* [PATCH] usb: musb: fix dead select of USB_MUSB_DUAL_ROLE
@ 2026-07-11 13:03 Julian Braha
2026-07-11 14:39 ` Arnd Bergmann
0 siblings, 1 reply; 3+ messages in thread
From: Julian Braha @ 2026-07-11 13:03 UTC (permalink / raw)
To: b-liu, gregkh; +Cc: arnd, linux-usb, linux-kernel, Julian Braha
'select' does not work on config options in a 'choice', so currently it is
possible to enable USB_MUSB_POLARFIRE_SOC without USB_MUSB_DUAL_ROLE.
Replace 'select' with 'depends on'.
This dead select was found by kconfirm, a static analysis tool for Kconfig.
Signed-off-by: Julian Braha <julianbraha@gmail.com>
---
drivers/usb/musb/Kconfig | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/usb/musb/Kconfig b/drivers/usb/musb/Kconfig
index f56929267eaa..f8ff2366f59f 100644
--- a/drivers/usb/musb/Kconfig
+++ b/drivers/usb/musb/Kconfig
@@ -116,7 +116,7 @@ config USB_MUSB_POLARFIRE_SOC
tristate "Microchip PolarFire SoC platforms"
depends on ARCH_MICROCHIP_POLARFIRE || COMPILE_TEST
depends on NOP_USB_XCEIV
- select USB_MUSB_DUAL_ROLE
+ depends on USB_MUSB_DUAL_ROLE
help
Say Y here to enable support for USB on Microchip's PolarFire SoC.
--
2.54.0
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] usb: musb: fix dead select of USB_MUSB_DUAL_ROLE
2026-07-11 13:03 [PATCH] usb: musb: fix dead select of USB_MUSB_DUAL_ROLE Julian Braha
@ 2026-07-11 14:39 ` Arnd Bergmann
2026-07-11 15:09 ` Julian Braha
0 siblings, 1 reply; 3+ messages in thread
From: Arnd Bergmann @ 2026-07-11 14:39 UTC (permalink / raw)
To: Julian Braha, Bin Liu, Greg Kroah-Hartman; +Cc: linux-usb, linux-kernel
On Sat, Jul 11, 2026, at 15:03, Julian Braha wrote:
> 'select' does not work on config options in a 'choice', so currently it is
> possible to enable USB_MUSB_POLARFIRE_SOC without USB_MUSB_DUAL_ROLE.
>
> Replace 'select' with 'depends on'.
>
> This dead select was found by kconfirm, a static analysis tool for Kconfig.
>
> Signed-off-by: Julian Braha <julianbraha@gmail.com>
Good catch, but I wonder if this is actually a real dependency
at all. What would happen if you just remove the 'select' line
here and build a polarfire kernel that only supports
host or gadget mode but not dual-role?
Arnd
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] usb: musb: fix dead select of USB_MUSB_DUAL_ROLE
2026-07-11 14:39 ` Arnd Bergmann
@ 2026-07-11 15:09 ` Julian Braha
0 siblings, 0 replies; 3+ messages in thread
From: Julian Braha @ 2026-07-11 15:09 UTC (permalink / raw)
To: Arnd Bergmann, Bin Liu, Greg Kroah-Hartman
Cc: linux-usb, linux-kernel, conor.dooley, daire.mcnamara,
valentina.fernandezalanis, Michael Turquette, Stephen Boyd,
claudiu.beznea, Jassi Brar, a.zummo, Alexandre Belloni, wsa,
ben.dooks, heinrich.schuchardt
Hi Arnd,
On 7/11/26 15:39, Arnd Bergmann wrote:
> Good catch, but I wonder if this is actually a real dependency
> at all. What would happen if you just remove the 'select' line
> here and build a polarfire kernel that only supports
> host or gadget mode but not dual-role?
The kernel builds just fine for me with USB_MUSB_POLARFIRE_SOC=y and
USB_MUSB_DUAL_ROLE=n
But I don't have this hardware so I don't know what would happen at
runtime.
I've CC'd more people involved in patches to this config option.
- Julian Braha
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2026-07-11 15:10 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-07-11 13:03 [PATCH] usb: musb: fix dead select of USB_MUSB_DUAL_ROLE Julian Braha
2026-07-11 14:39 ` Arnd Bergmann
2026-07-11 15:09 ` Julian Braha
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox