[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20260105-gpio-shared-fixes-v1-1-76d6ff0afcd8@oss.qualcomm.com>
Date: Mon, 05 Jan 2026 16:52:08 +0100
From: Bartosz Golaszewski <bartosz.golaszewski@....qualcomm.com>
To: Linus Walleij <linusw@...nel.org>, Bartosz Golaszewski <brgl@...nel.org>
Cc: linux-gpio@...r.kernel.org, linux-kernel@...r.kernel.org,
Bartosz Golaszewski <bartosz.golaszewski@....qualcomm.com>,
Marek Szyprowski <m.szyprowski@...sung.com>
Subject: [PATCH 1/2] gpio: shared: assign the correct firmware node for
reset-gpio use-case
When we defer probe due to unlucky timing of adding the lookup table, we
assign the matching firmware node to the shared reference for the future
probing. However, the fwnode we assign is wrong so fix it and assign the
one associated with the reset-gpio device.
Fixes: 49416483a953 ("gpio: shared: allow sharing a reset-gpios pin between reset-gpio and gpiolib")
Reported-by: Marek Szyprowski <m.szyprowski@...sung.com>
Closes: https://lore.kernel.org/all/00107523-7737-4b92-a785-14ce4e93b8cb@samsung.com/
Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@....qualcomm.com>
---
drivers/gpio/gpiolib-shared.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpio/gpiolib-shared.c b/drivers/gpio/gpiolib-shared.c
index baf7e07a3bb887dab8155078666a15779e304409..a68af06a6cc4e1e33946d7f200cecd4d3dc066af 100644
--- a/drivers/gpio/gpiolib-shared.c
+++ b/drivers/gpio/gpiolib-shared.c
@@ -417,7 +417,7 @@ static bool gpio_shared_dev_is_reset_gpio(struct device *consumer,
* Reuse the fwnode of the real device, next time we'll use it
* in the normal path.
*/
- ref->fwnode = fwnode_handle_get(real_ref->fwnode);
+ ref->fwnode = fwnode_handle_get(reset_fwnode);
return true;
}
--
2.47.3
Powered by blists - more mailing lists