diff options
Diffstat (limited to 'drivers/ide/pci/via82cxxx.c')
-rw-r--r-- | drivers/ide/pci/via82cxxx.c | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/drivers/ide/pci/via82cxxx.c b/drivers/ide/pci/via82cxxx.c index d21dd2e7eeb3..27e92fb9f95e 100644 --- a/drivers/ide/pci/via82cxxx.c +++ b/drivers/ide/pci/via82cxxx.c | |||
@@ -237,16 +237,14 @@ static int via82cxxx_ide_dma_check (ide_drive_t *drive) | |||
237 | static struct via_isa_bridge *via_config_find(struct pci_dev **isa) | 237 | static struct via_isa_bridge *via_config_find(struct pci_dev **isa) |
238 | { | 238 | { |
239 | struct via_isa_bridge *via_config; | 239 | struct via_isa_bridge *via_config; |
240 | u8 t; | ||
241 | 240 | ||
242 | for (via_config = via_isa_bridges; via_config->id; via_config++) | 241 | for (via_config = via_isa_bridges; via_config->id; via_config++) |
243 | if ((*isa = pci_get_device(PCI_VENDOR_ID_VIA + | 242 | if ((*isa = pci_get_device(PCI_VENDOR_ID_VIA + |
244 | !!(via_config->flags & VIA_BAD_ID), | 243 | !!(via_config->flags & VIA_BAD_ID), |
245 | via_config->id, NULL))) { | 244 | via_config->id, NULL))) { |
246 | 245 | ||
247 | pci_read_config_byte(*isa, PCI_REVISION_ID, &t); | 246 | if ((*isa)->revision >= via_config->rev_min && |
248 | if (t >= via_config->rev_min && | 247 | (*isa)->revision <= via_config->rev_max) |
249 | t <= via_config->rev_max) | ||
250 | break; | 248 | break; |
251 | pci_dev_put(*isa); | 249 | pci_dev_put(*isa); |
252 | } | 250 | } |
@@ -404,10 +402,9 @@ static unsigned int __devinit init_chipset_via82cxxx(struct pci_dev *dev, const | |||
404 | * Print the boot message. | 402 | * Print the boot message. |
405 | */ | 403 | */ |
406 | 404 | ||
407 | pci_read_config_byte(isa, PCI_REVISION_ID, &t); | ||
408 | printk(KERN_INFO "VP_IDE: VIA %s (rev %02x) IDE %sDMA%s " | 405 | printk(KERN_INFO "VP_IDE: VIA %s (rev %02x) IDE %sDMA%s " |
409 | "controller on pci%s\n", | 406 | "controller on pci%s\n", |
410 | via_config->name, t, | 407 | via_config->name, isa->revision, |
411 | via_config->udma_mask ? "U" : "MW", | 408 | via_config->udma_mask ? "U" : "MW", |
412 | via_dma[via_config->udma_mask ? | 409 | via_dma[via_config->udma_mask ? |
413 | (fls(via_config->udma_mask) - 1) : 0], | 410 | (fls(via_config->udma_mask) - 1) : 0], |