ioat: Handle channel-fatal HW errors safely
authorcem <cem@FreeBSD.org>
Sat, 31 Oct 2015 20:38:06 +0000 (20:38 +0000)
committercem <cem@FreeBSD.org>
Sat, 31 Oct 2015 20:38:06 +0000 (20:38 +0000)
commit39d22b9678b8c571aab6902620c95907d5bef2db
treef60b5af17308168bbe0df04d1b3dc94dd38c0e56
parente2a4d8f5654b8edbc45d0bcaa35df70ebe0f1f05
ioat: Handle channel-fatal HW errors safely

Certain invalid operations trigger hardware error conditions.  Error
conditions that only halt one channel can be detected and recovered by
resetting the channel.  Error conditions that halt the whole device are
generally not recoverable.

Add a sysctl to inject channel-fatal HW errors,
'dev.ioat.<N>.force_hw_error=1'.

When a halt due to a channel error is detected, ioat(4) blocks new
operations from being queued on the channel, completes any outstanding
operations with an error status, and resets the channel before allowing
new operations to be queued again.

Update ioat.4 to document error recovery;  document blockfill introduced
in r290021 while we are here;  document ioat_put_dmaengine() added in
r289907;  document DMA_NO_WAIT added in r289982.

Sponsored by: EMC / Isilon Storage Division
share/man/man4/ioat.4
sys/dev/ioat/ioat.c
sys/dev/ioat/ioat.h
sys/dev/ioat/ioat_hw.h
sys/dev/ioat/ioat_internal.h
sys/dev/ioat/ioat_test.c