wifi: mt76: mt7921: fix invalid remain_on_channel duration
authorDeren Wu <deren.wu@mediatek.com>
Sat, 31 Dec 2022 09:01:10 +0000 (17:01 +0800)
committerFelix Fietkau <nbd@nbd.name>
Fri, 3 Feb 2023 13:47:16 +0000 (14:47 +0100)
commitc36457a8f34d1e0fc55fbbd7b8b2d716af3f6289
tree70404998e6140b6ddd2157d99b030ed12b54661b
parentac922bd60ace311232ab5f33ec295acf8e9952f1
wifi: mt76: mt7921: fix invalid remain_on_channel duration

round_jiffies_up() may change the duration reported from chip. We should
take the real timeout for current channel privilege.

Fixes: 034ae28b56f1 ("wifi: mt76: mt7921: introduce remain_on_channel support")
Signed-off-by: Deren Wu <deren.wu@mediatek.com>
Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
Signed-off-by: Felix Fietkau <nbd@nbd.name>
drivers/net/wireless/mediatek/mt76/mt7921/mcu.c