mirror of
https://github.com/outbackdingo/mt76.git
synced 2026-10-24 13:26:48 +00:00
Revert "wifi: mt76: Check link_conf pointer in mt76_connac_mcu_sta_basic_tlv()"
In mt76_connac_mcu_sta_basic_tlv() link_conf is always not NULL.
Revert the commit '9890624c1b39 ("wifi: mt76: Check link_conf pointer in
mt76_connac_mcu_sta_basic_tlv()")' in order to fix the following
warning:
drivers/net/wireless/mediatek/mt76/mt76_connac_mcu.c:394 mt76_connac_mcu_sta_basic_tlv()
warn: variable dereferenced before check 'link_conf'
This reverts commit 9890624c1b3948c1c7f1d0e19ef0bb7680b8c80d.
Signed-off-by: Lorenzo Bianconi <[email protected]>
Link: https://patch.msgid.link/20250325-mt76_connac_mcu_sta_basic_tlv-link_conf-revert-v1-1-b84efefb74ee@kernel.org
Signed-off-by: Felix Fietkau <[email protected]>
This commit is contained in:
committed by
Felix Fietkau
parent
925d156dab
commit
a403590fd4
+1
-1
@@ -390,7 +390,7 @@ void mt76_connac_mcu_sta_basic_tlv(struct mt76_dev *dev, struct sk_buff *skb,
|
|||||||
basic->conn_type = cpu_to_le32(CONNECTION_INFRA_BC);
|
basic->conn_type = cpu_to_le32(CONNECTION_INFRA_BC);
|
||||||
|
|
||||||
if (vif->type == NL80211_IFTYPE_STATION &&
|
if (vif->type == NL80211_IFTYPE_STATION &&
|
||||||
link_conf && !is_zero_ether_addr(link_conf->bssid)) {
|
!is_zero_ether_addr(link_conf->bssid)) {
|
||||||
memcpy(basic->peer_addr, link_conf->bssid, ETH_ALEN);
|
memcpy(basic->peer_addr, link_conf->bssid, ETH_ALEN);
|
||||||
basic->aid = cpu_to_le16(vif->cfg.aid);
|
basic->aid = cpu_to_le16(vif->cfg.aid);
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
Reference in New Issue
Block a user