diff options
author | liuderong <liuderong@oppo.com> | 2024-12-06 15:29:42 +0800 |
---|---|---|
committer | Martin K. Petersen <martin.petersen@oracle.com> | 2024-12-09 21:49:08 -0500 |
commit | f103396ae31851d00b561ff9f8a32a441953ff8b (patch) | |
tree | bcaf5b7772aed7755c46dc08f0551ccdff10a3da /drivers/ufs/core/ufshcd.c | |
parent | 6918141d815acef056a0d10e966a027d869a922d (diff) | |
download | lwn-f103396ae31851d00b561ff9f8a32a441953ff8b.tar.gz lwn-f103396ae31851d00b561ff9f8a32a441953ff8b.zip |
scsi: ufs: core: Update compl_time_stamp_local_clock after completing a cqe
lrbp->compl_time_stamp_local_clock is set to zero after sending a sqe
but it is not updated after completing a cqe. Thus the printed
information in ufshcd_print_tr() will always be zero.
Update lrbp->cmpl_time_stamp_local_clock after completing a cqe.
Log sample:
ufshcd-qcom 1d84000.ufshc: UPIU[8] - issue time 8750227249 us
ufshcd-qcom 1d84000.ufshc: UPIU[8] - complete time 0 us
Fixes: c30d8d010b5e ("scsi: ufs: core: Prepare for completion in MCQ")
Reviewed-by: Bean Huo <beanhuo@micron.com>
Reviewed-by: Peter Wang <peter.wang@mediatek.com>
Signed-off-by: liuderong <liuderong@oppo.com>
Link: https://lore.kernel.org/r/1733470182-220841-1-git-send-email-liuderong@oppo.com
Reviewed-by: Avri Altman <avri.altman@wdc.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to 'drivers/ufs/core/ufshcd.c')
-rw-r--r-- | drivers/ufs/core/ufshcd.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/ufs/core/ufshcd.c b/drivers/ufs/core/ufshcd.c index b7ec5797d5ba..8a01e4393159 100644 --- a/drivers/ufs/core/ufshcd.c +++ b/drivers/ufs/core/ufshcd.c @@ -5556,6 +5556,7 @@ void ufshcd_compl_one_cqe(struct ufs_hba *hba, int task_tag, lrbp = &hba->lrb[task_tag]; lrbp->compl_time_stamp = ktime_get(); + lrbp->compl_time_stamp_local_clock = local_clock(); cmd = lrbp->cmd; if (cmd) { if (unlikely(ufshcd_should_inform_monitor(hba, lrbp))) |