Definition at line 631 of file ns8390.c.
637 #ifdef INCLUDE_NS8390 638 unsigned short pci_probe_addrs[] = { pci->
ioaddr, 0 };
639 unsigned short *probe_addrs = pci_probe_addrs;
651 struct wd_board *brd;
652 unsigned short chksum;
660 if ((chksum & 0xFF) == 0xFF &&
674 for (brd = wd_boards; brd->name; brd++)
675 if (brd->id ==
c)
break;
677 printf(
"Unknown WD/SMC NIC type %hhX\n",
c);
697 if (((
addr >> 4) & 3) == 0) {
720 ((
unsigned)(
eth_bmem >> 11) & 0x40) |
762 int iobase_reg, membase_reg;
763 static unsigned short base[] = {
764 0x300, 0x310, 0x330, 0x350,
765 0x250, 0x280, 0x2A0, 0x2E0, 0 };
787 if ((iobase_reg & (iobase_reg - 1)) ||
788 (membase_reg & (membase_reg - 1)))
795 switch (membase_reg) {
848 DBG (
", %s, MAC Addr %s\n",
nic->
flags ?
"AUI" :
"internal xcvr",
868 for(i = 0; i < 0x2000; ++i)
870 printf (
"Failed to clear 3c503 shared mem.\n");
881 #if defined(INCLUDE_NE) || defined(INCLUDE_NS8390) 888 unsigned char romdata[16];
889 unsigned char testbuf[32];
891 static unsigned char test[] =
"NE*000 memory";
892 static unsigned short base[] = {
898 if (probe_addrs ==
NULL || probe_addrs[0] == 0)
901 for (idx = 0; (
eth_nic_base = probe_addrs[idx]) != 0; ++idx) {
916 #ifdef NS8390_FORCE_16BIT 947 DBG (
"\nNE%c000 base %4.4x, MAC Addr %s\n",
963 dev->devid.device_id =
htons(0x812a);
967 dev->devid.device_id =
htons(0x80f3);
971 dev->devid.device_id =
htons(0x80d6);
static unsigned char eth_memsize
static __always_inline void off_t int c
int printf(const char *fmt,...)
Write a formatted string to the console.
unsigned long ioaddr
I/O address.
static unsigned short eth_asic_base
static unsigned char eth_vendor
static __always_inline void * bus_to_virt(unsigned long bus_addr)
Convert bus address to a virtual address.
static struct nic_operations ns8390_operations
static void eth_pio_read(unsigned int src, unsigned char *dst, unsigned int cnt)
static unsigned char eth_flags
#define GENERIC_ISAPNP_VENDOR
static void eth_pio_write(const unsigned char *src, unsigned int dst, unsigned int cnt)
const char * eth_ntoa(const void *ll_addr)
Transcribe Ethernet address.
static unsigned short eth_nic_base
static void ns8390_reset(struct nic *nic)
#define _3COM_ASIC_OFFSET
uint8_t inb(volatile uint8_t *io_addr)
Read byte from I/O-mapped device.
#define D8390_COMMAND_RD2
unsigned char * node_addr
#define outb(data, io_addr)
#define D8390_COMMAND_STP
static unsigned char eth_rx_start
#define DBG(...)
Print a debugging message.
struct nic_operations * nic_op
static unsigned char eth_tx_start
static unsigned char eth_drain_receiver
int memcmp(const void *first, const void *second, size_t len)
Compare memory regions.
#define NULL
NULL pointer (VOID *)
void * memset(void *dest, int character, size_t len) __nonnull
References _3COM_ASIC_OFFSET, _3COM_BCFR, _3COM_CR, _3COM_CR_EALO, _3COM_CR_RST, _3COM_CR_XSEL, _3COM_GACFR, _3COM_GACFR_MBS0, _3COM_GACFR_NIM, _3COM_GACFR_RSEL, _3COM_GACFR_TCM, _3COM_PCFR, _3COM_PCFR_C8000, _3COM_PCFR_CC000, _3COM_PCFR_D8000, _3COM_PCFR_DC000, _3COM_PCFR_PIO, _3COM_PSPR, _3COM_PSTR, _3COM_VPTR0, _3COM_VPTR1, _3COM_VPTR2, addr, base, bus_to_virt(), c, D8390_COMMAND_RD2, D8390_COMMAND_STP, D8390_DCR_FT1, D8390_DCR_LS, D8390_DCR_WTS, D8390_P0_COMMAND, D8390_P0_DCR, D8390_P0_PSTART, D8390_P0_PSTOP, D8390_P0_RCR, D8390_RCR_MON, D8390_TXBUF_SIZE, DBG, ETH_ALEN, eth_asic_base, eth_bmem, eth_drain_receiver, eth_flags, eth_memsize, eth_nic_base, eth_ntoa(), eth_pio_read(), eth_pio_write(), eth_rmem, eth_rx_start, eth_tx_start, eth_vendor, FLAG_16BIT, FLAG_790, FLAG_PIO, nic::flags, GENERIC_ISAPNP_VENDOR, htons, inb(), nic::ioaddr, pci_device::ioaddr, nic::irqno, ISA_MAX_ADDR, MEM_16384, MEM_32768, MEM_8192, memcmp(), memset(), NE_ASIC_OFFSET, NE_RESET, nic::nic_op, nic::node_addr, ns8390_operations, ns8390_reset(), NULL, outb, printf(), test, TYPE_SMC8216C, TYPE_SMC8216T, TYPE_WD8013EP, VENDOR_3COM, VENDOR_NONE, VENDOR_NOVELL, VENDOR_WD, WD_BID, WD_DEFAULT_MEM, WD_HIGH_BASE, WD_ICR, WD_ICR_16BIT, WD_LAAR, WD_LAAR_L16EN, WD_LAAR_M16EN, WD_LAR, WD_LOW_BASE, WD_MSR, WD_MSR_MENB, WD_NIC_ADDR, and WD_SOFTCONFIG.