Bug 58014

Summary: 2.4.16-0.13 kernel still enforces UDMA=2 for via chipsets
Product: [Retired] Red Hat Raw Hide Reporter: pogosyan
Component: kernelAssignee: Dave Jones <davej>
Status: CLOSED WONTFIX QA Contact: Brian Brock <bbrock>
Severity: medium Docs Contact:
Priority: medium    
Version: 1.0CC: db, pfrields
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2004-10-30 03:23:55 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description pogosyan 2002-01-05 19:33:07 UTC
Description of Problem:
For VIA IDE chipsets (in my case VT8233) kernel still enforces
cable type 40w even when 80w is present, thus limiting mode to UDMA2.
This behavior was introduced in 2.4.2 (see bug 35274) as safeguard
against VIA bugs.  These VIA bugs have recently been resolved, 
but the limitation remained in the kernel.
I think this is unneeded nowadays.

Forcing higher UDMA mode with ideX=ata66 boot option works
(although cable is still displayed as 40w by /proc/ide/via )


Version-Release number of selected component (if applicable):
2.4.16-0.13

How Reproducible:
always

Steps to Reproduce:
1. boot on machine with ATA100 drive and 80w cable
2. see UDMA mode set
3. 

Actual Results:


Expected Results:


Additional Information:

Comment 1 Arjan van de Ven 2002-01-05 19:39:37 UTC
Unfortionatly it's not just against the via bug; sometimes the cabletype is
misdetected and the result is corruption... right now it's "better safe than
sorry"

Comment 2 pogosyan 2002-01-05 19:50:28 UTC
I see. 

BTW, is it all in a single line #436 in via82cxxx.c ?
(in __init pci_init_via82cxxx subroutine) 

----------
/*
 * Check 80-wire cable presence and setup Clk66.
 */

	switch (via_config->flags & VIA_UDMA) {

		case VIA_UDMA_100:

			pci_read_config_dword(dev, VIA_UDMA_TIMING, &u);
			for (i = 24; i >= 0; i -= 8)
				if (((u >> i) & 0x10) || (((u >> i) & 0x20) && (((u >> i) & 7) < 3)))
					via_80w |= (1 << (1 - (i >> 4)));	/* BIOS 80-wire bit or UDMA w/ <
50ns/cycle */
			break;

		case VIA_UDMA_66:

			pci_read_config_dword(dev, VIA_UDMA_TIMING, &u);	/* Enable Clk66 */
			pci_write_config_dword(dev, VIA_UDMA_TIMING, u | 0x80008);
			for (i = 24; i >= 0; i -= 8)
				if (((u >> (i & 16)) & 8) && ((u >> i) & 0x20) && (((u >> i) & 7) < 2))
					via_80w |= (1 << (1 - (i >> 4)));	/* 2x PCI clock and UDMA w/ < 3T/cycle */
			break;
	}
        via_80w = 0;     <--------- line 436

	if (via_config->flags & VIA_BAD_CLK66) {
-----------------------