public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH][2.5.74] fix IDE init oops on PowerMac
@ 2003-07-04  0:16 Mikael Pettersson
  2003-07-06 19:28 ` Benjamin Herrenschmidt
  0 siblings, 1 reply; 3+ messages in thread
From: Mikael Pettersson @ 2003-07-04  0:16 UTC (permalink / raw)
  To: benh, paulus; +Cc: linux-kernel

Booting kernel 2.5.74 on a PowerMac with CONFIG_BLK_DEV_IDE_PMAC=y
results in an oops during IDE init, and the box then reboots.

The call chain at the oops is ideprobe_init() => probe_hwif() =>
__ide_dma_off_quietly() => HWIF(drive)->ide_dma_queued_off().
The HWIF(drive)->ide_dma_queued_off function pointer is NULL for
PMAC, which triggers the oops. Previously this call was conditional
on drive->queue_setup, but 2.5.74 made it unconditional.

The patch below updates drivers/ide/ppc/pmac.c to also set up the
hwif->ide_dma_queued_off and hwif->ide_dma_queued_on function
pointers, which fixes the oops. Tested on my ancient PM4400.

(I apologize for not including a full oops text, but the box has
no serial console.)

/Mikael

diff -ruN linux-2.5.74/drivers/ide/ppc/pmac.c linux-2.5.74.ide-pmac-fixes/drivers/ide/ppc/pmac.c
--- linux-2.5.74/drivers/ide/ppc/pmac.c	2003-05-28 22:16:00.000000000 +0200
+++ linux-2.5.74.ide-pmac-fixes/drivers/ide/ppc/pmac.c	2003-07-04 00:45:05.000000000 +0200
@@ -1514,6 +1514,8 @@
 	ide_hwifs[ix].ide_dma_timeout = &__ide_dma_timeout;
 	ide_hwifs[ix].ide_dma_retune = &__ide_dma_retune;
 	ide_hwifs[ix].ide_dma_lostirq = &pmac_ide_dma_lostirq;
+	ide_hwifs[ix].ide_dma_queued_on = &__ide_dma_queued_on;
+	ide_hwifs[ix].ide_dma_queued_off = &__ide_dma_queued_off;
 
 #ifdef CONFIG_BLK_DEV_IDEDMA_PMAC_AUTO
 	if (!noautodma)

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2003-07-07  6:39 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-07-04  0:16 [PATCH][2.5.74] fix IDE init oops on PowerMac Mikael Pettersson
2003-07-06 19:28 ` Benjamin Herrenschmidt
2003-07-07  6:53   ` Paul Mackerras

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox