2021-04-13 20:10:53

by Arnd Bergmann

[permalink] [raw]
Subject: [PATCH net-next] net: Space: remove hp100 probe

From: Arnd Bergmann <[email protected]>

The driver was removed last year, but the static initialization got left
behind by accident.

Fixes: a10079c66290 ("staging: remove hp100 driver")
Signed-off-by: Arnd Bergmann <[email protected]>
---
drivers/net/Space.c | 3 ---
1 file changed, 3 deletions(-)

diff --git a/drivers/net/Space.c b/drivers/net/Space.c
index 7bb699d7c422..a61cc7b26a87 100644
--- a/drivers/net/Space.c
+++ b/drivers/net/Space.c
@@ -59,9 +59,6 @@ static int __init probe_list2(int unit, struct devprobe2 *p, int autoprobe)
* look for EISA/PCI cards in addition to ISA cards).
*/
static struct devprobe2 isa_probes[] __initdata = {
-#if defined(CONFIG_HP100) && defined(CONFIG_ISA) /* ISA, EISA */
- {hp100_probe, 0},
-#endif
#ifdef CONFIG_3C515
{tc515_probe, 0},
#endif
--
2.29.2


2021-04-14 09:02:59

by Stephen Hemminger

[permalink] [raw]
Subject: Re: [PATCH net-next] net: Space: remove hp100 probe

On Tue, 13 Apr 2021 16:16:17 +0200
Arnd Bergmann <[email protected]> wrote:

> From: Arnd Bergmann <[email protected]>
>
> The driver was removed last year, but the static initialization got left
> behind by accident.
>
> Fixes: a10079c66290 ("staging: remove hp100 driver")
> Signed-off-by: Arnd Bergmann <[email protected]>
> ---
> drivers/net/Space.c | 3 ---
> 1 file changed, 3 deletions(-)
>
> diff --git a/drivers/net/Space.c b/drivers/net/Space.c
> index 7bb699d7c422..a61cc7b26a87 100644
> --- a/drivers/net/Space.c
> +++ b/drivers/net/Space.c
> @@ -59,9 +59,6 @@ static int __init probe_list2(int unit, struct devprobe2 *p, int autoprobe)
> * look for EISA/PCI cards in addition to ISA cards).
> */
> static struct devprobe2 isa_probes[] __initdata = {
> -#if defined(CONFIG_HP100) && defined(CONFIG_ISA) /* ISA, EISA */
> - {hp100_probe, 0},
> -#endif
> #ifdef CONFIG_3C515
> {tc515_probe, 0},
> #endif

Thanks, do we even need to have the static initialization anymore?

2021-04-14 13:44:41

by Arnd Bergmann

[permalink] [raw]
Subject: Re: [PATCH net-next] net: Space: remove hp100 probe

On Wed, Apr 14, 2021, 00:42 Stephen Hemminger
<[email protected]> wrote:
>
> On Tue, 13 Apr 2021 16:16:17 +0200 Arnd Bergmann <[email protected]> wrote:
>
> > */
> > static struct devprobe2 isa_probes[] __initdata = {
> > -#if defined(CONFIG_HP100) && defined(CONFIG_ISA) /* ISA, EISA */
> > - {hp100_probe, 0},
> > -#endif
> > #ifdef CONFIG_3C515
> > {tc515_probe, 0},
> > #endif
>
> Thanks, do we even need to have the static initialization anymore?

I actually did some more cleanups after I sent the above patch when
I found out that this code still exists. It turned out that above half of
the static initializations are completely pointless because the
drivers never rely on the netdev= command line arguments and
can simply be changed to always using module_init() instead of
relying on net_olddevs_init() for the built-in case.

The remaining ones are all ISA drivers: 3c515, Ultra, WD80x3,
NE2000, Lance, SMC9194, CS89x0, NI65 and COPS.

With my cleanups, I move the netdev_boot_setup infrastructure
into drivers/net/Space.c and only compile it when at least one of
these eight drivers is enabled.

All these drivers also support being built as loadable modules, but
in that configuration they only support a single device (back in the
day you could copy the module and just load it twice to support
more than one instance, not sure we still want to support that).

None of these drivers have a maintainer listed, but I suppose
there are still some PC/104 machines with NE2000 network
cards that could theoretically run a modern kernel.

Arnd