]> git.proxmox.com Git - mirror_ubuntu-focal-kernel.git/commitdiff
[POWERPC] Constify the of_device_id passed to of_platform_bus_probe
authorStephen Rothwell <sfr@canb.auug.org.au>
Fri, 21 Dec 2007 04:21:51 +0000 (15:21 +1100)
committerPaul Mackerras <paulus@samba.org>
Fri, 21 Dec 2007 11:14:07 +0000 (22:14 +1100)
This will allow us to declare const all the statically declared arrrays
of these.

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
arch/powerpc/kernel/of_platform.c
include/asm-powerpc/of_platform.h

index 79c04d151ddbf52631199d0aa0baa328afed1d73..de36e235a60a3a2b4be2a9a8379f88b0cc29047b 100644 (file)
@@ -40,7 +40,7 @@
  * a bus type in the list
  */
 
-static struct of_device_id of_default_bus_ids[] = {
+static const struct of_device_id of_default_bus_ids[] = {
        { .type = "soc", },
        { .compatible = "soc", },
        { .type = "spider", },
@@ -100,8 +100,8 @@ EXPORT_SYMBOL(of_platform_device_create);
  * @matches: match table, NULL to use the default, OF_NO_DEEP_PROBE to
  * disallow recursive creation of child busses
  */
-static int of_platform_bus_create(struct device_node *bus,
-                                 struct of_device_id *matches,
+static int of_platform_bus_create(const struct device_node *bus,
+                                 const struct of_device_id *matches,
                                  struct device *parent)
 {
        struct device_node *child;
@@ -137,7 +137,7 @@ static int of_platform_bus_create(struct device_node *bus,
  */
 
 int of_platform_bus_probe(struct device_node *root,
-                         struct of_device_id *matches,
+                         const struct of_device_id *matches,
                          struct device *parent)
 {
        struct device_node *child;
index d20a4cd08fa1a928fca2e4307552c0e6031c2bb9..1bce5efe1de042f7ab891f8bdf20fc57d56b77fb 100644 (file)
@@ -32,7 +32,7 @@ extern struct of_device *of_platform_device_create(struct device_node *np,
 #define OF_NO_DEEP_PROBE ((struct of_device_id *)-1)
 
 extern int of_platform_bus_probe(struct device_node *root,
-                                struct of_device_id *matches,
+                                const struct of_device_id *matches,
                                 struct device *parent);
 
 extern struct of_device *of_find_device_by_phandle(phandle ph);