|
@@ -319,18 +319,18 @@ static ide_hwif_t *ide_hwif_configure(struct pci_dev *dev,
|
|
|
|
|
|
ctl = pci_resource_start(dev, 2*port+1);
|
|
|
base = pci_resource_start(dev, 2*port);
|
|
|
- if ((ctl && !base) || (base && !ctl)) {
|
|
|
- printk(KERN_ERR "%s: inconsistent baseregs (BIOS) "
|
|
|
- "for port %d, skipping\n", d->name, port);
|
|
|
- return NULL;
|
|
|
- }
|
|
|
- }
|
|
|
- if (!ctl) {
|
|
|
+ } else {
|
|
|
/* Use default values */
|
|
|
ctl = port ? 0x374 : 0x3f4;
|
|
|
base = port ? 0x170 : 0x1f0;
|
|
|
}
|
|
|
|
|
|
+ if (!base || !ctl) {
|
|
|
+ printk(KERN_ERR "%s: bad PCI BARs for port %d, skipping\n",
|
|
|
+ d->name, port);
|
|
|
+ return NULL;
|
|
|
+ }
|
|
|
+
|
|
|
hwif = ide_find_port_slot(d);
|
|
|
if (hwif == NULL) {
|
|
|
printk(KERN_ERR "%s: too many IDE interfaces, no room in "
|