On Fri, Jun 14, 2013 at 08:24:24PM +0300, Jussi Kivilinna wrote: > On 14.06.2013 19:05, Greg Kroah-Hartman wrote: > > On Fri, Jun 14, 2013 at 04:38:03PM +0300, Jussi Kivilinna wrote: > >> Appearently some out-of-tree USB host drivers do not handle DMA alignment for > >> URB buffers and let core/hcd.c to do the mapping on architectures that have > >> minimum DMA alignment requirements. This leads to random memory corruptions > >> and crashes when using USB device drivers that use unaligned URB buffers. > >> > >> Instead of fixing host drivers, users end up posting bug reports against > >> those USB device drivers that use unaligned buffers for URB; such as with > >> rtl8192cu (http://thread.gmane.org/gmane.linux.kernel.wireless.general/105631). > >> > >> Patch makes this issue more visible at core level, and hopefully gives hint > >> for future hcd driver implementors about this problem. > > > > You should be more forceful in your warning messages to blame the host > > controller, as it is, if I was a user and I saw: > > > >> + WARN_ONCE(1, "urb->setup_packet not DMA aligned.\n"); > > > > I would think that the device driver was still the problem, not the host > > controller. > > Ok. Would this be better? > > "Possibly broken USB host controller driver; does not correctly handle DMA alignment for urb->blabla.\n" > > ... or should that 'Possibly' be dropped and just say "broken USB ...". Yes, just say "broken", and give the device id of the broken USB controller (I think you have a pointer to it somewhere at that time, right?) thanks, greg k-h -- 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