[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CACRpkdZ8JYoY4nJe8n8zDaY2Lcu3BRPRpzxkv=v4FC7T2zYdiA@mail.gmail.com>
Date: Wed, 17 Jan 2018 14:27:56 +0100
From: Linus Walleij <linus.walleij@...aro.org>
To: Peter Rosin <peda@...ntia.se>
Cc: Andrew Jeffery <andrew@...id.au>,
Charles Keepax <ckeepax@...nsource.cirrus.com>,
"linux-gpio@...r.kernel.org" <linux-gpio@...r.kernel.org>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: Re: [REGRESSION] mux/gpio.c is not able to get any gpio pins
On Wed, Jan 17, 2018 at 11:39 AM, Peter Rosin <peda@...ntia.se> wrote:
> On 2018-01-17 10:35, Linus Walleij wrote:
>> I would first try to add the gpio range in the DTS. Then the
>> GPIO core will add the range (the code is in drivers/gpio/gpiolib-of.c)
>> and everything will be happy.
>
> If I, in the above mentioned node, add
>
> gpio-ranges = <&ioexp 0 0 8>;
>
> it works.
OK good.
>> Another solution would be to do what Intel does and add a
>> static GPIO range. Since the SX150x doesn't seem very
>> configurable wrt pins-to-gpios mappings, this should be fine.
>
> Adding the below on top of the previous pinctrl/gpiochip reshuffle
> also works (with the dt change reverted, of course).
I think we should probably just do this.
> please state where you want that pinctrl_enable
> call; together with devm_pinctrl_register_and_init (or perhaps
> just use plain old deprecated devm_pinctrl_register), or at the
> end of the probe, after the gpio init block?
Definately before the gpio init, since GPIO is making use
of pin control.
I would put it immediatelt after devm_pinctrl_register_and_init()
unless you need something specific to happen inbetween.
Yours,
Linus Walleij
Powered by blists - more mailing lists