[PATCH] USB: Fix invalid dereference of initdata

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

 



Hi,

I found the issue in some hacked-up android 2.6.32 based kernel for
OMAP3 for an embedded project. However, afaik, the issue is still in
the USB development tree head and Torvalds' git.

The following patch applies both to the Torvalds' git and the USB
development tree.

Best regards,

Martin Jackson



From: Martin Jackson <mjackson220.list@xxxxxxxxx>

as_out_ep_desc contines to be used during gadget enumeration and thus
should not be marked as __initdata

Signed-off-by: Martin Jackson <mjackson220.list@xxxxxxxxx>

---

--- a/drivers/usb/gadget/f_audio.c 2011-05-16 12:03:15.027391360 +0200
+++ b/drivers/usb/gadget/f_audio.c 2011-05-16 12:04:43.787141989 +0200
@@ -177,7 +177,7 @@
 };

 /* Standard ISO OUT Endpoint Descriptor */
-static struct usb_endpoint_descriptor as_out_ep_desc __initdata = {
+static struct usb_endpoint_descriptor as_out_ep_desc  = {
 	.bLength =		USB_DT_ENDPOINT_AUDIO_SIZE,
 	.bDescriptorType =	USB_DT_ENDPOINT,
 	.bEndpointAddress =	USB_DIR_OUT,
--
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