* [PATCH] usb: gadget: Move USB_GADGET_DUALSPEED to be slightly more visible
@ 2026-03-17 1:24 Tom Rini
2026-03-17 2:34 ` Marek Vasut
2026-03-23 14:32 ` [PATCH v2] " Tom Rini
0 siblings, 2 replies; 16+ messages in thread
From: Tom Rini @ 2026-03-17 1:24 UTC (permalink / raw)
To: u-boot; +Cc: Mattijs Korpershoek, Marek Vasut
As exposed by "make randconfig", we have an issue around
USB_GADGET_DUALSPEED. It is possible to select this symbol (via
SPL_USB_CDNS3_GADGET for example) and so have an unmet dependency. As
this is a hidden symbol, move it up within the menu.
Signed-off-by: Tom Rini <trini@konsulko.com>
---
Cc: Mattijs Korpershoek <mkorpershoek@kernel.org>
Cc: Marek Vasut <marek.vasut+usb@mailbox.org>
---
drivers/usb/gadget/Kconfig | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/drivers/usb/gadget/Kconfig b/drivers/usb/gadget/Kconfig
index baa2eb61ea33..a36be818a68c 100644
--- a/drivers/usb/gadget/Kconfig
+++ b/drivers/usb/gadget/Kconfig
@@ -44,6 +44,10 @@ config SPL_USB_GADGET
Enable USB Gadget API which allows to enable USB device functions
in SPL.
+# Selected by UDC drivers that support high-speed operation.
+config USB_GADGET_DUALSPEED
+ bool
+
if USB_GADGET
config USB_GADGET_MANUFACTURER
@@ -179,10 +183,6 @@ config SDP_LOADADDR
hex "Default load address at SDP_WRITE and SDP_JUMP"
default 0x0
-# Selected by UDC drivers that support high-speed operation.
-config USB_GADGET_DUALSPEED
- bool
-
config USB_GADGET_DOWNLOAD
bool "Enable USB download gadget"
help
--
2.43.0
^ permalink raw reply related [flat|nested] 16+ messages in thread
* Re: [PATCH] usb: gadget: Move USB_GADGET_DUALSPEED to be slightly more visible
2026-03-17 1:24 [PATCH] usb: gadget: Move USB_GADGET_DUALSPEED to be slightly more visible Tom Rini
@ 2026-03-17 2:34 ` Marek Vasut
2026-03-17 13:41 ` Tom Rini
2026-03-23 14:32 ` [PATCH v2] " Tom Rini
1 sibling, 1 reply; 16+ messages in thread
From: Marek Vasut @ 2026-03-17 2:34 UTC (permalink / raw)
To: Tom Rini, u-boot; +Cc: Mattijs Korpershoek, Marek Vasut
On 3/17/26 2:24 AM, Tom Rini wrote:
> As exposed by "make randconfig", we have an issue around
> USB_GADGET_DUALSPEED. It is possible to select this symbol (via
> SPL_USB_CDNS3_GADGET for example) and so have an unmet dependency. As
> this is a hidden symbol, move it up within the menu.
What is the issue this is fixing ?
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PATCH] usb: gadget: Move USB_GADGET_DUALSPEED to be slightly more visible
2026-03-17 2:34 ` Marek Vasut
@ 2026-03-17 13:41 ` Tom Rini
2026-03-17 19:42 ` Marek Vasut
0 siblings, 1 reply; 16+ messages in thread
From: Tom Rini @ 2026-03-17 13:41 UTC (permalink / raw)
To: Marek Vasut; +Cc: u-boot, Mattijs Korpershoek, Marek Vasut
[-- Attachment #1: Type: text/plain, Size: 506 bytes --]
On Tue, Mar 17, 2026 at 03:34:36AM +0100, Marek Vasut wrote:
> On 3/17/26 2:24 AM, Tom Rini wrote:
> > As exposed by "make randconfig", we have an issue around
> > USB_GADGET_DUALSPEED. It is possible to select this symbol (via
> > SPL_USB_CDNS3_GADGET for example) and so have an unmet dependency. As
> > this is a hidden symbol, move it up within the menu.
> What is the issue this is fixing ?
Valid configs causing the kconfig part of the build system to note
unmet dependencies.
--
Tom
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PATCH] usb: gadget: Move USB_GADGET_DUALSPEED to be slightly more visible
2026-03-17 13:41 ` Tom Rini
@ 2026-03-17 19:42 ` Marek Vasut
2026-03-18 1:26 ` Tom Rini
0 siblings, 1 reply; 16+ messages in thread
From: Marek Vasut @ 2026-03-17 19:42 UTC (permalink / raw)
To: Tom Rini; +Cc: u-boot, Mattijs Korpershoek, Marek Vasut
On 3/17/26 2:41 PM, Tom Rini wrote:
> On Tue, Mar 17, 2026 at 03:34:36AM +0100, Marek Vasut wrote:
>> On 3/17/26 2:24 AM, Tom Rini wrote:
>>> As exposed by "make randconfig", we have an issue around
>>> USB_GADGET_DUALSPEED. It is possible to select this symbol (via
>>> SPL_USB_CDNS3_GADGET for example) and so have an unmet dependency. As
>>> this is a hidden symbol, move it up within the menu.
>> What is the issue this is fixing ?
>
> Valid configs causing the kconfig part of the build system to note
> unmet dependencies.
Lemme rephrase, is this actually a fix, or is this some
readability/ordering improvement patch ?
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PATCH] usb: gadget: Move USB_GADGET_DUALSPEED to be slightly more visible
2026-03-17 19:42 ` Marek Vasut
@ 2026-03-18 1:26 ` Tom Rini
2026-03-19 0:50 ` Marek Vasut
0 siblings, 1 reply; 16+ messages in thread
From: Tom Rini @ 2026-03-18 1:26 UTC (permalink / raw)
To: Marek Vasut; +Cc: u-boot, Mattijs Korpershoek, Marek Vasut
[-- Attachment #1: Type: text/plain, Size: 885 bytes --]
On Tue, Mar 17, 2026 at 08:42:06PM +0100, Marek Vasut wrote:
> On 3/17/26 2:41 PM, Tom Rini wrote:
> > On Tue, Mar 17, 2026 at 03:34:36AM +0100, Marek Vasut wrote:
> > > On 3/17/26 2:24 AM, Tom Rini wrote:
> > > > As exposed by "make randconfig", we have an issue around
> > > > USB_GADGET_DUALSPEED. It is possible to select this symbol (via
> > > > SPL_USB_CDNS3_GADGET for example) and so have an unmet dependency. As
> > > > this is a hidden symbol, move it up within the menu.
> > > What is the issue this is fixing ?
> >
> > Valid configs causing the kconfig part of the build system to note
> > unmet dependencies.
> Lemme rephrase, is this actually a fix, or is this some readability/ordering
> improvement patch ?
Yes, it's a fix because randconfig finds problems that users may stumble
on to while trying to make a valid config for a platform.
--
Tom
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PATCH] usb: gadget: Move USB_GADGET_DUALSPEED to be slightly more visible
2026-03-18 1:26 ` Tom Rini
@ 2026-03-19 0:50 ` Marek Vasut
2026-03-19 13:39 ` Tom Rini
0 siblings, 1 reply; 16+ messages in thread
From: Marek Vasut @ 2026-03-19 0:50 UTC (permalink / raw)
To: Tom Rini; +Cc: u-boot, Mattijs Korpershoek, Marek Vasut
On 3/18/26 2:26 AM, Tom Rini wrote:
> On Tue, Mar 17, 2026 at 08:42:06PM +0100, Marek Vasut wrote:
>> On 3/17/26 2:41 PM, Tom Rini wrote:
>>> On Tue, Mar 17, 2026 at 03:34:36AM +0100, Marek Vasut wrote:
>>>> On 3/17/26 2:24 AM, Tom Rini wrote:
>>>>> As exposed by "make randconfig", we have an issue around
>>>>> USB_GADGET_DUALSPEED. It is possible to select this symbol (via
>>>>> SPL_USB_CDNS3_GADGET for example) and so have an unmet dependency. As
>>>>> this is a hidden symbol, move it up within the menu.
>>>> What is the issue this is fixing ?
>>>
>>> Valid configs causing the kconfig part of the build system to note
>>> unmet dependencies.
>> Lemme rephrase, is this actually a fix, or is this some readability/ordering
>> improvement patch ?
>
> Yes, it's a fix because randconfig finds problems that users may stumble
> on to while trying to make a valid config for a platform.
Is the commit message telling me, that "config USB_GADGET_DUALSPEED" is
moved outside of the "if USB_GADGET" block ?
Because if this is something else, and the symbols are simply reordered,
that I do not understand how this could be fixing anything.
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PATCH] usb: gadget: Move USB_GADGET_DUALSPEED to be slightly more visible
2026-03-19 0:50 ` Marek Vasut
@ 2026-03-19 13:39 ` Tom Rini
2026-03-19 17:57 ` Marek Vasut
0 siblings, 1 reply; 16+ messages in thread
From: Tom Rini @ 2026-03-19 13:39 UTC (permalink / raw)
To: Marek Vasut; +Cc: u-boot, Mattijs Korpershoek, Marek Vasut
[-- Attachment #1: Type: text/plain, Size: 2175 bytes --]
On Thu, Mar 19, 2026 at 01:50:56AM +0100, Marek Vasut wrote:
> On 3/18/26 2:26 AM, Tom Rini wrote:
> > On Tue, Mar 17, 2026 at 08:42:06PM +0100, Marek Vasut wrote:
> > > On 3/17/26 2:41 PM, Tom Rini wrote:
> > > > On Tue, Mar 17, 2026 at 03:34:36AM +0100, Marek Vasut wrote:
> > > > > On 3/17/26 2:24 AM, Tom Rini wrote:
> > > > > > As exposed by "make randconfig", we have an issue around
> > > > > > USB_GADGET_DUALSPEED. It is possible to select this symbol (via
> > > > > > SPL_USB_CDNS3_GADGET for example) and so have an unmet dependency. As
> > > > > > this is a hidden symbol, move it up within the menu.
> > > > > What is the issue this is fixing ?
> > > >
> > > > Valid configs causing the kconfig part of the build system to note
> > > > unmet dependencies.
> > > Lemme rephrase, is this actually a fix, or is this some readability/ordering
> > > improvement patch ?
> >
> > Yes, it's a fix because randconfig finds problems that users may stumble
> > on to while trying to make a valid config for a platform.
>
> Is the commit message telling me, that "config USB_GADGET_DUALSPEED" is
> moved outside of the "if USB_GADGET" block ?
>
> Because if this is something else, and the symbols are simply reordered,
> that I do not understand how this could be fixing anything.
I'm unclear what else you need to know to take this bugfix. The symbol
is not placed correctly, leading to possibly unmet dependency errors.
Yes, the error is discovered by randconfig which makes it harder to
describe how exactly to reproduce it (but I believe it does), but that
doesn't make it any less valid.
We'll probably never hit the level of support the kernel has, which is
all randconfigs compile and link (and usually even run), but we should
at least be able to clear out most/all of the Kconfig issues that can be
caught at parse time in a month or two, and maybe even this year have
most CONFIG_SANDBOX=y results build (excluding drivers not fully
configured by Kconfig). And this matters for real users because it means
that downstream developers can probably configure a build rather than
get stuck with odd errors.
--
Tom
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PATCH] usb: gadget: Move USB_GADGET_DUALSPEED to be slightly more visible
2026-03-19 13:39 ` Tom Rini
@ 2026-03-19 17:57 ` Marek Vasut
2026-03-20 13:53 ` Tom Rini
0 siblings, 1 reply; 16+ messages in thread
From: Marek Vasut @ 2026-03-19 17:57 UTC (permalink / raw)
To: Tom Rini; +Cc: u-boot, Mattijs Korpershoek
On 3/19/26 2:39 PM, Tom Rini wrote:
> On Thu, Mar 19, 2026 at 01:50:56AM +0100, Marek Vasut wrote:
>> On 3/18/26 2:26 AM, Tom Rini wrote:
>>> On Tue, Mar 17, 2026 at 08:42:06PM +0100, Marek Vasut wrote:
>>>> On 3/17/26 2:41 PM, Tom Rini wrote:
>>>>> On Tue, Mar 17, 2026 at 03:34:36AM +0100, Marek Vasut wrote:
>>>>>> On 3/17/26 2:24 AM, Tom Rini wrote:
>>>>>>> As exposed by "make randconfig", we have an issue around
>>>>>>> USB_GADGET_DUALSPEED. It is possible to select this symbol (via
>>>>>>> SPL_USB_CDNS3_GADGET for example) and so have an unmet dependency. As
>>>>>>> this is a hidden symbol, move it up within the menu.
>>>>>> What is the issue this is fixing ?
>>>>>
>>>>> Valid configs causing the kconfig part of the build system to note
>>>>> unmet dependencies.
>>>> Lemme rephrase, is this actually a fix, or is this some readability/ordering
>>>> improvement patch ?
>>>
>>> Yes, it's a fix because randconfig finds problems that users may stumble
>>> on to while trying to make a valid config for a platform.
>>
>> Is the commit message telling me, that "config USB_GADGET_DUALSPEED" is
>> moved outside of the "if USB_GADGET" block ?
>>
>> Because if this is something else, and the symbols are simply reordered,
>> that I do not understand how this could be fixing anything.
>
> I'm unclear what else you need to know to take this bugfix. The symbol
> is not placed correctly, leading to possibly unmet dependency errors.
Why do you think the symbol is placed incorrectly ?
What this change does, is it moves "config USB_GADGET_DUALSPEED" outside
of the "if USB_GADGET" block in drivers/usb/gadget/Kconfig , which the
commit message should clearly spell out.
However , I believe that is not the correct fix. The
USB_GADGET_DUALSPEED has to be available only if USB_GADGET or
SPL_USB_GADGET is selected, the former is already satisfied, the later
is not and the SPL_USB_CDNS3_GADGET triggers a problem here. I think
this is the correct fix:
"
diff --git a/drivers/usb/gadget/Kconfig b/drivers/usb/gadget/Kconfig
index ebb306852a6..87d17780c45 100644
--- a/drivers/usb/gadget/Kconfig
+++ b/drivers/usb/gadget/Kconfig
@@ -178,10 +178,6 @@ config SDP_LOADADDR
hex "Default load address at SDP_WRITE and SDP_JUMP"
default 0x0
-# Selected by UDC drivers that support high-speed operation.
-config USB_GADGET_DUALSPEED
- bool
-
config USB_GADGET_DOWNLOAD
bool "Enable USB download gadget"
help
@@ -371,3 +367,11 @@ config SPL_SDP_USB_DEV
so it can be used in compiled environment.
endif # SPL_USB_GADGET
+
+if USB_GADGET || SPL_USB_GADGET
+
+# Selected by UDC drivers that support high-speed operation.
+config USB_GADGET_DUALSPEED
+ bool
+
+endif
"
> Yes, the error is discovered by randconfig which makes it harder to
> describe how exactly to reproduce it (but I believe it does), but that
> doesn't make it any less valid.
This part is not relevant.
^ permalink raw reply related [flat|nested] 16+ messages in thread
* Re: [PATCH] usb: gadget: Move USB_GADGET_DUALSPEED to be slightly more visible
2026-03-19 17:57 ` Marek Vasut
@ 2026-03-20 13:53 ` Tom Rini
2026-03-21 1:53 ` Marek Vasut
0 siblings, 1 reply; 16+ messages in thread
From: Tom Rini @ 2026-03-20 13:53 UTC (permalink / raw)
To: Marek Vasut; +Cc: u-boot, Mattijs Korpershoek
[-- Attachment #1: Type: text/plain, Size: 3748 bytes --]
On Thu, Mar 19, 2026 at 06:57:21PM +0100, Marek Vasut wrote:
> On 3/19/26 2:39 PM, Tom Rini wrote:
> > On Thu, Mar 19, 2026 at 01:50:56AM +0100, Marek Vasut wrote:
> > > On 3/18/26 2:26 AM, Tom Rini wrote:
> > > > On Tue, Mar 17, 2026 at 08:42:06PM +0100, Marek Vasut wrote:
> > > > > On 3/17/26 2:41 PM, Tom Rini wrote:
> > > > > > On Tue, Mar 17, 2026 at 03:34:36AM +0100, Marek Vasut wrote:
> > > > > > > On 3/17/26 2:24 AM, Tom Rini wrote:
> > > > > > > > As exposed by "make randconfig", we have an issue around
> > > > > > > > USB_GADGET_DUALSPEED. It is possible to select this symbol (via
> > > > > > > > SPL_USB_CDNS3_GADGET for example) and so have an unmet dependency. As
> > > > > > > > this is a hidden symbol, move it up within the menu.
> > > > > > > What is the issue this is fixing ?
> > > > > >
> > > > > > Valid configs causing the kconfig part of the build system to note
> > > > > > unmet dependencies.
> > > > > Lemme rephrase, is this actually a fix, or is this some readability/ordering
> > > > > improvement patch ?
> > > >
> > > > Yes, it's a fix because randconfig finds problems that users may stumble
> > > > on to while trying to make a valid config for a platform.
> > >
> > > Is the commit message telling me, that "config USB_GADGET_DUALSPEED" is
> > > moved outside of the "if USB_GADGET" block ?
> > >
> > > Because if this is something else, and the symbols are simply reordered,
> > > that I do not understand how this could be fixing anything.
> >
> > I'm unclear what else you need to know to take this bugfix. The symbol
> > is not placed correctly, leading to possibly unmet dependency errors.
>
> Why do you think the symbol is placed incorrectly ?
Because we wouldn't get a Kconfig unmet dependency error if it was
correctly placed.
> What this change does, is it moves "config USB_GADGET_DUALSPEED" outside of
> the "if USB_GADGET" block in drivers/usb/gadget/Kconfig , which the commit
> message should clearly spell out.
I could reword "As this is a hidden symbol, move it up within the menu."
more, sure.
> However , I believe that is not the correct fix. The USB_GADGET_DUALSPEED
> has to be available only if USB_GADGET or SPL_USB_GADGET is selected, the
> former is already satisfied, the later is not and the SPL_USB_CDNS3_GADGET
> triggers a problem here. I think this is the correct fix:
>
> "
> diff --git a/drivers/usb/gadget/Kconfig b/drivers/usb/gadget/Kconfig
> index ebb306852a6..87d17780c45 100644
> --- a/drivers/usb/gadget/Kconfig
> +++ b/drivers/usb/gadget/Kconfig
> @@ -178,10 +178,6 @@ config SDP_LOADADDR
> hex "Default load address at SDP_WRITE and SDP_JUMP"
> default 0x0
>
> -# Selected by UDC drivers that support high-speed operation.
> -config USB_GADGET_DUALSPEED
> - bool
> -
> config USB_GADGET_DOWNLOAD
> bool "Enable USB download gadget"
> help
> @@ -371,3 +367,11 @@ config SPL_SDP_USB_DEV
> so it can be used in compiled environment.
>
> endif # SPL_USB_GADGET
> +
> +if USB_GADGET || SPL_USB_GADGET
> +
> +# Selected by UDC drivers that support high-speed operation.
> +config USB_GADGET_DUALSPEED
> + bool
> +
> +endif
> "
You don't need to guard hidden symbols. But this also probably also
works, so yes, please post that as a proper patch and I'll go Changes
Requested mine.
> > Yes, the error is discovered by randconfig which makes it harder to
> > describe how exactly to reproduce it (but I believe it does), but that
> > doesn't make it any less valid.
> This part is not relevant.
Well it's been unclear to me what you do and don't see as a valid
problem with this and the other patch.
--
Tom
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PATCH] usb: gadget: Move USB_GADGET_DUALSPEED to be slightly more visible
2026-03-20 13:53 ` Tom Rini
@ 2026-03-21 1:53 ` Marek Vasut
2026-03-21 17:34 ` Tom Rini
0 siblings, 1 reply; 16+ messages in thread
From: Marek Vasut @ 2026-03-21 1:53 UTC (permalink / raw)
To: Tom Rini; +Cc: u-boot, Mattijs Korpershoek
On 3/20/26 2:53 PM, Tom Rini wrote:
[...]
>> @@ -371,3 +367,11 @@ config SPL_SDP_USB_DEV
>> so it can be used in compiled environment.
>>
>> endif # SPL_USB_GADGET
>> +
>> +if USB_GADGET || SPL_USB_GADGET
>> +
>> +# Selected by UDC drivers that support high-speed operation.
>> +config USB_GADGET_DUALSPEED
>> + bool
>> +
>> +endif
>> "
>
> You don't need to guard hidden symbols.
We also do not want to expose this Kconfig symbol unless it makes sense
to expose it ? In fact, if the symbol is not available and someone
attempts to use it in Kconfig, they would get a warning, which should
provide a clue that they are doing something wrong ?
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PATCH] usb: gadget: Move USB_GADGET_DUALSPEED to be slightly more visible
2026-03-21 1:53 ` Marek Vasut
@ 2026-03-21 17:34 ` Tom Rini
2026-03-21 18:50 ` Marek Vasut
0 siblings, 1 reply; 16+ messages in thread
From: Tom Rini @ 2026-03-21 17:34 UTC (permalink / raw)
To: Marek Vasut; +Cc: u-boot, Mattijs Korpershoek
[-- Attachment #1: Type: text/plain, Size: 1096 bytes --]
On Sat, Mar 21, 2026 at 02:53:13AM +0100, Marek Vasut wrote:
> On 3/20/26 2:53 PM, Tom Rini wrote:
>
> [...]
>
> > > @@ -371,3 +367,11 @@ config SPL_SDP_USB_DEV
> > > so it can be used in compiled environment.
> > >
> > > endif # SPL_USB_GADGET
> > > +
> > > +if USB_GADGET || SPL_USB_GADGET
> > > +
> > > +# Selected by UDC drivers that support high-speed operation.
> > > +config USB_GADGET_DUALSPEED
> > > + bool
> > > +
> > > +endif
> > > "
> >
> > You don't need to guard hidden symbols.
>
> We also do not want to expose this Kconfig symbol unless it makes sense to
> expose it ? In fact, if the symbol is not available and someone attempts to
> use it in Kconfig, they would get a warning, which should provide a clue
> that they are doing something wrong ?
It's a hidden symbol, so it's not exposed to the user. The problem is
that today someone is getting it wrong as you suggest but it's hard to
trigger a warning over it. That said, your patch also fixes the problem,
so:
Reviewed-by: Tom Rini <trini@konsulko.com>
--
Tom
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PATCH] usb: gadget: Move USB_GADGET_DUALSPEED to be slightly more visible
2026-03-21 17:34 ` Tom Rini
@ 2026-03-21 18:50 ` Marek Vasut
0 siblings, 0 replies; 16+ messages in thread
From: Marek Vasut @ 2026-03-21 18:50 UTC (permalink / raw)
To: Tom Rini; +Cc: u-boot, Mattijs Korpershoek
On 3/21/26 6:34 PM, Tom Rini wrote:
> On Sat, Mar 21, 2026 at 02:53:13AM +0100, Marek Vasut wrote:
>> On 3/20/26 2:53 PM, Tom Rini wrote:
>>
>> [...]
>>
>>>> @@ -371,3 +367,11 @@ config SPL_SDP_USB_DEV
>>>> so it can be used in compiled environment.
>>>>
>>>> endif # SPL_USB_GADGET
>>>> +
>>>> +if USB_GADGET || SPL_USB_GADGET
>>>> +
>>>> +# Selected by UDC drivers that support high-speed operation.
>>>> +config USB_GADGET_DUALSPEED
>>>> + bool
>>>> +
>>>> +endif
>>>> "
>>>
>>> You don't need to guard hidden symbols.
>>
>> We also do not want to expose this Kconfig symbol unless it makes sense to
>> expose it ? In fact, if the symbol is not available and someone attempts to
>> use it in Kconfig, they would get a warning, which should provide a clue
>> that they are doing something wrong ?
>
> It's a hidden symbol, so it's not exposed to the user. The problem is
> that today someone is getting it wrong as you suggest but it's hard to
> trigger a warning over it. That said, your patch also fixes the problem,
> so:
>
> Reviewed-by: Tom Rini <trini@konsulko.com>
Can you send that as a V2 please ?
Thank you
^ permalink raw reply [flat|nested] 16+ messages in thread
* [PATCH v2] usb: gadget: Move USB_GADGET_DUALSPEED to be slightly more visible
2026-03-17 1:24 [PATCH] usb: gadget: Move USB_GADGET_DUALSPEED to be slightly more visible Tom Rini
2026-03-17 2:34 ` Marek Vasut
@ 2026-03-23 14:32 ` Tom Rini
2026-03-23 15:05 ` Marek Vasut
` (2 more replies)
1 sibling, 3 replies; 16+ messages in thread
From: Tom Rini @ 2026-03-23 14:32 UTC (permalink / raw)
To: u-boot; +Cc: Mattijs Korpershoek, Marek Vasut
As exposed by "make randconfig", we have an issue around
USB_GADGET_DUALSPEED. It is possible to select this symbol (via
SPL_USB_CDNS3_GADGET for example) and so have an unmet dependency due to
how this symbol is placed today. Move this to it's own section of the
file guarded by USB_GADGET || SPL_USB_GADGET.
Signed-off-by: Tom Rini <trini@konsulko.com>
---
Changes in v2:
- Implement this move as suggested by Marek instead
Cc: Mattijs Korpershoek <mkorpershoek@kernel.org>
Cc: Marek Vasut <marek.vasut+usb@mailbox.org>
---
drivers/usb/gadget/Kconfig | 12 ++++++++----
1 file changed, 8 insertions(+), 4 deletions(-)
diff --git a/drivers/usb/gadget/Kconfig b/drivers/usb/gadget/Kconfig
index baa2eb61ea33..2f79840df18c 100644
--- a/drivers/usb/gadget/Kconfig
+++ b/drivers/usb/gadget/Kconfig
@@ -179,10 +179,6 @@ config SDP_LOADADDR
hex "Default load address at SDP_WRITE and SDP_JUMP"
default 0x0
-# Selected by UDC drivers that support high-speed operation.
-config USB_GADGET_DUALSPEED
- bool
-
config USB_GADGET_DOWNLOAD
bool "Enable USB download gadget"
help
@@ -372,3 +368,11 @@ config SPL_SDP_USB_DEV
so it can be used in compiled environment.
endif # SPL_USB_GADGET
+
+if USB_GADGET || SPL_USB_GADGET
+
+# Selected by UDC drivers that support high-speed operation.
+config USB_GADGET_DUALSPEED
+ bool
+
+endif
--
2.43.0
^ permalink raw reply related [flat|nested] 16+ messages in thread
* Re: [PATCH v2] usb: gadget: Move USB_GADGET_DUALSPEED to be slightly more visible
2026-03-23 14:32 ` [PATCH v2] " Tom Rini
@ 2026-03-23 15:05 ` Marek Vasut
2026-03-26 8:57 ` Mattijs Korpershoek
2026-04-08 9:26 ` Mattijs Korpershoek
2 siblings, 0 replies; 16+ messages in thread
From: Marek Vasut @ 2026-03-23 15:05 UTC (permalink / raw)
To: Tom Rini, u-boot; +Cc: Mattijs Korpershoek, Marek Vasut
On 3/23/26 3:32 PM, Tom Rini wrote:
> As exposed by "make randconfig", we have an issue around
> USB_GADGET_DUALSPEED. It is possible to select this symbol (via
> SPL_USB_CDNS3_GADGET for example) and so have an unmet dependency due to
> how this symbol is placed today. Move this to it's own section of the
> file guarded by USB_GADGET || SPL_USB_GADGET.
>
> Signed-off-by: Tom Rini <trini@konsulko.com>
Reviewed-by: Marek Vasut <marek.vasut+usb@mailbox.org>
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PATCH v2] usb: gadget: Move USB_GADGET_DUALSPEED to be slightly more visible
2026-03-23 14:32 ` [PATCH v2] " Tom Rini
2026-03-23 15:05 ` Marek Vasut
@ 2026-03-26 8:57 ` Mattijs Korpershoek
2026-04-08 9:26 ` Mattijs Korpershoek
2 siblings, 0 replies; 16+ messages in thread
From: Mattijs Korpershoek @ 2026-03-26 8:57 UTC (permalink / raw)
To: Tom Rini, u-boot; +Cc: Mattijs Korpershoek, Marek Vasut
Hi Tom,
Thank you for the patch.
On Mon, Mar 23, 2026 at 08:32, Tom Rini <trini@konsulko.com> wrote:
> As exposed by "make randconfig", we have an issue around
> USB_GADGET_DUALSPEED. It is possible to select this symbol (via
> SPL_USB_CDNS3_GADGET for example) and so have an unmet dependency due to
> how this symbol is placed today. Move this to it's own section of the
> file guarded by USB_GADGET || SPL_USB_GADGET.
>
> Signed-off-by: Tom Rini <trini@konsulko.com>
Reviewed-by: Mattijs Korpershoek <mkorpershoek@kernel.org>
> ---
> Changes in v2:
> - Implement this move as suggested by Marek instead
>
> Cc: Mattijs Korpershoek <mkorpershoek@kernel.org>
> Cc: Marek Vasut <marek.vasut+usb@mailbox.org>
> ---
> drivers/usb/gadget/Kconfig | 12 ++++++++----
> 1 file changed, 8 insertions(+), 4 deletions(-)
>
> diff --git a/drivers/usb/gadget/Kconfig b/drivers/usb/gadget/Kconfig
> index baa2eb61ea33..2f79840df18c 100644
> --- a/drivers/usb/gadget/Kconfig
> +++ b/drivers/usb/gadget/Kconfig
> @@ -179,10 +179,6 @@ config SDP_LOADADDR
> hex "Default load address at SDP_WRITE and SDP_JUMP"
> default 0x0
>
> -# Selected by UDC drivers that support high-speed operation.
> -config USB_GADGET_DUALSPEED
> - bool
> -
> config USB_GADGET_DOWNLOAD
> bool "Enable USB download gadget"
> help
> @@ -372,3 +368,11 @@ config SPL_SDP_USB_DEV
> so it can be used in compiled environment.
>
> endif # SPL_USB_GADGET
> +
> +if USB_GADGET || SPL_USB_GADGET
> +
> +# Selected by UDC drivers that support high-speed operation.
> +config USB_GADGET_DUALSPEED
> + bool
> +
> +endif
> --
> 2.43.0
^ permalink raw reply [flat|nested] 16+ messages in thread
* Re: [PATCH v2] usb: gadget: Move USB_GADGET_DUALSPEED to be slightly more visible
2026-03-23 14:32 ` [PATCH v2] " Tom Rini
2026-03-23 15:05 ` Marek Vasut
2026-03-26 8:57 ` Mattijs Korpershoek
@ 2026-04-08 9:26 ` Mattijs Korpershoek
2 siblings, 0 replies; 16+ messages in thread
From: Mattijs Korpershoek @ 2026-04-08 9:26 UTC (permalink / raw)
To: u-boot, Tom Rini; +Cc: Marek Vasut
Hi,
On Mon, 23 Mar 2026 08:32:53 -0600, Tom Rini wrote:
> As exposed by "make randconfig", we have an issue around
> USB_GADGET_DUALSPEED. It is possible to select this symbol (via
> SPL_USB_CDNS3_GADGET for example) and so have an unmet dependency due to
> how this symbol is placed today. Move this to it's own section of the
> file guarded by USB_GADGET || SPL_USB_GADGET.
>
>
> [...]
Thanks, Applied to https://source.denx.de/u-boot/custodians/u-boot-dfu (u-boot-dfu)
[1/1] usb: gadget: Move USB_GADGET_DUALSPEED to be slightly more visible
https://source.denx.de/u-boot/custodians/u-boot-dfu/-/commit/ace0e8034982fedb4ef75b8adcd97c1af063a990
--
Mattijs
^ permalink raw reply [flat|nested] 16+ messages in thread
end of thread, other threads:[~2026-04-08 9:26 UTC | newest]
Thread overview: 16+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-03-17 1:24 [PATCH] usb: gadget: Move USB_GADGET_DUALSPEED to be slightly more visible Tom Rini
2026-03-17 2:34 ` Marek Vasut
2026-03-17 13:41 ` Tom Rini
2026-03-17 19:42 ` Marek Vasut
2026-03-18 1:26 ` Tom Rini
2026-03-19 0:50 ` Marek Vasut
2026-03-19 13:39 ` Tom Rini
2026-03-19 17:57 ` Marek Vasut
2026-03-20 13:53 ` Tom Rini
2026-03-21 1:53 ` Marek Vasut
2026-03-21 17:34 ` Tom Rini
2026-03-21 18:50 ` Marek Vasut
2026-03-23 14:32 ` [PATCH v2] " Tom Rini
2026-03-23 15:05 ` Marek Vasut
2026-03-26 8:57 ` Mattijs Korpershoek
2026-04-08 9:26 ` Mattijs Korpershoek
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox