[PATCH 1/1] libata: blacklist NCQ on WDC WD740ADFD-00NLR4

From: Simon J. Rowe
Date: Wed Jan 18 2012 - 06:03:23 EST


I've been seeing intermittent issues on my desktop (running 2.6.38.7) recently

Jan 16 20:54:08 gilraen kernel: ata5.00: exception Emask 0x10 SAct 0x807f SErr
0x400100 action 0x6 frozen
Jan 16 20:54:08 gilraen kernel: ata5.00: irq_stat 0x08000000, interface fatal
error
Jan 16 20:54:08 gilraen kernel: ata5: SError: { UnrecovData Handshk }
Jan 16 20:54:08 gilraen kernel: ata5.00: failed command: WRITE FPDMA QUEUED
Jan 16 20:54:08 gilraen kernel: ata5.00: cmd
61/d8:00:ef:13:d8/00:00:00:00:00/40 tag 0 ncq 110592 out
Jan 16 20:54:08 gilraen kernel: res
40/00:20:97:13:d8/00:00:00:00:00/40 Emask 0x10 (ATA bus error)
Jan 16 20:54:08 gilraen kernel: ata5.00: status: { DRDY }

The disk is a WD Raptor WD740 which I noticed has NCQ blacklisted. The exact
model isn't present in the blacklist so I added it (patch below). The errors
then came out slightly differently

Jan 16 21:17:08 gilraen kernel: ata5.00: exception Emask 0x10 SAct 0x0 SErr
0x400100 action 0x6 frozen
Jan 16 21:17:08 gilraen kernel: ata5.00: irq_stat 0x08000000, interface fatal
error
Jan 16 21:17:08 gilraen kernel: ata5: SError: { UnrecovData Handshk }
Jan 16 21:17:08 gilraen kernel: ata5.00: failed command: WRITE DMA EXT
Jan 16 21:17:08 gilraen kernel: ata5.00: cmd
35/00:68:6f:5d:9a/00:01:00:00:00/e0 tag 0 dma 184320 out
Jan 16 21:17:08 gilraen kernel: res
50/00:00:66:5d:9a/00:00:00:00:00/e0 Emask 0x10 (ATA bus error)
Jan 16 21:17:08 gilraen kernel: ata5.00: status: { DRDY }
Jan 16 21:17:08 gilraen kernel: ata5: hard resetting link
Jan 16 21:17:08 gilraen kernel: ata5: SATA link up 1.5 Gbps (SStatus 113
SControl 300)
Jan 16 21:17:08 gilraen kernel: ata5.00: configured for UDMA/133
Jan 16 21:17:08 gilraen kernel: ata5: EH complete

Googling revealed that this is often caused by faulty cabling. I moved the
power and SATA cables and the problem has now gone but I think the disk should
still be added to the blacklist,

Thanks
Simon