Skip to content

Commit

Permalink
pata_cmd64x: fix handling of address setup timings
Browse files Browse the repository at this point in the history
Account for the requirements of the DMA mode currently used
by the pair device.

Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
  • Loading branch information
Bartlomiej Zolnierkiewicz authored and Jeff Garzik committed Mar 1, 2010
1 parent a2bd622 commit d62f557
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions drivers/ata/pata_cmd64x.c
Original file line number Diff line number Diff line change
Expand Up @@ -131,8 +131,14 @@ static void cmd64x_set_timing(struct ata_port *ap, struct ata_device *adev, u8 m

if (pair) {
struct ata_timing tp;

ata_timing_compute(pair, pair->pio_mode, &tp, T, 0);
ata_timing_merge(&t, &tp, &t, ATA_TIMING_SETUP);
if (pair->dma_mode) {
ata_timing_compute(pair, pair->dma_mode,
&tp, T, 0);
ata_timing_merge(&tp, &t, &t, ATA_TIMING_SETUP);
}
}
}

Expand Down

0 comments on commit d62f557

Please sign in to comment.