diff options
Diffstat (limited to 'arch/sparc')
| -rw-r--r-- | arch/sparc/kernel/of_device.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/arch/sparc/kernel/of_device.c b/arch/sparc/kernel/of_device.c index 36383f73d68..fb2caef79ce 100644 --- a/arch/sparc/kernel/of_device.c +++ b/arch/sparc/kernel/of_device.c | |||
| @@ -588,7 +588,10 @@ __setup("of_debug=", of_debug); | |||
| 588 | int of_register_driver(struct of_platform_driver *drv, struct bus_type *bus) | 588 | int of_register_driver(struct of_platform_driver *drv, struct bus_type *bus) |
| 589 | { | 589 | { |
| 590 | /* initialize common driver fields */ | 590 | /* initialize common driver fields */ |
| 591 | drv->driver.name = drv->name; | 591 | if (!drv->driver.name) |
| 592 | drv->driver.name = drv->name; | ||
| 593 | if (!drv->driver.owner) | ||
| 594 | drv->driver.owner = drv->owner; | ||
| 592 | drv->driver.bus = bus; | 595 | drv->driver.bus = bus; |
| 593 | 596 | ||
| 594 | /* register with core */ | 597 | /* register with core */ |
