]> git.itanic.dy.fi Git - linux-stable/commit
scsi: sd: Defer spinning up drive while SANITIZE is in progress
authorMahesh Rajashekhara <mahesh.rajashekhara@microsemi.com>
Tue, 17 Apr 2018 11:33:12 +0000 (17:03 +0530)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 1 May 2018 22:13:07 +0000 (15:13 -0700)
commitdbf1c17b6c2d4249d31a7b2516cdc2881c0a4860
tree218f31c438111d9300aea1defda914b0d93d13dd
parent6ab441353d668f98b98c6710e2024e6a777c9241
scsi: sd: Defer spinning up drive while SANITIZE is in progress

commit 505aa4b6a8834a2300971c5220c380c3271ebde3 upstream.

A drive being sanitized will return NOT READY / ASC 0x4 / ASCQ
0x1b ("LOGICAL UNIT NOT READY. SANITIZE IN PROGRESS").

Prevent spinning up the drive until this condition clears.

[mkp: tweaked commit message]

Signed-off-by: Mahesh Rajashekhara <mahesh.rajashekhara@microsemi.com>
Cc: <stable@vger.kernel.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/scsi/sd.c