/* Iterate through any ISA probe addresses specified by
* config.c, starting where we left off.
*/
+ DBG ( "ISA searching for device matching driver %s\n", driver->name );
for ( i = isa->probe_idx ; i < isa_extra_probe_addr_count ; i++ ) {
/* If we've already used this device, skip it */
if ( isa->already_tried ) {
notfound:
/* No device found */
+ DBG ( "ISA found no device matching driver %s\n", driver->name );
isa->probe_idx = 0;
return 0;
/* Iterate through all possible ISAPNP CSNs, starting where we
* left off.
*/
+ DBG ( "ISAPnP searching for device matching driver %s\n",
+ driver->name );
for ( ; isapnp->csn <= isapnp_max_csn ; isapnp->csn++ ) {
for ( ; isapnp->logdev <= 0xff ; isapnp->logdev++ ) {
/* If we've already used this device, skip it */
if ( ( isapnp->vendor_id == id->vendor_id ) &&
( ISA_PROD_ID ( isapnp->prod_id ) ==
ISA_PROD_ID ( id->prod_id ) ) ) {
- DBG ( "Device %s (driver %s) "
- "matches ID %s\n",
- id->name, driver->name,
+ DBG ( "ISAPnP found ID %hx:%hx "
+ "(\"%s\") (device %s) "
+ "matching driver %s\n",
+ isapnp->vendor_id,
+ isapnp->prod_id,
isa_id_string( isapnp->vendor_id,
- isapnp->prod_id ) );
+ isapnp->prod_id ),
+ id->name, driver->name );
isapnp->name = id->name;
isapnp->already_tried = 1;
return 1;
}
/* No device found */
+ DBG ( "ISAPnP found no device matching driver %s\n", driver->name );
isapnp->csn = 1;
return 0;
}
*
*/
static int fill_mca_device ( struct mca_device *mca ) {
- unsigned int i;
+ unsigned int i, seen_non_ff;
/* Make sure motherboard setup is off */
outb_p ( 0xff, MCA_MOTHERBOARD_SETUP_REG );
outb_p ( 0x8 | ( mca->slot & 0xf ), MCA_ADAPTER_SETUP_REG );
/* Read the POS registers */
+ seen_non_ff = 0;
for ( i = 0 ; i < ( sizeof ( mca->pos ) / sizeof ( mca->pos[0] ) ) ;
i++ ) {
mca->pos[i] = inb_p ( MCA_POS_REG ( i ) );
+ if ( mca->pos[i] != 0xff )
+ seen_non_ff = 1;
}
+
+ /* If all POS registers are 0xff, this means there's no device
+ * present
+ */
+ if ( ! seen_non_ff )
+ return 0;
/* Kill all setup modes */
outb_p ( 0, MCA_ADAPTER_SETUP_REG );
/* Iterate through all possible MCA slots, starting where we
* left off
*/
+ DBG ( "MCA searching for device matching driver %s\n", driver->name );
for ( ; mca->slot < MCA_MAX_SLOT_NR ; mca->slot++ ) {
/* If we've already used this device, skip it */
if ( mca->already_tried ) {
struct mca_id *id = &driver->ids[i];
if ( MCA_ID ( mca ) == id->id ) {
- DBG ( "Device %s (driver %s) matches ID %hx\n",
- id->name, driver->name, id->id );
+ DBG ( "MCA found ID %hx (device %s) "
+ "matching driver %s\n",
+ id->name, id->id, driver->name );
mca->name = id->name;
mca->already_tried = 1;
return 1;
}
/* No device found */
+ DBG ( "MCA found no device matching driver %s\n", driver->name );
mca->slot = 0;
return 0;
}