3
* This program is free software; you can redistribute it and/or
4
* modify it under the terms of the GNU General Public License as
5
* published by the Free Software Foundation; either version 2, or (at
6
* your option) any later version.
13
void isa_enumerate(void)
15
const struct isa_driver *driver;
16
for(driver = isa_drivers; driver < isa_drivers_end; driver++) {
17
printf("%s ", driver->name);
22
int isa_probe(struct dev *dev, const char *type_name)
25
* NIC probing is in the order the drivers were linked togeter.
26
* If for some reason you want to change the order,
27
* just change the order you list the drivers in.
29
struct isa_probe_state *state = &dev->state.isa;
31
printf("Probing isa %s...\n", type_name);
33
if (dev->how_probe == PROBE_FIRST) {
35
state->driver = isa_drivers;
40
if ((dev->how_probe != PROBE_AWAKE) && state->advance) {
46
if (state->driver >= isa_drivers_end)
49
if (state->driver->type != dev->type)
52
if (dev->how_probe != PROBE_AWAKE) {
56
printf("[%s]", state->driver->name);
58
dev->devid.bus_type = ISA_BUS_TYPE;
59
/* FIXME how do I handle dev->index + PROBE_AGAIN?? */
60
/* driver will fill in vendor and device IDs */
61
if (state->driver->probe(dev, state->driver->ioaddrs)) {
62
state->advance = (dev->index == -1);