135 DBG (
"T509 found no available ID port\n" );
144 unsigned short lrs_state, i;
150 for ( i = 0; i < 255; i++ ) {
153 lrs_state = lrs_state & 0x100 ? lrs_state ^ 0xcf : lrs_state;
176 for ( i = 0; i < 16; i++ ) {
217 DBG (
"T509 saw %s signs of life\n",
223 for ( i = 0 ; i < 3 ; i++ ) {
229 DBG (
"T509 found card %04x%04x%04x, assigning tag %02x\n",
237 DBG (
"T509 found %d cards using ID port %04x\n",
254 DBG (
"T509 activated device %02x at ioaddr %04x\n",
272 DBG (
"T509 deactivated device at %04x and re-tagged as %02x\n",
316 DBG (
"Adding 3c509 device %02x (I/O %04x)\n",
329 DBG (
"Removed 3c509 device %02x\n", t509->
tag );
353 t509 =
malloc (
sizeof ( *t509 ) );
358 memset ( t509, 0,
sizeof ( *t509 ) );
369 t509->
ioaddr = 0x200 + ( ( iobase & 0x1f ) << 4 );
static int t509bus_probe(struct root_device *rootdev)
Probe 3c509 root bus.
struct arbelprm_rc_send_wqe rc
static void activate_t509_device(struct t509_device *t509)
uint16_t inw(volatile uint16_t *io_addr)
Read 16-bit word from I/O-mapped device.
uint16_t ioaddr
I/O address.
#define list_add(new, head)
Add a new entry to the head of a list.
static void t509_reset_tag(void)
static int t509_find_id_port(void)
void t5x9_disable(struct nic *nic)
static void t509_deactivate_and_reset_tag(uint16_t ioaddr)
struct root_device t509_root_device __root_device
3c509 bus root device
#define ENOENT
No such file or directory.
struct device dev
Device chain.
unsigned int vendor
Vendor ID.
struct device * parent
Bus device.
static void * t509_get_drvdata(struct t509_device *t509)
Get 3c509 driver-private data.
static void t509_remove(struct t509_device *t509)
Remove a 3c509 device.
#define list_del(list)
Delete an entry from a list.
#define ENOMEM
Not enough space.
static void deactivate_t509_device(struct t509_device *t509)
#define BUS_TYPE_ISA
ISA bus type.
static unsigned long ioaddr
static struct root_driver t509_root_driver
3c509 bus root device driver
static void t509bus_remove(struct root_device *rootdev)
Remove 3c509 root bus.
void udelay(unsigned long usecs)
Delay for a fixed number of microseconds.
static void * legacy_t509_get_drvdata(void *hwdev)
static uint16_t t509_id_read_eeprom(int offset)
static void legacy_t509_set_drvdata(void *hwdev, void *priv)
#define list_for_each_entry_safe(pos, tmp, head, member)
Iterate over entries in a list, safe against deletion of the current entry.
static int legacy_t509_probe(struct nic *nic, void *hwdev)
static unsigned int t509_max_tag
static void t509_load_eeprom_word(uint8_t offset)
static void(* free)(struct refcnt *refcnt))
static void t509_select_tag(uint8_t tag)
struct list_head siblings
Devices on the same bus.
static void t509_set_drvdata(struct t509_device *t509, void *priv)
Set 3c509 driver-private data.
uint8_t inb(volatile uint8_t *io_addr)
Read byte from I/O-mapped device.
int(* probe)(struct root_device *rootdev)
Add root device.
void * malloc(size_t size)
Allocate memory.
static void t509_set_id_port(void)
void legacy_remove(void *hwdev, void *(*get_drvdata)(void *hwdev), void(*disable)(struct nic *nic, void *hwdev))
#define INIT_LIST_HEAD(list)
Initialise a list head.
#define ISA_PROD_ID(product)
static int t509_probe(struct t509_device *t509)
Probe a 3c509 device.
#define outb(data, io_addr)
static void t509_activate(uint16_t ioaddr)
unsigned int bus_type
Bus type.
static void t509_set_tag(uint8_t tag)
static struct tlan_private * priv
unsigned int device
Device ID.
struct list_head children
Devices attached to this device.
uint8_t data[48]
Additional event data.
struct device_description desc
Device description.
int snprintf(char *buf, size_t size, const char *fmt,...)
Write a formatted string to a buffer.
static int t509_isolate(void)
void * priv
Driver-private data.
static void t509_send_id_sequence(void)
uint16_t offset
Offset to command line.
static void t509_global_reset(void)
int t5x9_probe(struct nic *nic, uint16_t prod_id_check, uint16_t prod_id_mask)
static void t509_wait_for_id_sequence(void)
#define DBG(...)
Print a debugging message.
static void legacy_t509_disable(struct nic *nic, void *hwdev)
static unsigned int t509_id_port
uint64_t tag
Identity tag.
ISA_ROM("3c509", "3c509")
#define NULL
NULL pointer (VOID *)
struct device dev
Generic device.
void * memset(void *dest, int character, size_t len) __nonnull
int legacy_probe(void *hwdev, void(*set_drvdata)(void *hwdev, void *priv), struct device *dev, int(*probe)(struct nic *nic, void *hwdev), void(*disable)(struct nic *nic, void *hwdev))