diff options
author | Olaf Hering <olaf@aepfle.de> | 2008-04-24 23:16:00 +1000 |
---|---|---|
committer | Paul Mackerras <paulus@samba.org> | 2008-05-14 22:31:28 +1000 |
commit | 140b932f8cb6cced10b96860651a198b1b89cbb9 (patch) | |
tree | b515aa9982f7eaffd43b994497bff925b2a8b96b /drivers/of/platform.c | |
parent | 9d5f525b86453da921360727112161254accc8c1 (diff) |
[POWERPC] Create modalias file in sysfs for of_platform bus
Create /sys/bus/of_platform/devices/*/modalias file to allow autoloading
of modules. Modalias files are already present for many other bus types.
This adds also a newline to the devspec files.
Also create a devspec file for mac-io devices. They were created as a
side effect. Use correct buffer size for mac-io modalias buffer.
Tested on iBook1 and Efika.
Signed-off-by: Olaf Hering <olaf@aepfle.de>
Signed-off-by: Paul Mackerras <paulus@samba.org>
Diffstat (limited to 'drivers/of/platform.c')
-rw-r--r-- | drivers/of/platform.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/of/platform.c b/drivers/of/platform.c index ca09a63a64db..298de0f95d70 100644 --- a/drivers/of/platform.c +++ b/drivers/of/platform.c @@ -17,6 +17,8 @@ #include <linux/of_device.h> #include <linux/of_platform.h> +extern struct device_attribute of_platform_device_attrs[]; + static int of_platform_bus_match(struct device *dev, struct device_driver *drv) { struct of_device *of_dev = to_of_device(dev); @@ -103,6 +105,7 @@ int of_bus_type_init(struct bus_type *bus, const char *name) bus->suspend = of_platform_device_suspend; bus->resume = of_platform_device_resume; bus->shutdown = of_platform_device_shutdown; + bus->dev_attrs = of_platform_device_attrs; return bus_register(bus); } |