On 3/11/2025 3:29 AM, Johannes Berg wrote: > > Can this not use for_each_valid_link()? I think > for_each_valid_link(&sdata->vif, link_id) should work? If not some new > macro? I don't like open-coding this "if (valid_links)" etc. everywhere. > > johannes for_each_valid_link() is a cfg80211 macro that utilizes wdev to access valid_links and links array. Using this macro with &sdata->vif will not work since, links array located in sdata and is named "link" and valid_links is located inside vif. Should I will go ahead and define a new macro that is similar but utilizes sdata or should I stick to using for_each_valid_link() and pass in &sdata->wdev.