wifi: mt76: mt7925: Remove useless condition
Subsystems (2)
PATCH 1/1 wifi: mt76: mt7925: Remove useless condition
The condition (master_pref > NAN_MAX_MASTER_PREFERENCE) will always be false because the variable 'master_pref' is of type u8 and the macro 'NAN_MAX_MASTER_PREFERENCE' is equal to 255.
Fixes a5487a6824068 ("wifi: mt76: mt7925: add NAN MCU helpers")
Signed-off-by Ethan Tidmore <[email protected]>
--- drivers/net/wireless/mediatek/mt76/mt7925/nan.c | 3 --- 1 file changed, 3 deletions(-)
drivers/net/wireless/mediatek/mt76/mt7925/nan.c +0 -3
@@ -255,9 +255,6 @@ mt7925_nan_mp_tlv(struct sk_buff *skb, u8 master_pref) mp_tlv = (struct mt7925_nan_master_preference_tlv *)tlv; -if (master_pref >NAN_MAX_MASTER_PREFERENCE ) -return 0 ; - mp_tlv->master_preference = master_pref;return 0 ;
Signature · 3 lines
Thanks, ET https://github.com/sponsors/ethantidmore