Commit b6f0e756 authored by Arthur Simchaev's avatar Arthur Simchaev Committed by Bart Van Assche
Browse files

FROMGIT: scsi: ufs: core: Remove ufshcd_map_desc_id_to_length()



There shouldn't be any restriction of the descriptor size (not the
descriptor id for that matter) up to QUERY_DESC_MAX_SIZE.  According to the
spec, the caller can use any descriptor size, and it is up to the device to
return the actual size.  Therefore there shouldn't be any sizes hardcoded
in the kernel, nor any need to cache it, hence the
ufshcd_map_desc_id_to_length() function is redundant. Always read the
descriptors with QUERY_DESC_MAX_SIZE size.

Reviewed-by: default avatarBart Van Assche <bvanassche@acm.org>
Reviewed-by: default avatarBean Huo <beanhuo@micron.com>
Suggested-by: default avatarBean Huo <beanhuo@micron.com>
Change-Id: I7933da0b7ec3771b9faccb2c8fe05bb83f741162
Signed-off-by: default avatarArthur Simchaev <Arthur.Simchaev@wdc.com>
Signed-off-by: default avatarMartin K. Petersen <martin.petersen@oracle.com>
Bug: 258234315
(cherry picked from commit 16ed9d31 git://git.kernel.org/pub/scm/linux/kernel/git/mkp/scsi.git

 for-next)
Signed-off-by: default avatarBart Van Assche <bvanassche@google.com>
parent dc7535fe
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment