linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v1] drivers: pinctrl: qcom: fix Kconfig dependency on GPIOLIB
@ 2021-02-25  8:33 Julian Braha
  2021-03-02 14:46 ` Linus Walleij
  0 siblings, 1 reply; 5+ messages in thread
From: Julian Braha @ 2021-02-25  8:33 UTC (permalink / raw)
  To: linus.walleij; +Cc: linux-kernel, linux-gpio, linux-arm-msm

When PINCTRL_MSM is enabled, and GPIOLIB is disabled,
Kbuild gives the following warning:

WARNING: unmet direct dependencies detected for GPIOLIB_IRQCHIP
  Depends on [n]: GPIOLIB [=n]
  Selected by [y]:
  - PINCTRL_MSM [=y] && PINCTRL [=y] && (ARCH_QCOM || COMPILE_TEST [=y])

This is because PINCTRL_MSM selects GPIOLIB_IRQCHIP,
without selecting or depending on GPIOLIB, despite
GPIOLIB_IRQCHIP depending on GPIOLIB. Having PINCTRL_MSM
select GPIOLIB will cause a recursive dependency error.

Signed-off-by: Julian Braha <julianbraha@gmail.com>
---
 drivers/pinctrl/qcom/Kconfig | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/pinctrl/qcom/Kconfig b/drivers/pinctrl/qcom/Kconfig
index 6853a896c476..d42ac59875ab 100644
--- a/drivers/pinctrl/qcom/Kconfig
+++ b/drivers/pinctrl/qcom/Kconfig
@@ -3,7 +3,7 @@ if (ARCH_QCOM || COMPILE_TEST)

 config PINCTRL_MSM
 	tristate "Qualcomm core pin controller driver"
-	depends on QCOM_SCM || !QCOM_SCM #if QCOM_SCM=m this can't be =y
+	depends on GPIOLIB && (QCOM_SCM || !QCOM_SCM) #if QCOM_SCM=m this can't be =y
 	select PINMUX
 	select PINCONF
 	select GENERIC_PINCONF
--
2.27.0

^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [PATCH v1] drivers: pinctrl: qcom: fix Kconfig dependency on GPIOLIB
  2021-02-25  8:33 [PATCH v1] drivers: pinctrl: qcom: fix Kconfig dependency on GPIOLIB Julian Braha
@ 2021-03-02 14:46 ` Linus Walleij
  2021-03-29 16:41   ` Julian Braha
  0 siblings, 1 reply; 5+ messages in thread
From: Linus Walleij @ 2021-03-02 14:46 UTC (permalink / raw)
  To: Julian Braha; +Cc: linux-kernel, open list:GPIO SUBSYSTEM, MSM

On Thu, Feb 25, 2021 at 9:33 AM Julian Braha <julianbraha@gmail.com> wrote:

> When PINCTRL_MSM is enabled, and GPIOLIB is disabled,
> Kbuild gives the following warning:
>
> WARNING: unmet direct dependencies detected for GPIOLIB_IRQCHIP
>   Depends on [n]: GPIOLIB [=n]
>   Selected by [y]:
>   - PINCTRL_MSM [=y] && PINCTRL [=y] && (ARCH_QCOM || COMPILE_TEST [=y])
>
> This is because PINCTRL_MSM selects GPIOLIB_IRQCHIP,
> without selecting or depending on GPIOLIB, despite
> GPIOLIB_IRQCHIP depending on GPIOLIB. Having PINCTRL_MSM
> select GPIOLIB will cause a recursive dependency error.
>
> Signed-off-by: Julian Braha <julianbraha@gmail.com>

Does it work to just:

select GPIOLIB

instead?

The driver needs the library so...

Yours,
Linus Walleij

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH v1] drivers: pinctrl: qcom: fix Kconfig dependency on GPIOLIB
  2021-03-02 14:46 ` Linus Walleij
@ 2021-03-29 16:41   ` Julian Braha
  2021-04-08  8:03     ` Linus Walleij
  0 siblings, 1 reply; 5+ messages in thread
From: Julian Braha @ 2021-03-29 16:41 UTC (permalink / raw)
  To: Linus Walleij; +Cc: linux-kernel

On Tuesday, March 2, 2021 9:46:04 AM EDT you wrote:
> On Thu, Feb 25, 2021 at 9:33 AM Julian Braha <julianbraha@gmail.com> wrote:
> 
> > When PINCTRL_MSM is enabled, and GPIOLIB is disabled,
> > Kbuild gives the following warning:
> >
> > WARNING: unmet direct dependencies detected for GPIOLIB_IRQCHIP
> >   Depends on [n]: GPIOLIB [=n]
> >   Selected by [y]:
> >   - PINCTRL_MSM [=y] && PINCTRL [=y] && (ARCH_QCOM || COMPILE_TEST [=y])
> >
> > This is because PINCTRL_MSM selects GPIOLIB_IRQCHIP,
> > without selecting or depending on GPIOLIB, despite
> > GPIOLIB_IRQCHIP depending on GPIOLIB. Having PINCTRL_MSM
> > select GPIOLIB will cause a recursive dependency error.
> >
> > Signed-off-by: Julian Braha <julianbraha@gmail.com>
> 
> Does it work to just:
> 
> select GPIOLIB
> 
> instead?
> 
> The driver needs the library so...
> 
> Yours,
> Linus Walleij
> 

Hi Linus,

Looks like I confused this patch with another one when 
I responded last time. This config option cannot select 
GPIOLIB, because it will cause a recursive dependency 
error.

Any other ideas?

- Julian Braha




^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH v1] drivers: pinctrl: qcom: fix Kconfig dependency on GPIOLIB
  2021-03-29 16:41   ` Julian Braha
@ 2021-04-08  8:03     ` Linus Walleij
  2021-04-14  2:33       ` Bjorn Andersson
  0 siblings, 1 reply; 5+ messages in thread
From: Linus Walleij @ 2021-04-08  8:03 UTC (permalink / raw)
  To: Julian Braha, Bjorn Andersson; +Cc: linux-kernel

On Mon, Mar 29, 2021 at 6:41 PM Julian Braha <julianbraha@gmail.com> wrote:
>
> On Tuesday, March 2, 2021 9:46:04 AM EDT you wrote:
> > On Thu, Feb 25, 2021 at 9:33 AM Julian Braha <julianbraha@gmail.com> wrote:
> >
> > > When PINCTRL_MSM is enabled, and GPIOLIB is disabled,
> > > Kbuild gives the following warning:
> > >
> > > WARNING: unmet direct dependencies detected for GPIOLIB_IRQCHIP
> > >   Depends on [n]: GPIOLIB [=n]
> > >   Selected by [y]:
> > >   - PINCTRL_MSM [=y] && PINCTRL [=y] && (ARCH_QCOM || COMPILE_TEST [=y])
> > >
> > > This is because PINCTRL_MSM selects GPIOLIB_IRQCHIP,
> > > without selecting or depending on GPIOLIB, despite
> > > GPIOLIB_IRQCHIP depending on GPIOLIB. Having PINCTRL_MSM
> > > select GPIOLIB will cause a recursive dependency error.
> > >
> > > Signed-off-by: Julian Braha <julianbraha@gmail.com>
> >
> > Does it work to just:
> >
> > select GPIOLIB
> >
> > instead?
> >
> > The driver needs the library so...
> >
> > Yours,
> > Linus Walleij
> >
>
> Hi Linus,
>
> Looks like I confused this patch with another one when
> I responded last time. This config option cannot select
> GPIOLIB, because it will cause a recursive dependency
> error.
>
> Any other ideas?

No we can apply the patch as-is but let Bjorn have  a look at it first,
I noticed he is not on the To: line of the original patch.

You may need to resend with Bjorn Andersson in the recipients.

Yours,
Linus Walleij

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH v1] drivers: pinctrl: qcom: fix Kconfig dependency on GPIOLIB
  2021-04-08  8:03     ` Linus Walleij
@ 2021-04-14  2:33       ` Bjorn Andersson
  0 siblings, 0 replies; 5+ messages in thread
From: Bjorn Andersson @ 2021-04-14  2:33 UTC (permalink / raw)
  To: Linus Walleij; +Cc: Julian Braha, linux-kernel

On Thu 08 Apr 03:03 CDT 2021, Linus Walleij wrote:

> On Mon, Mar 29, 2021 at 6:41 PM Julian Braha <julianbraha@gmail.com> wrote:
> >
> > On Tuesday, March 2, 2021 9:46:04 AM EDT you wrote:
> > > On Thu, Feb 25, 2021 at 9:33 AM Julian Braha <julianbraha@gmail.com> wrote:
> > >
> > > > When PINCTRL_MSM is enabled, and GPIOLIB is disabled,
> > > > Kbuild gives the following warning:
> > > >
> > > > WARNING: unmet direct dependencies detected for GPIOLIB_IRQCHIP
> > > >   Depends on [n]: GPIOLIB [=n]
> > > >   Selected by [y]:
> > > >   - PINCTRL_MSM [=y] && PINCTRL [=y] && (ARCH_QCOM || COMPILE_TEST [=y])
> > > >
> > > > This is because PINCTRL_MSM selects GPIOLIB_IRQCHIP,
> > > > without selecting or depending on GPIOLIB, despite
> > > > GPIOLIB_IRQCHIP depending on GPIOLIB. Having PINCTRL_MSM
> > > > select GPIOLIB will cause a recursive dependency error.
> > > >
> > > > Signed-off-by: Julian Braha <julianbraha@gmail.com>
> > >
> > > Does it work to just:
> > >
> > > select GPIOLIB
> > >
> > > instead?
> > >
> > > The driver needs the library so...
> > >
> > > Yours,
> > > Linus Walleij
> > >
> >
> > Hi Linus,
> >
> > Looks like I confused this patch with another one when
> > I responded last time. This config option cannot select
> > GPIOLIB, because it will cause a recursive dependency
> > error.
> >
> > Any other ideas?
> 
> No we can apply the patch as-is but let Bjorn have  a look at it first,
> I noticed he is not on the To: line of the original patch.
> 
> You may need to resend with Bjorn Andersson in the recipients.
> 

I don't see a resend of this, perhaps I'm just not good at searching
today...I dug up the patch on lore instead.

GPIOLIB is user selectable, so it makes sense to depend on it, rather
than use select. And it seems like our current defconfigs have GPIOLIB
enabled already (directly or indirectly).

So...

Reviewed-by: Bjorn Andersson <bjorn.andersson@linaro.org>

Regards,
Bjorn

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2021-04-14  2:33 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-02-25  8:33 [PATCH v1] drivers: pinctrl: qcom: fix Kconfig dependency on GPIOLIB Julian Braha
2021-03-02 14:46 ` Linus Walleij
2021-03-29 16:41   ` Julian Braha
2021-04-08  8:03     ` Linus Walleij
2021-04-14  2:33       ` Bjorn Andersson

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).