Patch "scsi: ufs: core: Fix MCQ MAC configuration" has been added to the 6.6-stable tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is a note to let you know that I've just added the patch titled

    scsi: ufs: core: Fix MCQ MAC configuration

to the 6.6-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     scsi-ufs-core-fix-mcq-mac-configuration.patch
and it can be found in the queue-6.6 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.



commit 654d6301d1a85f5a5ac97c0361172cf4c77dd633
Author: Rohit Ner <rohitner@xxxxxxxxxx>
Date:   Tue Feb 20 01:56:37 2024 -0800

    scsi: ufs: core: Fix MCQ MAC configuration
    
    [ Upstream commit 767712f91de76abd22a45184e6e3440120b8bfce ]
    
    As per JEDEC Standard No. 223E Section 5.9.2, the max # active commands
    value programmed by the host sw in MCQConfig.MAC should be one less than
    the actual value.
    
    Signed-off-by: Rohit Ner <rohitner@xxxxxxxxxx>
    Link: https://lore.kernel.org/r/20240220095637.2900067-1-rohitner@xxxxxxxxxx
    Reviewed-by: Peter Wang <peter.wang@xxxxxxxxxxxx>
    Reviewed-by: Can Guo <quic_cang@xxxxxxxxxxx>
    Signed-off-by: Martin K. Petersen <martin.petersen@xxxxxxxxxx>
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

diff --git a/drivers/ufs/core/ufs-mcq.c b/drivers/ufs/core/ufs-mcq.c
index 0787456c2b892..c873fd8239427 100644
--- a/drivers/ufs/core/ufs-mcq.c
+++ b/drivers/ufs/core/ufs-mcq.c
@@ -94,7 +94,7 @@ void ufshcd_mcq_config_mac(struct ufs_hba *hba, u32 max_active_cmds)
 
 	val = ufshcd_readl(hba, REG_UFS_MCQ_CFG);
 	val &= ~MCQ_CFG_MAC_MASK;
-	val |= FIELD_PREP(MCQ_CFG_MAC_MASK, max_active_cmds);
+	val |= FIELD_PREP(MCQ_CFG_MAC_MASK, max_active_cmds - 1);
 	ufshcd_writel(hba, val, REG_UFS_MCQ_CFG);
 }
 EXPORT_SYMBOL_GPL(ufshcd_mcq_config_mac);




[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux