Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 185803
b: refs/heads/master
c: 5740345
h: refs/heads/master
i:
  185801: 56ca48f
  185799: 5648ed5
v: v3
  • Loading branch information
Bartlomiej Zolnierkiewicz authored and David S. Miller committed Jan 19, 2010
1 parent a98f77c commit 23b40b8
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 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: cde727be967a86aee01042f35c8a861728272cf1
refs/heads/master: 5740345b877e2c8745cdf454674b45919679f231
9 changes: 7 additions & 2 deletions trunk/drivers/ide/alim15x3.c
Original file line number Diff line number Diff line change
Expand Up @@ -84,14 +84,18 @@ static void ali_set_pio_mode(ide_hwif_t *hwif, ide_drive_t *drive)
struct ide_timing p;

ide_timing_compute(pair, pair->pio_mode, &p, T, 1);
ide_timing_merge(&p, &t, &t, IDE_TIMING_SETUP);
ide_timing_merge(&p, &t, &t,
IDE_TIMING_SETUP | IDE_TIMING_8BIT);
if (pair->dma_mode) {
ide_timing_compute(pair, pair->dma_mode, &p, T, 1);
ide_timing_merge(&p, &t, &t, IDE_TIMING_SETUP);
ide_timing_merge(&p, &t, &t,
IDE_TIMING_SETUP | IDE_TIMING_8BIT);
}
}

t.setup = clamp_val(t.setup, 1, 8) & 7;
t.act8b = clamp_val(t.act8b, 1, 8) & 7;
t.rec8b = clamp_val(t.rec8b, 1, 16) & 15;
t.active = clamp_val(t.active, 1, 8) & 7;
t.recover = clamp_val(t.recover, 1, 16) & 15;

Expand All @@ -101,6 +105,7 @@ static void ali_set_pio_mode(ide_hwif_t *hwif, ide_drive_t *drive)
ali_fifo_control(hwif, drive, (drive->media == ide_disk) ? 0x05 : 0x00);

pci_write_config_byte(dev, port, t.setup);
pci_write_config_byte(dev, port + 1, (t.act8b << 4) | t.rec8b);
pci_write_config_byte(dev, port + unit + 2,
(t.active << 4) | t.recover);
}
Expand Down

0 comments on commit 23b40b8

Please sign in to comment.