Kyle Moffett wrote:
BusMaster-DMA definitely should be enabled on that card. After a lot of looking through icky IDE code, I've determined that the reason for the crash is that if there is a "mate", or another IDE bus on the same card, then hwif->dma_master is set to hwif->mate- >dma_base on the secondary channel. Since DMA explicitly wasn't enabled on the primary channel, hwif->dma_master on the secondary is 0 even though dma is enabled, and therefore we hit that BUG().
Therefore it seems that the only issue is ide_get_or_set_dma_base is returning 0 when it should return a valid DMA base. In that function, the only ways that function can even theoretically return 0 without printing any weird error messages is "if (hwif- >mmio)" or "if (hwif->mate && hwif->mate->dma_base)". The latter can't happen before hwif->mate is set up (since the problem is while initializing the primary). Could hwif->mmio be nonzero somehow? The only drivers that seem to set it are pci/sgiioc4, pci/ siimage, ppc/pmac, and a couple misc arch drivers.
Maybe there is some fighting going on between ppc/pmac.c and that driver over the hwif's and you end up with mmio inadvertently set ?