Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 105693
b: refs/heads/master
c: d51f19c
h: refs/heads/master
i:
  105691: d18e6fd
v: v3
  • Loading branch information
Bartlomiej Zolnierkiewicz committed Jul 24, 2008
1 parent 07d8be8 commit a81a25d
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 19 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: b16040b14e766d390138b04c8829c816f4c1d95b
refs/heads/master: d51f19c86583ca70468883d8137a92689f1a80c1
36 changes: 18 additions & 18 deletions trunk/drivers/ide/pci/amd74xx.c
Original file line number Diff line number Diff line change
Expand Up @@ -173,24 +173,6 @@ static unsigned int __devinit init_chipset_amd74xx(struct pci_dev *dev,
t |= 0xf0;
pci_write_config_byte(dev, AMD_IDE_CONFIG + offset, t);

/*
* Determine the system bus clock.
*/

amd_clock = (ide_pci_clk ? ide_pci_clk : 33) * 1000;

switch (amd_clock) {
case 33000: amd_clock = 33333; break;
case 37000: amd_clock = 37500; break;
case 41000: amd_clock = 41666; break;
}

if (amd_clock < 20000 || amd_clock > 50000) {
printk(KERN_WARNING "%s: User given PCI clock speed impossible (%d), using 33 MHz instead.\n",
name, amd_clock);
amd_clock = 33333;
}

return dev->irq;
}

Expand Down Expand Up @@ -302,6 +284,24 @@ static int __devinit amd74xx_probe(struct pci_dev *dev, const struct pci_device_
d.name, pci_name(dev), dev->revision,
amd_dma[fls(d.udma_mask) - 1]);

/*
* Determine the system bus clock.
*/
amd_clock = (ide_pci_clk ? ide_pci_clk : 33) * 1000;

switch (amd_clock) {
case 33000: amd_clock = 33333; break;
case 37000: amd_clock = 37500; break;
case 41000: amd_clock = 41666; break;
}

if (amd_clock < 20000 || amd_clock > 50000) {
printk(KERN_WARNING "%s: User given PCI clock speed impossible"
" (%d), using 33 MHz instead.\n",
d.name, amd_clock);
amd_clock = 33333;
}

return ide_pci_init_one(dev, &d, NULL);
}

Expand Down

0 comments on commit a81a25d

Please sign in to comment.