Commit 79a43ee6 authored by Douglas Gilbert's avatar Douglas Gilbert Committed by Greg Kroah-Hartman
Browse files

scsi: core: Handle depopulation and restoration in progress



[ Upstream commit 2bbeb8d1 ]

The default handling of the NOT READY sense key is to wait for the device
to become ready. The "wait" is assumed to be relatively short. However
there is a sub-class of NOT READY that have the "... in progress" phrase in
their additional sense code and these can take much longer.  Following on
from commit 505aa4b6 ("scsi: sd: Defer spinning up drive while SANITIZE
is in progress") we now have element depopulation and restoration that can
take a long time.  For example, over 24 hours for a 20 TB, 7200 rpm hard
disk to depopulate 1 of its 20 elements.

Add handling of ASC/ASCQ: 0x4,0x24 (depopulation in progress)
and ASC/ASCQ: 0x4,0x25 (depopulation restoration in progress)
to sd.c . The scsi_lib.c has incomplete handling of these
two messages, so complete it.

Signed-off-by: default avatarDouglas Gilbert <dgilbert@interlog.com>
Link: https://lore.kernel.org/r/20231015050650.131145-1-dgilbert@interlog.com


Signed-off-by: default avatarMartin K. Petersen <martin.petersen@oracle.com>
Stable-dep-of: 9ff7c383 ("scsi: core: Do not retry I/Os during depopulation")
Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
parent 5c1e84bc
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment