Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 16 Feb 2017 21:56:51 +0000 (UTC)
From:      Warner Losh <imp@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r313831 - in head: share/man/man4/man4.i386 sys/conf sys/dev/ep sys/modules/ep
Message-ID:  <201702162156.v1GLup24043539@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: imp
Date: Thu Feb 16 21:56:51 2017
New Revision: 313831
URL: https://svnweb.freebsd.org/changeset/base/313831

Log:
  Remove EISA support for ep driver. Left in place EISA strings that are
  still relevant (ISA cards can still be in EISA mode, and we're still
  ignoring those in the identify routine). Notes about cards in EISA
  mode have been left in the manual since they aren't relevant to EISA
  support, but instruct how to properly configure an ISA card in a mode
  when it is in a ISA bus slot.

Deleted:
  head/sys/dev/ep/if_ep_eisa.c
Modified:
  head/share/man/man4/man4.i386/ep.4
  head/sys/conf/files
  head/sys/dev/ep/if_ep.c
  head/sys/dev/ep/if_ep_isa.c
  head/sys/dev/ep/if_epvar.h
  head/sys/modules/ep/Makefile

Modified: head/share/man/man4/man4.i386/ep.4
==============================================================================
--- head/share/man/man4/man4.i386/ep.4	Thu Feb 16 21:56:46 2017	(r313830)
+++ head/share/man/man4/man4.i386/ep.4	Thu Feb 16 21:56:51 2017	(r313831)
@@ -99,8 +99,6 @@ driver supports Ethernet adapters based 
 .It
 3Com 3C574, 3C574TX, 3C574-TX, 3CCFE574BT, 3CXFE574BT, 3C3FE574BT PCMCIA
 .It
-3Com 3C579-TP, 3C579-BNC EISA
-.It
 3Com 3C589, 3C589B, 3C589C, 3C589D, 3CXE589DT PCMCIA
 .It
 3Com 3CCFEM556B, 3CCFEM556BI PCMCIA
@@ -121,10 +119,7 @@ scan operation at IO address 0x110.
 Beware!
 Avoid placing other cards at that address!
 .Pp
-Furthermore, the 3c509 should only be configured in EISA mode
-when installed in a computer that has actual EISA slots
-(and an EISA-aware BIOS).
-The normal driver auto-detection support is sufficient for non-EISA systems.
+Furthermore, the 3c509 should not be configured in EISA mode.
 .Pp
 Cards in PnP mode may conflict with other resources in the system.
 Ensure your BIOS is configured correctly to exclude resources used by
@@ -180,9 +175,9 @@ has about connectors, so it is assuming 
 .It "ep0: unknown ID 0xXXXXXXXX"
 The driver has found an ID that it believes it supports, but does not
 have a specific identification string to present to the user.
-.It "ep0: <%s> at port 0x%03x in EISA mode"
+.It "ep0: <%s> at port 0x%03x in EISA mode, ignored."
 The 3C509 ISA card is in EISA mode.
-This message appears to be purely informational.
+The card will be ignored until it is taken out of EISA mode.
 .It "ep0: <%s> at x0%03x in PnP mode"
 This card appears to be in Plug and Play mode.
 It should be probed as part of the plug and play phase of the ISA

Modified: head/sys/conf/files
==============================================================================
--- head/sys/conf/files	Thu Feb 16 21:56:46 2017	(r313830)
+++ head/sys/conf/files	Thu Feb 16 21:56:51 2017	(r313831)
@@ -1604,7 +1604,6 @@ dev/et/if_et.c			optional et
 dev/en/if_en_pci.c		optional en pci
 dev/en/midway.c			optional en
 dev/ep/if_ep.c			optional ep
-dev/ep/if_ep_eisa.c		optional ep eisa
 dev/ep/if_ep_isa.c		optional ep isa
 dev/ep/if_ep_pccard.c		optional ep pccard
 dev/esp/esp_pci.c		optional esp pci

Modified: head/sys/dev/ep/if_ep.c
==============================================================================
--- head/sys/dev/ep/if_ep.c	Thu Feb 16 21:56:46 2017	(r313830)
+++ head/sys/dev/ep/if_ep.c	Thu Feb 16 21:56:51 2017	(r313831)
@@ -530,31 +530,17 @@ startagain:
 		CSR_WRITE_2(sc, EP_COMMAND,
 		    SET_TX_AVAIL_THRESH | EP_THRESH_DISABLE);
 
-	/* XXX 4.x and earlier would splhigh here */
-
 	CSR_WRITE_2(sc, EP_W1_TX_PIO_WR_1, len);
 	/* Second dword meaningless */
 	CSR_WRITE_2(sc, EP_W1_TX_PIO_WR_1, 0x0);
 
-	if (EP_FTST(sc, F_ACCESS_32_BITS)) {
-		for (m = m0; m != NULL; m = m->m_next) {
-			if (m->m_len > 3)
-				CSR_WRITE_MULTI_4(sc, EP_W1_TX_PIO_WR_1,
-				    mtod(m, uint32_t *), m->m_len / 4);
-			if (m->m_len & 3)
-				CSR_WRITE_MULTI_1(sc, EP_W1_TX_PIO_WR_1,
-				    mtod(m, uint8_t *)+(m->m_len & (~3)),
-				    m->m_len & 3);
-		}
-	} else {
-		for (m = m0; m != NULL; m = m->m_next) {
-			if (m->m_len > 1)
-				CSR_WRITE_MULTI_2(sc, EP_W1_TX_PIO_WR_1,
-				    mtod(m, uint16_t *), m->m_len / 2);
-			if (m->m_len & 1)
-				CSR_WRITE_1(sc, EP_W1_TX_PIO_WR_1,
-				    *(mtod(m, uint8_t *)+m->m_len - 1));
-		}
+	for (m = m0; m != NULL; m = m->m_next) {
+		if (m->m_len > 1)
+			CSR_WRITE_MULTI_2(sc, EP_W1_TX_PIO_WR_1,
+			    mtod(m, uint16_t *), m->m_len / 2);
+		if (m->m_len & 1)
+			CSR_WRITE_1(sc, EP_W1_TX_PIO_WR_1,
+			    *(mtod(m, uint8_t *)+m->m_len - 1));
 	}
 
 	while (pad--)
@@ -788,25 +774,13 @@ read_again:
 			mcur->m_next = m;
 			lenthisone = min(rx_fifo, M_TRAILINGSPACE(m));
 		}
-		if (EP_FTST(sc, F_ACCESS_32_BITS)) {
-			/* default for EISA configured cards */
-			CSR_READ_MULTI_4(sc, EP_W1_RX_PIO_RD_1,
-			    (uint32_t *)(mtod(m, caddr_t)+m->m_len),
-			    lenthisone / 4);
-			m->m_len += (lenthisone & ~3);
-			if (lenthisone & 3)
-				CSR_READ_MULTI_1(sc, EP_W1_RX_PIO_RD_1,
-				    mtod(m, caddr_t)+m->m_len, lenthisone & 3);
-			m->m_len += (lenthisone & 3);
-		} else {
-			CSR_READ_MULTI_2(sc, EP_W1_RX_PIO_RD_1,
-			    (uint16_t *)(mtod(m, caddr_t)+m->m_len),
-			    lenthisone / 2);
-			m->m_len += lenthisone;
-			if (lenthisone & 1)
-				*(mtod(m, caddr_t)+m->m_len - 1) =
-				    CSR_READ_1(sc, EP_W1_RX_PIO_RD_1);
-		}
+		CSR_READ_MULTI_2(sc, EP_W1_RX_PIO_RD_1,
+		    (uint16_t *)(mtod(m, caddr_t)+m->m_len),
+		    lenthisone / 2);
+		m->m_len += lenthisone;
+		if (lenthisone & 1)
+			*(mtod(m, caddr_t)+m->m_len - 1) =
+			    CSR_READ_1(sc, EP_W1_RX_PIO_RD_1);
 		rx_fifo -= lenthisone;
 	}
 

Modified: head/sys/dev/ep/if_ep_isa.c
==============================================================================
--- head/sys/dev/ep/if_ep_isa.c	Thu Feb 16 21:56:46 2017	(r313830)
+++ head/sys/dev/ep/if_ep_isa.c	Thu Feb 16 21:56:51 2017	(r313831)
@@ -194,8 +194,7 @@ ep_isa_identify(driver_t * driver, devic
 			(void)get_eeprom_data(ELINK_ID_PORT, j);
 
 		/*
-		 * Construct an 'isa_id' in 'EISA'
-		 * format.
+		 * Construct an 'isa_id' in 'EISA' format.
 		 */
 		data = get_eeprom_data(ELINK_ID_PORT, EEPROM_MFG_ID);
 		isa_id = (htons(data) << 16);
@@ -220,7 +219,7 @@ ep_isa_identify(driver_t * driver, devic
 
 		if ((data & ADDR_CFG_MASK) == ADDR_CFG_EISA) {
 			device_printf(parent,
-			    "<%s> at port 0x%03x in EISA mode!\n",
+			    "<%s> at port 0x%03x in EISA mode, ignoring!\n",
 			    desc, ioport);
 			/*
 			 * Set the adaptor tag so that the next card can be

Modified: head/sys/dev/ep/if_epvar.h
==============================================================================
--- head/sys/dev/ep/if_epvar.h	Thu Feb 16 21:56:46 2017	(r313830)
+++ head/sys/dev/ep/if_epvar.h	Thu Feb 16 21:56:51 2017	(r313831)
@@ -59,7 +59,6 @@ struct ep_softc {
 #define	F_RX_FIRST		0x001
 #define F_ENADDR_SKIP		0x002
 #define	F_PROMISC		0x008
-#define	F_ACCESS_32_BITS	0x100
 #define	F_HAS_TX_PLL		0x200
 
 	int gone;		/* adapter is not present (for PCCARD) */

Modified: head/sys/modules/ep/Makefile
==============================================================================
--- head/sys/modules/ep/Makefile	Thu Feb 16 21:56:46 2017	(r313830)
+++ head/sys/modules/ep/Makefile	Thu Feb 16 21:56:51 2017	(r313831)
@@ -9,7 +9,6 @@ KMOD=	if_ep
 SRCS=	if_ep.c
 SRCS+=	if_ep_pccard.c pccarddevs.h card_if.h
 SRCS+=	if_ep_isa.c isa_if.h
-SRCS.DEV_EISA=	if_ep_eisa.c eisa_if.h
 SRCS+=	bus_if.h device_if.h
 
 .include <bsd.kmod.mk>



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201702162156.v1GLup24043539>