Re: Linux 2.5.4 Sound Driver Problem

From: John Weber (weber@nyc.rr.com)
Date: Mon Feb 11 2002 - 13:13:22 EST


Alan Cox wrote:
>>>The sound_alloc_dmap() function in dmabuf.c must be changed from using
>>>__get_free_pages() and virt_to_bus() -> pci_alloc_consistent().
>>>
>>What the hell are you talking about, I changed it long ago.
>>Linus uses ymfpci on his Crusoe Picturebook with no problems.
>>What is your kernel version?
>>
>
> In the ymfpci case its not the sound_alloc_dmap (at least not in 2.4 but
> 2.5 might be out of date except in -dj). Its the use of virt_to_bus still
> rather than the handles returned from the pci api
>
>

I am looking at both 2.5.4 and 2.4.18-pre9.

In my copy of sound_alloc_dmap(), I see a direct call to
__get_free_pages to allocate the buffer and a call to virt_to_bus. I
just thought that this could be cleared up by using pci_alloc_consistent
(since this function will call __get_free_pages anyway and eliminates
the need to use virt_to_bus).

Anyway, I'm not sure I understand this. I know using the virt_to_bus is
wrong, but why would we use __get_free_pages() here? (This is not a
rhetorical question, I honestly want to learn).

-
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/



This archive was generated by hypermail 2b29 : Fri Feb 15 2002 - 21:00:40 EST