aboutsummaryrefslogtreecommitdiffstats
path: root/target
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
commit9ac8ae9d85a9b1ea2e70981bbe7f1dedf2200e70 (patch)
treef34dd9acecc68e14bdd0cf200a43de5f96d1310a /target
parent196af748d00a1a280a0ec1cdea3d4b41ff80d9e2 (diff)
downloadupstream-9ac8ae9d85a9b1ea2e70981bbe7f1dedf2200e70.tar.gz
upstream-9ac8ae9d85a9b1ea2e70981bbe7f1dedf2200e70.tar.bz2
upstream-9ac8ae9d85a9b1ea2e70981bbe7f1dedf2200e70.zip
ssb-mips: Fix IRQ routing on the MIPS core.
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@10770 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'target')
-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 3d3dd32bf3..a9e7eb45b2 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)