2 #error multicast support is not yet implemented 144 printf(
"\ncs: EEPROM data from %hX for %hX:",off,
len);
146 for (i = 0; i <
len; i++) {
173 for (i = 0; i <
len; i++)
190 for (i = 79; i--; )
putchar(
' ');
197 unsigned int selfcontrol;
205 selfcontrol &= ~
HCB1;
243 printf(
" negotiating duplex... ");
252 printf(
"using full duplex");
254 printf(
"using half duplex");
263 static unsigned char testpacket[] = { 0,0,0,0,0,0, 0,0,0,0,0,0,
287 printf(
" sending test packet ");
333 unsigned long reset_tmo;
412 printf(
"cs: unable to send packet; retrying...\n");
423 for (sr = sr/2 - (s+1)/2 -
ETH_ALEN - 1; sr > 0; sr--)
431 printf(
"\ntransmission error %#hX\n", s);
450 if ( ! retrieve )
return 1;
502 unsigned rev_type = 0, isa_cnf, cs_revision;
513 printf(
"\ncs: cs89%c0%s rev %c, base %#hX",
521 printf(
"\ncs: no EEPROM...\n");
526 printf(
"\ncs: EEPROM read failed...\n");
531 printf(
"\ncs: EEPROM checksum bad...\n");
569 if (i < 4) i =
"\012\013\014\005"[i];
570 else printf(
"\ncs: BUG: isa_config is %d\n", i); }
586 unsigned char MAC_HW_ADDR[6]={MAC_HW_ADDR_DRV};
617 printf(
"cs: EEPROM is configured for unavailable media\n");
634 printf(
"10Base-T (RJ-45%s",
635 ") has no cable\n"); }
646 ") has no cable\n"); }
657 ") has no cable\n"); }
679 case 0:
printf(
"no network cable attached to configured media\n");
714 0x300, 0x320, 0x340, 0x200, 0x220, 0x240,
715 0x260, 0x280, 0x2a0, 0x2c0, 0x2e0,
717 0x301, 0x321, 0x341, 0x201, 0x221, 0x241,
718 0x261, 0x281, 0x2a1, 0x2c1, 0x2e1,
730 ISA_ROM (
"cs89x0",
"Crystal Semiconductor CS89x0" );
DRIVER("cs89x0", nic_driver, isa_driver, cs89x0_driver, cs89x0_probe, cs89x0_disable)
#define AUTO_NEG_CNF_OFFSET
#define A_CNF_LOW_RX_SQUELCH
#define TICKS_PER_SEC
Number of ticks per second.
int printf(const char *fmt,...)
Write a formatted string to the console.
uint16_t inw(volatile uint16_t *io_addr)
Read 16-bit word from I/O-mapped device.
static int detect_tp(void)
#define START_EEPROM_DATA
ISA_DRIVER(cs89x0_driver, cs89x0_probe_addrs, cs89x0_probe_addr, ISAPNP_VENDOR('C', 'S', 'C'), 0x0007)
#define outw(data, io_addr)
static unsigned short eth_cs_type
static int cs89x0_poll(struct nic *nic, int retrieve)
static unsigned short eth_linectl
#define A_CNF_MEDIA_10B_T
struct arbelprm_completion_with_error error
static int cs89x0_probe(struct nic *nic, struct isa_device *isa __unused)
static unsigned short eth_adapter_cnf
void outsw(volatile uint16_t *io_addr, const uint16_t *data, unsigned int count)
Write 16-bit words to I/O-mapped device.
uint32_t buffer
Buffer index (or NETVSC_RNDIS_NO_BUFFER)
int dummy_connect(struct nic *nic __unused)
static void cs89x0_transmit(struct nic *nic, const char *d, unsigned int t, unsigned int s, const char *p)
static void writereg(int portno, int value)
static unsigned long ioaddr
void * memcpy(void *dest, const void *src, size_t len) __nonnull
static int wait_eeprom_ready(void)
static void clrline(void)
static int readreg(int portno)
static unsigned short eth_auto_neg_cnf
pseudo_bit_t value[0x00020]
#define __unused
Declare a variable or data structure as unused.
uint16_t isa_probe_addr_t
static unsigned short eth_irqno
#define A_CNF_DC_DC_POLARITY
#define PP_CS8920_ISAMemB
#define PACKET_PAGE_OFFSET
#define ISAPNP_VENDOR(a, b, c)
static isa_probe_addr_t cs89x0_probe_addrs[]
static struct nic_operations cs89x0_operations
const char * eth_ntoa(const void *ll_addr)
Transcribe Ethernet address.
void insw(volatile uint16_t *io_addr, uint16_t *data, unsigned int count)
Read 16-bit words from I/O-mapped device.
ISA_ROM("cs89x0", "Crystal Semiconductor CS89x0")
#define ADAPTER_CNF_OFFSET
static void cs89x0_irq(struct nic *nic __unused, irq_action_t action __unused)
static void cs89x0_reset(struct nic *nic)
unsigned char * node_addr
#define outb(data, io_addr)
static int cs89x0_probe_addr(isa_probe_addr_t ioaddr)
#define EE_AUTO_NEG_ENABLE
static void control_dc_dc(int on_not_off)
static int get_eeprom_data(int off, int len, unsigned short *buffer)
static int send_test_pkt(struct nic *nic)
static void cs89x0_disable(struct nic *nic, struct isa_device *isa __unused)
#define A_CNF_MEDIA_10B_2
static unsigned short eth_nic_base
unsigned long currticks(void)
Get current system time in ticks.
#define DBG(...)
Print a debugging message.
struct nic_operations * nic_op
FILE_LICENCE(GPL2_ONLY)
Per an email message from Russ Nelson nelson@crynwr.com on 18 March 2008 this file is now licensed un...
int(* connect)(struct nic *)
int putchar(int character)
Write a single character to each console device.
#define A_CNF_EXTND_10B_2
static int detect_aui(struct nic *nic)
static unsigned long eth_mem_start
static int get_eeprom_chksum(int off __unused, int len, unsigned short *buffer)
static int detect_bnc(struct nic *nic)