Driver core: proper prototype for drivers/base/init.c:driver_init()
authorAdrian Bunk <bunk@stusta.de>
Tue, 19 Dec 2006 21:01:28 +0000 (13:01 -0800)
committerGreg Kroah-Hartman <gregkh@suse.de>
Wed, 20 Dec 2006 18:56:45 +0000 (10:56 -0800)
Add a prototype for driver_init() in include/linux/device.h.

Also remove a static function of the same name in drivers/acpi/ibm_acpi.c to
ibm_acpi_driver_init() to fix the namespace collision.

Signed-off-by: Adrian Bunk <bunk@stusta.de>
Acked-by: Henrique de Moraes Holschuh <hmh@hmh.eng.br>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/acpi/ibm_acpi.c
include/linux/device.h
init/main.c

index 003a9876c9683bee7de662e5959f06ec42ed91f9..5a8445959f673cc6b6811da04fc7e231fb22cb38 100644 (file)
@@ -352,7 +352,7 @@ static char *next_cmd(char **cmds)
        return start;
 }
 
-static int driver_init(void)
+static int ibm_acpi_driver_init(void)
 {
        printk(IBM_INFO "%s v%s\n", IBM_DESC, IBM_VERSION);
        printk(IBM_INFO "%s\n", IBM_URL);
@@ -1605,7 +1605,7 @@ static int fan_write(char *buf)
 static struct ibm_struct ibms[] = {
        {
         .name = "driver",
-        .init = driver_init,
+        .init = ibm_acpi_driver_init,
         .read = driver_read,
         },
        {
index 49ab53ce92dc5d79a55218192de5a9b60d8934a0..f44247fe8135b861b46ac24cacc83a230e874eec 100644 (file)
@@ -433,6 +433,8 @@ static inline int device_is_registered(struct device *dev)
        return dev->is_registered;
 }
 
+void driver_init(void);
+
 /*
  * High level routines for use by the bus drivers
  */
index e3f0bb20b4ddffc0e82181f48ef42e3953df4fdd..2b1cdaab45e654bd1dd9c7d772c48e226e6ec20d 100644 (file)
@@ -53,6 +53,7 @@
 #include <linux/utsrelease.h>
 #include <linux/pid_namespace.h>
 #include <linux/compile.h>
+#include <linux/device.h>
 
 #include <asm/io.h>
 #include <asm/bugs.h>
@@ -94,7 +95,6 @@ extern void pidmap_init(void);
 extern void prio_tree_init(void);
 extern void radix_tree_init(void);
 extern void free_initmem(void);
-extern void driver_init(void);
 extern void prepare_namespace(void);
 #ifdef CONFIG_ACPI
 extern void acpi_early_init(void);