can: constify of_device_id array
authorFabian Frederick <fabf@skynet.be>
Tue, 17 Mar 2015 18:40:24 +0000 (19:40 +0100)
committerBen Hutchings <ben@decadent.org.uk>
Tue, 20 Nov 2018 18:05:46 +0000 (18:05 +0000)
commit 486e957033623656298a07c39a8bf2fd81db285b upstream.

of_device_id is always used as const.
(See driver.of_match_table and open firmware functions)

Signed-off-by: Fabian Frederick <fabf@skynet.be>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
drivers/net/can/cc770/cc770_platform.c
drivers/net/can/grcan.c
drivers/net/can/mscan/mpc5xxx_can.c
drivers/net/can/sja1000/sja1000_platform.c
drivers/net/can/xilinx_can.c

index ad76734b3ecc79556ee4eb59e5c2025a10824b48..1092fc71c2257da355ea6ff659c5ceb86ad9dd24 100644 (file)
@@ -254,7 +254,7 @@ static int cc770_platform_remove(struct platform_device *pdev)
        return 0;
 }
 
-static struct of_device_id cc770_platform_table[] = {
+static const struct of_device_id cc770_platform_table[] = {
        {.compatible = "bosch,cc770"}, /* CC770 from Bosch */
        {.compatible = "intc,82527"},  /* AN82527 from Intel CP */
        {},
index 3fd9fd942c6ef0b38ddaca66492c115f5f5ea771..cfdce309e86402a07f14b3c52ca9e54a825c0036 100644 (file)
@@ -1725,7 +1725,7 @@ static int grcan_remove(struct platform_device *ofdev)
        return 0;
 }
 
-static struct of_device_id grcan_match[] = {
+static const struct of_device_id grcan_match[] = {
        {.name = "GAISLER_GRCAN"},
        {.name = "01_03d"},
        {.name = "GAISLER_GRHCAN"},
index 44725296f72a25b07d21bb92f9af1f0534980bc5..921dae56f937f5d44b31a9b14a43c825119ee0b8 100644 (file)
@@ -43,7 +43,7 @@ struct mpc5xxx_can_data {
 };
 
 #ifdef CONFIG_PPC_MPC52xx
-static struct of_device_id mpc52xx_cdm_ids[] = {
+static const struct of_device_id mpc52xx_cdm_ids[] = {
        { .compatible = "fsl,mpc5200-cdm", },
        {}
 };
index 95a844a7ee7b0befa46e7d6dd9704c9ad99fac8b..9345185e55a5e1ff0520110890535eb308301dba 100644 (file)
@@ -242,7 +242,7 @@ static int sp_remove(struct platform_device *pdev)
        return 0;
 }
 
-static struct of_device_id sp_of_table[] = {
+static const struct of_device_id sp_of_table[] = {
        {.compatible = "nxp,sja1000"},
        {},
 };
index 479e962c049206d29a55db9a3243f1fb8f979db6..15c2bca2cf58525954d970ea71dd6c154f3d637c 100644 (file)
@@ -1184,7 +1184,7 @@ static int xcan_remove(struct platform_device *pdev)
 }
 
 /* Match table for OF platform binding */
-static struct of_device_id xcan_of_match[] = {
+static const struct of_device_id xcan_of_match[] = {
        { .compatible = "xlnx,zynq-can-1.0", },
        { .compatible = "xlnx,axi-can-1.00.a", },
        { /* end of list */ },