On Fri, 4 Jun 2004, Pete Zaitcev wrote:
> Hi, All:
>
> Suppose that I wish to transfer something from a page which might be
> mapped or not (highmem) in a client driver such as usb-storage.
>
> The setup works like this
>
> usb_stor_Bulk_transport
> usb_stor_bulk_transfer_sg
> usb_stor_bulk_transfer_sglist
> usb_sg_init
>
> Here things get interesting. If the controller does NOT want to use
> DMA, the check (dev->dev.dma_mask != 0) fails and we do this:
>
> if (dma) {
> /* hc may use _only_ transfer_dma */
> io->urbs [i]->transfer_dma = sg_dma_address (sg + i);
> len = sg_dma_len (sg + i);
> } else {
> /* hc may use _only_ transfer_buffer */
> io->urbs [i]->transfer_buffer =
> page_address (sg [i].page) + sg [i].offset;
> len = sg [i].length;
> }
>
> The page_address is NULL, and eventually, the controller driver
> oopses while trying to do outsb().
>
> It seems obvious to me that a kmap is missing somewhere, but where?
>
> -- Pete
It's funny you should bring this up. I've mentioned it to David Brownell
on at least two occasions (sometimes I forget that I've already asked a
question).
The current answer is that the most widespread host controllers do use
DMA, and the ones that don't generally aren't used on systems with more
than 1 GB of memory. So for now it's not a problem, although it may
become a problem in the future.
Alan Stern
-------------------------------------------------------
This SF.Net email is sponsored by the new InstallShield X.
>From Windows to Linux, servers to mobile, InstallShield X is the one
installation-authoring solution that does it all. Learn more and
evaluate today! http://www.installshield.com/Dev2Dev/0504
_______________________________________________
[EMAIL PROTECTED]
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-devel