diff mbox series

[v1,1/1] of: unittest: Switch to use fwnode instead of of_node

Message ID 20220629113839.4604-1-andriy.shevchenko@linux.intel.com
State New
Headers show
Series [v1,1/1] of: unittest: Switch to use fwnode instead of of_node | expand

Commit Message

Andy Shevchenko June 29, 2022, 11:38 a.m. UTC
GPIO library now accepts fwnode as a firmware node, so
switch the module to use it.

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
---
 drivers/of/unittest.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Andy Shevchenko June 29, 2022, 4:05 p.m. UTC | #1
On Wed, Jun 29, 2022 at 02:38:39PM +0300, Andy Shevchenko wrote:
> GPIO library now accepts fwnode as a firmware node, so
> switch the module to use it.

Sorry for a spam, here is v3 of this series, this one shouldn't be considered.
diff mbox series

Patch

diff --git a/drivers/of/unittest.c b/drivers/of/unittest.c
index 7f6bba18c515..03052ffb16e2 100644
--- a/drivers/of/unittest.c
+++ b/drivers/of/unittest.c
@@ -1602,7 +1602,7 @@  static int unittest_gpio_probe(struct platform_device *pdev)
 
 	platform_set_drvdata(pdev, devptr);
 
-	devptr->chip.of_node = pdev->dev.of_node;
+	devptr->chip.fwnode = dev_fwnode(&pdev->dev);
 	devptr->chip.label = "of-unittest-gpio";
 	devptr->chip.base = -1; /* dynamic allocation */
 	devptr->chip.ngpio = 5;