Commit b327c84c authored by Gregory Greenman's avatar Gregory Greenman Committed by Johannes Berg
Browse files

wifi: mac80211: replace link_id with link_conf in start/stop_ap()



When calling start/stop_ap(), mac80211 already has a protected
link_conf pointer. Pass it to the driver, so it shouldn't
handle RCU protection.

Signed-off-by: default avatarGregory Greenman <gregory.greenman@intel.com>
Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
parent fd17bf04
Loading
Loading
Loading
Loading
+8 −8
Original line number Diff line number Diff line
@@ -2397,7 +2397,7 @@ static void iwl_mvm_bss_info_changed_station(struct iwl_mvm *mvm,

static int iwl_mvm_start_ap_ibss(struct ieee80211_hw *hw,
				 struct ieee80211_vif *vif,
				 unsigned int link_id)
				 struct ieee80211_bss_conf *link_conf)
{
	struct iwl_mvm *mvm = IWL_MAC80211_GET_MVM(hw);
	struct iwl_mvm_vif *mvmvif = iwl_mvm_vif_from_mac80211(vif);
@@ -2525,20 +2525,20 @@ static int iwl_mvm_start_ap_ibss(struct ieee80211_hw *hw,

static int iwl_mvm_start_ap(struct ieee80211_hw *hw,
			    struct ieee80211_vif *vif,
			    unsigned int link_id)
			    struct ieee80211_bss_conf *link_conf)
{
	return iwl_mvm_start_ap_ibss(hw, vif, link_id);
	return iwl_mvm_start_ap_ibss(hw, vif, link_conf);
}

static int iwl_mvm_start_ibss(struct ieee80211_hw *hw,
			      struct ieee80211_vif *vif)
{
	return iwl_mvm_start_ap_ibss(hw, vif, 0);
	return iwl_mvm_start_ap_ibss(hw, vif, &vif->bss_conf);
}

static void iwl_mvm_stop_ap_ibss(struct ieee80211_hw *hw,
				 struct ieee80211_vif *vif,
				 unsigned int link_id)
				 struct ieee80211_bss_conf *link_conf)
{
	struct iwl_mvm *mvm = IWL_MAC80211_GET_MVM(hw);
	struct iwl_mvm_vif *mvmvif = iwl_mvm_vif_from_mac80211(vif);
@@ -2603,15 +2603,15 @@ static void iwl_mvm_stop_ap_ibss(struct ieee80211_hw *hw,

static void iwl_mvm_stop_ap(struct ieee80211_hw *hw,
			    struct ieee80211_vif *vif,
			    unsigned int link_id)
			    struct ieee80211_bss_conf *link_conf)
{
	iwl_mvm_stop_ap_ibss(hw, vif, link_id);
	iwl_mvm_stop_ap_ibss(hw, vif, link_conf);
}

static void iwl_mvm_stop_ibss(struct ieee80211_hw *hw,
			      struct ieee80211_vif *vif)
{
	iwl_mvm_stop_ap_ibss(hw, vif, 0);
	iwl_mvm_stop_ap_ibss(hw, vif, &vif->bss_conf);
}

static void
+2 −1
Original line number Diff line number Diff line
@@ -430,7 +430,8 @@ static void rtw_ops_bss_info_changed(struct ieee80211_hw *hw,
}

static int rtw_ops_start_ap(struct ieee80211_hw *hw,
			    struct ieee80211_vif *vif, unsigned int link_id)
			    struct ieee80211_vif *vif,
			    struct ieee80211_bss_conf *link_conf)
{
	struct rtw_dev *rtwdev = hw->priv;
	struct rtw_chip_info *chip = rtwdev->chip;
+3 −2
Original line number Diff line number Diff line
@@ -382,7 +382,8 @@ static void rtw89_ops_bss_info_changed(struct ieee80211_hw *hw,
}

static int rtw89_ops_start_ap(struct ieee80211_hw *hw,
			      struct ieee80211_vif *vif, unsigned int link_id)
			      struct ieee80211_vif *vif,
			      struct ieee80211_bss_conf *link_conf)
{
	struct rtw89_dev *rtwdev = hw->priv;
	struct rtw89_vif *rtwvif = (struct rtw89_vif *)vif->drv_priv;
@@ -403,7 +404,7 @@ static int rtw89_ops_start_ap(struct ieee80211_hw *hw,

static
void rtw89_ops_stop_ap(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
		       unsigned int link_id)
		       struct ieee80211_bss_conf *link_conf)
{
	struct rtw89_dev *rtwdev = hw->priv;
	struct rtw89_vif *rtwvif = (struct rtw89_vif *)vif->drv_priv;
+2 −2
Original line number Diff line number Diff line
@@ -380,7 +380,7 @@ static void wfx_set_mfp_ap(struct wfx_vif *wvif)
}

int wfx_start_ap(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
		 unsigned int link_id)
		 struct ieee80211_bss_conf *link_conf)
{
	struct wfx_vif *wvif = (struct wfx_vif *)vif->drv_priv;
	struct wfx_dev *wdev = wvif->wdev;
@@ -399,7 +399,7 @@ int wfx_start_ap(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
}

void wfx_stop_ap(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
		 unsigned int link_id)
		 struct ieee80211_bss_conf *link_conf)
{
	struct wfx_vif *wvif = (struct wfx_vif *)vif->drv_priv;

+2 −2
Original line number Diff line number Diff line
@@ -30,9 +30,9 @@ void wfx_configure_filter(struct ieee80211_hw *hw, unsigned int changed_flags,
int wfx_add_interface(struct ieee80211_hw *hw, struct ieee80211_vif *vif);
void wfx_remove_interface(struct ieee80211_hw *hw, struct ieee80211_vif *vif);
int wfx_start_ap(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
		 unsigned int link_id);
		 struct ieee80211_bss_conf *link_conf);
void wfx_stop_ap(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
		 unsigned int link_id);
		 struct ieee80211_bss_conf *link_conf);
int wfx_join_ibss(struct ieee80211_hw *hw, struct ieee80211_vif *vif);
void wfx_leave_ibss(struct ieee80211_hw *hw, struct ieee80211_vif *vif);
int wfx_conf_tx(struct ieee80211_hw *hw, struct ieee80211_vif *vif,
Loading