On Tue, 22 May 2007, Laurent Pinchart wrote: > If not overly difficult, it might be interesting to implement transparent > s-g, > where the URB submission handler would cut buffers in pieces if needed. That > way buffers could be allocated with kmalloc/get_free_pages for small buffers > used infrequently, with usb_buffer_alloc for small buffers used in data > bulk/isochronous streaming or with vmalloc for big buffers.
Isn't that basically what I said Pete had done? Except that it wasn't transparent -- you had to call the library routine explicitly. Besides, can vmalloc be used for allocating DMA buffers? AFAIK it doesn't have any mechanism for respecting DMA memory location requirements (the DMA mask). > Thinking about it, scatter-gathering buffers transparently would make it > difficult to allocate coherent DMA mappings for data streaming. It would make > life easier for driver writers, but performances might be impacted. It isn't the streaming as such which makes coherent DMA mappings attractive; it's the constant re-use of existing buffers. Alan Stern ------------------------------------------------------------------------- This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ _______________________________________________ linux-usb-devel@lists.sourceforge.net To unsubscribe, use the last form field at: https://lists.sourceforge.net/lists/listinfo/linux-usb-devel