Re: [PATCH] xHCI: refine td allocation

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

 



Am Dienstag, 26. Juli 2011, 13:17:12 schrieb Sergei Shtylyov:

Hi,

> > @@ -1059,13 +1060,15 @@ int xhci_urb_enqueue(struct usb_hcd *hcd, struct urb *urb, gfp_t mem_flags)
> >   	if (!urb_priv)
> >   		return -ENOMEM;
> >
> > +	buffer = kzalloc(size * sizeof(struct xhci_td), mem_flags);
> 
>     kcalloc() fits somewhat better here.

Is this really safe on all architectures? kmalloc() guarantees that you can
manipulate a TD without affecting other TDs

	Regards
		Oliver
--
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