All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Heiko Stübner" <heiko@sntech.de>
To: Linus Walleij <linus.walleij@linaro.org>
Cc: Bartosz Golaszewski <bgolaszewski@baylibre.com>,
	Jianqun Xu <jay.xu@rock-chips.com>,
	"open list:GPIO SUBSYSTEM" <linux-gpio@vger.kernel.org>,
	Linux ARM <linux-arm-kernel@lists.infradead.org>,
	"open list:ARM/Rockchip SoC..."
	<linux-rockchip@lists.infradead.org>,
	linux-kernel <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH 4/4] gpio/rockchip: fetch deferred output settings on probe
Date: Sat, 18 Sep 2021 02:00:27 +0200	[thread overview]
Message-ID: <1992229.jx4eJSTThl@diego> (raw)
In-Reply-To: <CACRpkda2Hc6E27LK=vH_qKkTayG3qP=BGdqBKyLR2dMhekyWTw@mail.gmail.com>

Hi Linus,

Am Samstag, 18. September 2021, 01:38:08 CEST schrieb Linus Walleij:
> On Tue, Sep 14, 2021 at 12:49 AM Heiko Stuebner <heiko@sntech.de> wrote:
> 
> > Fetch the output settings the pinctrl driver may have created
> > for pinctrl hogs and set the relevant pins as requested.
> >
> > Fixes: 9ce9a02039de ("pinctrl/rockchip: drop the gpio related codes")
> > Signed-off-by: Heiko Stuebner <heiko@sntech.de>
> 
> Since this patch depends on patch 4/4 I applied this to the pinctrl
> tree as well.
> 
> I still think this looks a bit kludgy but can't think of anything better
> right now and we need a fix for the problem so this goes in.
> 
> But we need to think of something better,

I'm all ears :-) . And yes I do agree with you that this is not very
elegant right now.

The issue is that the pinconf part for PIN_CONFIG_OUTPUT is actually
using the gpio controller to realize this setting. So when this ends up
in a pinctrl-hog, stuff explodes while probing the first pinctrl part.

I guess one way would be to somehow only do the pinctrl-hogs
_after_ all parts have probed.


Thinking about this, the component framework may be one option?
And then adding a pinctr-register / init+enable variant where the
pinctrl hogs can be aquired separately, not as part of pinctrl_enable?

Or maybe I'm thinking way too complex and a way easier solution
is around the corner ;-) .


Heiko



WARNING: multiple messages have this Message-ID (diff)
From: "Heiko Stübner" <heiko@sntech.de>
To: Linus Walleij <linus.walleij@linaro.org>
Cc: Bartosz Golaszewski <bgolaszewski@baylibre.com>,
	Jianqun Xu <jay.xu@rock-chips.com>,
	"open list:GPIO SUBSYSTEM" <linux-gpio@vger.kernel.org>,
	Linux ARM <linux-arm-kernel@lists.infradead.org>,
	"open list:ARM/Rockchip SoC..."
	<linux-rockchip@lists.infradead.org>,
	linux-kernel <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH 4/4] gpio/rockchip: fetch deferred output settings on probe
Date: Sat, 18 Sep 2021 02:00:27 +0200	[thread overview]
Message-ID: <1992229.jx4eJSTThl@diego> (raw)
In-Reply-To: <CACRpkda2Hc6E27LK=vH_qKkTayG3qP=BGdqBKyLR2dMhekyWTw@mail.gmail.com>

Hi Linus,

Am Samstag, 18. September 2021, 01:38:08 CEST schrieb Linus Walleij:
> On Tue, Sep 14, 2021 at 12:49 AM Heiko Stuebner <heiko@sntech.de> wrote:
> 
> > Fetch the output settings the pinctrl driver may have created
> > for pinctrl hogs and set the relevant pins as requested.
> >
> > Fixes: 9ce9a02039de ("pinctrl/rockchip: drop the gpio related codes")
> > Signed-off-by: Heiko Stuebner <heiko@sntech.de>
> 
> Since this patch depends on patch 4/4 I applied this to the pinctrl
> tree as well.
> 
> I still think this looks a bit kludgy but can't think of anything better
> right now and we need a fix for the problem so this goes in.
> 
> But we need to think of something better,

I'm all ears :-) . And yes I do agree with you that this is not very
elegant right now.

The issue is that the pinconf part for PIN_CONFIG_OUTPUT is actually
using the gpio controller to realize this setting. So when this ends up
in a pinctrl-hog, stuff explodes while probing the first pinctrl part.

I guess one way would be to somehow only do the pinctrl-hogs
_after_ all parts have probed.


Thinking about this, the component framework may be one option?
And then adding a pinctr-register / init+enable variant where the
pinctrl hogs can be aquired separately, not as part of pinctrl_enable?

Or maybe I'm thinking way too complex and a way easier solution
is around the corner ;-) .


Heiko



_______________________________________________
Linux-rockchip mailing list
Linux-rockchip@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-rockchip

WARNING: multiple messages have this Message-ID (diff)
From: "Heiko Stübner" <heiko@sntech.de>
To: Linus Walleij <linus.walleij@linaro.org>
Cc: Bartosz Golaszewski <bgolaszewski@baylibre.com>,
	Jianqun Xu <jay.xu@rock-chips.com>,
	"open list:GPIO SUBSYSTEM" <linux-gpio@vger.kernel.org>,
	Linux ARM <linux-arm-kernel@lists.infradead.org>,
	"open list:ARM/Rockchip SoC..."
	<linux-rockchip@lists.infradead.org>,
	linux-kernel <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH 4/4] gpio/rockchip: fetch deferred output settings on probe
Date: Sat, 18 Sep 2021 02:00:27 +0200	[thread overview]
Message-ID: <1992229.jx4eJSTThl@diego> (raw)
In-Reply-To: <CACRpkda2Hc6E27LK=vH_qKkTayG3qP=BGdqBKyLR2dMhekyWTw@mail.gmail.com>

Hi Linus,

Am Samstag, 18. September 2021, 01:38:08 CEST schrieb Linus Walleij:
> On Tue, Sep 14, 2021 at 12:49 AM Heiko Stuebner <heiko@sntech.de> wrote:
> 
> > Fetch the output settings the pinctrl driver may have created
> > for pinctrl hogs and set the relevant pins as requested.
> >
> > Fixes: 9ce9a02039de ("pinctrl/rockchip: drop the gpio related codes")
> > Signed-off-by: Heiko Stuebner <heiko@sntech.de>
> 
> Since this patch depends on patch 4/4 I applied this to the pinctrl
> tree as well.
> 
> I still think this looks a bit kludgy but can't think of anything better
> right now and we need a fix for the problem so this goes in.
> 
> But we need to think of something better,

I'm all ears :-) . And yes I do agree with you that this is not very
elegant right now.

The issue is that the pinconf part for PIN_CONFIG_OUTPUT is actually
using the gpio controller to realize this setting. So when this ends up
in a pinctrl-hog, stuff explodes while probing the first pinctrl part.

I guess one way would be to somehow only do the pinctrl-hogs
_after_ all parts have probed.


Thinking about this, the component framework may be one option?
And then adding a pinctr-register / init+enable variant where the
pinctrl hogs can be aquired separately, not as part of pinctrl_enable?

Or maybe I'm thinking way too complex and a way easier solution
is around the corner ;-) .


Heiko



_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

  reply	other threads:[~2021-09-18  0:00 UTC|newest]

Thread overview: 39+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-09-13 22:49 [PATCH 0/4] gpio/pinctrl-rockchip: Fixes for the recently separated gpio/pinctrl driver Heiko Stuebner
2021-09-13 22:49 ` Heiko Stuebner
2021-09-13 22:49 ` Heiko Stuebner
2021-09-13 22:49 ` [PATCH 1/4] gpio/rockchip: extended debounce support is only available on v2 Heiko Stuebner
2021-09-13 22:49   ` Heiko Stuebner
2021-09-13 22:49   ` Heiko Stuebner
2021-09-17 22:34   ` Linus Walleij
2021-09-17 22:34     ` Linus Walleij
2021-09-17 22:34     ` Linus Walleij
2021-09-22  9:45   ` Bartosz Golaszewski
2021-09-22  9:45     ` Bartosz Golaszewski
2021-09-22  9:45     ` Bartosz Golaszewski
2021-09-13 22:49 ` [PATCH 2/4] gpio/rockchip: fix get_direction value handling Heiko Stuebner
2021-09-13 22:49   ` Heiko Stuebner
2021-09-13 22:49   ` Heiko Stuebner
2021-09-17 23:30   ` Linus Walleij
2021-09-17 23:30     ` Linus Walleij
2021-09-17 23:30     ` Linus Walleij
2021-09-22  9:46   ` Bartosz Golaszewski
2021-09-22  9:46     ` Bartosz Golaszewski
2021-09-22  9:46     ` Bartosz Golaszewski
2021-09-13 22:49 ` [PATCH 3/4] pinctrl/rockchip: add a queue for deferred pin output settings on probe Heiko Stuebner
2021-09-13 22:49   ` Heiko Stuebner
2021-09-13 22:49   ` Heiko Stuebner
2021-09-17 23:35   ` Linus Walleij
2021-09-17 23:35     ` Linus Walleij
2021-09-17 23:35     ` Linus Walleij
2021-09-13 22:49 ` [PATCH 4/4] gpio/rockchip: fetch deferred " Heiko Stuebner
2021-09-13 22:49   ` Heiko Stuebner
2021-09-13 22:49   ` Heiko Stuebner
2021-09-17 23:38   ` Linus Walleij
2021-09-17 23:38     ` Linus Walleij
2021-09-17 23:38     ` Linus Walleij
2021-09-18  0:00     ` Heiko Stübner [this message]
2021-09-18  0:00       ` Heiko Stübner
2021-09-18  0:00       ` Heiko Stübner
2021-09-19 14:47       ` Linus Walleij
2021-09-19 14:47         ` Linus Walleij
2021-09-19 14:47         ` Linus Walleij

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=1992229.jx4eJSTThl@diego \
    --to=heiko@sntech.de \
    --cc=bgolaszewski@baylibre.com \
    --cc=jay.xu@rock-chips.com \
    --cc=linus.walleij@linaro.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-gpio@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-rockchip@lists.infradead.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.