RE: [PATCH][IDE] small cleanup for AMD/nVidia IDE driver

From: Allen Martin
Date: Fri Oct 03 2003 - 14:53:26 EST


> I've seen 2.4.x patches from Allen Martin@nVidia on lkml.
> In UDMA133 patch he mentioned that UDMA should be programmed by mode,
> not UDMA cycle timing on nVidia chipsets (probably the same
> applies to AMD).
> Can you comment on this?

Yes, these controllers have a 1:1 mapping between UDMA mode and
AMD_UDMA_TIMING value. Trying to map UDMA mode to cycle time and then map
back to UDMA mode is error prone, and cause for some of the ugly workarounds
in the current driver. My patch to add Ultra133 support just expands this
ugliness, but works.

The mapping is as follows:

UDMA2 0
UDMA1 1
UDMA0 2
UDMA3 4
UDMA4 5
UDMA5 6
UDMA6 7

Other ACPI aware OS'es use an ACPI method to change IDE timing, so this is
hidden from the OS.

-Allen
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/