summaryrefslogtreecommitdiff
path: root/target/linux
diff options
context:
space:
mode:
authorMichael Büsch <mb@bu3sch.de>2008-04-08 09:15:53 +0000
committerMichael Büsch <mb@bu3sch.de>2008-04-08 09:15:53 +0000
commit2e8af76a605b094f869a19dba541a219bebe84fd (patch)
tree41058b729924a14f7d26ed23c9fac36400207ae4 /target/linux
parent99e6b2d7dcb7d43c90704735dc71b098f6175dbe (diff)
downloadmtk-20170518-2e8af76a605b094f869a19dba541a219bebe84fd.zip
mtk-20170518-2e8af76a605b094f869a19dba541a219bebe84fd.tar.gz
mtk-20170518-2e8af76a605b094f869a19dba541a219bebe84fd.tar.bz2
ssb-mips: Fix IRQ routing on the MIPS core.
SVN-Revision: 10770
Diffstat (limited to 'target/linux')
-rw-r--r--target/linux/generic-2.6/files/drivers/ssb/driver_mipscore.c13
1 files changed, 7 insertions, 6 deletions
diff --git a/target/linux/generic-2.6/files/drivers/ssb/driver_mipscore.c b/target/linux/generic-2.6/files/drivers/ssb/driver_mipscore.c
index 3d3dd32..a9e7eb4 100644
--- a/target/linux/generic-2.6/files/drivers/ssb/driver_mipscore.c
+++ b/target/linux/generic-2.6/files/drivers/ssb/driver_mipscore.c
@@ -109,12 +109,13 @@ static void set_irq(struct ssb_device *dev, unsigned int irq)
clear_irq(bus, oldirq);
/* assign the new one */
- if (irq == 0)
- ssb_write32(mdev, SSB_INTVEC, ((1 << irqflag) & ssb_read32(mdev, SSB_INTVEC)));
-
- irqflag <<= ipsflag_irq_shift[irq];
- irqflag |= (ssb_read32(mdev, SSB_IPSFLAG) & ~ipsflag_irq_mask[irq]);
- ssb_write32(mdev, SSB_IPSFLAG, irqflag);
+ if (irq == 0) {
+ ssb_write32(mdev, SSB_INTVEC, ((1 << irqflag) | ssb_read32(mdev, SSB_INTVEC)));
+ } else {
+ irqflag <<= ipsflag_irq_shift[irq];
+ irqflag |= (ssb_read32(mdev, SSB_IPSFLAG) & ~ipsflag_irq_mask[irq]);
+ ssb_write32(mdev, SSB_IPSFLAG, irqflag);
+ }
}
static void ssb_mips_serial_init(struct ssb_mipscore *mcore)