[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1438089593-7696-3-git-send-email-tomeu.vizoso@collabora.com>
Date: Tue, 28 Jul 2015 15:19:33 +0200
From: Tomeu Vizoso <tomeu.vizoso@...labora.com>
To: linux-kernel@...r.kernel.org
Cc: Stephen Warren <swarren@...dotorg.org>,
Javier Martinez Canillas <javier@....samsung.com>,
Mark Brown <broonie@...nel.org>,
Thierry Reding <thierry.reding@...il.com>,
"Rafael J. Wysocki" <rjw@...ysocki.net>,
linux-arm-kernel@...ts.infradead.org,
Dmitry Torokhov <dmitry.torokhov@...il.com>,
devicetree@...r.kernel.org,
Linus Walleij <linus.walleij@...aro.org>,
linux-acpi@...r.kernel.org, Arnd Bergmann <arnd@...db.de>,
Tomeu Vizoso <tomeu.vizoso@...labora.com>,
Rob Herring <robh+dt@...nel.org>,
Grant Likely <grant.likely@...aro.org>
Subject: [PATCH v2 02/22] of/platform: Set fwnode field for new devices
When allocating a new platform device, set the fwnode field in the
struct device to point to the device_node.
This is needed by platform-independent code that needs to do something
with devices based on the data provided by the firmware.
Signed-off-by: Tomeu Vizoso <tomeu.vizoso@...labora.com>
---
Changes in v2:
- Use set_primary_fwnode()
drivers/of/platform.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/of/platform.c b/drivers/of/platform.c
index ddf8e42c9367..ff27494cda8c 100644
--- a/drivers/of/platform.c
+++ b/drivers/of/platform.c
@@ -139,6 +139,7 @@ struct platform_device *of_device_alloc(struct device_node *np,
}
dev->dev.of_node = of_node_get(np);
+ set_primary_fwnode(&dev->dev, &dev->dev.of_node->fwnode);
dev->dev.parent = parent ? : &platform_bus;
if (bus_id)
--
2.4.3
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists