diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2009-02-25 12:22:06 -0800 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2009-02-25 12:22:06 -0800 |
commit | a36e4f0cab6311110d1703eafb325baead9caff8 (patch) | |
tree | 09c0bda0639ea2ee36fb8f49563863dfad5dc32b /drivers/ide/atiixp.c | |
parent | 0b0a0806b0d8635e046bf533225a25903b1cddce (diff) | |
parent | 8fed43684174b68f04d01d1210fd00536af790df (diff) |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/bart/ide-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/bart/ide-2.6:
ide: fix refcounting in device drivers
ide-cd: document capacity hack
it821x: remove dead URL
atiixp: fix missing parentheses
amd74xx: device/vendor confusion
ide: ide.c 'clear' fix, update "ide=nodma" documentation
Diffstat (limited to 'drivers/ide/atiixp.c')
-rw-r--r-- | drivers/ide/atiixp.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/ide/atiixp.c b/drivers/ide/atiixp.c index b2735d28f5c..ecd1e62ca91 100644 --- a/drivers/ide/atiixp.c +++ b/drivers/ide/atiixp.c @@ -52,7 +52,7 @@ static void atiixp_set_pio_mode(ide_drive_t *drive, const u8 pio) { struct pci_dev *dev = to_pci_dev(drive->hwif->dev); unsigned long flags; - int timing_shift = (drive->dn & 2) ? 16 : 0 + (drive->dn & 1) ? 0 : 8; + int timing_shift = (drive->dn ^ 1) * 8; u32 pio_timing_data; u16 pio_mode_data; @@ -85,7 +85,7 @@ static void atiixp_set_dma_mode(ide_drive_t *drive, const u8 speed) { struct pci_dev *dev = to_pci_dev(drive->hwif->dev); unsigned long flags; - int timing_shift = (drive->dn & 2) ? 16 : 0 + (drive->dn & 1) ? 0 : 8; + int timing_shift = (drive->dn ^ 1) * 8; u32 tmp32; u16 tmp16; u16 udma_ctl = 0; |