[PATCH] staging: greybus: arche: drop dangling Kconfig symbol

Randy Dunlap posted 1 patch 1 month, 1 week ago
drivers/staging/greybus/Kconfig          |    1 -
drivers/staging/greybus/arche-platform.c |    4 ----
2 files changed, 5 deletions(-)
[PATCH] staging: greybus: arche: drop dangling Kconfig symbol
Posted by Randy Dunlap 1 month, 1 week ago
The Kconfig symbol USB_HSIC_USB3613 is not defined in the kernel source
tree. Drop it since it unused.

Fixes: 2eccd4aa19fc ("staging: greybus: enable compile testing of arche driver")
Signed-off-by: Randy Dunlap <rdunlap@infradead.org>
---
Cc: Vaibhav Hiremath <hvaibhav.linux@gmail.com>
Cc: Johan Hovold <johan@kernel.org>
Cc: Alex Elder <elder@kernel.org>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: greybus-dev@lists.linaro.org
Cc: linux-staging@lists.linux.dev

 drivers/staging/greybus/Kconfig          |    1 -
 drivers/staging/greybus/arche-platform.c |    4 ----
 2 files changed, 5 deletions(-)

--- linux-next-20251219.orig/drivers/staging/greybus/arche-platform.c
+++ linux-next-20251219/drivers/staging/greybus/arche-platform.c
@@ -23,14 +23,10 @@
 #include <linux/of.h>
 #include "arche_platform.h"
 
-#if IS_ENABLED(CONFIG_USB_HSIC_USB3613)
-#include <linux/usb/usb3613.h>
-#else
 static inline int usb3613_hub_mode_ctrl(bool unused)
 {
 	return 0;
 }
-#endif
 
 #define WD_COLDBOOT_PULSE_WIDTH_MS	30
 
--- linux-next-20251219.orig/drivers/staging/greybus/Kconfig
+++ linux-next-20251219/drivers/staging/greybus/Kconfig
@@ -206,7 +206,6 @@ endif	# GREYBUS_BRIDGED_PHY
 
 config GREYBUS_ARCHE
 	tristate "Greybus Arche Platform driver"
-	depends on USB_HSIC_USB3613 || COMPILE_TEST
 	help
 	  Select this option if you have an Arche device.
Re: [PATCH] staging: greybus: arche: drop dangling Kconfig symbol
Posted by Johan Hovold 3 weeks, 3 days ago
On Mon, Dec 29, 2025 at 10:27:04PM -0800, Randy Dunlap wrote:
> The Kconfig symbol USB_HSIC_USB3613 is not defined in the kernel source
> tree. Drop it since it unused.
>
> Fixes: 2eccd4aa19fc ("staging: greybus: enable compile testing of arche driver")

As the commit message of that commit says this was done on purpose to
allow the driver to be compile tested without the out-of-tree driver
that never went upstream.

These days we have a USB hub driver that should probably be used
instead, but yeah, someone would need to do the rework.

And while referencing the commit is good, I'm not sure a Fixes tag is
warranted.

> Signed-off-by: Randy Dunlap <rdunlap@infradead.org>
 
> --- linux-next-20251219.orig/drivers/staging/greybus/arche-platform.c
> +++ linux-next-20251219/drivers/staging/greybus/arche-platform.c
> @@ -23,14 +23,10 @@
>  #include <linux/of.h>
>  #include "arche_platform.h"
>  
> -#if IS_ENABLED(CONFIG_USB_HSIC_USB3613)
> -#include <linux/usb/usb3613.h>
> -#else
>  static inline int usb3613_hub_mode_ctrl(bool unused)
>  {
>  	return 0;
>  }
> -#endif
>  
>  #define WD_COLDBOOT_PULSE_WIDTH_MS	30
>  
> --- linux-next-20251219.orig/drivers/staging/greybus/Kconfig
> +++ linux-next-20251219/drivers/staging/greybus/Kconfig
> @@ -206,7 +206,6 @@ endif	# GREYBUS_BRIDGED_PHY
>  
>  config GREYBUS_ARCHE
>  	tristate "Greybus Arche Platform driver"
> -	depends on USB_HSIC_USB3613 || COMPILE_TEST
>  	help
>  	  Select this option if you have an Arche device.

The above just seems to hide the fact that the driver currently cannot
be used.

Can you please at least add some kind of TODO comment to indicate that
the driver should be reworked to drop the dependency on the OOT driver?

And it's probably best to keep the depends on COMPILE_TEST until that
has been resolved. Perhaps also wrap usb3613_hub_mode_ctrl() in

	#ifdef CONFIG_COMPILE_TEST
	...
	#endif

Johan
Re: [PATCH] staging: greybus: arche: drop dangling Kconfig symbol
Posted by Randy Dunlap 3 weeks, 3 days ago
Hi,

On 1/14/26 1:21 AM, Johan Hovold wrote:
> On Mon, Dec 29, 2025 at 10:27:04PM -0800, Randy Dunlap wrote:
>> The Kconfig symbol USB_HSIC_USB3613 is not defined in the kernel source
>> tree. Drop it since it unused.
>>
>> Fixes: 2eccd4aa19fc ("staging: greybus: enable compile testing of arche driver")
> 
> As the commit message of that commit says this was done on purpose to
> allow the driver to be compile tested without the out-of-tree driver
> that never went upstream.
> 
> These days we have a USB hub driver that should probably be used
> instead, but yeah, someone would need to do the rework.

We?
Do you mean drivers/usb/core/hub.c?

> And while referencing the commit is good, I'm not sure a Fixes tag is
> warranted.
> 
>> Signed-off-by: Randy Dunlap <rdunlap@infradead.org>
>  
>> --- linux-next-20251219.orig/drivers/staging/greybus/arche-platform.c
>> +++ linux-next-20251219/drivers/staging/greybus/arche-platform.c
>> @@ -23,14 +23,10 @@
>>  #include <linux/of.h>
>>  #include "arche_platform.h"
>>  
>> -#if IS_ENABLED(CONFIG_USB_HSIC_USB3613)
>> -#include <linux/usb/usb3613.h>
>> -#else
>>  static inline int usb3613_hub_mode_ctrl(bool unused)
>>  {
>>  	return 0;
>>  }
>> -#endif
>>  
>>  #define WD_COLDBOOT_PULSE_WIDTH_MS	30
>>  
>> --- linux-next-20251219.orig/drivers/staging/greybus/Kconfig
>> +++ linux-next-20251219/drivers/staging/greybus/Kconfig
>> @@ -206,7 +206,6 @@ endif	# GREYBUS_BRIDGED_PHY
>>  
>>  config GREYBUS_ARCHE
>>  	tristate "Greybus Arche Platform driver"
>> -	depends on USB_HSIC_USB3613 || COMPILE_TEST
>>  	help
>>  	  Select this option if you have an Arche device.
> 
> The above just seems to hide the fact that the driver currently cannot
> be used.
> 
> Can you please at least add some kind of TODO comment to indicate that
> the driver should be reworked to drop the dependency on the OOT driver?

Sure, I can add that, but I think it needs more info. Reworked how?
What should the usb3613_hub_mode_ctrl() function do?

> And it's probably best to keep the depends on COMPILE_TEST until that

ack

> has been resolved. Perhaps also wrap usb3613_hub_mode_ctrl() in
> 
> 	#ifdef CONFIG_COMPILE_TEST
> 	...
> 	#endif

Don't think so. The driver calls usb3613_hub_mod_ctrl() in 4 places,
so it needs to be there.

-- 
~Randy
Re: [PATCH] staging: greybus: arche: drop dangling Kconfig symbol
Posted by Johan Hovold 3 weeks, 1 day ago
On Wed, Jan 14, 2026 at 04:28:33PM -0800, Randy Dunlap wrote:
> On 1/14/26 1:21 AM, Johan Hovold wrote:
> > On Mon, Dec 29, 2025 at 10:27:04PM -0800, Randy Dunlap wrote:
> >> The Kconfig symbol USB_HSIC_USB3613 is not defined in the kernel source
> >> tree. Drop it since it unused.
> >>
> >> Fixes: 2eccd4aa19fc ("staging: greybus: enable compile testing of arche driver")
> > 
> > As the commit message of that commit says this was done on purpose to
> > allow the driver to be compile tested without the out-of-tree driver
> > that never went upstream.
> > 
> > These days we have a USB hub driver that should probably be used
> > instead, but yeah, someone would need to do the rework.
> 
> We?
> Do you mean drivers/usb/core/hub.c?

I meant the on-board hub driver (now renamed to "on-board dev") which
did not exist when this greybus driver was written and merged to
staging:

	drivers/usb/misc/onboard_usb_dev_pdevs.c

> >> -#if IS_ENABLED(CONFIG_USB_HSIC_USB3613)
> >> -#include <linux/usb/usb3613.h>
> >> -#else
> >>  static inline int usb3613_hub_mode_ctrl(bool unused)
> >>  {
> >>  	return 0;
> >>  }
> >> -#endif
> >>  
> >>  #define WD_COLDBOOT_PULSE_WIDTH_MS	30
> >>  
> >> --- linux-next-20251219.orig/drivers/staging/greybus/Kconfig
> >> +++ linux-next-20251219/drivers/staging/greybus/Kconfig
> >> @@ -206,7 +206,6 @@ endif	# GREYBUS_BRIDGED_PHY
> >>  
> >>  config GREYBUS_ARCHE
> >>  	tristate "Greybus Arche Platform driver"
> >> -	depends on USB_HSIC_USB3613 || COMPILE_TEST
> >>  	help
> >>  	  Select this option if you have an Arche device.
> > 
> > The above just seems to hide the fact that the driver currently cannot
> > be used.
> > 
> > Can you please at least add some kind of TODO comment to indicate that
> > the driver should be reworked to drop the dependency on the OOT driver?
> 
> Sure, I can add that, but I think it needs more info. Reworked how?
> What should the usb3613_hub_mode_ctrl() function do?

IIRC, this driver exists since we needed to power on the on-board USB
hub so that the controller could be enumerated. Since there was no
support for doing such things at the time in mainline, we have this
custom interface for calling into the out-of-tree hub driver.

I'd need to spend more time looking at this to say exactly how this
should be reworked.

> > And it's probably best to keep the depends on COMPILE_TEST until that
> 
> ack
> 
> > has been resolved. Perhaps also wrap usb3613_hub_mode_ctrl() in
> > 
> > 	#ifdef CONFIG_COMPILE_TEST
> > 	...
> > 	#endif
> 
> Don't think so. The driver calls usb3613_hub_mod_ctrl() in 4 places,
> so it needs to be there.

Not if the driver can only be enabled for compile testing.

Perhaps replacing USB_HSIC_USB3613 with

	depends on BROKEN || COMPILE_TEST

and adding a comment above the ifdeffed usb3613_hub_mode_ctrl() helper
would make the state of things more clear.

Or just keep the dependency on the non-existing hub driver symbol. 

Johan
Re: [PATCH] staging: greybus: arche: drop dangling Kconfig symbol
Posted by Randy Dunlap 3 weeks ago

On 1/16/26 2:48 AM, Johan Hovold wrote:
> On Wed, Jan 14, 2026 at 04:28:33PM -0800, Randy Dunlap wrote:
>> On 1/14/26 1:21 AM, Johan Hovold wrote:
>>> On Mon, Dec 29, 2025 at 10:27:04PM -0800, Randy Dunlap wrote:
>>>> The Kconfig symbol USB_HSIC_USB3613 is not defined in the kernel source
>>>> tree. Drop it since it unused.
>>>>
>>>> Fixes: 2eccd4aa19fc ("staging: greybus: enable compile testing of arche driver")
>>>
>>> As the commit message of that commit says this was done on purpose to
>>> allow the driver to be compile tested without the out-of-tree driver
>>> that never went upstream.
>>>
>>> These days we have a USB hub driver that should probably be used
>>> instead, but yeah, someone would need to do the rework.
>>
>> We?
>> Do you mean drivers/usb/core/hub.c?
> 
> I meant the on-board hub driver (now renamed to "on-board dev") which
> did not exist when this greybus driver was written and merged to
> staging:
> 
> 	drivers/usb/misc/onboard_usb_dev_pdevs.c
> 
>>>> -#if IS_ENABLED(CONFIG_USB_HSIC_USB3613)
>>>> -#include <linux/usb/usb3613.h>
>>>> -#else
>>>>  static inline int usb3613_hub_mode_ctrl(bool unused)
>>>>  {
>>>>  	return 0;
>>>>  }
>>>> -#endif
>>>>  
>>>>  #define WD_COLDBOOT_PULSE_WIDTH_MS	30
>>>>  
>>>> --- linux-next-20251219.orig/drivers/staging/greybus/Kconfig
>>>> +++ linux-next-20251219/drivers/staging/greybus/Kconfig
>>>> @@ -206,7 +206,6 @@ endif	# GREYBUS_BRIDGED_PHY
>>>>  
>>>>  config GREYBUS_ARCHE
>>>>  	tristate "Greybus Arche Platform driver"
>>>> -	depends on USB_HSIC_USB3613 || COMPILE_TEST
>>>>  	help
>>>>  	  Select this option if you have an Arche device.
>>>
>>> The above just seems to hide the fact that the driver currently cannot
>>> be used.
>>>
>>> Can you please at least add some kind of TODO comment to indicate that
>>> the driver should be reworked to drop the dependency on the OOT driver?
>>
>> Sure, I can add that, but I think it needs more info. Reworked how?
>> What should the usb3613_hub_mode_ctrl() function do?
> 
> IIRC, this driver exists since we needed to power on the on-board USB
> hub so that the controller could be enumerated. Since there was no
> support for doing such things at the time in mainline, we have this
> custom interface for calling into the out-of-tree hub driver.
> 
> I'd need to spend more time looking at this to say exactly how this
> should be reworked.
> 
>>> And it's probably best to keep the depends on COMPILE_TEST until that
>>
>> ack
>>
>>> has been resolved. Perhaps also wrap usb3613_hub_mode_ctrl() in
>>>
>>> 	#ifdef CONFIG_COMPILE_TEST
>>> 	...
>>> 	#endif
>>
>> Don't think so. The driver calls usb3613_hub_mod_ctrl() in 4 places,
>> so it needs to be there.
> 
> Not if the driver can only be enabled for compile testing.
> 
> Perhaps replacing USB_HSIC_USB3613 with
> 
> 	depends on BROKEN || COMPILE_TEST
> 
> and adding a comment above the ifdeffed usb3613_hub_mode_ctrl() helper
> would make the state of things more clear.
> 
> Or just keep the dependency on the non-existing hub driver symbol. 

Yeah, it's such a mess that I'll just leave it as is.

Perhaps you or someone who cares about it can do something about it.

-- 
~Randy
Re: [PATCH] staging: greybus: arche: drop dangling Kconfig symbol
Posted by Randy Dunlap 1 month, 1 week ago

On 12/29/25 10:27 PM, Randy Dunlap wrote:
> --- linux-next-20251219.orig/drivers/staging/greybus/Kconfig
> +++ linux-next-20251219/drivers/staging/greybus/Kconfig
> @@ -206,7 +206,6 @@ endif	# GREYBUS_BRIDGED_PHY
>  
>  config GREYBUS_ARCHE
>  	tristate "Greybus Arche Platform driver"
> -	depends on USB_HSIC_USB3613 || COMPILE_TEST
>  	help
>  	  Select this option if you have an Arche device.

Perhaps I should have left COMPILE_TEST here, like:

	depends on COMPILE_TEST

?
-- 
~Randy
Re: [PATCH] staging: greybus: arche: drop dangling Kconfig symbol
Posted by Dan Carpenter 1 month ago
On Tue, Dec 30, 2025 at 10:23:40AM -0800, Randy Dunlap wrote:
> 
> 
> On 12/29/25 10:27 PM, Randy Dunlap wrote:
> > --- linux-next-20251219.orig/drivers/staging/greybus/Kconfig
> > +++ linux-next-20251219/drivers/staging/greybus/Kconfig
> > @@ -206,7 +206,6 @@ endif	# GREYBUS_BRIDGED_PHY
> >  
> >  config GREYBUS_ARCHE
> >  	tristate "Greybus Arche Platform driver"
> > -	depends on USB_HSIC_USB3613 || COMPILE_TEST
> >  	help
> >  	  Select this option if you have an Arche device.
> 
> Perhaps I should have left COMPILE_TEST here, like:
> 
> 	depends on COMPILE_TEST
> 
> ?

If we're going to do that, we should just delete it.  It's been
impossible to build for eight years.

regards,
dan carpenter
Re: [PATCH] staging: greybus: arche: drop dangling Kconfig symbol
Posted by Randy Dunlap 1 month ago

On 1/5/26 2:09 AM, Dan Carpenter wrote:
> On Tue, Dec 30, 2025 at 10:23:40AM -0800, Randy Dunlap wrote:
>>
>>
>> On 12/29/25 10:27 PM, Randy Dunlap wrote:
>>> --- linux-next-20251219.orig/drivers/staging/greybus/Kconfig
>>> +++ linux-next-20251219/drivers/staging/greybus/Kconfig
>>> @@ -206,7 +206,6 @@ endif	# GREYBUS_BRIDGED_PHY
>>>  
>>>  config GREYBUS_ARCHE
>>>  	tristate "Greybus Arche Platform driver"
>>> -	depends on USB_HSIC_USB3613 || COMPILE_TEST
>>>  	help
>>>  	  Select this option if you have an Arche device.

OK, with just the v1 patch here, it does build without errors.
Seems like I should leave this patch as is.


  CC [M]  drivers/staging/greybus/arche-platform.o
  CC [M]  drivers/staging/greybus/arche-apb-ctrl.o
  LD [M]  drivers/staging/greybus/gb-arche.o

>> Perhaps I should have left COMPILE_TEST here, like:
>>
>> 	depends on COMPILE_TEST
>>
>> ?
> 
> If we're going to do that, we should just delete it.  It's been
> impossible to build for eight years.


-- 
~Randy
Re: [PATCH] staging: greybus: arche: drop dangling Kconfig symbol
Posted by Dan Carpenter 1 month ago
On Mon, Jan 05, 2026 at 01:09:17PM +0300, Dan Carpenter wrote:
> On Tue, Dec 30, 2025 at 10:23:40AM -0800, Randy Dunlap wrote:
> > 
> > 
> > On 12/29/25 10:27 PM, Randy Dunlap wrote:
> > > --- linux-next-20251219.orig/drivers/staging/greybus/Kconfig
> > > +++ linux-next-20251219/drivers/staging/greybus/Kconfig
> > > @@ -206,7 +206,6 @@ endif	# GREYBUS_BRIDGED_PHY
> > >  
> > >  config GREYBUS_ARCHE
> > >  	tristate "Greybus Arche Platform driver"
> > > -	depends on USB_HSIC_USB3613 || COMPILE_TEST
> > >  	help
> > >  	  Select this option if you have an Arche device.
> > 
> > Perhaps I should have left COMPILE_TEST here, like:
> > 
> > 	depends on COMPILE_TEST
> > 
> > ?
> 
> If we're going to do that, we should just delete it.  It's been
> impossible to build for eight years.
> 

I did a `git grep 'depends on COMPILE_TEST'` for other drivers which
are never used and only found this one which was disabled in 2018.

regards,
dan carpenter

commit da2827a298f8a2159f31466759cbba2dd4f1b65f
Author: Arnd Bergmann <arnd@arndb.de>
Date:   Fri Mar 9 22:45:26 2018 +0100

    usb: isp1362: remove blackfin arch glue

    The blackfin architecture is getting removed, and this is the last
    remaining architecture specific setting, so the various hacks
    can be removed now.

    From all I can tell, there are no remaining in-tree users of the
    driver, but it could be used by out-of-tree platform ports.
    I've marked the driver as 'depends on COMPILE_TEST', short of
    removing it outright.

    It was originally written for some ARM PXA machines using the same
    chip, but that platform never really worked and the code has been
    removed a long time ago.

    Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
    Acked-by: Aaron Wu <aaron.wu@analog.com>
    Signed-off-by: Arnd Bergmann <arnd@arndb.de>

diff --git a/drivers/usb/host/Kconfig b/drivers/usb/host/Kconfig
index 4fcfb3084b36..b85822f0c874 100644
--- a/drivers/usb/host/Kconfig
+++ b/drivers/usb/host/Kconfig
@@ -360,6 +360,7 @@ config USB_ISP116X_HCD
 config USB_ISP1362_HCD
        tristate "ISP1362 HCD support"
        depends on HAS_IOMEM
+       depends on COMPILE_TEST # nothing uses this
        ---help---
          Supports the Philips ISP1362 chip as a host controller
Re: [PATCH] staging: greybus: arche: drop dangling Kconfig symbol
Posted by Randy Dunlap 1 month ago
Hi Dan,

On 1/5/26 2:16 AM, Dan Carpenter wrote:
> On Mon, Jan 05, 2026 at 01:09:17PM +0300, Dan Carpenter wrote:
>> On Tue, Dec 30, 2025 at 10:23:40AM -0800, Randy Dunlap wrote:
>>>
>>>
>>> On 12/29/25 10:27 PM, Randy Dunlap wrote:
>>>> --- linux-next-20251219.orig/drivers/staging/greybus/Kconfig
>>>> +++ linux-next-20251219/drivers/staging/greybus/Kconfig
>>>> @@ -206,7 +206,6 @@ endif	# GREYBUS_BRIDGED_PHY
>>>>  
>>>>  config GREYBUS_ARCHE
>>>>  	tristate "Greybus Arche Platform driver"
>>>> -	depends on USB_HSIC_USB3613 || COMPILE_TEST
>>>>  	help
>>>>  	  Select this option if you have an Arche device.
>>>
>>> Perhaps I should have left COMPILE_TEST here, like:
>>>
>>> 	depends on COMPILE_TEST
>>>
>>> ?
>>
>> If we're going to do that, we should just delete it.  It's been
>> impossible to build for eight years.
>>

I saw that. I just wanted some feedback on it first.
I'll send v2.

> 
> I did a `git grep 'depends on COMPILE_TEST'` for other drivers which
> are never used and only found this one which was disabled in 2018.

Looks like it should go away also. Thanks.

> regards,
> dan carpenter
> 
> commit da2827a298f8a2159f31466759cbba2dd4f1b65f
> Author: Arnd Bergmann <arnd@arndb.de>
> Date:   Fri Mar 9 22:45:26 2018 +0100
> 
>     usb: isp1362: remove blackfin arch glue
> 
>     The blackfin architecture is getting removed, and this is the last
>     remaining architecture specific setting, so the various hacks
>     can be removed now.
> 
>     From all I can tell, there are no remaining in-tree users of the
>     driver, but it could be used by out-of-tree platform ports.
>     I've marked the driver as 'depends on COMPILE_TEST', short of
>     removing it outright.
> 
>     It was originally written for some ARM PXA machines using the same
>     chip, but that platform never really worked and the code has been
>     removed a long time ago.
> 
>     Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
>     Acked-by: Aaron Wu <aaron.wu@analog.com>
>     Signed-off-by: Arnd Bergmann <arnd@arndb.de>
> 
> diff --git a/drivers/usb/host/Kconfig b/drivers/usb/host/Kconfig
> index 4fcfb3084b36..b85822f0c874 100644
> --- a/drivers/usb/host/Kconfig
> +++ b/drivers/usb/host/Kconfig
> @@ -360,6 +360,7 @@ config USB_ISP116X_HCD
>  config USB_ISP1362_HCD
>         tristate "ISP1362 HCD support"
>         depends on HAS_IOMEM
> +       depends on COMPILE_TEST # nothing uses this
>         ---help---
>           Supports the Philips ISP1362 chip as a host controller
> 

-- 
~Randy