diff options
author | Jules Irenge <jbi.octave@gmail.com> | 2020-04-29 11:05:23 +0100 |
---|---|---|
committer | Felipe Balbi <balbi@kernel.org> | 2020-05-25 11:09:40 +0300 |
commit | 66bd76e79e41eb79452e10d62f2099742a7feeb0 (patch) | |
tree | 8e007ee45d0e349cd6451395beaece34aa49b945 | |
parent | 46b11a91124d481ff4754ec624fc5393a515a361 (diff) | |
download | linux-66bd76e79e41eb79452e10d62f2099742a7feeb0.tar.bz2 |
usb: gadget: Add missing annotation for xudc_handle_setup()
Sparse reports a warning at xudc_handle_setup()
warning: context imbalance in xudc_handle_setup() - unexpected unlock
The root cause is the missing annotation at xudc_handle_setup()
Add the missing __must_hold(&udc->lock) annotation
Signed-off-by: Jules Irenge <jbi.octave@gmail.com>
Signed-off-by: Felipe Balbi <balbi@kernel.org>
-rw-r--r-- | drivers/usb/gadget/udc/udc-xilinx.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/usb/gadget/udc/udc-xilinx.c b/drivers/usb/gadget/udc/udc-xilinx.c index b1cfc8279c3d..709553bdb233 100644 --- a/drivers/usb/gadget/udc/udc-xilinx.c +++ b/drivers/usb/gadget/udc/udc-xilinx.c @@ -1732,6 +1732,7 @@ static void xudc_set_clear_feature(struct xusb_udc *udc) * Process setup packet and delegate to gadget layer. */ static void xudc_handle_setup(struct xusb_udc *udc) + __must_hold(&udc->lock) { struct xusb_ep *ep0 = &udc->ep[0]; struct usb_ctrlrequest setup; |