summaryrefslogtreecommitdiff
path: root/arch/mn10300/unit-asb2364/irq-fpga.c
diff options
context:
space:
mode:
authorDavid Howells <dhowells@redhat.com>2011-03-18 16:52:54 (GMT)
committerDavid Howells <dhowells@redhat.com>2011-03-18 16:52:54 (GMT)
commitddb7d1e975d224885397c002512ded987be3c3bc (patch)
treec24cbe7132c243450aa11939f4d88a2bde8ed6e0 /arch/mn10300/unit-asb2364/irq-fpga.c
parent02b2944cd70c3166984699dd623612e2f8a3eebf (diff)
downloadlinux-fsl-qoriq-ddb7d1e975d224885397c002512ded987be3c3bc.tar.xz
MN10300: Clear ASB2364 peripheral interrupt masks before enabling interrupts
Clear the interrupt mask registers of ASB2364 peripherals before enabling interrupts so that any peripherals that weren't dealt with by the bootloader after a reboot (if there was one) won't cause an interrupt storm when interrupts are first enabled before the drivers are initialised. Also, attempt to reset the peripherals attached to the FPGA. Signed-off-by: David Howells <dhowells@redhat.com>
Diffstat (limited to 'arch/mn10300/unit-asb2364/irq-fpga.c')
-rw-r--r--arch/mn10300/unit-asb2364/irq-fpga.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/arch/mn10300/unit-asb2364/irq-fpga.c b/arch/mn10300/unit-asb2364/irq-fpga.c
index 4204a6c..ee84e62 100644
--- a/arch/mn10300/unit-asb2364/irq-fpga.c
+++ b/arch/mn10300/unit-asb2364/irq-fpga.c
@@ -88,6 +88,17 @@ void __init irq_fpga_init(void)
{
int irq;
+ ASB2364_FPGA_REG_MASK_LAN = 0x0001;
+ SyncExBus();
+ ASB2364_FPGA_REG_MASK_UART = 0x0001;
+ SyncExBus();
+ ASB2364_FPGA_REG_MASK_I2C = 0x0001;
+ SyncExBus();
+ ASB2364_FPGA_REG_MASK_USB = 0x0001;
+ SyncExBus();
+ ASB2364_FPGA_REG_MASK_FPGA = 0x0001;
+ SyncExBus();
+
for (irq = NR_CPU_IRQS; irq < NR_IRQS; irq++)
set_irq_chip_and_handler(irq, &asb2364_fpga_pic, handle_level_irq);