Skip to content
Commit d0c89af3 authored by Bao D. Nguyen's avatar Bao D. Nguyen Committed by Martin K. Petersen
Browse files

scsi: ufs: mcq: Fix the search/wrap around logic



The search and wrap around logic in the ufshcd_mcq_sqe_search() function
does not work correctly when the hwq's queue depth is not a power of two
number. Correct it so that any queue depth with a positive integer value
within the supported range would work.

Signed-off-by: default avatar"Bao D. Nguyen" <quic_nguyenb@quicinc.com>
Link: https://lore.kernel.org/r/ff49c15be205135ed3ec186f3086694c02867dbd.1692149603.git.quic_nguyenb@quicinc.com


Reviewed-by: default avatarBart Van Assche <bvanassche@acm.org>
Fixes: 8d729034 ("scsi: ufs: mcq: Add supporting functions for MCQ abort")
Signed-off-by: default avatarMartin K. Petersen <martin.petersen@oracle.com>
parent ef222f55
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment