diff mbox

NFC: nfcmrvl: constify usb_device_id

Message ID 339b58be7bd3cd1b3ca3310e4a8500d6c8bc1fdf.1502301580.git.arvind.yadav.cs@gmail.com (mailing list archive)
State Accepted
Delegated to: Samuel Ortiz
Headers show

Commit Message

Arvind Yadav Aug. 9, 2017, 6:03 p.m. UTC
usb_device_id are not supposed to change at runtime. All functions
working with usb_device_id provided by <linux/usb.h> work with
const usb_device_id. So mark the non-const structs as const.

Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com>
---
 drivers/nfc/nfcmrvl/usb.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox

Patch

diff --git a/drivers/nfc/nfcmrvl/usb.c b/drivers/nfc/nfcmrvl/usb.c
index bd35eab..46e11fc 100644
--- a/drivers/nfc/nfcmrvl/usb.c
+++ b/drivers/nfc/nfcmrvl/usb.c
@@ -23,7 +23,7 @@ 
 #include <net/nfc/nci_core.h>
 #include "nfcmrvl.h"
 
-static struct usb_device_id nfcmrvl_table[] = {
+static const struct usb_device_id nfcmrvl_table[] = {
 	{ USB_DEVICE_AND_INTERFACE_INFO(0x1286, 0x2046,
 					USB_CLASS_VENDOR_SPEC, 4, 1) },
 	{ }	/* Terminating entry */