of/device: Make of_device_make_bus_id() usable by other code.
authorGrant Likely <grant.likely@secretlab.ca>
Fri, 23 Jul 2010 21:04:01 +0000 (15:04 -0600)
committerGrant Likely <grant.likely@secretlab.ca>
Fri, 30 Jul 2010 06:03:58 +0000 (00:03 -0600)
The AMBA bus should also use of_device_make_bus_id() when populating device
out of device tree data.  This patch makes the function non-static, and
adds a suitable prototype in of_device.h

Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
drivers/of/platform.c
include/linux/of_device.h

index 033a224a9fdaf8429d6a181776cceb4b43772ae3..30a4641e798a238e9c6d1a3c73808c5530d4469c 100644 (file)
@@ -508,7 +508,7 @@ EXPORT_SYMBOL(of_unregister_driver);
  * value to derive a unique name.  As a last resort it will use the node
  * name followed by a unique number.
  */
-static void of_device_make_bus_id(struct device *dev)
+void of_device_make_bus_id(struct device *dev)
 {
        static atomic_t bus_no_reg_magic;
        struct device_node *node = dev->of_node;
index e11a0be7893afde1fa25eef52086cac6b23cd63d..35aa44ad9f2cb21b7ce2422dfbae2fc296aba7cc 100644 (file)
@@ -27,6 +27,7 @@
 
 extern const struct of_device_id *of_match_device(
        const struct of_device_id *matches, const struct device *dev);
+extern void of_device_make_bus_id(struct device *dev);
 
 /**
  * of_driver_match_device - Tell if a driver's of_match_table matches a device.