Wifi Direct GO Negotiation
Andrea Chittano
andrea.chittano
Thu May 15 09:25:23 PDT 2014
Sorry guys for my inexperience, but this thing are driving me mad.
Tell me if i'm wrong.Does the function at line 525 of the following link
http://code.metager.de/source/xref/hostapd-wpa_supplicant/src/p2p/p2p_go_neg.c?r=0e0e1e564f3dd8d2a6b645d079b46eba0acc7f83
that is
void p2p_process_go_neg_req(struct p2p_data *p2p, const u8 *sa,
const u8 *data, size_t len, int rx_freq)
represent the processing (performed by Device2) of the GO negotiation request that Device1 sent Device2?
This function performs at line 687
p2p_go_det(p2p->go_intent, *msg.go_intent)
which returns the highest GO intent between local GO intent and received one.If I'm not wrong, according to what Arend told me Device2 get local GO intent from wpa_supplicant configuration file. But I've found only one way to set the local GO intent and it is here :
http://code.metager.de/source/xref/hostapd-wpa_supplicant/src/p2p/p2p.c
at line 1387, into the function
int p2p_connect(struct p2p_data *p2p, const u8 *peer_addr,
enum p2p_wps_method wps_method,
int go_intent, const u8 *own_interface_addr,
unsigned int force_freq, int persistent_group,
const u8 *force_ssid, size_t force_ssid_len,
int pd_before_go_neg, unsigned int pref_freq, u16 oob_pw_id)
According to what specifications say, it is used to start a GO negotiation.So my question is, how can I set the local GO intent for Device2 without using p2p_connect() function?I would make it by means of an android application. Can I do this?
Thanks for your help.Andrea
> Date: Wed, 14 May 2014 10:21:56 -0700
> From: moon.linux at yahoo.com
> Subject: Re: Wifi Direct GO Negotiation
> To: arend at broadcom.com; andrea.chittano at hotmail.it
> CC: hostap at lists.shmoo.com
>
> Hi Arend,
>
> I agree with what you said regarding the AP.
>
> One more question: Any device with WPS capabilty can join a P2P network.
>
> Thanks.
> -Anand Moon
>
>
>
> On Wednesday, May 14, 2014 2:56 PM, Arend van Spriel <arend at broadcom.com> wrote:
> On 14-05-14 05:03, Anand Moon wrote:
> > Hi All,
> >
> > I would like to add new question to this thread.
> >
> > If the AP has the capability to support p2p and wps, how will
> > these two devices communicate with the AP.
> > Will this AP become P2P group owner (P2P Go) and the other devices P2P Clients ?
>
> I am not sure whether this scenario makes sense. P2P typically involves
> two STAs. They may be connected to some AP, but if both are connected to
> the same AP there may be not so much need to setup a P2P connection.
>
> > I would like to know how to judge if the wireless interface supports P2P
> > is it with the "Supported interface modes" or "Supported RX frame types" ?
> >
> > If the device support following p2p mode then how do we need to configure them.
> >
> > Supported interface modes:
> > * IBSS
> > * managed
> > * AP * AP/VLAN
> > * monitor
> > * mesh point
> > * P2P-client
> > * P2P-GO
> >
> > How do we configure these P2P modes for interface?
> > Please share your thoughts.
>
> Just use nl80211 API, ie. NL80211_CMD_SET_INTERFACE. wpa_supplicant is
> doing that in src/drivers/driver_nl80211.c
>
> Regards,
> Arend
>
>
> > -Anand Moon
> >
> >
> > On Tuesday, May 13, 2014 6:31 PM, Arend van Spriel <arend at broadcom.com> wrote:
> > On 05/13/14 14:03, Andrea Chittano wrote:
> >> Hi, my name is Andrea.
> >> I'm working on WiFi Direct and I found a thread about it.
> >> I've some doubts about it.
> >> Let's suppose we have 2 devices. Let's call D1 and D2.
> >> Let's suppose D1 sends a request of connection to D2 (D1 doesn't known
> >> D2 so no persistent connection there exist).
> >> The first step that wpa_supplicant on D1 is to send a GO negotiation
> >> request containing, among all,GO intent (of D1).
> >> I want to understand how wpa_supplicant on D2 acquires the GO intent of
> >> D2 in order to compare it with whichone sent by D1.
> >> Can someone explain me this?
> >
> > Both devices have their own go intent configuration in wpa_supplicant
> > configuration file. D2 sends own go intent value in the GO negotiation
> > response. The device with the highest GO intent will become GO.
> >
> > Regards,
> > Arend
> >
> >> Thanks,
> >> Andrea
> >>
> >>
> >>
> >> _______________________________________________
> >> HostAP mailing list
> >> HostAP at lists.shmoo.com
> >> http://lists.shmoo.com/mailman/listinfo/hostap
> >
> >
> > _______________________________________________
> > HostAP mailing list
> > HostAP at lists.shmoo.com
> > http://lists.shmoo.com/mailman/listinfo/hostap
> >
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.shmoo.com/pipermail/hostap/attachments/20140515/42d044df/attachment.htm>
More information about the Hostap
mailing list