]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - arch/sparc/kernel/of_device.c
[SPARC/64]: Prepare to remove of_platform_driver name.
[linux-2.6-omap-h63xx.git] / arch / sparc / kernel / of_device.c
index 36383f73d6855a425a92e60884c20f10e4c9f6be..fb2caef79cec407f0e36497567902c88c88b2418 100644 (file)
@@ -588,7 +588,10 @@ __setup("of_debug=", of_debug);
 int of_register_driver(struct of_platform_driver *drv, struct bus_type *bus)
 {
        /* initialize common driver fields */
-       drv->driver.name = drv->name;
+       if (!drv->driver.name)
+               drv->driver.name = drv->name;
+       if (!drv->driver.owner)
+               drv->driver.owner = drv->owner;
        drv->driver.bus = bus;
 
        /* register with core */