diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2010-05-19 14:36:03 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2010-05-19 14:36:03 -0400 |
commit | 7c7cbaf5b82c418cd3b1dcf718f71d0e6057e639 (patch) | |
tree | da9aaa5a246af464b1e10d88618c1cad07b76314 /drivers/base | |
parent | ba0234ec35127fe21d373db53cbaf9fe20620cb6 (diff) | |
parent | 4d0956b8f597aac10208ca763f8fe641fde16aab (diff) |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/lethal/sh-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/lethal/sh-2.6: (127 commits)
sh: update defconfigs.
sh: Fix up the NUMA build for recent LMB changes.
sh64: provide a stub per_cpu_trap_init() definition.
sh: fix up CONFIG_KEXEC=n build.
sh: fixup the docbook paths for clock framework shuffling.
driver core: Early dev_name() depends on slab_is_available().
sh: simplify WARN usage in SH clock driver
sh: Check return value of clk_get on ms7724
sh: Check return value of clk_get on ecovec24
sh: move sh clock-cpg.c contents to drivers/sh/clk-cpg.c
sh: move sh clock.c contents to drivers/sh/clk.
sh: move sh asm/clock.h contents to linux/sh_clk.h V2
sh: remove unused clock lookup
sh: switch boards to clkdev
sh: switch sh4-202 to clkdev
sh: switch shx3 to clkdev
sh: switch sh7757 to clkdev
sh: switch sh7763 to clkdev
sh: switch sh7780 to clkdev
sh: switch sh7786 to clkdev
...
Diffstat (limited to 'drivers/base')
-rw-r--r-- | drivers/base/platform.c | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/drivers/base/platform.c b/drivers/base/platform.c index c5fbe198fbd..765bcf0df3b 100644 --- a/drivers/base/platform.c +++ b/drivers/base/platform.c | |||
@@ -1254,6 +1254,26 @@ static int __init early_platform_driver_probe_id(char *class_str, | |||
1254 | } | 1254 | } |
1255 | 1255 | ||
1256 | if (match) { | 1256 | if (match) { |
1257 | /* | ||
1258 | * Set up a sensible init_name to enable | ||
1259 | * dev_name() and others to be used before the | ||
1260 | * rest of the driver core is initialized. | ||
1261 | */ | ||
1262 | if (!match->dev.init_name && slab_is_available()) { | ||
1263 | if (match->id != -1) | ||
1264 | match->dev.init_name = | ||
1265 | kasprintf(GFP_KERNEL, "%s.%d", | ||
1266 | match->name, | ||
1267 | match->id); | ||
1268 | else | ||
1269 | match->dev.init_name = | ||
1270 | kasprintf(GFP_KERNEL, "%s", | ||
1271 | match->name); | ||
1272 | |||
1273 | if (!match->dev.init_name) | ||
1274 | return -ENOMEM; | ||
1275 | } | ||
1276 | |||
1257 | if (epdrv->pdrv->probe(match)) | 1277 | if (epdrv->pdrv->probe(match)) |
1258 | pr_warning("%s: unable to probe %s early.\n", | 1278 | pr_warning("%s: unable to probe %s early.\n", |
1259 | class_str, match->name); | 1279 | class_str, match->name); |