Bug 7987

Summary: NCQ is not being detected or enabled on ICH8R
Product: IO/Storage Reporter: Michael Cronenworth (mike)
Component: Serial ATAAssignee: Jeff Garzik (jgarzik)
Status: CLOSED CODE_FIX    
Severity: normal    
Priority: P2    
Hardware: i386   
OS: Linux   
Kernel Version: 2.6.19-1.2895.fc6 Subsystem:
Regression: --- Bisected commit-id:

Description Michael Cronenworth 2007-02-11 12:24:19 UTC
Most recent kernel where this bug did *NOT* occur: none
Distribution: Fedora Core 6 x86_64
Hardware Environment: Asus P5B-E motherboard, Intel Core 2 Duo, 1gig DDR2,
Seagate 320gig 7200.10 SATA
Software Environment: FC6 packages, XFCE 4.4

Description of problem: I have an Asus P5B-E motherboard that has an i965
chipset with an ICH8R. I also have a Seagate 7200.10 320 gig S-ATA hard drive.
Both devices support NCQ. NCQ is only being enabled on the hard drive and not on
the host controller. I have a feeling that the "ahci" driver is seeing the
AsusTek Subsystem ID (see lspci below) and not enabling full support of my ICH8R.


Version-Release number of selected component (if applicable): 2.6.19-1.2895.fc6


How reproducible: Always


Steps to Reproduce:
1. Boot with AHCI or RAID configuration.
2. AHCI is detected, but NCQ is not.
3. NCQ is not enabled.
  
Actual results: NCQ disabled.


Expected results: NCQ enabled.


Additional info: 
lspci -vv
00:1f.2 RAID bus controller: Intel Corporation 82801HR/HO/HH (ICH8R/DO/DH) SATA
RAID Controller (rev 02)
        Subsystem: ASUSTeK Computer Inc. Unknown device 81ec
        Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr-
Stepping- SERR- FastB2B-
        Status: Cap+ 66MHz+ UDF- FastB2B+ ParErr- DEVSEL=medium >TAbort-
<TAbort- <MAbort- >SERR- <PERR-
        Latency: 0
        Interrupt: pin B routed to IRQ 2299
        Region 0: I/O ports at ec00 [size=8]
        Region 1: I/O ports at e880 [size=4]
        Region 2: I/O ports at e800 [size=8]
        Region 3: I/O ports at e480 [size=4]
        Region 4: I/O ports at e400 [size=32]
        Region 5: Memory at febff800 (32-bit, non-prefetchable) [size=2K]
        Capabilities: [80] Message Signalled Interrupts: 64bit- Queue=0/4 Enable+
                Address: fee01000  Data: 0099
        Capabilities: [70] Power Management version 3
                Flags: PMEClk- DSI- D1- D2- AuxCurrent=0mA
PME(D0-,D1-,D2-,D3hot+,D3cold-)
                Status: D0 PME-Enable- DSel=0 DScale=0 PME-
        Capabilities: [a8] #12 [0010]
---------------------------------------------
dmesg
libata version 2.00 loaded.
ahci 0000:00:1f.2: version 2.0
ACPI: PCI Interrupt 0000:00:1f.2[B] -> GSI 19 (level, low) -> IRQ 19
usb 3-1: device not accepting address 2, error -71
PCI: Setting latency timer of device 0000:00:1f.2 to 64
ahci 0000:00:1f.2: AHCI 0001.0100 32 slots 6 ports ? Gbps 0x3f impl RAID mode
ahci 0000:00:1f.2: flags: 64bit ilck stag led pmp pio 

The last line should be:
ahci 0000:00:1f.2: flags: 64bit ncq ilck stag led pmp pio 

Hard drive dmesg:
ata1: SATA link up 3.0 Gbps (SStatus 123 SControl 300)
ata1.00: ATA-7, max UDMA/133, 625142448 sectors: LBA48 NCQ (depth 0/32)

I posted this on the redhat bugzilla, but it seems they didn't care.
https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=223564
Comment 1 Michael Cronenworth 2007-03-12 18:40:19 UTC
Fixed for me in 2.6.20. Thanks...