Commit 2e985cfa authored by Rafał Miłecki's avatar Rafał Miłecki Committed by Johannes Berg
Browse files

wifi: brcmfmac: rename function that frees vif



Since the commit cf124db5 ("net: Fix inconsistent teardown and
release of private netdev state.") netdev isn't freed anymore in the
brcmf_cfg80211_free_netdev(). Adjust this function name to match what it
actually does (freeing vif).

Signed-off-by: default avatarRafał Miłecki <rafal@milecki.pl>
Acked-by: default avatarArend van Spriel <arend.vanspriel@broadcom.com>
Link: https://patch.msgid.link/20251215103817.29598-1-zajec5@gmail.com


Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
parent 4ea4a3d9
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -932,7 +932,7 @@ static struct wireless_dev *brcmf_mon_add_vif(struct wiphy *wiphy,
	ndev->type = ARPHRD_IEEE80211_RADIOTAP;
	ndev->ieee80211_ptr = &vif->wdev;
	ndev->needs_free_netdev = true;
	ndev->priv_destructor = brcmf_cfg80211_free_netdev;
	ndev->priv_destructor = brcmf_cfg80211_free_vif;
	SET_NETDEV_DEV(ndev, wiphy_dev(cfg->wiphy));

	ifp = netdev_priv(ndev);
@@ -6082,7 +6082,7 @@ void brcmf_free_vif(struct brcmf_cfg80211_vif *vif)
	kfree(vif);
}

void brcmf_cfg80211_free_netdev(struct net_device *ndev)
void brcmf_cfg80211_free_vif(struct net_device *ndev)
{
	struct brcmf_cfg80211_vif *vif;
	struct brcmf_if *ifp;
+1 −1
Original line number Diff line number Diff line
@@ -493,7 +493,7 @@ s32 brcmf_notify_escan_complete(struct brcmf_cfg80211_info *cfg,
void brcmf_set_mpc(struct brcmf_if *ndev, int mpc);
bool brcmf_is_apmode_operating(struct wiphy *wiphy);
void brcmf_abort_scanning(struct brcmf_cfg80211_info *cfg);
void brcmf_cfg80211_free_netdev(struct net_device *ndev);
void brcmf_cfg80211_free_vif(struct net_device *ndev);

int brcmf_set_wsec(struct brcmf_if *ifp, const u8 *key, u16 key_len, u16 flags);
int brcmf_cfg80211_mgmt_tx(struct wiphy *wiphy, struct wireless_dev *wdev,
+2 −2
Original line number Diff line number Diff line
@@ -674,7 +674,7 @@ int brcmf_net_attach(struct brcmf_if *ifp, bool locked)

	netif_carrier_off(ndev);

	ndev->priv_destructor = brcmf_cfg80211_free_netdev;
	ndev->priv_destructor = brcmf_cfg80211_free_vif;
	brcmf_dbg(INFO, "%s: Broadcom Dongle Host Driver\n", ndev->name);
	return 0;

@@ -692,7 +692,7 @@ void brcmf_net_detach(struct net_device *ndev, bool locked)
		else
			unregister_netdev(ndev);
	} else {
		brcmf_cfg80211_free_netdev(ndev);
		brcmf_cfg80211_free_vif(ndev);
		free_netdev(ndev);
	}
}