]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
wifi: mt76: add offchannel check to mt76_roc_complete
authorFelix Fietkau <nbd@nbd.name>
Mon, 9 Mar 2026 06:07:22 +0000 (06:07 +0000)
committerFelix Fietkau <nbd@nbd.name>
Tue, 24 Mar 2026 15:49:31 +0000 (15:49 +0000)
commitec0a9b01ef88b5f5bdf74140f8c987f7a96693af
tree963883d7b2efa3297ed92ec02c6f6bc1ae91a765
parent360552c8592dab3c69e0bbff786b55137f1a81bb
wifi: mt76: add offchannel check to mt76_roc_complete

mt76_roc_complete() unconditionally calls __mt76_set_channel() to
restore the operating channel. The scan equivalent mt76_scan_complete()
checks phy->offchannel first, skipping the restore if the phy is
already back on-channel.

Without this check, ROC completion performs a redundant full hardware
channel switch when something has already moved the phy back.

Link: https://patch.msgid.link/20260309060730.87840-3-nbd@nbd.name
Signed-off-by: Felix Fietkau <nbd@nbd.name>
drivers/net/wireless/mediatek/mt76/channel.c