scsi: ufs: mcq: Use active_reqs to check busy in clock scaling
authorAsutosh Das <quic_asutoshd@quicinc.com>
Wed, 8 Mar 2023 23:13:23 +0000 (15:13 -0800)
committerMartin K. Petersen <martin.petersen@oracle.com>
Fri, 10 Mar 2023 02:09:28 +0000 (21:09 -0500)
commitc6001025d53ab56d7159cf313313c6b5bd250380
tree4c71234c61e76af26deb21d7bc643b00fcc96388
parentbe03df3d4bfe7e8866d4aa43d62e648ffe884f5f
scsi: ufs: mcq: Use active_reqs to check busy in clock scaling

Multi Circular Queue doesn't use outstanding_reqs. However, the UFS clock
scaling functions use outstanding_reqs to determine if there are requests
pending. When MCQ is enabled, this check always returns false.

Hence use active_reqs to check if there are pending requests.

Fixes: eacb139b77ff ("scsi: ufs: core: mcq: Enable multi-circular queue")
Signed-off-by: Asutosh Das <quic_asutoshd@quicinc.com>
Reviewed-by: Manivannan Sadhasivam <mani@kernel.org>
Link: https://lore.kernel.org/r/a24e0d646aac70eae0fc5e05fac0c58bb7e6e680.1678317160.git.quic_asutoshd@quicinc.com
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
drivers/ufs/core/ufshcd.c