I am trying to develop a driver for a WLAN NIC using D80211, and to have it working as an AP with Hostapd on top of D80211. Logically, I need a new beacon every DTIM period since the TIM Information Element gets changed every DTIM period. In my 
hostapd.conf:<br><br>beacon_int = 100<br>dtim_period = 2<br><br>I thought that hostapd should send an ioctl to set the beacon, this ioctl would be translated to ieee80211_config_interface by D80211 with the beacon set by hostapd. At least, according to my understanding of driver_devicescape.c, this is what should happen. My problem is that this ioctl comes very late in the init process. Here is a short description of the init flow of D80211 (when hostapd sends its instructions), this is a list of handlers that I implement, and that D80211 calls:
<br><ol><li>add_interface</li><li>open (here I should be already able to send beacons according to d80211.h)</li><li>config_interface (several times with beacon NULL)</li></ol>And much later, config_interface is called again with a non-null beacon.
<br><br>All this when I register as a driver that needs a beacon template. When I register as a driver that needs a full beacon frame, I should be able to call ieee80211_beacon_get to get a beacon, but this does not work (beacon is NULL).
<br><br>Questions:<br>1) Am I right with I thought ?<br>2) Why does Hostapd begins to open and start my device before being able to give me a valid beacon ?<br>3) Is this a problem in Hostapd or D80211 or neither ?<br><br>
thanks<br><br>-- <br>Emmanuel Grumbach<br><a href="mailto:egrumbach@gmail.com">egrumbach@gmail.com</a>