X-Git-Url: http://wien.tomnetworks.com/gitweb/?a=blobdiff_plain;ds=sidebyside;f=irq.c;h=da2456b7084e9e6361fbf47a7ab9113e5252bc11;hb=3a17a5742283d2510b6bdcf42dcb76cdb66d3770;hp=1c5902b6de6f34af6700e3254f4452e7188b94b9;hpb=cbb2f30692a3d5cb7817aaa95dc14f8db24f5adb;p=ppcskel.git diff --git a/irq.c b/irq.c index 1c5902b..da2456b 100644 --- a/irq.c +++ b/irq.c @@ -19,19 +19,20 @@ Copyright (C) 2009 Andre Heider "dhewg" void irq_initialize(void) { - // enable hollywood-pic for ppc + // clear flipper-pic (processor interface) + write32(BW_PI_IRQMASK, 0); + write32(BW_PI_IRQFLAG, 0xffffffff); + + // clear hollywood-pic write32(HW_PPCIRQMASK, 0); write32(HW_PPCIRQFLAG, 0xffffffff); - // enable RESET and PIC (#14) interrupts on processor interface - write32(BW_PI_IRQMASK, 0); - write32(BW_PI_IRQFLAG, 0xffffffff); + printf("PPCIRQMASK: 0x%08X\n", read32(HW_PPCIRQMASK)); + //??? -- needed?! - /* write32(HW_PPCIRQMASK+0x04, 0); write32(HW_PPCIRQMASK+0x20, 0); - */ _CPU_ISR_Enable() } @@ -51,11 +52,11 @@ void irq_handler(void) flags = flags & enabled; - if (flags & (1<<1)) { //RESET + if (flags & (1<