diff options
-rw-r--r-- | drivers/base/platform.c | 2 | ||||
-rw-r--r-- | include/linux/platform_device.h | 1 |
2 files changed, 3 insertions, 0 deletions
diff --git a/drivers/base/platform.c b/drivers/base/platform.c index 0d3611cd1b3b..fc67a325beaa 100644 --- a/drivers/base/platform.c +++ b/drivers/base/platform.c @@ -525,6 +525,8 @@ struct platform_device *platform_device_register_full( pdev->dev.parent = pdevinfo->parent; pdev->dev.fwnode = pdevinfo->fwnode; + pdev->dev.of_node = of_node_get(to_of_node(pdev->dev.fwnode)); + pdev->dev.of_node_reused = pdevinfo->of_node_reused; if (pdevinfo->dma_mask) { /* diff --git a/include/linux/platform_device.h b/include/linux/platform_device.h index c7c081dc6034..466a8d02e298 100644 --- a/include/linux/platform_device.h +++ b/include/linux/platform_device.h @@ -63,6 +63,7 @@ extern int platform_add_devices(struct platform_device **, int); struct platform_device_info { struct device *parent; struct fwnode_handle *fwnode; + bool of_node_reused; const char *name; int id; |