aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/core/endpoint.c
diff options
context:
space:
mode:
authorRikard Falkeborn <rikard.falkeborn@gmail.com>2020-11-25 17:24:58 +0100
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2020-11-26 13:40:42 +0100
commit4154a4f70a9488212f8731770e10eae957d33da9 (patch)
tree4cd6f87dead07b766b15f5e61705a90860e9a625 /drivers/usb/core/endpoint.c
parent11e5e568ceed7c8c570313a14fa96c72f21dad31 (diff)
downloadlinux-4154a4f70a9488212f8731770e10eae957d33da9.tar.gz
USB: core: Constify static attribute_group structs
These are never modified, so make them const to allow the compiler to put them in read-only memory. Done with the help of coccinelle. Signed-off-by: Rikard Falkeborn <rikard.falkeborn@gmail.com> Link: https://lore.kernel.org/r/20201125162500.37228-2-rikard.falkeborn@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/usb/core/endpoint.c')
-rw-r--r--drivers/usb/core/endpoint.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/usb/core/endpoint.c b/drivers/usb/core/endpoint.c
index 1c2c040796760..903426b6d305c 100644
--- a/drivers/usb/core/endpoint.c
+++ b/drivers/usb/core/endpoint.c
@@ -153,7 +153,7 @@ static struct attribute *ep_dev_attrs[] = {
&dev_attr_direction.attr,
NULL,
};
-static struct attribute_group ep_dev_attr_grp = {
+static const struct attribute_group ep_dev_attr_grp = {
.attrs = ep_dev_attrs,
};
static const struct attribute_group *ep_dev_groups[] = {