432 Commits

Author SHA1 Message Date
Irfan Sheriff
527ba07b63 Use Map for DnsSd TXT record
Bug: 6434844
Change-Id: I767077585f501b46026ed34ec3e778d3e53209cc
2012-05-09 16:25:00 -07:00
Irfan Sheriff
531522c7fe Merge "Report open networks without saved networks" into jb-dev 2012-05-03 09:42:06 -07:00
Irfan Sheriff
027828bff7 Report open networks without saved networks
The supplicant stops periodic scans when there are no saved networks.
The framework needs to have a periodic scan to handle this scenario.

We do have an infrequent wake up scan (15 mins), but thats way too
slow to report an open network.

Setup a scan by the supplicant interval when there are no saved
networks

Bug: 5420656
Change-Id: Id3708ecc874b42971643cc747bb9e7f2efc7d1dd
2012-05-02 17:51:26 -07:00
Irfan Sheriff
04e83d3952 Merge "Fix reference counting of wifi locks" into jb-dev 2012-05-02 16:25:34 -07:00
Irfan Sheriff
2c02da2bc6 Fix reference counting of wifi locks
Bug: 6105898
Change-Id: I7368de91fa4aa63fd97dda0ee91d810aaaa53d8b
2012-05-02 14:40:16 -07:00
Irfan Sheriff
d07223f829 Merge "Fix getConfiguredNetworks when wifi is disabled" into jb-dev 2012-05-02 11:42:09 -07:00
Irfan Sheriff
a3cbe75c93 Fix getConfiguredNetworks when wifi is disabled
Bug: 6380917
Change-Id: I4c6f1a379ef2401cde739aedfc82578c03e7dcf3
2012-05-02 11:39:54 -07:00
Irfan Sheriff
de1e9fa9fb P2p fixes
- Fix group idle settings
- Fix provision discovery event handling. We only care about device address.
- Fix WPS setup at start

Bug: 6427634
Change-Id: I0b1a7d73199e373350001114f4607bc39f2a53ba
Signed-off-by: isheriff@google.com
Signed-off-by: Yoshihiko Ikenaga <yoshihiko.ikenaga@jp.sony.com>
2012-05-02 10:02:56 -07:00
Irfan Sheriff
8e8798d90a Merge "Fix connect & save of invalid networks" into jb-dev 2012-04-30 15:51:40 -07:00
Irfan Sheriff
b3e96c527b Fix connect & save of invalid networks
Ensure SSID is not null for a new network being added

Bug: 6411912
Change-Id: I26467810bf10b7325c04677c1d0e5ff1cfb4a09e
2012-04-30 12:05:45 -07:00
Irfan Sheriff
83a708e6ad Merge "Handle null SSID cleanly" into jb-dev 2012-04-28 10:51:34 -07:00
Irfan Sheriff
00a10a1494 Handle null SSID cleanly
Bug: 6411912
Change-Id: I12f9df403c9633d928d898ae675ce36303dda1a8
2012-04-27 21:24:17 -07:00
Irfan Sheriff
d8e0831b50 Merge "Recover immediately from driver hang" into jb-dev 2012-04-27 14:44:35 -07:00
Irfan Sheriff
a5ab608295 Merge "Switch to standard commands for pno & power save" into jb-dev 2012-04-27 14:44:26 -07:00
Irfan Sheriff
b678320cfa Recover immediately from driver hang
A firmware crash can now put the interface down without notifiying the framework.
We detect this and recover immediately.

Bug: 6263857
Change-Id: Ib2dc0412fcdf9ce7b90a7fc0fab778f7af9c0513
2012-04-27 13:35:07 -07:00
Irfan Sheriff
e2639d782e Switch to standard commands for pno & power save
Remove DRIVER commands and switch to cfg based commands

Bug: 6318223
Change-Id: I5e21c4bb554c2992a52fd3c1741629645b22ae43
2012-04-27 13:01:04 -07:00
Yoshihiko Ikenaga
bfb27bbefb Allow override of p2p dialogs
By default, we show dialogs for connection requests and for
user interaction for pin input from the framework.

For applications, that want to make the experience more seamless
we should allow automatic discovery and connection as long
as one app can control it. We allow this for a foreground
app alone right now.

This will be a hidden API for now.

Bug: 6411069
Change-Id: Id342e933073d30eb58bf5a03a47ca26a64df8ddb
Signed-off-by: isheriff@google.com
Signed-off-by: Yoshihiko Ikenaga <yoshihiko.ikenaga@jp.sony.com>
2012-04-27 11:18:14 -07:00
Irfan Sheriff
d52e0c791f Merge "Add support for changing p2p device name" into jb-dev 2012-04-27 09:55:37 -07:00
Irfan Sheriff
2bdefcab74 Add support for changing p2p device name
Change-Id: Ie13fe2adedd0bac6aa07b3369c4d6a05ef33cd24
Signed-off-by: isheriff@google.com
Signed-off-by: Yoshihiko Ikenaga <yoshihiko.ikenaga@jp.sony.com>
2012-04-27 08:53:34 -07:00
Irfan Sheriff
ea22ddd6bc Fix flag on network state change broadcast
Using FLAG_RECEIVER_REPLACE_PENDING causes broadcasts
to be missed confusing the connectivity service

BUg: 6401167
Change-Id: Id69b2df18b9eb6b3e2195fbf399f36501a8d41df
2012-04-26 14:13:23 -07:00
Jeff Sharkey
4190a047ca Better assertions when bandwidth module disabled.
Also disable some verbose logging in WifiStateTracker.

Bug: 6368329
Change-Id: I9a5219bc1b3fd870468f7de46cdf4f173a437c59
2012-04-21 15:36:48 -07:00
Jeff Sharkey
9f6e4ba50e Connect metered DHCP hint for Wi-Fi networks.
When DHCP lease includes vendor info indicating that remote Wi-Fi
network is metered, advise NetworkPolicy.  Users can still manually
change the metered flag in Settings.

Also remove any policies belonging to removed Wi-Fi networks, and
teach isNetworkMetered() about ethernet networks.

Bug: 6344821, 6369307, 6365872
Change-Id: I108606c6fddf2d02828fcab011f3a1501415f1bc
2012-04-20 15:57:19 -07:00
Irfan Sheriff
6ec0c6afaf Merge "Expose NO_SERVICE_REQUESTS error condition" 2012-04-19 15:12:35 -07:00
Irfan Sheriff
232ebad9ed Expose NO_SERVICE_REQUESTS error condition
Change-Id: I45214557579fc82faa93a41d22c0890a218b091e
2012-04-19 15:01:18 -07:00
Irfan Sheriff
3b8be87f89 Fix service discovery bugs
- Application does not have transaction id information. go through
 list and remove

- Avoid removing client info while enumerating it

Change-Id: Ie293876756418ed4cd6dc3a903689ee7003bd12d
Signed-off-by: yoshihiko.ikenaga@jp.sony.com
2012-04-18 17:40:49 -07:00
Irfan Sheriff
1205054240 Merge "Open p2p pre-association service discovery API" 2012-04-17 11:40:03 -07:00
Irfan Sheriff
60c8c1570b Fix SSID parse
Bug: 6350079
Change-Id: I104dafa982bd1f144ea3a4fe19a0a23d6bf8075d
2012-04-17 10:33:12 -07:00
Irfan Sheriff
7bdcb1eed7 Fix ssid fetch
Change-Id: Iee5ee5f53bea7dea219b41735cd169389ca7e719
2012-04-16 16:49:26 -07:00
Irfan Sheriff
6079237576 Log messages in dump
Remove event logging and add messages in dump

Change-Id: Ic79c68443bac9b7257644ed6941853f44a9b0661
2012-04-16 16:47:10 -07:00
Irfan Sheriff
8bf825f48f Open p2p pre-association service discovery API
This allows applications to filter out the devices by the
services supported for the purpose of establishing a
connection.

so, a game app can connect to devices that support the game,
and a media streaming app can filter and connect only to
the available media display devices

Change-Id: Ia792e292d2ca771beeb4ca3b007a047527c19229
2012-04-14 14:41:45 -07:00
Irfan Sheriff
d4fecc2567 Merge "Pre-association service discovery support" 2012-04-12 18:33:05 -07:00
Irfan Sheriff
21ba815332 Pre-association service discovery support
Add UPnp, Bonjour and vendor specific support for discovering services on
Wi-Fi direct before establishing a connection.

Change-Id: I1c1f3427180abdc80a4e682e713adc7f0326c5ef
Signed-off-by: Yoshihiko Ikenaga <yoshihiko.ikenaga@jp.sony.com>
2012-04-12 17:50:29 -07:00
Irfan Sheriff
7405b90df4 Merge "P2p fixes" 2012-04-09 14:29:01 -07:00
Irfan Sheriff
55bfa42b05 P2p fixes
Add powersave on client after connect
Set concurrency priority to STA
Fix connection cancellation

Change-Id: I76fd9d1085c611a8c4068047b64289ef539ab389
2012-04-06 15:40:17 -07:00
Irfan Sheriff
227dde2be4 Merge "Fix key handling" 2012-04-04 12:29:26 -07:00
Yoshihiko Ikenaga
b5e00bda40 Fix key handling
putListener() returns 0 when the argument is null. And The key value of listener
registered first is always 0. For this reason, if the p2p functions are called continuously
and first call is without listener and the second call is with listener, then the message
against first call wrongly pick up the second call's listener because the key value is
the same. In order to avoid this issue, we don't use 0 as the valid listener key.

Change-Id: I0cc960b2ad37f17cf7f528d839b39aa272b83670
Signed-off-by: Yoshihiko Ikenaga <yoshihiko.ikenaga@jp.sony.com>
2012-04-04 11:55:06 -07:00
Kenny Root
4e62fd3f95 Wifi: change empty "engine" config to integer
"engine" is specified as an integer in wpa_supplicant, so we have to
make sure we send an integer instead of a NULL when we want to disable
it.

Bug: 6250670
Change-Id: I693ccb49badbd400a5882e9df1bbd4febc847a6e
2012-03-29 17:25:24 -07:00
Irfan Sheriff
8901de0af6 Merge "Add discovery broadcasts for p2p" 2012-03-29 08:41:15 -07:00
Irfan Sheriff
c111d1caa8 Add discovery broadcasts for p2p
This will allow apps to figure out if discovery is active or not
and based on that initiate a new discovery for fresh connections

Change-Id: I4778f135fdd88773e4f0d50c384f9b6ebf561e6d
2012-03-28 17:37:04 -07:00
Irfan Sheriff
5fa47298af Merge "p2p fixes" 2012-03-28 16:57:46 -07:00
Irfan Sheriff
8a34718d84 Merge "Control suspend optimizations from framework" 2012-03-28 14:12:11 -07:00
Kenny Root
4898087be9 Merge changes Ibdf23227,I3681f98c
* changes:
  Update Wifi to use new keystore function
  Add signing to keystore
2012-03-27 20:42:15 -07:00
Yoshihiko Ikenaga
61472a8314 p2p fixes
Fix space handling in device name and ssid (This builds from contribution of
Yoshihiko Ikenaga <yoshihiko.ikenaga@jp.sony.com>)

Also clean up STA event handling and remove the unused interface address

Change-Id: Ic16a4aadf905c1da5c060faa8a3caa83adc0549f
2012-03-27 16:45:02 -07:00
Irfan Sheriff
262f766ac8 Control suspend optimizations from framework
The suspend optimizations handling in the driver is being removed.
The framework will hence forth control when these optimizations occur -
we do this at screen off and hold a short wakelock to ensure this.

We also remove the use of the now defunct setsuspendopt command and
handle the high perf locking with the new suspend mode command.

Change-Id: Ia12e38befb2c4f85cad6612bc8f807805bd0dae1
2012-03-26 23:48:53 -07:00
Mike Lockwood
1b6989cdc2 Merge commit '74803dc'
Change-Id: I35a76a27390c75a47e6387fb0ee853a5a689a56f
2012-03-22 15:09:52 -07:00
Mike Lockwood
09a12bcfab WifiStateMachine: Move wifi teardown delay to a framework resource
Bug: 5931171

Change-Id: I96a4e3bf1d044ea4a4d2955775703b6f0ce862ed
Signed-off-by: Mike Lockwood <lockwood@google.com>
2012-03-22 15:09:05 -07:00
Kenny Root
565f9f216a Update Wifi to use new keystore function
The old wpa_supplicant.conf format used a special URI prefix
"keystore://" for the private_key value to indicate when to load things
from keystore.

The new format uses an OpenSSL ENGINE to perform operations with the
private key, so we don't need the special URI prefix. This changes
enables that usage and also supports migrating the old style
configuration to the new style.

Change-Id: Ibdf2322743eaa129bd2aa5e874f197b573714b57
2012-03-21 14:34:36 -07:00
Irfan Sheriff
90d57dfac3 Improve network avoidance
Adds a back-off based technique where the amount of time we wait before
avoiding wi-fi is increased.

This will reduce power consumption on devices that are experiencing high
variance on wi-fi

Change-Id: I40da03edfb5373ddb51056818ca0744dc26a5600
2012-03-12 16:12:55 -07:00
Irfan Sheriff
4c8982ad82 Enhancements for avoiding poor connection on wifi
- Avoid flapping
- Increase thresholds and monitor rssi more closely to detect consistently weak signal

Change-Id: I6139a20b7306839b345146a72ce690020a2e00b8
2012-03-08 16:28:35 -08:00
Irfan Sheriff
db9e6937f1 Merge "Enhance WPS" 2012-03-02 16:33:01 -08:00