[PATCH] P2P return a successful response for p2p presence request if driver has return noa_len greater than 0

Jouni Malinen j
Sun Dec 11 07:14:10 PST 2011


On Mon, Nov 21, 2011 at 12:01:05PM +0100, Johannes Berg wrote:
> On Mon, 2011-11-21 at 11:53 +0100, Janusz Dziedzic wrote:
> >  and possible presence_request handling in the future
> 
> Not sure I agree here -- it seems it might be easier to let the
> driver/device handle figuring out whether or not a given request can be
> handled and how it should be handled.

I would be fine handling the message exchange through wpa_supplicant,
but it does need to be the driver/device figuring out whether to agree
to change schedule and if so, how. Getting the correct NoA information
into Presence Response can be a bit difficult in some cases, but this
gets updated with the next Beacon frame anyway, so I'm not too concerned
about that.

> > 4) supplicant get this notification and update beacon template  + probe_resp
> > 5) supplicant set new beacon.

This sounds unnecessary.. The driver can do this anyway (just add
another P2P IE with NoA attribute to the end of the frame).

> Right now our firmware will update beacons, and our driver will append
> NoA to all probe responses. Since we can't turn off the beacon part,
> we'll definitely need to handle this.

This seems to be what most vendors have ended up doing (or well
firmware/driver, but anyway, somewhere much lower in the stack than
wpa_supplicant).

> I suspect right now our firmware can't actually deal with presence
> requests properly at all, I believe it'll start a NoA schedule for
> example when you ask it to scan. So for this case it would be better to
> reject any presence request.
> 
> I'm not quite sure what we gain from having the supplicant handle all
> this. Is this a lot of code if we required drivers handle it?

Agreed. I did a small change based on the thread: reject Presence
Request if current NoA cannot be fetched from the driver. That sounds
like a safer option and if someone really wants to support Presence
Request properly, that can be implemented in the driver/firmware.

-- 
Jouni Malinen                                            PGP id EFC895FA



More information about the Hostap mailing list