Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1710255
| From | Bhumika Goyal <bhumirks@gmail.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | [PATCH 3/3] usb: dwc2: gadget: make usb_ep_ops const |
| Date | 2017-08-12 14:10 +0200 |
| Message-ID | <udDoS-yg-33@gated-at.bofh.it> (permalink) |
| References | <udDoS-yg-21@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
Make the structure const as it is only stored in the ops field of a
usb_ep structure, which is of type const.
Done using Coccinelle.
Signed-off-by: Bhumika Goyal <bhumirks@gmail.com>
---
drivers/usb/dwc2/gadget.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/usb/dwc2/gadget.c b/drivers/usb/dwc2/gadget.c
index c4066cd..0d8e09c 100644
--- a/drivers/usb/dwc2/gadget.c
+++ b/drivers/usb/dwc2/gadget.c
@@ -4179,7 +4179,7 @@ static int dwc2_hsotg_ep_sethalt_lock(struct usb_ep *ep, int value)
return ret;
}
-static struct usb_ep_ops dwc2_hsotg_ep_ops = {
+static const struct usb_ep_ops dwc2_hsotg_ep_ops = {
.enable = dwc2_hsotg_ep_enable,
.disable = dwc2_hsotg_ep_disable,
.alloc_request = dwc2_hsotg_ep_alloc_request,
--
1.9.1
Back to linux.kernel | Previous | Next — Previous in thread | Find similar | Unroll thread
[PATCH 0/3] usb: make usb_ep_ops const Bhumika Goyal <bhumirks@gmail.com> - 2017-08-12 14:10 +0200 [PATCH 1/3] usb: renesas_usbhs: gadget: make usb_ep_ops const Bhumika Goyal <bhumirks@gmail.com> - 2017-08-12 14:10 +0200 [PATCH 2/3] usb: gadget: udc: renesas_usb3: make usb_ep_ops const Bhumika Goyal <bhumirks@gmail.com> - 2017-08-12 14:10 +0200 [PATCH 3/3] usb: dwc2: gadget: make usb_ep_ops const Bhumika Goyal <bhumirks@gmail.com> - 2017-08-12 14:10 +0200
csiph-web