netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH]  remove isa stuff from smc91x driver
@ 2008-12-03 14:48 Luotao Fu
  2008-12-03 14:52 ` Alan Cox
  0 siblings, 1 reply; 5+ messages in thread
From: Luotao Fu @ 2008-12-03 14:48 UTC (permalink / raw)
  To: netdev; +Cc: linux-kernel, Luotao Fu

From: Luotao Fu <lfu@pengutronix.de>

ISA support in smc91x is incomplete. I doubt there're any smc91x isa card.
This driver is greatly used on arm pxa platforms. Hence we remove the
isa stuff from smc91x driver.

Signed-off-by: Luotao Fu <lfu@pengutronix.de>
---
 drivers/net/smc91x.c |   36 ------------------------------------
 drivers/net/smc91x.h |   13 -------------
 2 files changed, 0 insertions(+), 49 deletions(-)

diff --git a/drivers/net/smc91x.c b/drivers/net/smc91x.c
index 35c56ab..7827683 100644
--- a/drivers/net/smc91x.c
+++ b/drivers/net/smc91x.c
@@ -90,33 +90,6 @@ static const char version[] =
 
 #include "smc91x.h"
 
-#ifdef CONFIG_ISA
-/*
- * the LAN91C111 can be at any of the following port addresses.  To change,
- * for a slightly different card, you can add it to the array.  Keep in
- * mind that the array must end in zero.
- */
-static unsigned int smc_portlist[] __initdata = {
-	0x200, 0x220, 0x240, 0x260, 0x280, 0x2A0, 0x2C0, 0x2E0,
-	0x300, 0x320, 0x340, 0x360, 0x380, 0x3A0, 0x3C0, 0x3E0, 0
-};
-
-#ifndef SMC_IOADDR
-# define SMC_IOADDR		-1
-#endif
-static unsigned long io = SMC_IOADDR;
-module_param(io, ulong, 0400);
-MODULE_PARM_DESC(io, "I/O base address");
-
-#ifndef SMC_IRQ
-# define SMC_IRQ		-1
-#endif
-static int irq = SMC_IRQ;
-module_param(irq, int, 0400);
-MODULE_PARM_DESC(irq, "IRQ number");
-
-#endif  /* CONFIG_ISA */
-
 #ifndef SMC_NOWAIT
 # define SMC_NOWAIT		0
 #endif
@@ -2316,15 +2289,6 @@ static struct platform_driver smc_driver = {
 
 static int __init smc_init(void)
 {
-#ifdef MODULE
-#ifdef CONFIG_ISA
-	if (io == -1)
-		printk(KERN_WARNING
-			"%s: You shouldn't use auto-probing with insmod!\n",
-			CARDNAME);
-#endif
-#endif
-
 	return platform_driver_register(&smc_driver);
 }
 
diff --git a/drivers/net/smc91x.h b/drivers/net/smc91x.h
index a07cc93..066bab5 100644
--- a/drivers/net/smc91x.h
+++ b/drivers/net/smc91x.h
@@ -286,19 +286,6 @@ SMC_outw(u16 val, void __iomem *ioaddr, int reg)
 
 #define SMC_IRQ_FLAGS		(0)
 
-#elif	defined(CONFIG_ISA)
-
-#define SMC_CAN_USE_8BIT	1
-#define SMC_CAN_USE_16BIT	1
-#define SMC_CAN_USE_32BIT	0
-
-#define SMC_inb(a, r)		inb((a) + (r))
-#define SMC_inw(a, r)		inw((a) + (r))
-#define SMC_outb(v, a, r)	outb(v, (a) + (r))
-#define SMC_outw(v, a, r)	outw(v, (a) + (r))
-#define SMC_insw(a, r, p, l)	insw((a) + (r), p, l)
-#define SMC_outsw(a, r, p, l)	outsw((a) + (r), p, l)
-
 #elif   defined(CONFIG_M32R)
 
 #define SMC_CAN_USE_8BIT	0
-- 
1.5.6.5


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

* Re: [PATCH]  remove isa stuff from smc91x driver
  2008-12-03 14:48 [PATCH] remove isa stuff from smc91x driver Luotao Fu
@ 2008-12-03 14:52 ` Alan Cox
  2008-12-03 15:19   ` Luotao Fu
  0 siblings, 1 reply; 5+ messages in thread
From: Alan Cox @ 2008-12-03 14:52 UTC (permalink / raw)
  To: Luotao Fu; +Cc: netdev, linux-kernel, Luotao Fu

On Wed,  3 Dec 2008 15:48:21 +0100
Luotao Fu <l.fu@pengutronix.de> wrote:

> From: Luotao Fu <lfu@pengutronix.de>
> 
> ISA support in smc91x is incomplete. I doubt there're any smc91x isa card.
> This driver is greatly used on arm pxa platforms. Hence we remove the
> isa stuff from smc91x driver.

This makes no sense. It is protected by an ifdef anyway so doesn't affect
ARM


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

* Re: [PATCH]  remove isa stuff from smc91x driver
  2008-12-03 14:52 ` Alan Cox
@ 2008-12-03 15:19   ` Luotao Fu
  2008-12-03 16:30     ` Steve.Glendinning
  0 siblings, 1 reply; 5+ messages in thread
From: Luotao Fu @ 2008-12-03 15:19 UTC (permalink / raw)
  To: Alan Cox; +Cc: Luotao Fu, netdev, linux-kernel

[-- Attachment #1: Type: text/plain, Size: 935 bytes --]

On Wed, Dec 03, 2008 at 02:52:35PM +0000, Alan Cox wrote:
> On Wed,  3 Dec 2008 15:48:21 +0100
> Luotao Fu <l.fu@pengutronix.de> wrote:
> 
> > From: Luotao Fu <lfu@pengutronix.de>
> > 
> > ISA support in smc91x is incomplete. I doubt there're any smc91x isa card.
> > This driver is greatly used on arm pxa platforms. Hence we remove the
> > isa stuff from smc91x driver.
> 
> This makes no sense. It is protected by an ifdef anyway so doesn't affect
> ARM

The isa part in smc91x does nothing at all. Get you a unused variable warning if
you turn ISA on and compile it. The io table is defined and not used at all.
Neither does the io address and irq by parameter. I think that these are waste
code and should be removed.

Cheers
Luotao Fu
-- 
   Dipl.-Ing. Luotao Fu | Phone: +49-5121-206917-5004
Pengutronix - Linux Solutions for Science and Industry
Entwicklungszentrum Nord     http://www.pengutronix.de


[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 189 bytes --]

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

* Re: [PATCH]  remove isa stuff from smc91x driver
  2008-12-03 15:19   ` Luotao Fu
@ 2008-12-03 16:30     ` Steve.Glendinning
  2008-12-04  6:23       ` David Miller
  0 siblings, 1 reply; 5+ messages in thread
From: Steve.Glendinning @ 2008-12-03 16:30 UTC (permalink / raw)
  To: Luotao Fu; +Cc: Alan Cox, linux-kernel, Luotao Fu, netdev, Ian.Saturley

Hi all,

> > > ISA support in smc91x is incomplete. I doubt there're any smc91xisa 
card.
> > > This driver is greatly used on arm pxa platforms. Hence we remove 
the
> > > isa stuff from smc91x driver.
> > 
> > This makes no sense. It is protected by an ifdef anyway so doesn't 
affect
> > ARM
> 
> The isa part in smc91x does nothing at all. Get you a unused 
> variable warning if
> you turn ISA on and compile it. The io table is defined and not used at 
all.
> Neither does the io address and irq by parameter. I think that theseare 
waste
> code and should be removed.

SMSC LAN91C111 *does* still exist on ISA platforms (for example PC104), 
but
Luotao is right: the smc91x driver support for it is broken.

I have one here on an ISA board (and it took me a long time to find 
working PC
hardware old enough to use this!).  I'll send a patch when I can find time 
to
fix it, but until then I agree this broken code should be removed.

Acked-by: Steve Glendinning <steve.glendinning@smsc.com>

--
Steve Glendinning
SMSC GmbH
m: +44 777 933 9124
e: steve.glendinning@smsc.com


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

* Re: [PATCH] remove isa stuff from smc91x driver
  2008-12-03 16:30     ` Steve.Glendinning
@ 2008-12-04  6:23       ` David Miller
  0 siblings, 0 replies; 5+ messages in thread
From: David Miller @ 2008-12-04  6:23 UTC (permalink / raw)
  To: Steve.Glendinning; +Cc: l.fu, alan, linux-kernel, netdev, Ian.Saturley

From: Steve.Glendinning@smsc.com
Date: Wed, 3 Dec 2008 16:30:23 +0000

> SMSC LAN91C111 *does* still exist on ISA platforms (for example PC104), 
> but
> Luotao is right: the smc91x driver support for it is broken.
> 
> I have one here on an ISA board (and it took me a long time to find 
> working PC
> hardware old enough to use this!).  I'll send a patch when I can find time 
> to
> fix it, but until then I agree this broken code should be removed.
> 
> Acked-by: Steve Glendinning <steve.glendinning@smsc.com>

Agreed, applied to net-next-2.6, thanks everyone.

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

end of thread, other threads:[~2008-12-04  6:23 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-12-03 14:48 [PATCH] remove isa stuff from smc91x driver Luotao Fu
2008-12-03 14:52 ` Alan Cox
2008-12-03 15:19   ` Luotao Fu
2008-12-03 16:30     ` Steve.Glendinning
2008-12-04  6:23       ` David Miller

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).