public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
To: Thierry Reding <thierry.reding@gmail.com>
Cc: Bartosz Golaszewski <brgl@bgdev.pl>,
	Dmitry Torokhov <dmitry.torokhov@gmail.com>,
	linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org,
	Linus Walleij <linus.walleij@linaro.org>
Subject: Re: [PATCH v2 1/2] gpiolib: of: Prepare of_gpiochip_add() / of_gpiochip_remove() for fwnode
Date: Thu, 10 Nov 2022 15:53:42 +0200	[thread overview]
Message-ID: <Y20CZtHkaLmQj+IP@smile.fi.intel.com> (raw)
In-Reply-To: <Y2z7IJv2IQy+Mlsh@orome>

On Thu, Nov 10, 2022 at 02:22:40PM +0100, Thierry Reding wrote:
> On Tue, Nov 08, 2022 at 03:38:52PM +0200, Andy Shevchenko wrote:

...

> > +	np = to_of_node(chip->fwnode);
> 
> This breaks a number of GPIO controllers on Tegra where chip->fwnode
> ends up never getting set. I also see this break drivers like the MFD-
> based gpio-max77620, so I don't think this is anything specific to the
> Tegra drivers.
> 
> Looking at how fwnode handling works, it seems like we're checking the
> wrong value here, since chip->fwnode is only for explicit overrides of
> the fwnode value.
> 
> The below patch fixes the regression for me:

Thank you! Can you submit it as a formal fix? (Also see below)
Of if Bart prefers I can respin fixed verison. Bart?

...

> -       np = to_of_node(chip->fwnode);
> +       np = to_of_node(chip->gpiodev->dev.fwnode);

dev_fwnode(&chip->gpiodev->dev)

...


Your report makes me wonder if I can Cc you the patch that changes that logic,
so you can help with a testing on OF platforms.

-- 
With Best Regards,
Andy Shevchenko



  reply	other threads:[~2022-11-10 13:53 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-11-08 13:38 [PATCH v2 1/2] gpiolib: of: Prepare of_gpiochip_add() / of_gpiochip_remove() for fwnode Andy Shevchenko
2022-11-08 13:38 ` [PATCH v2 2/2] gpiolib: of: Integrate of_gpiochip_init_valid_mask() into gpiochip_init_valid_mask() Andy Shevchenko
2022-11-09  8:59   ` Linus Walleij
2022-11-09  8:59 ` [PATCH v2 1/2] gpiolib: of: Prepare of_gpiochip_add() / of_gpiochip_remove() for fwnode Linus Walleij
2022-11-10 13:22 ` Thierry Reding
2022-11-10 13:53   ` Andy Shevchenko [this message]
2022-11-10 15:07     ` Marek Szyprowski
2022-11-10 15:29     ` 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=Y20CZtHkaLmQj+IP@smile.fi.intel.com \
    --to=andriy.shevchenko@linux.intel.com \
    --cc=brgl@bgdev.pl \
    --cc=dmitry.torokhov@gmail.com \
    --cc=linus.walleij@linaro.org \
    --cc=linux-gpio@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=thierry.reding@gmail.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