diff options
| author | Maharaja Kennadyrajan <maharaja.kennadyrajan@oss.qualcomm.com> | 2025-07-18 11:38:35 +0530 |
|---|---|---|
| committer | Johannes Berg <johannes.berg@intel.com> | 2025-07-18 14:08:11 +0200 |
| commit | 4e1916dec9850cd49dd5792200ab649061cbedc1 (patch) | |
| tree | fbcdd09d5df0e409d83327d0742b6baf388dabd2 /scripts/lib/kdoc/kdoc_re.py | |
| parent | f562f6a5899d91940fd5ef78e3f6042f56abe3e2 (diff) | |
wifi: mac80211: Add link iteration macro for link data with rcu_dereference
Currently, the existing macro for_each_link_data() uses sdata_dereference()
which requires the wiphy lock. This lock cannot be used in atomic or RCU
read-side contexts, such as in the RX path.
Introduce a new macro, for_each_link_data_rcu(), that iterates over link of
sdata using rcu_dereference(), making it safe to use in RCU contexts. This
allows callers to access link data without requiring the wiphy lock.
The macro takes into account the vif.valid_links bitmap and ensures only
valid links are accessed safely. Callers are responsible for ensuring that
rcu_read_lock() is held when using this macro.
Signed-off-by: Maharaja Kennadyrajan <maharaja.kennadyrajan@oss.qualcomm.com>
Link: https://patch.msgid.link/20250718060837.59371-3-maharaja.kennadyrajan@oss.qualcomm.com
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'scripts/lib/kdoc/kdoc_re.py')
0 files changed, 0 insertions, 0 deletions
