Adding Vendor Specific IE in the Beacon
Dear all,
I would like to add a Vendor Specific IE in the Beacon frames generated by ath9k. I am however not able to find out where exactly in the code the Beacon frame is constructed. What I have seen is that ath9k requests the beacon frame to mac80211 in the function ath_beacon_generate() by calling ieee80211_beacon_get(). However in ieee80211_beacon_get_tim() it seems that the Beacon data is retrieved from the structure ieee80211_sub_if_data *sdata, that has been previously populated. In particular the following lines seem relevant in ieee80211_beacon_get_tim():
...
struct ieee80211_sub_if_data *sdata = NULL;
...
sdata = vif_to_sdata(vif);
...
ap = &sdata->u.ap;
beacon = rcu_dereference(ap->beacon);
What I am not able to find out is when and how is the beacon data loaded in sdata->u.ap.beacon ? Any help would be appreciated.
Best Regards
Daniel
Quoted 21 lines · Dani Camps
Dear all,
I would like to add a Vendor Specific IE in the Beacon frames generated by ath9k. I am however not able to find out where exactly in the code the Beacon frame is constructed. What I have seen is that ath9k requests the beacon frame to mac80211 in the function
ath_beacon_generate()by callingieee80211_beacon_get(). However inieee80211_beacon_get_tim()it seems that the Beacon data is retrieved from the structureieee80211_sub_if_data*sdata, that has been previously populated. In particular the following lines seem relevant inieee80211_beacon_get_tim():...
structieee80211_sub_if_data*sdata = NULL;
...
sdata =vif_to_sdata(vif);
...
ap =&sdata->u.ap;
beacon =rcu_dereference(ap->beacon);
Quoted 2 lines
What I am not able to find out is when and how is the beacon data loaded in
sdata->u.ap.beacon? Any help would be appreciated.
The beacon template is set by hostapd.
Sujith