diff options
Diffstat (limited to 'drivers/of/platform.c')
-rw-r--r-- | drivers/of/platform.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/drivers/of/platform.c b/drivers/of/platform.c index ea9b8fd9ce..ca9b7d153a 100644 --- a/drivers/of/platform.c +++ b/drivers/of/platform.c @@ -365,11 +365,14 @@ int of_platform_populate(struct device_node *root, } EXPORT_SYMBOL_GPL(of_platform_populate); -static struct device_d *of_device_create_on_demand(struct device_node *np) +struct device_d *of_device_create_on_demand(struct device_node *np) { struct device_node *parent; struct device_d *parent_dev, *dev; + if (!deep_probe_is_supported()) + return NULL; + parent = of_get_parent(np); if (!parent) return NULL; |