35 #ifdef ISA_PROBE_ADDRS 39 #define ISA_EXTRA_PROBE_ADDR_COUNT \ 40 ( sizeof ( isa_extra_probe_addrs ) / sizeof ( isa_extra_probe_addrs[0] ) ) 42 #define ISA_IOIDX_MIN( driver ) ( -ISA_EXTRA_PROBE_ADDR_COUNT ) 44 #define ISA_IOIDX_MAX( driver ) ( -1 ) 46 #define ISA_IOIDX_MAX( driver ) ( (int) (driver)->addr_count - 1 ) 49 #define ISA_IOADDR( driver, ioidx ) \ 50 ( ( (ioidx) >= 0 ) ? \ 51 (driver)->probe_addrs[(ioidx)] : \ 52 *( isa_extra_probe_addrs + (ioidx) + ISA_EXTRA_PROBE_ADDR_COUNT ) ) 65 DBG (
"Trying ISA driver %s at I/O %04x\n",
69 DBG (
"...probe failed\n" );
73 DBG (
"...device found\n" );
106 isa =
malloc (
sizeof ( *isa ) );
111 memset ( isa, 0,
sizeof ( *isa ) );
struct arbelprm_rc_send_wqe rc
uint16_t ioaddr
I/O address.
struct device dev
Generic device.
#define list_add(new, head)
Add a new entry to the head of a list.
uint16_t prod_id
Product ID to be assumed for this device.
int(* probe)(struct isa_device *isa)
Probe device.
#define ISA_IOADDR(driver, ioidx)
struct device dev
Device chain.
unsigned int vendor
Vendor ID.
struct device * parent
Bus device.
ISA probe address configuration.
uint16_t vendor_id
Manufacturer ID to be assumed for this device.
#define list_del(list)
Delete an entry from a list.
#define ENOMEM
Not enough space.
#define BUS_TYPE_ISA
ISA bus type.
uint16_t isa_probe_addr_t
static void isabus_remove(struct root_device *rootdev)
Remove ISA root bus.
const char * driver_name
Driver name.
#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 isa_probe(struct isa_device *isa)
Probe an ISA device.
static void(* free)(struct refcnt *refcnt))
struct list_head siblings
Devices on the same bus.
#define for_each_table_entry(pointer, table)
Iterate through all entries within a linker table.
#define ISA_DRIVERS
ISA driver table.
int(* probe)(struct root_device *rootdev)
Add root device.
void * malloc(size_t size)
Allocate memory.
void(* remove)(struct isa_device *isa)
Remove device.
#define INIT_LIST_HEAD(list)
Initialise a list head.
unsigned int bus_type
Bus type.
unsigned int device
Device ID.
struct list_head children
Devices attached to this device.
static void isa_remove(struct isa_device *isa)
Remove an ISA device.
struct device_description desc
Device description.
static isa_probe_addr_t isa_extra_probe_addrs[]
int snprintf(char *buf, size_t size, const char *fmt,...)
Write a formatted string to a buffer.
#define ISA_IOIDX_MAX(driver)
static int isabus_probe(struct root_device *rootdev)
Probe ISA root bus.
struct isa_driver * driver
Driver for this device.
#define DBG(...)
Print a debugging message.
static struct root_driver isa_root_driver
ISA bus root device driver.
#define ISA_IOIDX_MIN(driver)
struct root_device isa_root_device __root_device
ISA bus root device.
#define NULL
NULL pointer (VOID *)
FILE_LICENCE(GPL2_OR_LATER)
void * memset(void *dest, int character, size_t len) __nonnull