Skip to content
Commit 16ed9d31 authored by Arthur Simchaev's avatar Arthur Simchaev Committed by Martin K. Petersen
Browse files

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>
Signed-off-by: default avatarArthur Simchaev <Arthur.Simchaev@wdc.com>
Signed-off-by: default avatarMartin K. Petersen <martin.petersen@oracle.com>
parent 01a0d515
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment