History log of /frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
665e1aed5e99af1e66af56c0d73e32fd86f57273 22-Aug-2012 Robert Greenwalt <rgreenwalt@google.com> Add BT - DataTracker connection

Allows the external BT stack the means to communicate with
ConnectivityService during reverse tethering.

bug:8445208
Change-Id: Ice7dfb0b50c9481d359aed14a51372878185171c
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
69edd64d9bf839428ce0a7723cd0f1deda98dc0d 07-Mar-2013 Lorenzo Colitti <lorenzo@google.com> Add stacking to the NetworkStateTrackers.

Bug: 8276725
Change-Id: I55a107fea78f9cc84f15bd6c75292138fb35a1b6
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
0f08b813bb0f14f00cf167eeb49b5eea8f3b4f0f 26-Sep-2012 Irfan Sheriff <isheriff@google.com> Remove WifiStateTracker code tracking wifi p2p

This code was never supposed to have been there. It just remained
from an old implementation and actually results in
CS getting the wrong network info when both wifi and p2p are connected

Exposing p2p network type to CS needs to be done differently.

Bug: 7233984
Change-Id: I84a6091b8236cf5bdfcef3e7f626163d629e372d
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
da6da0907b28d4704aabbdb1bbeb4300954670d1 16-Aug-2012 Irfan Sheriff <isheriff@google.com> Captive portal handling

We now notify the user of a captive portal before switching to the network as default.
This allows background applications to continue to work until the user confirms he
wants to sign in to the captive portal.

Also, moved out captive portal handling out of wifi as a seperate component.

Change-Id: I7c7507481967e33a1afad0b4961688bd192f0d31
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
4190a047ca1c5eb19a1f7e5d599ef1d532da71c7 22-Apr-2012 Jeff Sharkey <jsharkey@android.com> Better assertions when bandwidth module disabled.

Also disable some verbose logging in WifiStateTracker.

Bug: 6368329
Change-Id: I9a5219bc1b3fd870468f7de46cdf4f173a437c59
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
2367e75beebd44338d67c20270cecedd5ca3cb5c 13-Sep-2011 Robert Greenwalt <rgreenwalt@google.com> am 61db35da: am 2f835a61: Merge "Make copies of NetworkInfo to give out." into honeycomb-LTE

* commit '61db35da2b4501dde5646f86f21cf5054c41ea26':
Make copies of NetworkInfo to give out.
6aecb98a627daa3f66c060ca5177a075e4e9bcca 09-Sep-2011 Robert Greenwalt <rgreenwalt@google.com> Make copies of NetworkInfo to give out.

Otherwise we'll change it out from under those we've given it too.
bug:5233462

Change-Id: Iffc886849edfa6ced3da1133f9d363e11b2733f8
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
8e28b7d78232f6cf08739ca0d129cc7f9e650801 19-Aug-2011 Jeff Sharkey <jsharkey@android.com> Proactively disable data when over policy limit.

Add policy controls to NetworkStateTracker which are combined with
other user preference and internal flags to decide if data connection
should be established. Better locking around enabled flags.

When data network would be over limit, proactively disable data on
that network. Enable when policy is snoozed or when cycle resets.

Track and dismiss notifications from now-stale policies.

Bug: 4587023, 5178147
Change-Id: Ibfcc9f73cda7c369209af701b46eddd3d1943f2d
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
aea743aaa43a833fd8ff3dc56205197583152d5f 30-Jul-2011 repo sync <isheriff@google.com> P2p enhancements

- ConnectivityService interaction and support for running dhcp server
and client

- State machine enhancements for connectivity interaction

Change-Id: Iba3beb8c87554ffd67a7b7e852bbb4dd8666a4f5
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
d55a6b498d66d8fc415908ecf63e50f46cce67e8 25-Mar-2011 Robert Greenwalt <rgreenwalt@google.com> Add external dependency API.

An APN will not be connected to if some external dependency is not met.

bug:3486704
Change-Id: I7d94df343b260013efd11faa978deb13f07f1389
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
645b83f3ec2ead154c2062fd6d4498713d11de7e 21-Feb-2011 Robert Greenwalt <rgreenwalt@google.com> Remove some unused code.

Change-Id: Id29bf7d2118065e2e772b22d910bda1c6de2a475
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
e798268f16ec6d0542616ea45ca0bb18ae2645ee 07-Dec-2010 Wink Saville <wink@google.com> Have MobileDataStateTracker & DataConnectionTracker communicate directly.

Added CMD_SET_DATA_ENABLE which is sent when data is enabled/disabled
via the ConnectivityService. It is anticipated that the communication
channel will be used for additional commands and to receive unsoliciated
commands from DataConnectionTracker back to MobileDataStateTracker.

Change-Id: I3863e7385155d503f069b1dcb7e4f766ec78b5f8
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
be9ee6a498afc08df1ca6d796b703b703b25c9a9 02-Dec-2010 Irfan Sheriff <isheriff@google.com> Fix configuration change handling

When IP or proxy config changes, we now reconfigure
the network and inform connectivityservice.

Also, fixed the naming for changes on configured
networks.

Bug: 3237735
Change-Id: I2a94b3158b6b0e0d27442d7fd525a8a23f0497f8
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
f61101f6266be243c481d163b95e65d67b8d1669 17-Sep-2010 Wink Saville <wink@google.com> Add LinkCapabilities

Change-Id: Ia1599ade936b79f12526252c0a2e6b453abb136e
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
5de38d11f6bb277ac0930f4264f012dac14a05a9 02-Sep-2010 Wink Saville <wink@google.com> Remove unused Intent filter values.

Change-Id: I902cdbbff9238b2ac975441ef6ecb3c6d5c7a56f
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
37e65ebb7eb932e1a144b1cab262e11ca5fd109b 30-Aug-2010 Robert Greenwalt <robdroid@android.com> Rename NetworkProperties to LinkProperties

Also add copy constructors and use them when giving out data.

Change-Id: Id320eb8fb91d0bd250305ce7bb4f628570215615
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
2338f48ddb3d1746c2d46df85fdc4dcd6cfa240b 20-Aug-2010 Jean-Baptiste Queru <jbq@google.com> resolved conflicts for merge of 34df5ccc to master

Change-Id: I55558b2ab9452b2a819a1fce5b3ee5af29688e98
a00f8db5ef724bf9a695ac43c1538557f2dffe1f 18-Aug-2010 Jean-Baptiste Queru <jbq@google.com> fix build

Change-Id: I13a6a34e8eae73b046769df365be8a46489bd111
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
3719f8568e809ffd30f90adc38993256a9d3d066 18-Aug-2010 Jean-Baptiste Queru <jbq@google.com> DO NOT MERGE resolved conflicts for merge of 8c11e952 to gingerbread-plus-aosp

Change-Id: I29703133654f0f80a4425914d290e9dc50cbc3cc
f93951851052f14e3263adff22266b61f487b018 18-Aug-2010 Jean-Baptiste Queru <jbq@google.com> Revert "- updates NetUtils to use new libnetutils headers"

This reverts commit 9bf3bb21c097cc96f30d9bf3ec7dea62a74a738b.
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
8c11e952305327183db9f7be719e4c94fde15a7c 13-Aug-2010 Irfan Sheriff <isheriff@google.com> DO NOT MERGE WifiLock extensions for high performance mode

Add extension to WifiLock to allow apps to operate
in high performance mode (high power & disable suspend
optimizations for battery consumption).

Bug: 2834260
Change-Id: I8b33d307f3d569bc92ba2139b9ed224ffc147547
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
c7a98341b053bd8090accca151e8f3522f2dd126 14-Aug-2010 Wink Saville <wink@google.com> Add documentation to NetworkStateTracker and a small change to the API.

Also, removed some unused NetworkStateTracker event codes.

The API change was to add context and target to startMonitor, this makes
it easier to document what the actual interface contract is.

Change-Id: If9b52486c3c281fe4794bc78417c8b03888414b1
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
993f85f3194000d0eb212f361431c9319548b144 14-Aug-2010 Robert Greenwalt <robdroid@android.com> am e300b8c1: Merge "DO NOT MERGE Always set/remove default routes." into gingerbread

Merge commit 'e300b8c10c306b575bbbec29d5572ba92a97785e' into gingerbread-plus-aosp

* commit 'e300b8c10c306b575bbbec29d5572ba92a97785e':
DO NOT MERGE Always set/remove default routes.
b738fb9938631a2e4540f9a9308f49e6be5565b8 13-Aug-2010 Robert Greenwalt <robdroid@android.com> DO NOT MERGE Always set/remove default routes.

Must clean up default route if a default 3g connection is replaced
by a non-default (ie, mms) connection on teh same interface.

Also stop mucking with all connections dns and routes - do it only
for the connection that has changed.

bug:2865974
Change-Id: Ifdf49080fa0413a4d826813706c809975a562dfa
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
876247784ee6202066abdefd8366f2e09e681fab 07-Apr-2010 Mikael Kanstrup <mikael.kanstrup@sonyericsson.com> DO NOT MERGE WLAN: Reset power save mode to startup value after DHCP response.

When the driver was configured to run with power save mode disabled the
power save mode incorrectly got reverted back to AUTO mode right after
DHCP response. The power save mode value is now saved so that the device
properly reverts back to a previous mode after DHCP response.

Change-Id: Ie68cd107872d233bf422e24130a1eb9f6432db91
Bug: 2834260
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
0d25534fed91f636def5776ddc4605005bd7471c 28-Jul-2010 Irfan Sheriff <isheriff@google.com> Split WifiStateMachine from WifiStateTracker

Notifications handled in WifiService. WifiStateTracker tracks
state for connectivity service

Change-Id: Idb0cf494898d28712af0f95f9e60c5417cd4a053
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
34fe791453ec139086237d9ac902d9a502de0798 29-Jul-2010 Irfan Sheriff <isheriff@google.com> Handle loss of supplicant events at start

If the supplicant events are lost even before connection,
we stay stuck without doing IP address.
The earlier implementation used polling at connection to handle
this case.
A disconnect after connection handles this cleanly.

Bug: 2876987
Change-Id: I7509c5f332f87b91e1ff8438cf859a0e49df2e6d
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
22c2b25ad7c6ed175831bd2421ee110a343c78dd 28-Jul-2010 Irfan Sheriff <isheriff@google.com> sticky broadcasts dont need system ready check

Fix an issue where checking for system ready status
for sticky broadcasts can lead to boot up with wifi
turned on and settings showing incorrect status.

Bug: 2876746
Change-Id: Iae39855c255513e28a13bd819b3d14d81fbaba43
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
a2a1b911a31dd94ee75e94845f762b91f1db1368 07-Jun-2010 Irfan Sheriff <isheriff@google.com> Refactor WifiStateTracker

Implement WifiStateTracker as a HSM.

Change-Id: Ic12fd78f1f183b5c4dea8ad2301002267ceff0cb
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
47f69fe2999e46004f2f2463b70d38de9ff7079a 16-Jun-2010 Robert Greenwalt <robdroid@android.com> Pass network properties to ConnectivityService.

Used as a bag to hold ipaddr, gateway, dns, proxy info.
addr's are InetAddresses for v4/v6 use. Cleaning up some old v4-only code

bug:2655015
Change-Id: I7ac886fe5c519e8bab42f49cd82a5189d9c9ab59
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
3b9f0a33a110d01e587ffd5ec7708af68723ad4b 21-Jun-2010 Jean-Baptiste Queru <jbq@google.com> Recover a handful of commits that were reverted earlier
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
6c9a30045b1e6b9ef5d756e0a9657576c546c9bd 21-Jun-2010 The Android Open Source Project <initial-contribution@android.com> merge from froyo-plus-aosp

Change-Id: I36dd4460cae6e3212d724e70ff1091cb791670cd
bd580127fca2797ba1a0f6653fe4cb2fd427ec83 16-Jun-2010 Irfan Sheriff <isheriff@google.com> am 1af48920: am f897b443: Fix driver stop check

Merge commit '1af489205a3942630e6203237213e98ef53d4118'

* commit '1af489205a3942630e6203237213e98ef53d4118':
Fix driver stop check
1af489205a3942630e6203237213e98ef53d4118 16-Jun-2010 Irfan Sheriff <isheriff@google.com> am f897b443: Fix driver stop check

Merge commit 'f897b443fed5c88c6b12e3fa1da72f231db67673' into gingerbread-plus-aosp

* commit 'f897b443fed5c88c6b12e3fa1da72f231db67673':
Fix driver stop check
f897b443fed5c88c6b12e3fa1da72f231db67673 15-Jun-2010 Irfan Sheriff <isheriff@google.com> Fix driver stop check

- Remove check for supplicant command: setScanResultHandling
- Add check for stopDriver
- Fix condition for rest of commands

Bug: 2771298
Change-Id: I1262b2228814c4f6a4c251390af2f445c5f47234
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
14f2ef4c9da27a3d58d65dc9f684c5f764ee279a 15-Jun-2010 Robert Greenwalt <robdroid@android.com> Move the net transition wakelock to ConnService.

When the default network goes down we lose the wake-on-incoming-data capability
until the new net is brought up and apps rebuild their connections. We fixed this
in Wifi, but it's a general connectivity issue, not a wifi issue so moving the
mechanism to connecitivty so other networks can use it.

bug:2734419
Change-Id: I39b5d825eb6b548bd9bb8f179b89254f4db53147
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
7d10df4e2402c55dc827cb6675a15957071c00af 15-Jun-2010 The Android Open Source Project <initial-contribution@android.com> merge from open-source master

Change-Id: I0684cac9eb230d864614aef0634c072f4e3ef6a3
9bf3bb21c097cc96f30d9bf3ec7dea62a74a738b 09-Jun-2010 Szymon Jakubczak <szym@google.com> - updates NetUtils to use new libnetutils headers
- updates WifiStateTracker to track net.XXX.dnsX properties for name servers
- removes dhcp from WifiNative (use NetworkUtils instead)

Change-Id: Ic69ff253e8784cad34e9291e7970ee38bfa235b9
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
fa804aa367e4c5c52c8a92d489b1a4ef405811f7 15-Jun-2010 The Android Open Source Project <initial-contribution@android.com> merge from open-source master

Change-Id: I227bf1b5f1de8f858df72d58a4463aed5cc09cbc
baccb91ece4ac650cae465ae36f5d7397a1f32af 02-Jun-2010 Kenny <gongwuchun@gmail.com> Fix the ssid display issue

Reproduce steps:
1. Set a special AP name that contains "=" (looks like "-=^-^=-");
2. Connect to this AP;
3. The display of ssid will be incorrect;

Change-Id: Idc7433a42cf59932f5fb147f5500e0175f745399
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
e377032899fd7a9f88ad1313847e77c098b9f248 14-Jun-2010 The Android Open Source Project <initial-contribution@android.com> am 864c68ea: merge from froyo-plus-aosp

Merge commit '864c68ea452baa0f4f298faf2155af45a9b6d60c'

* commit '864c68ea452baa0f4f298faf2155af45a9b6d60c':
Added an addAll to the ArrayAdapter
WLAN: Reset power save mode to startup value after DHCP response.
Add PageUp and PageDown hot keys
Should accept "application/vnd.wap.multipart.alternative" message.
replaced deprecated getIntent with parseURI
864c68ea452baa0f4f298faf2155af45a9b6d60c 14-Jun-2010 The Android Open Source Project <initial-contribution@android.com> merge from froyo-plus-aosp

Change-Id: I9cede57e10df9d6ba411b2960a77d7b9b60a1489
0631c608b0997efe5c0bd8e8955e65f1a7b3f32c 12-Jun-2010 Irfan Sheriff <isheriff@google.com> merge from open-source master

Change-Id: I8a950276787e9439420db396d0e32f88bd6e04cc
9e30a6e374c0ac154d6ea256f50597c4b0b63cca 11-Jun-2010 Irfan Sheriff <isheriff@google.com> am 749defb0: am f4f614f5: am 9f2a0115: Merge "Remove indefinite DHCP retries" into froyo
f4f614f5edeeceddf1145df73b30f7066d00d7fa 11-Jun-2010 Irfan Sheriff <isheriff@google.com> am 9f2a0115: Merge "Remove indefinite DHCP retries" into froyo

Merge commit '9f2a0115220c8e288c32d8cf90e235a2f2be115b' into kraken

* commit '9f2a0115220c8e288c32d8cf90e235a2f2be115b':
Remove indefinite DHCP retries
60d0d22c75ef49d151290592652b92f3e199679b 10-Jun-2010 Irfan Sheriff <isheriff@google.com> Remove indefinite DHCP retries

Replace indefinite DHCP retries
with a sufficiently large retry count

Bug: 2761057
Change-Id: I4570b74476aa78c71c73e06c2aafac33d924e867
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
d649c12815bcf944b2c97371f3f60716a42a1557 10-Jun-2010 Irfan Sheriff <isheriff@google.com> Make NetworkStateTracker an interface

As part of the WifiStateTracker cleanup, need
to have NetworkStateTracker as an interface.

Change-Id: I2ac48d7e4c7274ac4df40bc3b8591b182956a936
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
ea8bd1d1676dd96f8f9726bb8f67fa18dec7b9c1 07-Apr-2010 Mikael Kanstrup <mikael.kanstrup@sonyericsson.com> WLAN: Reset power save mode to startup value after DHCP response.

When the driver was configured to run with power save mode disabled the
power save mode incorrectly got reverted back to AUTO mode right after
DHCP response. The power save mode value is now saved so that the device
properly reverts back to a previous mode after DHCP response.

Change-Id: I5035aad10146812ecef1be8ea4b22a03e230ccc9
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
02648a4b8422733ed401f07edf8e426318bb2f8d 18-May-2010 Robert Greenwalt <robdroid@android.com> Clean up APN notifications.

Add APNType info to notifications so you can tell what's happening. Now, even if a new APN
shares a connection with an already-connected-to- apn type, the new type will get all
the connecting and connected messages on connect and disconnecting/disconnected on disconnect
even though the shared connection remains connected.

Cleaning out the hacks MobileDataStateTracker needed to deal with the old situation.
bug:2226092

Change-Id: Iddd7421d6b91cda7c8405f9c3d5404ac04ef8e42
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
740e39be6af3e366a4b82c030b5ea67ab144b42a 02-Jun-2010 Jaikumar Ganesh <jaikumar@google.com> Pass BluetoothDevice to the Bluetooth Headset calls.

This is to support multiple headsets at the same time, atleast
at the framework level.

Change-Id: I91d05c6c2828c9a09d00806d5e79f1e9c9c7cf84
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
2d1a6e9429ea5cec8aa45e0508f97ab4573c9f09 19-Apr-2010 Irfan Sheriff <isheriff@google.com> Reset notification state on wifi enable

Bug: 2600111
Change-Id: Ifaa63cd7c05dfa27fbd851de6f7e92f7fc38907b
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
3bf504df9fc1971078fdde7eed418a0dd8f601e2 23-Mar-2010 Irfan Sheriff <isheriff@google.com> Fix WakeLock issue for driver stop

Due to message removal, wakelock could be held forever.

Do a timer only based wakelock release until we do this
more cleanly in ConnectivityService for later release.

Also, add an optimization to prevent use of wakelocks when driver is
already stopped.

Bug: 2529883
Change-Id: Ia1c2ddd44213ef3aa609855613bf155945bef8e4
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
49de491379fc56960d00ff6c52472fe1a7d907a7 22-Mar-2010 Irfan Sheriff <isheriff@google.com> Use a single mWifiState instance

mWifiState was split up to speed up access
of wifi state when things are synchronized.
Use a single atomic state variable throughout.

Change-Id: I345981e3ffa3d2b0b7e70a5c6efc43185cba9062
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
90dd21eff5f4799dd770a6e1a0390ac68734429a 22-Mar-2010 Brad Fitzpatrick <bradfitz@android.com> Make getting wifi state lockless.

Previous it was synchronized on the same lock that was held while
transitioning wifi states, effectively making it impossible to ever
find out about such states, and worse: making calls during transitions
block.

This manifested itself in a really laggy power control widget, which
I'm working on fixing in general in a separate change.

Change-Id: Ia34af98c73d7f5662e41360a213df87f6adaf130
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
4f31a00376fa0907ab167af51525455ef4b4e638 18-Mar-2010 Irfan Sheriff <isheriff@google.com> Fix null pointer exception

Bug: 2525763
Change-Id: If2f334187af26e0352d754d7e00a9ca3efc5dffa
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
0f344060096329f091af20a16d69547a47c1a9d5 10-Mar-2010 Irfan Sheriff <isheriff@google.com> Clean up native access from framework

Driver commands should be issued when driver has started.
Supplicant commands should be issued when Wi-Fi is enabled
Bug: 2339709
Bug: 2371609
Change-Id: I9ba6ddfa0cf4c4b8ca049b0eb7eaaa8edb42bad1
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
a8fbe1fb74d3bd40b73c90c85ac25e5176475ca5 09-Mar-2010 Irfan Sheriff <isheriff@google.com> Re-organize access to native interface through WifiStateTracker

Bug: 2339709
Change-Id: Ibb2eeb09b83dc24897116ea15a9016f81a08d442
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
c1ba7431a45dbf10f211e7b0bbf5b03e64bf020c 24-Feb-2010 Irfan Sheriff <isheriff@google.com> Remove redundant interface disable

Bug: 2274930
Change-Id: Ia1eafe422f6e18b826e53e72a306dd2961b948a6
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
102d05fa9135bef5c6b875f9a6485566b06ebd18 05-Feb-2010 Irfan Sheriff <isheriff@google.com> get DHCP IP on each connection

The IP state was not being refreshed when the supplicant transitions
from COMPLETED to ASSOCIATED to COMPLETED. This can lead to
a connected state with no real connection due to old IP settings.
The fix refreshes IP on each connection.

Bug: 2329261
Change-Id: I38cd56369ee2d8ab3e0f06f5c9f5712b9b2f35a0
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
0049a1bf3f8bae3a10cfeff38aefce215bf1298b 14-Jan-2010 Irfan Sheriff <isheriff@google.com> Blacklist APs instead of disable

We currently disable networks upon too many reconnects. This leads to asking
the user input for reconnects. Blacklist it instead.

Bug: 2129037
Change-Id: I23d69daf3964c066ed7f70d32fefb81016f19aa2
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
7aac5547daf54005243c5d685cf60c5a4ff74a44 23-Dec-2009 Irfan Sheriff <isheriff@google.com> Synchronize all WifiNative calls

Some of the native calls were left unsynchronized in the framework. Pre-empted IOCTL call
interrupted by another call from the framework cannot be handled in the driver.

Bug: 2310455
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
1c633fc89bae9bf0af6fe643ac7ad2e744f27bed 09-Dec-2009 Dianne Hackborn <hackbod@google.com> Implement API to have new broadcasts replace existing broadcasts.

Use this in various places where it should serve no purpose to deliver
both broadcasts. This is intended to reduce somewhat the flurry of
broadcasts that we churn through during boot.
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
7614d3d819315b1ca15088e617f12d0f0ea41b06 09-Dec-2009 Robert Greenwalt <robdroid@android.com> am 68b15b68: Porting change I064698b3 from mr2 to eclair.

Merge commit '68b15b68497e373fe63a13f11e18349a738a7989' into eclair-mr2

* commit '68b15b68497e373fe63a13f11e18349a738a7989':
Porting change I064698b3 from mr2 to eclair.
68b15b68497e373fe63a13f11e18349a738a7989 09-Dec-2009 Robert Greenwalt <robdroid@android.com> Porting change I064698b3 from mr2 to eclair.

Add support for "HANGED" driver state - we'll reboot the driver when requested (by the driver).

bug: 2310372
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
f75aa36fc86989ca3bae2f46207e6b897a32d7ae 23-Oct-2009 Robert Greenwalt <robdroid@android.com> Add wifi "HANGED" driver state triggering reload.

The driver can now report to us that they are hosed and we'll shut
down wifi and restart it - only to be used as a last resort.

Also fixing synch problem with updateWifiState.

bug: 2173119
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
e2d155a51e68694e17fa6e27d05c928215a5dbcf 21-Oct-2009 Robert Greenwalt <robdroid@android.com> Add a new API for initing Wifi multicast filtering

Gets rid of the old method which generated Log noise.

bug: 1973855
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
1538dba4b00f767ddc4010e05b5983d6377999c2 08-Oct-2009 Robert Greenwalt <robdroid@android.com> Make FWK start a wifi scan if supplicant forgets. (do not merge)

Waits 15sec after getting a DISCONNECTED or INACTIVE state. Also tracks
the number of supplicant state transitions. After the period is up
if we haven't received any more supplicant state transitions, it requests a scan.

bug: 2168081
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
b106118c2cc558a9ea2ade69ff47766280a35e17 08-Oct-2009 Robert Greenwalt <robdroid@android.com> Make FWK start a wifi scan if supplicant forgets.

Waits 15sec after getting a DISCONNECTED or INACTIVE state. Also tracks
the number of supplicant state transitions. After the period is up
if we haven't received any more supplicant state transitions, it requests a scan.

bug: 2168081
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
bb5626c569bb9ccedd7b7d4197a2dace4c997c49 01-Oct-2009 Robert Greenwalt <robdroid@android.com> Stop bringing the wifi interface up on reset.

The driver will bring up the interface when needed and bring it up
at reset time has caused some problems.

bug: 2144870
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
7121ac5644f222763c99975bcce93c28775a6386 22-Sep-2009 Chung-yih Wang <cywang@google.com> Fix the issue of 'Wifi framework is not aware of state change'

Problem:
Connect to AP with WEP security.
Change AP's WEP password.
Phone will quickly reassociated (less than in 5 sec) and will not restart full "reconnect".
Indication will show "connected" but it will be no network access.

Fix: (for non-static IP only)

With WEP mode, the association could be successful if we change the AP's WEP password. However,
the phone wont be able to send/recv any traffic with the old password. What we could quickly
fix here is to send the DHCP request if the network is not configured to use static IP. We
can do nothing but ping access point to see if it we are able to communicate with it.
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
4282a5bad44b1b994a26a8eb02051f29f410d33a 17-Sep-2009 Robert Greenwalt <robdroid@android.com> Reintroduce wifi RssiApprox, reducing driver calls

Only do the full signal strength calc when we need to, otherwise use
an approximate value.

This change was introduced a while back but was lost in some merge.

bug: 2125543
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
7c9bf7caa2936e8b76598be9fffea980d81c61d3 12-Sep-2009 Robert Greenwalt <robdroid@android.com> Don't init wifiChannels until after supplicant up

The supplicant can take up to 15 seconds to start - setting the number of wifi channels
immediately after requested wifi start often will fail.

Changed to set the number of channels when the supplicant is reported as alive.

bug:2083601
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
bd022f423a33f0794bb53e5b0720da2d67e4631c 15-Aug-2009 Nick Pelly <npelly@google.com> Bluetooth: API change.

Split BluetoothDevice into BluetoothDevice and BluetoothAdapter.

BluetoothAdapter: Represents the local BT adapter. Operations on the local
adapter (start a scan, etc).
BluetoothDevice: Represents a remote BT device. Operations on remote devices
(pair, connect, etc).

IBluetoothDevice.aidl -> Bluetooth.aidl
BluetoothDeviceService.java -> BluetoothDeviceService.java

TODO:
Javadoc
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
6ee4b5b504a2542b47befe5d6c5f9aaff9b40ed9 28-Jul-2009 Mike Lockwood <lockwood@android.com> Wifi: Make sure the interface is up before telling supplicant to start the driver.

This fixes a problem that resulted in the interface not being up when resuming
an authenticated connection.

Signed-off-by: Mike Lockwood <lockwood@android.com>
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
e2a5385c70b48b57476a0c8c52bad4ea40398641 15-Jul-2009 Mike Lockwood <lockwood@android.com> resolved conflicts for merge of f7703519 to master
f32be166d56302b59c242a1296a6b03862f3c061 14-Jul-2009 Mike Lockwood <lockwood@android.com> wifi: Disable RSSI polling when the screen is off.

Signed-off-by: Mike Lockwood <lockwood@android.com>
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
0900f3657664d9046e6723825fd32b244eef2b6c 10-Jul-2009 Mike Lockwood <lockwood@android.com> wifi: Keep the WLAN network interface up whenever wifi is enabled.

We now only bring it down briefly and bring it back up again when
we want to reset the interface.

Signed-off-by: Mike Lockwood <lockwood@android.com>
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
622f82a0c78aa69d9b3b29ea0617cb8002b57c16 10-Jul-2009 Mike Lockwood <lockwood@android.com> WifiService: Remove hidden AP counting logic for active/passive scanning mode.

Apparently this code was not 100% correct, and now the Wifi driver is responsible
for setting the scan mode to active for hidden networks, so this is no longer needed.

Signed-off-by: Mike Lockwood <lockwood@android.com>
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
6811355d9683412cb3651e75c59c3256ceaddcec 09-Jul-2009 Android (Google) Code Review <android-gerrit@google.com> am 463aacfb: Merge change 6661 into donut

Merge commit '463aacfbd220c9ef2f6ed915d54092289fdac05b'

* commit '463aacfbd220c9ef2f6ed915d54092289fdac05b':
wifi: WifiManager.startScan() will now do passive scans by default.
a5ec95cdb1a7d2024249277dff1f99d0046c9b56 08-Jul-2009 Mike Lockwood <lockwood@android.com> wifi: WifiManager.startScan() will now do passive scans by default.

Active scans will only happen if a hidden AP is in use, or if the new method
WifiManager.startScanActive() is called.
This fixes some audio playback problems with bluetooth A2DP.

Signed-off-by: Mike Lockwood <lockwood@android.com>
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
56c59da434354e1efaebbd0e5c135814605f9842 10-Jun-2009 Mike Lockwood <lockwood@android.com> WifiStateTracker: Add support for positive RSSI values.

Signed-off-by: Mike Lockwood <lockwood@android.com>
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
91f22f901bee5d52d81ca4070a1b187ac8b90dad 09-Jun-2009 Robert Greenwalt <robdroid@android.com> Use new wifi cmd rssi-approx when polling.

Cheaper approx call should be used when polling every 3 sec for
wifi signal strength. Fixes bug 1903653.
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
96cdc61c69aa735e65295a50e3e2922425b3c877 28-May-2009 Android (Google) Code Review <android-gerrit@google.com> am 1e2e44e9: Merge change 2365 into donut

Merge commit '1e2e44e900cb9a25d548e27a20d65292a7f321bc'

* commit '1e2e44e900cb9a25d548e27a20d65292a7f321bc':
Fix wifi multicast API for public use.
Revert "Bug fixes and performance improvements"
fc1b15cfbfc5f69235ec1f367abd7a909381cd05 23-May-2009 Robert Greenwalt <robdroid@android.com> Fix wifi multicast API for public use.

Applying API review comments and taking it public.
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
b5010cc3c33c74cc406a70f34f93d330a3f0db6a 22-May-2009 Robert Greenwalt <robdroid@android.com> Add carrier/mcc factors to wifi-channel decision.

Uses ro.carrier and MCC when available to try to set
(non-persistingly) the number of allowed wifi channels.
Part of the fix for 1625953.
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
58ff0217a617d5b03d18f0ef532f254f8ba6de2b 20-May-2009 Robert Greenwalt <robdroid@android.com> Increment BatteryStatsImpl's VERSION.
That'll make it stop trying to interpret older records with the new format.
Also applied other comments involving name changes to remove un-needed 'Wifi' labels in WifiManager API, etc.
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
d9c32bc838cb618dcbc1e48df02a34b6596b8930 18-May-2009 Mike Lockwood <lockwood@android.com> WifiService: Wifi power management change

Put Wifi into an idle state immediately if the screen is turned off and the Wifi interface has no IP address.
We will continue to keep Wifi up for 15 minutes in the case where the screen is turned off when Wifi is fully connected.
This will allow us to go into a low power mode faster when Wifi is not actively being used.
It also avoids bringing up Wifi if the user just turns on the screen for a few seconds to check the clock, etc.

Fixes bug b/1736920

Signed-off-by: Mike Lockwood <lockwood@android.com>
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
5347bd4cda2b6afc18f8acab48e52131f35ed13c 14-May-2009 Robert Greenwalt <robdroid@android.com> Add wifi multicast filter api (enable/disable).
Fixes 1833432. Automatically re-disables any request when the app
exits/crashes. Also hooked into Battery Stats for power managment analysis.
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
5711fadfc48f0e77bc25a91ef36c76acb0d2f55a 28-Mar-2009 Eric Shienbrood <> AI 143266: am: CL 143124 Fix bug #1731826, in which auto-connect to remembered networks does not
take place.
This has the same underlying cause as bug #1739874, so this fixes that
bug as well. The problem was that if the supplicant was in the DORMANT
state at the time a scan-only Wi-Fi lock was released, the command to
stop the Wi-Fi driver would never be issued. This had two main results:
first, the driver would stay awake when the screen was blank and it was
supposed to be sleeping, leading to excessive battery drain, and second,
when the screen was turned back on, there would be no DRIVER-STARTED
event generated (because the driver was already running). The
DRIVER-STARTED event is the trigger for the framework to issue a
RECONNECT command to the supplicant to cause it leave the DORMANT state
and look for available remembered networks.
To assist in tracking down this problem, and any such problems in the
future, I added four counters to keep track of how many times full and
scan-only Wi-Fi locks are acquired and released. The counter values
are output in the dump() method of WifiService. While doing this, I
noticed that because of missing "break" statements, the battery stats
that keep track of how much time Wi-Fi locks are held were including
the time for full locks in the time reported for scan-only locks.
Original author: ers
Merged from: //branches/cupcake/...

Automated import of CL 143266
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
d4c5f8919b0522bcaab41a5863c313fec52d3a79 25-Mar-2009 Eric Shienbrood <> Automated import from //branches/donutburger/...@140679,140679
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
b2a3dd88a53cc8c6d19f6dc8ec4f3d6c4abd9b54 09-Mar-2009 The Android Open Source Project <initial-contribution@android.com> auto import from //branches/cupcake/...@137197
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
9066cfe9886ac131c34d59ed0e2d287b0e3c0087 04-Mar-2009 The Android Open Source Project <initial-contribution@android.com> auto import from //depot/cupcake/@135843
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
d83a98f4ce9cfa908f5c54bbd70f03eec07e7553 04-Mar-2009 The Android Open Source Project <initial-contribution@android.com> auto import from //depot/cupcake/@135843
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
da996f390e17e16f2dfa60e972e7ebc4f868f37e 13-Feb-2009 The Android Open Source Project <initial-contribution@android.com> auto import from //branches/cupcake/...@131421
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
d24b8183b93e781080b2c16c487e60d51c12da31 11-Feb-2009 The Android Open Source Project <initial-contribution@android.com> auto import from //branches/cupcake/...@130745
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
b798689749c64baba81f02e10cf2157c747d6b46 10-Jan-2009 The Android Open Source Project <initial-contribution@android.com> auto import from //branches/cupcake/...@125939
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
f013e1afd1e68af5e3b868c26a653bbfb39538f8 18-Dec-2008 The Android Open Source Project <initial-contribution@android.com> Code drop from //branches/cupcake/...@124589
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java
54b6cfa9a9e5b861a9930af873580d6dc20f773c 21-Oct-2008 The Android Open Source Project <initial-contribution@android.com> Initial Contribution
/frameworks/base/wifi/java/android/net/wifi/WifiStateTracker.java