Skip to content

Commit 9cb3ce5

Browse files
nmarci1dtor
authored andcommitted
Input: make USB device ids constant
The id_table field of the struct usb_device_id is constant in <linux/usb.h> so it makes sense to mark the initialization data also constant. Signed-off-by: Márton Németh <nm127@freemail.hu> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
1 parent c6d5709 commit 9cb3ce5

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

‎drivers/input/tablet/gtco.c‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ Scott Hill shill@gtcocalcomp.com
9292
/* DATA STRUCTURES */
9393

9494
/* Device table */
95-
static struct usb_device_id gtco_usbid_table [] = {
95+
static const struct usb_device_id gtco_usbid_table[] = {
9696
{ USB_DEVICE(VENDOR_ID_GTCO, PID_400) },
9797
{ USB_DEVICE(VENDOR_ID_GTCO, PID_401) },
9898
{ USB_DEVICE(VENDOR_ID_GTCO, PID_1000) },

‎drivers/input/touchscreen/usbtouchscreen.c‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -144,7 +144,7 @@ enum {
144144
.bInterfaceClass = USB_INTERFACE_CLASS_HID, \
145145
.bInterfaceProtocol = USB_INTERFACE_PROTOCOL_MOUSE
146146

147-
static struct usb_device_id usbtouch_devices[] = {
147+
static const struct usb_device_id usbtouch_devices[] = {
148148
#ifdef CONFIG_TOUCHSCREEN_USB_EGALAX
149149
/* ignore the HID capable devices, handled by usbhid */
150150
{USB_DEVICE_HID_CLASS(0x0eef, 0x0001), .driver_info = DEVTYPE_IGNORE},

0 commit comments

Comments
 (0)