• Deren Wu's avatar
    wifi: mt76: mt7921: fix wrong command to set STA channel · fcc51acf
    Deren Wu authored
    Should not use AND operator to check vif type NL80211_IFTYPE_MONITOR, and
    that will cause we go into sniffer command for both STA and MONITOR
    mode. However, the sniffer command would set channel properly (with some
    extra options), the STA mode still works even if using the wrong
    command.
    
    Fix vif type check to make sure we using the right command to update
    channel.
    
    Fixes: 914189af
    
     ("wifi: mt76: mt7921: fix channel switch fail in monitor mode")
    Signed-off-by: default avatarDeren Wu <deren.wu@mediatek.com>
    Signed-off-by: default avatarFelix Fietkau <nbd@nbd.name>
    fcc51acf
main.c 47.5 KB