Re: [PATCH 5/5] usb/hcd: Ensure scatter-gather is not used for isoc transfers

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, 3 Jul 2012, Peter Stuge wrote:

> Hans de Goede wrote:
> > +++ b/drivers/usb/core/hcd.c
> > @@ -1389,7 +1389,12 @@ int usb_hcd_map_urb_for_dma(struct usb_hcd *hcd, struct urb *urb,
> >  	    && !(urb->transfer_flags & URB_NO_TRANSFER_DMA_MAP)) {
> >  		if (hcd->self.uses_dma) {
> >  			if (urb->num_sgs) {
> > -				int n = dma_map_sg(
> > +				int n;
> > +
> > +				/* We don't support sg for isoc transfers ! */
> > +				BUG_ON(usb_endpoint_xfer_isoc(&urb->ep->desc));
> 
> Again not very 2012. I'm not saying this is a must have right now,
> but I do think it is desirable. Isoc sg makes just as much sense to
> me as bulk sg, if not more. Yes may get interesting with empty
> buffers.

There's a good reason why isochronous transfers don't need this feature 
so much.  They _have_ to be limited in size, because they proceed at a 
fixed rate and they can't extend too far into the future owing to
limitations in the host controller drivers.

> In any case, maybe add a comment about *why* isoc sg isn't supported.

A comment would be okay.

Alan Stern

--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux