Skip to contentSkip to conversation

bcma: gpio: Switch to use fwnode instead of of_node

PATCH In review Andy Shevchenko 2 participants 2 messages May 4, 2022 – May 9, 2022 Broadcom specific amba driver (bcma)

lore
Share & tools
lore
#0 lore raw

PATCH v2 1/1 bcma: gpio: Switch to use fwnode instead of of_node

GPIO library now accepts fwnode as a firmware node, so switch the driver to use it.

---
v2: fixed typo (LKP)

 drivers/bcma/driver_gpio.c | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)
drivers/bcma/driver_gpio.c +4 -3
index 1e74ec1c7f23..fac8ff983aec 100644
@@ -11,6 +11,8 @@
 #include <linux/gpio/driver.h>
 #include <linux/interrupt.h>
 #include <linux/export.h>
+#include <linux/property.h>
+
 #include <linux/bcma/bcma.h>
 
 #include "bcma_private.h"
@@ -182,9 +184,8 @@ int bcma_gpio_init(struct bcma_drv_cc *cc)
 	chip->direction_input	= bcma_gpio_direction_input;
 	chip->direction_output	= bcma_gpio_direction_output;
 	chip->parent		= bus->dev;
-#if IS_BUILTIN(CONFIG_OF)
-	chip->of_node		= cc->core->dev.of_node;
-#endif
+	chip->fwnode		= dev_fwnode(&cc->core->dev);
+
 	switch (bus->chipinfo.id) {
 	case BCMA_CHIP_ID_BCM4707:
 	case BCMA_CHIP_ID_BCM5357:
Signature · 1 line
2.35.1
#1 lore raw
Quoted 4 lines · Andy Shevchenko

GPIO library now accepts fwnode as a firmware node, so switch the driver to use it.

Patch applied to wireless-next.git, thanks.

f63bc788727c bcma: gpio: Switch to use fwnode instead of of_node

Signature · 3 lines
https://patchwork.kernel.org/project/linux-wireless/patch/[email protected]/

https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches