diff options
| author | Elson Roy Serrao <quic_eserrao@quicinc.com> | 2023-03-25 00:47:57 +0300 |
|---|---|---|
| committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2023-03-29 11:27:00 +0300 |
| commit | b93c2a68f3d9dc98ec30dcb342ae47c1c8d09d18 (patch) | |
| tree | 0ab2f0fef04383c702f06f478ba36e0ce964fc18 /include/linux/usb/composite.h | |
| parent | 79e94aa19736ec8f38ec02880eeec37cc5900bd8 (diff) | |
| download | linux-b93c2a68f3d9dc98ec30dcb342ae47c1c8d09d18.tar.xz | |
usb: gadget: Properly configure the device for remote wakeup
The wakeup bit in the bmAttributes field indicates whether the device
is configured for remote wakeup. But this field should be allowed to
set only if the UDC supports such wakeup mechanism. So configure this
field based on UDC capability. Also inform the UDC whether the device
is configured for remote wakeup by implementing a gadget op.
Reviewed-by: Thinh Nguyen <Thinh.Nguyen@synopsys.com>
Signed-off-by: Elson Roy Serrao <quic_eserrao@quicinc.com>
Link: https://lore.kernel.org/r/1679694482-16430-2-git-send-email-quic_eserrao@quicinc.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'include/linux/usb/composite.h')
| -rw-r--r-- | include/linux/usb/composite.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/include/linux/usb/composite.h b/include/linux/usb/composite.h index 608dc962748b..d949e91ceb48 100644 --- a/include/linux/usb/composite.h +++ b/include/linux/usb/composite.h @@ -413,6 +413,8 @@ extern int composite_dev_prepare(struct usb_composite_driver *composite, extern int composite_os_desc_req_prepare(struct usb_composite_dev *cdev, struct usb_ep *ep0); void composite_dev_cleanup(struct usb_composite_dev *cdev); +void check_remote_wakeup_config(struct usb_gadget *g, + struct usb_configuration *c); static inline struct usb_composite_driver *to_cdriver( struct usb_gadget_driver *gdrv) |
