Hi, the priority array of the gic_state structure contains 96 elements but gic_set_running_irq is also called with irq == 1023 so that without the fix some random value is used for s->running_priority. The printf patch is necessary to make the DPRINTFs work.
Index: arm_gic.c =================================================================== RCS file: /sources/qemu/qemu/hw/arm_gic.c,v retrieving revision 1.2 diff -u -r1.2 arm_gic.c --- arm_gic.c 1 Oct 2006 13:03:52 -0000 1.2 +++ arm_gic.c 4 Oct 2006 13:39:24 -0000 @@ -17,7 +17,7 @@ #ifdef DEBUG_GIC #define DPRINTF(fmt, args...) \ -do { printf("arm_gic: " fmt , (int)s->base, ##args); } while (0) +do { printf("arm_gic(%x): " fmt , (int)s->base, ##args); } while (0) #else #define DPRINTF(fmt, args...) do {} while(0) #endif @@ -135,7 +135,7 @@ static void gic_set_running_irq(gic_state *s, int irq) { s->running_irq = irq; - s->running_priority = s->priority[irq]; + s->running_priority = (irq == 1023) ? 0x100 : s->priority[irq]; gic_update(s); } Thanks, Adam -- Adam [EMAIL PROTECTED] Lackorzynski http://os.inf.tu-dresden.de/~adam/ _______________________________________________ Qemu-devel mailing list Qemu-devel@nongnu.org http://lists.nongnu.org/mailman/listinfo/qemu-devel