mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-09-03 17:40:04 +00:00
cmd64x: convert to use ide_timing_find_mode()
There should be no functional changes caused by this patch. Acked-by: Sergei Shtylyov <sshtylyov@ru.mvista.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
This commit is contained in:
parent
17b500de0a
commit
86a0e12fcb
2 changed files with 4 additions and 3 deletions
|
@ -495,6 +495,7 @@ config BLK_DEV_ATIIXP
|
||||||
|
|
||||||
config BLK_DEV_CMD64X
|
config BLK_DEV_CMD64X
|
||||||
tristate "CMD64{3|6|8|9} chipset support"
|
tristate "CMD64{3|6|8|9} chipset support"
|
||||||
|
select IDE_TIMINGS
|
||||||
select BLK_DEV_IDEDMA_PCI
|
select BLK_DEV_IDEDMA_PCI
|
||||||
help
|
help
|
||||||
Say Y here if you have an IDE controller which uses any of these
|
Say Y here if you have an IDE controller which uses any of these
|
||||||
|
|
|
@ -116,6 +116,7 @@ static void cmd64x_tune_pio(ide_drive_t *drive, const u8 pio)
|
||||||
{
|
{
|
||||||
ide_hwif_t *hwif = HWIF(drive);
|
ide_hwif_t *hwif = HWIF(drive);
|
||||||
struct pci_dev *dev = to_pci_dev(hwif->dev);
|
struct pci_dev *dev = to_pci_dev(hwif->dev);
|
||||||
|
struct ide_timing *t = ide_timing_find_mode(XFER_PIO_0 + pio);
|
||||||
unsigned int cycle_time;
|
unsigned int cycle_time;
|
||||||
u8 setup_count, arttim = 0;
|
u8 setup_count, arttim = 0;
|
||||||
|
|
||||||
|
@ -124,10 +125,9 @@ static void cmd64x_tune_pio(ide_drive_t *drive, const u8 pio)
|
||||||
|
|
||||||
cycle_time = ide_pio_cycle_time(drive, pio);
|
cycle_time = ide_pio_cycle_time(drive, pio);
|
||||||
|
|
||||||
program_cycle_times(drive, cycle_time,
|
program_cycle_times(drive, cycle_time, t->active);
|
||||||
ide_pio_timings[pio].active_time);
|
|
||||||
|
|
||||||
setup_count = quantize_timing(ide_pio_timings[pio].setup_time,
|
setup_count = quantize_timing(t->setup,
|
||||||
1000 / (ide_pci_clk ? ide_pci_clk : 33));
|
1000 / (ide_pci_clk ? ide_pci_clk : 33));
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|
Loading…
Reference in a new issue