So as you can see from the code, I only allowed station interfaces for now. Which is actually pretty useless since you can't use two of them to associate to the same AP. It also violates the IEEE 802.11 specification as far as I can tell because we can only adopt the time of one BSS... This is a good stepping stone, however. I've shown that the firmware can easily be modified to support address masks, so we can now think about how multi-BSS AP operation can work. Right now, I'm thinking we should do it this way: As for the firmware, I'd disable support for TIM manipulation and make it take the beacon from the multicast/broadcast frame queue instead of from the template RAM. Essentially, at beacon time, the firmware would send the first frame from the mc/bc queue (the beacon) and then all other frames from the mc/bc queue (the mc/bc traffic) up to the "last bc/mc frame ID" where we clear the more data bit. No special-casing of the DTIM period etc, we let the driver handle all that. We should limit multi-BSS operation to some sane value, say 16, and require that the mask is the last four bits or less. This way, we can use the lowest four bits of the mac address as a beacon ID and have different "last bc/mc frame ID"s for the different beacons to ease driver operation and make it race-free. In the driver, for such modified firmware, we rely on mac80211's software broadcast/multicast queuing feature along with the get_beacon() function. Every time the firmware indicates that it has sent a beacon, the driver will queue the next beacon (round-robin between the interfaces) and the corresponding multicast traffic. Something I'm not clear on right now is the timing of it all. If there are say two BSSes, the driver can simply program the hardware to half the beacon period and then the beacons will alternate. But if there are seven BSSes, the beacon period might not be divisible by seven so timing errors will happen and, worse yet, accumulate. Does hostapd somehow account for this? Or should the beaconing work completely differently, for example with all N beacons sent in a burst? johannes
Attachment:
signature.asc
Description: This is a digitally signed message part