After upgrading to 4.12rc0 (also tested on all RC's 4.12, and 4.13 git), the following mtx commands fail on an ML6000 with LTO5 FC drive attached to a qlogic 2462 HBA. Running Ubuntu Server 16.04 mtx -f /dev/sg19 load 16 0 Loading media from Storage Element 16 into drive 0...mtx: Request Sense: Long Report=yes mtx: Request Sense: Valid Residual=no mtx: Request Sense: Error Code=0 (Unknown?!) mtx: Request Sense: Sense Key=No Sense mtx: Request Sense: FileMark=no mtx: Request Sense: EOM=no mtx: Request Sense: ILI=no mtx: Request Sense: Additional Sense Code = 00 mtx: Request Sense: Additional Sense Qualifier = 00 mtx: Request Sense: BPV=no mtx: Request Sense: Error in CDB=no mtx: Request Sense: SKSV=no MOVE MEDIUM from Element Address 4111 to 256 Failed Downgrading to 4.11.10 resolves the issue. The issue (and fix) has been replicated on a server running Fedora with an NEOs T48 with an LTO6 SAS drive attached to LSI 3008. Commit hash from latest version that works is - v4.11-4395-g89c9fea Sorry if anything here is formatted wrong, first bug report.
Fedora bug report is https://bugzilla.redhat.com/show_bug.cgi?id=1471302 I believe I've bisected this down to the following, but I've pretty much come to the end of my comprehension. commit 28676d869bbb5257b5f14c0c95ad3af3a7019dd5 Author: Johannes Thumshirn <jthumshirn@suse.de> Date: Fri Apr 7 09:34:15 2017 +0200 scsi: sg: check for valid direction before starting the request Check for a valid direction before starting the request, otherwise we risk running into an assertion in the scsi midlayer checking for valid requests. [mkp: fixed typo] Signed-off-by: Johannes Thumshirn <jthumshirn@suse.de> Link: http://www.spinics.net/lists/linux-scsi/msg104400.html Reported-by: Dmitry Vyukov <dvyukov@google.com> Signed-off-by: Hannes Reinecke <hare@suse.com> Tested-by: Johannes Thumshirn <jthumshirn@suse.de> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
I've confirmed that reverting just that patch fixes the problem.
Created attachment 257725 [details] Patch fixing this issue The attached patch was committed to the scsi-fixes tree so it should hopefully be in 4.13 soon. This was also sent to the stable tree so with luck it will appear in a 4.12 point release.
Fixed by commit ID f930c7043663188429cd9b254e9d761edfc101ce in July, 2017.