From 41dd5272ca960be5026e1a9411ce65502cfeba18 Mon Sep 17 00:00:00 2001 From: Alexander Graf Date: Thu, 1 Apr 2010 23:40:21 +0000 Subject: [PATCH] [PPC] Make mac-io ata interrupts depend on local, not global index In commit r680 I incorrectly made the interrupt number of the mac-io ata device depend on its global index. Of course the interrupt only depends on its index inside the mac-io chip. So let's fix that up and make Qemu's oldworld emulation work again! Signed-off-by: Alexander Graf git-svn-id: svn://coreboot.org/openbios/trunk/openbios-devel@721 f158a5a8-5612-0410-a976-696ce0be7e32 --- drivers/ide.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/ide.c b/drivers/ide.c index 17e90a3..3b3fd90 100644 --- a/drivers/ide.c +++ b/drivers/ide.c @@ -1582,16 +1582,16 @@ int macio_ide_init(const char *path, uint32_t addr, int nb_channels) /* The first interrupt entry is the ide interrupt, the second the dbdma interrupt */ - switch (current_channel) { - case 1: + switch (i) { + case 0: props[0] = 0x0000000d; props[2] = 0x00000002; break; - case 2: + case 1: props[0] = 0x0000000e; props[2] = 0x00000003; break; - case 3: + case 2: props[0] = 0x0000000f; props[2] = 0x00000004; break;