diff options
author | Shinya Kuribayashi <skuribay@pobox.com> | 2010-06-27 09:52:01 -0400 |
---|---|---|
committer | Ralf Baechle <ralf@linux-mips.org> | 2010-08-05 08:26:05 -0400 |
commit | f5c1ca77a3b2f9b424c4f39bd71143d0ac308924 (patch) | |
tree | 361d18f2ac0b08bd480403aeca319f725eefd585 /arch/mips/loongson | |
parent | 1f1f4e7dbc0c0312e9e7fe3cadd07340ea62070f (diff) |
MIPS: Loongson: irq.c: Misc cleanups
* Remove unnecessary 'if (int_status & (1 <<10))' statement
* s/if (foo != 0)/if (foo)/
* Remove unused 'inst_status &= ~(1 << i);' line
Signed-off-by: Shinya Kuribayashi <skuribay@pobox.com>
To: wuzhangjin@gmail.com
CC: linux-mips@linux-mips.org
Patchwork: https://patchwork.linux-mips.org/patch/1433/
Acked-by: Wu Zhangjin <wuzhangjin@gmail.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Diffstat (limited to 'arch/mips/loongson')
-rw-r--r-- | arch/mips/loongson/common/irq.c | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/arch/mips/loongson/common/irq.c b/arch/mips/loongson/common/irq.c index 20e732831978..25a11df03482 100644 --- a/arch/mips/loongson/common/irq.c +++ b/arch/mips/loongson/common/irq.c | |||
@@ -21,19 +21,16 @@ void bonito_irqdispatch(void) | |||
21 | 21 | ||
22 | /* workaround the IO dma problem: let cpu looping to allow DMA finish */ | 22 | /* workaround the IO dma problem: let cpu looping to allow DMA finish */ |
23 | int_status = LOONGSON_INTISR; | 23 | int_status = LOONGSON_INTISR; |
24 | if (int_status & (1 << 10)) { | 24 | while (int_status & (1 << 10)) { |
25 | while (int_status & (1 << 10)) { | 25 | udelay(1); |
26 | udelay(1); | 26 | int_status = LOONGSON_INTISR; |
27 | int_status = LOONGSON_INTISR; | ||
28 | } | ||
29 | } | 27 | } |
30 | 28 | ||
31 | /* Get pending sources, masked by current enables */ | 29 | /* Get pending sources, masked by current enables */ |
32 | int_status = LOONGSON_INTISR & LOONGSON_INTEN; | 30 | int_status = LOONGSON_INTISR & LOONGSON_INTEN; |
33 | 31 | ||
34 | if (int_status != 0) { | 32 | if (int_status) { |
35 | i = __ffs(int_status); | 33 | i = __ffs(int_status); |
36 | int_status &= ~(1 << i); | ||
37 | do_IRQ(LOONGSON_IRQ_BASE + i); | 34 | do_IRQ(LOONGSON_IRQ_BASE + i); |
38 | } | 35 | } |
39 | } | 36 | } |