mtd: intel_vr_nor: constify pci_device_id.
authorArvind Yadav <arvind.yadav.cs@gmail.com>
Thu, 3 Aug 2017 16:22:09 +0000 (21:52 +0530)
committerBoris Brezillon <boris.brezillon@free-electrons.com>
Tue, 15 Aug 2017 12:00:46 +0000 (14:00 +0200)
pci_device_id are not supposed to change at runtime. All functions
working with pci_device_id provided by <linux/pci.h> work with
const pci_device_id. So mark the non-const structs as const.

Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com>
Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com>
drivers/mtd/maps/intel_vr_nor.c

index 8bf79775e7c1abb8b5652008c48f6179029f79cd..dd5d6855f5432083e4745974dbf19213d4a5d690 100644 (file)
@@ -170,7 +170,7 @@ static int vr_nor_init_maps(struct vr_nor_mtd *p)
        return err;
 }
 
-static struct pci_device_id vr_nor_pci_ids[] = {
+static const struct pci_device_id vr_nor_pci_ids[] = {
        {PCI_DEVICE(PCI_VENDOR_ID_INTEL, 0x500D)},
        {0,}
 };