Patch "wifi: mt76: mt7915: fix register mapping" has been added to the 6.12-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

    wifi: mt76: mt7915: fix register mapping

to the 6.12-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:
     wifi-mt76-mt7915-fix-register-mapping.patch
and it can be found in the queue-6.12 subdirectory.

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



commit 2d5195b00c1b8f5c291e5ce0ecaa1799bc61ae6d
Author: Peter Chiu <chui-hao.chiu@xxxxxxxxxxxx>
Date:   Thu Jan 9 19:04:35 2025 +0800

    wifi: mt76: mt7915: fix register mapping
    
    [ Upstream commit dd1649ef966bb87053c17385ea2cfd1758f5385b ]
    
    Bypass the entry when ofs is equal to dev->reg.map[i].size.
    Without this patch, it would get incorrect register mapping when the CR
    address is located at the boundary of an entry.
    
    Fixes: cd4c314a65d3 ("mt76: mt7915: refine register definition")
    Signed-off-by: Peter Chiu <chui-hao.chiu@xxxxxxxxxxxx>
    Signed-off-by: Shengyu Qu <wiagn233@xxxxxxxxxxx>
    Link: https://patch.msgid.link/OSZPR01MB843401EAA1DA6BD7AEF356F298132@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
    Signed-off-by: Felix Fietkau <nbd@xxxxxxxx>
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

diff --git a/drivers/net/wireless/mediatek/mt76/mt7915/mmio.c b/drivers/net/wireless/mediatek/mt76/mt7915/mmio.c
index 44e112b8b5b36..2e7604eed27b0 100644
--- a/drivers/net/wireless/mediatek/mt76/mt7915/mmio.c
+++ b/drivers/net/wireless/mediatek/mt76/mt7915/mmio.c
@@ -484,7 +484,7 @@ static u32 __mt7915_reg_addr(struct mt7915_dev *dev, u32 addr)
 			continue;
 
 		ofs = addr - dev->reg.map[i].phys;
-		if (ofs > dev->reg.map[i].size)
+		if (ofs >= dev->reg.map[i].size)
 			continue;
 
 		return dev->reg.map[i].maps + ofs;




[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