aboutsummaryrefslogtreecommitdiffstats
path: root/arch/powerpc/sysdev
diff options
context:
space:
mode:
authorUwe Kleine-König <u.kleine-koenig@pengutronix.de>2014-09-10 15:56:38 -0400
committerMichael Ellerman <mpe@ellerman.id.au>2014-09-25 09:14:46 -0400
commitce6d73c94d7cfbdc3dc31860fe14af2f37d1b4fe (patch)
tree004b418dc22e1e6be5b8ba27d229a67a4ceee4df /arch/powerpc/sysdev
parentd4fe0965e20820f3dd05bcc4d89de3da29bb83aa (diff)
powerpc: make of_device_ids const
of_device_ids (i.e. compatible strings and the respective data) are not supposed to change at runtime. All functions working with of_device_ids provided by <linux/of.h> work with const of_device_ids. This allows to mark all struct of_device_id const, too. While touching these line also put the __init annotation at the right position where necessary. Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Diffstat (limited to 'arch/powerpc/sysdev')
-rw-r--r--arch/powerpc/sysdev/axonram.c2
-rw-r--r--arch/powerpc/sysdev/fsl_85xx_l2ctlr.c2
-rw-r--r--arch/powerpc/sysdev/mv64x60_dev.c2
-rw-r--r--arch/powerpc/sysdev/pmi.c2
-rw-r--r--arch/powerpc/sysdev/xilinx_intc.c2
-rw-r--r--arch/powerpc/sysdev/xilinx_pci.c2
6 files changed, 6 insertions, 6 deletions
diff --git a/arch/powerpc/sysdev/axonram.c b/arch/powerpc/sysdev/axonram.c
index 47b6b9f81d43..ad56edc39919 100644
--- a/arch/powerpc/sysdev/axonram.c
+++ b/arch/powerpc/sysdev/axonram.c
@@ -314,7 +314,7 @@ axon_ram_remove(struct platform_device *device)
314 return 0; 314 return 0;
315} 315}
316 316
317static struct of_device_id axon_ram_device_id[] = { 317static const struct of_device_id axon_ram_device_id[] = {
318 { 318 {
319 .type = "dma-memory" 319 .type = "dma-memory"
320 }, 320 },
diff --git a/arch/powerpc/sysdev/fsl_85xx_l2ctlr.c b/arch/powerpc/sysdev/fsl_85xx_l2ctlr.c
index afc2dbf37011..90545ad1626e 100644
--- a/arch/powerpc/sysdev/fsl_85xx_l2ctlr.c
+++ b/arch/powerpc/sysdev/fsl_85xx_l2ctlr.c
@@ -171,7 +171,7 @@ static int mpc85xx_l2ctlr_of_remove(struct platform_device *dev)
171 return 0; 171 return 0;
172} 172}
173 173
174static struct of_device_id mpc85xx_l2ctlr_of_match[] = { 174static const struct of_device_id mpc85xx_l2ctlr_of_match[] = {
175 { 175 {
176 .compatible = "fsl,p2020-l2-cache-controller", 176 .compatible = "fsl,p2020-l2-cache-controller",
177 }, 177 },
diff --git a/arch/powerpc/sysdev/mv64x60_dev.c b/arch/powerpc/sysdev/mv64x60_dev.c
index c2dba7db71ad..026bbc3b2c47 100644
--- a/arch/powerpc/sysdev/mv64x60_dev.c
+++ b/arch/powerpc/sysdev/mv64x60_dev.c
@@ -23,7 +23,7 @@
23 23
24/* These functions provide the necessary setup for the mv64x60 drivers. */ 24/* These functions provide the necessary setup for the mv64x60 drivers. */
25 25
26static struct of_device_id __initdata of_mv64x60_devices[] = { 26static const struct of_device_id of_mv64x60_devices[] __initconst = {
27 { .compatible = "marvell,mv64306-devctrl", }, 27 { .compatible = "marvell,mv64306-devctrl", },
28 {} 28 {}
29}; 29};
diff --git a/arch/powerpc/sysdev/pmi.c b/arch/powerpc/sysdev/pmi.c
index 5aaf86c03893..13e67d93a7c1 100644
--- a/arch/powerpc/sysdev/pmi.c
+++ b/arch/powerpc/sysdev/pmi.c
@@ -101,7 +101,7 @@ out:
101} 101}
102 102
103 103
104static struct of_device_id pmi_match[] = { 104static const struct of_device_id pmi_match[] = {
105 { .type = "ibm,pmi", .name = "ibm,pmi" }, 105 { .type = "ibm,pmi", .name = "ibm,pmi" },
106 { .type = "ibm,pmi" }, 106 { .type = "ibm,pmi" },
107 {}, 107 {},
diff --git a/arch/powerpc/sysdev/xilinx_intc.c b/arch/powerpc/sysdev/xilinx_intc.c
index 83f943a8e0db..56f0524e47a6 100644
--- a/arch/powerpc/sysdev/xilinx_intc.c
+++ b/arch/powerpc/sysdev/xilinx_intc.c
@@ -265,7 +265,7 @@ static void __init xilinx_i8259_setup_cascade(void)
265static inline void xilinx_i8259_setup_cascade(void) { return; } 265static inline void xilinx_i8259_setup_cascade(void) { return; }
266#endif /* defined(CONFIG_PPC_I8259) */ 266#endif /* defined(CONFIG_PPC_I8259) */
267 267
268static struct of_device_id xilinx_intc_match[] __initconst = { 268static const struct of_device_id xilinx_intc_match[] __initconst = {
269 { .compatible = "xlnx,opb-intc-1.00.c", }, 269 { .compatible = "xlnx,opb-intc-1.00.c", },
270 { .compatible = "xlnx,xps-intc-1.00.a", }, 270 { .compatible = "xlnx,xps-intc-1.00.a", },
271 {} 271 {}
diff --git a/arch/powerpc/sysdev/xilinx_pci.c b/arch/powerpc/sysdev/xilinx_pci.c
index 1453b0eed220..fea5667699ed 100644
--- a/arch/powerpc/sysdev/xilinx_pci.c
+++ b/arch/powerpc/sysdev/xilinx_pci.c
@@ -27,7 +27,7 @@
27 27
28#define PCI_HOST_ENABLE_CMD PCI_COMMAND_SERR | PCI_COMMAND_PARITY | PCI_COMMAND_MASTER | PCI_COMMAND_MEMORY 28#define PCI_HOST_ENABLE_CMD PCI_COMMAND_SERR | PCI_COMMAND_PARITY | PCI_COMMAND_MASTER | PCI_COMMAND_MEMORY
29 29
30static struct of_device_id xilinx_pci_match[] = { 30static const struct of_device_id xilinx_pci_match[] = {
31 { .compatible = "xlnx,plbv46-pci-1.03.a", }, 31 { .compatible = "xlnx,plbv46-pci-1.03.a", },
32 {} 32 {}
33}; 33};