Commit 9ec6dbd1 authored by James Bottomley's avatar James Bottomley Committed by Greg Kroah-Hartman
Browse files

SCSI: sd: handle bad lba in sense information



patch 366c246d in mainline.

Some devices report medium error locations incorrectly.  Add guards to
make sure the reported bad lba is actually in the request that caused
it.  Additionally remove the large case statment for sector sizes and
replace it with the proper u64 divisions.

Tested-by: default avatarMike Snitzer <snitzer@gmail.com>
Cc: Stable Tree <stable@kernel.org>
Cc: Tony Battersby <tonyb@cybernetics.com>
Signed-off-by: default avatarJames Bottomley <James.Bottomley@HansenPartnership.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
parent 4b30c359
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment