hc
2024-09-20 a36159eec6ca17402b0e146b86efaf76568dc353
kernel/arch/arm/mach-iop32x/irq.c
....@@ -1,3 +1,4 @@
1
+// SPDX-License-Identifier: GPL-2.0-only
12 /*
23 * arch/arm/mach-iop32x/irq.c
34 *
....@@ -5,10 +6,6 @@
56 *
67 * Author: Rory Bolt <rorybolt@pacbell.net>
78 * Copyright (C) 2002 Rory Bolt
8
- *
9
- * This program is free software; you can redistribute it and/or modify
10
- * it under the terms of the GNU General Public License version 2 as
11
- * published by the Free Software Foundation.
129 */
1310
1411 #include <linux/init.h>
....@@ -16,8 +13,9 @@
1613 #include <linux/list.h>
1714 #include <asm/mach/irq.h>
1815 #include <asm/irq.h>
19
-#include <mach/hardware.h>
2016 #include <asm/mach-types.h>
17
+
18
+#include "hardware.h"
2119
2220 static u32 iop32x_mask;
2321
....@@ -34,14 +32,14 @@
3432 static void
3533 iop32x_irq_mask(struct irq_data *d)
3634 {
37
- iop32x_mask &= ~(1 << d->irq);
35
+ iop32x_mask &= ~(1 << (d->irq - 1));
3836 intctl_write(iop32x_mask);
3937 }
4038
4139 static void
4240 iop32x_irq_unmask(struct irq_data *d)
4341 {
44
- iop32x_mask |= 1 << d->irq;
42
+ iop32x_mask |= 1 << (d->irq - 1);
4543 intctl_write(iop32x_mask);
4644 }
4745
....@@ -67,7 +65,7 @@
6765 machine_is_em7210())
6866 *IOP3XX_PCIIRSR = 0x0f;
6967
70
- for (i = 0; i < NR_IRQS; i++) {
68
+ for (i = 1; i < NR_IRQS; i++) {
7169 irq_set_chip_and_handler(i, &ext_chip, handle_level_irq);
7270 irq_clear_status_flags(i, IRQ_NOREQUEST | IRQ_NOPROBE);
7371 }