Search Linux Wireless

Re: [PATCH 1/8] wifi: ath12k: Add MLO station state change handling

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Baochen Qiang <quic_bqiang@xxxxxxxxxxx> writes:

>> Ok, I think I now get what you mean. Does this look better:
>> 
>> static void ath12k_mac_free_unassign_link_sta(struct ath12k_hw *ah,
>> 					      struct ath12k_sta *ahsta,
>> 					      u8 link_id)
>> {
>> 	struct ath12k_link_sta *arsta;
>> 
>> 	lockdep_assert_wiphy(ah->hw->wiphy);
>> 
>> 	if (WARN_ON(link_id >= IEEE80211_MLD_MAX_NUM_LINKS))
>> 		return;
>> 
>> 	arsta = wiphy_dereference(ah->hw->wiphy, ahsta->link[link_id]);
>> 	if (WARN_ON(!arsta))
>> 		return;
>> 
>> 	ahsta->links_map &= ~BIT(link_id);
>> 	rcu_assign_pointer(ahsta->link[link_id], NULL);
>
> below synchronize_rcu() should be moved to here, such that any change
> to arsta can happen only AFTER all existing RCU readers finish
> accessing it.

Good point, I'll move it.

-- 
https://patchwork.kernel.org/project/linux-wireless/list/

https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches




[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Wireless Personal Area Network]     [Linux Bluetooth]     [Wireless Regulations]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite Hiking]     [MIPS Linux]     [ARM Linux]     [Linux RAID]

  Powered by Linux