Messages in this thread | | | Date | Mon, 11 Feb 2002 12:38:12 -0500 | From | John Weber <> | Subject | Re: 2.5.4, cs46xx snd, and virt_to_bus |
| |
Tom Gall wrote: > Hi All, > > Well forgive me for not being up on the lastest news but from building > 2.5.4 kernel for my box, which uses the cs46xx.c sound driver, it would > appear that virt_to_bus and bus_to_virt has gone the way of the do-do. > > What's the correct method now? > > Be nice to get this cleaned up.... > > Regards, > > Tom
Use pci_alloc_consistent() to allocate the buffer. This function returns the right thing so that virt_to_bus() is no longer needed.
From what I read, it looks like pci_alloc_consistent returns a pci address and a physical address (via dma_addr_t), so it should be simple to change the code to use this function. However, I don't know where the hell I'm supposed to find pci_dev -- I'll try rereading the driver-model.txt code again :).
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
| |