mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Bartosz Golaszewski <bartosz.golaszewski@oss.qualcomm.com>
To: "Santosh Kumar Yadav" <santoshkumar.yadav@barco.com>,
	"Peter Korsgaard" <peter.korsgaard@barco.com>,
	"Hans de Goede" <hansg@kernel.org>,
	"Ilpo Järvinen" <ilpo.jarvinen@linux.intel.com>,
	"Dmitry Torokhov" <dmitry.torokhov@gmail.com>
Cc: platform-driver-x86@vger.kernel.org,
	linux-kernel@vger.kernel.org, brgl@kernel.org,
	Bartosz Golaszewski <bartosz.golaszewski@oss.qualcomm.com>
Subject: [PATCH] platform/x86: barco-p50-gpio: attach software node to its target GPIO device
Date: Tue, 31 Mar 2026 13:28:19 +0200	[thread overview]
Message-ID: <20260331112819.103298-1-bartosz.golaszewski@oss.qualcomm.com> (raw)

The software node representing the GPIO controller to consumers is
"dangling": it's not really attached to the device. The GPIO lookup
relies on matching the name of the node to the chip's label. Set it as
the secondary firmware node of the platform device to enable proper
fwnode-based GPIO lookup.

Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@oss.qualcomm.com>
---
 drivers/platform/x86/barco-p50-gpio.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/platform/x86/barco-p50-gpio.c b/drivers/platform/x86/barco-p50-gpio.c
index 2a6d8607c402..5f4ffa584295 100644
--- a/drivers/platform/x86/barco-p50-gpio.c
+++ b/drivers/platform/x86/barco-p50-gpio.c
@@ -365,6 +365,8 @@ static int p50_gpio_probe(struct platform_device *pdev)
 	if (ret)
 		return dev_err_probe(&pdev->dev, ret, "failed to register software nodes");
 
+	set_secondary_fwnode(&pdev->dev, software_node_fwnode(&gpiochip_node));
+
 	led_info.fwnode = software_node_fwnode(&gpio_leds_node);
 	p50->leds_pdev = platform_device_register_full(&led_info);
 	if (IS_ERR(p50->leds_pdev)) {
-- 
2.47.3


             reply	other threads:[~2026-03-31 11:28 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-03-31 11:28 Bartosz Golaszewski [this message]
2026-04-01  2:09 ` Dmitry Torokhov
2026-04-02  8:29   ` Bartosz Golaszewski
2026-04-02 15:53     ` Dmitry Torokhov
2026-04-02 16:39       ` Bartosz Golaszewski
2026-04-02 17:30         ` Dmitry Torokhov
2026-04-03  7:30           ` Bartosz Golaszewski

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20260331112819.103298-1-bartosz.golaszewski@oss.qualcomm.com \
    --to=bartosz.golaszewski@oss.qualcomm.com \
    --cc=brgl@kernel.org \
    --cc=dmitry.torokhov@gmail.com \
    --cc=hansg@kernel.org \
    --cc=ilpo.jarvinen@linux.intel.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=peter.korsgaard@barco.com \
    --cc=platform-driver-x86@vger.kernel.org \
    --cc=santoshkumar.yadav@barco.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®