diff options
| author | Alan Cox <alan@lxorguk.ukuu.org.uk> | 2003-02-17 19:49:02 -0800 |
|---|---|---|
| committer | Linus Torvalds <torvalds@home.transmeta.com> | 2003-02-17 19:49:02 -0800 |
| commit | 04f8ba9564f98ca99ecc0435e229cedcbc098e28 (patch) | |
| tree | 33a76532d4a98f8c4773ca475d9d152e8916659e | |
| parent | dbc9f2a60102c5e92c1314463beed7059508c24b (diff) | |
[PATCH] part fix the highpoint timing/overclock bug
| -rw-r--r-- | drivers/ide/pci/hpt366.c | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/drivers/ide/pci/hpt366.c b/drivers/ide/pci/hpt366.c index cdc467276378..974d7a56093c 100644 --- a/drivers/ide/pci/hpt366.c +++ b/drivers/ide/pci/hpt366.c @@ -1,5 +1,5 @@ /* - * linux/drivers/ide/hpt366.c Version 0.34 Sept 17, 2002 + * linux/drivers/ide/pci/hpt366.c Version 0.34 Sept 17, 2002 * * Copyright (C) 1999-2002 Andre Hedrick <andre@linux-ide.org> * Portions Copyright (C) 2001 Sun Microsystems, Inc. @@ -807,7 +807,7 @@ static int __init init_hpt37x(struct pci_dev *dev) } else if (freq < 0xc8) { pll = F_LOW_PCI_50; if (hpt_minimum_revision(dev,8)) - return -EOPNOTSUPP; + pci_set_drvdata(dev, NULL); else if (hpt_minimum_revision(dev,5)) pci_set_drvdata(dev, (void *) fifty_base_hpt372); else if (hpt_minimum_revision(dev,4)) @@ -820,7 +820,7 @@ static int __init init_hpt37x(struct pci_dev *dev) if (hpt_minimum_revision(dev,8)) { printk(KERN_ERR "HPT37x: 66MHz timings are not supported.\n"); - return -EOPNOTSUPP; + pci_set_drvdata(dev, NULL); } else if (hpt_minimum_revision(dev,5)) pci_set_drvdata(dev, (void *) sixty_six_base_hpt372); @@ -923,7 +923,7 @@ static int __init init_hpt366 (struct pci_dev *dev) if (!pci_get_drvdata(dev)) { printk(KERN_ERR "hpt366: unknown bus timing.\n"); - return -EOPNOTSUPP; + pci_set_drvdata(dev, NULL); } return 0; } @@ -1061,6 +1061,12 @@ static void __init init_dma_hpt366 (ide_hwif_t *hwif, unsigned long dmabase) if (!dmabase) return; + + if(pci_get_drvdata(hwif->pci_dev) == NULL) + { + printk(KERN_WARNING "hpt: no known IDE timings, disabling DMA.\n"); + return; + } dma_old = hwif->INB(dmabase+2); |
