upgrade to linux 2.6.10-1.12_FC2
[linux-2.6.git] / drivers / acpi / scan.c
index 4e46eed..da2e35c 100644 (file)
@@ -4,6 +4,7 @@
 
 #include <linux/init.h>
 #include <linux/acpi.h>
+#include <linux/module.h>
 
 #include <acpi/acpi_drivers.h>
 #include <acpi/acinterp.h>     /* for acpi_ex_eisa_id_to_string() */
@@ -158,10 +159,10 @@ acpi_bus_get_power_flags (
 
        device->power.state = ACPI_STATE_UNKNOWN;
 
-       return 0;
+       return_VALUE(0);
 }
 
-static int
+int
 acpi_match_ids (
        struct acpi_device      *device,
        char                    *ids)
@@ -280,7 +281,7 @@ acpi_bus_get_wakeup_device_flags (
 end:
        if (ACPI_FAILURE(status))
                device->flags.wake_capable = 0;
-       return 0;
+       return_VALUE(0);
 }
 
 /* --------------------------------------------------------------------------
@@ -314,6 +315,8 @@ acpi_bus_match (
        struct acpi_device      *device,
        struct acpi_driver      *driver)
 {
+       if (driver && driver->ops.match)
+               return driver->ops.match(device, driver);
        return acpi_match_ids(device, driver->ids);
 }
 
@@ -451,6 +454,7 @@ acpi_bus_register_driver (
 
        return_VALUE(count);
 }
+EXPORT_SYMBOL(acpi_bus_register_driver);
 
 
 /**
@@ -479,6 +483,7 @@ acpi_bus_unregister_driver (
                error = -EINVAL;
        return_VALUE(error);
 }
+EXPORT_SYMBOL(acpi_bus_unregister_driver);
 
 /**
  * acpi_bus_find_driver 
@@ -495,9 +500,6 @@ acpi_bus_find_driver (
 
        ACPI_FUNCTION_TRACE("acpi_bus_find_driver");
 
-       if (!device->flags.hardware_id && !device->flags.compatible_ids)
-               goto Done;
-
        spin_lock(&acpi_device_lock);
        list_for_each_safe(node,next,&acpi_bus_drivers) {
                struct acpi_driver * driver = container_of(node,struct acpi_driver,node);
@@ -762,7 +764,7 @@ void acpi_device_get_debug_info(struct acpi_device * device, acpi_handle handle,
 #endif /*CONFIG_ACPI_DEBUG_OUTPUT*/
 }
 
-static int 
+int 
 acpi_bus_add (
        struct acpi_device      **child,
        struct acpi_device      *parent,
@@ -906,7 +908,7 @@ end:
 
        return_VALUE(result);
 }
-
+EXPORT_SYMBOL(acpi_bus_add);
 
 
 static int acpi_bus_scan (struct acpi_device   *start)
@@ -1010,6 +1012,7 @@ static int acpi_bus_scan (struct acpi_device      *start)
 
        return_VALUE(0);
 }
+EXPORT_SYMBOL(acpi_bus_scan);
 
 
 static int