aboutsummaryrefslogtreecommitdiffstats
path: root/src/p2p/p2p_i.h
Commit message (Collapse)AuthorAgeFilesLines
* Fix p2p service discoveryIrfan Sheriff2012-08-021-0/+8
| | | | | | | - Fix listen timing to improve SD reliability - Fix SD packet scheduling Signed-off-by: Eyal Shapira <eyal@wizery.com>
* p2p: consider age for the p2p scan resultsYoni Divinsky2012-07-301-2/+3
| | | | | | | | | | | | | | | | | Cfg80211 caches the scan results according the channel number. Due to the 15 sec aging this might cause the user mode to see more than one scan result with the same BSSID, e.g. - one scan result for the p2p-device and one for the p2p-GO (once it's enabled). Fix this by updating the device entry only if the new peer entry is newer than the one previously stored. Signed-off-by: Yoni Divinsky <yoni.divinsky@ti.com> Signed-off-by: Victor Goldenshtein <victorg@ti.com> Signed-off-by: Igal Chernobelsky <igalc@ti.com>
* P2P: Add option for Provision Discovery before GO NegotiationJouni Malinen2012-05-111-0/+1
| | | | | | | | | | This is a workaround for interoperability issues with some deployed P2P implementations that require a Provision Discovery exchange to be used before GO Negotiation. The new provdisc parameter for the p2p_connect command can be used to request this behavior without having to run a separate p2p_prov_disc command. Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>
* P2P: Store SSID of the group in p2p_group dataJouni Malinen2012-05-081-0/+2
| | | | | | | | This can be used with P2P management operations that need to verify whether the local device is operating a specific group based on P2P Group ID attribute from a peer. Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>
* P2P: Do not update peer Listen channel based on PD/InvitationJouni Malinen2012-04-261-1/+1
| | | | | | | | | | | | | | | | | | Commits 17bef1e97a5061a8b5443dc24166e28439911f0b and ffe98dfb88a19b66418184955ef272789e3abb68 started using p2p_add_device() with other frames than just Probe Response frames from scan results. However, these changes did not take into account that the PD Request and Invitation Request frames are normally received on the our own Listen channel, not on the Listen channel of the peer. As such, these frames must not be used to update Listen channel information for the peer. Fix this by letting p2p_add_device() know whether the results are from scan results and if not, skip the peer table updates that are specific to Probe Response frames. Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com> intended-for: hostap-1
* P2P: Advertise immediate availability of WPS credentialJouni Malinen2012-02-271-1/+2
| | | | | | | | | | | | | | Use Device Password ID in WSC IE of Probe Request and Probe Response frames to advertise immediate availability of WPS credentials per P2P specification sections 3.1.2.1.1 (Listen State), 3.1.2.1.2 (Scan Phase), and 3.1.2.1.3 (Find Phase). For now, the Device Password ID is set only for the case where we are active GO Negotiation with a specific peer. In practice, this means that the Probe Response frames during pending GO Negotiation (whenever in Listen state) indicate availability of the credential. Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>
* P2P: Fix remain-on-channel use with PD/Invitation Request while in ListenJouni Malinen2012-02-271-0/+1
| | | | | | | | | | | | | | | | | If Listen state was in progress on another channel when a request to send an Action frame (e.g., Provision Discovery Request or Invitation Request to a peer on the peer's Listen channel that is different from our Listenc hannel) is issued, wpa_supplicant tried to use concurrent remain-on-channel operations. While some drivers can handle this cleanly, there are drivers that don't and wpa_supplicant is not expected to request concurrent remain-on-channel operations. Fix this by cancelling the ongoing remain-on-channel with stop_listen prior to sending the Action frame on another channel. If a P2P search was in progress, it will be continued after the timeout on the new operation. Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>
* Remove the GPL notification from files contributed by AtherosJouni Malinen2012-02-111-8/+2
| | | | | | | Remove the GPL notification text from files that were initially contributed by Atheros Communications or Qualcomm Atheros. Signed-hostap: Jouni Malinen <j@w1.fi>
* P2P: Move p2p_add_device() prototype to correct header fileJouni Malinen2012-02-071-0/+2
| | | | | | | This was supposed to be an internal API to be used only within src/p2p/*.c. Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>
* P2P: Allow Device ID to be specified for p2p_find commandJouni Malinen2012-01-081-0/+2
| | | | | | | dev_id=<P2P Device Addr> can now be specified as an argument to p2p_find to request P2P find for a specific P2P device. Signed-hostap: Jouni Malinen <j@w1.fi>
* P2P: Fix Provision Discovery channel for some join-GO casesJouni Malinen2011-12-181-1/+1
| | | | | | | | | The Provision Discovery Request needs to be sent on the operating channel of the GO and as such, the frequency from the BSS table (scan results) need to override the frequency in the P2P peer table that could be based on the Listen channel of the GO. Signed-hostap: Jouni Malinen <j@w1.fi>
* P2P: Fix Provision Discovery name in debug messagesJouni Malinen2011-12-111-1/+1
| | | | | | | Some debug messages used incorrect name for Provision Discovery. Replace "Provisioning Discovery" with "Provision Discovery". Signed-hostap: Jouni Malinen <j@w1.fi>
* P2P: Remove forgotten TODO commentJouni Malinen2011-12-101-2/+0
| | | | | | The P2P peers are already expired. Signed-hostap: Jouni Malinen <j@w1.fi>
* P2P: Skip duplicated provision discovery on joinJithu Jance2011-12-061-0/+8
| | | | | | | If p2p_prov_disc join command is used prior to p2p_connect join, skip the duplicated provision discovery exchange. Signed-hostap: Jithu Jance <jithu@broadcom.com>
* P2P: Wait until ongoing scan completes before starting P2P findJouni Malinen2011-11-151-0/+6
| | | | | | | | | The P2P_FIND command was failing if it was issued at the moment when a scan operation was in progress. Avoid returning failure in this case by scheduling the P2P find to start once the ongoing scan is completed. Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>
* P2P: Advertise Persistent Reconnect group capabilityJouni Malinen2011-10-241-0/+1
| | | | | | | | The persistent_reconnect configuration parameter was used to decide whether to accept invitation to re-establish a persistent group. However, this was not being advertised in the Group Capability bitmap. Add the Persistent Reconnect bit based on this configuration to GO Negotiation frames and Beacon/Probe Response frames from the GO.
* P2P: Do not change SSID during GO negotiationJouni Malinen2011-10-111-0/+5
| | | | | | | | If GO Negotiation Request (or in theory, also GO Negotiation Response) frame is delivered multiple time for processing, the SSID of the group could end up getting changed. This could result in possible issues if the peer ended up using different SSID. To avoid this, make sure the SSID does not get changed unless the negotiation is for a new group.
* P2P: Show P2P peer signal level in D-Bus P2P device propertiesJayant Sane2011-06-231-1/+0
| | | | | | | | | Move level parameter from p2p_device to p2p_device_info in order to expose this information and modify D-Bus P2P handler to return this new parameter through the P2P device properties. Signed-off-by: Fabien Marotte <fabienx.marotte@intel.com> Signed-off-by: Jayant Sane <jayant.sane@intel.com>
* P2P: Retry provision discovery requests in IDLE stateJayant Sane2011-06-121-0/+18
| | | | | | | | | | | Since the peer may not be in Listen state when the provision discovery request is sent, try to send the request again number of times when in IDLE state. This was already done when p2p_find is in progress, but this commit adds retries to the case where no other P2P operations are in progress. Signed-off-by: Jayant Sane <jayant.sane@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
* P2P: Store more WPS attributes for peersJouni Malinen2011-03-281-0/+8
| | | | | | Store Manufacturer, Model Name, Model Number, and Serial Number attributes for P2P peers and expose these through the existing peer information mechanisms.
* P2P: Add option for requested device type in P2P search/scanJean-Michel Bachot2011-03-191-0/+4
| | | | | | | With this, p2p_find can be extended to find certain requested device types. Signed-off-by: Johannes Berg <johannes.berg@intel.com>
* P2P: Use a single define for max number of vendor extensionsJouni Malinen2011-03-191-4/+3
|
* P2P: Keep track of peer WPS vendor extensionsJean-Michel Bachot2011-03-191-0/+2
| | | | | | | | Make the P2P code keep track of WPS vendor extensions received from peers so they can be exposed via DBus later. Signed-off-by: Jean-Michel Bachot <jean-michelx.bachot@linux.intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
* P2P: Allow adding of WPS vendor extension attributesJean-Michel Bachot2011-03-191-0/+6
| | | | | | | | This adds the ability to add WPS vendor extension attributes in P2P frames, like GO Negotiation and Probe Response frames. Signed-off-by: Jean-Michel Bachot <jean-michelx.bachot@linux.intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
* P2P: Keep track of secondary device types for peersJean-Michel Bachot2011-03-171-0/+2
| | | | | Signed-off-by: Jean-Michel Bachot <jean-michelx.bachot@linux.intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
* P2P: Add new_device flag to dev_found callbackJohannes Berg2011-02-241-0/+1
| | | | | | | | | | | | | | The DBus code will want to have perfect matching of dev_found and the dev_lost it adds so it doesn't need to keep track internally. Enable that with a new flag in the core that tracks whether we have already notified about this -- the existing users can ignore it. The part where this is always set to 1 if the new device is discovered by a driver that has P2P in the driver is buggy -- the driver should feed the P2P peer database and then that should feed the notification here instead. Signed-off-by: Johannes Berg <johannes.berg@intel.com>
* P2P: Embed publically visible struct in peer infoKonguraj(Raj) Kulanthaivel2011-02-241-6/+1
| | | | | | | | | | | | This embeds some information about each P2P peer that will be publically visible in a struct that is shared. The dev_found notification function is also passed the new struct, which requires some work for the driver-based P2P management. Signed-off-by: Konguraj(Raj) Kulanthaivel <konguraj.kulanthaivel@intel.com> Signed-off-by: Fabien Marotte <fabienx.marotte@linux.intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
* P2P: Limit the retransmission of GO Negotiation request to 120Fabien Marotte2010-12-281-0/+1
| | | | | | | | | | | | | | | | If the peer you want to connect to is no longer available (does not acknowledge frames) when wpa_supplicant sends GO Negotition Request frames, retransmission of this frame is done until the associated p2p_device structure is removed on timeout. In that case, no signal is emitted to inform the GO Negotiation has failed. When sending an Invitation Request frame, the same retransmission mechanism is in place but limit the transmission to 100 and hitting the limit generates an event. This patch adds the same mechanism as the one in place for Invitation Request, but with limit of 120 to match the existing wait_count for for GO Negotiation.
* P2P: Add support for automatic channel selection at GOAnil Gathala Sudha2010-11-101-0/+4
| | | | | | | | | | | | | The driver wrapper may now indicate the preferred channel (e.g., based on scan results) on both 2.4 GHz and 5 GHz bands (and an overall best frequency). When setting up a GO, this preference information is used to select the operating channel if configuration does not include hardcoded channel. Similarly, this information can be used during GO Negotiation to indicate preference for a specific channel based on current channel conditions. p2p_group_add command can now use special values (freq=2 and freq=5) to indicate that the GO is to be started on the specified band.
* P2P: Do not re-send PD Request for join-a-group after acked frameJouni Malinen2010-10-271-0/+1
| | | | | | | We are not actually interested in the PD Response in join-a-group case, so there is no point in trying to send PD Request until the response is received. This avoids an extra PD getting started after a join-a-group operation in some cases.
* P2P: Delay send_action call if p2p_scan is in progressJouni Malinen2010-10-201-0/+14
| | | | | | In order to avoid confusing the driver with a new remain-on-channel request, delay sending of a new Action frame if the driver indicates Action frame RX diromg a scan.
* P2P: Add peer timeout into group formation 15 second timeoutJouni Malinen2010-09-101-0/+3
| | | | | This adds some more time for WPS provisioning step in case the peer takes long time to start group interface operations.
* P2P: Fix GAS fragmentation to match with IEEE 802.11uJouni Malinen2010-09-091-0/+1
| | | | | | | | P2P specification v1.15 fixed the description of the GAS fragmentation to not duplicate NQP Query Response Field header in all fragments. This change makes the fragmentation match with the description in IEEE 802.11u. The change is not backwards compatible with previous P2P specification versions as far as fragmented SD responses are concerned.
* P2P: Add support for cross connectionJouni Malinen2010-09-091-0/+2
| | | | | | | | If enabled, cross connection allows GO to forward IPv4 packets using masquerading NAT from the P2P clients in the group to an uplink WLAN connection. This is disabled by default and can be enabled with "wpa_cli p2p_set cross_connect 1" on the P2P device interface.
* P2P: Fix channel forcing for p2p_connect authJouni Malinen2010-09-091-0/+1
|
* P2P: Add test command for filtering which peers are discoveredJouni Malinen2010-09-091-0/+2
| | | | | | | "wpa_cli p2p_set peer_filter <MAC address>" can now be used to only allow a single P2P Device (based on P2P Device Address) to be discovered for testing. Setting the address to 00:00:00:00:00:00 disables the filter.
* P2P: Initial support for SD fragmentation (GAS Comeback Request/Response)Jouni Malinen2010-09-091-1/+13
|
* P2P: Add initial version of P2P ModuleJouni Malinen2010-09-091-0/+580