Skip to contentSkip to conversation

gpio: gpiolib-swnode: Remove deprecated label fallback for GPIO device lookup

PATCH In review Pranav Kharche 2 participants 2 messages Feb 25 GPIO

lore
Share & tools
lore
#0 lore raw

PATCH v2 1/1 gpio: gpiolib-swnode: Remove deprecated label fallback for GPIO device lookup

---
 drivers/gpio/gpiolib-swnode.c | 18 +-----------------
 1 file changed, 1 insertion(+), 17 deletions(-)
drivers/gpio/gpiolib-swnode.c +1 -17
index 0d7f3f09a0b4..d6ab5bf0d2f1 100644
@@ -43,23 +43,7 @@ static struct gpio_device *swnode_get_gpio_device(struct fwnode_handle *fwnode)
 fwnode_lookup:
 	gdev = gpio_device_find_by_fwnode(fwnode);
 	if (!gdev && gdev_node && gdev_node->name)
-		/*
-		 * FIXME: We shouldn't need to compare the GPIO controller's
-		 * label against the software node that is supposedly attached
-		 * to it. However there are currently GPIO users that - knowing
-		 * the expected label of the GPIO chip whose pins they want to
-		 * control - set up dummy software nodes named after those GPIO
-		 * controllers, which aren't actually attached to them. In this
-		 * case gpio_device_find_by_fwnode() will fail as no device on
-		 * the GPIO bus is actually associated with the fwnode we're
-		 * looking for.
-		 *
-		 * As a fallback: continue checking the label if we have no
-		 * match. However, the situation described above is an abuse
-		 * of the software node API and should be phased out and the
-		 * following line - eventually removed.
-		 */
-		gdev = gpio_device_find_by_label(gdev_node->name);
+		
 
 	return gdev ?: ERR_PTR(-EPROBE_DEFER);
 }
Signature · 1 line
2.34.1
#1 lore raw
Quoted 36 lines · Pranav Kharche
---
 drivers/gpio/gpiolib-swnode.c | 18 +-----------------
 1 file changed, 1 insertion(+), 17 deletions(-)
drivers/gpio/gpiolib-swnode.c +1 -18
index 0d7f3f09a0b4..d6ab5bf0d2f1 100644
@@ -43,23 +43,7 @@ static struct gpio_device *swnode_get_gpio_device(struct fwnode_handle *fwnode)
 fwnode_lookup:
        gdev = gpio_device_find_by_fwnode(fwnode);
        if (!gdev && gdev_node && gdev_node->name)
-               /*
-                * FIXME: We shouldn't need to compare the GPIO controller's
-                * label against the software node that is supposedly attached
-                * to it. However there are currently GPIO users that - knowing
-                * the expected label of the GPIO chip whose pins they want to
-                * control - set up dummy software nodes named after those GPIO
-                * controllers, which aren't actually attached to them. In this
-                * case gpio_device_find_by_fwnode() will fail as no device on
-                * the GPIO bus is actually associated with the fwnode we're
-                * looking for.
-                *
-                * As a fallback: continue checking the label if we have no
-                * match. However, the situation described above is an abuse
-                * of the software node API and should be phased out and the
-                * following line - eventually removed.
-                */
-               gdev = gpio_device_find_by_label(gdev_node->name);
+
 
        return gdev ?: ERR_PTR(-EPROBE_DEFER);
 }
--
Quoted 2 lines

2.34.1

Sigh... Are you an AI model?