From 7010bdba62be4800a89fea2317054b46481c64ca Mon Sep 17 00:00:00 2001 From: Hemant Kumar Date: Thu, 5 Feb 2015 13:19:08 -0800 Subject: usb: gadget: f_mbim: Queue notification request upon function resume In super speed mode if userspace issues a write after usb bus suspend usb_func_ep_queue() schedules wakeup to resume the function. After that it queues the request which fails with -ENOTSUPP. As a result no notification request queued to hw and write request gets delayed to be sent until another write request comes and queues notification request after function resume. This causes mismatch to the mbim request response. Fix this by queuing the notification request upon function resume if notify count is greater than zero. Also, drop control packet after bus suspend if remote wakeup is not supported or if ep enqueue returns error other than -EAGAIN. CRs-Fixed: 789467 Change-Id: I446de1eb169b4ccb8f4db5f003b622d7b9c0b22b Signed-off-by: Hemant Kumar Signed-off-by: Azhar Shaikh --- include/linux/usb/composite.h | 1 + 1 file changed, 1 insertion(+) (limited to 'include/linux') diff --git a/include/linux/usb/composite.h b/include/linux/usb/composite.h index 2c7cf4c1f569..98b39ed43f5b 100644 --- a/include/linux/usb/composite.h +++ b/include/linux/usb/composite.h @@ -189,6 +189,7 @@ struct usb_os_desc_table { struct usb_function { const char *name; + int intf_id; struct usb_gadget_strings **strings; struct usb_descriptor_header **fs_descriptors; struct usb_descriptor_header **hs_descriptors; -- cgit v1.2.3