• Home
  • History
  • Annotate
  • only in /frameworks/opt/net/wifi/service/java/
History log of /frameworks/opt/net/wifi/service/java/
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
affb7a1ef39dba5ec6febdf7fafc76cc52db9aca 11-Oct-2016 Peter Qiu <zqiu@google.com> Do not send ANQP queries when no Hotspot 2.0 provider is configured

Sending ANQP queries without Hotspot 2.0 provider is only needed
for supporting Hotspot 2.0 Release 2. Since the Release 2 app
(OSU) is not ready in NYC, remove the sending of ANQP queries in
this situation to avoid unnecessary power consumptions.

Bug: 31989358
Test: run frameworks/opt/net/wifi/tests/wifitests/runtests.sh
Test: manual - verify no ANQP queries being sent with no Hotspot 2.0
provider configured
Test: manual - install a Boingo Hotspot 2.0 configuration, verify
device will automaically connect to a Boingo AP

Change-Id: Id0bcec28c36169079fbf0e96e0429fe6cef94f03
om/android/server/wifi/WifiConfigManager.java
7d7c671b6dea0c8f947afdf9300548b797db4483 23-Sep-2016 Randy Pan <zpan@google.com> Merge "WCM: forced connectivity scan" into nyc-mr1-dev
8cf5bfbee9d70dac8c83729a979bd7208a47d44d 21-Sep-2016 Randy Pan <zpan@google.com> WCM: forced connectivity scan

WCM starts a full band single scan when user forces a connectivity
scan and wait for the full band scan results to make network
selection.

Bug: 30897947
Test: unit tests and manual test
Change-Id: Ie220c25dd60a0534afbf33f62691f32515f7062b
om/android/server/wifi/WifiConnectivityManager.java
om/android/server/wifi/WifiStateMachine.java
d76a14997a969ea44daa47756dcc8f83aee96935 20-Sep-2016 Mitchell Wills <mwills@google.com> Ignore disconnect messages that don't indicate the channel is dead

Bug: 29368784
Test: mmma frameworks/opt/net/wifi/tests && runtest frameworks-wifi
Change-Id: I5ae3665898565379b101c4ac0c5570c9debb1228
om/android/server/wifi/scanner/WifiScanningServiceImpl.java
5e816a8c6f96076f69dd8bbb0110203d92940c4e 20-Sep-2016 Glen Kuhne <kuh@google.com> Merge "Wifi Metrics: dumpsys arg for clean output" into nyc-mr1-dev
dbba9f8bd63a53a6f2750949e2a0cc0299006e22 20-Sep-2016 TreeHugger Robot <treehugger-gerrit@google.com> Merge "WifiStateMachine: Switch to ACTION_LOCKED_BOOT_COMPLETED" into nyc-mr1-dev
9ff7dea01b09f658492b7b8fa122695e56d28cdc 17-Sep-2016 Glen Kuhne <kuh@google.com> Wifi Metrics: dumpsys arg for clean output

Modify the way dumpsys works in wifi so that
'dumpsys wifi wifiMetricsProto clean'
outputs only serialized base64 encoded wifi metrics proto bytes.

BUG=31556602
Test: Created new unit test

Change-Id: Id1aa319a03a5e2bcffb1276057cb770679015abd
om/android/server/wifi/WifiMetrics.java
om/android/server/wifi/WifiStateMachine.java
b5cec87f420d63c6dba97f85b4229fbeb5f13e4b 17-Sep-2016 Roshan Pius <rpius@google.com> WifiStateMachine: Switch to ACTION_LOCKED_BOOT_COMPLETED

Use the |ACTION_LOCKED_BOOT_COMPLETED| broadcast instead of
|ACTION_BOOT_COMPLETED| broadcast to initiate connection attempts. For
FBE enabled devices, the |ACTION_BOOT_COMPLETED| is only received after
user unlock.

BUG: 31189385
Change-Id: If7c511076aafc37760e050a116a05290780793c4
om/android/server/wifi/WifiStateMachine.java
891bba121efd35038a2b17744779acc01ead8ad0 12-Sep-2016 Mitchell Wills <mwills@google.com> Merge "Add a flag to indicate if a ScanData is for a scan for all channels" into nyc-mr1-dev
918820374a229eb03257fee0d6baa1f00ec5c919 12-Sep-2016 Wei Wang <weiwa@google.com> Merge "DO NOT MERGE: Remove spam logs for Wifi RTT" into nyc-mr1-dev
4e1f32efceee1db37bfb1e2624b434dbfb055686 07-Sep-2016 Mitchell Wills <mwills@google.com> Add a flag to indicate if a ScanData is for a scan for all channels

BUG=30897947

Change-Id: I989a25dd3df3f473090b76b4e3cb798a2d513490
om/android/server/wifi/scanner/ChannelHelper.java
om/android/server/wifi/scanner/KnownBandsChannelHelper.java
om/android/server/wifi/scanner/NoBandChannelHelper.java
om/android/server/wifi/scanner/SupplicantWifiScannerImpl.java
0a0ee55c5feb49529d9c01fb0110579e2b7a0834 08-Sep-2016 Randy Pan <zpan@google.com> WSM: Fix roaming log message

Fix the log message which prints out the roaming target network
BSSID.

Bug: 31317756
Change-Id: I4a7d2dbacbbaa73d4141be306e58369eba16fbba
om/android/server/wifi/WifiStateMachine.java
fbc0f388aacac432f5abfadfd25e212d5e4b159b 08-Sep-2016 Randy Pan <zpan@google.com> QNS: currently connected network BSSID

Always get the currently conntect network BSSID from WifiInfo in
case that firmware roaming switched the device to a different
BSSID than the one previously chosen by QNS.

Bug: 31317902
Change-Id: I6f69144e2a386481d127dbd1ba997e2879c6e000
Tests: unit tests and manual test
om/android/server/wifi/WifiQualifiedNetworkSelector.java
22fcd83c560e45deaadb22795dd2683ebd923914 15-Aug-2016 Sohani Rao <sohanirao@google.com> Define and track Wifi scores to report Wifi metrics

Add a proto definition to track counts corresponding to wifi scores
Scores are calculated in WifiScoreReport and metrics are updated in
calculateAndReportScore. Wifi scores are limited in a range [0, 60]
where the max score is the base score assigned by Network Agent.
To ensure the size of the map is limited, any scores out of this
range will be dropped. Updated test framework to validate score
tracking and check out of bound values are dropped. The unit tests
also ensure the base score is within reasonable limits.
Merge details:
This is a merge from CL 1326502 on master. Merge conflicts were
mainly due to code placement and only major difference was the call
to calculateScore as it has different arguments on the branches.

BUG=29418013

Change-Id: Iaf22ed7dc7fb73413739507406ec88d7719b362e
TEST=Wifi Unit tests, Walk tests and log scores via dumpsys
DEVICE=angler
om/android/server/wifi/WifiMetrics.java
om/android/server/wifi/WifiScoreReport.java
om/android/server/wifi/WifiStateMachine.java
7a36be372edfa3f7fe0e37320b9b21a5fbadf277 01-Aug-2016 Glen Kuhne <kuh@google.com> WiFiMetrics: Count hidden & passpoint networks

1. Extended the WiFiMetrics proto to include counts for hidden and
passpoint networks, counting these for all saved networks, connections
and scan results.
2. Extended the counting of Open, Personal and Enterprise network to
include scans.
3. Extended ConnectionEvent logging to detect and flag passpoint network
connections.
4. Implemented the checks that detect if a scan Result is a hidden network.
While I was here: Cleaned up a couple old WifiMetrics <TODO>s, which we will not be doing.
BUG=28634987

Change-Id: I2e22bf8d79ccbda84ead700272ff0f1b0f13d2e7
Test: Extended unit tests, executed manually
om/android/server/wifi/WifiConnectivityManager.java
om/android/server/wifi/WifiMetrics.java
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/hotspot2/NetworkDetail.java
om/android/server/wifi/util/InformationElementUtil.java
1c50de232acb3d6148c454941a6b9a79e0663b81 26-Jul-2016 Glen Kuhne <kuh@google.com> WiFiMetrics: Add LastResortWatchdog success metric

Added a metric that tracks how often WifiLastResortWatchdog triggers
successfully fix wifi, allowing wifi to connect to a network after
triggering. It does not count a success, if the connection occurs
after a new network becomes available.

BUG=30407550
TEST=Unit Tests

Change-Id: I68d1f003fee9eb8074c04db141bd7b5c3089d57b
om/android/server/wifi/WifiLastResortWatchdog.java
om/android/server/wifi/WifiMetrics.java
a284841edf33e4070748816a034c47f996bfeb81 12-Aug-2016 mukesh agrawal <quiche@google.com> WifiMetrics: add metric for alert reasons

Add metric to track the number of alerts triggered
by Wifi driver/firmware. This will give us a
concrete measurement of stability in the field.

BUG=29158746
TEST=tests/wifitests/runtests.sh

Change-Id: I435e5d792a97c197fe685e5b2c05d7b8efda62f0
om/android/server/wifi/WifiLoggerHal.java
om/android/server/wifi/WifiMetrics.java
om/android/server/wifi/WifiStateMachine.java
f4bd8974d7f3ce05eb6e7325cabcb706d6ac5999 05-Aug-2016 Wei Wang <weiwa@google.com> DO NOT MERGE: Remove spam logs for Wifi RTT

Removed debug logs for RTT params and adjusted log levels.

Bug: 30115441
Change-Id: I89d6757c8ebb59851eff67f91abe71b095ade327
om/android/server/wifi/WifiNative.java
0fd8e37b6285c448d971fb4b61b287b5b0a27c6f 15-Jul-2016 zhangshuxiao <zhangshuxiao@xiaomi.com> Some networks can not connect automatically.

Becasuse the key of scan cache is supplicant's networkid,
when supplicant process restart, the supplicant's networkid
may be regenerated, so clear scan cache when loading the
configured networks.

BUG: 30158982

Change-Id: Iec94e8eef517bd0411eb0be53a31cdb34a1494cf
Signed-off-by: zhangshuxiao <zhangshuxiao@xiaomi.com>
om/android/server/wifi/WifiConfigManager.java
9d60f8726575683f345cfe527e2d1afb2367c92f 22-Aug-2016 Randy Pan <zpan@google.com> Merge "Track if untrusted wifi network is allowed" into nyc-mr1-dev
8bc512d77b002fdd4a4a920ab8737e70f74a4f0d 22-Aug-2016 Randy Pan <zpan@google.com> Merge "Fix WiFiNetworkAgent#unwanted" into nyc-mr1-dev
d5bfc592dd08cd01395497f2463b14d3fb244bd6 19-Aug-2016 Roshan Pius <rpius@google.com> Merge changes Ib328abd8,If75993eb into nyc-mr1-dev

* changes:
SupplicantWifiScannerImpl: Restart PNO on settings change
SupplicantWifiScannerImpl: Ignore PNO stop failure
1bf983a4211f547593a60523e43112ecdb5c8997 15-Aug-2016 Roshan Pius <rpius@google.com> SupplicantWifiScannerImpl: Restart PNO on settings change

When a new network is added, ConnectivityManager will stop/restart PNO
scans. However because of the 5 second debounce logic in HwPnoDebouncer,
this toggle will not be sent to wpa_supplicant. So, force restart PNO in
SupplicantWifiScannerImpl whenever there is a change in the network list .

PS: wpa_supplicant already has some internal logic to handle network
additions when PNO scans are running. But, not sure if this is working
as intended.

BUG: 30833790
Change-Id: Ib328abd866298a8a672a2f19fc863ee515dcbe74
TEST: Added unit tests
om/android/server/wifi/WifiNative.java
om/android/server/wifi/scanner/SupplicantWifiScannerImpl.java
f49876f2c98b9ab5298cdc3eeca242102ed0166d 10-Aug-2016 Glen Kuhne <kuh@google.com> resolve merge conflicts of b843fca to nyc-dev
am: 2709be1ecb

Change-Id: I41ad20f61dda33ba0b3a938330f12cd273f35ae3
2709be1ecb0062e301dc2d3ea9eef11951a5b958 10-Aug-2016 Glen Kuhne <kuh@google.com> resolve merge conflicts of b843fca to nyc-dev

Change-Id: I9dd10e35d901404b6d77d9ca0f99dbc8c2294b2f
b843fca514bf16b3ba2cf2ddfec626e280dd0713 10-Aug-2016 Samuel Tan <samueltan@google.com> ANQPFactory: catch all potential parsing errors am: 6154eb070b am: eda4e04ebc
am: b3c997c5f5

Change-Id: Idec74f1035a8cb117d3898d35eae6828c59a799d
b3c997c5f528977db0ba170d17ca738d58ebedc6 10-Aug-2016 Samuel Tan <samueltan@google.com> ANQPFactory: catch all potential parsing errors am: 6154eb070b
am: eda4e04ebc

Change-Id: I50e99a7a5f781be6e9668ef6732c593f2db23376
eda4e04ebc9f382f754bfd7679d420d696c31f39 10-Aug-2016 Samuel Tan <samueltan@google.com> ANQPFactory: catch all potential parsing errors
am: 6154eb070b

Change-Id: I59977b90dd905e5a8d72275ddef0594c2b9906f5
e483fd4a3151e59b3d0a596572b4d9f035fa8424 09-Aug-2016 Roshan Pius <rpius@google.com> SupplicantWifiScannerImpl: Ignore PNO stop failure

Ignore PNO stop failures when resetting the |mCurrentPnoState| flag. The
stop PNO command failure indicates that wpa_supplicant has already
stopped PNO scan internally. So, we should reset our flag to reflect that.
Otherwise, the next attempt to turn on PNO scans will be silently ignored by
|SupplicantWifiScannerImpl|.

BUG: 30764879
Change-Id: If75993ebe3bfc853628a96a698bb5806f0da5962
TEST: Unit tests
TEST: `act.py -c connectivity_basic.config -tb basic_wifi_tethering -tc
TelLiveDataTest:test_lte_wifi_switching`
om/android/server/wifi/scanner/SupplicantWifiScannerImpl.java
41b85e0341099cc2da048e7400a72046336c1cce 08-Aug-2016 Randy Pan <zpan@google.com> Track if untrusted wifi network is allowed

Always notify WifiConnectivityManager if untrusted wifi network is
allowed right after WifiConnectivityManager is initialized.

Bug: 30634120
Change-Id: I8cb13ab476d4845ede8a0b57c3d8e20350e59926
Tests: WiFi Framework Unit Tests
om/android/server/wifi/WifiStateMachine.java
173dae04272c1b40488292f6392a922b4c4b2949 05-Aug-2016 Rebecca Silberstein <silberst@google.com> WifiStateMachine: update new mode in initial state

When WifiController calls setOperationalMode a CMD_SET_OPERATIONAL_MODE
message is sent to WifiStateMachine. When this message is received in
the InitialState, it is not handled where it is then dropped in the
default state. Dropping this message causes WifiController and
WifiStateMachine to get out of sync on the operating mode.

BUG:29938263
Change-Id: I8481af8d6826f3da18f5762833a7b145d81b74dd
TEST:runtest frameworks-wifi
om/android/server/wifi/WifiStateMachine.java
01dafe766c969517561dd9fd733ec475bc8eee5d 04-Aug-2016 Rebecca Silberstein <silberst@google.com> [DO NOT MERGE] WifiStateMachine: check verbosity level in update

When updating the setting for verbose logging, first check if we are
already at the desired setting. If we are, return from
enableVerboseLogging immediately. This avoids updating the size in the
underlying StateMachine log record vectors, and thereby avoids clearing
them.

BUG: 30675249
Change-Id: I005f236baa3149c46470e79dee3491e691908da0
TEST: runtest frameworks-wifi
TEST: manual testing
om/android/server/wifi/WifiStateMachine.java
c4d044acc589188f25b8dcd962db52e1fc08fe8d 27-Jul-2016 Randy Pan <zpan@google.com> Fix WiFiNetworkAgent#unwanted

1) No longer blacklist a network when it's unwanted by NetworkAgent.
2) Deprecate the network disable reason BAD_LINK.
3) Stop WiFi Auto_Connect attempt if neither saved Wifi network nor
untrusted WiFi network is requested.

Bug: 28558417
Tests: Unit Tests and manual tests
Change-Id: I2b245cfb357b92ed925d89603e0fefded9d6865a
om/android/server/wifi/WifiConfigManager.java
om/android/server/wifi/WifiConnectivityManager.java
om/android/server/wifi/WifiStateMachine.java
24750cd1f8148d6a935bda96f3b17f22b0c1d8bd 03-Aug-2016 Rebecca Silberstein <silberst@google.com> WifiController: correct active state after ap mode

When a device is in AP mode and wifi is toggled, the device should end
the wifi hotspot and enter the connect mode for wifi. When wifi was
toggled in ApEnabledState, a wifi toggle would trigger a switch to
StaEnabledState. This state's enter method would trigger
WifiStateMachine to start supplicant, but would not indicate it should
be in connect mode. This is done by DeviceActiveState. This CL switches
the mPendingState in ApEnabledState from StaEnabledState to
DeviceActiveState.

Added a test to WifiControllerTest to cover this situation.

BUG: 30042498
Change-Id: I0792c06521e82e07a8c36648ebbd62c8babceaff
TEST: runtest frameworks-wifi
om/android/server/wifi/WifiController.java
6154eb070b9f224a8daebf0a852d61f07d2c5cf3 20-Jul-2016 Samuel Tan <samueltan@google.com> ANQPFactory: catch all potential parsing errors

The ANQP Element parsing code that parses untrusted data broadcasted
by APs is currently untested, and might contain errors that will
trigger exceptions that can crash the system service (e.g. null pointer
exceptions).

To contain this risk, catch all possible exceptions from the invoking
ANQP element parsing code from ANQPFactory, and throw them again
as ProtocolExceptions, which users of ANQPFactory already catch.

BUG: 30230534
Change-Id: Icaba02c0e6739d94482cf4a5e704b59f8d4105b4
om/android/server/wifi/anqp/ANQPFactory.java
225b5d3d3da2356a124ce4cad4fc99d1b8303d21 29-Jul-2016 Rebecca Silberstein <silberst@google.com> [DO NOT MERGE] WifiStateMachine: better handle disconnect

Allow WifiStateMachine to disconnect by handling the CMD_DISCONNECT call
if supplicant is currently connecting. If it is not connecting, the
call will be ignored (to avoid cancelling scans and confusing supplicant).

BUG: 30507955
Change-Id: Id91f372efc180c2eb0449d7d53e24960d473690b
TEST: runtest frameworks-wifi
om/android/server/wifi/WifiStateMachine.java
800e83d2e78ebc96e0fbc69eed6cfe489ff7fec0 27-Jul-2016 Rebecca Silberstein <silberst@google.com> Merge "WifiStateMachine: ignore disconnect" into nyc-mr1-dev
83fc97d72a76fc522b774e79ad871b951560d33a 27-Jul-2016 Ningyuan Wang <nywang@google.com> Merge "Fix tethering failure when wifi is not started" into nyc-mr1-dev
fd21a7601142e03b4c93e7d1349e900cfc0a36fe 26-Jul-2016 Rebecca Silberstein <silberst@google.com> WifiStateMachine: ignore disconnect

WifiStateMachine allows tests to inject a disconnect by using the
CMD_DISCONNECT message. This message is now ignored in the
disconnecting and disconnected states. This would previously cause a
variety of failures depending on the timing due to the tests calling
disconnect before calling connect. This caused scans to be cancelled
and tests to fail.

BUG: 30313886
TEST: Created new sl4a tests (still in development) that stress test wifi
startup and connections. The specific failure is not seen with the
included changes. WiFi framework unit tests also pass.

Change-Id: I143a762f38fe3e4ecaf1be71b21553def3cfb239
om/android/server/wifi/WifiStateMachine.java
828b94eca5e0ffa67448f67a9dfb4d7eb492312a 23-Jul-2016 Randy Pan <zpan@google.com> QNS: candidate network BSSID

QNS recommends a network for WCM to connect or roam to by
returning that network's configuration with the BSSID stored
in the 'candidate' field.

In a corner case that if 1) two APs are within the same network
(SSID), 2) the two APs get exactly the same QNS score (one AP has
higher RSSI value but 2.4GHz, and the other is 5GHz but lower RSSI),
and 3) the 5GHz AP shows up in the scan results before the 2.4GHz AP,
QNS sets the wrong BSSID value. This change fixes that problem.

Bug: 30184472
Change-Id: I8c67ab194571ba17b853eae617fb659017f72969
Test: WiFi Framework Unit Tests & manual tests
om/android/server/wifi/WifiQualifiedNetworkSelector.java
37b06cd7aae7fe27cfaf1d95cc9901548765406b 20-Jul-2016 Ningyuan Wang <nywang@google.com> Fix tethering failure when wifi is not started

getCurrentCountryCode() returns the country code which we already
sent to driver.

However, sometimes when wifi and location scan are not started,
we have a valid country code but we didn't set it. In this case
getCurrentCountryCode() returns null. This will confuse SoftApManager
and break tethering. This also causes WifiApDialog not to show 5GHz
option in the UI when user creates a new wifi hotspot config.

In this CL we fix the incorrectly reported country code by adding a
function getCountryCode() which returns a valid country code regardless
of was it sent to driver or not.
SoftApManager and WifiApDialog will use this function to make decisions.

In addition, we also rename getCurrentCountryCode() to getCountryCode
SentToDriver() for better readability.

BUG=30200338
TEST=compile
TEST=unit tests
TEST=manual tests

Change-Id: I5ba576509f9f401f4d57a4628a147ac8871552c0
om/android/server/wifi/WifiCountryCode.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
58a8f2e0ac9894831dff6d7f18c9c92df6eda381 21-Jul-2016 Samuel Tan <samueltan@google.com> VenueNameElement: fix off-by-one enum bounds check am: 48ee5f1e1c am: 37ec3aff4c am: 2d03259907 am: deab674fa9
am: 2ef5e899a8

Change-Id: Ie338a574ea975993e632a1add537664749cc5b7c
2ef5e899a8cfee7ce41e9e219b271fb250ba9cf5 21-Jul-2016 Samuel Tan <samueltan@google.com> VenueNameElement: fix off-by-one enum bounds check am: 48ee5f1e1c am: 37ec3aff4c am: 2d03259907
am: deab674fa9

Change-Id: Ie553aba21c393b83166b7c225b982cddada9424e
5382acb5eb3a0448a32651dcc7fe9fd634ce0e38 20-Jul-2016 Roshan Pius <rpius@google.com> WifiScanningServiceImpl: Add ClientInfo null checks

Add missing null checks for |ClientInfo| in a few places. ClientInfo
could end up being null if there was a pending cleanup of the client
before processing of the request in the appropriate state machine.

Also, add a unit test to simulate the scenario in the bug specified.

BUG: 30241457
Change-Id: Ic4412ae03b5176764b10cba357d19086c0c09e6e
TEST: Unit tests
om/android/server/wifi/scanner/WifiScanningServiceImpl.java
deab674fa9191e4028df00532502b29f0aedba05 20-Jul-2016 Samuel Tan <samueltan@google.com> VenueNameElement: fix off-by-one enum bounds check am: 48ee5f1e1c am: 37ec3aff4c
am: 2d03259907

Change-Id: I3aec7dac23cd6e384c5b65d29d90263f1fbf34c3
2d032599075dd4bd72dc8e4f5c19ca227110f45f 20-Jul-2016 Samuel Tan <samueltan@google.com> VenueNameElement: fix off-by-one enum bounds check am: 48ee5f1e1c
am: 37ec3aff4c

Change-Id: I7e07d99f997a4bc07f2fb57626110374c84b902d
37ec3aff4c02b1cfcdd809762576348ebe9d8db0 20-Jul-2016 Samuel Tan <samueltan@google.com> VenueNameElement: fix off-by-one enum bounds check
am: 48ee5f1e1c

Change-Id: Ic85f78c41d25149e5db3840914e2b6c41a75490b
179d479d047c22d94d1db53980156986b0dba710 18-Jul-2016 Randy Pan <zpan@google.com> WCM: reset last connection BSSID

Reset WCM's record of last connection attempt BSSID when WiFi
is disconnected or WiFi/WCM is disabled.

Bug: 30140653
Tests: WiFi framework unit tests & manual tests
Change-Id: I70b285ffcc8783db587b3fcc14f8f85ffa6122f2
om/android/server/wifi/WifiConnectivityManager.java
48ee5f1e1c6e2a2dc63e9cb84c42f532c8a6847a 18-Jul-2016 Samuel Tan <samueltan@google.com> VenueNameElement: fix off-by-one enum bounds check

Fix the off-by-one error in the conditionals that check
whether the Venue Group and Venue Type codes in the ANQP
element are in the "Reserved" range.

BUG: 30169673
BUG: 29464811
TEST: Manually set up AP with Hotspot 2.0 support, broadcasting
Venue Group value 0xc, and ensure that device does not
crash when in range of this AP.

Change-Id: I14adc3a919e19b67fc0f46bf09d0cffb88b5354e
om/android/server/wifi/anqp/VenueNameElement.java
62a41b4a43cba3fad221291533c145863b7001f0 12-Jul-2016 Mukesh Agrawal <quiche@google.com> Merge "WifiNative: make getLocalLog() an instance method" into nyc-mr1-dev
20d76f6f2f264cc27a8821e46ad1bd1dc50700e7 23-Jun-2016 mukesh agrawal <quiche@google.com> WifiConfigManager: move dumping of LocalLog

The dump() method of WifiConfigManager dumps the
LocalLog that's used by WCM. That would make sense,
except that the LocalLog that WCM uses isn't actually
owned by WCM.

Instead, the LocalLog is allocated by WifiNative, and
shared by multiple objects. (The sharing is safe, because
LocalLog's methods are synchronized.)

Since the LocalLog in question is a shared facility,
let's move dumping of the LocalLog to WifiLogger.

BUG=29424414
TEST=unit tests
TEST=manual

Manual test
$ adb bugreport foo.zip
$ unzip foo.zip
$ grep 'WifiNative LocalLog' bugreport*.txt
-> expect a match

Change-Id: I291ac29385472fd0e56fcb522d818dcffcedfe36
(cherry picked from commit 6b42d03b9d92d6167a0629b042b2a3c2e2489a1b)
om/android/server/wifi/WifiConfigManager.java
om/android/server/wifi/WifiLogger.java
367a496587a34be0aec60765eeb1365baadf03bc 23-Jun-2016 mukesh agrawal <quiche@google.com> WifiNative: make getLocalLog() an instance method

We want to add some tests that mock out WifiNative.getLocalLog().
To do that, we need getLocalLog() to be an instance method.
Make it so.

While there: add @NonNull annotation to getLocalLog(), to
make the semantics clearer.

BUG=29424414
TEST=unit tests

Change-Id: Ifb224104cf54b42a945258967dcaf50541849abc
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiNative.java
d0a7e444a6af85ccaa03e52bcb82de7f66033cfb 08-Jul-2016 Samuel Tan <samueltan@google.com> ScanDetail: set scan result passpoint flag in constructor

ScanDetail does not set the ScanResult.FLAG_PASSPOINT_NETWORK flag
for its |mScanResult| member in its constructor. This causes
problems when in WifiTracker, which uses this flag from the
ScanResult to determine whether or not to associate Passpoint configs
with Passpoint access points.

Fix this by setting this flag in the ScanDetail constructor.

BUG: 29550309
TEST: Manually verify that the "Available via $PROVIDER" subtext
appears under the SSIDs of Passpoint networks, when we have
the credentials for connecting to these passpoint networks
installed, but are currently connected to a non-Passpoint
network.

Change-Id: I1da2c0eff336331deae4dbd86f4c6afc3d456db9
om/android/server/wifi/ScanDetail.java
da2e11e7e8ba2cc022c9c74e659ada9f1f27382e 07-Jul-2016 Samuel Tan <samueltan@google.com> Merge "[DO NOT MERGE] WifiConfigManager: do not use ScanDetailCache to set SSID for... passpoint networks" into nyc-mr1-dev
ad8d44d3239610cca3aa630035bebacd9677ef5a 06-Jul-2016 Samuel Tan <samueltan@google.com> [DO NOT MERGE] WifiConfigManager: do not use ScanDetailCache to set SSID for...
passpoint networks

For passpoint networks, set the WPA supplicant SSID field for the
network being selected in WifiConfigManager.selectNetwork() to the
SSID stored in the WifiConfiguration argument, since we know that QNS
will set this field to the SSID of the network it has selected.

This replaces the previous logic of looking for the SSID in a cached
ScanDetail, which is not guaranteed to match correspond to the network
selectNetwork() is attempting to connect to.

While there:
- Remove ScanDetailCache.getFirst(), since it is no longer used
anywhere else.

BUG: 29946781
TEST: In the lab, there are currently two Passpoint APs, each
broadcasting a network that the same Passpoint profile can be
used to connect to. One of these networks ("X") rejects the Passpoint
credentials presented to it, while the other ("Y") accepts them. Verify
that a device loaded with the aforementioned Passpoint profile
will try to connect to X and fail, and then attempt to connect to
Y and succeed.

Change-Id: Ic5292d00fbb4c1e999a5c9e49390c7c13f4eb17c
om/android/server/wifi/ScanDetailCache.java
om/android/server/wifi/WifiConfigManager.java
9288564d29d00c4f6d7fe3a581c5c70635f04d74 07-Jul-2016 Samuel Tan <samueltan@google.com> Merge "ConfigBuilder: only set anonymous identity for EAP-TLS/TTLS configurations" into nyc-mr1-dev
958eb1fb96709b94ddd7b4310908de9ece986d2c 06-Jul-2016 TreeHugger Robot <treehugger-gerrit@google.com> Merge "WifiNetworkHistory: Ignore file not found exceptions" into nyc-mr1-dev
478dd448011f5b9cf9dfaa0c5c950399b88d90d1 06-Jul-2016 Roshan Pius <rpius@google.com> WifiNetworkHistory: Ignore file not found exceptions

Raise a info log message instead of logging an error when the
networkHistory.txt file is not found.

While there,
Cleanup the logs to remove the "reset to default" sentence from the logs.

BUG: 29641462
Change-Id: I572f248d0991d66ebdd118fc7ddb26680e1d7b15
TEST: Manual testing.
om/android/server/wifi/WifiNetworkHistory.java
a03e931932912355c9656216813458a9e6054f59 01-Jul-2016 TreeHugger Robot <treehugger-gerrit@google.com> Merge "Fix NPE in WifiScanningService" into nyc-mr1-dev
ed70365e5a3a6e2b06c2d4d06603f97596f1124b 01-Jul-2016 Mitchell Wills <mwills@google.com> Fix NPE in WifiScanningService

Fixes: 29924121

Change-Id: Iabb8111d0d4cdef6b02710f6ea2b3545f1b6d70b
om/android/server/wifi/scanner/WifiScanningServiceImpl.java
221874210c77844242774ba4117e61b0bdfeee27 30-Jun-2016 Roshan Pius <rpius@google.com> WifiStateMachine: Set supplicant log level after restart

Currently we lose |wpa_supplicant|'s debug log setting when we restart
|wpa_supplicant|. Re-activate the verbose logging setting for
|wpa_supplicant| (if verbose logging is enabled) after starting
supplicant every time.

BUG: 29902287
Change-Id: I04512ab82a7b16e24db1d959f9cc7e7a6d23174f
om/android/server/wifi/WifiStateMachine.java
21d43031a1141caae823977a1e1015b596f47895 29-Jun-2016 Mukesh Agrawal <quiche@google.com> Merge "WifiLogger: use R for ring buffer sizing" into nyc-mr1-dev
06a68478d7ab476da36b70d26eee9b0adef3d03c 29-Jun-2016 Mukesh Agrawal <quiche@google.com> Merge "WifiLogger: speed up compression" into nyc-mr1-dev
9a53ff620c9281be423227bc48378d9aad3f37e0 29-Jun-2016 Rebecca Silberstein <silberst@google.com> Merge changes from topic 'cherrypickWifiWatchdogResetOnTrigger' into nyc-mr1-dev

* changes:
DO NOT MERGE WifiLastResortWatchdog: reset wifi on trigger
DO NOT MERGE WifiController: Add CMD_RESET_WIFI command
DO NOT MERGE WifiLockManager: create class to manage WifiLocks
e1db4e04054d8cc302fb96c4f78370845650504e 23-Jun-2016 mukesh agrawal <quiche@google.com> WifiLogger: use R for ring buffer sizing

Use Resources to determine ring-buffer sizing.
This is to support board-specific ring-buffer
sizes.

BUG=29225988
TEST=unit tests
TEST=manual

Manual test (bullhead): Added some Log.e() statements,
and verified that RING_BUFFER_BYTE_LIMIT_SMALL and
RING_BUFFER_BYTE_LIMIT_LARGE were 32KB and 1024KB,
respectively.

Change-Id: I25ee7d871609c4ebe186424bfdd324a8283f43e3
(cherry picked from commit eacd212af097fada70bdb49da3ed06e8d172237b)
om/android/server/wifi/FrameworkFacade.java
om/android/server/wifi/WifiLogger.java
om/android/server/wifi/WifiStateMachine.java
969de309e3edc1795d6df24415e586d1a1587cb6 27-May-2016 Rebecca Silberstein <silberst@google.com> DO NOT MERGE WifiLastResortWatchdog: reset wifi on trigger

( cherry-pick of Icb7c3a211afcd234cfcd25a42665aed03c33f5e1 from master )

Added wifi reset on WifiLastResortTrigger. The reset is implemented by
sending the CMD_RESTART_WIFI message to WifiController.

BUG: 27856267
Change-Id: Icb7c3a211afcd234cfcd25a42665aed03c33f5e1
om/android/server/wifi/WifiLastResortWatchdog.java
om/android/server/wifi/WifiServiceImpl.java
5f0238c0d7b4b037dcb1c397217eb65dcfbf53ce 26-May-2016 Rebecca Silberstein <silberst@google.com> DO NOT MERGE WifiController: Add CMD_RESET_WIFI command

(cherry-pick from master)

Allow WifiController to safely restart the WiFi stack. This will
initially be used by the WifiLastResortWatchdog. The CMD_RESET_WIFI
message is only handled in the StaEnabledState where it would have been
attempting to connect. The process of bringing the wifi back up is
handled through the use of the new CMD_RESET_WIFI_CONTINUE command.
Tests are also added to verify that the new CMD_RESET_WIFI command
is ignored in other states (explicitly tests Emergency mode and
AP enabled).

BUG: 27856267
Change-Id: I778ccd6f7d555f6ee6abb195c1c16c106c2e66b7
om/android/server/wifi/WifiController.java
9563500603c158373e2ee512c4d451783c104660 20-May-2016 Rebecca Silberstein <silberst@google.com> DO NOT MERGE WifiLockManager: create class to manage WifiLocks

( cherry-pick of Ib055078eb0a8555e9a7715d7ce10de1103e73130 from master)

Create new class to maintain WifiLocks requested by applications.

WifiLock management was closely tied to the WifiServiceImpl and made it
very difficult to write tests using different WifiLock modes in
DeviceIdle states. This CL moves the lock management to a new class,
WifiLockManager, and adds tests to check the behavior.

Bug: 28669096
Change-Id: Ib055078eb0a8555e9a7715d7ce10de1103e73130
Test: runtest frameworks-wifi
om/android/server/wifi/WifiController.java
om/android/server/wifi/WifiLockManager.java
om/android/server/wifi/WifiServiceImpl.java
1480044b958c1ee30ad1644705115b87ac8e1d6f 23-Jun-2016 mukesh agrawal <quiche@google.com> WifiLogger: speed up compression

Some rough benchmarking suggests that using
BEST_COMPRESSION may cause us to take 4 seconds
to service a dump() request. The same benchmarking
indicates that using BEST_SPEED will be about
10x as fast, and yield output that's only 5%
larger.

Switch to BEST_SPEED, to avoid slowing down
bug report generation.

BUG=28986501
TEST=manual

Manual test:
- Enable Wi-Fi Verbose Logging
$ adb bugreport foo.zip
- verify that foo.zip contains base-64 encoded
ringbuffer dumps

Change-Id: I0eac83def5cf393a6babdd481079086ea11a5a96
(cherry picked from commit 9a312a13ba34712f3de7f4d0c8d04ff695a41cae)
om/android/server/wifi/WifiLogger.java
ab7a54087b8c1874c7ca5e8b8da1faddbe1da0ce 22-Jun-2016 Randy Pan <zpan@google.com> WCM: periodic single scan timer cancellation

Cancel the periodic single scan timer only if it is started.

Bug: 28881202
Change-Id: I4d4936916daf2869bfda46476c7254a2b38e9a9b
om/android/server/wifi/WifiConnectivityManager.java
2352bf22557051e98eb16d087d20731e91cfdc71 28-Jun-2016 Randy Pan <zpan@google.com> WCM: track PNO scan state

Add a flag to track if PNO scan is started.

Bug: 29822923
Change-Id: I96416eb5a6590a52800b962838d2e87d9f52bb1a
Tests: Wifi Framework Unit Tests
om/android/server/wifi/WifiConnectivityManager.java
cb26f07ae9c558f8c6136c951a7f633d0ccfe79f 24-Jun-2016 Randy Pan <zpan@google.com> WCM: Listen to all single scan results

In addition to single scan results initiated by WCM itself, it
listens to the single scans requested by other modules as well.
This gives us more opportunities to connect to a network.

We don't check if a single scan is scheduled by WCM watchdog
any more since we now listen to all single scan results.

Bug: 29606099
Tests: Wifi Framework Unit Test & manual tests
Change-Id: I2a1df0337005878f415eccc425600267434c2e54
om/android/server/wifi/WifiConnectivityManager.java
450fee26a21eb56d536df147d3e88d3549f807c0 27-Jun-2016 Mitchell Wills <mwills@google.com> Merge "Add a WifiScanner API to listen for ongoing scans" into nyc-mr1-dev
1ba04405f98489f0fbd66b6566c64324be11111a 23-Jun-2016 Mitchell Wills <mwills@google.com> Add a WifiScanner API to listen for ongoing scans

Bug: 29412469
Change-Id: I1b8c6f3524e937cbc902af0be391b5e6b23e8ee2
om/android/server/wifi/scanner/WifiScanningServiceImpl.java
3c8094ab45f3320dbe45e6460c5d62dcc24ce7ae 04-May-2016 Mitchell Wills <mwills@google.com> Clear auth identity if sim removed while the device is off

TEST: Validated that changing a SIM both when the device is on and when
it is off results in the correct identity being used when trying
to authenticate with an EAP-SIM network.
Fixes: 28163651
Change-Id: I3dda95308a527be225a9f70636c727c9826ac939
om/android/server/wifi/WifiConfigManager.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/util/TelephonyUtil.java
55b1b58e72df2362888c7a1c60ad76a43523bfcf 25-Jun-2016 Mitchell Wills <mwills@google.com> Merge "Reuse single scan results if a request comes in during an ongoing scan" into nyc-mr1-dev
a9b40d7093e260891d543f4fc418e6a7088f2c6c 23-Jun-2016 Samuel Tan <samueltan@google.com> ConfigBuilder: only set anonymous identity for EAP-TLS/TTLS configurations

Modify the logic in ConfigBuilder.buildConfig() so that the anonymous
identity field is only set for EAP-TLS/TTLS configurations.

WPA supplicant will use this field to send the NAI realm to the EAP
server in its EAP Identity Response packet, which is necessary for
AAA routing purposes. See the comments in the new
setAnonymousIdentityToNaiRealm() method for details.

While there, move the setting of the CA Certificate field
of the configuration's enterprise config into buildTTLSConfig() and
buildTLSConfig(), since this field is only needed for those two
protocols.

BUG: 29356519
TEST: Connected successfully to the AT&T, Boingo, and GlobalReach Passpoint
APs in the lab.

Change-Id: Idf55cd92173c0543e5426d6145ce472b5894466b
om/android/server/wifi/configparse/ConfigBuilder.java
5751e82f645ab5b4366c63e0fbc561534c1cb3b8 22-Jun-2016 Mitchell Wills <mwills@google.com> Reuse single scan results if a request comes in during an ongoing scan

Change-Id: I590c64a4718385214e4ba803112ed7283f69b3be
Fixes: 28936380
om/android/server/wifi/scanner/WifiScanningServiceImpl.java
af2c07c305e33b759b3b0e707fdc264b193626c4 22-Jun-2016 Glen Kuhne <kuh@google.com> Merge "Wifi Metrics: Log RSSI polls" into nyc-mr1-dev
a780a159b70cb9a72ea1adc47ab7dbb458914d5a 22-Jun-2016 Randy Pan <zpan@google.com> Merge "WCM: reset connectivity scan retry counter" into nyc-mr1-dev
7a0b9ffe794113c4a5ed528d8aadeb3303d1b089 10-Jun-2016 Glen Kuhne <kuh@google.com> Wifi Metrics: Log RSSI polls

Added logging of the periodic RSSI polls into wifi metrics, as a
key-value histogram (count per rssi level).

BUG=29247576

Change-Id: I9aa19dbf0891b87d1d12a375aeb3771ba7ef6308
om/android/server/wifi/WifiMetrics.java
om/android/server/wifi/WifiStateMachine.java
0adb951552650442bafea5689307b1c58de14c25 22-Jun-2016 Paul Stewart <pstew@google.com> Merge "Fix invitation request from persistent GC" into nyc-mr1-dev
de5fadf2e5c7bb769705c830efb04133b1e0219d 21-Jun-2016 Randy Pan <zpan@google.com> WCM: reset connectivity scan retry counter

Move the scan retry count reset to where scan results are received.
This is to deal with the case that WifiScanner reports success when
a scan request is queued but later fails to be executed.

Add a unit test case to verify the retry behavior.

Bug: 29523369
Change-Id: Ibcd7c771a8efa78612a84021a4511db621f4451e
Tests: Wifi Framework Unit Tests & manual tests
om/android/server/wifi/WifiConnectivityManager.java
4301f4786e565d9555e5cbf81ef1055f81975385 20-Jun-2016 Randy Pan <zpan@google.com> Merge "Cut down Wifi local log buffers size" into nyc-mr1-dev
a90ff1f02fc6820fde13d2c76738c7ae75a503e1 27-Feb-2015 daisuke niwa <daisuke.x.niwa@sonymobile.com> Fix invitation request from persistent GC

When the device received the second invitation request
from GC of the same PersistentGroup, the wifi framework
processes "sa" as mOwner of WifiP2pGroup. At this point,
if an invited group is persistent group, WifiP2pGroup can't
know whether "sa" is GC or GO yet. So the framework shouldn't
process mOwner in the constructor.

BUG=28715251
Change-Id: Ie7065da0d6c978c3747ecbd6f728de87d9567009
om/android/server/wifi/p2p/WifiP2pServiceImpl.java
1e911c92133843fc0a50a1b1c6f654f62e7c98a8 17-Jun-2016 Randy Pan <zpan@google.com> Cut down Wifi local log buffers size

The new buffer size can hold up to around 3 hours of logs. This
can be further optimized later after we have more usage data.
The goal is to save the logs from the last one hour only.

Bug: 29179543
Change-Id: I99e15531328fdb03df28dcf5a014deb2f074b254
om/android/server/wifi/WifiConnectivityManager.java
om/android/server/wifi/WifiQualifiedNetworkSelector.java
om/android/server/wifi/scanner/WifiScanningServiceImpl.java
895b3e2186362770b46d318cc011a0e502e1c961 17-Jun-2016 Bartosz Fabianowski <bartfab@google.com> Allow connecting to WiFi networks via Quick Settings
am: a3e8570867

Change-Id: I46046d9292fa343d6fd7f01f41fd20b71337374e
b271c249debc3e0327354638a84a8daff33427ee 16-Jun-2016 Mitchell Wills <mwills@google.com> Merge "Better distinguish between WifiScanner clients in logs" into nyc-mr1-dev
a3e8570867c26322499d306f118427f77a561ee5 30-May-2016 Bartosz Fabianowski <bartfab@google.com> Allow connecting to WiFi networks via Quick Settings

System UI acts on behalf of the current foreground user and should
thus be allowed to connect to WiFi networks, even if it actually runs
as user 0.

BUG=28799309

Change-Id: I50c3bdf30c9a1fd7780b47cac3f8ff3d0fb34f36
om/android/server/wifi/WifiStateMachine.java
7fc5d7d6f5650e630fcf0eff87dce335810a9786 16-Jun-2016 Mukesh Agrawal <quiche@google.com> Merge "WifiLoggerHal: fix TX fate constants" into nyc-mr1-dev
9e7f5e0a47a9a4aa519a50d9a0959547c1c604f1 15-Jun-2016 Mitchell Wills <mwills@google.com> Better distinguish between WifiScanner clients in logs

Change-Id: I15327935f4b9ccdf3d3244087c508f19fd275c1f
Fixes: 29385784
om/android/server/wifi/scanner/WifiScanningServiceImpl.java
4b420cc79303370df99603dcec1b8ec6abf14ab5 15-Jun-2016 Randy Pan <zpan@google.com> Merge \"QNS: cut down BSSID blacklist time to 5 minutes\" into nyc-dev
am: 9ec065de4d

Change-Id: I2c131ee8852d4428b876633014be890deb31e7b6
9ec065de4d3f323bbda2da034ff414d9d045b48c 15-Jun-2016 Paul Stewart <pstew@google.com> Merge "QNS: cut down BSSID blacklist time to 5 minutes" into nyc-dev
e1b848bb11cc44060328bf53162cb776e3dd54dc 13-Jun-2016 Glen Kuhne <kuh@google.com> Merge \"DO NOT MERGE WifiMetrics: Record capture duration\" into nyc-dev
am: 622e9ff387

Change-Id: Ie7de4f9173a815abe88f91efc5a46893be5270d1
622e9ff3874251022ae3c27548bc5a2f77bdc8bc 13-Jun-2016 Glen Kuhne <kuh@google.com> Merge "DO NOT MERGE WifiMetrics: Record capture duration" into nyc-dev
e8f7d4ab151251991982329f7274f866bb03b3da 11-Jun-2016 Mitchell Wills <mwills@google.com> Fix crash when cleaning up WifiScanner client before Wifi enabled
am: 3040b86393

Change-Id: Ied0c5e048cceba8f4935e8dd9bdc104db6b64366
3040b86393a04bc939a5a94cda4169b0293dfac7 10-Jun-2016 Mitchell Wills <mwills@google.com> Fix crash when cleaning up WifiScanner client before Wifi enabled

Change-Id: Ia212840fcf781740d5e185d3e3c2e30a477e25f0
Fixes: 29250616
om/android/server/wifi/scanner/WifiScanningServiceImpl.java
49410c13ba2284fb7c836fd3527dc526ea5681a0 07-Jun-2016 Glen Kuhne <kuh@google.com> DO NOT MERGE WifiMetrics: Record capture duration

Adds a wifi metric that records the capture duration period represented
by the WifiLog proto. This is to improve the way wifiLogs are weighted when
aggregated.
Modified WifiMetrics to use the Clock wrapper of SystemClock to
facilitate unit tests.

BUG=29185886

Change-Id: I61dd2b481c26f0ea21bcb280ce1d40f3d73b7625
om/android/server/wifi/WifiInjector.java
om/android/server/wifi/WifiMetrics.java
d16695d8998b5fd50dc1d966e67122ed9ac0464d 09-Jun-2016 Mitchell Wills <mwills@google.com> Fix crashes in significant change when wifi hasn\'t started
am: 11bb0926a6

Change-Id: I8b0479a1931798fbc6a34504cdd56e64e41d97b6
11bb0926a6cc3380f2217532fefb9605a1fdc9e8 09-Jun-2016 Mitchell Wills <mwills@google.com> Fix crashes in significant change when wifi hasn't started

The SignificantChange state machine doesn't actually have a concept of
if Wifi is on or not. This will simply ensure that it is not possible to
cause a crash.

Change-Id: I8ff87364bf7d5c87f0519b6cdc32d164facf30eb
Fixes: 29237535
om/android/server/wifi/scanner/WifiScanningServiceImpl.java
9a133e027b91252da4d193571fc76cd2cf49e4b7 08-Jun-2016 mukesh agrawal <quiche@google.com> WifiLoggerHal: fix TX fate constants

A couple of the constants in WifiLoggerHal
do not match the values in wifi_logger.h

And that's despite the comment stating
the requirement right at the top of
WifiLoggerHal. Hrmph!

Anyway, let's fix that.

BUG=29213973
TEST=unit tests

Change-Id: I10edaf3c72f1a9112d2419fad4ca25ab1f405d3a
(cherry picked from commit 4144562f905b765744d4e937f0ce0449c7e96abb)
om/android/server/wifi/WifiLoggerHal.java
497b04c439e7dd2b61a796e6a4da04452c46e69a 09-Jun-2016 mukesh agrawal <quiche@google.com> WifiLogger: revert large ringbuffers for userdebug/eng
am: 9a865ec91c

Change-Id: I727e2175df055a2485dd7071e568f676afa0f40c
76d591d5abba138d5104cbadd5c30c6e7c567194 08-Jun-2016 Christopher Wiley <wiley@google.com> Merge "Remove all knowledge of tethering from SoftApManager" into nyc-mr1-dev
9a865ec91cf32d41496a28d800279cd86832b027 18-May-2016 mukesh agrawal <quiche@google.com> WifiLogger: revert large ringbuffers for userdebug/eng

When the WiFi code is sufficiently mature, we'll use
this patch to return to using small ring buffers
on all builds.

Note that this patch is not a literal/full revert of
CL:1048267. The reason for the more focused change
is to minimize merge conflicts, in case other code
changes by the time this CL lands.

BUG=28822174
TEST=unit tests

Change-Id: I9facadf8aaf779e0627b15815a426b86bde692a1
om/android/server/wifi/WifiLogger.java
0ef8048dbb79f3197efcc5d684cb452b6fa72338 08-Jun-2016 Randy Pan <zpan@google.com> Merge "WCM: No connectivity scan if auto roaming is off" into nyc-mr1-dev
a68f3e359ac27285b10332ea2461469e5e03bfd4 08-Jun-2016 Randy Pan <zpan@google.com> WCM: No connectivity scan if auto roaming is off

When WiFi is already connected, WCM initiates connectivity scan
for roaming only if config 'EnableAutoJoinWhenAssociated" is
turned on. This config option is turned on by default. More
power sensitive devices can turn the config off to save battery.

Note, when this config option is turned off, only the WCM
initiated auto roaming is disabled. Wifi chipset firmware may
still perform a roaming on its own.

Bug: 29157340
Change-Id: I9a8f0df65d39412f242c064db5b3d6654d23634c
Test: Framework Unit Tests and manual tests
om/android/server/wifi/WifiConnectivityManager.java
c405929e28fad4ef2325a0f798b14536382f2b4d 08-Jun-2016 Paul Stewart <pstew@google.com> resolve merge conflicts of 6da17ca to nyc-dev
am: 073c371dbc

Change-Id: I9cab61eae43744280cbb6f2f299141a6a088e683
073c371dbc5b361bf5f6651ed5f6b471012bd673 08-Jun-2016 Paul Stewart <pstew@google.com> resolve merge conflicts of 6da17ca to nyc-dev

Change-Id: Ifb500e3f745b5e2493ffa016a06f23120e80910a
6da17ca8f26560a6718626ca58a0c5693ace3f67 08-Jun-2016 Paul Stewart <pstew@google.com> Merge \\\"Perform a null-check in getMatchingConfig\\\" into mnc-dev am: e3c37daf73 am: e180938097
am: 96cc486099

Change-Id: Iae9d523d364079407f500d00f96db951c3d7f994
96cc486099b6bc342db50e575d27d8eb9f4c09f1 08-Jun-2016 Paul Stewart <pstew@google.com> Merge \\"Perform a null-check in getMatchingConfig\\" into mnc-dev am: e3c37daf73
am: e180938097

Change-Id: I15921c5f5903d66052cb48d851913672077a190c
e1809380976b20aebfb362bc1ebe52216f4a17e4 08-Jun-2016 Paul Stewart <pstew@google.com> Merge \"Perform a null-check in getMatchingConfig\" into mnc-dev
am: e3c37daf73

Change-Id: Ic33a155d3f19e39279a7d8b47ee63da217539c47
8cb1589234aa116c49bba15ca616c7beeae0cebe 07-Jun-2016 Roshan Pius <rpius@google.com> Merge "WifiStateMachine: Return null link layer stats" into nyc-dev
am: e3235277e0

* commit 'e3235277e0bef27f51c50a1ddb74acbd80c996d5':
WifiStateMachine: Return null link layer stats

Change-Id: I90d89c48f346c6473f63fd6c4f40b2d180049a0d
e3235277e0bef27f51c50a1ddb74acbd80c996d5 07-Jun-2016 TreeHugger Robot <treehugger-gerrit@google.com> Merge "WifiStateMachine: Return null link layer stats" into nyc-dev
d9c55738e1bb2ff3faee24c5434453352a9e6611 31-May-2016 Christopher Wiley <wiley@google.com> Remove all knowledge of tethering from SoftApManager

( dirty cherry-pick from f502d3e20409d81cfefd762b3b44f46dead09a92 )

This logic has moved into Tethering and TetherInterfaceStatemachine,
where it probably always belonged.

Bug: 29054780
Test: WiFi tethering continues to work on angler
`runtest frameworks-wifi` passes.

Change-Id: Ifff78ea540929fde4abea65716e1f659da2ecfec
om/android/server/wifi/FrameworkFacade.java
om/android/server/wifi/SoftApManager.java
73b62544391a0a15d9ca2dd7feb7797751026c0f 07-Jun-2016 Randy Pan <zpan@google.com> QNS: cut down BSSID blacklist time to 5 minutes

Today the association to an AP can be rejected because of either
the rejection from the AP or the STA host driver time-out. The
WiFi framework receives the same ASSOC_REJECT messages for both
scenarios. Cut down the blacklist time value to 5 mins for now.
When we can differentiate these two types of rejections,
the blacklist time for the real AP rejection can go back to
30 minutes.

Bug: 28899826
Change-Id: I785e13140bfdfbefbae17320c247ae1c8134fa92
om/android/server/wifi/WifiQualifiedNetworkSelector.java
c39b9a4dc4661baab1ed638cffdc985ccbd4afb6 07-Jun-2016 Ningyuan Wang <nywang@google.com> Merge "Continue supporting persisting country code" into nyc-dev
am: ff6f114971

* commit 'ff6f1149718d709ce4799883af4d77251c2652dc':
Continue supporting persisting country code

Change-Id: I7b5e7e7ce04a1518652ec5be3333fae4fc0c08d2
ff6f1149718d709ce4799883af4d77251c2652dc 07-Jun-2016 Ningyuan Wang <nywang@google.com> Merge "Continue supporting persisting country code" into nyc-dev
2bb56aa74dcad6946b1201cab016fd3f1fa410d7 07-Jun-2016 Roshan Pius <rpius@google.com> WifiStateMachine: Return null link layer stats

Modify |CMD_GET_LINK_LAYER_STATS| handling to return a null object when
the stats cannot be retrieved from wifi HAL. We've added a
feature check in |WifiServiceImpl.reportActivityInfo| method to check if
the device supports link layer stats reporting or not. So, there is no
need to fake an empty object if the retrieval fails.

BUG:29117407
Change-Id: Iaf8e060912611773398210785ebfaae7371db77c
om/android/server/wifi/WifiStateMachine.java
4f088ed037dc1ae22fb1a0dd5c88a25965167a90 06-Jun-2016 Randy Pan <zpan@google.com> Merge "WCM: Periodic scan interval policy adjustment" into nyc-dev
am: 2d7797eae8

* commit '2d7797eae8364c2c42d7368090b25adc74de3ff1':
WCM: Periodic scan interval policy adjustment

Change-Id: Iee1fec3a64f957746ee0026adc6733fad21401ab
2d7797eae8364c2c42d7368090b25adc74de3ff1 06-Jun-2016 Paul Stewart <pstew@google.com> Merge "WCM: Periodic scan interval policy adjustment" into nyc-dev
0091305175e8c6fe7fc6d01efb9d405961db4ac7 03-Jun-2016 Ningyuan Wang <nywang@google.com> Continue supporting persisting country code

Some devices rely on Setup Wizard to set a persistent country
code.
This CL honors the persistent option, fixing corresponding 5GHz AP
problem.
This also includes addtional unit tests for this change.

BUG=28127280
TEST=compile
TEST=runtest frameworks-wifi
Change-Id: I2f36216e143d0ac4959f26a9965def061a06aabf
om/android/server/wifi/FrameworkFacade.java
om/android/server/wifi/WifiCountryCode.java
om/android/server/wifi/WifiServiceImpl.java
58cbdef15c1c764435e1c6ae10dc4d19a780ea72 04-Jun-2016 Jack Tian <jack.tian@sonyericsson.com> Merge "DO NOT MERGE: Repeatedly prompting when no internet connection" into nyc-dev
am: 5f4074fa7f

* commit '5f4074fa7f8e61d27cd24c317a0a1b8a5ece4724':
DO NOT MERGE: Repeatedly prompting when no internet connection

Change-Id: I1360e20bc35bb91197bd8937c2296df3ae0912d8
5f4074fa7f8e61d27cd24c317a0a1b8a5ece4724 04-Jun-2016 Lorenzo Colitti <lorenzo@google.com> Merge "DO NOT MERGE: Repeatedly prompting when no internet connection" into nyc-dev
a08979a41421d0412cf64c38ccb06da0c0d2135c 04-Jun-2016 John Eckerdal <john.eckerdal@sonymobile.com> Stop the recurring alarm if no scansettings are available
am: 0d0a4c339b

* commit '0d0a4c339b3950ad6d882e89223dc21a89ef3953':
Stop the recurring alarm if no scansettings are available

Change-Id: I6deb23f47a5b183430f2b3a28994b7f49a5fff6f
59d39b88c7af97049210f4e296570d03f1a32d91 04-Jun-2016 Wei Liu <luciferleo@google.com> Merge "Hold the wakelock for suspend optimaztion only when it matters." into nyc-mr1-dev
07a83d343adb6a5a2d4fce734b1dbec717126b6d 03-Jun-2016 Wei Liu <luciferleo@google.com> Hold the wakelock for suspend optimaztion only when it matters.

b/23106128

Change-Id: I367ffd43f84bb46276d30c12ffcd54d641a9bc4a
om/android/server/wifi/WifiStateMachine.java
016ca1ae5e33eb9529ae10c2510a56fa5c7fec4d 03-Jun-2016 Randy Pan <zpan@google.com> WCM: Periodic scan interval policy adjustment

Allow immediate single scan for scenarios such as user allows
untrusted networks, user forces a connectivity scan, and etc.
The minimum scan interval is enforced only for the screen state
change and connection state change cases.

Also removed the scan started by WCM for user selected network.
We connect to the user selected network by directly invoking
the wpa_supplicant select_network. Now WCM always sets the
'forceSelectNetwork' parameter to false when calling into
WifiQualifiedNetworkSelector.selectQualifiedNetwork(). So deleted
the unused variable mForceSelectNetwork.

Bug: 29103349
Change-Id: I1dd77af0cf7de85a96afac63de1344daab192968
om/android/server/wifi/WifiConnectivityManager.java
0d0a4c339b3950ad6d882e89223dc21a89ef3953 02-Jun-2016 John Eckerdal <john.eckerdal@sonymobile.com> Stop the recurring alarm if no scansettings are available

This will fix an NPE whenever no scansettings are available.
The stop of the recurring alarm should not introduce a permanent
stop though since the whole processPendingScans function is dependant
on mPendingBackgroundScanSettings != null.

Anyway, as soon as mPendingBackgroundScanSettings is changed,
the processPendingScans function will be called, either directly
or indirectly through handleScanPeriod().

Crash call stack:
java.lang.NullPointerException: Attempt to read from field
'int com.android.server.wifi.WifiNative$ScanSettings.base_period_ms'
on a null object reference

at com.android.server.wifi.scanner.SupplicantWifiScannerImpl.processPendingScans
(SupplicantWifiScannerImpl.java:395)

Bug: 29113658
Author: Ola Olsson <ola.olsson@sonymobile.com>
Change-Id: Ibf08c9d6c5e476052449ef11d82ce005e50bd4fd
om/android/server/wifi/scanner/SupplicantWifiScannerImpl.java
3ea09e080a9ab3ed594356d8f3e498ec61a4d0fb 02-Jun-2016 Jack Tian <jack.tian@sonyericsson.com> DO NOT MERGE: Repeatedly prompting when no internet connection

When internet connection is not avaiable there is always
a prompt even if user has checked "never ask again" on the
dialog prompt.
This is caused by noInternetAccessExpected reset while reloading
network configuration and this patch puts noInternetAccessExpected
into network history so that its value is not lost.

Bug: 29085788
Bug: 29111340

(cherry picked from commit 4854de88e57279bf930f0754b268093061e88544)

Change-Id: I407a5c60e89d7da4ac7fe30df08087fe24039f98
om/android/server/wifi/WifiNetworkHistory.java
om/android/server/wifi/WifiStateMachine.java
d722d068b68772e52dd7621cfb915fce5ac08482 01-Jun-2016 Glen Kuhne <kuh@google.com> Remove chatty log from WiFiNative

When verbose debugging is enabled, every beacon frame generates a log
stating the DTIM value. This was left behind from development of DTIM
tracking.

BUG=29055049
TEST=unit tests
Change-Id: I3923536094b1894b940754101123f38518a5d519
om/android/server/wifi/WifiNative.java
4ab8ee5e3ecfdc107892396178efa9176a72438f 01-Jun-2016 Paul Stewart <pstew@google.com> Perform a null-check in getMatchingConfig

Ensure the scanResult parameter is non-null.

BUG: 29061312
Change-Id: I9b9d1c5d10b7a2776c3f5fed4b942fb7924bb5b3
om/android/server/wifi/WifiConfigStore.java
f5dba8eb5e660932367fc650a2e2ca724df3734e 27-May-2016 Randy Pan <zpan@google.com> Reset single scan timestamp when disabling Wifi

This timestamp needs to be reset when WiFi is disabled. When WiFi
is enabled again, a connectivity scan starts immediately.
Otherwise it can be delayed because of the minimum periodic single
scan interval rule.

Bug: 28986330
Change-Id: I5a01dc267a05791eba34c87e6d9301bd998bf377
Tests: Wifi unit tests, manual test
om/android/server/wifi/WifiConnectivityManager.java
528d0693bde1e2b83fab717252cf0ea2c55b4e56 26-May-2016 Mitchell Wills <mwills@google.com> Merge "Update background scan bucket periods to align with minutes" into nyc-dev
70162410612cfbf6d398a7625d3b9924cff719b7 25-May-2016 pkanwar <pkanwar@google.com> Hardcode the frequency band to 'AUTO'.

Users are unable to change their preference since we've taken out the UI

Changed the setFrequencyBand method to always set the band to 'AUTO'.

b/28906443

Change-Id: I7ebd8aa204f72ecee754e31662d8ebf509ae6063
om/android/server/wifi/WifiStateMachine.java
1b266ec1524c516a7ebf25b76801db86427ba68b 25-May-2016 Mitchell Wills <mwills@google.com> Update background scan bucket periods to align with minutes

Bug: 28320003
Change-Id: Ic551cc6d7fcaa94945d2768d7aa2cf705dd510fd
om/android/server/wifi/scanner/BackgroundScanScheduler.java
3126f8d5394f8790e9c4ed4ab5c47fcc686e6803 25-May-2016 Randy Pan <zpan@google.com> Merge "Wifi: local log size reduction" into nyc-dev
15941215e85f924765f00779e9b5daff9ed6f118 24-May-2016 Randy Pan <zpan@google.com> Wifi: local log size reduction

Cut down the max number of lines allowed in Wifi LocalLogs.
Currently LocalLog checks the number of lines in its buffer
instead of total size in number of bytes. The buffer being
used can grow really big if some lines are lengthy.

Bug: 28865103
Change-Id: I7f77de1048bb465b79265b3ecb3a925e3a2659d9
Test: Wifi Framework Unit Tests
om/android/server/wifi/WifiConnectivityManager.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiQualifiedNetworkSelector.java
c2963eb07660a06592c60224279685166390217d 23-May-2016 Randy Pan <zpan@google.com> WifiConnectivityManager: enforce minimum single scan interval

Instead of always starting a single scan when the device enters
screen on state, we now keep track of how long it has been since
last periodic single scan and defer the new scan request.

Bug: 28887789
Tests: Wifi Unit Tests, manual tests
Change-Id: Iba5b5b7db897d3227d87f8d989246a1942525b9c
om/android/server/wifi/WifiConnectivityManager.java
5de778c46065cf6a72c2c0d124c0ac882e5b55fe 23-May-2016 Randy Pan <zpan@google.com> Merge "Inform WifiConnectivityManager screen state" into nyc-dev
1f9f7c109ca952884fb7bff7271669d879ce9b97 23-May-2016 Mitchell Wills <mwills@google.com> Merge "Make sure that all ways a scan can fail get logged" into nyc-dev
9d6a7a1b5f9e9ea194fc6b15044c9d14d6aefabf 21-May-2016 Roshan Pius <rpius@google.com> Merge changes Ie64c11f3,I91272aa5 into nyc-dev

* changes:
WifiNetworHistory: Don't persist QNS blacklist
Change clock for time interval/elapsed measurments
a2cc7092156cb3280fa4b9c1d832e5d1ed2855a4 21-May-2016 Roshan Pius <rpius@google.com> Merge "WifiConnectivityManager: Fall back to full band scan" into nyc-dev
65dcc4a7fe234a371df17068933090db38af3987 21-May-2016 Randy Pan <zpan@google.com> Inform WifiConnectivityManager screen state

Tell WifiConnectivityManager the screen state in case
WifiConnectivityManager missed the screen update event because
it was not started yet.

Bug: 28824622
Tests: Wifi Framework Unit Tests; reproduced the symptom and
verified it went away after this change.

Change-Id: I33cce9276982f6e77cf89a42ddd14ad00f2e4f46
om/android/server/wifi/WifiStateMachine.java
56820e92fd4b1a0cee83f552905fc76fc8290146 20-May-2016 Mitchell Wills <mwills@google.com> Make sure that all ways a scan can fail get logged

Bug: 28682351
Change-Id: If9296d862adbd479e8600699f06f4684d377ae6a
om/android/server/wifi/scanner/WifiScanningServiceImpl.java
0195dc3dabc52cfb1455308109625a23ee126880 20-May-2016 Roshan Pius <rpius@google.com> WifiNetworHistory: Don't persist QNS blacklist

QNS blacklists network temporarily by setting the network status. Reset
this value when we bootup so that this not persisted. This is especially
needed as we move away from using wall clock for blacklist time.

Also,
Remove the unused blacklist timestamp key from network history parsing.

BUG: 28824635
Change-Id: Ie64c11f358b2e3389ec419cfcfdde8bb04298dd4
TEST: Compliles & unit-test passes
om/android/server/wifi/WifiNetworkHistory.java
fb196453c07daad5e525520cecad84cec5d89fb7 20-May-2016 Roshan Pius <rpius@google.com> WifiConnectivityManager: Fall back to full band scan

Fall back to full band scan when the currently connected network is not
present in scan result cache. This could be a transient problem, but we
don't want to cause an error by sending an invalid scan request.

Changes needed for unit-testing this change:
1. Make WifiInfo a real instance so that we can set the values for the
public members directly accessed like tx/rx success rate.
2. Make |getCurrentWifiConfiguration| public so that it can be stubbed
out.

BUG: 28845855
TEST: Compiles & unit-test passes
Change-Id: I6cb2b7ad762b3f8f2ab36d66c4b1fcc39fafffed
om/android/server/wifi/WifiConnectivityManager.java
om/android/server/wifi/WifiStateMachine.java
ee0ab818341d44614ffe56ae73ecc08b974c2cbb 20-May-2016 Roshan Pius <rpius@google.com> Change clock for time interval/elapsed measurments

1. Use the clock retrieved from WifiInjector in more modules: QNS,
Scanner, WifiConfigManager.
2. Use |elapsedRealtime| for time interval/elapsed measurments. Things
like scan results, config elements still continue to use
|currentTimeMillis|

Also,
1. Had to make |tryEnableQualifiedNetwork| public to prevent mockito from
calling the real method in WifiConfigManager.
2. Move keystore also into WifiInjector.

BUG: 28299258
BUG: 28824635
Change-Id: I91272aa5665abb741da7530d8920d09c8c5ea41f
TEST: Compiles & unit-test passes
om/android/server/wifi/WifiConfigManager.java
om/android/server/wifi/WifiConnectivityManager.java
om/android/server/wifi/WifiInjector.java
om/android/server/wifi/WifiQualifiedNetworkSelector.java
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/scanner/HalWifiScannerImpl.java
om/android/server/wifi/scanner/SupplicantWifiScannerImpl.java
om/android/server/wifi/scanner/WifiScannerImpl.java
om/android/server/wifi/scanner/WifiScanningServiceImpl.java
1bf155710ada7a6ee27453a120690d2c91a0fec5 19-May-2016 mukesh agrawal <quiche@google.com> WifiLogger: fetch packet fate on dump()

We've observed that it's tricky to detect when a connection
fails. Consequently, even if the user is careful to generate
a bugreport while the device is in the failed state, the
bugreport will not include packet fate data for the most
recent connection.

Improve the utility of packet fate, by fetching the most
recent fate on the call to dump(). With this change in place,
we'll get packet fates for the most recent connection
attempt (even if it's still in progress).

BUG=28849396
TEST=unit tests, manual

Manual test
- configure bullhead for open network
- configure bullhead for wpa-2 network, wrong password
- let bullhead fail connecting to wpa-2 network
- let bullhead succeed connecting to open network
$ adb dumpsys > /tmp/dumpsys
$ grep 'fates ---' /tmp/dumpsys
--------------------- Last failed connection fates ----------------------
--------------------- Latest fates ----------------------

Change-Id: Iaeb2584020f70ac5d2f3139bac72ea07a7ddce81
om/android/server/wifi/WifiLogger.java
30c88d6ec01c9f871ac62c6c7038bc99c2a6f7d8 19-May-2016 Mukesh Agrawal <quiche@google.com> Merge "WifiNative: add wallclock timestamps for packet fate" into nyc-dev
eaf6303a081b4a7f2231b5053099da7a1c16b7bd 18-May-2016 mukesh agrawal <quiche@google.com> WifiNative: add wallclock timestamps for packet fate

Packet fate reports are timestampped in a different format than
logcat messages. This makes it hard to correlate packet fate
summaries with other system activity.

Resolve this, by adding wall-clock timestamps to packet fate
summaries.

BUG=28701632
TEST=manual test

Manual test:
- set bullhead to non-GMT timezone
- install build on bullhead
- trigger connection failure
- verify that walltime column is in the right ballpark,
relative to logcat messages

Change-Id: I3aed8d9acca42f0ef0cc4f2f2fbdabdde33ce4c8
om/android/server/wifi/WifiNative.java
bf984686a38b0574c18f728a21dfadf620d5e427 19-May-2016 Mitchell Wills <mwills@google.com> Merge "Fix crash when scanner gets results that don't match the request" into nyc-dev
18eda1dc93cdb4fb79f8022c661b7464c2ac0397 18-May-2016 TreeHugger Robot <treehugger-gerrit@google.com> Merge "WifiConnectivityManager: partial scan only when connected" into nyc-dev
ee9329dc901d59b8ae1e39edac99bd9d91306d2f 18-May-2016 Randy Pan <zpan@google.com> WifiConnectivityManager: partial scan only when connected

Starts partial scan only when Wifi is connected and traffic
is heavy. This is to work around an issue that WifiInfo
tx/rx rate is not updated to reflect the Wifi state. Ideally
the tx/rx rate should have been reset to 0 when Wifi is
disconnected.

Bug: 28831562
Change-Id: Ifa415b14e2b216654ddd8a2a0c885754da489bef
Test: Wifi Framework Unit Tests, manual tests
om/android/server/wifi/WifiConnectivityManager.java
43d1480fe5ec04f3dec53cbe9d6c46186ddc8d44 18-May-2016 Mukesh Agrawal <quiche@google.com> Merge changes I5884dee0,I6f4cb00c into nyc-dev

* changes:
WifiLogger: use large ringbuffers on eng/userdebug
WifiService: add build properties abstraction
8df302f5b9c647f69acee24e09fa20d8b5c54c4a 18-May-2016 mukesh agrawal <quiche@google.com> WifiLogger: use large ringbuffers on eng/userdebug

We're having trouble resolving some field reports, due
to insufficient time coverage in the HAL ring buffers.

Increase the ringbuffer size of eng/userdebug builds,
to make it easier to debug issues reported by
dogfooders.

This change will be reverted closer to launch.
(b/28822174 has been filed for the reversion.)

BUG=28729317
TEST=unit tests

Change-Id: I5884dee05db79245d211a457ff44b5e7b96ddbcb
om/android/server/wifi/FrameworkFacade.java
om/android/server/wifi/WifiLogger.java
om/android/server/wifi/WifiStateMachine.java
b6d6e31dc6ed9a9a0178990a0cec8edb9ad36c77 18-May-2016 mukesh agrawal <quiche@google.com> WifiService: add build properties abstraction

As it turns out, WifiStateMachine isn't the only thing that
wants to change its logging behavior depending on
Build.TYPE.

1) Add an abstraction of Build.TYPE, so that we can
a) check build type in a common way, and
b) test the logging behavior across build types
2) Migrate WifiStateMachine to use this new abstraction.

BUG=28822027
TEST=unit tests

Change-Id: I6f4cb00ccb5f3a4b9a5b67e69f8365aab7fd429c
om/android/server/wifi/BuildProperties.java
om/android/server/wifi/SystemBuildProperties.java
om/android/server/wifi/WifiInjector.java
om/android/server/wifi/WifiStateMachine.java
ac90f832cc7efcbe0a7a2ec24d8d45192e3ecc66 18-May-2016 Randy Pan <zpan@google.com> Merge changes from topic 'exponential backoff periodic scan' into nyc-dev

* changes:
WifiConfigManager: clean up makeChannelList()
WifiStateMachine: clean up dead code
WifiConnectivityManagerTest: exponential backoff periodic scan
Restrict connectivty periodic scan
f5cdd8e7a6b7d4c0b5f77134273c7e894d8c087b 16-May-2016 Mitchell Wills <mwills@google.com> Fix crash when scanner gets results that don't match the request

Before this, when WifiScanningService processed single scan results from
supplicant that only contained results that did not match a request the
filter code would return null indicating that the results should not be
delivered, causing a NPE later. This change updates the meaning of the
bucket index that the single scan code provides to the filtering code to
instead force it to always include scan results.

Change-Id: I65cd57b14abacec3f407991188c570601d05ac77
Fixes: 28794598
om/android/server/wifi/scanner/ScanScheduleUtil.java
c03758554f64e6afeaaf5068df0e691d0aa006a3 17-May-2016 TreeHugger Robot <treehugger-gerrit@google.com> Merge "SupplicantScannerImpl: Change PNO scan log location" into nyc-dev
c7d77be3baa194e67f676594ae8f958156e27cbb 17-May-2016 Mukesh Agrawal <quiche@google.com> Merge "packet fate: include status code for auth+associate" into nyc-dev
304d3451b9245f7c7bb5e81465561f0eb63b2473 16-May-2016 Randy Pan <zpan@google.com> WifiConfigManager: clean up makeChannelList()

Removed the unused input paramater 'restrict'. Updated its
callers.

Bug: 28786277
Change-Id: I44dc870ce3f353698187f76e8996cc77395b17d3
Tests: Wifi Framework Unit Tests, manual tests
om/android/server/wifi/WifiConfigManager.java
om/android/server/wifi/WifiConnectivityManager.java
om/android/server/wifi/WifiStateMachine.java
46604d0d8d27c9dbdf986032de6e906e331f80ce 16-May-2016 Randy Pan <zpan@google.com> WifiStateMachine: clean up dead code

Cleaned up the dead code from the original exponential back off
scan implementation.

Bug: 28750989
Bug: 28070598

Change-Id: I8abf82cdaa3530fb514794b4004c5d3f15950672
Tests: Wifi Unit Tests, manual test
om/android/server/wifi/WifiConfigManager.java
om/android/server/wifi/WifiConnectivityManager.java
om/android/server/wifi/WifiStateMachine.java
b32b649c815b0b50fd0127d9d4a4563c54a536fb 16-May-2016 Randy Pan <zpan@google.com> WifiConnectivityManagerTest: exponential backoff periodic scan

Add a couple of unit tests to cover the periodic scan exponential
backoff feature.

Extended MockAlarmManager class such that users can query a
pending alarm's trigger time.

Bug: 28750989
Change-Id: I9520477180786fce2937e5fa87f790f60f12a3da
om/android/server/wifi/WifiConnectivityManager.java
ae9e0ef3efdd579fab8d89b5c653f4069e7ac883 13-May-2016 Randy Pan <zpan@google.com> Restrict connectivty periodic scan

When the phone screen is on, the periodic scan interval is setup
in an exponential backoff fashion. Also, if the traffic is higher
than certain threshold, perform scan on certain channels only
instead of full band.

Bug: 28627603
Change-Id: I95b686d7835265d843edac7c005f661393ae5383
om/android/server/wifi/WifiConnectivityManager.java
ab3adbcced14ec2ae5cf8f8a75f2ef9c9224f2a3 17-May-2016 Roshan Pius <rpius@google.com> SupplicantScannerImpl: Change PNO scan log location

Since PNO scans are started by the PNO debouncer (which debounces PNO state
change for 5 seconds), the log message stating that we have started PNO
scan should be moved to the location where the scan is actually started.

This removes the confusion from the logs in the below case:
05-16 16:51:40.135 D/SupplicantWifiScannerImpl( 876): Change PNO state
from false to true
05-16 16:51:42.356 D/SupplicantWifiScannerImpl( 876): Change PNO state
from true to false
05-16 16:51:45.109 D/SupplicantWifiScannerImpl( 876): Start PNO timer
with delay 2247
05-16 16:51:45.116 D/SupplicantWifiScannerImpl( 876): Starting wifi PNO
scan
05-16 16:51:50.111 D/SupplicantWifiScannerImpl( 876): Change PNO state
from false to true
05-16 16:51:52.368 D/SupplicantWifiScannerImpl( 876): Change PNO state
from true to false
05-16 16:51:55.143 D/SupplicantWifiScannerImpl( 876): Start PNO timer
with delay 2225
05-16 16:51:55.148 D/SupplicantWifiScannerImpl( 876): Starting wifi PNO
scan

BUG: 28800979
Change-Id: Ib4cc7c59fde83a02a2b938fb334a85f0c046cd87
om/android/server/wifi/scanner/SupplicantWifiScannerImpl.java
8adf99d607e2ee41513fa63a4b8a7118b22ab928 17-May-2016 Ningyuan Wang <nywang@google.com> Merge "Fix null intent handling" into nyc-dev
cf731bc480e2e11474b5d820b7d7a04bd0eff176 16-May-2016 Ningyuan Wang <nywang@google.com> Fix null intent handling

This also fixes the potential crash when handling intent
with null action string.

BUG=28689719
TEST=compile
TEST=runtest frameworks-wifi

Change-Id: I6ef3e07e38f33d8c5040dd358f161224095189d6
om/android/server/wifi/WifiTrafficPoller.java
5e550bdccf8aaace892366fbbaf90bd0a7c456af 14-May-2016 mukesh agrawal <quiche@google.com> packet fate: include status code for auth+associate

During 802.11 authentication, we've seen wpa_supplicant
report error information that is at odds with
over-the-air traffic.

For systems that provide packet fate for these early
frames, we can gather better information about the
auth process from the frames themselves.

Specifically: we can include the status code in the
packet fate summary. Make it so.

While there:
- fix a whitespace issue in parseIeee80211FrameCtrlType()
- rename frameControlField, since it didn't really hold
all of the frame control info. (frameControlField
omitted the frame control flags.)
- modify some packet fate tests to be less specific about
expected whitespace; it's too hard to maintain the tests
when exact whitespace matching is required

BUG=28717266
TEST=unit tests
TEST=manual

Manual test
- configure hostapd to allow zero connections
- configure bullhead to connect to hostapd
$ adb shell dumpsys > /tmp/dumpsys
- verify that packet fate summary shows auth frame with status 17

Change-Id: Ib8742091d0a9acc7fdde0423229d150bf4c1c6d8
om/android/server/wifi/WifiNative.java
om/android/server/wifi/util/FrameParser.java
6b838f693ae0635b8f513d14725e54efadc29977 16-May-2016 Mitchell Wills <mwills@google.com> Add scan bucket for 80s period scans

Change-Id: I87779468d37971c53c1c9cfd615e5ca2e7a65108
Fixes: 28793104
om/android/server/wifi/scanner/BackgroundScanScheduler.java
9ed1f7b1a80aae513f3730869b614f66b6c79125 09-May-2016 Erik Kline <ek@google.com> Move WifiP2pServiceImpl to IpManager

Bug: 28437662
Change-Id: I9d478d644cc5b52a031a3ee3e157d40f952dff50
om/android/server/wifi/p2p/WifiP2pServiceImpl.java
c2c27ff4aa6dfd4449612d61afd62d89b9652618 10-May-2016 Rebecca Silberstein <silberst@google.com> Merge changes Ie19e66b9,Idfcc51e2,Ie2b6f031 into nyc-dev

* changes:
WifiController: set to proper state after SoftAP
WifiControllerTest: cleanup style issues
WifiSettingsStore: add methods for WifiSavedState
208c3c19bae4801f7e18c44e1ce2b6e06dd19d05 10-May-2016 Ningyuan Wang <nywang@google.com> Merge "Fix string comparision and return value in try catch block" into nyc-dev
191fa5b445e8cfd0fa2c4aa7458776ab7a3972f7 09-May-2016 Rebecca Silberstein <silberst@google.com> WifiController: set to proper state after SoftAP

After receiving a CMD_AP_STOPPED message, WifiController should return
to the DeviceActive state or the appropriate Idle state. This CL sets
the correct pending state and also adds a check for the idle state.
A test is also added to confirm the DeviceActive state is entered after
the SoftAp state is completed.

Note: An additional test for the DeviceIdle path will be added at a
later point after some code refactoring (bug 28669096)

BUG: 28434530
Change-Id: Ie19e66b9c84ff545a622119890bc7705ebd74c46
om/android/server/wifi/WifiController.java
3f2620fbec3b556148211c429af5cbcd9ea174a2 07-May-2016 Rebecca Silberstein <silberst@google.com> WifiSettingsStore: add methods for WifiSavedState

Add methods to get and set WifiSavedState in WifiSettingsStore. This
change allows us to better test state transitions in WifiController
since we can now mock out the calls easily.

BUG: 28434530
Change-Id: Ie2b6f0311462da0179ecd28665f78f4bf14a02f9
om/android/server/wifi/WifiController.java
om/android/server/wifi/WifiSettingsStore.java
b53cd9aa2625ec2a1c2e69c609d8a9dda3569a36 10-May-2016 Mitchell Wills <mwills@google.com> Merge "SupplicantScanner: Truncate hidden network list" into nyc-dev
027f5195dced3e660c100c539e3d9dfaa668c215 09-May-2016 Randy Pan <zpan@google.com> Merge "WifiConfigManager: clean up log message level" into nyc-dev
48371a12a251b17593a14f1af37935764599e615 09-May-2016 Randy Pan <zpan@google.com> Merge "WifiStateMachine: fix setTargetBssid()" into nyc-dev
646ee7704694ef70c0dd3c707170163361ed504a 07-May-2016 Randy Pan <zpan@google.com> WifiConfigManager: clean up log message level

Quite some logs should be debug message instead of error
message.

Bug: 28619076
Change-Id: Iee06f57bab58aeca881068f0b4f36a0d5bbb3230
Test: Wifi Unit Tests
om/android/server/wifi/WifiConfigManager.java
b2c2f85c959cb0deba238b566f39b1b942eb70a8 05-May-2016 Ningyuan Wang <nywang@google.com> Fix string comparision and return value in try catch block

This CL uses value comparision instead of reference comparision
for strings.
This also removes returning value in finally block, otherwise
exception may be suppressed.

BUG=28605846
TEST=compile
TEST=runtest frameworks-wifi

Change-Id: I6ace4d233d2b0af3627f75dfdb7dcec6a46b0092
om/android/server/wifi/WifiApConfigStore.java
om/android/server/wifi/WifiCertManager.java
om/android/server/wifi/WifiConfigManager.java
om/android/server/wifi/WifiCountryCode.java
om/android/server/wifi/WifiStateMachine.java
362fad8eddd674d7cf19ffcc1fec38d2d2ee2f53 06-May-2016 Roshan Pius <rpius@google.com> SupplicantScanner: Truncate hidden network list

Truncate the hidden network id list if it goes beyond wpa_supplicant's
max value. wpa_supplicant has a hard coded value of 16 for the max
number of networks that can be specified for each scan.

There is currently no way to query this value from wpa_supplicant, so
hardcoding this value in SupplicantScanner.

BUG: 28632556
Change-Id: I31a338b91c221c1686437b738894e13abb897474
TEST: Compiles & unit-test passes
om/android/server/wifi/scanner/SupplicantWifiScannerImpl.java
85c0f06d47e484e039e3ad1f584c7c9b8410c2b1 06-May-2016 Randy Pan <zpan@google.com> WifiStateMachine: fix setTargetBssid()

Always return when the current preferred BSSID is the same as
the target one. This was done previously only if the DBG flag
is set.

While there, fixed the log message wording a bit.

Bug: 28619076
Tests: Wifi unit tests, manual connection & roaming tests
Change-Id: I109b57d54b1bcaccb00a148b488244b7d9358907
om/android/server/wifi/WifiStateMachine.java
a4e4bd02b4d77de2ad69fcdf79a32c6fbb395513 06-May-2016 Randy Pan <zpan@google.com> Clear config BSSID after successful roaming

Clear the config BSSID after roaming completed and before entering
ConnectedState. Wifi chipset may roam from this point on and
having the BSSID specified by QNS would cause the roam to fail
and the device to disconnect.

We used to rely on the fact that entering ObtainingIpState
clears the config BSSID. But this assumption was broken by
commit bcbc449d47124ec8f73a, which changed from transition
to ObtainingIpState to ConnectedState.

Bug: 28520770
Test: Wifi unit tests, manual tests
Change-Id: I09a2d5d1132ff597c63a324a24d13719be384603
om/android/server/wifi/WifiStateMachine.java
a4da0a81a0a93faac3a8d9ef8d83b1a35c500073 06-May-2016 Roshan Pius <rpius@google.com> Merge changes I1424053c,I96e35e06 into nyc-dev

* changes:
WifiConnectivityManager: Unit tests for metrics
WifiConnectivityManager: Increment metrics
1d7d62393181cc36b6f87c3cf2151adc54275f9c 04-May-2016 Roshan Pius <rpius@google.com> WifiConnectivityManager: Unit tests for metrics

Add couple of unit-tests for metrics. Had to migrate the unit-tests to use
mock alarm manager.

BUG: 27479439
BUG: 27704599
BUG: 28480516
Change-Id: I1424053c35799905612b37edeb679e7556568ca5
TEST: Compiles & unit-test passes
om/android/server/wifi/WifiConnectivityManager.java
bacd0dca59fbba9f650a421a3d3b0dc5fa2eb606 04-May-2016 Roshan Pius <rpius@google.com> WifiConnectivityManager: Increment metrics

Make changes to increment the watchdog related metrics in
WifiConnectivityManager.

PS: Will need to add mock alarm manager to add unit-tests here. This is
done in the next CL.

BUG: 27479439
BUG: 27704599
Change-Id: I96e35e06d222056ec29488666619486a65746b38
om/android/server/wifi/WifiConnectivityManager.java
855b32875a1ab89aa073f772790bdf71a42d08f9 04-May-2016 Mukesh Agrawal <quiche@google.com> Merge changes Icaa91d9d,Ic930337a into nyc-dev

* changes:
WifiStateMachine: dynamically configure WifiHAL log level
wifi service: abstract away access to SystemProperties
d06a43097e21f90b9dca90a3767e8c7f610c67d8 04-May-2016 Mitchell Wills <mwills@google.com> Merge "Suppress some Supplicant WifiScanner logs" into nyc-dev
576cda1bc1660af54dc52d933c79d43014e466e9 04-May-2016 Mitchell Wills <mwills@google.com> Merge "Add more details about what scan results were delivered to clients" into nyc-dev
e49b29c8c378fd93421359034117a4d5b7b7062a 04-May-2016 Glen Kuhne <kuh@google.com> Merge "Fix null configs passed to WifiLastResortWatchdog" into nyc-dev
59298c7cfffdf856e32879ec967fe27c7e977a49 04-May-2016 Mitchell Wills <mwills@google.com> Add more details about what scan results were delivered to clients

Fixes: 28563549
Change-Id: I445054af4b176c69a26af6fe340a6eb88cf06452
om/android/server/wifi/scanner/WifiScanningServiceImpl.java
2617b7a7df6bcc9b12a89bc6e26662b3be997fcd 10-Apr-2016 mukesh agrawal <quiche@google.com> WifiStateMachine: dynamically configure WifiHAL log level

By default, VERBOSE level logging is disabled for native code.
However, when debugging Wifi issues, we'll sometimes want to
include VERBOSE level log messages from the HAL implementation.

Update WifiStateMachine's verbose-debugging logic, to support
this case.

Note that VERBOSE level messages will not be compiled in
on user builds. Nor will system server be permitted to change
the logging level on user builds. For these reasons, the
log level is only modified on non-user builds.

BUG=27857554
TEST=unit tests, manual

Manual test (bullhead):
- On userdebug build with 'Enable Wi-Fi Verbose Logging' set:
$ adb reboot && adb wait-for-device && adb logcat -d | grep 'V WifiHAL'
-> matching lines seen
$ adb shell getprop | grep WifiHAL
[log.tag.WifiHAL]: [V]
- On userdebug build with 'Enable Wi-Fi Verbose Logging' unset:
$ adb reboot && adb wait-for-device && adb logcat -d | grep 'V WifiHAL'
-> NO matching lines
$ adb shell getprop | grep WifiHAL
[log.tag.WifiHAL]: [D]
- On user build with 'Enable Wi-Fi Verbose Logging' set:
$ adb logcat -d | grep 'V WifiHAL'
-> NO matching lines
$ adb shell getprop | grep WifiHAL
-> NO matching lines

Change-Id: Icaa91d9d1261a6cf5851d5ad9b0a6a25fd329344
om/android/server/wifi/WifiStateMachine.java
f74a1cfd50d7b44aa7e4b598eb229cd464983dfe 03-May-2016 mukesh agrawal <quiche@google.com> wifi service: abstract away access to SystemProperties

We want the ability to modify the value of a system property,
so that we can dynamically change the logging level for WifiHAL.

This ability depends on permissions that are not available to
the test runner. For example, the process that is running the
wifi service code needs the ability to connect to the
|property_service| socket.

To resolve the problem, we do the following:
- add a PropertyService interface, which abstracts away access
to SystemProperties
- add PropertyService to the dependencies managed by WifiInjector
- add SystemPropertyService, which routes property requests
to android.os.SystemProperties
- update WifiStateMachine, to access properties via PropertyService
- update WifiStateMachineTest, to use a mock implementation of
PropertyService

BUG=27857554
TEST=unit tests

Change-Id: Ic930337a6a8f6a600ae7b4da2ca2eaf5c9e6c2cb
om/android/server/wifi/PropertyService.java
om/android/server/wifi/SystemPropertyService.java
om/android/server/wifi/WifiInjector.java
om/android/server/wifi/WifiStateMachine.java
5cdc80d103ebd2935693a8d855162d55bed2821c 04-May-2016 Mitchell Wills <mwills@google.com> Suppress some Supplicant WifiScanner logs

Fixes: 28452172
Change-Id: I99a1c11f15adf615b13496aec63642bfc2e552de
om/android/server/wifi/scanner/SupplicantWifiScannerImpl.java
4623817eb6b784f160763a22b3e06891ab11cf20 03-May-2016 Glen Kuhne <kuh@google.com> Fix null configs passed to WifiLastResortWatchdog

This CL fixes a bug where scan results were being paired with null
configs instead of their associated WifiConfiguration, and passed to
WifiLastResortWatchdog. This lead to the watchdog trigger potentially
not activating.

BUG=28476482

Change-Id: I0a10fc2309cf2199001dc440ed93ceaa3c891dba
om/android/server/wifi/WifiQualifiedNetworkSelector.java
f55d6b141718183eba880a86714d45d8e9c503e1 03-May-2016 Glen Kuhne <kuh@google.com> Fixed NetworkFactories being dumped twice

mNetworkFactory and mUntrustedNetworkFactory are being dumped twice. The
second time, potentially causing null exceptions.
Removed the second calls (were left over from bad rebase).

BUG=28530520

Change-Id: I3312ac83a7ea2d4027036ea85702caa74985753d
om/android/server/wifi/WifiStateMachine.java
00f5ad8bafa58232b799e5195783a444fa9168fe 02-May-2016 Randy Pan <zpan@google.com> Merge "WifiConnectivityManager: PNO retry for low RSSI network" into nyc-dev
0d491e5bf120b31534e03c5ec7c187ae4cf00fff 02-May-2016 Ningyuan Wang <nywang@google.com> Merge "Optimize logcat fetching by using logcat -t option" into nyc-dev
12cf770141cd8223809fbb69223dafb631ca4352 02-May-2016 Randy Pan <zpan@google.com> Merge "Fix check on current connected/connecting network" into nyc-dev
3d09b9117df33608a43c1fbe0135123e2de9aea2 27-Apr-2016 Randy Pan <zpan@google.com> WifiConnectivityManager: PNO retry for low RSSI network

Added an exponential back off retry mechanism for networks
found by PNO scan but rejected by QNS due to their low RSSI
values.

Bug: 28402107
Change-Id: I8a69afb3d22fbd2f479073e6087893c24e5a5d39
om/android/server/wifi/WifiConnectivityManager.java
91a8893f047b8a193e4516ab772b6f43882777f5 30-Apr-2016 Rebecca Silberstein <silberst@google.com> WifiLastResortWatchdog: update config if not null

When new scan results are processed, networks already stored as the
available networks may have updated configs passed in, but they may also
have null configs. The null configs should not be used to update the
stored config. Added a check to determine if the passed in config is
not null before the update.

In addition, debugging output also reported the value of
HasEverConnected as false for networks with a null config. This was
updated to report null_config instead.

Added tests covering config updates.
Added tests for debugging output.

BUG: 28451079
Change-Id: Iff9888ab87c61619b2f865516eca22d87eb4f4b8
om/android/server/wifi/WifiLastResortWatchdog.java
50abba06efa7834b5309df561375e4a2e2df630d 29-Apr-2016 Randy Pan <zpan@google.com> Fix check on current connected/connecting network

Keep track of the network BSSID of the last connection attempt.
This BSSID is checked in case the phone is still in the process of
connecting to that network. mWifiInfo is checked for the currently
connected network. This is for the case that firmware performed
roaming automatically.

While there, addressed a checkstyle issue.

Bug: 28462151
Change-Id: Ia9316048e0549036de1c20bf1f3099cfcda9a75e
Test: WiFi unit tests
om/android/server/wifi/WifiConnectivityManager.java
ddf3afe31f5e2174643e41943e9e9b881033981a 28-Apr-2016 TreeHugger Robot <treehugger-gerrit@google.com> Merge "WifiLastResortWatchdog metrics" into nyc-dev
7883cf595742b2c9b1ccba223b45a5fcb6978ec9 27-Apr-2016 TreeHugger Robot <treehugger-gerrit@google.com> Merge changes I91ad6127,I416bfd0e into nyc-dev

* changes:
WifiLastResortWatchdog trigger logic
WifiLastResortWatchdog failure counting
5f001750a0ce82a8b3a47ac566117d4de27f3e23 22-Apr-2016 Glen Kuhne <kuh@google.com> WifiLastResortWatchdog metrics

Added logging of various metrics to the WifiLastResortWatchdog. These
metrics count the number of times the Watchdog triggers, and stats
counting the number of networks present at failure time for different
failure types.

BUG=27856474

Change-Id: If43836b1c33791fefb8000196b231c312161feef
om/android/server/wifi/WifiInjector.java
om/android/server/wifi/WifiLastResortWatchdog.java
om/android/server/wifi/WifiMetrics.java
83f2b8087178705445e4d1618eaac832f9c633f4 20-Apr-2016 Glen Kuhne <kuh@google.com> WifiLastResortWatchdog trigger logic

Implemented trigger condition logic that is checked after a failure is
counted. The condition takes into account: failure counts, wifi
connected state, past connections to saved networks and whether the
watchdog has fired since the wifi environment changed.

Please note: This change only implements the logic for deciding when to
trigger, not the trigger itself.

BUG=27856709

Change-Id: I91ad6127a72ca24c72a5520348c4fff83f16b559
om/android/server/wifi/WifiLastResortWatchdog.java
om/android/server/wifi/WifiStateMachine.java
1f4fa946d229906500f381fa5561821fba164ba8 27-Apr-2016 Randy Pan <zpan@google.com> Fix setEnableAutoJoinWhenAssociated() handling

Move the execution of this method to the thread of
WifiStateMachine to address a potential WifiConnectivityManager
concurrent access issue.

While there, remove a dead method.

Bug: 28369823
Change-Id: I49f424637ee6897495daedbf4b1cc06477e78798
om/android/server/wifi/WifiStateMachine.java
c8a21e495dfaa5c44e87fda330621a1ed6c8aace 26-Apr-2016 Randy Pan <zpan@google.com> WifiConnectivityManager: Run AlarmManager on WifiStateMachine thread

With WifiScanner also running on the WifiStateMachine thread,
WifiConnectivityManager is now exectued on a single thread context.

While there, fixed a few checkstyle issues.

Bug: 28369823
Change-Id: Ibf2b65be42d243deb61a68380a9011f4acc663b4
om/android/server/wifi/WifiConnectivityManager.java
om/android/server/wifi/WifiStateMachine.java
f6807b2f28848838d60aef1c9563c79e15cd7519 27-Apr-2016 Roshan Pius <rpius@google.com> Merge "WifiConnectivityManager: Add stats for rate limiting" into nyc-dev
5c9943e8c89f5f857d0680f0c77f7fccdfabd9f4 26-Apr-2016 TreeHugger Robot <treehugger-gerrit@google.com> Merge "Revert "WifiStateMachine: dynamically configure WifiHAL log level"" into nyc-dev
8fe3e3497daf08b71ffc8c33cb7b139df6667448 14-Apr-2016 Glen Kuhne <kuh@google.com> WifiLastResortWatchdog failure counting

Implemented watchdog methods and calls to them from WifiStateMachine to
count association rejection, authentication failure & dhcp failures.

This will allow the watchdog to determine when all available networks
are failing, and Wifi Framework has no other options, however this Cl
does not implement that logic.

BUG=27855690
BUG=27856523

Change-Id: I416bfd0e0340823de5ca04f2d040bff7a751b677
om/android/server/wifi/WifiLastResortWatchdog.java
om/android/server/wifi/WifiStateMachine.java
9a65085cf054575bdb7fbd6bce672bd902b633fc 26-Apr-2016 Ningyuan Wang <nywang@google.com> Merge "Do not use ANQP when Wifi is connecting or connected" into nyc-dev
3cd7bbde2e51c99f69904f0d6b6481334e70f55a 26-Apr-2016 Mukesh Agrawal <quiche@google.com> Revert "WifiStateMachine: dynamically configure WifiHAL log level"

This reverts commit ced2db17a5049bc84a58934ca91c25f7147ee012.

Reverting due to test failure.
BUG=28385150

Change-Id: I86ffd7f017727ee94508102cd7a2962dcf803ffc
om/android/server/wifi/WifiStateMachine.java
d54ddacc42d9cd929d40b1df391895293bacafe2 22-Apr-2016 Roshan Pius <rpius@google.com> WifiConnectivityManager: Add stats for rate limiting

BUG: 28242396
Change-Id: I53c0e91d2b9ee2731c0f74ef6376f4fb4e67f2e9
om/android/server/wifi/WifiConnectivityManager.java
c7c241f0e59329c7c50101926fb9bde7ef6cca6f 26-Apr-2016 Mitchell Wills <mwills@google.com> Merge "Fix another potential crash when dumping WifiScanningService" into nyc-dev
25864553f48e32671d86e256fe20136e7e05e695 26-Apr-2016 TreeHugger Robot <treehugger-gerrit@google.com> Merge "WifiStateMachine: dynamically configure WifiHAL log level" into nyc-dev
1e5f0667515826cdc9c85a63a82c4c48cad446c2 22-Apr-2016 Ningyuan Wang <nywang@google.com> Do not use ANQP when Wifi is connecting or connected

Sending ANQP request when wifi is connecting or connected
may fail the connection.
This CL fixes it by adding a parameter to WifiConfigManager
::updateSavedNetworkWithNewScanDetail(). This boolean value
can indicate that we are connecting or connected.
Link debouncing is also considered as connecting in this case.

BUG=26494190
TEST=runtest frameworks-wifi
Change-Id: Ic4dfd0c0ba0392da68b6705d18fb82d92f44e508
om/android/server/wifi/WifiConfigManager.java
om/android/server/wifi/WifiQualifiedNetworkSelector.java
b8635136f9a15f0d79a142f12d3b56fa727327f3 25-Apr-2016 TreeHugger Robot <treehugger-gerrit@google.com> Merge "WificonfigManager: Split out scandetail to network lookup" into nyc-dev
d36b93b07ee7a3f6116cc7ae7a1a1e6b687a9d3c 25-Apr-2016 Mitchell Wills <mwills@google.com> Fix another potential crash when dumping WifiScanningService

Also make logging in WifiScanningService not static and add some tests
to verify some logging behavior.

Fixes: 28274869
Change-Id: I879200778dcadb4e67d5a85d42442baf3ceef6c9
om/android/server/wifi/scanner/WifiScanningServiceImpl.java
6181c4c32d8bb792fa7f66e8859f6b1037980ac5 25-Apr-2016 Pankaj Kanwar <pkanwar@google.com> Merge "Fix the string equality check, to avoid a possible NPE." into nyc-dev
f799eff77d81ae0509b8b890a7c6068d5c6cda6e 22-Apr-2016 Roshan Pius <rpius@google.com> WificonfigManager: Split out scandetail to network lookup

Create a separate method to fetch the saved network from scan detail.
This can be used for caching dtim values in WifiStateMachine.

BUG: 26494190
TEST: Compiles & unit-test passes

Change-Id: Ib5819fd72afc3dcf691735deccb237874eac3f8d
om/android/server/wifi/WifiConfigManager.java
om/android/server/wifi/WifiStateMachine.java
37e073350c5e3bdac08d4fa2a0cc9f37190d1173 22-Apr-2016 Ningyuan Wang <nywang@google.com> Optimize logcat fetching by using logcat -t option

WifiLogger::getOutput() sometimes takes more than a few
seconds because it fetchs the entire logcat buffer then takes
the most recent 127 lines.
Since it is a blocking call, it may increase the chance that
WifiService being killed by WatchDog.

This change uses logcat -t option, only fetching the
most recent 127 lines. It significantly reduces the time of the
blocking call.

BUG=28298654
TEST=unit tests, manual test
Manual test:
- boot device
$ adb logcat -d | wc -l
-> repeat until >127
$ adb bugreport > /tmp/bugreport
- check that ‘system log:’ section contains 127 lines.

Change-Id: Ifcfb9e53a7c8b731e76cab1f25cec1bc0c83f33e
om/android/server/wifi/WifiLogger.java
a7bf9d90d68a4833cc3c64da98024167931c4b1e 22-Apr-2016 pkanwar <pkanwar@google.com> Fix the string equality check, to avoid a possible NPE.

b/27905553 This fixes CTS failures in testProtectedBroadcasts in
android.permission.cts.TelephonyManagerPermissionTest.

Currently the "state" variable can be null, so the equality condition
has been rearranged to avoid the NPE.

Change-Id: I0326df8680c6e37bc2151a38f8f74305b3f8de79
om/android/server/wifi/WifiServiceImpl.java
c7338605251ff62f6e21737b1cfca865ce6f3dd9 22-Apr-2016 Roshan Pius <rpius@google.com> Merge changes I2bfae3a9,I3e247667 into nyc-dev

* changes:
WifiConnectivityManager: Unit tests for rate limit
WifiConnectivityManager: Connection rate limit
05e91b1c9b1e261d8f72b32e5ab3a85e1c8e0bc3 22-Apr-2016 TreeHugger Robot <treehugger-gerrit@google.com> Merge "WifiConnectivityManager: Turn off ePno/Gscans" into nyc-dev
ced2db17a5049bc84a58934ca91c25f7147ee012 10-Apr-2016 mukesh agrawal <quiche@google.com> WifiStateMachine: dynamically configure WifiHAL log level

By default, VERBOSE level logging is disabled for native code.
However, when debugging Wifi issues, we'll sometimes want to
include VERBOSE level log messages from the HAL implementation.

Update WifiStateMachine's verbose-debugging logic, to support
this case.

Note that VERBOSE level messages will not be compiled in
on user builds. Nor will system server be permitted to change
the logging level on user builds. For these reasons, the
log level is only modified on non-user builds.

BUG=27857554
TEST=manual

Manual test (bullhead + forthcoming HAL patch)
- On userdebug build with 'Enable Wi-Fi Verbose Logging' set:
$ adb reboot && adb wait-for-device && adb logcat -d | grep 'V WifiHAL'
-> matching lines seen
$ adb shell getprop | grep WifiHAL
[log.tag.WifiHAL]: [V]
- On userdebug build with 'Enable Wi-Fi Verbose Logging' unset:
$ adb reboot && adb wait-for-device && adb logcat -d | grep 'V WifiHAL'
-> NO matching lines
$ adb shell getprop | grep WifiHAL
[log.tag.WifiHAL]: [D]
- On user build with 'Enable Wi-Fi Verbose Logging' set:
$ adb logcat -d | grep 'V WifiHAL'
-> NO matching lines
$ adb shell getprop | grep WifiHAL
-> NO matching lines

Change-Id: I43af6852cd445f9a7daee04981f253a6c0ebc499
om/android/server/wifi/WifiStateMachine.java
fa2ac2743307559e8dcc5aaf54873536315fbe62 19-Apr-2016 Roshan Pius <rpius@google.com> WifiConnectivityManager: Unit tests for rate limit

Adding unit tests to verify the connection attempt rate limiting
functionality. Had to change the way system time is being fetched in
WifiConnectivityManager to achieve this.

BUG: 28242396
Change-Id: I2bfae3a9ea60cba1c3c1405dd5eb58208f12c2db
TEST: Compiles & unit-test passes
om/android/server/wifi/WifiConnectivityManager.java
om/android/server/wifi/WifiInjector.java
om/android/server/wifi/WifiStateMachine.java
4f5054647a2f4cac54a78d6e3bf3efa0727b488a 18-Apr-2016 Roshan Pius <rpius@google.com> WifiConnectivityManager: Connection rate limit

Implement a rate limit for connection attempts to prevent us flapping
between networks.

While there,
Cleanup all the static time values to be more readable.

BUG: 28242396
Change-Id: I3e2476674e7239e000b93b95751acec3ea7bc8ce
om/android/server/wifi/WifiConnectivityManager.java
ca4e81e099ff1608874a91afd9846100d4599f04 22-Apr-2016 TreeHugger Robot <treehugger-gerrit@google.com> Merge "WifiConfigManager: Remove redundant code" into nyc-dev
ad36265b6efc83414daf7e38283826482dfb5045 21-Apr-2016 Roshan Pius <rpius@google.com> WifiConfigManager: Remove redundant code

Remove some redundant code in enableNetwork and move some the network
status updation from state machine to ConfigManager.

BUG: 28317135
Change-Id: I375af87bd971352d3066a150e046571f00de44fd
TEST: Compiles & unit-test passes
om/android/server/wifi/WifiConfigManager.java
om/android/server/wifi/WifiStateMachine.java
7ce0f144104c68da40c196c16f73e2d0bcc50cc7 21-Apr-2016 Roshan Pius <rpius@google.com> WifiConnectivityManager: Turn off ePno/Gscans

There is a lot of instability/unknowns for using ePno/Gscans for
connectivity purposes. Unless we've all of them hashed out, turn them
off.

BUG: 28300874
BUG: 28278197
Change-Id: Ifd650032237ac510687f0d374d31f7c9f13d18bd
TEST: Compiles & unit-test passes (Will send for ACTS testing).
om/android/server/wifi/WifiConnectivityManager.java
om/android/server/wifi/scanner/HalWifiScannerImpl.java
0ab2b1ad5b0c902c3e8b3c9afd786e3b79e30c95 21-Apr-2016 Jeremy Joslin <jjoslin@google.com> Set WifiNetworkScoreCache DBG to false.

Also made the constants final.

BUG:28317300
Change-Id: I32ad6d1e4dbd3f5cc1cdbde8803b66e48b9928c6
om/android/server/wifi/WifiNetworkScoreCache.java
0b775f08887d4d52e57a06c6a8680aa10a1c7bb8 21-Apr-2016 TreeHugger Robot <treehugger-gerrit@google.com> Merge "WifiLogger: fix bug in HAL callback registration" into nyc-dev
956fd40b6145c4aba9160e10bfc1ea609873ce8d 20-Apr-2016 mukesh agrawal <quiche@google.com> WifiLogger: fix bug in HAL callback registration

When we call WifiLogger.startLogging(), WifiLogger
may or may not register callbacks for ring-buffer
data delivery, and WiFi alerts.

Whether or not WifiLogger registers the callbacks
depends on whether or not the callbacks have already
been reigstered. If WifiLogger has already registered
callbacks, then a new call to startLogging() will
skip callback registration.

Now, it's not entirely clear if this already-registered
check is necessary. It is certainly conceivable that the
HAL implementations allow us to replace existing callbacks,
without explicitly removing the existing callbacks first.

But, the necessity of the check aside, the immediate
problem is that the already-registered check fails to
handle the case where an early registration failed.

This CL revises the code, to handle this case.

While there:
- Fix some whitespace issues.
- Remove unnecessary comment about the effects of
resetLogHandler(). (Even if the comment _were_ necessary,
it should be part of the Javadoc for resetLogHandler().)

BUG=28274991
TEST=(new) unit tests, manual

Manual test:
- boot device
$ adb shell dumpsys | grep -A1 'ring-buffer = driver_prints_rb'
ring-buffer = driver_prints_rb
<base64 encoded data...>

Change-Id: I04e9bc1863aaf5bda00ca9cf8dc35696ae1e5f24
om/android/server/wifi/WifiLogger.java
de68b305e798943904671f1dd56413b51fc479cb 20-Apr-2016 Jeremy Joslin <jjoslin@google.com> Merge "Use external scores on saved networks if requested." into nyc-dev
af8c59a9cb6b9cd0151b3cfa5d4ea2c698fd7eda 20-Apr-2016 Samuel Tan <samueltan@google.com> Merge changes Id4cc9c3c,Ice7dad5a into nyc-dev

* changes:
Log summarized packet fate reports
Add FrameParser
ea2048738be95ae9d5367a42ba798503a7039a6b 15-Apr-2016 Jeremy Joslin <jjoslin@google.com> Use external scores on saved networks if requested.

When a saved network has the useExternalScores boolean set to true then
lump it in with the ephemeral networks when considering it as a
candidate.

Externally scored saved networks are only considered if a saved network
candidate cannot be found.

BUG: 25562019
Change-Id: Icdb7318103e14e518536c3179cd30c87cc2c3035
om/android/server/wifi/WifiConfigManager.java
om/android/server/wifi/WifiNetworkHistory.java
om/android/server/wifi/WifiQualifiedNetworkSelector.java
985df17909a5703a86f3e665abc9dd964d9623d9 20-Apr-2016 Mitchell Wills <mwills@google.com> Fix NullPointerException when dumping WifiScanningService

If WiFi was not turned on prior to dumping WifiScanningService a
NullPointerException would be thrown.

Change-Id: I79d7a0d23db670f4fef3fb01072d3eb2155428b2
Fixes: 28274869
om/android/server/wifi/scanner/WifiScanningServiceImpl.java
14ef58beaf5c3ca9d3909ff67bbbc109521e29bf 19-Apr-2016 Roshan Pius <rpius@google.com> Merge "WifiConnectivityManager: Clear scan details after results" into nyc-dev
590f3fc2045389d5ef274c4b3bd6162d93b1a0ac 13-Apr-2016 Samuel Tan <samueltan@google.com> Log summarized packet fate reports

When verbose debugging is not turned on, log
summarized packet fate reports that include the
timestamp, direction, fate, protocol, and type of the
network frame, but nothing more. These one-line
summaries will be logged to the system dump in
table format.

BUG: 28150622
TEST: 'runtest frameworks-wifi' passes.
TEST: Manually trigger a WiFi connection failure (e.g. enter
wrong password for a secured network), and examine the
output of 'adb shell dumpsys' for the logged packet fate
summaries.

Change-Id: Id4cc9c3cdc85d209788e0eb1c51e5a47e04d0a6a
om/android/server/wifi/WifiLogger.java
om/android/server/wifi/WifiNative.java
9f04178d32d9fd84ce99fe95401692077d69497a 19-Apr-2016 Adam Lesinski <adamlesinski@google.com> Merge "Implement new async response for controller activity info" into nyc-dev
1e5ceb7ad228e29bf0f6b4706df49c684880c6e0 19-Apr-2016 Roshan Pius <rpius@google.com> Merge "WifiConnectivityManger: Enable background/ePNO scan" into nyc-dev
224198c8ba46f362a5df6d25f1b60e56f442b58b 18-Apr-2016 Roshan Pius <rpius@google.com> WifiConnectivityManager: Clear scan details after results

BUG: 28247321
Change-Id: I7913ae97ceb8566d7e0612455096362c661b6969
om/android/server/wifi/WifiConnectivityManager.java
a6b66a48b231f5729b8015d3446feb4c2fa0a9d1 06-Apr-2016 Roshan Pius <rpius@google.com> QNS: Skip ephemeral networks deleted by user

Skip ephemeral networks which were explicitly deleted by the user. This
was missed in migration from autojoin to QNS.

BUG: 28026676
Change-Id: Ib663183b29774b851e492ddd170c4b4bef03ae61
TEST: Compiles & unit-test passes
om/android/server/wifi/WifiConfigManager.java
om/android/server/wifi/WifiQualifiedNetworkSelector.java
70b4f7f1b8f57c5ae449dedb48edc0d07b6b5c41 14-Apr-2016 Samuel Tan <samueltan@google.com> Add FrameParser

Add FrameParser, a utility class that parses the contents
of a network frame, and stores it in its public member fields.
This utility will be used to print out summarized versions of
the contents of packet fate report frames.

In this initial implementation of FrameParser, we only parse out
the information we are interested in printing (i.e. the most specific
networking protocol, and the type of packet within this protocol).

BUG: 28150622
Change-Id: Ice7dad5a7800736605043688955027893fadffc7
TEST: 'runtest frameworks-wifi -c \
com.android.server.wifi.util.FrameParserTest' passes.
om/android/server/wifi/WifiLoggerHal.java
om/android/server/wifi/util/FrameParser.java
752bd0ed137ccc42cdfd911611f2d5f8d33be53c 11-Apr-2016 Sunil Dutt <usdutt@codeaurora.org> Check KEY_CONFIG_WIFI_DISABLE_IN_ECBM on ECBM notification

Wi-Fi disable on ECBM notification is controlled by the
configuration parameter KEY_CONFIG_WIFI_DISABLE_IN_ECBM.
Hence check for the same while processing the notification.

Bug: 27854016
Change-Id: If1724f825f1c8b47ec2f29ecd8abda45ef9bc393
om/android/server/wifi/FrameworkFacade.java
om/android/server/wifi/WifiController.java
79e3bf8db6b566a5b3c7065cdd43f87f07e73747 08-Apr-2016 Roshan Pius <rpius@google.com> WifiConnectivityManger: Enable background/ePNO scan

Add a new flag to control both background scans & connected PNO scan in
WifiConnectivityManager (We may need to disable connected PNO even if we
enable gscan).
Also, change the disconnected PNO interval to 20 seconds.

BUG: 28020168
BUG: 27877781
Change-Id: I6e7224b02456573070a68dbe8f5a5b0d49f37fdc
om/android/server/wifi/WifiConnectivityManager.java
om/android/server/wifi/scanner/HalWifiScannerImpl.java
6095c3ef2eb6dbe7321a23b146997ad13875696d 15-Apr-2016 Mitchell Wills <mwills@google.com> Merge "Run WifiScanner on WifiStateMachine thread" into nyc-dev
33e62df1fd2d065f6d626d800350e2063978a0ab 15-Apr-2016 Glen Kuhne <kuh@google.com> Merge "Created LastResortWatchdog class" into nyc-dev
cae5f15cb8d8cc925398b29c7bb16ade3eed7475 15-Apr-2016 TreeHugger Robot <treehugger-gerrit@google.com> Merge "WifiScanningService: Correct state machine names" into nyc-dev
799f1c026941c9183657ffb99f0fb34ff643a0dd 15-Apr-2016 Roshan Pius <rpius@google.com> WifiScanningService: Correct state machine names

This improves readability of the state machine dump command.
BUG: 27886011

Change-Id: I8676f3c3c638d8f32dde063adb5e79b0cf978ea5
om/android/server/wifi/scanner/WifiScanningServiceImpl.java
5ccc0a429dfea8ef452f8f63454b013983eb87fe 07-Apr-2016 Mitchell Wills <mwills@google.com> Run WifiScanner on WifiStateMachine thread

Fixes: 27695292
Change-Id: I34f05fc532c48c7c3eaa735bc6ec95e7da2794aa
om/android/server/wifi/FrameworkFacade.java
om/android/server/wifi/WifiStateMachine.java
493fa573c471f1c5650bc35dda016c744808c363 14-Apr-2016 Randy Pan <zpan@google.com> Merge "Condition on if the phone is connected to an AP" into nyc-dev
00e988440a0b1bf0c443142fa6a1a0369cb95799 14-Apr-2016 TreeHugger Robot <treehugger-gerrit@google.com> Merge "Add log when we don't update the channel list" into nyc-dev
eeb1a3c3cb4c09f925496000392d63b2b28301f7 14-Apr-2016 Randy Pan <zpan@google.com> Condition on if the phone is connected to an AP

In addition to check if the BSSID of the candidate network
recommended by QNS matches the one tracked by WifiStateMachine's
WifiInfo, check if the phone is in one of the supplicant
connecting states. This is to take the fact that WifiInfo stores
a diconnected network's BSSID into count.

Bug: 28163444
Change-Id: I682bedc26e9f2ea34cb006b859384a8e414b047d
om/android/server/wifi/WifiConnectivityManager.java
0fa34e0ff61d7aa41ef69da1ebaf24adf5aaca2f 14-Apr-2016 TreeHugger Robot <treehugger-gerrit@google.com> Merge "WifiScanningService: Remove ClienthandlerMap" into nyc-dev
09abbe29be6e552a2531b0367bd6d29647d33767 30-Mar-2016 Glen Kuhne <kuh@google.com> Created LastResortWatchdog class

Created the WifiLastResortWatchdog class, that will handle restarting
the wifi stack as a last resort when wifi is failing.
Implemented the logic that tracks failure counts for all available
networks, and the maintaining of that list of available networks.

BUG=27856523

Change-Id: I8c944d033955ad7e5cc9484cce8f20cd3755312e
om/android/server/wifi/WifiConnectivityManager.java
om/android/server/wifi/WifiInjector.java
om/android/server/wifi/WifiLastResortWatchdog.java
om/android/server/wifi/WifiQualifiedNetworkSelector.java
om/android/server/wifi/WifiStateMachine.java
f8f5cb07ca2ead74f7f8bb03621fe0157aeba373 14-Apr-2016 Roshan Pius <rpius@google.com> WifiScanningService: Remove ClienthandlerMap

Migrate all scans to use the new RequestList class to maintain the list
of active scans.

BUG: 28190728
Change-Id: Iad84fda9c50c0c1c493a399ce2adb2792ec75a2f
om/android/server/wifi/scanner/WifiScanningServiceImpl.java
46216839c58e6aa6933eae304da750cd46148837 14-Apr-2016 Samuel Tan <samueltan@google.com> Merge changes Ia5efa8a0,I2ec700c3 into nyc-dev

* changes:
WifiConfigStore: remove migrateCerts()
WifiConfigStore: remove migrateOldEapTlsNative()
c38419bd95b0934cb1dfc6f1e1f29eca9929da8c 14-Apr-2016 Rebecca Silberstein <silberst@google.com> Merge "Update hasEverConnected for wifi networks" into nyc-dev
deaf58e6f2c5fb93543f3ead79c1f160cc2248a8 14-Apr-2016 Roshan Pius <rpius@google.com> Merge "BackgroundScanScheduler: Optimize buckets" into nyc-dev
ffd253e626fd6154dbd77320d08e2a42cc178aa6 14-Apr-2016 Mitchell Wills <mwills@google.com> Add log when we don't update the channel list

Change-Id: I4f95934636d63faced42954831f8be6389db1f8f
om/android/server/wifi/scanner/HalChannelHelper.java
d347f07ab5908f1736a912e1305cdc653fb606fe 14-Apr-2016 Jan Nordqvist <jannq@google.com> Merge "Fixed incomplete OSEN config code." into nyc-dev
c48fd721a9a3273f0faa927d93caad4c9832af7d 11-Apr-2016 Adam Lesinski <adamlesinski@google.com> Implement new async response for controller activity info

Bug:26842468
Change-Id: Ic031dd6b5781c11aaec97f9c2b943dbd3f9317bf
om/android/server/wifi/WifiServiceImpl.java
a8e54474f05cbd5ccb42c4b1dc7cf7411dde559a 14-Apr-2016 TreeHugger Robot <treehugger-gerrit@google.com> Merge "SupplicantWifiScanner: Increase single scan timeout" into nyc-dev
a85fc1b07490d3ff194a98fe7389f6697ace5801 13-Apr-2016 Roshan Pius <rpius@google.com> SupplicantWifiScanner: Increase single scan timeout

Increase single scan timeout to 15 seconds to account for delays in scan
processing when there is a parallel gscan running.

BUG: 28005679
Change-Id: I5efd2c547f1ffb12ea026f2e289cb7e83e6f3021
om/android/server/wifi/scanner/SupplicantWifiScannerImpl.java
2b7a4daa21df85f6a8ca2c4992ba53634071cac6 14-Apr-2016 Mukesh Agrawal <quiche@google.com> Merge changes I8da6c1a4,I619b9c81,I22a753d7,If818bc37 into nyc-dev

* changes:
wifi service: nuke verbose logs on no-verbose
wifi service: add support for driver dump HAL API
WifiLogger: make firmware dump conditional on verbose
wifi service: add utility to check printability
216eb45e7fb44a1ba8edc156d08b532a17219f66 08-Apr-2016 Roshan Pius <rpius@google.com> BackgroundScanScheduler: Optimize buckets

Optimize the buckets to ensure that the same channel is not scheduled
across multiple buckets. The settings are split if some of the channels
in the setting is already being scanned in lower time period bucket.
Also go thru each bucket and check if any of them don't fit into the
bucket specifications, if yes create split buckets with the same
time period. The split buckets will cumulatively contain all the channels
needed to be scanned in the original buckets.

BUG:28022609
Change-Id: Ie24bc3ec891965adad0ce6e855015be6ff5f0740
TEST: Compiles & unit-test passes
om/android/server/wifi/scanner/BackgroundScanScheduler.java
om/android/server/wifi/scanner/ChannelHelper.java
om/android/server/wifi/scanner/KnownBandsChannelHelper.java
om/android/server/wifi/scanner/NoBandChannelHelper.java
b571743f406cbe1c13cc0fdfcd9fc58093728f4c 12-Apr-2016 Samuel Tan <samueltan@google.com> WifiConfigStore: remove migrateCerts()

The abovementioned method was introduced 3 years ago,
and should not be needed anymore.

BUG: 28124406
Change-Id: Ia5efa8a068c1a68b875bcbe1b21424d7ab201e4a
TEST: 'runtest frameworks-wifi' passes.
om/android/server/wifi/WifiConfigStore.java
41a43eccc1f100f15bc37755d9824494d1ea773a 12-Apr-2016 Samuel Tan <samueltan@google.com> WifiConfigStore: remove migrateOldEapTlsNative()

The abovementioned method was introduced 4 years ago,
and should not be needed anymore.

BUG: 28124210
Change-Id: I2ec700c3a96cc2c37831394f6bc7b4075270f3fb
TEST: 'runtest frameworks-wifi' passes.
om/android/server/wifi/WifiConfigStore.java
42396f489e485671100353beb6102d315ff3a542 13-Apr-2016 TreeHugger Robot <treehugger-gerrit@google.com> Merge "WifiConfigStore: set requirePMF when ieee80211w==2" into nyc-dev
af3c71f28531c8d52ebc8e913f34b674f91b9fd8 13-Apr-2016 Rebecca Silberstein <silberst@google.com> WifiConfigStore: set requirePMF when ieee80211w==2

When reading back WifiConfigurations, the ieee80211w value is
incorrectly defaulting to 3, this is causing the requirePMF value to be
incorrectly set to true. Change this behavior to only set requirePMF
when the value read is 2.

BUG: 28159304
Change-Id: I0896b1feb10415c04b335ac1b91844ae0fe87f2d
om/android/server/wifi/WifiConfigStore.java
30925b4fe118d954c671523b71ecd8820e70d962 13-Apr-2016 Samuel Tan <samueltan@google.com> Merge "Remove WifiConfigManager.mDeletedSSIDs" into nyc-dev
a43ada87b8111dc2c5c440d3b9b529ffba8384e7 13-Apr-2016 TreeHugger Robot <treehugger-gerrit@google.com> Merge "WifiConfigManager: Remove dead code" into nyc-dev
feaedc1a064de293bc18ab1e522a7953b7fa2719 31-Mar-2016 Jan Nordqvist <jannq@google.com> Fixed incomplete OSEN config code.

Changed the makeString method to comply with new Hotspot 2.0 release 2
group cipher name with underscores in the value.
The legacy code bluntly assumed that all wpa_supplicant values used
dashes only and no underscores.

BUG=27929688

Change-Id: I74f7549b7771402121570f725e9d2f95be8d19c4
om/android/server/wifi/WifiConfigStore.java
2e17da3b28b31b24aabd18367347c2a15f148cd1 13-Apr-2016 TreeHugger Robot <treehugger-gerrit@google.com> Merge "WifiConfigManager: remove OLD_PRIVATE_KEY_NAME" into nyc-dev
329b3a9a9bc32d14649e91c15876ea7f95f148d1 13-Apr-2016 Roshan Pius <rpius@google.com> WifiConfigManager: Remove dead code

BUG: 28164778
Change-Id: I1e09b8039dbf7d220fd699b5be3b29330d02a305
om/android/server/wifi/WifiConfigManager.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiConnectivityManager.java
6e1539d01b5c05f790d803b98128f2a03b7e155f 13-Apr-2016 Glen Kuhne <kuh@google.com> Merge "WifiMetrics Extension" into nyc-dev
15c889b305b3086a93229258d4f3a083acadc8b5 13-Apr-2016 Paul Jensen <pauljensen@google.com> Merge "If Internet probe is redirected, pass redirect destination to NetworkAgent." into nyc-dev
ce003b812aead64dcb36647180991150021b24c1 12-Apr-2016 Glen Kuhne <kuh@google.com> WifiMetrics Extension

Extended the wifi metrics proto with the changes submitted
logs/proto/wireless/android/play/playlog/connectivity/wifi.proto in
CL/119321981.
Added interfaces to WifiMetrics for incrementing the Connectivity
Watchdog counts.

The new Connectivity Watchdog metrics can be viewed in the 'WifiMetrics'
section output by:
adb shell dumpsys wifi

BUG=27479439

Change-Id: I38f0a0ad7c7e0b4d3f0054c818d188ac1b171121
om/android/server/wifi/WifiMetrics.java
2ecb62764d26c3f0d95a9dc5c0a616af1b2bf8de 12-Apr-2016 mukesh agrawal <quiche@google.com> wifi service: nuke verbose logs on no-verbose

When a user disables verbose Wi-Fi logging, they
probably don't want to retain firmware dumps or
driver dumps. Similarly for packet fate logs (at
least in raw form).

Nuke such data on entering non-verbose mode,
accordingly.

While there: update reportConnectionFailure(),
to use the recently added isVerboseLoggingEnabled()
method.

BUG=27554392
BUG=27528124
TEST=unit tests

Change-Id: I8da6c1a4ab11e5f43b9e660fb64efed62e7cb9e3
om/android/server/wifi/WifiLogger.java
d0cb2fae195ebb9f658095667f3c7b7b8d69a204 07-Apr-2016 mukesh agrawal <quiche@google.com> wifi service: add support for driver dump HAL API

Implement the framework side of the driver dump HAL API:
- When a bugreport is generated, ask the HAL to provide
a driver memory dump.
- When dumping a bugreport, include the driver memory
dump (if available).

Along the way: add a stub implementation of the driver
dump HAL API, in case a particular vendor HAL does not
implement the API.

While there: declare the (existing) callback for
firmware memory dumps as static. There's no need for
on_firmware_memory_dump() to be visible outside of
com_android_server_wifi_WifiNative.cpp. (Modules
that need access to on_firmware_memory_dump() will be
provided with a pointer; they don't need to reference
the function by name.)

BUG=27554392
TEST=unit tests
TEST=bullhead: dumpsys + verify that driver dump is present
TEST=angler: dumpsys + verify we properly handle unimplemented API

Change-Id: I619b9c819a41a795c1119a8c2fa22447f0c44b56
om/android/server/wifi/WifiLogger.java
om/android/server/wifi/WifiNative.java
913bb9047c0eab77653b47a0ed69dbe0bd3d479f 13-Apr-2016 Samuel Tan <samueltan@google.com> Remove WifiConfigManager.mDeletedSSIDs

mDeletedSSIDs are introduced in WifiConfigStore in
go/ag/585797, where it was used in
WifiConfigStore.associateWithConfiguration(). This method
was later removed in go/pag/215262, but mDeletedSSIDs
was not. Later, mDeletedSSIDs was moved to WifiConfigManager
in a WifiConfigStore refactor.

Since this variable is no longer used, delete it and all
references to it.

BUG: 28088479
Change-Id: I056ae6f6654269100fc96f25b299a9fece85be93
TEST: 'runtest frameworks-wifi' passes.
om/android/server/wifi/WifiConfigManager.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiNetworkHistory.java
f8c50b1e8239d843dd01e6dcf956629dad0771c1 12-Apr-2016 mukesh agrawal <quiche@google.com> WifiLogger: make firmware dump conditional on verbose

We want to make firmware memory dump conditional on
verbose logging for it's own sake. But this also
sets the stage for the driver dump feature to be
conditional on verbose. (Driver dump is still in
the works.)

BUG=21661292
BUG=27554392
TEST=compile (more tests to come)

Change-Id: I22a753d785d1023a94f5c2e753714bc918b41fdf
om/android/server/wifi/WifiLogger.java
e31290e1c2eebf70c5ab22091a9520c7a001161e 12-Apr-2016 mukesh agrawal <quiche@google.com> wifi service: add utility to check printability

When logging data, it's useful to know whether or not
the data is plain ASCII. (If so, we can print the
data raw. Otherwise, we need to base64 encode the data.)

To meet this need: add a utility method to check if a byte
buffer contains (only) printable ASCII.

BUG=27554392
TEST=unit tests

Change-Id: If818bc378c6f146e7517f6ae4bb36b4b5bb8db48
om/android/server/wifi/util/StringUtil.java
604285d676078e9d0d5c7944770bdba36144363e 13-Apr-2016 Wei Wang <weiwa@google.com> Merge "Send failure reason from RttService." into nyc-dev
ff90a6e25ba0e4388f14d87a0fbd8231d5f8a721 13-Apr-2016 TreeHugger Robot <treehugger-gerrit@google.com> Merge "WifiConfigManager: set default value of mShowNetworks back to false" into nyc-dev
93332917bf29ddbe853a495816e486150f49da40 29-Mar-2016 Rebecca Silberstein <silberst@google.com> Update hasEverConnected for wifi networks

Set hasEverConnected to true for a network that completes a connection.

Set hasEverConnected to false when a network config changes.

Add tests to confirm hasEverConnected was added on a successful
connection and cleared when connection or credential related
configuration changes are made.

Also removed some unused imports to fix checkstyle issues in
WifiStateMachine and WifiConfigStore.

BUG: 27856374

Change-Id: Ica633166892b4673683f21ff98e3ded1607dedec
om/android/server/wifi/WifiConfigManager.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiStateMachine.java
49db6a0f9104fea99013fa6cfe6fcf2bdc7aa661 12-Apr-2016 Rebecca Silberstein <silberst@google.com> Merge "WifiConfigStore: read requirePMF config variable" into nyc-dev
bca895e7651c2929ff883568940892987c1a03d3 12-Apr-2016 Samuel Tan <samueltan@google.com> WifiConfigManager: set default value of mShowNetworks back to false

Since b/17516271 is marked as fixed, act on the TODO and set
the default value of this field back to false.

While there, re-order some fields in accordance to the style in
WifiConfigManager.java.

BUG: 28088219
Change-Id: Ib6a0985babdbebb35916278fe64bacdeb863ab8e
TEST: 'runtest frameworks-wifi' passes.
om/android/server/wifi/WifiConfigManager.java
fdbf9d334419ff5aff35bf56f7cf46d01998861b 12-Apr-2016 Samuel Tan <samueltan@google.com> WifiConfigManager: remove obselete field description

Remove description for a field that was previously deleted
(mNetworkIds).

BUG: 28088467
Change-Id: I2f6ac921b9b73e91c4eed5b0481bc4a910e92f02
TEST: N/A
om/android/server/wifi/WifiConfigManager.java
87a0e55e7d75e305e0fb50a0748d2002cd44c984 12-Apr-2016 Wei Wang <weiwa@google.com> Send failure reason from RttService.

Also use CMD_OP_ENALBE_RESPONDER_FAILED when wifi is not available.

Bug: 28143916

Change-Id: I8eb6139e3464989739783fd96637d549756aa2cf
om/android/server/wifi/RttService.java
eaea4b75c2ecfd192d5dcefcf67bb851bf031f5e 12-Apr-2016 Rebecca Silberstein <silberst@google.com> WifiConfigStore: read requirePMF config variable

When saving a wifi configuration, we set the requirePMF variable from
the config, but it is never read back.

Add the getNetworkVariable call for pmfVarName and add a call to verify
the attempt to read it back in the WifiConfigManagerTest.

Additionally fixed a checkstyle issue for unused imports.

BUG: 28088226
Change-Id: Ib7b2ba796e31ae57273c34b6845c218419125b72
om/android/server/wifi/WifiConfigStore.java
0fe550277a9db5a06d8d8265f50a87b4645094f8 12-Apr-2016 Samuel Tan <samueltan@google.com> WifiConfigManager: remove OLD_PRIVATE_KEY_NAME

Remove WifiConfigManager.OLD_PRIVATE_KEY_NAME, since it
is a duplicate of WifiConfigStore.OLD_PRIVATE_KEY_NAME, and
WifiConfigManager's copy of this variable is not used.

While there, re-order some fields in WifiConfigManager to
match the style in this file.

BUG: 28088377
Change-Id: I448c4368fd7e1d0a86606fec8187298c005734d5
TEST: 'runtest frameworks-wifi' passes.
om/android/server/wifi/WifiConfigManager.java
50f2c0b31f4b8e8f523efa2d820a1517a31c6fb2 12-Apr-2016 Randy Pan <zpan@google.com> Merge "Remove startDelayedScan() from WifiStateMachine" into nyc-dev
7429ca2593265cc1b97fb0d616ef3c07364b2931 12-Apr-2016 Samuel Tan <samueltan@google.com> Merge "Rename WifiConfigManager.getConfiguredNetworks()" into nyc-dev
90aa70f8474e3f28587f152ee2abf2a3708f47b6 12-Apr-2016 Samuel Tan <samueltan@google.com> Merge "WifiConfigManager: remove mEnableSsidWhitelist and mEnableHalBasedPno" into nyc-dev
286d5bc822626b2307fa89cfd6738da3ee91e21a 12-Apr-2016 Randy Pan <zpan@google.com> Merge "Clean up scan from WifiStateMachine" into nyc-dev
10ae325bdea24f342d7db71365c27e9c1e4082b4 12-Apr-2016 Randy Pan <zpan@google.com> Merge changes Iba4639b8,Ie07b4730 into nyc-dev

* changes:
Remove check for roaming by supplicant from QNS
Keep QNS local log enabled
74c56848625bdc3c358475e87d7b15a44bd5a985 12-Apr-2016 Randy Pan <zpan@google.com> Remove startDelayedScan() from WifiStateMachine

This logic is now replaced by WifiConnectivityManager.
While there, clean up some dead code.

Bug: 28070598
Change-Id: I122fee6630f74e30b7b9a36ff325f8d6baa1a8f0
om/android/server/wifi/WifiStateMachine.java
c24bdfeb8386f892eca5b6513179fa08260c49e7 11-Apr-2016 Randy Pan <zpan@google.com> Clean up scan from WifiStateMachine

Removed a bunch of dead code.

Bug: 28070598
Change-Id: Iee11bbc79a5512e3116c6c38ec071c27a0609bb5
om/android/server/wifi/WifiStateMachine.java
19628835ddf7b7557ff61dfdf00e916abc2c13d2 11-Apr-2016 Randy Pan <zpan@google.com> Remove check for roaming by supplicant from QNS

With network switching and roaming by wpa_supplicant disabled,
QNS does not have to check for that any more.

Bug: 27932378
Change-Id: Iba4639b88e9369148ce3d398203d69c9e9ef8d20
om/android/server/wifi/WifiQualifiedNetworkSelector.java
030b802722b896b2139e0771a2ceee48bd19699d 11-Apr-2016 Randy Pan <zpan@google.com> Keep QNS local log enabled

While there, changed the local log method name and tags for
log dumping to comply with the Wifi stack naming convention.

Bug: 27765462
Change-Id: Ie07b4730d58a2768c6f6a2d37fc0b20c6852a3ba
om/android/server/wifi/WifiQualifiedNetworkSelector.java
a8367288377cbaed6371256ca837b7aa22280706 11-Apr-2016 Mitchell Wills <mwills@google.com> Move WifiScanner related code to scanner package

Change-Id: I73d01fe4d0de99a4e9758353cacf1d7a790cf040
om/android/server/wifi/HalWifiScannerImpl.java
om/android/server/wifi/SupplicantWifiScannerImpl.java
om/android/server/wifi/WifiScannerImpl.java
om/android/server/wifi/WifiScanningScheduler.java
om/android/server/wifi/WifiScanningService.java
om/android/server/wifi/WifiScanningServiceImpl.java
om/android/server/wifi/scanner/HalWifiScannerImpl.java
om/android/server/wifi/scanner/SupplicantWifiScannerImpl.java
om/android/server/wifi/scanner/WifiScannerImpl.java
om/android/server/wifi/scanner/WifiScanningService.java
om/android/server/wifi/scanner/WifiScanningServiceImpl.java
666a2e92468803a739394e6b53d9fe021a7b4afd 11-Apr-2016 Samuel Tan <samueltan@google.com> WifiConfigManager: remove mEnableSsidWhitelist and mEnableHalBasedPno

Remove both these members, since they are only set, but not used.

BUG: 28088382
Change-Id: I610b67b7cc84e66a2378c7422908ce80b3dae69a
TEST: 'runtest frameworks-wifi' passes.
om/android/server/wifi/WifiConfigManager.java
60969bf2c849011fb585cf6dc914dbd779dfb8cf 11-Apr-2016 Samuel Tan <samueltan@google.com> Rename WifiConfigManager.getConfiguredNetworks()

Rename WifiConfigManager.getConfiguredNetworks() and related methods
to WifiConfigManager.getSavedNetworks, since it better reflects
what this method does (i.e. get all configured networks except
ephemeral networks). While there, add comments for some previously
undocumented helper methods.

BUG: 28088229
Change-Id: I30e144b46277605f5847371d9e65b70306013cf5
TEST: 'runtest frameworks-wifi' passes.
om/android/server/wifi/WifiConfigManager.java
om/android/server/wifi/WifiQualifiedNetworkSelector.java
om/android/server/wifi/WifiStateMachine.java
492900e5895d4480292d5f7518d109e6b3b9fb47 11-Apr-2016 Mukesh Agrawal <quiche@google.com> Merge "WifiStateMachine: reduce number of LogRecords" into nyc-dev
4cd91e207897c250c7fc0e6ed3176698dce29093 11-Apr-2016 Samuel Tan <samueltan@google.com> Merge "Rename enableAutoJoinWhenAssociated()" into nyc-dev
c769e9f8aa687a80d10c9442ce44d091f63f06b6 11-Apr-2016 Samuel Tan <samueltan@google.com> Merge "WifiConfigManager: remove unused fields" into nyc-dev
cf2c37cff48a96fe221121dfe6a0360a54ed9ebb 06-Apr-2016 mukesh agrawal <quiche@google.com> WifiStateMachine: reduce number of LogRecords

Allowing 3000 LogRecords uses too much memory (we've
seen >1 MB in some cases). Lower this limit to 100
records, as it was before.

To facilitate debugging issues that happen overnight,
allow the user to opt-in to a larger log record buffer.
To do so, the user should "enable wi-fi verbose logging"
under developer options.

BUG=27504679
TEST=unit tests

Change-Id: Iee983e3c815bef1a9e05f7085147bc73c79753f6
om/android/server/wifi/WifiStateMachine.java
a88d1b207c401c4510e635156442973a8e30ac95 11-Apr-2016 Samuel Tan <samueltan@google.com> Merge changes I468f7425,I649dca1b,Ic7f97157,I06a8be88 into nyc-dev

* changes:
WifiConfigManager: remove WifiStateMachine field
Move wnmFrameReceived() from WifiConfigManager to WifiStateMachine
Move mActiveScanDetail from WifiStateMachine to WifiConfigManager
Remove getCurrentUserId() and getCurrentUserProfiles() from ...WifiStateMachine
207985b8f6d960784948aa7dcc1af754ea57b449 09-Apr-2016 Mitchell Wills <mwills@google.com> Merge "Move single scan blaming from WifiStateMachine to WifiScanningService" into nyc-dev
f1c2e8cc3728f65aee24905ad5c44e84891f0693 08-Apr-2016 Glen Kuhne <kuh@google.com> Merge "Added buffering of filtered ScanDetails to QNS" into nyc-dev
43eba5ba17a9af5d9a050a4ba5e12e93c92f722d 08-Apr-2016 Samuel Tan <samueltan@google.com> Rename enableAutoJoinWhenAssociated()

Rename instances of the abovementioned method to
setEnableAutoJoinWhenAssociated(), to better reflect
that this method is a setter.

BUG: 28088867
Change-Id: I2ea170c8b3f1042356014f9ac57035d78302db76
TEST: 'runtest frameworks-wifi' passes.
om/android/server/wifi/WifiConfigManager.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
2e738247c930892598473f3cbe593670ab23a02c 08-Apr-2016 Glen Kuhne <kuh@google.com> Merge "Track WifiState on single scan start" into nyc-dev
1a572a27cffc6ee853f9b6a40d83eef18963e2b0 08-Apr-2016 Randy Pan <zpan@google.com> Merge "Build ESS into the GScan result's Capabilities" into nyc-dev
0efd09fea566f4445807b6aff60b18e127e72d38 31-Mar-2016 Glen Kuhne <kuh@google.com> Added buffering of filtered ScanDetails to QNS

Added logic to buffer the scanDetails considered by
QualifiedNetworkSelection as potential candidates (has a saved config,
and signal strength over threshold). And a getter to access these.

BUG=27932650

Change-Id: I4e04194c944f7d8a18719d7dfc7b66cbf42eb5af
om/android/server/wifi/WifiQualifiedNetworkSelector.java
48444cb4214a48a3a0bf4bbb93945c2aa68c9980 01-Apr-2016 Mitchell Wills <mwills@google.com> Move single scan blaming from WifiStateMachine to WifiScanningService

Bug: 27247460
Change-Id: Id855329450659b8b762fcb0bf9dba5a0b551604e
om/android/server/wifi/WifiConnectivityManager.java
om/android/server/wifi/WifiScanningServiceImpl.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
78bfa19f8eb5f8e05f72b831b6629d07ec6909e1 08-Apr-2016 Samuel Tan <samueltan@google.com> WifiConfigManager: remove unused fields

Remove unused fields from WifiConfigManager.

BUG: 28084272
Change-Id: If6e316693d42ddd6914ac9b1c4d7cdf044c66b5a
TEST: 'runtest frameworks-wifi' passes.
om/android/server/wifi/WifiConfigManager.java
ac69b83c9cafb9a839b578c3b5b71eb3439244ad 08-Apr-2016 Samuel Tan <samueltan@google.com> WifiConfigManager: remove WifiStateMachine field

Remove the WifiStateMachine field from WifiConfigManager, since the
latter no longer calls methods of the former. Also, change calls
to the WifiConfigManager constructors to accomodate this change.

BUG: 27405059
Change-Id: I468f74259d45d9a1a61e00b987533eaa66846024
TEST: 'runtest frameworks-wifi' succeeds.
om/android/server/wifi/FrameworkFacade.java
om/android/server/wifi/WifiConfigManager.java
om/android/server/wifi/WifiStateMachine.java
94e8f71b884e11abb8c46e69467af96f17d6423e 08-Apr-2016 Mukesh Agrawal <quiche@google.com> Merge changes from topic 'ring-buffer-size' into nyc-dev

* changes:
wifi service: use large ringbuffers in verbose mode
ByteArrayRingBuffer: add ability to resize buffer
930174d9abe89ddb275e03620f40b937b1f53dd5 06-Apr-2016 Samuel Tan <samueltan@google.com> Move wnmFrameReceived() from WifiConfigManager to WifiStateMachine

Move this method into WifiStateMachine, since it does not use
any state specific to WifiConfigManager, and removes the dependency
of WifiConfigManager on WifiStateMachine.

BUG: 27405059
Change-Id: I649dca1ba748f2ffdfa3ef6d0de014186a753d91
TEST: 'runtest frameworks-wifi' succeeds.
om/android/server/wifi/WifiConfigManager.java
om/android/server/wifi/WifiStateMachine.java
308a06a125932081304655cda8374ffcf0772b3c 05-Apr-2016 Samuel Tan <samueltan@google.com> Move mActiveScanDetail from WifiStateMachine to WifiConfigManager

Since |mActiveScanDetail| is only used in WifiConfigManager, move
it from WifiStateMachine to WifiConfigManager, and add a
sycnhronized setter for this variable that WifiStateMachine
can call to update it.

BUG: 27405059
Change-Id: Ic7f97157433bf0db9d5ec3d5ac93073e163c5355
TEST: 'runtest frameworks-wifi' succeeds.
om/android/server/wifi/WifiConfigManager.java
om/android/server/wifi/WifiStateMachine.java
06636d2de935ad5d2e8fb6483c406fe922c75ff2 05-Apr-2016 Samuel Tan <samueltan@google.com> Remove getCurrentUserId() and getCurrentUserProfiles() from
...WifiStateMachine

Move getCurrentUserId() from WifiStateMachine to WifiConfigManager,
and remove WifiStateMachine.getCurrentUserProfiles(), so that
WifiConfigManager no longer makes calls to WifiStateMachine to
perform these two tasks.

Achieve this by moving the bookkeeping for the current user ID
from WifiStateMachine to WifiConfigManager.

BUG: 27405059
Change-Id: I06a8be88f24fd81cbfe785c4304883ddc44658f8
TEST: 'runtest frameworks-wifi' succeeds.
om/android/server/wifi/WifiConfigManager.java
om/android/server/wifi/WifiStateMachine.java
73a52d3336a40903965b946f6d3624a223ad5aac 07-Apr-2016 Samuel Tan <samueltan@google.com> WifiConfigManager: rename member and constant fields

Rename fields in WifiConfigManager to properly reflect that
they are members (m* prefix), and constants (all caps with
underscores). To accomodate this change, also modify uses
of these fields outside WifiConfigManager (e.g. in WifiStateMachine).

Also:
- Remove default values given to WifiConfigManager member fields
that are initialized in its constructor, since the initalization renders
the default values useless.
- Remove member fields and constants that are unused.
- Replace the "*Milli" suffix on fields with "Ms".
- Re-ordered fields in a logical manner (i.e. static, public, then
private).
- Fixed checkstyle issues.

BUG: 27300099
Change-Id: Ifaef76bc04960f12f09267a581b9a02da7c5ab5c
TEST: 'runtest frameworks-wifi' passes.
TEST: Checkstyle returns only missing javadoc errors.
om/android/server/wifi/WifiConfigManager.java
om/android/server/wifi/WifiConnectivityManager.java
om/android/server/wifi/WifiQualifiedNetworkSelector.java
om/android/server/wifi/WifiScoreReport.java
om/android/server/wifi/WifiStateMachine.java
d604bbd63d620244ef43408de10f65ead01d5026 06-Apr-2016 mukesh agrawal <quiche@google.com> wifi service: use large ringbuffers in verbose mode

When the user has chosen to enable wi-fi verbose
logging, we'd like to use larger ring buffers.

Make it so.

BUG=27578082
TEST=unit tests

Change-Id: I1e2447df2beda455cea37072e91fa0aac338bb3f
om/android/server/wifi/FrameworkFacade.java
om/android/server/wifi/WifiLogger.java
om/android/server/wifi/WifiStateMachine.java
ca0bac5826ab430d1b765b201a609f7bc38401ee 06-Apr-2016 mukesh agrawal <quiche@google.com> ByteArrayRingBuffer: add ability to resize buffer

When verbose mode is enabled, we'd like to use
larger ring buffers. To support this, add the
ability to resize a ByteArrayRingBuffer.

BUG=27578082
TEST=unit tests

Change-Id: I976a2ec05ade3f5c2c0fe5dc50cbb391534ab241
om/android/server/wifi/util/ByteArrayRingBuffer.java
70ce5a4cbaf5aaccd4e542e7bb87196fb4464a6e 06-Apr-2016 Glen Kuhne <kuh@google.com> Track WifiState on single scan start

Adding a call to WifiMetrics, populating the WifiSystemStateEntries when
oneshot scans are started.

BUG=27793184

Change-Id: I694c17e7b2cfde54204ec206072a1ae5f58b088b
om/android/server/wifi/WifiMetrics.java
om/android/server/wifi/WifiScanningServiceImpl.java
9b5773d2805e8c6141ca75de272921a84941546b 07-Apr-2016 Randy Pan <zpan@google.com> Build ESS into the GScan result's Capabilities

Obtain this piece of information from the beacon and build it
into the Capabilities string.

Bug: 27810218
Change-Id: Iffa57f6e1c0997e5705da779a3693de9e3108e37
om/android/server/wifi/util/InformationElementUtil.java
f37079e3d8f4aca3242a971cbaef732fe1b75bde 07-Apr-2016 Roshan Pius <rpius@google.com> WifiScanner: Remove pnosetting stopPno API (2/2)

BUG: 27532350
Change-Id: I291732cc693b6042ae995194094c4fec774dfbf1
om/android/server/wifi/WifiConnectivityManager.java
1d540dbd9ddeafc27dda51e26b0303df4a66914d 07-Apr-2016 Roshan Pius <rpius@google.com> Merge "WifiNative: Remove PnoMonitor" into nyc-dev
8ba794562167643688ee38352f98345403fa22c8 07-Apr-2016 Roshan Pius <rpius@google.com> WifiNative: Remove PnoMonitor

Remove PNOMonitor from WifiNative since it has been refactored out into
SupplicantScanner now.

BUG: 27677054
Change-Id: I99850a1e59bfe0ee21c674467ae7480df85e76ff
om/android/server/wifi/SupplicantWifiScannerImpl.java
om/android/server/wifi/WifiNative.java
466158a6669d51541ce6c5c4e04a71dad36cdb4e 01-Apr-2016 Randy Pan <zpan@google.com> Enable/disable WifiConnectivityManager at runtime

Add support to turn on and off WifiConnectivityManager at
runtime.

Bug: 27968625
Change-Id: I3583d1564a78a6db7227d2fa5a91e859cef83776
om/android/server/wifi/WifiConnectivityManager.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
2a9dc4d883484e006054433426be91c6e675754c 07-Apr-2016 Randy Pan <zpan@google.com> Merge "Wifi Connectivity Manager" into nyc-dev
84d962ec8f487f824214744498bba505a6db0c59 11-Feb-2016 Randy Pan <zpan@google.com> Wifi Connectivity Manager

Created a submodule which manages all the WiFi connectivity
related operations. It starts a scan when screen turns on/off,
WiFI gets connected/disconnected or on demand. The scan results
are passed to QNS for it to recommend a network to connect to.

Clean up the relevant logic from WifiStateMachine.

Bug: 26666366
Bug: 27227489
Bug: 27677391
Bug: 27364917
Change-Id: I65405506ff55940d0b23f1407e476bff6fce47fa
om/android/server/wifi/WifiConfigManager.java
om/android/server/wifi/WifiConnectivityManager.java
om/android/server/wifi/WifiQualifiedNetworkSelector.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
d1bd53369b88d91968c19dd0cc288d1d2db8b3c6 06-Apr-2016 Mukesh Agrawal <quiche@google.com> Merge changes from topic 'packet-fate' into nyc-dev

* changes:
WifiStateMachine: report failures to WifiLogger
WifiLogger: add support for packet fate
WifiNative: flesh out packet fate implementation
WifiNative C++: add support for packet fate
WifiNative: add infrastructure for packet fates
jni_helper: add createObjectWithArgs
066cc9f845897357886081fbd972ab36e74ce345 01-Apr-2016 mukesh agrawal <quiche@google.com> WifiStateMachine: report failures to WifiLogger

When a connection ends in failure, report the failure
to WifiLogger. WifiLogger will then fetch packet
fates (if appropriate).

BUG=27528124
TEST=compile

Change-Id: I926902e0fbe9480920ad6d326bc61faf4f7ea33a
om/android/server/wifi/WifiStateMachine.java
ed510cfa64decd813f76faf9bb1b0a70b74b9898 01-Apr-2016 mukesh agrawal <quiche@google.com> WifiLogger: add support for packet fate

1) Provide a method for other parts of wifi service
to report connection failures to WifiLogger.
2) Start packet fate monitoring if/when we start
logging in verbose mode.
3) Fetch packet fates on failure, as appropriate.
4) Include packet fate information in dumps.

While there:
a) Change visibility of the single-arg dump() method
in BaseWifiLogger. (Only derived classes should be
calling that overload.)
b) Disambiguate the call from WifiLogger.dump() to
BaseWifiLogger.dump(), by adding |super| to the
expression.
c) Remove unused WifiNative.WIFI_ERROR_UNINITIALIZED

BUG=27528124
TEST=unit tests

Change-Id: Ica85ce39e79983194c3930ef54c29ac07454faed
om/android/server/wifi/BaseWifiLogger.java
om/android/server/wifi/WifiLogger.java
om/android/server/wifi/WifiNative.java
0fcb06473cbe2824e401a80c0520bb1c14ed8f41 01-Apr-2016 mukesh agrawal <quiche@google.com> WifiNative: flesh out packet fate implementation

1) Add methods to invoke the packet fate HAL functions.
2) Add methods to dump a packet fate to a string.

BUG=27528124
TEST=unit tests

Change-Id: I3897687099ab19f5cf24a0821cbc6600ea12e52a
om/android/server/wifi/WifiNative.java
09b1d0786d05436d524d7556c269e665a0962ee6 01-Apr-2016 mukesh agrawal <quiche@google.com> WifiNative: add infrastructure for packet fates

1) Define the Java classes that the C++ code will
copy packet fate information into.
2) Define the constants that will be used to represent
fates. (This is needed to write readable tests for
item 1.)
3) Declare the native methods on the Java side.
(This is required for registerNatives to continue
to work, after we add the new methods on the C++
side.)

BUG=27528124
TEST=unit tests

Change-Id: If0930f645f95e60c8cb471b10fcb740273159e05
om/android/server/wifi/WifiLoggerHal.java
om/android/server/wifi/WifiNative.java
1b36c74e3e037576522479ebb42b261020ccf76f 06-Apr-2016 Samuel Tan <samueltan@google.com> Merge "WifiConfigStore: write configKey for legacy networks to WPA supplicant" into nyc-dev
22ae26d04f0dd23f300a303bb316ee1e3608c23a 06-Apr-2016 Jeremy Joslin <jjoslin@google.com> Merge "Print the meteredHint in the dump." into nyc-dev
68d94988777f2484f97b087a4ffb5b4f460a0903 06-Apr-2016 Paul Jensen <pauljensen@google.com> If Internet probe is redirected, pass redirect destination to NetworkAgent.

Transport may use the redirect to make additional determination about network
state.

Bug: 25203607
Change-Id: I18e8dc074c7a3edcf589d3df2dda7fb0f8c7e5ee
om/android/server/wifi/WifiStateMachine.java
8d629bd8bbbb2a0c055dbb2f93c556192771e921 05-Apr-2016 Jeremy Joslin <jjoslin@google.com> Print the meteredHint in the dump.

BUG: 27702356
Change-Id: I473236869a665945afb3625786c162fd09a0e8f9
om/android/server/wifi/WifiNetworkScoreCache.java
3c81a8ca9afd89f19114e042b91fef594e68f412 05-Apr-2016 Junda Liu <junda@google.com> Merge "Use new ICC authentication API for wifi statemachine." into nyc-dev
b2040e483314ba96a9cbda4d1f24209006fce4d8 04-Apr-2016 Erik Kline <ek@google.com> Move from on464XlatChange() to setNeighborDiscoveryOffload()

Bug: 26238390
Change-Id: I3a343dae8143713574a95d8064f810ff87d2915a
om/android/server/wifi/WifiStateMachine.java
78b8d2feb70093e8717e924ed41176d6d8417e60 05-Apr-2016 Paul Jensen <pauljensen@google.com> Merge "Plumb WiFi multicast filter through to ApfFilter" into nyc-dev
9b5ffdfd63416af3245a89058fde1c3ebbfb5645 01-Apr-2016 Samuel Tan <samueltan@google.com> WifiConfigStore: write configKey for legacy networks to WPA supplicant

Whenever WifiConfigStore encounters a legacy network that does not have a
configKey (i.e. its configuration was written by a pre-N version of
Android), force an update of this network by immediately writing the
computed configKey into wpa_supplicant.conf (via supplicant's SET_NETWORK
control interface method).

This will ensure that all network configurations stored in
wpa_supplicant.conf will have configKeys available for parsing.

BUG: 27962844
Change-Id: Icdcac80d1ce06a50f99556e3c451543abeb59f75
TEST: 'runtest frameworks/wifi' succeeds.
TEST: Created network config with WiFi UI, deleted its id_str in
wpa_supplicant.conf manually via adb, restarted device using
'adb reboot', read wpa_supplicant.conf again and verified
that the id_str field was restored for that network.
om/android/server/wifi/WifiConfigStore.java
720aba804a5c7fa5e4cc92af60b129e3e0013666 01-Apr-2016 Mitchell Wills <mwills@google.com> Defuse all bundles destined from WifiScanningService

Also check for null bundles before attempting to access them

Change-Id: I2606954b0828c3bbd6d192607f112a96fae2ccf6
om/android/server/wifi/WifiScanningServiceImpl.java
3e954f2804d376c9ca08e23c00b266c668f65e53 25-Mar-2016 Paul Jensen <pauljensen@google.com> Plumb WiFi multicast filter through to ApfFilter

Use APF to implement WifiManager.MulticastLock, if APF isn't available
fallback to the present behavior of using DRIVER RXFILTER. Since we
don't know whether APF is supported until we're connected, postpone
enabling/disabling the multicast filter until then; this should be
fine as there isn't much need to filter packets if there aren't any
packets going by since we're not connected.

Bug: 26238573
Change-Id: I96515cd99f8899aea70f99029c73816b1b172c80
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
aa10749aa9063a03c6e66af336c85863949fdbb1 01-Apr-2016 Ritesh Reddy <riteshr@google.com> Merge "Calling BackupManager.dataChanged for WifiNetwork Changes" into nyc-dev
53be76ffbda87f1e76f843332b95ad31f191341f 01-Apr-2016 Mitchell Wills <mwills@google.com> Merge "Associate work source with single scan settings" into nyc-dev
44f8fc30974fa61a5a64be81874f6002ca0368f3 31-Mar-2016 Mitchell Wills <mwills@google.com> Associate work source with single scan settings

Change-Id: I9358223b11bd80f889a6c9df9e7a1828c9cc7489
om/android/server/wifi/WifiScanningServiceImpl.java
0e4f6ab00e1f2bd64f17302dae279c77c4cf7d8e 31-Mar-2016 Roshan Pius <rpius@google.com> WifiScanningServiceImpl: Reset HW PNO for all failure

Move the HW PNO reset functionality to the HwPnoScanState exit.
Also, move the internal client deletion there for both HwPnoScanState &
SwPnoScanState.

BUG: 27886011

Change-Id: I4e1d40ddb28862af8881bb0a9707d2ff986cbda5
om/android/server/wifi/WifiScanningServiceImpl.java
2fc3d4dcabb6ddcd72dc335d908aa192c38c5e5f 26-Mar-2016 Samuel Tan <samueltan@google.com> WifiConfigStore: use configKey instead of SSID as unique ID in
...readNetworkVariablesFromSupplicantFile

Use the configKey stored in the id_str field of wpa_supplicant.conf,
rather than SSID, to uniquely identify networks in
readNetworkVariablesFromSupplicantFile.

Also:
- Remove WifiConfigStore.readNetworkVariableFromSupplicantFile(),
and move the logic in that method into
WifiConfigManager.readNetworkVariableFromSupplicantFile().
- Add a helper method, WifiConfigStore.readNetworkVariablesFromReader(),
so that we can inject a test supplicant config file during testing.
- Add WifiConfigStoreTest.java, which currently only contains unit tests
for WifiConfigStore.readNetworkVariablesFromSupplicantFile().

BUG: 26733972
Change-Id: Ice2dcdae0c2e95b4df6459f75f3a98df30290256
TEST: 'runtest frameworks-wifi' succeeds.
om/android/server/wifi/WifiConfigManager.java
om/android/server/wifi/WifiConfigStore.java
6874d75b9fa79e90e0ea75ba962a7759e702da64 31-Mar-2016 Roshan Pius <rpius@google.com> Merge changes I18879cb1,Ic84bc39f,I8704da8f into nyc-dev

* changes:
WifiScanningServiceImpl: Create PNO state machine
WifiScanningService: Create internal clientInfo
WifiScanningService: Cleanup ClientInfo
5ee2476aa8320de89c47697c66e67b8c08864973 30-Mar-2016 Junda Liu <junda@google.com> Use new ICC authentication API for wifi statemachine.

The new API is cleaner and requires caller to specify authType explicitly.

Bug: b/27360179
Change-Id: I6cb732c60be8940423753415b7d3d8932db73ecc
om/android/server/wifi/WifiStateMachine.java
e309b6ef69954273509957efb7d4de7556630600 31-Mar-2016 Nathan Harold <nharold@google.com> Persist Wifi Verbose Logging Across Reboots

-Adds Global Setting 'WIFI_VERBOSE_LOGGING_ENABLED'
-Synchronizes this property at WifiStateMachine creation and
persists the developer menu toggle across reboots

Bug: 27878903
Change-Id: I7626cc5524a786767d16d9a50b0555ded48f844f
om/android/server/wifi/FrameworkFacade.java
om/android/server/wifi/WifiStateMachine.java
c343aec32e1d3fe320eb97c527b0bcfb2d334e45 29-Mar-2016 Roshan Pius <rpius@google.com> WifiScanningServiceImpl: Create PNO state machine

Adding a PNO state machine to fetch full scan results for all types of
PNO when reporting events back to the client.

BUG: 27886011
TEST: Compiles & unit-test passes
TEST: Made changes in WifiConnectivityManager to use the scan results to
auto-connect.
Change-Id: I18879cb1bf82226e329c6076e8443e0986ddbe27
om/android/server/wifi/WifiScanningServiceImpl.java
a91494208927643d011b4fa62db2064d9e8228c1 24-Mar-2016 Roshan Pius <rpius@google.com> WifiScanningService: Create internal clientInfo

Create a new class for keeping track of internal clients to the
WifiScanningService. This object is used to communicate between the
state machines using a valid clientInfo.
The external clients override the onReportEvent to send the events back
to the WifiScanner interface.
The internal clients override the onReportEvent to send the events to
the state machine which requested the event.

Internal Clients are going to be used by WifiChangeStateMachine and the
upcoming WifiPnoScanStateMachine to make background scan requests

BUG: 27727025
Change-Id: Ic84bc39f59890151c51ac14356e1a3183819e09d
TEST: Compiles & unit-test passes
om/android/server/wifi/WifiScanningServiceImpl.java
19a7b07a44c1ce4cf2500d277ef31e3344868142 24-Mar-2016 Roshan Pius <rpius@google.com> WifiScanningService: Cleanup ClientInfo

Move Hotlist & WifiChange client handling away from ClientInfo
to ClientHandlerMap in their own respective state machines.
Had to refactor the WifiChange to plumb the related
message handling out of background state machine.

BUG: 27727025
BUG: 27738627
Change-Id: I8704da8fedf84dda7aface4061785d15e0086473
om/android/server/wifi/WifiScanningServiceImpl.java
479d894ecc1087afc29529c87abbad8bf69ed172 31-Mar-2016 Jan Nordqvist <jannq@google.com> Merge "Fixed broken Hotspot 2.0 r1 provisioning." into nyc-dev
84c201000b753297280bc12d4bd0b8221367c098 31-Mar-2016 Roshan Pius <rpius@google.com> Merge "Fix null pointer exception in reportActivityInfo" into nyc-dev
0e776ddb6de62e76c54ff32148d9d170172be308 30-Mar-2016 Mitchell Wills <mwills@google.com> Merge "Add handling of incoming WorkSource for scans" into nyc-dev
c71fb2904e5588444ff2cbab6273661921675339 30-Mar-2016 Mitchell Wills <mwills@google.com> Merge "Use buckets scanned field when delivering scan results" into nyc-dev
9c8892ebd2ec5340785f6b787805fdc6088069d7 30-Mar-2016 Roshan Pius <rpius@google.com> Fix null pointer exception in reportActivityInfo

Fix null pointer exception when tx_timer_per_level is null.

BUG: 27924555
Change-Id: I83240a63e1163ab7888f3a0777408f3cb271bd86
om/android/server/wifi/WifiServiceImpl.java
0ea5062316013cd4173faf16c2a0f3ecd1b9ed43 30-Mar-2016 Mitchell Wills <mwills@google.com> Add handling of incoming WorkSource for scans

Bug: 27903217
Change-Id: Ic3693e083c3ac7369465bfd6cbd4dadebe03f907
om/android/server/wifi/WifiScanningServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
02a782764421f0cccc6a9044df31f58b6558f980 30-Mar-2016 Samuel Tan <samueltan@google.com> Merge "WifiNative: fix error log message typo in getNetworkExtra()" into nyc-dev
64697f7a5b9c1c39f8c9d9c225b8ca4c798422c2 26-Mar-2016 Samuel Tan <samueltan@google.com> WifiNative: fix error log message typo in getNetworkExtra()

Change "serialize" to "deserialize" in the error log message,
since WifiNative.getNetworkExtra() attempts to do the latter rather
than the former.

BUG: 27919414
Change-Id: Idd4f750ae8af79d89d2e5662d391d10d239f1f09
TEST: N/A
om/android/server/wifi/WifiNative.java
d5d850a6435d044f73f196715967f74ffd6f7ea3 30-Mar-2016 Wei Wang <weiwa@google.com> Merge "Clean up for responder mode when client goes away." into nyc-dev
b39039bb466eb4ab3e71da9daadeaed9d686d40f 28-Mar-2016 Wei Wang <weiwa@google.com> Clean up for responder mode when client goes away.

Bug:27878941
Change-Id: I5febde5ad3edd945b6d4b77e688581099c88bf7e
om/android/server/wifi/RttService.java
c4f23cbd6de85cbffcd91b398e51eff106ef08d4 26-Mar-2016 Mitchell Wills <mwills@google.com> Use buckets scanned field when delivering scan results

Fixes: 27506257
Change-Id: I224b78a89dfde54ef4f3dae37f1bb10d2a12b78e
om/android/server/wifi/WifiScanningServiceImpl.java
om/android/server/wifi/scanner/BackgroundScanScheduler.java
om/android/server/wifi/scanner/ScanScheduleUtil.java
bf4982c6b1e230a3659e30eb47290e49c7034b14 29-Mar-2016 Roshan Pius <rpius@google.com> Merge changes from topic 'wifi_tx_power_levels' into nyc-dev

* changes:
Read new HAL tx_time_per_level structure element
Send wifi tx power levels to BatteryStats
e7737522e50283ae92c5f48b3fdbd8594c6daa00 29-Mar-2016 Rebecca Silberstein <silberst@google.com> Merge "Extend NetworkHistory to incorporate hasEverConnected" into nyc-dev
0530d49a5b25e5133a175e47ba2c7a9ada1c105c 29-Mar-2016 Lorenzo Colitti <lorenzo@google.com> Merge "Make wifi code pass through IpManager dump requests." into nyc-dev
476172f2eef83ff367fae4344eda8129ea9d16f7 23-Mar-2016 Roshan Pius <rpius@google.com> WifiScanningService: Remove |pnoSettings| in stopPno

Remove the |pnoSettings| param for stopPno requests. We added this param
to revert network priorities in supplicant after PNO. But, because we
have disabled all auto-connect in wpa_supplicant having the wrong
priorities is irrelevant now.

Note: Will add a follow up CL to remove it from the WifiScanner
interface.

BUG: 27532350
Change-Id: I8bc4102b7e45699152a2ee0f816d65738b8531fa
TEST: Compiles & unit test passes
om/android/server/wifi/HalWifiScannerImpl.java
om/android/server/wifi/SupplicantWifiScannerImpl.java
om/android/server/wifi/WifiScannerImpl.java
om/android/server/wifi/WifiScanningServiceImpl.java
e7ba2963bedf426a1d8ba09ab535260ef364512b 23-Mar-2016 Roshan Pius <rpius@google.com> SupplicantWifiScannerImpl: Add Pno Debouncer

Add the PNO debouncer class for PNO scan request debouncing. We debounce
all PNO scan/stop requests for 5 seconds. Pno pause bypasses this
debounce logic so that we can immediately schedule the
single/background scan after stopping the PNO scan.

BUG: 27677054
Change-Id: Ibafeb936e30c9c6c1b23a39d9ed08b23a5f72030
TEST: Compiles & unit test passes
om/android/server/wifi/SupplicantWifiScannerImpl.java
36bb65444a73ee94fa20207549e451bcb85adfe5 28-Mar-2016 Roshan Pius <rpius@google.com> Merge "Turn off HAL ePNO" into nyc-dev
6552fb836f7ee130c53f15865bb4f666c7d8a01e 28-Mar-2016 Roshan Pius <rpius@google.com> Turn off HAL ePNO

BUG: 27877781
Change-Id: I72cfc491e25b7a163feaf722428a1ebeece32ce1
om/android/server/wifi/HalWifiScannerImpl.java
11b4c4c3c813237826117270741c63faa0d312aa 26-Mar-2016 Rebecca Silberstein <silberst@google.com> Extend NetworkHistory to incorporate hasEverConnected

Add boolean to NetworkHistory (tracked in
WifiConfiguration.NetworkSelectionStatus) to track if we have ever
connected to the given network with the current configuration.

BUG: 27856504
Change-Id: I5f858afe3128fbc7293b15f8b95892da7cae171e
om/android/server/wifi/WifiNetworkHistory.java
ea6fdf9a58f8ee83fba32c221331f10f9ec941e9 24-Mar-2016 Glen Kuhne <kuh@google.com> Track WifiState in WifiMetrics

Added a WifiState tracking member to WifiMetrics. It is now logged in
memory for each ConnectionEvent, and printed in the human readable
metrics dump.
The intention of this is to support WifiSystemScanEntry counts (will be
implemented in/after the Scanning Metrics CL)
Achieved this by tracking entering and exiting of the ConnectMode &
L2Connected states in WifiStateMachine.

BUG=27793184

Change-Id: Iba1ab974cc4e7b9d1a2d8d8185ee5c90da6da151
om/android/server/wifi/WifiMetrics.java
om/android/server/wifi/WifiStateMachine.java
675de6070a3c1980fcc99bc6863b2689bfeb0271 28-Mar-2016 Lorenzo Colitti <lorenzo@google.com> Make wifi code pass through IpManager dump requests.

"adb shell dumpsys wifi ipmanager <args>" is now passed along
to IpManager.

Bug: 26991160
Change-Id: Ib84b2003719075416c71998477e8189072eb4480
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
ef7053e8dc65c0a9d4f98a6e40f5061a9be3c139 28-Mar-2016 Erik Kline <ek@google.com> Change one instance of StringBuilder to TextUtils.join()

Change-Id: I15e608d2a36464b420af585687db5edaad0719a9
om/android/server/wifi/WifiStateMachine.java
94ec2aa5ee673e03b270ffa9e7f86bf9e0d6d5b4 28-Mar-2016 Paul Stewart <pstew@google.com> Merge "WifiStateMachine: Send NetworkStateChangedBroadcast on IPv4 config" into nyc-dev
8139a142bd2a30a85a093d7012d0ee84df077995 25-Mar-2016 Erik Kline <ek@google.com> Relay the metered hint to network capabilities

Also: mWifiInfo is effectively final. Make it so and remove
useless null checks.

Bug: 26241591
Change-Id: I224e0717a4a00466ae61317e20d09724ab10e684
om/android/server/wifi/WifiStateMachine.java
96d42c4198ca91a5a24af3ec6da41715dc08e4aa 25-Mar-2016 Rebecca Silberstein <silberst@google.com> Merge "Fix checkstyle issues in ScanDetail and ScanDetailCache" into nyc-dev
aa575d82dcc01cb213402923796c870ecdd45b28 25-Mar-2016 Mitchell Wills <mwills@google.com> Merge "Pass buckets scanned from HAL to framework" into nyc-dev
b9cc92f3325f8bb08bf7eb1e1fd25d40cfe43604 25-Mar-2016 Glen Kuhne <kuh@google.com> Merge "Add scanning into WifiMetrics" into nyc-dev
20047f18a7cccdc279d480916308f612c5cbb63e 25-Mar-2016 Paul Jensen <pauljensen@google.com> Merge "Move ApfFilter from ConnectivityService to IpManager" into nyc-dev
9cef0b96fd275dede1571b55feed636621717d3b 25-Mar-2016 Jan Nordqvist <jannq@google.com> Fixed broken Hotspot 2.0 r1 provisioning.

Bug=27698600

Change-Id: If398e2388ed8abac746833ea2ae5bef90c1fa2da
om/android/server/wifi/configparse/ConfigBuilder.java
ff21cf2ed3aa7e71056ec68ce2c14eba22ef4b28 24-Mar-2016 Rebecca Silberstein <silberst@google.com> Fix checkstyle issues in ScanDetail and ScanDetailCache

Remove extra comments and fix unused import.

BUG: 27836797
Change-Id: I1b43dbafb94de2d5dea5b660e3ee9417300261c1
om/android/server/wifi/ScanDetail.java
om/android/server/wifi/ScanDetailCache.java
c2c2648141e6190d85601ee8a6a1d0034e7ff927 11-Mar-2016 Glen Kuhne <kuh@google.com> Add scanning into WifiMetrics

Added calls to WifiMetrics to increment various scanning metrics, in the
Single & Background - ScanStateMachine's.
Added expected metrics value checks to existing unit tests.

BUG=25691077

Change-Id: I7c335d829876f6b31220571bb4330b7b30f4cc0e
om/android/server/wifi/WifiMetrics.java
om/android/server/wifi/WifiScanningService.java
om/android/server/wifi/WifiScanningServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
0e67c341974310405230e2fd761395296f15d5c1 24-Mar-2016 Samuel Tan <samueltan@google.com> Merge "WifiNative: improve documentation for getRawScanResults()" into nyc-dev
cba3f6e3c7466c8cc76d5642c6f90970f42b314f 24-Mar-2016 Jeremy Joslin <jjoslin@google.com> Merge "Allow ephemeral WiFi conns to be marked as metered" into nyc-dev
6b6fc371d3355f4e1eb44f7635d3b7187e3dce06 24-Mar-2016 Glen Kuhne <kuh@google.com> Merge "Add more synchronization to WifiMetrics" into nyc-dev
544f4cf36568caba965bf7b456f88b16c733c517 24-Mar-2016 Randy Pan <zpan@google.com> Merge "Fix ephemeral network Wifi configuration" into nyc-dev
e1dab7a2e3ab5911f812a302b4beed1f6eb5aba7 18-Mar-2016 Paul Jensen <pauljensen@google.com> Move ApfFilter from ConnectivityService to IpManager

There's a few advantages to having ApfFilter in IpManager:
1. If things go wrong, crashing a particular transport is less bad then
crashing ConnectivityService. We also don't want to use
ConnectivityService as a dumping ground for transport-specific logic.
2. This makes implementing WifiManager.MulticastLock a lot simpler and
safer because enabling/disabling it doesn't have to go through the
NetworkAgent, which could risk various races (e.g. installing a filter
into the wrong WiFi network).
3. IpManager is the ultimate source for LinkProperties for a particular
transport and since ApfFilter uses the LinkProperties it's better to
have it closely paired with the IpManager. Likewise, ApfFilter needs
to know the APF capabilities of the transport, so having it in
the transport avoids having to parcel this information through the
NetworkAgent.

Bug: 26238573
Change-Id: I99b85f2b64972f0e7572170ec5d1926081aa3429
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
3ab8ec5cfa986b07e1c948af0f45bd333edef24c 21-Mar-2016 Jeremy Joslin <jjoslin@google.com> Allow ephemeral WiFi conns to be marked as metered

Pass through the metered hint from the score cache to the
WifiStateMachine when making an ephemeral connection. The
NetworkPolicyManagerService already looks for the hint after
every NETWORK_STATE_CHANGED_ACTION and takes the correct action.

BUG: 27120794
Change-Id: I3d4a5030724e8e0fb1084c67d74fb768bd9ad2b5
om/android/server/wifi/WifiConfigManager.java
om/android/server/wifi/WifiNetworkHistory.java
om/android/server/wifi/WifiNetworkScoreCache.java
om/android/server/wifi/WifiQualifiedNetworkSelector.java
om/android/server/wifi/WifiStateMachine.java
8e66cfa1668921d9ef0f385879a7cffa54a3f5a8 24-Mar-2016 Ningyuan Wang <nywang@google.com> Merge "Revert "Remove hardcoded 'wlan0' from native WiFi code"" into nyc-dev
3b51fd1bb8356b284822f4f677ad941524e616eb 24-Mar-2016 Ningyuan Wang <nywang@google.com> Revert "Remove hardcoded 'wlan0' from native WiFi code"

This reverts commit da10b1588be241c59434d5f464463e7f8c7bcc5e.

BUG=27814126

Change-Id: I04be0b5b991fdb8a1d3a8467d622c07a185f3900
om/android/server/wifi/WifiNative.java
ebd663ff7027bbf19c4a5ed2bfb71b91bb925cd6 24-Mar-2016 Glen Kuhne <kuh@google.com> Add more synchronization to WifiMetrics

Added synchronization that was missing from some public methods.

BUG=27792729

Change-Id: I71f94a7005e2789df0eed14176329d2a3158d52f
om/android/server/wifi/WifiMetrics.java
37cc4a769e6a2b81f3b99941187cdfd95fc6f713 23-Mar-2016 Randy Pan <zpan@google.com> Fix ephemeral network Wifi configuration

Build ephemeral network Wifi Configuration's key managment
protocol properly from the scan results.

Bug: 27577494
Change-Id: Iec142a4cad64546f4a95c3ab270affd355469ff9
om/android/server/wifi/WifiConfigManager.java
eb5731beb47704699dd8866b1a1dc59f3764c981 23-Mar-2016 Samuel Tan <samueltan@google.com> WifiNative: improve documentation for getRawScanResults()

Change documentation for getRawScanResults() so that it is more
readable, and clearly indicates which BSS information fields are
being masked.

BUG=None
TEST=N/A

Change-Id: Ic6322759590c0c25021511ab74e44961f7f1ad66
om/android/server/wifi/WifiNative.java
3b479405c66fd65c2ac9d88dcdae936cf8477e3a 23-Mar-2016 Paul Stewart <pstew@google.com> Merge "WifiNotificationController: Take a looper" into nyc-dev
baef64ddbe4660f95a51db4e1527d3ff3e0d9628 23-Mar-2016 Glen Kuhne <kuh@google.com> Merge "Fix Roaming between Dual-Band SSIDs on same router" into nyc-dev
1651f1bcd0e843b1806e3f0f30983345a9fd6faf 23-Mar-2016 Roshan Pius <rpius@google.com> Merge "WifiConfigManager: Write ipconfig.txt for new configs" into nyc-dev
c9e6069eb941d282af213dc20b171877db6b567b 23-Mar-2016 Mitchell Wills <mwills@google.com> Pass buckets scanned from HAL to framework

Bug: 27506257
Change-Id: Ia57327e265317fd0d1ce09d238d9c1e9c55bf2b1
om/android/server/wifi/SupplicantWifiScannerImpl.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiScanningServiceImpl.java
om/android/server/wifi/scanner/BackgroundScanScheduler.java
4e54617758f86acef751bc8588257a58ed985b0f 22-Mar-2016 Mitchell Wills <mwills@google.com> Move scan filtering to a common utility class

This way single scans don't depend on the background scan scheduler

Bug: 27506257
Change-Id: I7130302b364cc86e3a8f1cd0a168e0068c29953b
om/android/server/wifi/WifiScanningServiceImpl.java
om/android/server/wifi/scanner/BackgroundScanScheduler.java
om/android/server/wifi/scanner/ScanScheduleUtil.java
adad2ba52d44119ad20efffb04ec0a70459e7113 23-Mar-2016 Roshan Pius <rpius@google.com> Merge changes Ia15900d4,I4e82007c into nyc-dev

* changes:
WifiScanningServiceImpl: Sw PNO scans
WifiScanningServiceImpl: Refactor background scans
40abf54c81c5624641543d86e1d7ab21ebe30175 08-Mar-2016 Paul Stewart <pstew@google.com> WifiNotificationController: Take a looper

This CL adds a Looper argument to the WifiNotificationController
constructor, so its Handler can be initialized with a specific
looper instead of relying on the default.

Bug: 27545448
Test: runtest frameworks-wifi \
-c 'com.android.server.wifi.WifiNotificationControllerTest' \
-m 'verifyNotificationDisplayed'

Change-Id: I33fb221ddfead0b24d98bd23c92c0226ff3c6a1d
om/android/server/wifi/WifiNotificationController.java
om/android/server/wifi/WifiServiceImpl.java
24fd5197092ef8a143edcb11dac3383483aa0650 22-Mar-2016 Mitchell Wills <mwills@google.com> Merge "Make sure to cleanup when timing out from a single scan" into nyc-dev
05762a3d4a5e88727cbf2818c67d84d0f9ca9a82 22-Mar-2016 Ningyuan Wang <nywang@google.com> Merge "Remove hardcoded 'p2p0' from WifiNative" into nyc-dev
1b14e7606da9c3a1a0636279875018ece7f4aa74 22-Mar-2016 Ningyuan Wang <nywang@google.com> Merge "Remove hardcoded 'wlan0' from native WiFi code" into nyc-dev
c6ccad1ec19b0a53266962237774422b156ea726 18-Mar-2016 Ningyuan Wang <nywang@google.com> Remove hardcoded 'p2p0' from WifiNative

WifiNative should get the p2p interface name from
SystemProperties instead hard-coded name.

BUG=27383938
TEST= cts & unit tests & manual test
Change-Id: I25a4280ee14252d01e4582ced90c1b456e4babb2
om/android/server/wifi/WifiNative.java
6c5018cef1eb7acbcfa7fc6c9b7c018bab7ba7ba 18-Mar-2016 Roshan Pius <rpius@google.com> WifiScanningServiceImpl: Sw PNO scans

Moving the implementation of SW PNO scans from SupplicantScanner to
WifiScanningServiceImpl.

WifiScanningServiceImpl checks is HW PNO is supported by the
scanner implementation:
a) if false it manually schedules a background scan and
converts all background scan results to PNO results.
b) if true, it lets the scanner implementation handle the PNO scans.

BUG: 27742823
Change-Id: Ia15900d402ba005d11251931b39bf30b8d21a02c
TEST: Compiles & unit-test passes
om/android/server/wifi/HalWifiScannerImpl.java
om/android/server/wifi/SupplicantWifiScannerImpl.java
om/android/server/wifi/WifiScannerImpl.java
om/android/server/wifi/WifiScanningServiceImpl.java
80640ff4d13e252f0a5637ec16ca2d626070e751 18-Mar-2016 Roshan Pius <rpius@google.com> WifiScanningServiceImpl: Refactor background scans

Refactor the background scan handling to be similar to single scan state
machine and remove the nested layers of logic it uses now.

While there,
Remove the |reportPeriodChanged| functionality which doesn't seem to be
used anymore.

BUG: 27738627
TEST: Compiles & unit-test passes
Change-Id: I4e82007cb316b48e260ab6d80ceedd0c6120fd5b
om/android/server/wifi/WifiScanningServiceImpl.java
cc018db319baff34c9d36928d04c2c420257498f 22-Mar-2016 Roshan Pius <rpius@google.com> WifiConfigManager: Write ipconfig.txt for new configs

We need to write the ipconfig.txt file for all new config additions.
The |writeIpAndProxyConfigurationsOnChange| method is modified to force
update the ipconfig.txt for new networks.
While there,
1. Move the log indicating that we're updating ipconfig.txt to the place
where we actually update the file.
2. Remove the redundant config change update broadcast from
|writeIpAndProxyConfigurationsOnChange|. This is anyway being done in
saveNetwork & addOrUpdateNetwork.

BUG: 27697450
Change-Id: Ie2b8d51ed218ac8809a726ca169f2e61ef185593
TEST: Verified that the ipconfig.txt is written for new configs.
om/android/server/wifi/WifiConfigManager.java
da10b1588be241c59434d5f464463e7f8c7bcc5e 18-Mar-2016 Ningyuan Wang <nywang@google.com> Remove hardcoded 'wlan0' from native WiFi code

This CL changes the setInterfaceUpNative() API, adding an
interfaceName parameter.
This also moves the code for 'bringing up wlan0' out of
startHalNative().
The reason is that startHalNative() should not be in charge of
bringing up a specific interface.
For the similar reason this moves the code for 'bringing down
wlan0' out of waitForHalEventsNative().

BUG=22457263
TEST= cts & unit tests & manual test

Change-Id: Ia9cd7a6b4d75e5582561ffa53084932a3c177f05
om/android/server/wifi/WifiNative.java
1cba41b5c3a5d96f3f10596afef6159caaff97e4 22-Mar-2016 Roshan Pius <rpius@google.com> Merge "WifiConfigManager: Update network metadata" into nyc-dev
0f179857cae968ee9a5bdae47a4ec914dea08f1d 21-Mar-2016 Glen Kuhne <kuh@google.com> Fix Roaming between Dual-Band SSIDs on same router

Fixed CMD_AUTO_ROAM so that it actually uses the network ID & associated
config of the target, rather than always assuming roams are to the same
networkID & config as the previous connection.

BUG=27358522

Change-Id: I3ec6fae9cb45cd62a7afc8d48ac5a0b29d93f87c
om/android/server/wifi/WifiStateMachine.java
08c939fa7f1fcd666a3076b6921864b4bf70308f 21-Mar-2016 Roshan Pius <rpius@google.com> WifiConfigManager: Update network metadata

The configkey saved for new networks may change after we save the
network. This is because some of the default values are not specified
when saving the network to supplicant, but these values are filled when
reading the config back from supplicant.
The configKey which depends on the |authAlgorithms| field needs to be
updated after all of these default values are read.

BUG: 27756946
TEST: Compiles & unit-test passes
TEST: Manually executed the failing test in the above bug and verified
that it passes now.

Change-Id: Ia568a2804f69697a8342e666d2ec3b269dbc9922
om/android/server/wifi/WifiConfigManager.java
om/android/server/wifi/WifiConfigStore.java
3ad0bffcb0b535dcba434ec83f0adab80ce524f0 22-Mar-2016 Lorenzo Colitti <lorenzo@google.com> Merge "Don't call NetworkUtils.resetConnections." into nyc-dev
443e7052b1b229d062424ec890beb24322223236 21-Mar-2016 Lorenzo Colitti <lorenzo@google.com> Don't call NetworkUtils.resetConnections.

Netd already closes all TCP connections when IP addresses are
removed, which happens two lines before this call.

Bug: 26976388
Change-Id: Ie1b8833142db5ab319b769283ff013ad3942cb94
om/android/server/wifi/p2p/WifiP2pServiceImpl.java
9d0c558cab7c80a572a32ae70d501df15367fd5f 21-Mar-2016 Mitchell Wills <mwills@google.com> Make sure to cleanup when timing out from a single scan

Also fix general failure cases

Bug: 26095183
Change-Id: I88433ff77c0adb4073350ae7a4746b5ee4da5033
om/android/server/wifi/SupplicantWifiScannerImpl.java
om/android/server/wifi/WifiScanningServiceImpl.java
0ca00b5ea4c63011e97d127ced843dbbffc0ec71 21-Mar-2016 Paul Stewart <pstew@google.com> WifiStateMachine: Send NetworkStateChangedBroadcast on IPv4 config

Since handleIPv4Success modifies mWifiInfo and
sendNetworkStateChangeBroadcast reports mWifiInfo, it follows that
a new broadcast should be sent when CMD_IPV4_PROVISIONING_SUCCESS
is handled.

Bug: 27659510

Change-Id: Ib579ffc4809ce9a4b07bd45cdeaafe87167ecaae
om/android/server/wifi/WifiStateMachine.java
5ed43368643dab64c83bfb15e14ab59d63645c6f 21-Mar-2016 Mitchell Wills <mwills@google.com> Report capabilities for background scans for supplicant impl

Bug: 25744874

Change-Id: I68645178f5f63e534c479d0712b40be0dcde5a1e
om/android/server/wifi/SupplicantWifiScannerImpl.java
1b662dbe559e74179ddcb86a02baa74a0a85b3ce 18-Mar-2016 Ningyuan Wang <nywang@google.com> Merge "Use boolean instead of int parameter for toggleInterface()" into nyc-dev
b96a2696678dedf52bdaf97f41c7d8b76dfa561e 18-Mar-2016 Glen Kuhne <kuh@google.com> Merge "Remove SupplicantStateTracker dependency on WSM" into nyc-dev
bb777ad459f2bb638cddf9268cd1818763a4b39a 18-Mar-2016 Paul Stewart <pstew@google.com> Merge "Reduce the link de-bounce time to 4 from earlier 7 seconds" into nyc-dev
c69afb4ac905dd77e1c707c27d0a0c15deb92d1a 18-Mar-2016 Mitchell Wills <mwills@google.com> Merge "Fix WifiController handling of emergency call mode" into nyc-dev
64e816ff5483030636e1815f69a6cbaf8cef289e 17-Mar-2016 Ningyuan Wang <nywang@google.com> Use boolean instead of int parameter for toggleInterface()

WifiNative::toggleInterface() is using an int parameter for setting
interface up/down. It should be boolean instead.
This CL also renames toggleInterface() to setInterfaceUp().

BUG=27704936
TEST=compile, manually tested on bullhead

Change-Id: I88a98d3e4e53c95921d519db685886a3535dab9e
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
e0f989563233faa6873a80f803d087f4d5f2af8c 18-Mar-2016 Ningyuan Wang <nywang@google.com> Merge "Fixed 'Remove ill-defined WifiNative::getInterfaces()'" into nyc-dev
b1b1211b3477e306a8626e7e6cf2d2aae7983396 18-Mar-2016 Mitchell Wills <mwills@google.com> Fix WifiController handling of emergency call mode

Fixes: 27724263
Change-Id: If6f6456cbe2419999cd3d26549a7904482b0af27
om/android/server/wifi/WifiController.java
2c9840a1063fd74eae131260fda2841566fc6d62 18-Mar-2016 Roshan Pius <rpius@google.com> SupplicantWifiScanner: Connected Pno bug fixes

Missed a |isHwPnoScanRequired| check in couple of places.

Found during manual testing on Shamu with WifiConnectivityManager and
setting the HAL ePNO flag to false in HalWifiScanner.

While there,
Log |isConnected| flag in PNO scan requests

BUG: 27525899
Change-Id: I0830db7e629e7463c0e5cd3e1a12c7e6df8e6927
TEST: Compiles & unit-test passes
TEST: Manual testing on shamu
om/android/server/wifi/SupplicantWifiScannerImpl.java
om/android/server/wifi/WifiScanningServiceImpl.java
54c9cf8d299b99f8b999bc2cf4adcda1eba81469 18-Mar-2016 Glen Kuhne <kuh@google.com> Remove SupplicantStateTracker dependency on WSM

Removed the SST's dependency on WifiStateMachine, since it doesn't use
it for anything.

BUG=27725788

Change-Id: I209056f8ecc9fe73d184718b86a0b8442e3950ea
om/android/server/wifi/FrameworkFacade.java
om/android/server/wifi/SupplicantStateTracker.java
om/android/server/wifi/WifiStateMachine.java
dcd877d6c143db557884993ea437e2a432cb0ba3 17-Mar-2016 Roshan Pius <rpius@google.com> SupplicantScannerImpl: Support connected PNO scan

wpa_supplicant does not support PNO scans when it is in connected state.
So, we need to revert to using background scans for devices which do not
support ePNO.
So, connected PNO becomes a SW PNO scan regardless of whether the device
supports HW PNO scan or not.

BUG: 27525899
Change-Id: I84fb8f5028403dae00302940e9d71ca1c0603de3
TEST: Compiles & unit-test passes
om/android/server/wifi/HalWifiScannerImpl.java
om/android/server/wifi/SupplicantWifiScannerImpl.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiScannerImpl.java
om/android/server/wifi/WifiScanningServiceImpl.java
17ada7f5241dfbc44eecc6db43105709f2dbf04f 17-Mar-2016 Roshan Pius <rpius@google.com> WifiScanningServiceImpl: Log scan requests and callbacks

Add local logs for all scan requests and results callbacks
sent to clients. This help us keep track of start/end of
scan requests.

BUG: 27719172

Change-Id: Ie0c5573f4c1f3d44ad7d1f1e17add5b8a7063532
om/android/server/wifi/WifiScanningServiceImpl.java
918b4bdc2ae16438c5213320daeff1d551f4aed8 16-Mar-2016 Ningyuan Wang <nywang@google.com> Fixed 'Remove ill-defined WifiNative::getInterfaces()'

WifiNative::getInterfaces() is ill-defined because it does not only
get the number of interfaces but also changes sWlan0Index and sP2p0Index.
This CL removes this function and replaces it with queryInterfaceIndex().
This also removes sP2p0Index because it is never used.
This fixes pervious CL:887328 by making sure interface was not removed
before toggling.

BUG=27369790
BUG=27711081
TEST=compile, and manually tested with bullhead

Change-Id: Ib24ec70edf82ef9b3177caa39978ade337ff0e4f
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
71466f8b3cccbc46abad4f5b2d710fb22ce886cb 18-Mar-2016 Mitchell Wills <mwills@google.com> Merge "Merge MultiClientScheduler and WifiScanningScheduler" into nyc-dev
a24cf11dc36674056efef38be297eea40cc5761f 17-Mar-2016 Rebecca Silberstein <silberst@google.com> Merge "Revert "Remove ill-defined WifiNative::getInterfaces()"" into nyc-dev
6d8029355c62eea70a230d49493d35c4462938b4 17-Mar-2016 Rebecca Silberstein <silberst@google.com> Revert "Remove ill-defined WifiNative::getInterfaces()"

This reverts commit 34fdbd63c2d3c402cd83b5e7911c88d4180832b2.

Change-Id: Idf5e4f1cde14e16805953f2fc78b7beefdbce76c
BUG: 27711081
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
95984d1af44a00183a4b0e0ed61417583096ff90 17-Mar-2016 Mitchell Wills <mwills@google.com> Merge MultiClientScheduler and WifiScanningScheduler

And move them to the com.android.server.wifi.scanner package

Change-Id: Iceac6823f118017f577e316d8eacc77c3445b2a7
om/android/server/wifi/MultiClientScheduler.java
om/android/server/wifi/WifiScanningScheduler.java
om/android/server/wifi/WifiScanningServiceImpl.java
om/android/server/wifi/scanner/BackgroundScanScheduler.java
om/android/server/wifi/scanner/ScanScheduleUtil.java
e43135bfd49a1a8d1821dffaea0d44ff36eb8b23 17-Mar-2016 Mitchell Wills <mwills@google.com> Fix crash when wifi monitor dispatches a message with no handler
am: 18456db

* commit '18456db02b67d04d9e601aca68538b64c7a374f8':
Fix crash when wifi monitor dispatches a message with no handler
05af64cf72e191310760172a557e3c3340b78075 17-Mar-2016 Joe Onorato <joeo@google.com> Merge "Turn off excess logging" into nyc-dev
cc97542f6bcd322d8f352b339cd3337be42c55a7 17-Mar-2016 Randy Pan <zpan@google.com> Merge "Wifi: Update WifiController state if Wifi turn On fails" into nyc-dev
dc69106e28e9a6755b1454467f65761f7cbb59c9 17-Mar-2016 Glen Kuhne <kuh@google.com> Merge "Various WifiMetrics fixes" into nyc-dev
96cdfc0acafef88832515ecc52c01638c1493211 11-Mar-2016 Glen Kuhne <kuh@google.com> Various WifiMetrics fixes

-WifiMetrics now determines if repeated 'startConnectionEvent' are for
the same attempt, and adds the failure code
FAILURE_REDUNDANT_CONNECTION_ATTEMPT to designate this.
-Added end condition for roaming timeouts
-Modifed the naming of all failures to be less cryptic
-level_2_failure_code will now be used to log all failure reasons
(making ConnectivityLevelFailure a redundant subset)
-Started using ScanResult frequency instead of WifiConfiguration for
'ChannelInfo'
-Added AuthType checking on 'startConnectionEvent' (Also doing it when
we receive scanResults after associating with the BSSID)
-Refactored all of the config stuff out of startConnectionEvent() into
updateFromWifiConfiguration

BUG=25691077

Change-Id: Id1de2d5dea88611f81e58fed71e6b4e0ee88159a
om/android/server/wifi/WifiMetrics.java
om/android/server/wifi/WifiStateMachine.java
83903ec3df7c51307fd662d7f28544c2051dc471 15-Mar-2016 Sunil Dutt <usdutt@codeaurora.org> Reduce the link de-bounce time to 4 from earlier 7 seconds

The Link de-bounce time of 7 seconds affects the station's
handover time to a better AP,thus tearing down the VoWiFi call
(due to RTP timeout). Reduce this time to 4 seconds.

BUG=27527764
Change-Id: Icc68496c4364fb34139fb6e90a87377c56634383
om/android/server/wifi/WifiStateMachine.java
917ecd60fb7e65ca97604ccad9f4427f28bb3cd6 17-Mar-2016 Ningyuan Wang <nywang@google.com> Merge "Remove ill-defined WifiNative::getInterfaces()" into nyc-dev
34fdbd63c2d3c402cd83b5e7911c88d4180832b2 16-Mar-2016 Ningyuan Wang <nywang@google.com> Remove ill-defined WifiNative::getInterfaces()

WifiNative::getInterfaces() is ill-defined because it does not only
get the number of interfaces but also changes sWlan0Index and sP2p0Index.
This CL removes this function and replaces it with queryInterfaceIndex().
This also removes sP2p0Index because it is never used.

Bug: 27369790
TEST=compile, and manually tested with bullhead

Change-Id: Ia67954de88957c24b16b9c962231e785a465f44c
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
2d211b1809081bce900a5cbb890aca7c93d252c3 17-Mar-2016 Roshan Pius <rpius@google.com> Merge changes I05684ce1,Icb1037ed,I1acf704a into nyc-dev

* changes:
SupplicantWifiScannerImpl: Sw Pno scans
HalWifiScanner: Create SupplicantScanner delegate
SupplicantWifiScannerImpl: Report Pno events
18456db02b67d04d9e601aca68538b64c7a374f8 17-Mar-2016 Mitchell Wills <mwills@google.com> Fix crash when wifi monitor dispatches a message with no handler

Bug: 27705420
Change-Id: I68708215ccd0a0aa1b6f331122d3bcd54ce7669e
om/android/server/wifi/WifiMonitor.java
4668a26b24f37d6f10f3d94c3674efde0efacb72 17-Mar-2016 Ningyuan Wang <nywang@google.com> Merge "Wifi country code refactoring" into nyc-dev
a1514cb347fccf11566e5172ed71030c695d2abd 16-Mar-2016 Roshan Pius <rpius@google.com> Send wifi tx power levels to BatteryStats

This CL just plumbs in the values received from HAL to BatteryStats.

The actual power estimation due to these power levels will need to wait
for the new config.xml additions.

BUG: 27227497
Change-Id: Ic4ee5a286c765658b10a573e84296a8cf35d4d5b
om/android/server/wifi/WifiServiceImpl.java
62bc101940ae1f5e60c4d8861a149b900dbf5e5c 16-Mar-2016 Roshan Pius <rpius@google.com> SupplicantWifiScannerImpl: Sw Pno scans

If the hardware does not support PNO scans via wpa_supplicant,
we need to perform a periodic background scan.
Add a new flag called swPnoScan to take care of this and use the flag
hwPnoScan for HW based PNO scans. All SW pno scans will be accompanied
by a background scan request.

BUG: 27525899
Change-Id: I05684ce1ec9081ee2c5935c4d5dae2c0175bb592
TEST: Compiles & unit-test passes
cherry-picked from:
https://partner-android-review.googlesource.com/#/c/540348/10
om/android/server/wifi/SupplicantWifiScannerImpl.java
2332e9ea1b691fa0ea3a340feec159f2040aa6ca 14-Mar-2016 Roshan Pius <rpius@google.com> HalWifiScanner: Create SupplicantScanner delegate

We need to use supplicant scans for all single shot scans and
for PNO scans (on some devices like shamu) even when HAL based gscan is
supported. So, create a supplicant scanner delegate in HalScannerImpl to
use for single scans & Pno scans (if device does not support ePno).

This helps us get rid of all supplicant scan code currently present in
HalWifiScannerImpl.

While there,
Moved all the methods in both Hal & Supplicant ScannerImpl to be in the
same order.

BUG: 27600810
Change-Id: Icb1037ed3599db2a9770802dd78edfb885bde452
TEST: Compiles & unit-test passes
cherry-picked from:
https://partner-android-review.googlesource.com/#/c/542729/
om/android/server/wifi/HalWifiScannerImpl.java
om/android/server/wifi/SupplicantWifiScannerImpl.java
om/android/server/wifi/WifiScannerImpl.java
da26eea1bdb583ce02f1bc9107997d9370f02f1d 16-Mar-2016 Ningyuan Wang <nywang@google.com> Merge "Ignore empty SSID when 'linkDeboucing' is on" into nyc-dev
063cfc7e3eef78fcbda24a66f0c473828b39c854 10-Mar-2016 Roshan Pius <rpius@google.com> SupplicantWifiScannerImpl: Report Pno events

1. Plumb the scan results event from wpa_supplicant to onPnoNetworkFound()
callback for supplicant based PNO scans.
2. Pull in the PNO scan pause/resume logic to WifiScanner. PNO scans take
the lowest priority and will be scheduled when all other ongoing scans
are completed.

BUG: 27167559
Change-Id: I1acf704af99a00ffde654ed684792afede3cf326
cherry-picked from:
https://partner-android-review.googlesource.com/#/c/539848
om/android/server/wifi/SupplicantWifiScannerImpl.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiScanningServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
d7a1994f19f3bbec7df063488214a347fbcb5b92 16-Dec-2015 Sunil Dutt <usdutt@codeaurora.org> Wifi: Update WifiController state if Wifi turn On fails

If Wifi turn On fails due to failure in reloading firmware then
WifiStateMachine stays in InitialState, but WifiController is left
stuck in StaEnabledState, which in turn fails to turn on WLAN again.

Set Wifi state as failed to generate intent WIFI_STATE_CHANGED_ACTION so
that WifiController transitions to ApStaDisabledState.

Change-Id: I007d85179a0566e2f1b452ae8b564c4e8258987d
om/android/server/wifi/WifiController.java
om/android/server/wifi/WifiStateMachine.java
d02611ce4158fda6c2d14ee13ad7f9553f416d21 02-Mar-2016 Ningyuan Wang <nywang@google.com> Wifi country code refactoring

This CL pulls coutry code logic into one class.
This also refactors all the existing country code logic.
We do not set country code for P2p interface now because
this is redundant. wpa_supplicant will route all the request
to the real interface.
Some initial unittests are added.

Bug: 27477896
TEST: compile, runtest frameworks-wifi,
manually tested with an angler phone
Change-Id: I870c3ad615a1f9bfb3fb40b149b9ca71dc850cdd
om/android/server/wifi/WifiCountryCode.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/p2p/WifiP2pServiceImpl.java
5818c1320387ec7a14eb8b7e2710667800319fae 16-Mar-2016 Ningyuan Wang <nywang@google.com> Ignore empty SSID when 'linkDeboucing' is on

We pretend we are still connected when we are disconnected with
'linkDeboucing' on. In this case we should ignore the empty
SSID wpa_supplicant send to us.

Bug: 27403109
TEST: compiles & unittests & cts tests
Change-Id: I6bda8404734766936d2d1db41329ed2c2a17184a
om/android/server/wifi/WifiStateMachine.java
12a73dbc70d547ea87048209fd84d9dace01be17 15-Mar-2016 Etan Cohen <etancohen@google.com> [NAN] Refactor session lifecycle to clarify API & eliminate race conditions [DO NOT MERGE]

Bug: 27257965
Change-Id: I405de3d18187770d97171d636abddfe4e1be4510
om/android/server/wifi/nan/WifiNanClientState.java
om/android/server/wifi/nan/WifiNanServiceImpl.java
om/android/server/wifi/nan/WifiNanSessionState.java
om/android/server/wifi/nan/WifiNanStateManager.java
7462584f8a30f6dba5dc979b3dfbe3821b739d9c 15-Mar-2016 Wei Wang <weiwa@google.com> Merge "Fix native crash caused by null rtt params." into nyc-dev
e6ee3780bad3664ce5d2c61f9a4e76a5daae1a7d 15-Mar-2016 Paul Stewart <pstew@google.com> Merge "WifiStateMachine: Defer CMD_RESET_SIM_NETWORKS by default" into nyc-dev
d8cb19d3c7835afc76149ddeb91a74cf49e8f1ef 15-Mar-2016 Paul Stewart <pstew@google.com> Merge "Don't crash if no supported rates are given" into nyc-dev
e367514651d7f888dda870fb472eea6bcfd9ec5d 14-Mar-2016 Paul Stewart <pstew@google.com> Don't crash if no supported rates are given

The com.android.server.wifi.hotspot2.NetworkDetail class
crashed with an ArrayIndexOutOfBoundsException if a an empty
supported rates IE was encountered. This CL fixes this by
checking the array size in the validity check of the IE.

Bug: 27619848
Change-Id: I9569d063d7c64d3cc3f80ced9cf9d1425f97abbd
om/android/server/wifi/util/InformationElementUtil.java
c9ac67224dcf7a41692256c338188206f4f29f5c 11-Mar-2016 Etan Cohen <etancohen@google.com> [NAN] Removed NAN event registration - dispatch all callbacks. [DO NOT MERGE]

All events dispatched by default - there's no reason to ignore events.
The specific identity changed events for which there are use-cases to
get or ignore is controlled through a new configuration.

Bug: 27607613
Change-Id: I877d4e31fa0633c073163e3a35d8a700c1eb2f36
om/android/server/wifi/nan/WifiNanClientState.java
om/android/server/wifi/nan/WifiNanServiceImpl.java
om/android/server/wifi/nan/WifiNanStateManager.java
9cf66a4b8313520a6967eb5491459e7bebd3a718 11-Mar-2016 Etan Cohen <etancohen@google.com> [NAN] Consolidate publish/subscribe callback sets into single set [DO NOT MERGE]

Merge onPublishFail & onSubscribeFail into onSessionConfigFail.
Merge onPublishTerminated & onSubscribeTerminated into onSessionTerminated.
A session is either publish or subscribe (never the two) so redundant.

Bug: 27610709
Change-Id: If2e1533e203a7cd1697c2bfcfb0a141f87d9af29
om/android/server/wifi/nan/WifiNanSessionState.java
951fbeb8c17867bcc748d7334d2f4f4c1a7fd97d 11-Mar-2016 Etan Cohen <etancohen@google.com> [NAN] Replace session callback configuration control [DO NOT MERGE]

Controlling session callback invocation:
- Remove event registration
- Add configurations to the subset (actually just termination) which
can be configured through the HAL

Bug: 27607613
Change-Id: I040ab7902156605c3244515c81fa9435f1adaedc
om/android/server/wifi/nan/WifiNanClientState.java
om/android/server/wifi/nan/WifiNanServiceImpl.java
om/android/server/wifi/nan/WifiNanSessionState.java
om/android/server/wifi/nan/WifiNanStateManager.java
202fdf96e1e0191be37a916d97116df35fe3cbfc 22-Feb-2016 Wei Wang <weiwa@google.com> Fix native crash caused by null rtt params.

Bug:27227320

Change-Id: I822045f2dd35aeb824cea0d0c0791480e0d1b80a
om/android/server/wifi/RttService.java
41bf84fbd38c4a9b5ec1f49ea9057705673d0c3e 14-Mar-2016 Mitchell Wills <mwills@google.com> Fix WifiScanner not recovering after Wifi is turned off
am: 1e806a7aac

* commit '1e806a7aac77f6f65ba299329e1fc452e0148b8d':
Fix WifiScanner not recovering after Wifi is turned off
1e806a7aac77f6f65ba299329e1fc452e0148b8d 12-Mar-2016 Mitchell Wills <mwills@google.com> Fix WifiScanner not recovering after Wifi is turned off

WifiScanner implementations could previously get in an inconsistent
state where they had not cleaned up from a previous scan that was
interrupted by turning Wifi off.

Bug: 27620477
Change-Id: I042e35d1aa8ee65e6ebfeb6f62a54c071a7be4ef
om/android/server/wifi/HalWifiScannerImpl.java
om/android/server/wifi/SupplicantWifiScannerImpl.java
om/android/server/wifi/WifiScannerImpl.java
om/android/server/wifi/WifiScanningServiceImpl.java
4bf1cc8cc917441bef9e53cda2c5ceb7f048a3e4 14-Mar-2016 Ritesh Reddy <riteshr@google.com> Calling BackupManager.dataChanged for WifiNetwork Changes

Using the BackupManager Proxy in the service package
to stage a backup of com.android.providers.settings when
Wifi Networks are added/removed.

Bug: 26087998
Change-Id: Ie91d40870fc843e67e99c6fbda26b14d281e96bb
om/android/server/wifi/WifiConfigStore.java
b740903bec94d63f89904ec9561085f9ca6c453a 11-Mar-2016 Paul Stewart <pstew@google.com> WifiStateMachine: Defer CMD_RESET_SIM_NETWORKS by default

Defer the CMD_RESET_SIM_NETWORKS message in states that do
not handle it. This way, this message will remain pending
until it can be handled.

Bug: 27532197
Change-Id: I1b1b8c0b198cf46cff86b625afead045fd7aec36
Test: Compile + unit tests
om/android/server/wifi/WifiStateMachine.java
25211a6fab0c8c623a0b9d39ac1bebac3d496176 12-Mar-2016 Roshan Pius <rpius@google.com> Merge "Update ScanCapabilities in WifiNative" into mm-wireless-dev
am: 9b34eab696

* commit '9b34eab6963479d468e6ab7859c3721b2d1e17f8':
Update ScanCapabilities in WifiNative
ef7480f78d994c786248a1ee8a601abf39aec696 11-Mar-2016 Glen Kuhne <kuh@google.com> resolve merge conflicts of ea91131081 to nyc-dev

Change-Id: I0662ccf4f80c3b0b48314aef3a5807ce27a13659
9b34eab6963479d468e6ab7859c3721b2d1e17f8 11-Mar-2016 Roshan Pius <rpius@google.com> Merge "Update ScanCapabilities in WifiNative" into mm-wireless-dev
d34e3a7b98d51f684100483151fceb233fd95215 11-Mar-2016 Roshan Pius <rpius@google.com> Update ScanCapabilities in WifiNative

BUG: 27607839
Change-Id: I8edb1b7637fa69b3ba1ee59e52d2e1c5a6e79c9e
TEST:Compiles & unit-test passes
om/android/server/wifi/WifiNative.java
ea91131081772e97c65581b9a290dee21ee79a83 11-Mar-2016 Glen Kuhne <kuh@google.com> Merge "Created WifiInjector, dependency injector for wifi" into mm-wireless-dev
963a22849edcbebdfe3bf2ecf2329a20789dbd7a 11-Mar-2016 Paul Stewart <pstew@google.com> Merge "WifiStateMachine: Return to InitialState if driver start fails" into mm-wireless-dev
am: 03e6c26c18

* commit '03e6c26c18a2bc89471569a899bef913c2770b36':
WifiStateMachine: Return to InitialState if driver start fails
03e6c26c18a2bc89471569a899bef913c2770b36 11-Mar-2016 Paul Stewart <pstew@google.com> Merge "WifiStateMachine: Return to InitialState if driver start fails" into mm-wireless-dev
637a86ffb3a036a4f26a471378b57d8817f35c25 08-Mar-2016 Glen Kuhne <kuh@google.com> Created WifiInjector, dependency injector for wifi

Created a new class WifiInjector, a lazy singleton for dependency
injection. Initial use case was accessing WifiMetrics from within
WifiScanningService, will allow for easy mocking, and is a potential
candidate to replace the mess that is FrameworkFacade.

BUG=27550630
BUG=25691077

Change-Id: I0b1a99f718912fe6ee9a1453ff275b5dfedce6fd
om/android/server/wifi/WifiInjector.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
bb1378fdf0fba19ad35de8803f33cdc663cfbea7 11-Mar-2016 Mitchell Wills <mwills@google.com> Fix Crash when getScanCapabilities fails
am: 017307e0d7

* commit '017307e0d7133f3b2523090136b919c6f494098e':
Fix Crash when getScanCapabilities fails
017307e0d7133f3b2523090136b919c6f494098e 11-Mar-2016 Mitchell Wills <mwills@google.com> Fix Crash when getScanCapabilities fails

Bug: 27603305
Change-Id: I7f7c3e86364b0e53b05c6c07962d32e95efae851
om/android/server/wifi/WifiScanningServiceImpl.java
1c3442a6f4f3966b25ab35b70e806e34b0674092 11-Mar-2016 Roshan Pius <rpius@google.com> Merge changes Ib8c98c06,I0731192d,I7d03b43b into mm-wireless-dev
am: b92d0785aa

* commit 'b92d0785aa1bb8ac828b067ce1c938f447c8ac7a':
WifiScanningServiceImpl: Add PNO active scans map
Pause PNO scans for single scan
Refactor WifiScanner support for oneshot scans
b92d0785aa1bb8ac828b067ce1c938f447c8ac7a 11-Mar-2016 Roshan Pius <rpius@google.com> Merge changes Ib8c98c06,I0731192d,I7d03b43b into mm-wireless-dev

* changes:
WifiScanningServiceImpl: Add PNO active scans map
Pause PNO scans for single scan
Refactor WifiScanner support for oneshot scans
afcee21ea26b08fd85bb3f878bec51e1e101bce7 10-Mar-2016 Paul Stewart <pstew@google.com> Fix map reference in WifiMonitor.sendMessage()
am: 7ce3d79fd3

* commit '7ce3d79fd3ed12a379d6abbe31c680d6fd8abf51':
Fix map reference in WifiMonitor.sendMessage()
7ce3d79fd3ed12a379d6abbe31c680d6fd8abf51 10-Mar-2016 Paul Stewart <pstew@google.com> Fix map reference in WifiMonitor.sendMessage()

In the case where no interface is available, we should iterate
over mHandlerMap and not depend on the possibly null variable
ifaceHandlers.

Bug: 27583666
Change-Id: I983972af593004262d939024f9e893f4867f2504
Test: Build and run unit tests
om/android/server/wifi/WifiMonitor.java
cc1d874560e4c0ca157bfda5d12df33a4f50fc11 10-Mar-2016 Mitchell Wills <mwills@google.com> Merge changes from topic \'wifi_scanner_hidden_network_ids\' into mm-wireless-dev
am: 01fb5b27ba

* commit '01fb5b27ba32f180080f2b2b12adbc5c803611ce':
Allow multiple Handlers to be registered for a WifiMonitor event
WifiScanner: Changes to support hidden Network Ids
1fa40005d82db21b2cc1c7e06d249b09c674ab8b 09-Mar-2016 Roshan Pius <rpius@google.com> WifiScanningServiceImpl: Add PNO active scans map

Add a separate map for storing all PNO request to their corresponding
listeners.

BUG: 27167559
Change-Id: Ib8c98c06478687d3fde50f33f0843ae0f13f2431
om/android/server/wifi/WifiScanningServiceImpl.java
d0310c7cb097dcb88a042b9308306091b4b8d568 08-Mar-2016 Roshan Pius <rpius@google.com> Pause PNO scans for single scan

Since PNO scans and regular scans are being scheduled by
WifiStateMachine and WifiScanner respectively. We need a
stop gap solution to pause wpa_supplicant PNO scans during
single scans.

TODO's:
Will move this logic in entirety to within Scanner once we
have WifiConnectivity manager using Scanner for all scans.

BUG: 27481309
TEST: Compiles & unit-test passes
TEST: Used PMC app to run single scan along with PNO to verify
behaviour manually.

Change-Id: I0731192dcad2dc5b697f645d588580303818f370
om/android/server/wifi/HalWifiScannerImpl.java
om/android/server/wifi/SupplicantWifiScannerImpl.java
om/android/server/wifi/WifiNative.java
8adb4e72f58e3e25918f33e0b2687e6acc14c47d 04-Nov-2015 Mitchell Wills <mwills@google.com> Refactor WifiScanner support for oneshot scans

Seperate oneshot scans so they are no longer implemented using
background scans and make WifiStateMachine use WifiScanner for single
scans.

This changes requires a few parts:
1. Implement single scan logic in WifiScanningServiceImpl for merging
and executing scan requests using the single scan native interface.
2. Writing tests for the new code in 1
3. Make supplicant start scans by using WifiScanner and when it
recieves callbacks dispatch scan complete/failure messages.
4. Enable HalWifiScannerImpl and SupplicantWifiScannerImpl to listen to
supplicant scan events now that WifiStateMachine does not.

Bug: 26525037
Bug: 26895774
Change-Id: I7d03b43bbd2be396b3c772bc4bae681acce8eb7b
om/android/server/wifi/HalWifiScannerImpl.java
om/android/server/wifi/ScanDetail.java
om/android/server/wifi/SupplicantWifiScannerImpl.java
om/android/server/wifi/WifiScanningScheduler.java
om/android/server/wifi/WifiScanningServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
01fb5b27ba32f180080f2b2b12adbc5c803611ce 10-Mar-2016 Roshan Pius <rpius@google.com> Merge changes from topic 'wifi_scanner_hidden_network_ids' into mm-wireless-dev

* changes:
Allow multiple Handlers to be registered for a WifiMonitor event
WifiScanner: Changes to support hidden Network Ids
af2b79e4cfc1da793b3d8fb4a96c144deefc7d58 01-Mar-2016 Joe Onorato <joeo@google.com> Turn off excess logging

Change-Id: I1e1d116f1e2abfc01255b492a38a7839635b9bed
om/android/server/wifi/WifiNative.java
om/android/server/wifi/hotspot2/AnqpCache.java
fc0f43edd0def7d760e42d6e800d862007cf9fd5 09-Mar-2016 Paul Stewart <pstew@google.com> WifiStateMachine: Return to InitialState if driver start fails

If WiFi is set to shut off on idle, WifiController calls
mWifiStateMachine.setDriverStart(false), and WifiStateMachine
eventually enters the DriverStopped state. On return from
idle the reverse happens and WifiStateMachine attempts to
restore the driver. If this fails, WifiStateMachine simply
returns to the DriverStopped state.

This CL changes this behavior. If restarting the driver
fails we now restart supplicant, which causes the state
machine to traverse the InitialState. This provides a fail
safe mechanism for restarting drivers that may not have
suspended correctly.

Bug: 26735919
Change-Id: Ide9bc5339a9be1ea4ac67fc99fe6065529ee67e2
Test: Reproduce b/26735919 on bullhead, which is currently suffering from b/27576943
om/android/server/wifi/WifiStateMachine.java
143d50d011d4a26ff5402fc6b3ff19f945ff7153 09-Mar-2016 Sunil Dutt <usdutt@qti.qualcomm.com> Merge "Wifi: send an explicit ENABLE_NETWORK with "no-connect"" into mm-wireless-dev
am: e5da466fd5

* commit 'e5da466fd5d9d8024780590ee8b1c335889443a7':
Wifi: send an explicit ENABLE_NETWORK with "no-connect"
e5da466fd5d9d8024780590ee8b1c335889443a7 09-Mar-2016 Roshan Pius <rpius@google.com> Merge "Wifi: send an explicit ENABLE_NETWORK with "no-connect"" into mm-wireless-dev
3c83d4783673c1e2fa64c56dc586c5f7c3ab73e0 09-Mar-2016 Mitchell Wills <mwills@google.com> Allow multiple Handlers to be registered for a WifiMonitor event

Bug: 26966049
Bug: 27569474
Change-Id: I07012b0e4ad2e3510e0a84368949b65d7b99507d
om/android/server/wifi/WifiMonitor.java
d74ff28cdb01d3f711e0b0f0e99e51fdb221eaf2 07-Mar-2016 Roshan Pius <rpius@google.com> WifiScanner: Changes to support hidden Network Ids

Add the required plumbing to support scanning for hidden networks via
wpa_supplicant.
Added a test case to verify that the network ID list is being sent
as expected.

BUG: 27503786
Change-Id: I2d1ef74494080e01248ae8aad5081c7608fc0e81
TEST: Compiles & unit-test passes
om/android/server/wifi/HalWifiScannerImpl.java
om/android/server/wifi/MultiClientScheduler.java
om/android/server/wifi/SupplicantWifiScannerImpl.java
om/android/server/wifi/WifiNative.java
b409fc8e164c522275e1df302a37e05662163004 08-Mar-2016 Glen Kuhne <kuh@google.com> Merge "Fix WifiMetrics connection auth type" into mm-wireless-dev
am: a7aef0a457

* commit 'a7aef0a45759880487863fd81bfbfbc748baa73b':
Fix WifiMetrics connection auth type
a7aef0a45759880487863fd81bfbfbc748baa73b 08-Mar-2016 Glen Kuhne <kuh@google.com> Merge "Fix WifiMetrics connection auth type" into mm-wireless-dev
838e8915ad29a380254f4bb77293badb949b4b1b 08-Mar-2016 Glen Kuhne <kuh@google.com> Merge "Add Supported Rates and 802.11 Mode detection" into mm-wireless-dev
am: 9947ed6dfd

* commit '9947ed6dfddffe1746d98bf01499a81d7c3de123':
Add Supported Rates and 802.11 Mode detection
9947ed6dfddffe1746d98bf01499a81d7c3de123 08-Mar-2016 Glen Kuhne <kuh@google.com> Merge "Add Supported Rates and 802.11 Mode detection" into mm-wireless-dev
163d510aac068682c390664e51e83bbf870fe5f5 08-Mar-2016 Sunil Dutt <usdutt@qti.qualcomm.com> Wifi: send an explicit ENABLE_NETWORK with "no-connect"

ENABLE_NETWORK command is called from the framework because of PNO state
change, which triggers the connect.This command is only expected to
enable the network and not issue a connect because from framework the
expected sequence of operations for a connect are SET_NETWORK,
ENABLE_NETWORK and SELECT_NETWORK.
Send an explicit ENABLE_NETWORK with "no-connect" to avoid connection.

Change-Id: I7583e9ff0c5b8700d9ec945d93b5175c134e8e76
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiNative.java
699238e909ebaee0b7f759c4d04efabe75813789 07-Mar-2016 Mitchell Wills <mwills@google.com> Correctly filter results by time from supplicant in Hal scan impl
am: 2e0b845b65

* commit '2e0b845b65b2e2151cddbdafb90bd0f744b10654':
Correctly filter results by time from supplicant in Hal scan impl
2e0b845b65b2e2151cddbdafb90bd0f744b10654 05-Mar-2016 Mitchell Wills <mwills@google.com> Correctly filter results by time from supplicant in Hal scan impl

Bug: 27358828
Change-Id: Ic9ddfa02a0e3c282871ddfa3347312a5917dbec0
om/android/server/wifi/HalWifiScannerImpl.java
244eddf3f51abce29914bdc1c1582b4a13e7733c 07-Mar-2016 Roshan Pius <rpius@google.com> Capture Wlan host wake reasons in bugreport
am: 15ed48d023

* commit '15ed48d023d623a4eeb8fd3a54b9c275874362f5':
Capture Wlan host wake reasons in bugreport
15ed48d023d623a4eeb8fd3a54b9c275874362f5 07-Mar-2016 Roshan Pius <rpius@google.com> Capture Wlan host wake reasons in bugreport

Dump out the wlan host wake reasons data retrieved from
WifiNative into bugreport.

BUG: 27461093
Change-Id: Ibec4676fb68b8fa95858bea39398395b204ca1f4
om/android/server/wifi/WifiStateMachine.java
2b152feb1c574f30557581770d4f8c06c770ba34 07-Mar-2016 Glen Kuhne <kuh@google.com> Fix WifiMetrics connection auth type

Use ScanResult instead of WifiConfiguration to get the Auth type, as
WifiConfiguration's allowedAuthAlgorithms is not valid at the beginning
of a connection attempt.
Also refactored metric getting from ScanResults and NetworkDetails into
their own helper functions.

BUG=25691077

Change-Id: I528a1c76204b5197815ad3836d743513f89bc9ca
om/android/server/wifi/WifiMetrics.java
0a21d6c371532509c566ddf1cc485f99f1abdb57 07-Mar-2016 Roshan Pius <rpius@google.com> Merge "WifiConfigManager: Change PNO network list type" into mm-wireless-dev
am: 3a2b55ba28

* commit '3a2b55ba283dec0d3e3421bdd27568ad0644bd7e':
WifiConfigManager: Change PNO network list type
df14c4522d4e948a2ae21a27de2ee926c32b9b5e 07-Mar-2016 Roshan Pius <rpius@google.com> Merge "PNO: Bugfixes in WifiNative" into mm-wireless-dev
am: 9a7223a7a5

* commit '9a7223a7a51be6e8f700b9240493859e667f2017':
PNO: Bugfixes in WifiNative
da535126fc49867ce88faba99cc854ef59192dc7 07-Mar-2016 Roshan Pius <rpius@google.com> Merge "WifiScannerImpl: PNO implementation (Part 1)" into mm-wireless-dev
am: d17c24a96d

* commit 'd17c24a96de6fdeec1d6d41ad5c986712d9acf18':
WifiScannerImpl: PNO implementation (Part 1)
3a2b55ba283dec0d3e3421bdd27568ad0644bd7e 07-Mar-2016 Roshan Pius <rpius@google.com> Merge "WifiConfigManager: Change PNO network list type" into mm-wireless-dev
9a7223a7a51be6e8f700b9240493859e667f2017 07-Mar-2016 Roshan Pius <rpius@google.com> Merge "PNO: Bugfixes in WifiNative" into mm-wireless-dev
d17c24a96de6fdeec1d6d41ad5c986712d9acf18 07-Mar-2016 Roshan Pius <rpius@google.com> Merge "WifiScannerImpl: PNO implementation (Part 1)" into mm-wireless-dev
f5cc6a0c7ede374b33de1cf5156bf149e2e76c13 01-Mar-2016 Glen Kuhne <kuh@google.com> Add Supported Rates and 802.11 Mode detection

Added an Information Element parser for Supported and Extended Supported
Rates.
Uses this information and other IEs to determine the 802.11 Mode
(a/b/g/n/ac) being used by APs, stores it in their scan results.
Modified WifiMetrics to receive and store this metric from a ScanDetail
Added calls to WifiMetrics from WifiStateMachine to give it a ScanDetail
Minor fix to WifiStateMachine's tracking of TargetNetworkId, which it
was clearing incorrectly on NETWORK_DISCONNECTION_EVENT

BUG=25691077
BUG=27446779
Change-Id: I63af5911916bfec87628aeb4e1ed4f9138acfafa
om/android/server/wifi/WifiMetrics.java
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/hotspot2/NetworkDetail.java
om/android/server/wifi/util/InformationElementUtil.java
f38ce9684dc1e5eeae48ef45a75d10c6d738046f 07-Mar-2016 Roshan Pius <rpius@google.com> Merge "PNO: Changes in Native for new interface" into mm-wireless-dev
am: ffe70f78d0

* commit 'ffe70f78d0aca71e9c5af82f11472d422f14b301':
PNO: Changes in Native for new interface
ffe70f78d0aca71e9c5af82f11472d422f14b301 07-Mar-2016 Roshan Pius <rpius@google.com> Merge "PNO: Changes in Native for new interface" into mm-wireless-dev
8c0c14b2c98bc26e6a09f66cff1244f0a30f44cb 05-Mar-2016 Roshan Pius <rpius@google.com> WifiConfigManager: Change PNO network list type

Change the PNO network list type from WifiNative to WifiScanner type
since that is the new public interface for starting PNO scans.

1. Remove the PnoNetwork constructore from WifiNative
2. Create a temporary conversion function in WifiStateMachine to
convert to WifiNative.PnoNetwork.

BUG: 27167559
Change-Id: I7c845321eab20f822f5d7d5231294181343ef2be
TEST: Compiles & unit-test passes
om/android/server/wifi/WifiConfigManager.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
ef3ea1092bc17673c0a85a845b053151b7c10e07 04-Mar-2016 Roshan Pius <rpius@google.com> PNO: Bugfixes in WifiNative

Fix coupke of bugs in the |setPnoListNative| API found in manual testing
of startPnoScan/stopPnoScan testing.

BUG: 27167559
Change-Id: I1e2f8167fbee6db2401fdc918cd46f7d9d594bff
TEST: Compiles & unit-test passes & manual testing of Scanner API
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiScanningServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
9153bd67d51b305ffdd61355e0748e3c332c2caf 02-Mar-2016 Roshan Pius <rpius@google.com> WifiScannerImpl: PNO implementation (Part 1)

1. Immplementation of the PNO interface in WifiScannerImpl for
setting/resetting the PNO list.
a. For supplicant based PNO, setting the pno list will also
trigger the scan and we don't scan any background scans.
b. For HAL based PNO, we set the pno list and then schedule a normal
background scan.
2. Plumbing of the OnPnoNetworkFound callback to the client.

TODO's:
1. Will need to integrate the PNO monitor notifcations in
SupplicantWifiScannerImpl to raise OnPnoNetworkFound callbacks.

BUG: 27167559
Change-Id: I8859a419b37b9cb125a710fb67ae1b62db7f779d
TEST: Compiles & unit-test passes
om/android/server/wifi/HalWifiScannerImpl.java
om/android/server/wifi/SupplicantWifiScannerImpl.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiScannerImpl.java
om/android/server/wifi/WifiScanningServiceImpl.java
9bd01d6cb65ea96d6729d35a1fc43bb2bb40e3bd 02-Mar-2016 Roshan Pius <rpius@google.com> PNO: Changes in Native for new interface

Changes in WifiNative to accomodate the new Scanner based PNO interface.
Currently, we're just setting the |wifi_epno_network| list member in
|wifi_epno_params| structure. All the other values are being ignored.

1. Change the native |android_net_wifi_setPnoListNative| to accept the
PNO settings parameter instead of directly accepting the list of
networks.
2. Changes in WifiNative to send down the new |PnoSettings| structure
down to the native code instead of directly sending the list.
a. Keep the existing interface from |WifiStateMachine| which accepts a
|PnoNetwork| list and converts it into |PnoSettings| structure.
This interface will be removed once all the new Scanner based
interface plumbing is complete.
3. Add a separate native API to reset PNO list.

While there,
Remove redundant "Wifi" prefix from Pno class names.

BUG: 27167559
Change-Id: I78d35c20b4bb7a12c51d0c2cc609fb7bcb5ae516
TEST: Compiles & unit-test passes
om/android/server/wifi/WifiConfigManager.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
b51e54f90373ec8cfcf57cc67f495dc831d8f5b4 05-Mar-2016 Roshan Pius <rpius@google.com> Merge "Send list of hidden networkID for supplicant scan" into mm-wireless-dev
am: 6b0c636d0a

* commit '6b0c636d0a97e6163a99a8fbf5c199998c1be770':
Send list of hidden networkID for supplicant scan
6b0c636d0a97e6163a99a8fbf5c199998c1be770 05-Mar-2016 Roshan Pius <rpius@google.com> Merge "Send list of hidden networkID for supplicant scan" into mm-wireless-dev
3d995b8a3a508e957e3dac2e508956020cd9abfe 04-Mar-2016 Roshan Pius <rpius@google.com> Send list of hidden networkID for supplicant scan

Since we disable all the networks in wpa_supplicant (as of b/26984166),
we need to explicitly send the list of hidden ssid's to scan.

1. Use the 'scan_id' override to send a lit of hidden networkId's to
supplicant.
2. Add a new set of hidden networkId's in ConfigurationMap which can be
used as parameter for the above.
3. Add a test to start scan with a hidden network added.

BUG: 27471630
TEST: Verfied that we auto-connect to a hidden ssid.
TEST: `runtest frameworks-wifi`

Change-Id: I8aea09d1ec2f24310959a558e8b12d31a26d179c
om/android/server/wifi/ConfigurationMap.java
om/android/server/wifi/HalWifiScannerImpl.java
om/android/server/wifi/SupplicantWifiScannerImpl.java
om/android/server/wifi/WifiConfigManager.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
aba75f2f27c381db3048e1edc075dd2dd293c41a 04-Mar-2016 Randy Pan <zpan@google.com> Propogate user band preference to QNS
am: 2d35cbcae4

* commit '2d35cbcae4d281b6fd242402b87ed5668ec0400c':
Propogate user band preference to QNS
f4f32b8912e79b8e144ed640ffda8da8edc0513d 04-Mar-2016 Paul Stewart <pstew@google.com> Merge "Resolve merge conflict with mmwd" into nyc-dev
2d35cbcae4d281b6fd242402b87ed5668ec0400c 04-Mar-2016 Randy Pan <zpan@google.com> Propogate user band preference to QNS

The path was disabled unless a debugging flag's turned on.

Bug: 27481486
Change-Id: Ia137897e3e617a936c9adb54956c2ef121762708
om/android/server/wifi/WifiStateMachine.java
3a06049bbb03018afb5f883b3ea402201711ba0e 04-Mar-2016 Ningyuan Wang <nywang@google.com> Merge "Remove lazy roam code" into mm-wireless-dev
am: f8cd000f75

* commit 'f8cd000f751b6e886cdcfd254fee34ed2dc4109b':
Remove lazy roam code
f8cd000f751b6e886cdcfd254fee34ed2dc4109b 04-Mar-2016 Ningyuan Wang <nywang@google.com> Merge "Remove lazy roam code" into mm-wireless-dev
90bcd3310f82b3e766f736701868077299ea3d9b 04-Mar-2016 Paul Stewart <pstew@google.com> Resolve merge conflict with mmwd

Due to its sordid history, this handleGsmAuthRequest method in
WifiStateMachine got out of sync between nyc-dev and mmwd.

Bug: 27487428
Change-Id: I762989fe1fb7a3e0dbf2e943fc564e1540bb33a1
om/android/server/wifi/WifiStateMachine.java
f1b21eb3b25dd2b7c605bce86c57ce4abc799371 04-Mar-2016 Rakesh Iyer <rni@google.com> Re-add guard removed to fix build.

if (VDBG) was removed to fix build, re-add if (DBG).

Change-Id: I04931a91e2ead5d647ac33eef0fcf519298f7f3f
om/android/server/wifi/WifiStateMachine.java
86e6f8023b7b0f1da86ed3584523d7c701027f39 04-Mar-2016 Rakesh Iyer <rni@google.com> Fix build.

Change-Id: I4dd26a81a6924ed6dbe3a874931d9c393d8d4289
om/android/server/wifi/WifiStateMachine.java
cc4f303ff2b0c2406528d4d4fbdf24e0c20df74f 04-Mar-2016 Ningyuan Wang <nywang@google.com> Clean the WifiStateMachine logging tags
am: 55dd2dd2cc

* commit '55dd2dd2ccabb3a18d6b3166b9d8a68246f8dc23':
Clean the WifiStateMachine logging tags
55dd2dd2ccabb3a18d6b3166b9d8a68246f8dc23 01-Mar-2016 Ningyuan Wang <nywang@google.com> Clean the WifiStateMachine logging tags

There are several logging tags (DBG, VDBG, PDBG, VVDBG, etc)
in WifiStateMachine. Theses tags are not well defined therefore
bringing difficulties to debugging.
It would be better if we only use one DBG tag instead of these
tags.

BUG=27433414

Change-Id: I2108d9b9b61aa5e697e746eb9d12b492361844b8
om/android/server/wifi/WifiStateMachine.java
35aa32e8098002796059589c6084349d15d029c9 04-Mar-2016 Ningyuan Wang <nywang@google.com> Merge "Remove redundant class TetherStateChange" into mm-wireless-dev
am: 39970b6abd

* commit '39970b6abd278e87e7a1cf2083158c07e03003ee':
Remove redundant class TetherStateChange
81c730b75b8772ee0192ef8391e3fedfc7405274 04-Mar-2016 Ningyuan Wang <nywang@google.com> Remove unused function configureSsidWhiteList()
am: d63e34a4e6

* commit 'd63e34a4e68bcd320d01fe930662cc2ad3426656':
Remove unused function configureSsidWhiteList()
a5c3069e0bf18cb7eedd3e5c0eccecea48e953c0 04-Mar-2016 Ningyuan Wang <nywang@google.com> Remove lazy roam code

Lazy roam is no longer in use.
Therefore this CL removes the relevant code.

Bug: 27484729

Change-Id: I8209a6ff1ba9281aa83840c039e99ae9c34ffe9a
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
39970b6abd278e87e7a1cf2083158c07e03003ee 04-Mar-2016 Ningyuan Wang <nywang@google.com> Merge "Remove redundant class TetherStateChange" into mm-wireless-dev
d63e34a4e68bcd320d01fe930662cc2ad3426656 04-Mar-2016 Ningyuan Wang <nywang@google.com> Remove unused function configureSsidWhiteList()

The function configureSsidWhiteList calls a empty function in
WifiNative.
This removes the relevant code.

Bug: 27377844
Change-Id: Ifc1e6418e52e28688fb0c379b77824a20add127f
om/android/server/wifi/WifiConfigManager.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
5a9de3b00d2a3b7c361eb89355f0afaec22d71e7 03-Mar-2016 Ningyuan Wang <nywang@google.com> Remove redundant class TetherStateChange

The SoftApManager was moved out of WifiStateMachine.
Class TetherStateChange is not used any more.
This CL removes it.

Bug: 27475281

Change-Id: I237b6d7b55f4d1da314b9ae06a391bb2d50542f3
om/android/server/wifi/WifiStateMachine.java
324a8f59d5d2e36fb9a20a175bc857f3408a12e5 03-Mar-2016 Roshan Pius <rpius@google.com> Merge "WifiConfigStore: Cleanup logging in the module" into mm-wireless-dev
am: 4f45b3dd4a

* commit '4f45b3dd4ab6c6cfa07e2b696272ce6ad61b92a5':
WifiConfigStore: Cleanup logging in the module
cf8925fa96505b5ea704b7eef697f97c94f6c186 03-Mar-2016 Boxiang Pan <bopan@codeaurora.org> Wifi: Update Frequency before broadcasting intent
am: b68baa2dcc

* commit 'b68baa2dccdf781d3f8dd5af52f38e7e4986be72':
Wifi: Update Frequency before broadcasting intent
4f45b3dd4ab6c6cfa07e2b696272ce6ad61b92a5 03-Mar-2016 Roshan Pius <rpius@google.com> Merge "WifiConfigStore: Cleanup logging in the module" into mm-wireless-dev
b68baa2dccdf781d3f8dd5af52f38e7e4986be72 26-Feb-2016 Boxiang Pan <bopan@codeaurora.org> Wifi: Update Frequency before broadcasting intent

Update the frequency information before broadcasting
NETWORK_STATE_CHANGED_ACTION so that it contains the
up-to-date frequency info.

Bug:27367137
Change-Id: I9fe53a5f25b7c4a718b4e7b4c66459482f4f084e
om/android/server/wifi/WifiStateMachine.java
547c7b692ebd03dc108ef1397be5c15a19f0dab0 03-Mar-2016 Paul Jensen <pauljensen@google.com> Merge "Plumb WiFi packet filtering HAL APIs to Network Agent." into mm-wireless-dev
am: c121fe3f27

* commit 'c121fe3f2733b3d1d091f2f87fb53b2e3581ca82':
Plumb WiFi packet filtering HAL APIs to Network Agent.
c121fe3f2733b3d1d091f2f87fb53b2e3581ca82 03-Mar-2016 Lorenzo Colitti <lorenzo@google.com> Merge "Plumb WiFi packet filtering HAL APIs to Network Agent." into mm-wireless-dev
6609df5a9c14e4440c085567a27437a8cfc50f88 14-Jan-2016 Paul Jensen <pauljensen@google.com> Plumb WiFi packet filtering HAL APIs to Network Agent.

Bug: 26238573
Change-Id: I67e08f4771007a2ea2cbc7a93eaaa55cddd017a2
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
2791875608a19bde5bf431294502a9b138125278 03-Mar-2016 Sharvil Nanavati <sharvil@google.com> Merge "Make sure WiFi country code gets set properly." into mm-wireless-dev
am: 799d849a80

* commit '799d849a809a8f98bf13ac5cbbb441882d35509f':
Make sure WiFi country code gets set properly.
799d849a809a8f98bf13ac5cbbb441882d35509f 03-Mar-2016 Paul Stewart <pstew@google.com> Merge "Make sure WiFi country code gets set properly." into mm-wireless-dev
90ee0a6ad4ce8ac3280fd07a0b148d82678fc6a0 03-Mar-2016 mukesh agrawal <quiche@google.com> Merge "make ringbuffer size configurable" into mm-wireless-dev
am: 3e3ad8dfb0

* commit '3e3ad8dfb0eddfc98ed21ce51a96a28924fe8c14':
make ringbuffer size configurable
762e4ccc42148315dbd4c4c6aae14e0c45d78588 03-Mar-2016 mukesh agrawal <quiche@google.com> Merge "WifiLogger: manage ring buffers by bytes" into mm-wireless-dev
am: 84f4423601

* commit '84f44236019a1ae41739984c12eccdd14ca97e3f':
WifiLogger: manage ring buffers by bytes
f19b89324583cf23eb5cea9b5f94810a5a5825c5 03-Mar-2016 mukesh agrawal <quiche@google.com> Merge "add ByteArrayRingBuffer" into mm-wireless-dev
am: 00ed767aee

* commit '00ed767aee2b1eaef10b849a27f1ce6bda43f83f':
add ByteArrayRingBuffer
3e3ad8dfb0eddfc98ed21ce51a96a28924fe8c14 03-Mar-2016 Mukesh Agrawal <quiche@google.com> Merge "make ringbuffer size configurable" into mm-wireless-dev
84f44236019a1ae41739984c12eccdd14ca97e3f 03-Mar-2016 Mukesh Agrawal <quiche@google.com> Merge "WifiLogger: manage ring buffers by bytes" into mm-wireless-dev
00ed767aee2b1eaef10b849a27f1ce6bda43f83f 03-Mar-2016 Mukesh Agrawal <quiche@google.com> Merge "add ByteArrayRingBuffer" into mm-wireless-dev
c42e29a329fabcbcb9868f4966c106f865a199e8 03-Mar-2016 Mitchell Wills <mwills@google.com> Merge "Update scan band channels when needed" into mm-wireless-dev
am: 25d25de358

* commit '25d25de358ece952e16420a89dd899ebed46f77a':
Update scan band channels when needed
25d25de358ece952e16420a89dd899ebed46f77a 03-Mar-2016 Mitchell Wills <mwills@google.com> Merge "Update scan band channels when needed" into mm-wireless-dev
900f0bce69543e60b5546b9722f845e970540eb4 02-Mar-2016 Randy Pan <zpan@google.com> Merge "Fix ScanDetailCache thread safety issue" into mm-wireless-dev
am: 3006ab39ff

* commit '3006ab39ff7cf73197c097418a2b510349925b25':
Fix ScanDetailCache thread safety issue
3006ab39ff7cf73197c097418a2b510349925b25 02-Mar-2016 Randy Pan <zpan@google.com> Merge "Fix ScanDetailCache thread safety issue" into mm-wireless-dev
6c8745470e4819996b3797dbec324b1cb88e892b 26-Feb-2016 Sharvil Nanavati <sharvil@google.com> Make sure WiFi country code gets set properly.

The current logic forces the country code to be set if it has never
been *attempted* to be set before or if a new country code is being set.
However, it doesn't handle the case where setting the country code with
the driver fails.

This change always forces the country code to be set if it has never
been set for, taking into account potential failures coming back
from the native layer.

Cherry picked from 96cbf09d2430d0f1dc4a06bb62263c56469d63f2

Bug: 25208308
Change-Id: Ie0f03e9a16a0f681b2977f4ee19af9339281a9c0
om/android/server/wifi/WifiStateMachine.java
7713c37038f24f06039e5c4c3c191e10a1b9e159 02-Mar-2016 Randy Pan <zpan@google.com> Fix ScanDetailCache thread safety issue

Changed the type of ScanDetailCache HashMap to ConcurrentHashMap.
Tuned ScanDetailCaches and ScanDetailCache ConcurrentHashMap
concurrency level parameter to save memory.

Bug: 27064997
Change-Id: Icc0a36970fc58142968bccfe2d94a7d5a039344d
om/android/server/wifi/ScanDetailCache.java
om/android/server/wifi/WifiConfigManager.java
9506574387c00033ad7b0e95a4c43d0753e42b56 02-Mar-2016 Erik Kline <ek@google.com> Merge changes from topic \'ndoe\' into mm-wireless-dev
am: 4123d08364

* commit '4123d0836446e8979a4e012a0de51f73bdfcafb8':
Disable/enable ND offload whenever 464xlat is enabled/disabled
Add NDOE calls to WifiNative
4123d0836446e8979a4e012a0de51f73bdfcafb8 02-Mar-2016 Erik Kline <ek@google.com> Merge changes from topic 'ndoe' into mm-wireless-dev

* changes:
Disable/enable ND offload whenever 464xlat is enabled/disabled
Add NDOE calls to WifiNative
fef1495477206d4cabfc95325d71de41790cf9cc 02-Mar-2016 mukesh agrawal <quiche@google.com> make ringbuffer size configurable

Different builds of the WiFi service may want to have different
ring buffer sizes. To allow for this, have the WiFi service
consult Resources for the size to use.

BUG=27264418
TEST=unit tests
TEST=add Log call in WSM ctor, verify size from values.xml was used

Change-Id: Ie6adc9efe107dfeaf4894aaff35c0beb6f7f9819
om/android/server/wifi/FrameworkFacade.java
om/android/server/wifi/WifiLogger.java
om/android/server/wifi/WifiStateMachine.java
b46c550a7305e6c42af4ca92a964b801c33f1f72 02-Mar-2016 mukesh agrawal <quiche@google.com> WifiLogger: manage ring buffers by bytes

At present, we manage the ring buffers by the number of
entries, rather than the number of bytes. Since the size
of an entry is variable, managing by the number of entries
doesn't give us solid control over the amount of memory
used.

To solve this, switch from LimitedCircularArray<byte[]>, to
ByteArrayRingBuffer. ByteArrayRingBuffer limits the number of
bytes, rather than the number of entries.

To facilitate testing, make two of WifiLogger's inner classes
(BugReport and LimitedCircularArray) package-private, instead
of strictly private.

BUG=27264379
TEST=(new) unit tests

Change-Id: I2ed6557bd0b40db3227e1e22ea7ff9f8a27ab2ba
om/android/server/wifi/WifiLogger.java
cc84bc6179db408b1e45168d43e10ba0ab089fca 01-Mar-2016 mukesh agrawal <quiche@google.com> add ByteArrayRingBuffer

We want to manage the debug ring buffers by total spaced used,
rather than by the number of entries in the ring. Add a new
class, ByteArrayRingBuffer, to provide the needed functionality.

BUG=27264379
TEST=(new) unit tests

Change-Id: I6e1ce82e028fc621f3fc9c96a5cb0cbd71c2d4e3
om/android/server/wifi/util/ByteArrayRingBuffer.java
7daffc2adcbdb907d3689dadac0f62be857dac18 02-Mar-2016 Roshan Pius <rpius@google.com> Merge "WifiStateMachine: Remove ScanDetailCache" into mm-wireless-dev
am: 2bcef4b02f

* commit '2bcef4b02f2ee2bc2219f672a7d2483f34bc68fb':
WifiStateMachine: Remove ScanDetailCache
2bcef4b02f2ee2bc2219f672a7d2483f34bc68fb 02-Mar-2016 Roshan Pius <rpius@google.com> Merge "WifiStateMachine: Remove ScanDetailCache" into mm-wireless-dev
ab51f239fdcbdb0ef6e6f4205c1d0e2b307731ce 01-Mar-2016 Randy Pan <zpan@google.com> Merge "Fix WifiConfigManager thread safety issue" into mm-wireless-dev
am: 6f5af9b7f6

* commit '6f5af9b7f69b15369238bd2642c46638ba1f0255':
Fix WifiConfigManager thread safety issue
6f5af9b7f69b15369238bd2642c46638ba1f0255 01-Mar-2016 Randy Pan <zpan@google.com> Merge "Fix WifiConfigManager thread safety issue" into mm-wireless-dev
6226db5c008e38b536d4679db43878ec75d12337 01-Mar-2016 Randy Pan <zpan@google.com> Merge "Request score from NetworkScoreManager" into mm-wireless-dev
am: 476a705b3b

* commit '476a705b3b97a7232773c005d228ec331f2a292a':
Request score from NetworkScoreManager
476a705b3b97a7232773c005d228ec331f2a292a 01-Mar-2016 Randy Pan <zpan@google.com> Merge "Request score from NetworkScoreManager" into mm-wireless-dev
e6d8fa5fb50afdfc04922f7f87c2cac08db5bbec 29-Feb-2016 Mitchell Wills <mwills@google.com> Update scan band channels when needed

The involves adding an ability to channel helper to trigger a channel
list update.

Bug: 27381346
Change-Id: I7908018ff8136b9ce7880d5090bbe9e6fb63405d
om/android/server/wifi/HalWifiScannerImpl.java
om/android/server/wifi/WifiScanningServiceImpl.java
om/android/server/wifi/scanner/ChannelHelper.java
om/android/server/wifi/scanner/HalChannelHelper.java
om/android/server/wifi/scanner/KnownBandsChannelHelper.java
om/android/server/wifi/scanner/NoBandChannelHelper.java
om/android/server/wifi/scanner/PresetKnownBandsChannelHelper.java
429cfce25c56c4c041c428711888a72bf10b118d 01-Mar-2016 Roshan Pius <rpius@google.com> WifiStateMachine: Remove ScanDetailCache

Remove all ScanDetailCache references from WifiStateMachine since it's
not being used. Add a new synchronization object to lock all scan result
updation.

BUG: 27412278
Change-Id: Ie56c632103d3551dbe5c10803041eb290f516951
TEST: `runtest frameworks-wifi`
om/android/server/wifi/WifiStateMachine.java
6bb2f7103134f742100c5f71ec9f85a0ef58581e 29-Feb-2016 Erik Kline <ek@google.com> Disable/enable ND offload whenever 464xlat is enabled/disabled

Bug: 26238390
Change-Id: I40d55f51b2ccf3e5da8eaecbf0f1127a7eea92b5
om/android/server/wifi/WifiStateMachine.java
3dd6f75ff2ab823bd0c14581f2e047c74916f16f 29-Feb-2016 Erik Kline <ek@google.com> Add NDOE calls to WifiNative

Bug: 26238390
Change-Id: I23109a6c3692dc49c4c931151c3c5ed735aa23a7
om/android/server/wifi/WifiNative.java
dec9f72b9872bcdea2c6b7ef9eae5470d6141291 01-Mar-2016 Paul Stewart <pstew@google.com> Revert inadvertent EAP-SIM merges from mnc-dr1.5-dev

This reverts the following errant merges from
mnc-dr1.5-dev, which should have been marked with
"DO NOT MERGE":

12a3cb2980e200dd7869e9d1ee4659a6c7e44c02
b732b11b2f24d57859bf0f301cf22e2ddc5dedc3

BUG=27420454

Change-Id: I7ba112cf4fdd127e16972769c678c5ca125489c3
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
12a3cb2980e200dd7869e9d1ee4659a6c7e44c02 01-Mar-2016 Paul Stewart <pstew@google.com> Revert "Appropriately fail EAP-SIM/AKA when SIM doesn\'t generate good response"
am: f9aabd71e9

* commit 'f9aabd71e9e60b80ea08bf92a3d3ebb28c7031df':
Revert "Appropriately fail EAP-SIM/AKA when SIM doesn't generate good response"
b732b11b2f24d57859bf0f301cf22e2ddc5dedc3 01-Mar-2016 Paul Stewart <pstew@google.com> Revert "WifiStateMachine: Only respond once to multiple EAP-SIM challenges"
am: 550a2c8d88

* commit '550a2c8d8885c56b049dcf5369cf6bc9234543b7':
Revert "WifiStateMachine: Only respond once to multiple EAP-SIM challenges"
adf70a7b3856bed24be4ddaf3a7d69da37c1f952 01-Mar-2016 Randy Pan <zpan@google.com> Fix WifiConfigManager thread safety issue

Change ScanDetailCaches type from HashMap to ConcurrentHashMap,
which is thread safe.

Bug: 27064997
Change-Id: I7d7228e8ad479af2b4d14e6a544c1bfc94bd5f2c
om/android/server/wifi/WifiConfigManager.java
om/android/server/wifi/WifiNetworkHistory.java
e5f74b10e5011ffb33739b2ae3d7840db7a5155b 29-Feb-2016 Randy Pan <zpan@google.com> Request score from NetworkScoreManager

Fixed a regression from QNS that scores were never requested
from the NetworkScoreManger.

Bug: 27246174
Change-Id: Ie0795d45264d4d18a9f73669bf28a7475a6cf427
om/android/server/wifi/WifiQualifiedNetworkSelector.java
e27341c71aa34f49dfc90d1ebee1e5eadb6a4605 29-Feb-2016 Roshan Pius <rpius@google.com> Merge "WifiConfigManager: Refactor remove network" into mm-wireless-dev
am: 60c716a0ed

* commit '60c716a0ed1549fe9e3e9e8528abc284f32a8aba':
WifiConfigManager: Refactor remove network
4b7cac8c07150195ff5e27f05f3f2e9927a74804 29-Feb-2016 Roshan Pius <rpius@google.com> Merge "WifiConfigManager: Cleanup instance names" into mm-wireless-dev
am: dfd0b02138

* commit 'dfd0b0213860f726e25a8c17ab648e4e56a8abcc':
WifiConfigManager: Cleanup instance names
60c716a0ed1549fe9e3e9e8528abc284f32a8aba 29-Feb-2016 Roshan Pius <rpius@google.com> Merge "WifiConfigManager: Refactor remove network" into mm-wireless-dev
dfd0b0213860f726e25a8c17ab648e4e56a8abcc 29-Feb-2016 Roshan Pius <rpius@google.com> Merge "WifiConfigManager: Cleanup instance names" into mm-wireless-dev
34d1b0a6bb748eb3e87eeab8e5f17bdcde35669e 29-Feb-2016 Rebecca Silberstein <silberst@google.com> Merge "Fix checkstyle issues with ScanDetailCache" into mm-wireless-dev
am: 5ca7933b04

* commit '5ca7933b040e22b741cc75b894823cc02cbc5816':
Fix checkstyle issues with ScanDetailCache
5ca7933b040e22b741cc75b894823cc02cbc5816 29-Feb-2016 Rebecca Silberstein <silberst@google.com> Merge "Fix checkstyle issues with ScanDetailCache" into mm-wireless-dev
b9601e3985540a776eff1d63355a721bea56aa4c 29-Feb-2016 Roshan Pius <rpius@google.com> WifiConfigManager: Cleanup instance names

Change some remaining configStore variables to configManager.

BUG: 27296463
Change-Id: Ib8c435edb056e5c11d9bc960b127b29f9aa8956d
om/android/server/wifi/FrameworkFacade.java
f9aabd71e9e60b80ea08bf92a3d3ebb28c7031df 29-Feb-2016 Paul Stewart <pstew@google.com> Revert "Appropriately fail EAP-SIM/AKA when SIM doesn't generate good response"

This reverts commit 5ebc35f19feab2755a13cf7d5acaeff4bbc78994.
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
550a2c8d8885c56b049dcf5369cf6bc9234543b7 29-Feb-2016 Paul Stewart <pstew@google.com> Revert "WifiStateMachine: Only respond once to multiple EAP-SIM challenges"

This reverts commit 71e35742798ca292d2fb727dd3a73e11b0f9b09d.

Change-Id: I4dcc9fadb14b50870e08b94f0fc45703e0ea7582
om/android/server/wifi/WifiStateMachine.java
33a835ab0060d25faa6852c84cda7bbbf2fa244a 29-Feb-2016 Erik Kline <ek@google.com> Use IpManager for HTTP proxy and TCP buffer sizes
am: a9b34f1390

* commit 'a9b34f1390c21af703606669b6548ef4d02d8231':
Use IpManager for HTTP proxy and TCP buffer sizes
a9b34f1390c21af703606669b6548ef4d02d8231 22-Feb-2016 Erik Kline <ek@google.com> Use IpManager for HTTP proxy and TCP buffer sizes

Bug: 26991160
Change-Id: I8ab4d5b4d6a1c05c094cf09dba81e99a972cd5ef
om/android/server/wifi/WifiStateMachine.java
6a229f790826761b79d5b71e01d7238299c81eff 27-Feb-2016 Roshan Pius <rpius@google.com> resolve merge conflicts of 2d65b9aaaa to nyc-dev

Change-Id: I52c055a8b26d01745d3378ef062faab9952ee393
c14fe5d3f6a84d8a0788956e15f9102a3aa354a6 25-Feb-2016 Rebecca Silberstein <silberst@google.com> Fix checkstyle issues with ScanDetailCache

ScanDetailCache was missing the header and documentation. Fix these
along with other style issues.

BUG=27361133

Change-Id: I0e289b1df02774cdfe7d787124dd5630156995bd
om/android/server/wifi/ScanDetailCache.java
cf608a89599ccd38b1471af2e2546638fc4d3142 26-Feb-2016 Roshan Pius <rpius@google.com> WifiConfigStore: Cleanup logging in the module

Adding some localLog debug messages in every method in the class.

BUG: 27375886
Change-Id: Iaf54c642b767c5052613fa8951e97ea1b0e98dfe
TEST: `runtest frameworks-wifi`
om/android/server/wifi/WifiConfigStore.java
dc61ad4fe8a84909a288af50a8b187c98e2194b6 26-Feb-2016 Roshan Pius <rpius@google.com> WifiConfigManager: Refactor remove network

Move the actual removal of network from database into a common utility
method which can be invoked in handleUserSwitch & removeNetwork.

This CL is part 1 of refactoring some repeating patterns in
WifiConfigManager.

BUG: 27364882
Change-Id: I374a31f4d5cf4d7ec480b9b40f26af33e1deb8b1
TEST: `runtest frameworks-wifi`
om/android/server/wifi/WifiConfigManager.java
2d65b9aaaa740ecf66bf4734c12aea3df88e352a 24-Feb-2016 Roshan Pius <rpius@google.com> WifiConfigStore: New WifiConfigStore (Part 2)

Integrate the new WifiConfigStore into WifiConfigManager class.
Most of the public methods that have been moved to ConfigStore have been
stubbed out in WifiConfigManager. Some of the methods have been changed
to make it consistent with the other methods.

The end goal of this CL to remove all WifiNative usages in
WifiConfigManager class.

Other related changes:
1. Changes in unit-tests to use mock wifiNative everywhere.
2. Change WifiConfigManager to accept an instance of KeyStore so that it
can be mocked out in unit-tests.

BUG=27299172
TEST:`mmma -j32 frameworks/opt/net/wifi/service/ && runtest
frameworks-wif`

Change-Id: I1656d81aec0ae3337bd794541b5a0bde9cddd48e
om/android/server/wifi/FrameworkFacade.java
om/android/server/wifi/WifiConfigManager.java
om/android/server/wifi/WifiStateMachine.java
54052854a7f1a9089bcd0877bf995d69b2e602ae 27-Feb-2016 Roshan Pius <rpius@google.com> Merge "WifiConfigStore: New WifiConfigStore (Part 1)" into mm-wireless-dev
am: f68805457e

* commit 'f68805457e24e9729629c0622f0b2763a4dbec1b':
WifiConfigStore: New WifiConfigStore (Part 1)
f68805457e24e9729629c0622f0b2763a4dbec1b 27-Feb-2016 Roshan Pius <rpius@google.com> Merge "WifiConfigStore: New WifiConfigStore (Part 1)" into mm-wireless-dev
e812d55a5329a42726f2e257c0f16a29c2a451dd 24-Feb-2016 Roshan Pius <rpius@google.com> WifiConfigStore: New WifiConfigStore (Part 1)

This is part 1 of creating the new WifiConfigStore class.

Trying to move parts of WifiConfigManager that deal with only
saving/loading wifi configurations from wpa_supplicant into a separate
class. Some of the methods are direct copies of the methods in
WifiConfigManager, but there are others which needed some modifications.
Tried to keep the new class to only contain direct interactions with
supplicant, but there are a some dependencies which needed to pulled
in along with those like:
1. Keystore interactions for enterprise networks.
2. Certificate migration

Will put up a follow-up CL for integrating this class into
WifiConfigManager.

BUG=27299172
Change-Id: I3e4527a310e0d39202c9ae9433e9a5a891443eef
TEST:`mmma -j32 frameworks/opt/net/wifi/service/`
om/android/server/wifi/WifiConfigStore.java
7bbcebafd698aee1b18062f9b2120c70c1fc6c47 26-Feb-2016 Mitchell Wills <mwills@google.com> Merge "Remove a bunch of dead wifi code" into mm-wireless-dev
am: 2691cf8a53

* commit '2691cf8a53d13c47eccf71e9c16c3cb9ef35af27':
Remove a bunch of dead wifi code
2691cf8a53d13c47eccf71e9c16c3cb9ef35af27 26-Feb-2016 Mitchell Wills <mwills@google.com> Merge "Remove a bunch of dead wifi code" into mm-wireless-dev
52da3dd6345bb068b0f0ec8fd6a749b2ee977d89 26-Feb-2016 Glen Kuhne <kuh@google.com> Merge "Add makeWifiConfigManager() to FacadeFramework" into mm-wireless-dev
am: 2bdcccb7ba

* commit '2bdcccb7badf35e9e00ea0b3b8e315f3f77af86a':
Add makeWifiConfigManager() to FacadeFramework
2bdcccb7badf35e9e00ea0b3b8e315f3f77af86a 26-Feb-2016 Glen Kuhne <kuh@google.com> Merge "Add makeWifiConfigManager() to FacadeFramework" into mm-wireless-dev
590b0d9b7879a4d7f24a057603ac82f30aff80f4 26-Feb-2016 Rebecca Silberstein <silberst@google.com> Merge "checkstyle fixes for ScanDetail" into mm-wireless-dev
am: 1fe5d7fc41

* commit '1fe5d7fc417c0861572e09644ddd4437dbc02069':
checkstyle fixes for ScanDetail
1fe5d7fc417c0861572e09644ddd4437dbc02069 26-Feb-2016 Rebecca Silberstein <silberst@google.com> Merge "checkstyle fixes for ScanDetail" into mm-wireless-dev
d8801e6ae46f95b2adb6e374c96b6b5d7ca64879 26-Feb-2016 Randy Pan <zpan@google.com> Correct WifiQualifiedNetworkSelection file name
am: 2177731ae0

* commit '2177731ae0a49be7dd66fd05dfb0ca73831b062c':
Correct WifiQualifiedNetworkSelection file name
8f852de7a8f081aff36bc9896781b270ca88d0e8 25-Feb-2016 Glen Kuhne <kuh@google.com> Add makeWifiConfigManager() to FacadeFramework

Added a function to FacadeFramework to make WifiConfigManager, replaced
the constructor in WifiConfigManager unit tests with this function.

BUG=27359698

Change-Id: Id9c0e6757244527e7f5fe7143687a32dd8d96c58
om/android/server/wifi/FrameworkFacade.java
om/android/server/wifi/WifiStateMachine.java
96cbf09d2430d0f1dc4a06bb62263c56469d63f2 26-Feb-2016 Sharvil Nanavati <sharvil@google.com> DO NOT MERGE ANYWHERE Make sure WiFi country code gets set properly.

The current logic forces the country code to be set if it has never
been *attempted* to be set before or if a new country code is being set.
However, it doesn't handle the case where setting the country code with
the driver fails.

This change always forces the country code to be set if it has never
been set for, taking into account potential failures coming back
from the native layer.

Bug: 25208308
Change-Id: Ie0f03e9a16a0f681b2977f4ee19af9339281a9c0
om/android/server/wifi/WifiStateMachine.java
44b562e47ee1cb4b5ce8b64b2cb7c0adc9b71d98 26-Feb-2016 Glen Kuhne <kuh@google.com> Merge "WifiNetworkHistory log level lowering" into mm-wireless-dev
am: 01dd88cf30

* commit '01dd88cf3004bbb9e3b6fd2257814e11d617a06d':
WifiNetworkHistory log level lowering
62681bff4b0c7eadf35546f6e6f35a19268e87a3 26-Feb-2016 Glen Kuhne <kuh@google.com> WifiMetric ConnectionEvent logging refactor
am: 4dead162c5

* commit '4dead162c5336443e9d7b3deae5eb26b07d39254':
WifiMetric ConnectionEvent logging refactor
2af03130d7f85823223b8591dc52858d851b301d 24-Feb-2016 Mitchell Wills <mwills@google.com> Remove a bunch of dead wifi code

Bug: 26907933

Change-Id: I3398b9bc9a2c915319ac4533b402ba400588f6e8
om/android/server/wifi/ScanDetail.java
om/android/server/wifi/SupplicantStateTracker.java
om/android/server/wifi/SupplicantWifiScannerImpl.java
om/android/server/wifi/WifiConfigManager.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/WifiTrafficPoller.java
om/android/server/wifi/hotspot2/SupplicantBridge.java
om/android/server/wifi/p2p/WifiP2pServiceImpl.java
b3c9b82f86637a6bc0a9e442ee759bd4eb5d8ad0 26-Feb-2016 Rebecca Silberstein <silberst@google.com> checkstyle fixes for ScanDetail

Fix issues flagged by checkstyle.

BUG=27363592

Change-Id: Iddd584cb780b806f1bef1d56b58b97e8e8dfbd8c
om/android/server/wifi/ScanDetail.java
2177731ae0a49be7dd66fd05dfb0ca73831b062c 26-Feb-2016 Randy Pan <zpan@google.com> Correct WifiQualifiedNetworkSelection file name

Rename WifiQualifiedNetworkSelection to
WifiQualifiedNetworkSelector to be consistent with the class
name.

Bug: 27296738
Change-Id: I48d21b1361cc2331b09cab84282eb47017be7f23
om/android/server/wifi/WifiQualifiedNetworkSelection.java
om/android/server/wifi/WifiQualifiedNetworkSelector.java
01dd88cf3004bbb9e3b6fd2257814e11d617a06d 25-Feb-2016 Glen Kuhne <kuh@google.com> Merge "WifiNetworkHistory log level lowering" into mm-wireless-dev
4dead162c5336443e9d7b3deae5eb26b07d39254 19-Feb-2016 Glen Kuhne <kuh@google.com> WifiMetric ConnectionEvent logging refactor

Modified the placement of start & end-ConnectionEvent() calls in
WifiStateMachine and the Roam Types they use, to more accurately describe
the types of connection events that are occuring.
Improved the human readability of metrics when as part of 'dumpsys
wifi'.

BUG=25691077
Change-Id: Ia8bd8415cab0feec476e012fd1b0bfa358e35e52
om/android/server/wifi/WifiMetrics.java
om/android/server/wifi/WifiStateMachine.java
0e38762759db5c27d7dcf4ebbd72775542606db2 25-Feb-2016 Randy Pan <zpan@google.com> Merge "Retire ScanResult.autoJoinStatus" into mm-wireless-dev
am: 7925cfb0de

* commit '7925cfb0de40a8e7aba97bf1cff1f5da75fab987':
Retire ScanResult.autoJoinStatus
7925cfb0de40a8e7aba97bf1cff1f5da75fab987 25-Feb-2016 Randy Pan <zpan@google.com> Merge "Retire ScanResult.autoJoinStatus" into mm-wireless-dev
f3ceffe27f1f8c37e85746bf5166d2e881cada8d 25-Feb-2016 Randy Pan <zpan@google.com> Merge "Delete auto join config" into mm-wireless-dev
am: acdde5816c

* commit 'acdde5816c1a4d76cfc49c2eb5bfa8410d377558':
Delete auto join config
acdde5816c1a4d76cfc49c2eb5bfa8410d377558 25-Feb-2016 Randy Pan <zpan@google.com> Merge "Delete auto join config" into mm-wireless-dev
71e35742798ca292d2fb727dd3a73e11b0f9b09d 18-Feb-2016 Paul Stewart <pstew@google.com> WifiStateMachine: Only respond once to multiple EAP-SIM challenges

The commit in 5ebc35f19feab2755a13cf7d5acaeff4bbc78994 made an
attempt to fail the EAPOL process due to intermediate failures
with TelephonyManager. It's not clear how well that worked,
but it's clear from inspection that when multiple challenges
are supplied that the code then sent multiple simAuthResponse
messages -- one per challenge. This is clearly wrong.

This CL refactors the code to clearly separate the function
that generates the complete response string so it can be tested,
and leaves the handleGsmAuthRequest() method to interact with
mWifiNative in a hopefully more readable manner.

BUG: 26758602
Change-Id: Ibf8f85893e4c18195eb08114b5169dcff05dc045
TEST: New unit test for the getGsmSimAuthResponse method
om/android/server/wifi/WifiStateMachine.java
21a0eaca95a54bcd5878a7e36b2e25b64f4825f8 25-Feb-2016 Rebecca Silberstein <silberst@google.com> Merge "Move calculateWifiScore out of WSM and create new WifiScoreReport class" into mm-wireless-dev
am: 29fc49efc5

* commit '29fc49efc59d5ff061439f4c119931ba6deb55e6':
Move calculateWifiScore out of WSM and create new WifiScoreReport class
29fc49efc59d5ff061439f4c119931ba6deb55e6 25-Feb-2016 Rebecca Silberstein <silberst@google.com> Merge "Move calculateWifiScore out of WSM and create new WifiScoreReport class" into mm-wireless-dev
f99504e885ef365adb0c54263dcf7fecfedf9f1c 25-Feb-2016 Glen Kuhne <kuh@google.com> WifiNetworkHistory log level lowering

Lowered the log level of a few chatty log commands spamming Error
messages.

BUG=27294533

Change-Id: I668f0e96dcd59e2a61a5028f0402e511478d94ef
om/android/server/wifi/WifiNetworkHistory.java
7f18bae3a6e6a6d83fb060995cbdd2ed62df275a 25-Feb-2016 Roshan Pius <rpius@google.com> Merge "WifiConfigManager: Add SupplicantBridge callbacks" into mm-wireless-dev
am: 1f8a9c2152

* commit '1f8a9c21526f7cfd518fdcfa1e9ff42a1253f38d':
WifiConfigManager: Add SupplicantBridge callbacks
1f8a9c21526f7cfd518fdcfa1e9ff42a1253f38d 25-Feb-2016 Roshan Pius <rpius@google.com> Merge "WifiConfigManager: Add SupplicantBridge callbacks" into mm-wireless-dev
23fe1c9201d6e734f3b4f727144a91c3a20a2627 24-Feb-2016 Randy Pan <zpan@google.com> Retire ScanResult.autoJoinStatus

This attribute is no longer in use.

Bug: 27340037
Change-Id: Id65230daf2c1b7085568f65fe3018cef54869fd0
om/android/server/wifi/ScanDetailCache.java
om/android/server/wifi/WifiConfigManager.java
om/android/server/wifi/WifiNetworkHistory.java
om/android/server/wifi/WifiStateMachine.java
b7224f0075035f1d5957e156f5666ac78d597e2c 24-Feb-2016 Randy Pan <zpan@google.com> Delete auto join config

Remove obsoleted auto join configuration. The configuration file
is no longer in use.

Bug: 27312337
Change-Id: I3b1945f56cd09809e84a7fe5c0b7e4a976fb35d5
om/android/server/wifi/WifiConfigManager.java
25fccb255c269bf0c59fa776623a0002cc24a211 23-Feb-2016 Rebecca Silberstein <silberst@google.com> Move calculateWifiScore out of WSM and create new WifiScoreReport class

Pulled the calculation for a Wifi Score out of WSM and created a class to
hold score related objects. This new class holds the score report
string along with the badLinkspeedcount int. The calculateWifiScore
function is now a static method in the new WifiScoreReport class. Added
the ScoreReport to a couple of places where related counters are also
cleaned up.

This CL also cleans up some style issues and converts hardcoded values
to static variables for the class. No functionality changes were
introduced into the score calculation.

BUG=27312068

Change-Id: I167ecbef6e365923a687928235beecf3ac1b66f1
om/android/server/wifi/WifiScoreReport.java
om/android/server/wifi/WifiStateMachine.java
9456d35ba321fa5e9cd629e416bb8bb78e8166e4 25-Feb-2016 Paul Stewart <pstew@google.com> Merge "WifiNotificationController: Ignore "SCANNING" network state" into mm-wireless-dev
am: e08c8038a4

* commit 'e08c8038a432eb68a3493abdfa7e69d92bad3b80':
WifiNotificationController: Ignore "SCANNING" network state
e08c8038a432eb68a3493abdfa7e69d92bad3b80 25-Feb-2016 Paul Stewart <pstew@google.com> Merge "WifiNotificationController: Ignore "SCANNING" network state" into mm-wireless-dev
a73697c129a759ab403dfc6929aadfa71ea52141 25-Feb-2016 Peter Qiu <zqiu@google.com> Merge "Use a wrapper for BackupManager" into mm-wireless-dev
am: ac90154934

* commit 'ac90154934c0daf4e69a6d38344b82eea8dee91b':
Use a wrapper for BackupManager
ac90154934c0daf4e69a6d38344b82eea8dee91b 25-Feb-2016 Peter Qiu <zqiu@google.com> Merge "Use a wrapper for BackupManager" into mm-wireless-dev
a09a7fd5125abc1df067201bcb604d95e9265644 24-Feb-2016 Peter Qiu <zqiu@google.com> Merge "WifiController: handle WiFi toggle events in ApEnabledState" into mm-wireless-dev
am: 303373e71a

* commit '303373e71a6f4474b22cc21a3e4282b563cf2a93':
WifiController: handle WiFi toggle events in ApEnabledState
750c6962838af6ab7ba034c80f2d325df7e74cbe 23-Feb-2016 Peter Qiu <zqiu@google.com> Use a wrapper for BackupManager

This avoids invoking calls to BackupManager/BackupManagerService during
unit test.

Bug:27296824
TEST=runtest frameworks-wifi

Change-Id: I3d4fe1b4d2fdabe079e65242099f4dd4ed4ab7f4
om/android/server/wifi/BackupManagerProxy.java
om/android/server/wifi/FrameworkFacade.java
om/android/server/wifi/WifiApConfigStore.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
303373e71a6f4474b22cc21a3e4282b563cf2a93 24-Feb-2016 Peter Qiu <zqiu@google.com> Merge "WifiController: handle WiFi toggle events in ApEnabledState" into mm-wireless-dev
fbeef71cf8251d4537f1ba65484f39d78c14b81b 24-Feb-2016 Etan Cohen <etancohen@google.com> Merge changes I9921d663,Ib9d42823,Ia0be2203,I09b28da3 into mm-wireless-dev

* changes:
[NAN] Increase coverage [DO NOT MERGE]
[NAN] Enable testing of apps faking client IDs [DO NOT MERGE]
[NAN] Add code to clean-up after all (even No-Op) transactions [DO NOT MERGE]
[NAN] Replace crashing on illegal state to failure response/ignore [DO NOT MERGE]
5c0a79c305877c8c96df69035eed38c3650dfa5b 24-Feb-2016 Etan Cohen <etancohen@google.com> [NAN] Enable testing of apps faking client IDs [DO NOT MERGE]

Enable mocking of UIDs. Enables testing of multiple apps (each with
its own UID) trying to access 'invalid' client IDs - i.e. client IDs
which were created by different UIDs.

Bug: 27335234
Change-Id: Ib9d4282378d144a51d83229ed4d924a49375fd11
om/android/server/wifi/nan/WifiNanServiceImpl.java
4f1887493430b6b61126f233f3de54201b363145 24-Feb-2016 Etan Cohen <etancohen@google.com> [NAN] Add code to clean-up after all (even No-Op) transactions [DO NOT MERGE]

Some transactions have no app-facing callbacks - e.g. cancelling a publish
or subscribe (app assumes it succeeds). In such cases still need to clean
up the internal transaction tracking state. Add No-Op callback in state
manager to perform that clean-up.

Add tests for above as well as for unknown transaction callback: i.e.
response codes from HAL which aren't "known" (not handled, possibly
yet).

Bug: 27334871
Change-Id: Ia0be220310689c0e06030b71236d955a557b7a27
om/android/server/wifi/nan/WifiNanNative.java
om/android/server/wifi/nan/WifiNanStateManager.java
e903e3cb1e7a41fa20306dc3bd1f3518c51a8a86 24-Feb-2016 Etan Cohen <etancohen@google.com> [NAN] Replace crashing on illegal state to failure response/ignore [DO NOT MERGE]

Do not crash NAN service (i.e. system service) when illegal state or illegal
inputs are detected (especially inputs - since can be created by bad/malicious
app). Instead either ignore or respond with failure callbacks.

Bug: 27334919
Change-Id: I09b28da3bea396633dbe76f729c276f9e5620c5d
om/android/server/wifi/nan/WifiNanSessionState.java
om/android/server/wifi/nan/WifiNanStateManager.java
3d1baff308fd209648a4d3cf5c02a8bfd1a98a52 24-Feb-2016 Roshan Pius <rpius@google.com> WifiConfigManager: Add SupplicantBridge callbacks

Create a new SupplicantBridge callbacks instead of passing
WifiConfigManager instance to SupplicantBridge.

BUG: 27325803
Change-Id: Id6d61af6e2758492f6779da4487a8238857bd124
om/android/server/wifi/WifiConfigManager.java
om/android/server/wifi/hotspot2/SupplicantBridge.java
2ef14db559ceee38b4e9d86eab8196cea4749d76 24-Feb-2016 Glen Kuhne <kuh@google.com> Merge "WifiConfigStore Refactor read&write NetworkHistory" into mm-wireless-dev
am: 5eb49f6169

* commit '5eb49f61695e122d5c9c3a1b89a0ce1a6474f195':
WifiConfigStore Refactor read&write NetworkHistory
5eb49f61695e122d5c9c3a1b89a0ce1a6474f195 24-Feb-2016 Glen Kuhne <kuh@google.com> Merge "WifiConfigStore Refactor read&write NetworkHistory" into mm-wireless-dev
c1996c9f9334d0da0e931acf92eaf7e936de6e40 24-Feb-2016 Mitchell Wills <mwills@google.com> Merge "Replace WifiChannelHelper with ChannelHelper implementations" into mm-wireless-dev
am: b1a4d1c1bb

* commit 'b1a4d1c1bb210c702d20006517b74b6375480313':
Replace WifiChannelHelper with ChannelHelper implementations
df21baf692e4906c26ce5ab38fa24904787807b5 24-Feb-2016 Peter Qiu <zqiu@google.com> WifiController: handle WiFi toggle events in ApEnabledState

This allows the WiFi toggle event to be handled when Soft AP
is enabled, which will stop the soft AP and transition to
StaEnabledState when soft AP is stopped.

Bug: 27325949
TEST=runtest frameworks-wifi
TEST=Manual Test
Manual Tests
1. Enable WiFi (connected to "GoogleGuest"), enable WiFi hotspot,
disable WiFi hotspot (toggle Hotspot), verify WiFi is enabled
and reconnected to "GoogleGuest".
2. Enable WiFi (connected to "GoogleGuest"), disable WiFi, enable
WiFi hotspot, toggle WiFi (which will enable WiFi), verify WiFi
is enabled and reconnected to "GoogleGuest".
3. Enable WiFi (connected to "GoogleGuest"), enable WiFi hotspot,
toggle WiFi (which will enable WiFi), verify WiFi is enabled
and reconnected to "GoogleGuest".

Change-Id: I3561431f41612e2a015082b2b80b72bf737b879d
om/android/server/wifi/WifiController.java
b1a4d1c1bb210c702d20006517b74b6375480313 24-Feb-2016 Mitchell Wills <mwills@google.com> Merge "Replace WifiChannelHelper with ChannelHelper implementations" into mm-wireless-dev
c485ebf64d1049d17db8108b85653f53fcdc8949 23-Feb-2016 Glen Kuhne <kuh@google.com> WifiConfigStore Refactor read&write NetworkHistory

Created a new helper class: WifiNetworkHistory
Moved readNetworkHistory() and writeKnownNetworkHistory() from
WifiConfigStore into this class, replacing them with calls to the
helper.

BUG=27294533
Change-Id: I10d43e3fd37e251d1845ef726fea0faf136d9626
om/android/server/wifi/WifiConfigManager.java
om/android/server/wifi/WifiNetworkHistory.java
250e70cb113e75ac9b24b09bbf176804d37755d8 09-Feb-2016 Paul Stewart <pstew@google.com> WifiNotificationController: Ignore "SCANNING" network state

While the system is disconnected and does screen-on scanning,
it is legitimate to see temporary state changes to the "SCANNING"
state then back to "DISCONNECTED". The current implementation
of WifiNotificationController resets its scan counter during
these transitions, and therefore never displays the "WiFi
Networks Avaialable" notification. This CL fixes this problem
by separately tracking NetworkInfo.DetailedState and ignoring both
"SCANNING" and the no-op state changes that will happen as a
result.

BUG=26076402
TEST=New unit test included in CL
TEST=Repeat bug reproduction steps

Change-Id: I5e6049edb767e4f67be1ddb31023a28043db53d5
om/android/server/wifi/WifiNotificationController.java
om/android/server/wifi/WifiServiceImpl.java
1abd49f3445df5d221319a1571c1a0dda3ecab79 24-Feb-2016 Paul Stewart <pstew@google.com> Merge "WifiStateMachine: Only respond once to multiple EAP-SIM challenges" into mm-wireless-dev
am: af8f9541d2

* commit 'af8f9541d248f7e1ca8232774de1310838ef4b0a':
WifiStateMachine: Only respond once to multiple EAP-SIM challenges
af8f9541d248f7e1ca8232774de1310838ef4b0a 24-Feb-2016 Paul Stewart <pstew@google.com> Merge "WifiStateMachine: Only respond once to multiple EAP-SIM challenges" into mm-wireless-dev
a462153f4e7edc4de7769b1caa9c8b0fee912c90 24-Feb-2016 Erik Kline <ek@google.com> Merge "Unbreak framework roaming" into mm-wireless-dev
am: 30dda83595

* commit '30dda8359520657589f880a71b745a522c5024bb':
Unbreak framework roaming
30dda8359520657589f880a71b745a522c5024bb 24-Feb-2016 Erik Kline <ek@google.com> Merge "Unbreak framework roaming" into mm-wireless-dev
87af62a5bfe014ff3e62a14d90e168741636da0c 24-Feb-2016 Roshan Pius <rpius@google.com> Merge "Disable all networks in supplicant" into mm-wireless-dev
am: e2dc63bb99

* commit 'e2dc63bb990eed0f1909f8f38cbfb0d2f4bc2a92':
Disable all networks in supplicant
e2dc63bb990eed0f1909f8f38cbfb0d2f4bc2a92 24-Feb-2016 Roshan Pius <rpius@google.com> Merge "Disable all networks in supplicant" into mm-wireless-dev
bcbc449d47124ec8f73a38ffe228b97bd9b493bf 23-Feb-2016 Erik Kline <ek@google.com> Unbreak framework roaming

Framework roams could transition to ObtainingIpState in which we
no longer send DHCPv4 RENEWs. Owing to a bug we still started the
watchdog timer which would just fire 40 seconds later.

Instead, don't transition to ObtainingIpState except when actually
wanting to obtain IP configuration (gasp!). We transition instead
back to ConnectedState and let IpReachabilityMonitor signal us if
we need to transition further.

Bug: 26991160
Change-Id: I535611aee542cf3dcebf57e618fcc73806797aac
om/android/server/wifi/WifiStateMachine.java
7e3e85327ca82a83de84b4750e793f2e3d1b3bfc 06-Feb-2016 Mitchell Wills <mwills@google.com> Replace WifiChannelHelper with ChannelHelper implementations

Change-Id: I20c266825e3b0b0566d6d2939ca2d0c67d213d78
om/android/server/wifi/HalWifiScannerImpl.java
om/android/server/wifi/MultiClientScheduler.java
om/android/server/wifi/SupplicantWifiScannerImpl.java
om/android/server/wifi/WifiChannelHelper.java
om/android/server/wifi/WifiScannerImpl.java
om/android/server/wifi/WifiScanningServiceImpl.java
om/android/server/wifi/scanner/KnownBandsChannelHelper.java
02e62bfb297d14643e71f65ded7d08fab3ccbfb5 23-Feb-2016 Roshan Pius <rpius@google.com> resolve merge conflicts of f3e16ca77e to nyc-dev

Change-Id: I083eec242286cb631e0655621ad4fa7abcc239ba
9d7489491984e86915b2cf4fac38a882de1c8cdb 09-Feb-2016 Roshan Pius <rpius@google.com> Disable all networks in supplicant

Temporary changes to test if we can disable all the networks in
supplicant conf file except the one we want to connect to.

Changes:
1. Remove all existing native enableNetwork invocations and replace
it with a single selectNetwork call in |WifiConfigStore.selectNetwork|.
selectNetwork enables the provided network and disables all others in
wpa_supplicant.
2. Enable all networks in wpa_supplicant before enabling PNO. These will
be disabled when we come out of PNO and decide to conneect to one of
them via selectNetwork.
3. Save the network status in networkHistory.txt and ignore the status
stored in wpa_supplicant.conf.
4. Some other cleanups:
a. Remove |enableNetworkWithoutBroadcast| definition/usages and
replace with |selectNetworkWithoutBroadcast|.
b. Add enableAllNetworksNative/disableAllNetworksNative methods to
just enable the network in wpa_supplicant.
c. Move all wpa_supplicant network enable/disable to a common API.
d. Fixed all the unit-test expectations.

BUG:26984166
TEST: `mmma frameworks/opt/net/wifi/tests && runtest frameworks-wifi`

Change-Id: Ib5a089f054557071ece6be25aad03b6458c0217c
om/android/server/wifi/WifiConfigManager.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
3cb977400be8d10f06f44dd9b46da70baf2a037a 18-Feb-2016 Etan Cohen <etancohen@google.com> [NAN] API cleanup - rename FLAGS. [DO NOT MERGE]

Per API guidelines - non-overlapping constants can be (should be)
named with "FLAG".

Bug: 27122760
Change-Id: I090c5c6090494240843bf91ab69b6c75072ee2b9
om/android/server/wifi/nan/WifiNanClientState.java
om/android/server/wifi/nan/WifiNanSessionState.java
f3e16ca77eb3fce92ef9040de577d64103cb8b7d 23-Feb-2016 Roshan Pius <rpius@google.com> Merge "Modify the wake reasons data structure(1/2)" into mm-wireless-dev
434a2a9c1147f8ebdebe434e04e3374d107d80b8 23-Feb-2016 Wei Wang <weiwa@google.com> Merge "Add test case for duplicate listeners in WifiScanner." into mm-wireless-dev
am: 384dc1ae37

* commit '384dc1ae37b7087ed2f15442715ca9f50dd3567c':
Add test case for duplicate listeners in WifiScanner.
384dc1ae37b7087ed2f15442715ca9f50dd3567c 23-Feb-2016 Wei Wang <weiwa@google.com> Merge "Add test case for duplicate listeners in WifiScanner." into mm-wireless-dev
767b3b51641ea9bb5b1b54c0757a3a54824b7f3c 23-Feb-2016 Roshan Pius <rpius@google.com> Rename WifiConfigStore to WifiConfigManager
am: c2a0ff06d5

* commit 'c2a0ff06d58e1cfb9b69fa5b6a8fef5929812f27':
Rename WifiConfigStore to WifiConfigManager
d0be2d83c247d461b3bcee7343b035f1fc92396e 23-Feb-2016 Roshan Pius <rpius@google.com> Merge "WifiConfigStore: Remove IpConfigStore inheritance" into mm-wireless-dev
am: ba035ceba4

* commit 'ba035ceba49da6c3fa4e9407900655ab5cb5e006':
WifiConfigStore: Remove IpConfigStore inheritance
c2a0ff06d58e1cfb9b69fa5b6a8fef5929812f27 22-Feb-2016 Roshan Pius <rpius@google.com> Rename WifiConfigStore to WifiConfigManager

Rename WifiConfigStore class to WifiConfigManager and replace all
existing occurences of WifiConfigStore.
This is in preparation of refactoring WifiConfigStore into a
separate class which will only deal with storing/reading configurations
from a perisistent database.

BUG: 27296463
Change-Id: Ib4c4bd3bdf3fa28771a646e1f3d244f73b690d5e
TEST: Ran unit-tests
om/android/server/wifi/FrameworkFacade.java
om/android/server/wifi/SupplicantStateTracker.java
om/android/server/wifi/WifiConfigManager.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiQualifiedNetworkSelection.java
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/hotspot2/SupplicantBridge.java
ba035ceba49da6c3fa4e9407900655ab5cb5e006 23-Feb-2016 Roshan Pius <rpius@google.com> Merge "WifiConfigStore: Remove IpConfigStore inheritance" into mm-wireless-dev
e893eef97a7bf3efcfba3a0dbc10832ad7f6add1 23-Feb-2016 Jan Nordqvist <jannq@google.com> Merge "Downloaded configuration fails to delete after framework changes." into mm-wireless-dev
am: 3037741c91

* commit '3037741c919b3979a4faf0f8504b7b347f6199d9':
Downloaded configuration fails to delete after framework changes.
3037741c919b3979a4faf0f8504b7b347f6199d9 23-Feb-2016 Jan Nordqvist <jannq@google.com> Merge "Downloaded configuration fails to delete after framework changes." into mm-wireless-dev
eb47908e92e36c4ea24fe25b004f71476c19f4d2 23-Feb-2016 Jan Nordqvist <jannq@google.com> Merge "Exclude implicit MO creation when creating Hotspot 2.0 release 2 networks." into mm-wireless-dev
am: bbefecdee0

* commit 'bbefecdee0f49fd99407d64d1d0558a075c612c5':
Exclude implicit MO creation when creating Hotspot 2.0 release 2 networks.
bbefecdee0f49fd99407d64d1d0558a075c612c5 23-Feb-2016 Jan Nordqvist <jannq@google.com> Merge "Exclude implicit MO creation when creating Hotspot 2.0 release 2 networks." into mm-wireless-dev
de509a74735519a9efaa5e5d8d86728c084b804d 23-Feb-2016 Jan Nordqvist <jannq@google.com> Downloaded configuration fails to delete after framework changes.

Bug=27243862

Change-Id: Ic7fa19657ea31ff8d8398862307ff978c1db5dfb
om/android/server/wifi/configparse/ConfigBuilder.java
c1bc5a14b94276421f741eaebb54daa8e63e4a05 22-Feb-2016 Roshan Pius <rpius@google.com> WifiConfigStore: Remove IpConfigStore inheritance

Move IpconfigStore instance to be a member of the WifiConfigStore and
create a new DelayedDiskWriter for writing the other configurations.

BUG: 27293150
Change-Id: I76654d49848c417599996b0a8b510ff2b04a3d4a
TEST: `runtest frameworks-wifi`
om/android/server/wifi/WifiConfigStore.java
549d7a1dbbee16585af667d3efe1a6fdc6c7b9c6 22-Feb-2016 Peter Qiu <zqiu@google.com> Merge "Integrate SoftApManager to WifiStateMachine" into mm-wireless-dev
am: bc4548f2f5

* commit 'bc4548f2f5bc9cb5f72c405454a480ccb470b86e':
Integrate SoftApManager to WifiStateMachine
bc4548f2f5bc9cb5f72c405454a480ccb470b86e 22-Feb-2016 Peter Qiu <zqiu@google.com> Merge "Integrate SoftApManager to WifiStateMachine" into mm-wireless-dev
cb3aa74733cef68dd30d5e6aa8f252cd749b4143 22-Feb-2016 Jan Nordqvist <jannq@google.com> Exclude implicit MO creation when creating Hotspot 2.0 release 2 networks.

Bug=27294473

Change-Id: I8f13cd49e8b2d17e9451625ab1b01dd16c057f2e
om/android/server/wifi/WifiConfigStore.java
ec1690a8364f678ba8ca4472c8e031d482895533 20-Feb-2016 Rebecca Silberstein <silberst@google.com> Merge "Add Looper param to WifiStateMachine constructor and AutoDispatch" into mm-wireless-dev
am: 75a3fd9a4d

* commit '75a3fd9a4d37dd6ba1a0ac3e174673e3b80795d1':
Add Looper param to WifiStateMachine constructor and AutoDispatch
75a3fd9a4d37dd6ba1a0ac3e174673e3b80795d1 20-Feb-2016 Rebecca Silberstein <silberst@google.com> Merge "Add Looper param to WifiStateMachine constructor and AutoDispatch" into mm-wireless-dev
d0846fa841b604ccb969c54b45367fa2bececf83 16-Feb-2016 Rebecca Silberstein <silberst@google.com> Add Looper param to WifiStateMachine constructor and AutoDispatch

Add Looper to the WifiStateMachine constructor. This allows unittests to
pass a MockLooper and control how messages are dispatched. This change
allows the wait() calls to be removed from the WifiStateMachineTest
tests and will bring stability to test runs. This change will also
reduce test run time.

Due to the blocking calls in WifiStateMachine that are expecting a
response, also implement AutoDispatch functionality for MockLooper.
This functionality is implemented by creating a thread that calls
MockLooper.dispatchAll when messages are available. Once at least one
message is dispatched, the thread will exit. The thread will attempt a
limited number of times and log an error if no messages are dispatched.

BUG=26943243

Change-Id: Ia892303e04d18c56d7f1d896db6098e7c3bd9607
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
9aa6d49161f0be66fc89b9b14f7f478e9af407e1 19-Feb-2016 Roshan Pius <rpius@google.com> Merge "WifiConfigStore: API for fetching PNO network list" into mm-wireless-dev
am: d9f96a5827

* commit 'd9f96a58271313deefb135b0606429953157a5f9':
WifiConfigStore: API for fetching PNO network list
d9f96a58271313deefb135b0606429953157a5f9 19-Feb-2016 Roshan Pius <rpius@google.com> Merge "WifiConfigStore: API for fetching PNO network list" into mm-wireless-dev
9a2eb2015d22ee0901c6bce616963643ab3e9e08 19-Feb-2016 Glen Kuhne <kuh@google.com> Merge "InformationElementUtil TIM element parser" into mm-wireless-dev
am: 55b5d3d0e8

* commit '55b5d3d0e887313ece26bad8ebf8f8c25ac66e3f':
InformationElementUtil TIM element parser
55b5d3d0e887313ece26bad8ebf8f8c25ac66e3f 19-Feb-2016 Glen Kuhne <kuh@google.com> Merge "InformationElementUtil TIM element parser" into mm-wireless-dev
947e55415eab3989f2f5cede0c03745cf9268309 09-Feb-2016 Glen Kuhne <kuh@google.com> InformationElementUtil TIM element parser

Added a parser to InformationElementUtil for the beacon frame Traffic
Indication Map element. Only current use for this is to get DTIM
interval for metrics.

BUG=25691077
Change-Id: I1aba8ca658e446ae5697b6d749687b0dd24f790d
om/android/server/wifi/WifiMetrics.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/hotspot2/NetworkDetail.java
om/android/server/wifi/util/InformationElementUtil.java
5c3c06082b24f9ff0d479e82a63b52220c86598b 12-Feb-2016 Roshan Pius <rpius@google.com> WifiConfigStore: API for fetching PNO network list

Modify the existing API for retrieving PNO network list to
differentiate the list for disconnected vs connected PNO scenarios.
The network sorting orders are different for each of these PNO
scenarios. Use different comparator objects to sort the network list for
the 2 scenarios.

Also, merging the existing ePNO network class (WifiPnoNetwork) with the
supplicant based PNO network class (PnoNetworkPriority). This allows the
Connectivity manager to use a single class for all types of PNO.

While there,
Remove dead code in WifiConfigStore (buildPnoList) which was written for
ePNO.

While there,
Add back the numAssociation counter increment because we're now using
it to sort PNO list.

BUG: 27151228
Change-Id: I6d48dab367a2106eef4f1d3f396f391c57a22339
TEST: Ran unit tests
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
d4f347f7de30834317dd1561dc806eccb1c4f277 17-Feb-2016 Peter Qiu <zqiu@google.com> Integrate SoftApManager to WifiStateMachine

Refactor WifiStateMachine to use SoftApManager for managing soft AP
instance. This consolidate all soft AP related states in WifiStateMachine
to a single SoftApState.

While there, fix number of existing issues in WifiController:
- fix a possible race condition in WifiController where it will
transition to a new state before AP is completely stopped. Currently it is
being worked around in WifiStateMachine by having the soft AP states defer
the commands that might be issued during this race window. This doesn't
really scale and not really clear to the reader. Fix it by only transition
out of ApEnabledState when AP is completely stopped.
- fix a bug in WifiController where it doesn't transition out of
ApEnabledState when AP is stopped internally (either tether notification
timed out or WiFi becomes untethered), results in WifiController and
WifiStateMachine being out of sync.
- fix couple unintentional fall through case statements.

Bug: 26876260
TEST=run frameworks-wifi test
TEST=run autotests

Change-Id: I1d12690b51265dacd087f22f601b7b0ea0a1082e
om/android/server/wifi/FrameworkFacade.java
om/android/server/wifi/WifiController.java
om/android/server/wifi/WifiStateMachine.java
047aee0ba277cb512db1c22605e9b73ccfc20374 19-Feb-2016 Peter Qiu <zqiu@google.com> Merge "Add SoftApManager class" into mm-wireless-dev
am: 5aecec3422

* commit '5aecec3422a573e09b5792edd587153c00748da1':
Add SoftApManager class
5aecec3422a573e09b5792edd587153c00748da1 19-Feb-2016 Peter Qiu <zqiu@google.com> Merge "Add SoftApManager class" into mm-wireless-dev
6bf6986d359556010638dfae332b585162f06520 18-Feb-2016 Roshan Pius <rpius@google.com> Modify the wake reasons data structure(1/2)

Changes in the android framework to use the modifed HAL API to
fetch the host wakeup reasons from the driver.

BUG: 26902794

Change-Id: Id14f8fa695ba3406392663b5d792309464a4b5bf
om/android/server/wifi/WifiNative.java
be6cb1df0c221f72d09fc0ab6f5c45b0949c9a88 18-Feb-2016 Paul Stewart <pstew@google.com> WifiStateMachine: Only respond once to multiple EAP-SIM challenges

The commit in 5ebc35f19feab2755a13cf7d5acaeff4bbc78994 made an
attempt to fail the EAPOL process due to intermediate failures
with TelephonyManager. It's not clear how well that worked,
but it's clear from inspection that when multiple challenges
are supplied that the code then sent multiple simAuthResponse
messages -- one per challenge. This is clearly wrong.

This CL refactors the code to clearly separate the function
that generates the complete response string so it can be tested,
and leaves the handleGsmAuthRequest() method to interact with
mWifiNative in a hopefully more readable manner.

BUG: 26758602
Change-Id: Ibf8f85893e4c18195eb08114b5169dcff05dc045
TEST: New unit test for the getGsmSimAuthResponse method
om/android/server/wifi/WifiStateMachine.java
0633c7b5996582ac2c10c5084cb11090080b07b0 19-Feb-2016 Paul Stewart <pstew@google.com> Refactor for accessor changes to WifiEnterpriseConfig [Re-Land]
am: 0fa719c770

* commit '0fa719c7706dc6e447d16543518d4ecb269b91d0':
Refactor for accessor changes to WifiEnterpriseConfig [Re-Land]
0fa719c7706dc6e447d16543518d4ecb269b91d0 16-Jan-2016 Paul Stewart <pstew@google.com> Refactor for accessor changes to WifiEnterpriseConfig [Re-Land]

WifiEnterpriseConfig has changed to provide more sane accessors.
Now, callers are not given blanket access to the internal fields
and need to pass an accessor object to either save or restore
wpa_supplicant configuration.

This CL also adds unit tests to validate the new behavior of EAP
and Phase 2 parameters to ensure that recent changes do not cause
any regressions.

Bug:26400915
Change-Id: I294d804b431e216071905b96c51e023ea424aaf5
om/android/server/wifi/WifiConfigStore.java
c3b22ef2e6bbccd048e1012160b75d14353ab894 17-Feb-2016 Wei Wang <weiwa@google.com> Add test case for duplicate listeners in WifiScanner.

Bug:26663377

Change-Id: I89c7936b215251c2afb20a49de1d03184e9b4b21
om/android/server/wifi/HalWifiScannerImpl.java
8f129e6c43893cddfcfb18804a543ace7fb983b3 19-Feb-2016 Lorenzo Colitti <lorenzo@google.com> Simplify smToString using MessageUtils.
am: eed7ed0f23

* commit 'eed7ed0f235d1124564d567178e485f0a5cda616':
Simplify smToString using MessageUtils.
eed7ed0f235d1124564d567178e485f0a5cda616 17-Feb-2016 Lorenzo Colitti <lorenzo@google.com> Simplify smToString using MessageUtils.

Change-Id: If7355bbf5295c55e97882dce55a07b607309e0f2
om/android/server/wifi/WifiStateMachine.java
7debc76f64763f2ff91236ca0f26b2257ea29cf8 19-Feb-2016 xin He <xinhe@google.com> Merge "Fix QNS bssid blacklist update" into mm-wireless-dev
am: 9f362510e1

* commit '9f362510e1070007c54b60ebfd9fbbe312017a9a':
Fix QNS bssid blacklist update
9f362510e1070007c54b60ebfd9fbbe312017a9a 19-Feb-2016 xin He <xinhe@google.com> Merge "Fix QNS bssid blacklist update" into mm-wireless-dev
676d8394860aa8fb0ed856f41bbd0bbe2c4727fc 18-Feb-2016 Etan Cohen <etancohen@google.com> [NAN] Renamed listeners to callback per API guidelines [DO NOT MERGE]

The interfaces had multiple functions and are hence callback
and not a listener.

Note: purely a rename operation.

Bug: 27122760
Change-Id: I6dcfe1f623ee730217b52b362819abf656583003
om/android/server/wifi/nan/WifiNanClientState.java
om/android/server/wifi/nan/WifiNanNative.java
om/android/server/wifi/nan/WifiNanServiceImpl.java
om/android/server/wifi/nan/WifiNanSessionState.java
om/android/server/wifi/nan/WifiNanStateManager.java
8f06198cafd0e52aebe2f050af0c1a3533270888 17-Feb-2016 Etan Cohen <etancohen@google.com> [NAN]: API update - consolidate Puslish|Subscribe Data+Subscribe -> Config [DO NOT MERGE]

Simplify configuration and consolidate structures whose difference
wasn't very clear.

Bug: 27122760
Change-Id: Ib24f6217e2124c2184506f2ce1407575f5d9baaa
om/android/server/wifi/nan/WifiNanNative.java
om/android/server/wifi/nan/WifiNanServiceImpl.java
om/android/server/wifi/nan/WifiNanSessionState.java
om/android/server/wifi/nan/WifiNanStateManager.java
4c618adccba43334df62ad7d2949138344c11f58 18-Feb-2016 xin He <xinhe@google.com> Fix QNS bssid blacklist update

The crash is due to delete map entries not through the
iterator's remove method when transverse the map. Removing
item will change the size of iterator and
java.util.ConcurrentModificationException will be thrown at
next iterator.next(). The correct way is to remove item through
the iterator's remove method.

BUG=27243032

Change-Id: Iede6efeafacaf8a33cce44f56e0c2b58e598e07e
om/android/server/wifi/WifiQualifiedNetworkSelection.java
e5b93fbfe451bc57c07b3f72191b52b6bd237d5b 09-Feb-2016 Peter Qiu <zqiu@google.com> Add SoftApManager class

The newly created class is responsible for managing soft AP
instance and tethering state transitions.

This class will be integrated to WifiStateMachine in an upcoming
CL, which will remove the existing soft AP and tethering related
code from WifiStateMachine.

Bug: 26876260
TEST=runtest frameworks-wifi

Change-Id: I25568649b8c9d18ce78019dac614bafb9c5a3448
om/android/server/wifi/SoftApManager.java
om/android/server/wifi/util/ApConfigUtil.java
c9783c72ce84ea8cc42f2c407824113019e59b11 17-Feb-2016 Etan Cohen <etancohen@google.com> NAN: Add client ID to support multiple NAN clients per UID. [DO NOT MERGE]

Allow multiple clients per UID - each with its own session namespace.
Effectively replace UID by client ID in the main state machine. The
mapping of new client IDs and their validation (as belonging to the
correct UID) is handled by the service front-end implementation.

Fix missing documentation to enable passing style checker.

Bug: 26962024
Change-Id: I963cc5940957953008035b846626dd1e8d6c82fa
om/android/server/wifi/nan/WifiNanClientState.java
om/android/server/wifi/nan/WifiNanNative.java
om/android/server/wifi/nan/WifiNanService.java
om/android/server/wifi/nan/WifiNanServiceImpl.java
om/android/server/wifi/nan/WifiNanSessionState.java
om/android/server/wifi/nan/WifiNanStateManager.java
621e9252d62be622e369ba43bd5c65ed63eb2f4a 18-Feb-2016 mukesh agrawal <quiche@google.com> WifiLogger: fix startLogging()
am: 28a073ae46

* commit '28a073ae465df4e92b11bc8c9b3a1890de375d30':
WifiLogger: fix startLogging()
28a073ae465df4e92b11bc8c9b3a1890de375d30 16-Feb-2016 mukesh agrawal <quiche@google.com> WifiLogger: fix startLogging()

startLogging() asks the native layer for meta-data about the ring
buffers, and then, if meta-data was _not_ available, starts logging the
ring buffers.

That's pretty much the opposite of what we want. Perhaps even exactly
the opposite of what we want.

Invert the condition, to actually start the ring buffers.

BUG=26981286
TEST=unit tests

Change-Id: I3acf227a9b8d4a8970d9bdc7a52fefa101a32852
om/android/server/wifi/WifiLogger.java
a2375bdc9f97ef50ad26ddc1e95ce9bbfbec1210 18-Feb-2016 Roshan Pius <rpius@google.com> resolve merge conflicts of 4bee869e0d to mnc-dr1.5-dev

Change-Id: Iffc3434864cc198fe2bd9e8b95162aa775624e36
29f9fde8aaa4da3495a8bc2153dbb06dd32c2dd9 18-Feb-2016 Adam Lesinski <adamlesinski@google.com> Merge "DO NOT MERGE ANYWHERE: Fix issue with WiFi scan reporting" into mnc-dr-dev
4bee869e0d5f85c43aca900db93004f7259ccbf9 18-Feb-2016 Roshan Pius <rpius@google.com> DO NOT MERGE Update network priorities before PNO is triggered
am: 27e7123ef9

* commit '27e7123ef9e83fe8bc6f3f881e425358e7f5e62b':
DO NOT MERGE Update network priorities before PNO is triggered
df9e5758803508633b1615f9df7759893f41ddd1 18-Feb-2016 Erik Kline <ek@google.com> Remove references to BaseDhcpStateMachine and DhcpStateMachine
am: ea8ea9e7c8

* commit 'ea8ea9e7c8b4ab27aa2e25c1ee99323478ee9f2d':
Remove references to BaseDhcpStateMachine and DhcpStateMachine
ea8ea9e7c8b4ab27aa2e25c1ee99323478ee9f2d 17-Feb-2016 Erik Kline <ek@google.com> Remove references to BaseDhcpStateMachine and DhcpStateMachine

Everything is android.net.dhcp.DhcpClient for now.

Bug: 26991160
Change-Id: I7140ec8295fcfb53da509c18b65fb38d702cf13a
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/p2p/WifiP2pServiceImpl.java
27e7123ef9e83fe8bc6f3f881e425358e7f5e62b 28-Jan-2016 Roshan Pius <rpius@google.com> DO NOT MERGE Update network priorities before PNO is triggered

The max SSID watch list size for PNO supported by wlan drivers is fixed
to a certain size. wpa_supplicant sorts this SSID watch list based on
the priorities assigned to those networks. This may result in us losing
some frequently used networks from the PNO list because they have lower
priorities. This is a side effect of how we assign priorities to
network configuration as they're added.
So before we trigger PNO, re-sort the network list based on the
'numAssociation' value and assign them relative priorities. This will make
sure that the PNO SSID watch list contains all the frequent SSID's to
which we were connected to.
PS: This change has a side-effect of ignoring the configured priorities
during PNO.

BUG: 26763375
Change-Id: I2c82254b2cb83aef0dd4da9e7d9b2eb5b376bead
Cherry-picked from:
https://partner-android-review.googlesource.com/#/c/529355
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
14b99c4fc8b765a34131ccba06d00c37115e25fa 12-Nov-2015 Adam Lesinski <adamlesinski@google.com> DO NOT MERGE ANYWHERE: Fix issue with WiFi scan reporting

Need to assign the overridden WorkSource to the member
mScanWorkSource in order to properly finish the scan.

Bug:23868900
Change-Id: I7c8ca5ce40ce1238e702bcc65dcef2b94b4b64e9
om/android/server/wifi/WifiStateMachine.java
009149d90a2ba968ca23122b635f93e05517daef 18-Feb-2016 Mitchell Wills <mwills@google.com> Merge "Add final bits of required functionality for ChannelHelper" into mm-wireless-dev
am: b6e44a4ad8

* commit 'b6e44a4ad89793a9a33ed9f82f51808d62de3ad8':
Add final bits of required functionality for ChannelHelper
b6e44a4ad89793a9a33ed9f82f51808d62de3ad8 18-Feb-2016 Mitchell Wills <mwills@google.com> Merge "Add final bits of required functionality for ChannelHelper" into mm-wireless-dev
63b2b657b63bc435907638c92511417c8f21a109 17-Feb-2016 Mitchell Wills <mwills@google.com> Merge "Remove WifiScanner scheduler context hub references" into mm-wireless-dev
am: 46817c38d8

* commit '46817c38d8e693046a7a7fbbe63e95b23ce41f01':
Remove WifiScanner scheduler context hub references
46817c38d8e693046a7a7fbbe63e95b23ce41f01 17-Feb-2016 Mitchell Wills <mwills@google.com> Merge "Remove WifiScanner scheduler context hub references" into mm-wireless-dev
5d1a27b0c7e7d9314519371966dec54b29a7def3 17-Feb-2016 Randy Pan <zpan@google.com> Merge "Fix PNO ScanResult creation" into mm-wireless-dev
am: 2fc7240522

* commit '2fc7240522039f542e4870baea7553613a3b8f39':
Fix PNO ScanResult creation
2fc7240522039f542e4870baea7553613a3b8f39 17-Feb-2016 Randy Pan <zpan@google.com> Merge "Fix PNO ScanResult creation" into mm-wireless-dev
1ab129e587d334a144a0bca5323c27985397a403 17-Feb-2016 Randy Pan <zpan@google.com> Fix PNO ScanResult creation

Fixed a couple of issues with PNO scan result creation. Moved
information element field population into createScanResult(),
which simplifies data passing between JNI and JAVA. This
also helps fix the issue that IE was not populated in PNO
scan result.

Bug: 26666366
Change-Id: I5c6b060713ac9597bac8b1ec64c7c3231c8d0d51
om/android/server/wifi/WifiNative.java
d50c443ebd668317163648ea08e9834a5a7e5277 17-Feb-2016 Roshan Pius <rpius@google.com> WifiService: Store UIDs for WifiLock/Multicaster
am: 1fb0a78b06

* commit '1fb0a78b06041b918fdf55173d026efc315ee574':
WifiService: Store UIDs for WifiLock/Multicaster
1fb0a78b06041b918fdf55173d026efc315ee574 12-Feb-2016 Roshan Pius <rpius@google.com> WifiService: Store UIDs for WifiLock/Multicaster

Store the UID of the calling user in the WifiLock/Multicaster object and
print it in the toString method of both.

Restructure the DeathRecipient class to only hold the information that
is common to WifiLock/Multicaster.

BUG: 27149817
Change-Id: I14031f9badaffc7ba9d952719f61ff0a7d80c5a1
om/android/server/wifi/WifiServiceImpl.java
eed6bcbbe112bd907ceddf6bfe35d99d5e51934e 17-Feb-2016 xin He <xinhe@google.com> Merge "Modify BSSID blacklist behavior" into mm-wireless-dev
am: a2a3c5080b

* commit 'a2a3c5080bb6ccf6afbb8599d00b948963bfb23a':
Modify BSSID blacklist behavior
a2a3c5080bb6ccf6afbb8599d00b948963bfb23a 17-Feb-2016 xin He <xinhe@google.com> Merge "Modify BSSID blacklist behavior" into mm-wireless-dev
6ed97affc9bbce6497b6155285ba4a71196d69e1 16-Feb-2016 xinhe <xinhe@google.com> Modify BSSID blacklist behavior

The new behaviors are:
(1) If a BSSID get association rejection three times, blacklist it
(2) After 30 min of blacklist, we re-enable it again.
(3) If any connect successfully to the BSSID, re-enable it

BUG=27166673

Change-Id: I70f439b524ffc304d6c61744f90389f47006341b
om/android/server/wifi/WifiQualifiedNetworkSelection.java
om/android/server/wifi/WifiStateMachine.java
4240c0a27d1e3a49df078e807e1ede47d737495a 16-Feb-2016 Ningyuan Wang <nywang@google.com> Merge "Mark status DISABLED when disabling a network" into mm-wireless-dev
am: f41a9021a7

* commit 'f41a9021a7374c2ce6c1c658bc721ce4eef3e2ae':
Mark status DISABLED when disabling a network
f41a9021a7374c2ce6c1c658bc721ce4eef3e2ae 16-Feb-2016 Ningyuan Wang <nywang@google.com> Merge "Mark status DISABLED when disabling a network" into mm-wireless-dev
0a8904265fc81ec1051030e66815aa191d4c347c 16-Feb-2016 Mitchell Wills <mwills@google.com> Merge "Migrate channel/band toString to ChannelHelper" into mm-wireless-dev
am: f2d417a69e

* commit 'f2d417a69e52898d976ea01334794357ecdcfcd8':
Migrate channel/band toString to ChannelHelper
798a997d2e5bf8b3278bfeaa7ca841394e2db4b9 12-Feb-2016 Mitchell Wills <mwills@google.com> Add final bits of required functionality for ChannelHelper

Add support for getting the list of available channels for a band if
available.
Add support for estimating the duration of a scan.

Change-Id: I8abe6d857400775f72969abd4b15e8763ec772c5
om/android/server/wifi/WifiScanningServiceImpl.java
om/android/server/wifi/scanner/ChannelHelper.java
om/android/server/wifi/scanner/KnownBandsChannelHelper.java
om/android/server/wifi/scanner/NoBandChannelHelper.java
303b05a42b953f325fa3cea3e0021684741554c5 09-Feb-2016 Ningyuan Wang <nywang@google.com> Mark status DISABLED when disabling a network

This marks the status as DISABLED in WifiConfiguration when
the WifiConfigStore disables a network.
This also fixes a comment typo.

Bug: 26985338
TEST=cts WifiManagerTest
Change-Id: Idb10a4e53cf07b8e56f260bd7f846b3967862140
om/android/server/wifi/WifiConfigStore.java
f2d417a69e52898d976ea01334794357ecdcfcd8 16-Feb-2016 Mitchell Wills <mwills@google.com> Merge "Migrate channel/band toString to ChannelHelper" into mm-wireless-dev
ed70643c5c1dc368b1390eed0d3c8f24b19e342f 16-Feb-2016 xin He <xinhe@google.com> Merge "add more unit test case to Quality Network Selection" into mm-wireless-dev
am: d2995af00d

* commit 'd2995af00d433ea6f952e8ff1c82c0ed2c71a274':
add more unit test case to Quality Network Selection
d2995af00d433ea6f952e8ff1c82c0ed2c71a274 16-Feb-2016 xin He <xinhe@google.com> Merge "add more unit test case to Quality Network Selection" into mm-wireless-dev
154f6abe46bab660f5a61dedc8c25157fa5b37be 16-Feb-2016 Erik Kline <ek@google.com> Use IpManager.ProvisioningRequest for IpManager#startProvisioning.
am: 00cd284ff0

* commit '00cd284ff0b4bbfd4bb39683cd2d37ef402bbc45':
Use IpManager.ProvisioningRequest for IpManager#startProvisioning.
00cd284ff0b4bbfd4bb39683cd2d37ef402bbc45 11-Feb-2016 Erik Kline <ek@google.com> Use IpManager.ProvisioningRequest for IpManager#startProvisioning.

Bug: 26991160
Change-Id: I929744e9faa3c71170a3e8e1e1bedc3c6cd16d22
om/android/server/wifi/WifiStateMachine.java
4f945c572fd7e26cf4eecc740a2c672883b71e49 13-Feb-2016 Vinit Deshpande <vinitd@google.com> UnitTests for MOManager and AnqpCache
am: ae815bc712

* commit 'ae815bc71287f8a85727034c40bb07247a3d9415':
UnitTests for MOManager and AnqpCache
ae815bc71287f8a85727034c40bb07247a3d9415 26-Jan-2016 Vinit Deshpande <vinitd@google.com> UnitTests for MOManager and AnqpCache

MOManager is the repository that holds management
objects for Passpoint networks. This change adds tests
to add/remove and modify management objects.

AnqpCache holds results to save power; this test
verifies basic adding/querying and expiry of entries.

Change-Id: I9b12a6661f689227f7564cc6a7e0fd7e338e1e8a
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/hotspot2/ANQPData.java
om/android/server/wifi/hotspot2/AnqpCache.java
9cd5bee6fcbaa9cf2b3f553d0115d26340d02dea 13-Feb-2016 Jan Nordqvist <jannq@google.com> Merge "Fixed incorrect XML serialization of MO Tree." into mm-wireless-dev
am: 1a12bb7614

* commit '1a12bb76143efa4c86e17bf1a14e6c19a21e747b':
Fixed incorrect XML serialization of MO Tree.
1a12bb76143efa4c86e17bf1a14e6c19a21e747b 13-Feb-2016 Jan Nordqvist <jannq@google.com> Merge "Fixed incorrect XML serialization of MO Tree." into mm-wireless-dev
167250a118f9fb93f88a867cc7679414da4dc8b4 12-Feb-2016 xinhe <xinhe@google.com> add more unit test case to Quality Network Selection

Add more QNS unit test cases (most are for connected state)

BUG=26941880

Change-Id: I436cce2154a0cefdb9e19486b122ebe931412dee
om/android/server/wifi/WifiQualifiedNetworkSelection.java
c9b88562541a0c2acd60d0a01ac1e182e73c79f9 11-Feb-2016 Jan Nordqvist <jannq@google.com> Fixed incorrect XML serialization of MO Tree.

Bug=27145137

Change-Id: Id2016b3ca2cf8091f254b35d8e6ff9cf4a14907a
om/android/server/wifi/hotspot2/omadm/MOTree.java
om/android/server/wifi/hotspot2/omadm/ManagementTreeRoot.java
om/android/server/wifi/hotspot2/omadm/NodeAttribute.java
om/android/server/wifi/hotspot2/omadm/OMAConstructed.java
om/android/server/wifi/hotspot2/omadm/OMANode.java
om/android/server/wifi/hotspot2/omadm/OMAParser.java
om/android/server/wifi/hotspot2/omadm/OMAScalar.java
om/android/server/wifi/hotspot2/omadm/PasspointManagementObjectManager.java
om/android/server/wifi/hotspot2/omadm/XMLNode.java
18fa274d5835b6aa853cced404316157293e8fd5 12-Feb-2016 xinhe <xinhe@google.com> add Clock class for Wifi
am: ed514c84aa

* commit 'ed514c84aae008d245679f05c9dbcd7e71f126f8':
add Clock class for Wifi
ed514c84aae008d245679f05c9dbcd7e71f126f8 12-Feb-2016 xinhe <xinhe@google.com> add Clock class for Wifi

Add clock interface to wrapper the System and SystemClock
APIs. In this way we can mock it in mockito test. Integrated
with Quality Network Selection first

BUG=27166726

Change-Id: I952944ccbad32e07ba316197d1785e551e03ea21
om/android/server/wifi/Clock.java
om/android/server/wifi/WifiQualifiedNetworkSelection.java
om/android/server/wifi/WifiStateMachine.java
17445b7996487f059114a1ab6a0efa5f95fb86be 12-Feb-2016 Bartosz Fabianowski <bartfab@google.com> resolve merge conflicts of b2f519476e to nyc-dev

Change-Id: I28da4aee94bf4f80347481da396ca40bb7d107d9
23dc88716b6fc4c15e576dacbdd5235b0f5e6552 12-Feb-2016 Paul Stewart <pstew@google.com> Merge "Revert "Refactor for accessor changes to WifiEnterpriseConfig"" into mm-wireless-dev
am: 50919ff875

* commit '50919ff8752d2b2a4617adb869047bf64e6cb34b':
Revert "Refactor for accessor changes to WifiEnterpriseConfig"
50919ff8752d2b2a4617adb869047bf64e6cb34b 12-Feb-2016 Paul Stewart <pstew@google.com> Merge "Revert "Refactor for accessor changes to WifiEnterpriseConfig"" into mm-wireless-dev
25704f0019d27c7939499721d779a1cb66537ebb 12-Feb-2016 Paul Stewart <pstew@google.com> Revert "Refactor for accessor changes to WifiEnterpriseConfig"

This reverts commit 1b0da700f6d88ab64c51cf66f2cf31cff8663fca.

Reverting until test team does their thing later today. Whoops.

Change-Id: I47716b6135fbaf1843b0f062c9374e908dc8a62e
om/android/server/wifi/WifiConfigStore.java
7cc7c2dd4452e5097c83d1ff96cc31a6816e509e 12-Feb-2016 Paul Stewart <pstew@google.com> Merge "Refactor for accessor changes to WifiEnterpriseConfig" into mm-wireless-dev
am: 525af45a81

* commit '525af45a817d3e548bfbdba2af38e182bc6ec8b5':
Refactor for accessor changes to WifiEnterpriseConfig
525af45a817d3e548bfbdba2af38e182bc6ec8b5 12-Feb-2016 Paul Stewart <pstew@google.com> Merge "Refactor for accessor changes to WifiEnterpriseConfig" into mm-wireless-dev
0fb9cf43830d67894b519c9a6271320c4842a5c0 12-Feb-2016 Bartosz Fabianowski <bartfab@google.com> Allow managed profile to modify networks

If the current foreground user has a managed profile, apps running in that
profile should have the same permissions to add/remove/modify networks as
apps running as the foreground user itself.

This is a re-submit of
https://partner-android-review.googlesource.com/#/c/529950/
with updated unit tests that will also work after merging to N/master.

BUG=26867426

Change-Id: If97734abad801ae1264919c91c3ef4236469cfde
om/android/server/wifi/ConfigurationMap.java
om/android/server/wifi/FrameworkFacade.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiConfigurationUtil.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
54e2c84547e22622ba4a08bddd1c632d1d937be3 11-Feb-2016 Mitchell Wills <mwills@google.com> Migrate channel/band toString to ChannelHelper

Change-Id: Ia4ea1d29b74cd08593f13b9e74cb6f6257adf78b
om/android/server/wifi/WifiChannelHelper.java
om/android/server/wifi/WifiScanningServiceImpl.java
om/android/server/wifi/scanner/ChannelHelper.java
ffd939c5b9a68b9df7242c546b666d961ffefb03 12-Feb-2016 Etan Cohen <etancohen@google.com> Merge "NAN: Disable all DBG flags." into mm-wireless-dev
am: 75ad7fa297

* commit '75ad7fa297007a0cfe1b5a02f45c78441d819d42':
NAN: Disable all DBG flags.
75ad7fa297007a0cfe1b5a02f45c78441d819d42 12-Feb-2016 Etan Cohen <etancohen@google.com> Merge "NAN: Disable all DBG flags." into mm-wireless-dev
2cb727022e130f0c0b3c549b01c7d88cd57904e3 11-Feb-2016 Etan Cohen <etancohen@google.com> NAN: Disable all DBG flags.

Change-Id: I98873ef3419282dde855987a1f4f8b6c29a30b89
om/android/server/wifi/nan/WifiNanClientState.java
om/android/server/wifi/nan/WifiNanNative.java
om/android/server/wifi/nan/WifiNanServiceImpl.java
om/android/server/wifi/nan/WifiNanSessionState.java
om/android/server/wifi/nan/WifiNanStateManager.java
06c07f7548feb9a4c7b53b170340447ca473ff3f 11-Feb-2016 Mitchell Wills <mwills@google.com> Update scanner onScanStatus callback to include event
am: 63539f1283

* commit '63539f1283899fbbf83ab90757961b4be51d5034':
Update scanner onScanStatus callback to include event
1b0da700f6d88ab64c51cf66f2cf31cff8663fca 16-Jan-2016 Paul Stewart <pstew@google.com> Refactor for accessor changes to WifiEnterpriseConfig

WifiEnterpriseConfig has changed to provide more sane accessors.
Now, callers are not given blanket access to the internal fields
and need to pass an accessor object to either save or restore
wpa_supplicant configuration.

This CL also adds unit tests to validate the new behavior of EAP
and Phase 2 parameters to ensure that recent changes do not cause
any regressions.

Bug:26400915
Change-Id: I575dc1688ff4b6055708e135b2692c982bc89d7a
om/android/server/wifi/WifiConfigStore.java
63539f1283899fbbf83ab90757961b4be51d5034 04-Feb-2016 Mitchell Wills <mwills@google.com> Update scanner onScanStatus callback to include event

This now allows scanner implementations to indicate scan failues as
well.

This change also ensures that anqpLines is set in results from supplicant

Change-Id: Ibe18c9b804bf073b9152800295c40d072a41e641
om/android/server/wifi/HalWifiScannerImpl.java
om/android/server/wifi/ScanDetail.java
om/android/server/wifi/SupplicantWifiScannerImpl.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiScanningServiceImpl.java
10df92e35f8b7d2abb5b311dc09bf2b8ff30d206 11-Feb-2016 Mitchell Wills <mwills@google.com> Merge changes I86b5194b,Ic4150120 into mm-wireless-dev
am: 3459602371

* commit '345960237132c18a817d3aed93ab6df5906fcc97':
Add more functionality to ChannelHelper
Add scan channel helper abstraction
345960237132c18a817d3aed93ab6df5906fcc97 11-Feb-2016 Mitchell Wills <mwills@google.com> Merge changes I86b5194b,Ic4150120 into mm-wireless-dev

* changes:
Add more functionality to ChannelHelper
Add scan channel helper abstraction
8a8f89708a14547b79df1774b254f7252c64ad4d 11-Feb-2016 Mitchell Wills <mwills@google.com> resolve merge conflicts of 4086badffe to nyc-dev.

Change-Id: Idcabbfc19669aff2a99d6a39fd12a2be25dca058
4086badffeb97f4c87b2bed3fcaa49b731a6670e 11-Feb-2016 Mitchell Wills <mwills@google.com> Merge "Revert "Allow managed profile to modify networks"" into mm-wireless-dev
9f8586ea6d640e86560efd9a2d9c1909b08a3ef4 11-Feb-2016 Mitchell Wills <mwills@google.com> Revert "Allow managed profile to modify networks"

This reverts commit bbb3149f3bc301e81c202438b77c45574a90a851.

Bug: 27145628
Change-Id: I05ac9c714373b98fa73e0dba21ec4d815200af75
om/android/server/wifi/ConfigurationMap.java
om/android/server/wifi/FrameworkFacade.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiConfigurationUtil.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
f5b4bcf6af1dd024e7219ca69fd54f20948c0be9 11-Feb-2016 Glen Kuhne <kuh@google.com> Merge "WifiMetrics ConnectionEvent logging" into mm-wireless-dev
am: 6eb121431c

* commit '6eb121431c67b98d8b14242a34c28b205a42b119':
WifiMetrics ConnectionEvent logging
6eb121431c67b98d8b14242a34c28b205a42b119 11-Feb-2016 Glen Kuhne <kuh@google.com> Merge "WifiMetrics ConnectionEvent logging" into mm-wireless-dev
3e024d7ca0520bd167eac44c1745183919748c83 11-Feb-2016 Bartosz Fabianowski <bartfab@google.com> resolve merge conflicts of bbb3149f3b to nyc-dev

Change-Id: I29effba14b5e3bcff4c996e1e12b07f1d7143850
bbb3149f3bc301e81c202438b77c45574a90a851 11-Feb-2016 Bartosz Fabianowski <bartfab@google.com> Allow managed profile to modify networks

If the current foreground user has a managed profile, apps running in that
profile should have the same permissions to add/remove/modify networks as
apps running as the foreground user itself.

BUG:26867426

Change-Id: I6ab891625b673e617e1c38863b9c6e71e4938a0b
om/android/server/wifi/ConfigurationMap.java
om/android/server/wifi/FrameworkFacade.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiConfigurationUtil.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
4326ff75bfc8dbe3081402df4f568584ab61b9d7 11-Feb-2016 Roshan Pius <rpius@google.com> Merge "Update network priorities before PNO is triggered" into mm-wireless-dev
am: bfcea7de75

* commit 'bfcea7de75875c900de19a8504416492ed96ae21':
Update network priorities before PNO is triggered
bfcea7de75875c900de19a8504416492ed96ae21 11-Feb-2016 Roshan Pius <rpius@google.com> Merge "Update network priorities before PNO is triggered" into mm-wireless-dev
2532a24b254d724a9b6771d327dc410b32b18602 05-Feb-2016 Glen Kuhne <kuh@google.com> WifiMetrics ConnectionEvent logging

Reworked ConnectionEvent start and end calls within StateMachine to
produce a more correct log of ConnectionEvents (previously these calls
produced an incorrect placeholder log).
Some ConnectionEvents being triggered by CMD_AUTO_CONNECT are still not
being ended due to double CMD_AUTO_CONNECT calls.
Modified the behaviour of endConnectionEvent(), this will not create or
modify ConnectionEvents if there is no currentConnectionEvent.

BUG=25691077

Change-Id: I932b50cef5d6d66a7dc22f8c118fe9c140a5f4ba
om/android/server/wifi/WifiMetrics.java
om/android/server/wifi/WifiStateMachine.java
39175cc807488dd849e2c530f8be30dd674fbd9f 09-Feb-2016 Mitchell Wills <mwills@google.com> Add more functionality to ChannelHelper

Check if a channel is in a ScanSettings
Add channels to accumulator from native settings
Add unit tests for non-abstract ChannelHelper methods

Change-Id: I86b5194b2a5c852fd25041a363f42caa202dfa7a
om/android/server/wifi/scanner/ChannelHelper.java
om/android/server/wifi/scanner/KnownBandsChannelHelper.java
om/android/server/wifi/scanner/NoBandChannelHelper.java
0e03fa9a1ac57d1eca2b5f5d6880b655d67e2508 11-Feb-2016 Erik Kline <ek@google.com> Merge "Split updateLinkProperties() and provisioning change handling" into mm-wireless-dev
am: d150184a5b

* commit 'd150184a5b28f862b39ad383ab87ee0ac4ca6be8':
Split updateLinkProperties() and provisioning change handling
f6290e740290bd2d404cba0815dd5be9d54761f7 11-Feb-2016 Mitchell Wills <mwills@google.com> Remove WifiScanner scheduler context hub references

Since all scan results will now be reported to the context hub the
scheduler no longer needs to worry about handling requests specially.

Change-Id: Ie27f735a361175865c874f671236812477d1e090
om/android/server/wifi/MultiClientScheduler.java
d150184a5b28f862b39ad383ab87ee0ac4ca6be8 10-Feb-2016 Erik Kline <ek@google.com> Merge "Split updateLinkProperties() and provisioning change handling" into mm-wireless-dev
ac9ad3283508db15b65b1cbb89b841278973276b 28-Jan-2016 Roshan Pius <rpius@google.com> Update network priorities before PNO is triggered

The max SSID watch list size for PNO supported by wlan drivers is fixed
to a certain size. wpa_supplicant sorts this SSID watch list based on
the priorities assigned to those networks. This may result in us losing
some frequently used networks from the PNO list because they have lower
priorities. This is a side effect of how we assign priorities to
network configuration as they're added.
So before we trigger PNO, re-sort the network list based on the
'numAssociation' value and assign them relative priorities. This will make
sure that the PNO SSID watch list contains all the frequent SSID's to
which we were connected to.
PS: This change has a side-effect of ignoring the configured priorities
during PNO.

While there,
1. Add a common test utils class for common utility functions for all
tests.
2. Annotate all tests in WifiConfigStore so that
|WifiTestUtil.getTestMethod| works reliably.

BUG: 26763375
Change-Id: I2c82254b2cb83aef0dd4da9e7d9b2eb5b376bead
TEST: `adb shell am instrument -e class
'com.android.server.wifi.WifiConfigStoreTest' -w
'com.android.server.wifi.test/android.support.test.runner.AndroidJUnitRunner'`
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
b30f36a05e8867c209a3d6fd1de84af69a627053 10-Feb-2016 Mitchell Wills <mwills@google.com> Merge "Remove unused supplicant scan with connection setup option" into mm-wireless-dev
am: 28d387c8fa

* commit '28d387c8fa63967072dc7c1be46b8aa00f754a17':
Remove unused supplicant scan with connection setup option
b1bbed13ea8ed71e8aab45327921b4df669686f8 10-Feb-2016 Ritesh Reddy <riteshr@google.com> Merge "Staging WifiAP Configuration for backup" into mm-wireless-dev
am: 209f44caf9

* commit '209f44caf9436467ee8efcc173cbefdf44540e31':
Staging WifiAP Configuration for backup
28d387c8fa63967072dc7c1be46b8aa00f754a17 10-Feb-2016 Mitchell Wills <mwills@google.com> Merge "Remove unused supplicant scan with connection setup option" into mm-wireless-dev
8cf2b5c507918a30629b9dc24944422fc0920665 03-Feb-2016 Erik Kline <ek@google.com> Split updateLinkProperties() and provisioning change handling

Bug: 26991160
Change-Id: I20a41e5f1426befc474e923d2763b508f26f1ce4
om/android/server/wifi/WifiStateMachine.java
209f44caf9436467ee8efcc173cbefdf44540e31 10-Feb-2016 Ritesh Reddy <riteshr@google.com> Merge "Staging WifiAP Configuration for backup" into mm-wireless-dev
06cee75cad97451d3dcb5ea2fc9344a87c5bb319 10-Feb-2016 Erik Kline <ek@google.com> Upgrade from legacy dhcpcd to DhcpClient
am: dde96dcb17

* commit 'dde96dcb1758669a7840ca88cff767ffec218936':
Upgrade from legacy dhcpcd to DhcpClient
dde96dcb1758669a7840ca88cff767ffec218936 05-Feb-2016 Erik Kline <ek@google.com> Upgrade from legacy dhcpcd to DhcpClient

Change-Id: I06b2642864fc067be4e92d563aab7183edc1bb47
om/android/server/wifi/p2p/WifiP2pServiceImpl.java
ed6a985c7b63e295248fa7e8292c99b48b7a4283 04-Feb-2016 Mitchell Wills <mwills@google.com> Remove unused supplicant scan with connection setup option

We no longer want supplicant to make connection decisions by itself so
remove the option since it is dead code.

Change-Id: I53a059219e0080e4780d9a131748958049b47df2
om/android/server/wifi/HalWifiScannerImpl.java
om/android/server/wifi/SupplicantWifiScannerImpl.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
729b7f72d116a4b757484fa70c9549419775b5fa 09-Feb-2016 Mitchell Wills <mwills@google.com> Merge "Rename WIFI_SCAN_DISABLED event to WIFI_SCAN_FAILED" into mm-wireless-dev
am: 3acfa01007

* commit '3acfa01007faf85d6c3bd1efa01b0b6bd85bafe5':
Rename WIFI_SCAN_DISABLED event to WIFI_SCAN_FAILED
3acfa01007faf85d6c3bd1efa01b0b6bd85bafe5 09-Feb-2016 Mitchell Wills <mwills@google.com> Merge "Rename WIFI_SCAN_DISABLED event to WIFI_SCAN_FAILED" into mm-wireless-dev
71af8bb37fee5852ae458edabdef3b487d62a5b8 29-Jan-2016 Mitchell Wills <mwills@google.com> Rename WIFI_SCAN_DISABLED event to WIFI_SCAN_FAILED

disabled was not very clear as to the actual meaning of the event and
left the implication that the scan could be reenabled.

Change-Id: Id1894a43dd761624fc3839841029ceb0333647de
om/android/server/wifi/WifiNative.java
7538f4c7a132a5015dee8b4563bb5ea5cd3f0a13 09-Feb-2016 Randy Pan <zpan@google.com> Merge "Build \'capabilities\' string for gscan results" into mm-wireless-dev
am: aab5468666

* commit 'aab54686664ce47f2c41614a8460f454743d157d':
Build 'capabilities' string for gscan results
aab54686664ce47f2c41614a8460f454743d157d 09-Feb-2016 Randy Pan <zpan@google.com> Merge "Build 'capabilities' string for gscan results" into mm-wireless-dev
3571366ac36c70746b9f013ec2b54482861c9292 03-Feb-2016 Randy Pan <zpan@google.com> Build 'capabilities' string for gscan results

Populate the WiFi beacon capability information from gscan to
WifiNative. Build ScanResult 'capabilities' string based on this
value and the information elements.

Add unit tests.

Bug: 26908033
Bug: 26908558
Change-Id: I661bb501a09d3e79ee0b0a8e141e7e47c72687f7
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiParser.java
om/android/server/wifi/util/InformationElementUtil.java
a079e33387387a0edc978a4d48c0a3d4c9905311 09-Feb-2016 Samuel Tan <samueltan@google.com> Merge "WifiConfigStore: Add CA_PATH_KEY to ENTERPRISE_CONFIG_SUPPLICANT_KEYS" into mm-wireless-dev
am: 422167cade

* commit '422167cade62a533efe680cea1e32446fa103e1b':
WifiConfigStore: Add CA_PATH_KEY to ENTERPRISE_CONFIG_SUPPLICANT_KEYS
422167cade62a533efe680cea1e32446fa103e1b 09-Feb-2016 Samuel Tan <samueltan@google.com> Merge "WifiConfigStore: Add CA_PATH_KEY to ENTERPRISE_CONFIG_SUPPLICANT_KEYS" into mm-wireless-dev
9e06c302626204c7b46e0025a6f91888be5607ef 09-Feb-2016 xin He <xinhe@google.com> Merge "add more unit test case to Quality Network Selection" into mm-wireless-dev
am: 84c11d63f2

* commit '84c11d63f274ec136a94e0f17982eba1e07f1d9e':
add more unit test case to Quality Network Selection
84c11d63f274ec136a94e0f17982eba1e07f1d9e 09-Feb-2016 xin He <xinhe@google.com> Merge "add more unit test case to Quality Network Selection" into mm-wireless-dev
2bc580c67c614c2b7eeaf88a7795620fc53a8099 09-Feb-2016 Jan Nordqvist <jannq@google.com> Merge "Removing Hotspot 2.0 OSU client code from framework." into mm-wireless-dev
am: 676d664bf4

* commit '676d664bf4b5f59279a53a986ce94363e2bc4fd2':
Removing Hotspot 2.0 OSU client code from framework.
676d664bf4b5f59279a53a986ce94363e2bc4fd2 09-Feb-2016 Jan Nordqvist <jannq@google.com> Merge "Removing Hotspot 2.0 OSU client code from framework." into mm-wireless-dev
712ef6246834caeac3d5b06bea08e85d6b29cd7a 05-Feb-2016 Mitchell Wills <mwills@google.com> Add scan channel helper abstraction

This will allow code to easily function without worrying about the
differences in the amount of information known about scan channels.

Currently this abstraction will only support merging channels, but more
functionality will be added as needed. Eventually this will replace all
functionality in WifiChannelHelper.

Change-Id: Ic41501204fa4ff4470491055f4204ad9a88000d4
om/android/server/wifi/WifiNative.java
om/android/server/wifi/scanner/ChannelHelper.java
om/android/server/wifi/scanner/KnownBandsChannelHelper.java
om/android/server/wifi/scanner/NoBandChannelHelper.java
a08566d83c94ad608dd25f86fa7cc82d78734508 09-Feb-2016 Wei Wang <weiwa@google.com> Enable Rtt Responder Role(2/4).
am: 68cb8c02b4

* commit '68cb8c02b4ad079c54a2ffd4407da921d18c7af9':
Enable Rtt Responder Role(2/4).
68cb8c02b4ad079c54a2ffd4407da921d18c7af9 25-Jan-2016 Wei Wang <weiwa@google.com> Enable Rtt Responder Role(2/4).

Change-Id: Ib18af94fbba21c833c47336f7a92afe918dc9a89
om/android/server/wifi/RttService.java
om/android/server/wifi/WifiNative.java
21524058ffc735089b1777526df6c9f9dd37ff0e 09-Feb-2016 Mitchell Wills <mwills@google.com> Merge "Add ScanDetailUtil to convert ScanResult to ScanDetail" into mm-wireless-dev
am: 5f38b29b5f

* commit '5f38b29b5f4b891e59e8c20b210fa9e0e0a28440':
Add ScanDetailUtil to convert ScanResult to ScanDetail
c83c0526b1c209ca9d831154a13c4ef9131b17f8 05-Feb-2016 xinhe <xinhe@google.com> add more unit test case to Quality Network Selection

Add more QNS test cases when deivice is under disconnected
state. Add a clear method in QNS for test purpose

BUG=26941880

Change-Id: Icf03dc71b1fab5b65b528e6fed4eb5f918f06e36
om/android/server/wifi/WifiQualifiedNetworkSelection.java
c11476cd6b68ba6c5b34c99ea312c45e18a17658 08-Feb-2016 Ritesh Reddy <riteshr@google.com> Staging WifiAP Configuration for backup

Staging WifiAp Config for backup when the config
is changed.

Change-Id: Ie2d586f37e81c184fc6b7ca99f24c82e3dcc12dc
om/android/server/wifi/WifiApConfigStore.java
e4e3b8cb884dd9e754a437ea6feac502191f1767 07-Feb-2016 Mitchell Wills <mwills@google.com> Add ScanDetailUtil to convert ScanResult to ScanDetail

Also move InformationElementUtilTest to util package

Change-Id: I4a2c6a561ce6106d7c8c671cec225cf5ae6532f0
om/android/server/wifi/ScanDetail.java
om/android/server/wifi/util/ScanDetailUtil.java
435d037ed4e5da4cd2e73a6f089382deb79c1fc0 05-Feb-2016 Samuel Tan <samueltan@google.com> WifiConfigStore: Add CA_PATH_KEY to ENTERPRISE_CONFIG_SUPPLICANT_KEYS

Add CA_PATH_KEY to ENTERPRISE_CONFIG_SUPPLICANT_KEYS, so that the
|ca_path| WPA supplicant directive will be saved and loaded.

BUG: 25180141
Change-Id: Id425270644c64d89f7094ebd756093e57e848ee4
om/android/server/wifi/WifiConfigStore.java
1b9c2436f0a03d8b5725cf521b0cf8248e85d228 05-Feb-2016 Etan Cohen <etancohen@google.com> NAN: Add NAN HAL capability
am: e36f5903f5

* commit 'e36f5903f5d236a29dc94c8bdb215807ae75f5a1':
NAN: Add NAN HAL capability
72401daf8411fb8e56ee0dd4ecb27cd3bba29e33 05-Feb-2016 Etan Cohen <etancohen@google.com> Merge "NAN: Adding tests for internal state of WifiNanStateManager" into mm-wireless-dev
am: a40a871604

* commit 'a40a871604177637c12f190cbbfbf71752c490bd':
NAN: Adding tests for internal state of WifiNanStateManager
e36f5903f5d236a29dc94c8bdb215807ae75f5a1 03-Feb-2016 Etan Cohen <etancohen@google.com> NAN: Add NAN HAL capability

Query NAN HAL for its capabilities and propagate to WifiNanStateManager for
storage (usage is TBD).

BUG=26564631
Change-Id: Icb4223c5a03cb65fba1781d0ebe78d70110d3a86
om/android/server/wifi/nan/WifiNanNative.java
om/android/server/wifi/nan/WifiNanStateManager.java
a40a871604177637c12f190cbbfbf71752c490bd 05-Feb-2016 Etan Cohen <etancohen@google.com> Merge "NAN: Adding tests for internal state of WifiNanStateManager" into mm-wireless-dev
da2a851df92114887f885ae8ea1973f0548f38d8 05-Feb-2016 xinhe <xinhe@google.com> fix NullPointerException occurred during WifiManagerForgetNetworkOnSuccess
am: d852b3a37c

* commit 'd852b3a37c17c4d4595fbe0389c90fec06ed9382':
fix NullPointerException occurred during WifiManagerForgetNetworkOnSuccess
22b4156d2948e3108ae8439dc72f76fb97526ace 26-Jan-2016 Etan Cohen <etancohen@google.com> NAN: Adding tests for internal state of WifiNanStateManager

Add tests for internal state of WifiNanStateManager: validate that
cleanup of client (UID) and session registrations (pending transactions)
done when client disconnected or when a session is destroyed.

While usually not a good idea to test internal state (all other tests
are focused on external contract of class) in this case the results would
be memory leak and information leak.

Fixed several errors discovered with new unit tests.

Bug: 26878060
Bug: 26880665
Change-Id: I89f20353c296edb562de3cb0dfdc208e91624acf
om/android/server/wifi/nan/WifiNanClientState.java
om/android/server/wifi/nan/WifiNanNative.java
om/android/server/wifi/nan/WifiNanSessionState.java
om/android/server/wifi/nan/WifiNanStateManager.java
d852b3a37c17c4d4595fbe0389c90fec06ed9382 05-Feb-2016 xinhe <xinhe@google.com> fix NullPointerException occurred during
WifiManagerForgetNetworkOnSuccess

It is a risk condition. At this time, WifiStateMachine still
in mConnectedState, but WifiInfo has been updated since it
is updated in handleSupplicantStateChange which is earlier.
Add condition check protection to solve this issue

BUG=26989672

Change-Id: I465628dc0f8c74f2693aecf746229818a31f9d74
om/android/server/wifi/WifiQualifiedNetworkSelection.java
3fff4c9bd5db730141e75706a7229814d403b363 05-Feb-2016 Jan Nordqvist <jannq@google.com> Removing Hotspot 2.0 OSU client code from framework.

Change-Id: I1be652aeb60cc3c49b606e4e2f467951cf2d68b5
om/android/server/wifi/FrameworkFacade.java
om/android/server/wifi/hotspot2/AlarmHandler.java
om/android/server/wifi/hotspot2/Chronograph.java
om/android/server/wifi/hotspot2/OMADMAdapter.java
om/android/server/wifi/hotspot2/SupplicantBridge.java
om/android/server/wifi/hotspot2/WifiNetworkAdapter.java
om/android/server/wifi/hotspot2/asn1/Asn1Boolean.java
om/android/server/wifi/hotspot2/asn1/Asn1Class.java
om/android/server/wifi/hotspot2/asn1/Asn1Constructed.java
om/android/server/wifi/hotspot2/asn1/Asn1Decoder.java
om/android/server/wifi/hotspot2/asn1/Asn1ID.java
om/android/server/wifi/hotspot2/asn1/Asn1Integer.java
om/android/server/wifi/hotspot2/asn1/Asn1Object.java
om/android/server/wifi/hotspot2/asn1/Asn1Octets.java
om/android/server/wifi/hotspot2/asn1/Asn1Oid.java
om/android/server/wifi/hotspot2/asn1/Asn1String.java
om/android/server/wifi/hotspot2/asn1/Asn1Tag.java
om/android/server/wifi/hotspot2/asn1/DecodeException.java
om/android/server/wifi/hotspot2/asn1/OidMappings.java
om/android/server/wifi/hotspot2/est/ESTHandler.java
om/android/server/wifi/hotspot2/omadm/OMAConstants.java
om/android/server/wifi/hotspot2/omadm/PasspointManagementObjectManager.java
om/android/server/wifi/hotspot2/osu/ClientKeyManager.java
om/android/server/wifi/hotspot2/osu/ExchangeCompleteResponse.java
om/android/server/wifi/hotspot2/osu/ExecCommand.java
om/android/server/wifi/hotspot2/osu/HTTPHandler.java
om/android/server/wifi/hotspot2/osu/IconCache.java
om/android/server/wifi/hotspot2/osu/OSUCertType.java
om/android/server/wifi/hotspot2/osu/OSUClient.java
om/android/server/wifi/hotspot2/osu/OSUCommand.java
om/android/server/wifi/hotspot2/osu/OSUCommandID.java
om/android/server/wifi/hotspot2/osu/OSUError.java
om/android/server/wifi/hotspot2/osu/OSUInfo.java
om/android/server/wifi/hotspot2/osu/OSUListener.java
om/android/server/wifi/hotspot2/osu/OSUManager.java
om/android/server/wifi/hotspot2/osu/OSUMessageType.java
om/android/server/wifi/hotspot2/osu/OSUOperationStatus.java
om/android/server/wifi/hotspot2/osu/OSUResponse.java
om/android/server/wifi/hotspot2/osu/OSUSocketFactory.java
om/android/server/wifi/hotspot2/osu/OSUStatus.java
om/android/server/wifi/hotspot2/osu/PostDevDataResponse.java
om/android/server/wifi/hotspot2/osu/RequestReason.java
om/android/server/wifi/hotspot2/osu/ResponseFactory.java
om/android/server/wifi/hotspot2/osu/SOAPBuilder.java
om/android/server/wifi/hotspot2/osu/SOAPParser.java
om/android/server/wifi/hotspot2/osu/SPVerifier.java
om/android/server/wifi/hotspot2/osu/UserInputListener.java
om/android/server/wifi/hotspot2/osu/WiFiKeyManager.java
om/android/server/wifi/hotspot2/osu/XMLParser.java
om/android/server/wifi/hotspot2/osu/commands/BrowserURI.java
om/android/server/wifi/hotspot2/osu/commands/ClientCertInfo.java
om/android/server/wifi/hotspot2/osu/commands/GetCertData.java
om/android/server/wifi/hotspot2/osu/commands/MOURN.java
om/android/server/wifi/hotspot2/osu/commands/OSUCommandData.java
om/android/server/wifi/hotspot2/osu/commands/PasspointManagementObjectData.java
om/android/server/wifi/hotspot2/osu/service/RedirectListener.java
om/android/server/wifi/hotspot2/osu/service/SubscriptionTimer.java
om/android/server/wifi/hotspot2/utils/HTTPMessage.java
om/android/server/wifi/hotspot2/utils/HTTPRequest.java
om/android/server/wifi/hotspot2/utils/HTTPResponse.java
136bd86c2653e31b2a26d93a3c4a0e2df76b41bc 04-Feb-2016 xin He <xinhe@google.com> Merge "fix the broken network selection BSSID disable / enable" into mm-wireless-dev
am: ddc9e6bd99

* commit 'ddc9e6bd99cf28b4b7304672b7ecc1ead9cdd0b4':
fix the broken network selection BSSID disable / enable
ddc9e6bd99cf28b4b7304672b7ecc1ead9cdd0b4 04-Feb-2016 xin He <xinhe@google.com> Merge "fix the broken network selection BSSID disable / enable" into mm-wireless-dev
76e9e2a18840cc17747103c86b5b9323d059ef18 03-Feb-2016 Jan Nordqvist <jannq@google.com> Merge "New System APIs for Passpoint r2 app." into mm-wireless-dev
am: 92ce793e9a

* commit '92ce793e9af3faf5d996dd1e592fbc728785058a':
New System APIs for Passpoint r2 app.
92ce793e9af3faf5d996dd1e592fbc728785058a 03-Feb-2016 Jan Nordqvist <jannq@google.com> Merge "New System APIs for Passpoint r2 app." into mm-wireless-dev
2e814680f4dd27a5f825afab189843582235cedc 24-Jan-2016 Jan Nordqvist <jannq@google.com> New System APIs for Passpoint r2 app.

Change-Id: If23e6ab432e871a407cbff94292673524c6d72bd
om/android/server/wifi/FrameworkFacade.java
om/android/server/wifi/ScanDetail.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/WnmData.java
om/android/server/wifi/anqp/ANQPFactory.java
om/android/server/wifi/anqp/I18Name.java
om/android/server/wifi/anqp/RawByteElement.java
om/android/server/wifi/anqp/TestDriver.java
om/android/server/wifi/configparse/ConfigBuilder.java
om/android/server/wifi/hotspot2/NetworkDetail.java
om/android/server/wifi/hotspot2/SupplicantBridge.java
om/android/server/wifi/hotspot2/omadm/MOManager.java
om/android/server/wifi/hotspot2/omadm/MOTree.java
om/android/server/wifi/hotspot2/omadm/OMAParser.java
om/android/server/wifi/hotspot2/omadm/PasspointManagementObjectManager.java
om/android/server/wifi/hotspot2/osu/OSUClient.java
om/android/server/wifi/hotspot2/osu/OSUCommand.java
om/android/server/wifi/hotspot2/osu/OSUManager.java
om/android/server/wifi/hotspot2/osu/commands/MOData.java
om/android/server/wifi/hotspot2/osu/commands/PasspointManagementObjectData.java
om/android/server/wifi/hotspot2/osu/service/SubscriptionTimer.java
om/android/server/wifi/hotspot2/pps/HomeSP.java
om/android/server/wifi/hotspot2/pps/Policy.java
om/android/server/wifi/hotspot2/pps/SubscriptionParameters.java
om/android/server/wifi/hotspot2/pps/UpdateInfo.java
7b6cd1fce7850fc2aa0e510b170e6fd509308d21 02-Feb-2016 xinhe <xinhe@google.com> fix the broken network selection BSSID disable / enable

In this bug, AP try to steer the STA from 2.4GHz to 5GHz
band. Thus, the 2.4GHz BSSID reject the association request.
In theory, framework should disable this bssid for future
connection. However, this is broken. This CL fix the broken
network selection BSSID disable/enable

BUG=26916700

Change-Id: Ib358dd5a8481c4785391345df33b08459f781b81
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiQualifiedNetworkSelection.java
om/android/server/wifi/WifiStateMachine.java
6094859a6bb7a6e24e7d0eea78975c52eb071e41 03-Feb-2016 Erik Kline <ek@google.com> resolve merge conflicts of 8013a9b653 to master.

Change-Id: I327bc86b770c516a4357633d1b5929f89e097738
8013a9b65375608d80606780e9e1b313576a0f80 02-Feb-2016 Erik Kline <ek@google.com> Move DHCPv4 mechanics out to IpManager

Bug: 17345682
Change-Id: Iafe64e924b15c60e27e71c625439f3ab3d251c69
om/android/server/wifi/FrameworkFacade.java
om/android/server/wifi/WifiStateMachine.java
3350cbe20cc4f04f96d87a93376ba44cc00bfba7 02-Feb-2016 Peter Qiu <zqiu@google.com> Merge "WifiApConfigStore refactoring" into mm-wireless-dev
am: a51955bb18

* commit 'a51955bb18c047b2d7e4160f75b7e2dc876eb227':
WifiApConfigStore refactoring
a51955bb18c047b2d7e4160f75b7e2dc876eb227 02-Feb-2016 Peter Qiu <zqiu@google.com> Merge "WifiApConfigStore refactoring" into mm-wireless-dev
99501298a44a63049b47908c153290ead28709df 02-Feb-2016 xin He <xinhe@google.com> Merge "decouple Quality Network Selection with WifiStateMachine" into mm-wireless-dev
am: 2e484f49a0

* commit '2e484f49a044c3d25da845e544c81b2bacfce714':
decouple Quality Network Selection with WifiStateMachine
2e484f49a044c3d25da845e544c81b2bacfce714 02-Feb-2016 xin He <xinhe@google.com> Merge "decouple Quality Network Selection with WifiStateMachine" into mm-wireless-dev
00350909989434fe20c2cf8f4fefbce60f4ed61a 02-Feb-2016 Erik Kline <ek@google.com> Move static IP configuration into IpManager
am: 6728555d8e

* commit '6728555d8e533b3ae2efe7e48f4a0bac3809d959':
Move static IP configuration into IpManager
6728555d8e533b3ae2efe7e48f4a0bac3809d959 01-Feb-2016 Erik Kline <ek@google.com> Move static IP configuration into IpManager

Also, stop passing around "reason" for IPv4 provisioning success
or failure.

Bug: 17345682
Change-Id: Ib7f2e1ba7ce5d8c17427e21ad9035b06750d2452
om/android/server/wifi/WifiStateMachine.java
f498fc49083e8f6e9685e3e9d3cee210160332e7 02-Feb-2016 Erik Kline <ek@google.com> Remove unused mDhcpActive variable
am: 5c175abc31

* commit '5c175abc314bbb32c7d9fb542c97577f39a910f8':
Remove unused mDhcpActive variable
5c175abc314bbb32c7d9fb542c97577f39a910f8 01-Feb-2016 Erik Kline <ek@google.com> Remove unused mDhcpActive variable

This was only ever assigned to, and never examined.

Change-Id: I1e9acdf433a2d1ade5985cc7ba33d585edca9f81
om/android/server/wifi/WifiStateMachine.java
b7e25b4194b602300b9fc62c22f528bf5e668faf 02-Feb-2016 Pankaj Kanwar <pkanwar@google.com> Merge "Add DhcpFailure and BadNetworkEvent tests to WifiStateMachine" into mm-wireless-dev
am: bade25ebb7

* commit 'bade25ebb7b4137521576ba01e77adbda382ac11':
Add DhcpFailure and BadNetworkEvent tests to WifiStateMachine
bade25ebb7b4137521576ba01e77adbda382ac11 02-Feb-2016 Pankaj Kanwar <pkanwar@google.com> Merge "Add DhcpFailure and BadNetworkEvent tests to WifiStateMachine" into mm-wireless-dev
abcc229a23f7f0754bac999c7944e8ea4b4c3253 01-Feb-2016 Arthur Hsu <arthurhsu@google.com> Merge "Follow up of ag/848030."
142f2a85c48847ff0b15d71490b8465df0841492 01-Feb-2016 Mitchell Wills <mwills@google.com> Merge "Revert "Refactor WifiScanner support for oneshot scans"" into mm-wireless-dev
am: aed8c07f8d

* commit 'aed8c07f8dc09da9450eae81f4fa8c63191894e0':
Revert "Refactor WifiScanner support for oneshot scans"
aed8c07f8dc09da9450eae81f4fa8c63191894e0 01-Feb-2016 Mitchell Wills <mwills@google.com> Merge "Revert "Refactor WifiScanner support for oneshot scans"" into mm-wireless-dev
3fdceeaa74e21c0ca4da52deeeef6571e7e2a6cd 01-Feb-2016 Mitchell Wills <mwills@google.com> Revert "Refactor WifiScanner support for oneshot scans"

This CL does not correctly handle devices that do not support WifiNative.getChannelsForBand

Bug: 26895774

This reverts commit 772124d1f1ddb2b9537de5efc748943808dafe80.

Change-Id: Ie49715fc89750f79c8e5f188cb42094f1076a48b
om/android/server/wifi/HalWifiScannerImpl.java
om/android/server/wifi/ScanDetailUtil.java
om/android/server/wifi/SupplicantWifiScannerImpl.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiScanningScheduler.java
om/android/server/wifi/WifiScanningServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
b96deebb3e7ce2587fef3cab0049c703d0623c24 30-Jan-2016 xinhe <xinhe@google.com> decouple Quality Network Selection with WifiStateMachine

Currently, Quality Network Selection grab a reference to
WifiStateMachine and need directly call some APIs in
WifiStateMachine. We'd like to reduce the coupling
between Quality Network Selection and WifiStateMachine
for better stronger self-containing. This can increase
the robust and test-ability.

BUG=26875232

Change-Id: Ib4e02a2d5b29bade22c416540c38d39dfee2c302
om/android/server/wifi/WifiQualifiedNetworkSelection.java
om/android/server/wifi/WifiStateMachine.java
c94a64a292925a00c33413c81a46941093495b3e 24-Jan-2016 pkanwar <pkanwar@google.com> Add DhcpFailure and BadNetworkEvent tests to WifiStateMachine

This CL adds 2 tests for WifiStateMachine:

- TestDhcpFailure tests failure in dhcp client.
- TestBadNetworkEvent tests sending the NETWORK_DISCONNECTION_EVENT
during connection to make sure that the state machine does not break.

BUG=26901681

Change-Id: I9e79d8a07d18f397a38816e0a508d13482143937
om/android/server/wifi/WifiConfigStore.java
3b608e5aaaa35a2d8e03dd197eadb0f25974bcf6 01-Feb-2016 Erik Kline <ek@google.com> Fix a race that causes an NPE due to b/26238832

This should be removed with the next change to IpManager, but if the
bug gets fixed first then that's a good time to delete this too.

Bug: 26238832
Change-Id: I27085c6a15edc1eee9a149a82363e3f2d89c4ed4
om/android/server/wifi/WifiStateMachine.java
683b98d17bfa71701eea245f334bd83d9cfa6e01 01-Feb-2016 Erik Kline <ek@google.com> resolve merge conflicts of 9bd76b7c0a to master.

Change-Id: Ia89f7d00b8a1d5d4f0c71bdc0ab3912dab9b4e41
9bd76b7c0afc90d800066397497b5947916b90fa 13-Jan-2016 Erik Kline <ek@google.com> Initial refactoring to migrate IP-related things to IpManager

Bug: 17345682
Change-Id: I2cdd59a4ed405b49dd1e5c4f382f6515705b5261
om/android/server/wifi/FrameworkFacade.java
om/android/server/wifi/WifiStateMachine.java
3a24f36a730316a194c79e87963f3b19e3b1e1e4 30-Jan-2016 Arthur Hsu <arthurhsu@google.com> Follow up of ag/848030.

Address reviewer comments and make linter happy.

Change-Id: Iba9738275038ad2dfb0f40c5112b2d6a762cb333
om/android/server/wifi/WifiCertManager.java
c79666b79e273ceaa2f74090b02ca6cf83c61387 27-Jan-2016 Peter Qiu <zqiu@google.com> WifiApConfigStore refactoring

Here are main changes to WifiApConfigStore:
- add public APIs to get/set AP configurations, instead of doing it
via message passing between state machines.
- remove unnecessary statemachine logics.
- remove the use of a dedicated thread for writing configuration file,
the reason is that the file size is fairly small, seems unnecessary to
create a separate thread just for that (which adds complexity).
- handle setting of "null" ap configuration, by falling back to use
the default configuration.
- add unit tests

With this refactoring, WifiApConfigStore becomes more self-contained,
which can be easily reused by other modules (e.g. upcoming SoftApManager).

Bug: 26727266
TEST=runtest frameworks-wifi
TEST=manual test: update/enable WiFi hotspot

Change-Id: If438d5be7eaf59f0f2d35ed25a899cef93c5a638
om/android/server/wifi/FrameworkFacade.java
om/android/server/wifi/WifiApConfigStore.java
om/android/server/wifi/WifiStateMachine.java
d24bd60cc49acfabd6eb47ca77ad6af02b1082b1 30-Jan-2016 Mitchell Wills <mwills@google.com> Merge "Refactor WifiScanner support for oneshot scans" into mm-wireless-dev
am: 6788fcec7c

* commit '6788fcec7c1f46563aaf30e8cc1e8e7cb7773c60':
Refactor WifiScanner support for oneshot scans
6788fcec7c1f46563aaf30e8cc1e8e7cb7773c60 30-Jan-2016 Mitchell Wills <mwills@google.com> Merge "Refactor WifiScanner support for oneshot scans" into mm-wireless-dev
772124d1f1ddb2b9537de5efc748943808dafe80 04-Nov-2015 Mitchell Wills <mwills@google.com> Refactor WifiScanner support for oneshot scans

Seperate oneshot scans so they are no longer implemented using
background scans and make WifiStateMachine use WifiScanner for single
scans.

This changes requires a few parts:
1. Implement single scan logic in WifiScanningServiceImpl for merging
and executing scan requests using the single scan native interface.
2. Writing tests for the new code in 1
3. Make supplicant start scans by using WifiScanner and when it
recieves callbacks dispatch scan complete/failure messages.
4. Enable HalWifiScannerImpl and SupplicantWifiScannerImpl to listen to
supplicant scan events now that WifiStateMachine does not.

Bug: 26525037
Change-Id: Iddd6d64b35fed129048e1fd5c79acb6982bfc418
om/android/server/wifi/HalWifiScannerImpl.java
om/android/server/wifi/ScanDetailUtil.java
om/android/server/wifi/SupplicantWifiScannerImpl.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiScanningScheduler.java
om/android/server/wifi/WifiScanningServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
030e15024e75322ba27650be2a05d15ac06026dc 29-Jan-2016 Bartosz Fabianowski <bartfab@google.com> resolve merge conflicts of aae3592ef5 to master.

Change-Id: I24cf4c223dc384861e807493637bef4da4bb5ad2
aae3592ef5a6fb1031a405248e40ce8727f3a3b9 29-Jan-2016 Bartosz Fabianowski <bartfab@google.com> Merge "WiFiServiceImpl should not be checking who is allowed to forget networks" into mm-wireless-dev
a43ca810bea25734a8ad1a8ced14991ceb04272b 29-Jan-2016 Bartosz Fabianowski <bartfab@google.com> Merge "Handle user switch in WifiStateMachine.DefaultState" into mm-wireless-dev
am: 9feb86132e

* commit '9feb86132e4613603f8c1ed649001014c8059969':
Handle user switch in WifiStateMachine.DefaultState
9feb86132e4613603f8c1ed649001014c8059969 29-Jan-2016 Bartosz Fabianowski <bartfab@google.com> Merge "Handle user switch in WifiStateMachine.DefaultState" into mm-wireless-dev
b1a96d8ce9da10cd3a212d5bf41f0eee964828d9 29-Jan-2016 Erik Kline <ek@google.com> Merge "Add static getLinkPropertiesSummary() method." into mm-wireless-dev
am: d0bfb3bc03

* commit 'd0bfb3bc032f443f68ead6198cfb6ef9ca67e20d':
Add static getLinkPropertiesSummary() method.
d0bfb3bc032f443f68ead6198cfb6ef9ca67e20d 29-Jan-2016 Erik Kline <ek@google.com> Merge "Add static getLinkPropertiesSummary() method." into mm-wireless-dev
3f790a1d4483446f15216d5077c6c77dfb41408f 28-Jan-2016 Erik Kline <ek@google.com> Add static getLinkPropertiesSummary() method.

Replaces triplicate code with a call to a single static method.

Change-Id: Ie656a59c67c242ad57b3947d91fb7f748048cad2
om/android/server/wifi/WifiStateMachine.java
04e2e800da7fc759fb2f7b54df02d9f7ea6ae4e8 28-Jan-2016 Etan Cohen <etancohen@google.com> Merge "NAN: add message ID to correlate message callbacks to original message" into mm-wireless-dev
am: d3efa09daa

* commit 'd3efa09daa49ad39ed1f6920388e9ba63c8e271b':
NAN: add message ID to correlate message callbacks to original message
d3efa09daa49ad39ed1f6920388e9ba63c8e271b 28-Jan-2016 Etan Cohen <etancohen@google.com> Merge "NAN: add message ID to correlate message callbacks to original message" into mm-wireless-dev
9a5832469bc0755635934c4343c5f63fbc893839 28-Jan-2016 Peter Qiu <zqiu@google.com> Merge "Correctly log old/new link properties when IP provisioning is lost" into mm-wireless-dev
am: 27d23f166b

* commit '27d23f166b1f33e4991cf56ca20bfe382dfcb408':
Correctly log old/new link properties when IP provisioning is lost
27d23f166b1f33e4991cf56ca20bfe382dfcb408 28-Jan-2016 Peter Qiu <zqiu@google.com> Merge "Correctly log old/new link properties when IP provisioning is lost" into mm-wireless-dev
bace539f9cdc4ffb521c8251dd1c56073e805cd4 28-Jan-2016 Bartosz Fabianowski <bartfab@google.com> WiFiServiceImpl should not be checking who is allowed to forget networks

WiFiStateMachine takes care of verifying whether the caller is allowed
to forget a network. WiFiServiceImpl should not be performing its own
(redundant, obsolete and incompatible) checks on top of this.

BUG: 26845784

Change-Id: Ia10551ce44182c6f98407201f0cdf689ce9dbc6c
om/android/server/wifi/WifiServiceImpl.java
f2a63d82102461f1e6dbcef7ba16625bc07940ff 28-Jan-2016 Bartosz Fabianowski <bartfab@google.com> Handle user switch in WifiStateMachine.DefaultState

The WiFiStateMachine should take not of changes to the foreground user
regardless of its current internal state. The handling of the user
switch message should therefore be implemented in the DefaultState,
which all other states are built on top of.

BUG: 26846176

Change-Id: Ie605f4df3625e445d2015797c3e9bf57615c1f4d
om/android/server/wifi/WifiStateMachine.java
fcc5bc85293213868da5830e01c26363ee2e2cb1 28-Jan-2016 xin He <xinhe@google.com> Merge "Remodel Network Selection" into mm-wireless-dev
am: 2c990df82a

* commit '2c990df82a9e01a29b4cbe682226b22b805f527f':
Remodel Network Selection
2c990df82a9e01a29b4cbe682226b22b805f527f 28-Jan-2016 xin He <xinhe@google.com> Merge "Remodel Network Selection" into mm-wireless-dev
b50356194ccfdaf5e127d9f705f99713d6f1e98c 26-Jan-2016 xinhe <xinhe@google.com> Remodel Network Selection

There are two main changes in this CL:
(1) Add user selection preference support. If user
explicitly chooses a network, framework will remember
it and consider user has a higher preference of this
network over all other visible networks.

(2) Seperate user set BSSID and framework chosen BSSID.
The BSSID under WifiConfiguration is set by user and is
not allowed to be overrided. The BSSID under Network
selection status is the best BSSID chosen by the
framework to associate with.

BUG=26012244
BUG=26721725

Change-Id: I3cfb7db870c6abe933a296267bc1909b4810c8f8
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiQualifiedNetworkSelection.java
om/android/server/wifi/WifiStateMachine.java
95a40b7432e9928ec6606f0c95abd428e26e758c 28-Jan-2016 Lorenzo Colitti <lorenzo@google.com> Merge "Unbreak the code that chooses the DHCP client." into mm-wireless-dev
am: 65027c30ca

* commit '65027c30caafb24f939dcc0eab716454c39bd6fe':
Unbreak the code that chooses the DHCP client.
65027c30caafb24f939dcc0eab716454c39bd6fe 28-Jan-2016 Lorenzo Colitti <lorenzo@google.com> Merge "Unbreak the code that chooses the DHCP client." into mm-wireless-dev
46c47eee5d6f557f8f1652051e5b8f0a6ed01020 27-Jan-2016 Lorenzo Colitti <lorenzo@google.com> Unbreak the code that chooses the DHCP client.

https://partner-android-review.googlesource.com/#/c/516526/ broke
the code that chooses the DHCP client, by writing code that in
effect did:

if (setting) {
use legacy DHCP client;
} else {
use legacy DHCP client;
}

This means that both mm-wireless-dev and master are using the
legacy DHCP client all the time, which we did not use in M.

Change-Id: I9f5cee93262d001f9363b9c91840add1a8c9a4a6
om/android/server/wifi/FrameworkFacade.java
om/android/server/wifi/WifiStateMachine.java
a8f4fbe984b2ee4a10a98d71f61bbb7c3065c5f2 27-Jan-2016 Glen Kuhne <kuh@google.com> Merge "WifiMetric shorter proto dump" into mm-wireless-dev
am: b8bf980e58

* commit 'b8bf980e5827fb97d1b3ad5debcea74d5ad8db8b':
WifiMetric shorter proto dump
11638f348ba45f9f417928e79b81186cef76c561 27-Jan-2016 Glen Kuhne <kuh@google.com> WifiMetric shorter proto dump

Before, proto was dumped as part of the standard Wifi dump using:
'dumpsys wifi proto'
Now, proto is dumped on its own using:
'dumpsys wifi wifiMetricsProto'
This reduces dump size significantly. The old dumpsys argument is no
longer used to dump the proto.

BUG=25691077

Change-Id: I7c7d09b906b11af7842d07fc719bf52dca9ba438
om/android/server/wifi/WifiMetrics.java
om/android/server/wifi/WifiServiceImpl.java
2e09c384f5ce86061b115f20fe3ca75a175d87f0 26-Jan-2016 Etan Cohen <etancohen@google.com> NAN: add message ID to correlate message callbacks to original message

Add message ID to be specified by caller to each message. Same message ID
is provided back in callbacks indicating message send success or failure.

Message ID is purely used as a caller-side object - the service doesn't use
the contents in any way.

Bug: 26769293
Change-Id: Ib1243f42473ecbd616a6c620d2fff4aa9d3a0d73
om/android/server/wifi/nan/WifiNanServiceImpl.java
om/android/server/wifi/nan/WifiNanSessionState.java
om/android/server/wifi/nan/WifiNanStateManager.java
58ca3b3efbe38a3a13bba21ee312a610616fa57c 27-Jan-2016 Rubin Xu <rubinxu@google.com> Merge "Support multiple CA certificates for EAP network" into mm-wireless-dev
am: fbda49b838

* commit 'fbda49b838947610deb378d501c686965fef134e':
Support multiple CA certificates for EAP network
fbda49b838947610deb378d501c686965fef134e 27-Jan-2016 Rubin Xu <rubinxu@google.com> Merge "Support multiple CA certificates for EAP network" into mm-wireless-dev
266600869bd02f51c8351e01a9e415af8257f259 26-Jan-2016 Arthur Hsu <arthurhsu@google.com> Merge "WifiCertManager implementation."
c0428052cf4075a794e5fe34e26f461971fe7243 26-Jan-2016 Bartosz Fabianowski <bartfab@google.com> Update bug numbers referenced by TODOs
am: 7be46e76ac

* commit '7be46e76ac639934f19e84f897cbe8b698e56dff':
Update bug numbers referenced by TODOs
7be46e76ac639934f19e84f897cbe8b698e56dff 26-Jan-2016 Bartosz Fabianowski <bartfab@google.com> Update bug numbers referenced by TODOs

P2 and lower-priority pieces of b/25600871 were split out into their own
bugs. This CL updates bug references in TODOs accordingly.

BUG:25600871
Change-Id: Ic196506b45e87adac390252ff8b0cf5a403214e9
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiStateMachine.java
78463be32c01259841f4c0b670b742c3c2040cf3 29-Nov-2015 Rubin Xu <rubinxu@google.com> Support multiple CA certificates for EAP network

Copy all configured CA certificates to key store and set up their aliases
when adding networks. Remove all certificates when the network is removed.

Bug: 22547958
Change-Id: I91836911bfc84ec2922c5db4e9019a2872f361f0
om/android/server/wifi/WifiConfigStore.java
2bfc67c9893c0a525b224d68dd73a74212b0c29f 20-Jan-2016 Arthur Hsu <arthurhsu@google.com> WifiCertManager implementation.

The WiFiCertManager is essentially a wrapper around the KeyStore that
filters out client certs (and their corresponding private keys) that the
current user should not see.

Change-Id: I1843114c54cb459ceec3d3546055b91f6b177125
om/android/server/wifi/WifiCertManager.java
om/android/server/wifi/WifiServiceImpl.java
e8401edf5e7bdb63261407b0df67cc763463c84c 25-Jan-2016 Mitchell Wills <mwills@google.com> Merge "Updates for gscan HAL updates in N" into mm-wireless-dev
am: 5b6b6d00d8

* commit '5b6b6d00d817acd25b55badf226c42b8d9811399':
Updates for gscan HAL updates in N
5b6b6d00d817acd25b55badf226c42b8d9811399 25-Jan-2016 Mitchell Wills <mwills@google.com> Merge "Updates for gscan HAL updates in N" into mm-wireless-dev
bf54d3375aea13eb0147dbea8a03933b5e83fe3e 25-Jan-2016 Peter Qiu <zqiu@google.com> Correctly log old/new link properties when IP provisioning is lost

Move the logging for new and old link properties when IP provisioning
is lost to before the check for link changes, since the link changed
check would overwrite the old link properties with the new one, results
in logging only the new link properties (which is not quiet useful for
debugging).

Bug: None
Change-Id: I314cb9fc1831dd12a03bbf48fdd93c157ed46e80
om/android/server/wifi/WifiStateMachine.java
037b57b9c5f78b96ea01c31a602e872b35da526e 25-Jan-2016 Bartosz Fabianowski <bartfab@google.com> resolve merge conflicts of bcdabb1fa1 to master.

Change-Id: I93ead6b9e09d6d9ef0361eff42767a75961d8fd3
bcdabb1fa1894fcca610692ec94459fe623afa74 22-Jan-2016 Bartosz Fabianowski <bartfab@google.com> Implement private network configurations in WifiService

* Make ConfigurationMap aware of the current foreground user. Suffix each
accessor with one of:
- ForCurrentUser() (operates on network configurations visible to the
current user only)
- ForAllUsers() (operates on all network configurations)
* Make WifiConfigStore aware of the current foreground user:
- Whenever the user changes, networks that are no longer visible are
disabled and networks that newly became visible are enabled.
- Account for the fact that the configKey cannot be computed from
information stored in wpa_supplicant.conf alone while loading
network configurations from disk.
- Have all public methods that add/remove/modify network configurations
operate on configurations visible to the current foreground user only.

BUG=25600871

Change-Id: Id1e81dd649ac5253c94e65b6a25e239fc3cf09a4
om/android/server/wifi/ConfigurationMap.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiService.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
68ae7112ce5c8d7f871c816cba1f41b2da395ef2 22-Jan-2016 Peter Qiu <zqiu@google.com> Remove WifiWatchdogStateMachine
am: cb8c60a24d

* commit 'cb8c60a24d9e89f3b1aa601e76e38e05f8db6fae':
Remove WifiWatchdogStateMachine
2a6d76f0899289cd3b96e3428f02076fdbc0363e 17-Dec-2015 Mitchell Wills <mwills@google.com> Updates for gscan HAL updates in N

This will compile, but all new functionality may not work

Change-Id: Ia87dbc753e146cd47adb814063ac217508d6caa2
om/android/server/wifi/WifiNative.java
cb8c60a24d9e89f3b1aa601e76e38e05f8db6fae 20-Jan-2016 Peter Qiu <zqiu@google.com> Remove WifiWatchdogStateMachine

Wifi watchdog is not being used anymore, the associated setting
("Settings -> Wi-Fi -> Advanced -> Avoid poor internet connection")
had already been deleted from UI. So remove it.

While there, remove the unused state VerifyingLinkState in WifiStateMachine,
which is only triggered by WifiWatchdogStateMachine.

Bug: 26254553
TEST=runtest frameworks-wifi

Change-Id: Ic7d01d1657f7c737fd22980a7f66434c7667d4ea
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/WifiWatchdogStateMachine.java
b48e8dabf1f3bda2b27c0a070575994cdcd2a2ed 21-Jan-2016 Mitchell Wills <mwills@google.com> Merge "Add some tests for WifiScanningService" into mm-wireless-dev
am: daf5292779

* commit 'daf5292779d8a24d02f8ec51f51b061b535ed667':
Add some tests for WifiScanningService
daf5292779d8a24d02f8ec51f51b061b535ed667 21-Jan-2016 Mitchell Wills <mwills@google.com> Merge "Add some tests for WifiScanningService" into mm-wireless-dev
94bd575cb4766ed0dfbaad0fc7719a9e9e85a260 15-Jan-2016 Mitchell Wills <mwills@google.com> Add some tests for WifiScanningService

Cleanup WifiScanningServiceImpl a little and add a few basic tests
Also cleaned up some tests and added some more utilities

Change-Id: Ic0ac34344de6cf8fa03b741189156916ae35e2a3
om/android/server/wifi/HalWifiScannerImpl.java
om/android/server/wifi/SupplicantWifiScannerImpl.java
om/android/server/wifi/WifiScannerImpl.java
om/android/server/wifi/WifiScanningService.java
om/android/server/wifi/WifiScanningServiceImpl.java
e87e2c32eb31f18c5024b6aa5d491fa5180c2d98 21-Jan-2016 Glen Kuhne <kuh@google.com> Merge "Wifi Metrics, Initial Commit" into mm-wireless-dev
am: 996ff6b8a9

* commit '996ff6b8a9d5a75ef41ad4d1efccb04a915ea2c3':
Wifi Metrics, Initial Commit
996ff6b8a9d5a75ef41ad4d1efccb04a915ea2c3 21-Jan-2016 Glen Kuhne <kuh@google.com> Merge "Wifi Metrics, Initial Commit" into mm-wireless-dev
1b067831bbff14f8e7a99b927b69f714d1b03448 04-Jan-2016 Glen Kuhne <kuh@google.com> Wifi Metrics, Initial Commit

Created WifiMetrics class to log wireless metrics.
Dumps Metrics as Base64 wifi.proto, with dumpsys option 'proto'.
Implements SOME metric collection from wifi service

Bug: 25691077
Change-Id: I28a745b5f66dd1d38868b7eadd79882fd2c5c5a2
om/android/server/wifi/WifiMetrics.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
660f137724789c535e9468cd1572912d57150a53 20-Jan-2016 Randy Pan <zpan@google.com> Merge "Optimize WiFi scanner predefined bucket settings" into mm-wireless-dev
am: a04138fa63

* commit 'a04138fa633a02ed992e1a38decb0eb9a81430e2':
Optimize WiFi scanner predefined bucket settings
a04138fa633a02ed992e1a38decb0eb9a81430e2 20-Jan-2016 Randy Pan <zpan@google.com> Merge "Optimize WiFi scanner predefined bucket settings" into mm-wireless-dev
c6d8e5bb244533d5ce58a5107525bd6bc776cb0d 20-Jan-2016 xin He <xinhe@google.com> Merge "Constant reboots with the latest Dogfood release NYC" into mm-wireless-dev
am: 55a8036f39

* commit '55a8036f3954b99a99bc592bcf3e5ee34cabdabc':
Constant reboots with the latest Dogfood release NYC
55a8036f3954b99a99bc592bcf3e5ee34cabdabc 20-Jan-2016 xin He <xinhe@google.com> Merge "Constant reboots with the latest Dogfood release NYC" into mm-wireless-dev
0d044caad1328809a5f7fb5848e9d488b47911e1 20-Jan-2016 xinhe <xinhe@google.com> Constant reboots with the latest Dogfood release NYC

This crashs happens when user enable untrusted network
but there is no NETWORK_SCORE_SERVICE

BUG=26681441

Change-Id: I1aed84086e9aca179d86675b3756d08e38fb2d4f
om/android/server/wifi/WifiQualifiedNetworkSelection.java
4a7fda19b731474151c768b7284ad325f6c9e46c 20-Jan-2016 Peter Qiu <zqiu@google.com> Run WifiTrafficPoller.TrafficHandler in WifiService thread
am: 8e14dcb9dc

* commit '8e14dcb9dc38149b4672eceb3fe22287ea4343a0':
Run WifiTrafficPoller.TrafficHandler in WifiService thread
8e14dcb9dc38149b4672eceb3fe22287ea4343a0 19-Jan-2016 Peter Qiu <zqiu@google.com> Run WifiTrafficPoller.TrafficHandler in WifiService thread

Currently WifiTrafficPoller.TrafficHandler is running under a non-WiFi
related thread ("SystemServer" thread). Update it to run under
WifiService thread instead.

Bug: 26584131
TEST=Run frameworks-wifi unitests

Change-Id: Ieb151f3609944f47fdd0d1f18fc483786f148342
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiTrafficPoller.java
78c66a6fa8ac2f6c9d3fa74313a4ac8c3585cb18 16-Jan-2016 Randy Pan <zpan@google.com> Optimize WiFi scanner predefined bucket settings

Configure the predefined period values to be PERIOD_MIN_GCD_MS
* 2^N. This helps power saving and cpu utilization.

Updated the scanner unit tests.

Bug: 26588661
Change-Id: I6f62fd8072086843506c9b624c67f959fcdc4ecb
om/android/server/wifi/MultiClientScheduler.java
b48fdddedf38698f6230c07bd921e2f544abce8a 19-Jan-2016 Etan Cohen <etancohen@google.com> Merge changes from topic 'wake_cherry_pick'

* changes:
JNI interface to obtain wlan wake reasons.
Declaration of native JNI call in WiFiNative.java
5deb84dbb62c92a75f16f1f405e52a5dd8619ffc 16-Jan-2016 xinhe <xinhe@google.com> Broken Network Selection Tests
am: c84802f3c6

* commit 'c84802f3c6026f42cd39575d7cf23972ad9fe375':
Broken Network Selection Tests
c84802f3c6026f42cd39575d7cf23972ad9fe375 15-Jan-2016 xinhe <xinhe@google.com> Broken Network Selection Tests

StateMachine.sendMessage is final and can not
be mocked. Use other mothod to verify

BUG=26549815

Change-Id: I4a5fcd682654bd7925a15f1f51be808653f4e9be
om/android/server/wifi/WifiQualifiedNetworkSelection.java
om/android/server/wifi/WifiStateMachine.java
fb44635701d0edc9a76b3c844743b11b7940bd43 18-Dec-2015 Prerepa Viswanadham <dham@google.com> Declaration of native JNI call in WiFiNative.java

Cherry picked from 5ea42964ba17901a8d724736b450ace6ed48880f

Bug: 26572953
Change-Id: I99bae1b598ba3598413e7089bb6a9e68d9e06346
om/android/server/wifi/WifiNative.java
2ba8086441462481427538e1cd8ab0a2c787cebf 15-Jan-2016 xin He <xinhe@google.com> Merge " NullPointerException: Attempt to read from field \'int android.net.wifi.ScanResult.level\' on a null object reference" into mm-wireless-dev
am: 0992d8b7dd

* commit '0992d8b7ddc5530800ad728ee41d8dce60002308':
NullPointerException: Attempt to read from field 'int android.net.wifi.ScanResult.level' on a null object reference
0992d8b7ddc5530800ad728ee41d8dce60002308 15-Jan-2016 xin He <xinhe@google.com> Merge " NullPointerException: Attempt to read from field 'int android.net.wifi.ScanResult.level' on a null object reference" into mm-wireless-dev
387245d75d8b572fbcf3179f477881ade58203e9 15-Jan-2016 xinhe <xinhe@google.com> NullPointerException: Attempt to read from field
'int android.net.wifi.ScanResult.level' on a null
object reference

This bug is due to such a case: The first scan
result belong to a network which is disabled
temporarily or permanently

Also clean the code remove dsiabled network since it is useless.

BUG=26576928

Change-Id: Id4f32f6f85df06659279a363906b63becceb6f76
om/android/server/wifi/WifiQualifiedNetworkSelection.java
80f2b7568ef7e18ffc83dd8f39e222bd9a8f9259 15-Jan-2016 Bartosz Fabianowski <bartfab@google.com> Remove spurious import added by auto-merger

The auto-merger picked up an import statement for a file that does not
exist in master. This CL removes the spurious import.

BUG=25600871

Change-Id: I1934aa33d5d1e60b076d64a61eb2e5c45c212092
om/android/server/wifi/WifiNative.java
921358408d25f4042acaf2d8b73a95a5491c1502 15-Jan-2016 Bartosz Fabianowski <bartfab@google.com> Store configKey in wpa_supplicant.conf
am: fbb081b7c2

* commit 'fbb081b7c28c18f0644701061a1ab38a4627db27':
Store configKey in wpa_supplicant.conf
fbb081b7c28c18f0644701061a1ab38a4627db27 15-Jan-2016 Bartosz Fabianowski <bartfab@google.com> Store configKey in wpa_supplicant.conf

With per-user networks, the data normally present in wpa_supplicant.conf
will no longer be sufficient to reconstruct a network's configKey. The
configKey must thus explicitly be stored with each wpa_supplicant.conf
entry.

The wpa_supplicant.conf format provides a single variable for keeping
such metadata, "id_str". Since that variable is already used to store the
FQDN for Passpoint networks, it must be extended to hold both the FQDN
and the configKey. This is done by changing the variable's data format to
a serialized JSON dictionary. For future reference, the configuration's
creator UID is also added to the dictionary.

BUG=25600871

Change-Id: I2d63e21d1a87bb9645fed957479dcdb3d2642e38
om/android/server/wifi/ConfigurationMap.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiNative.java
31921cc78d7c997dff60a4cbd3f1bf29b3a63fed 15-Jan-2016 Bartosz Fabianowski <bartfab@google.com> Merge "Revert "Store configKey in wpa_supplicant.conf"" into mm-wireless-dev
am: 0fd73e0888

* commit '0fd73e0888e297a7a01118f0552783f5ff4ec39d':
Revert "Store configKey in wpa_supplicant.conf"
4fe40b729af7ef20685004516dd85f79d4c57eda 15-Jan-2016 Bartosz Fabianowski <bartfab@google.com> Revert "Restore import order"
am: 1b45ac8ca6

* commit '1b45ac8ca62c6a82813871ebe8e3df24dc2f9d0e':
Revert "Restore import order"
39c3574fa3be035eafbf86462f3ca1bb859060fa 15-Jan-2016 Bartosz Fabianowski <bartfab@google.com> Revert "Store configKey in wpa_supplicant.conf"

This reverts commit 3552d3bc8329aa9bc843f62c3a854e5ad2b41037.

Change-Id: Ib0d425baa3ac38a20d3ba660e5e5da490a1551e0
om/android/server/wifi/ConfigurationMap.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiNative.java
1b45ac8ca62c6a82813871ebe8e3df24dc2f9d0e 15-Jan-2016 Bartosz Fabianowski <bartfab@google.com> Revert "Restore import order"

This reverts commit d56219f62d7bd1104c0d76fbc187ec8378a030f6.

Change-Id: I36b8c218c15ea569e4a267933203fc63ada67038
om/android/server/wifi/WifiNative.java
ef73682633c428f70157e33bccb4897e22492281 15-Jan-2016 Bartosz Fabianowski <bartfab@google.com> Restore import order
am: d56219f62d

* commit 'd56219f62d7bd1104c0d76fbc187ec8378a030f6':
Restore import order
d56219f62d7bd1104c0d76fbc187ec8378a030f6 15-Jan-2016 Bartosz Fabianowski <bartfab@google.com> Restore import order

As part of "Store configKey in wpa_supplicant.conf", I tidied up the
order of imports as advised by the checkstyle script. For some reason,
that is causing one of the imports to not be found. This CL reverts the
import order to fix the build breakage.

BUG=25600871

Change-Id: I5e6bf2545d2070026537dd73533f731da5aee854
om/android/server/wifi/WifiNative.java
73b19b3084d21a3fa9227b4b6723a1fd20fb2e5c 15-Jan-2016 Bartosz Fabianowski <bartfab@google.com> Store configKey in wpa_supplicant.conf
am: 3552d3bc83

* commit '3552d3bc8329aa9bc843f62c3a854e5ad2b41037':
Store configKey in wpa_supplicant.conf
3552d3bc8329aa9bc843f62c3a854e5ad2b41037 14-Jan-2016 Bartosz Fabianowski <bartfab@google.com> Store configKey in wpa_supplicant.conf

With per-user networks, the data normally present in wpa_supplicant.conf
will no longer be sufficient to reconstruct a network's configKey. The
configKey must thus explicitly be stored with each wpa_supplicant.conf
entry.

The wpa_supplicant.conf format provides a single variable for keeping
such metadata, "id_str". Since that variable is already used to store the
FQDN for Passpoint networks, it must be extended to hold both the FQDN
and the configKey. This is done by changing the variable's data format to
a serialized JSON dictionary. For future reference, the configuration's
creator UID is also added to the dictionary.

BUG=25600871

Change-Id: I01518fee6237f4cf60efa4be92c3c7a1aff32704
om/android/server/wifi/ConfigurationMap.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiNative.java
938651399d38ba46e7c588785ff7ec0b177fcb84 15-Jan-2016 Vinit Deshpande <vinitd@google.com> Merge "Fix broken WifiStateMachine tests" into mm-wireless-dev
am: 7bec7def69

* commit '7bec7def6968a224f026df852d744011030b9c1b':
Fix broken WifiStateMachine tests
c5ab6bc3c683f9d97e1af9887136a44fce133afc 15-Jan-2016 Vinit Deshpande <vinitd@google.com> Merge "Unit test for WifiController\'s emergency mode behaviors" into mm-wireless-dev
am: 859240c33a

* commit '859240c33a7af91ed5cfe64813a0d296981d2f63':
Unit test for WifiController's emergency mode behaviors
5fa540c1bf4e4529ed892b9526cf9c661c04c578 15-Jan-2016 Vinit Deshpande <vinitd@google.com> Merge "Allow turning off Wi-Fi when emergency call is made" into mm-wireless-dev
am: a84fd7d178

* commit 'a84fd7d178aedbea7ba73bd68c810fb4294f3094':
Allow turning off Wi-Fi when emergency call is made
7bec7def6968a224f026df852d744011030b9c1b 15-Jan-2016 Vinit Deshpande <vinitd@google.com> Merge "Fix broken WifiStateMachine tests" into mm-wireless-dev
859240c33a7af91ed5cfe64813a0d296981d2f63 15-Jan-2016 Vinit Deshpande <vinitd@google.com> Merge "Unit test for WifiController's emergency mode behaviors" into mm-wireless-dev
a84fd7d178aedbea7ba73bd68c810fb4294f3094 15-Jan-2016 Vinit Deshpande <vinitd@google.com> Merge "Allow turning off Wi-Fi when emergency call is made" into mm-wireless-dev
a3b6ba415e187a5b4ac07f007373dffde5d9fe10 15-Jan-2016 xin He <xinhe@google.com> Merge "Broken WifiStateMachine and Network Selection Test" into mm-wireless-dev
am: f26259a93c

* commit 'f26259a93c77a0069deb46ca29a864de31c99ba6':
Broken WifiStateMachine and Network Selection Test
f26259a93c77a0069deb46ca29a864de31c99ba6 15-Jan-2016 xin He <xinhe@google.com> Merge "Broken WifiStateMachine and Network Selection Test" into mm-wireless-dev
f7c95ec09ee41c4ab06c1effa6d9cf3b13a2e664 15-Jan-2016 Vinit Deshpande <vinitd@google.com> Fix broken WifiStateMachine tests

Removal of a facade call is causing these to fail

Change-Id: I981ed0b65b9c63cdd78bbfbd71b87cb903467fed
om/android/server/wifi/WifiStateMachine.java
79a4204d12f32d2f6a4dfc8500f5e74718cabb8d 14-Jan-2016 Vinit Deshpande <vinitd@google.com> Unit test for WifiController's emergency mode behaviors

Change-Id: Ic3d8618501632d449bbd3432b95542ac92f336e4
om/android/server/wifi/WifiController.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiSettingsStore.java
89c1bd779fcf2e4631a5da21333ef7775b397050 15-Jan-2016 Vinit Deshpande <vinitd@google.com> resolve merge conflicts of 7e03151407 to master.

Change-Id: I7ab6a5e2fa7fd3a6502ddf5e02e2fa64b4493a63
5aa63dd6c8a00c9dea40a2105c5a774c19c58cb3 15-Jan-2016 Etan Cohen <etancohen@google.com> resolve merge conflicts of 17b7a79520 to master.

Change-Id: I779f8bbf80a3d08b119078d31960fda0951723f4
090aa74f2d36010abba6563a39c87ab7ba8a7473 14-Jan-2016 Vinit Deshpande <vinitd@google.com> Allow turning off Wi-Fi when emergency call is made

Bug: 24147407

Change-Id: I52db1b34df318d0754b1c316806712a61fc3a1f5
om/android/server/wifi/WifiController.java
om/android/server/wifi/WifiServiceImpl.java
7e0315140767e6f12200f7dbbe7aff43b4f75089 13-Nov-2015 Vinit Deshpande <vinitd@google.com> Capture kernel logs with bugreport

This change captures kernel logs along with Wifi firmware
dump; since lost kernel logs have been a big reason for
unresolved bugs.

It also ensures that we dump version information regardless
of whether or not firmware debugging is ON.

Change-Id: I3e44e4b34af3d5d878de242aa344d2950d9b3b1e
om/android/server/wifi/BaseWifiLogger.java
om/android/server/wifi/WifiLogger.java
om/android/server/wifi/WifiNative.java
3ff269ca67e73f66ac22049fc318b2f86eafb253 13-Jan-2016 Vinit Deshpande <vinitd@google.com> Guard against HAL returning null scan results [DO NOT MERGE]

Bug: 26374148

Change-Id: I3355f969f237fd4ba50e980f83bcbcacc7e55c84
om/android/server/wifi/WifiNative.java
97c5ad54fcc5499d22292e65114ea332e6e39352 15-Jan-2016 Vinit Deshpande <vinitd@google.com> Merge "Reset idenitities for EAP-SIM networks when SIM is pulled [DO NOT MERGE]" into mm-wireless-dev
17b7a795202659694aeb21e45b4dd4a4b016ac4d 15-Jan-2016 Etan Cohen <etancohen@google.com> Merge "NAN: initial service implementation for discovery" into mm-wireless-dev
2ada3ea8a48bfc8202d692a70bde6bc14708b4b5 07-Jan-2016 Vinit Deshpande <vinitd@google.com> Reset idenitities for EAP-SIM networks when SIM is pulled [DO NOT MERGE]

This change resets identity and anonymous_identity for all
netorks that use SIM based auth. This ensures that all cached
data is destoryed when SIM is removed; and newly added SIM
must be authorized on the network to connect again.

Bug: 23703716

Change-Id: I83d80336b2089c73d99214651b64b79443faf7f7
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
e978c4348f2dc0d0af3393f669ce382d7e1a841a 15-Jan-2016 Vinit Deshpande <vinitd@google.com> Merge "Appropriately fail EAP-SIM/AKA when SIM doesn't generate good response [DO NOT MERGE]" into mm-wireless-dev
8f3ec73d1ce52b3f23e4cccd6a202b5707874f46 15-Jan-2016 xinhe <xinhe@google.com> Broken WifiStateMachine and Network Selection Test

Fix the broken on Network Selection Test

BUG=26549815

Change-Id: I1e331c6c677b050b3625ca708c8513dcbd3c192f
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiStateMachine.java
df9b18c89d406a346aa6c55cd168dcd907037fc8 15-Jan-2016 xin He <xinhe@google.com> Merge "Device restarted multiple times upon tapping any option in settings after performing tap and go V2" into mm-wireless-dev
am: 68bca95e16

* commit '68bca95e166d3af64dc7b519a06a2ee0bc062588':
Device restarted multiple times upon tapping any option in settings after performing tap and go V2
956f54b391677d78379729dd14518edddf3c7660 29-Sep-2015 Etan Cohen <etancohen@google.com> NAN: initial service implementation for discovery

Initial NAN service implementation. Supports:
- Configuration
- Publish/Subscribe = Discovery
- Message passing
- Notifications

Bug: 26216681
Change-Id: I1f84a6006cec3c3ed9a4566a79b1b4f8dcecde08
om/android/server/wifi/WifiNative.java
om/android/server/wifi/nan/WifiNanClientState.java
om/android/server/wifi/nan/WifiNanNative.java
om/android/server/wifi/nan/WifiNanService.java
om/android/server/wifi/nan/WifiNanServiceImpl.java
om/android/server/wifi/nan/WifiNanSessionState.java
om/android/server/wifi/nan/WifiNanStateManager.java
68bca95e166d3af64dc7b519a06a2ee0bc062588 15-Jan-2016 xin He <xinhe@google.com> Merge "Device restarted multiple times upon tapping any option in settings after performing tap and go V2" into mm-wireless-dev
21a7287737e8b2a122b07d63a7393868101a99a1 15-Jan-2016 xinhe <xinhe@google.com> Device restarted multiple times upon tapping any option in
settings after performing tap and go V2

This is due to print the wrong configuration information
and check the pointer before use

BUG=26564614

Change-Id: I19505646c78d2dd8c469805c6775ec71611c35bd
om/android/server/wifi/WifiStateMachine.java
426f0b86c837307c8ea6d49003c7feccf426fe1a 14-Jan-2016 Mitchell Wills <mwills@google.com> Fix a couple bugs in WifiScanner and improve tests
am: 2771787818

* commit '2771787818003e53e8175036a3d09688c783f350':
Fix a couple bugs in WifiScanner and improve tests
2771787818003e53e8175036a3d09688c783f350 07-Jan-2016 Mitchell Wills <mwills@google.com> Fix a couple bugs in WifiScanner and improve tests

Ordering of scan results for HAL scanner implementation was wrong.
Generated scan results for tests were very similar in some cases leading
to tests missing the bug above. This CL makes generated scan results
dependant on the test case name as well.

Change-Id: Ibb35abf275db3585766be630585d0e3c8870494c
om/android/server/wifi/HalWifiScannerImpl.java
om/android/server/wifi/SupplicantWifiScannerImpl.java
om/android/server/wifi/WifiScannerImpl.java
0c52bc5370597f9ea584d88497c181694a32ad2d 14-Jan-2016 Mitchell Wills <mwills@google.com> Cleanup some of the wifi logging
am: 65b752f1da

* commit '65b752f1da25f028a204a88264380c610866c027':
Cleanup some of the wifi logging
65b752f1da25f028a204a88264380c610866c027 14-Jan-2016 Mitchell Wills <mwills@google.com> Cleanup some of the wifi logging

There were many things that were being logged as errors that
weren't. This either removes those log statements entirely if they are no
longer needed or reduces the log level.

Change-Id: I4a150b7bb862b187cb52d03a9714ddfc496a775b
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiScanningServiceImpl.java
om/android/server/wifi/WifiServiceImpl.java
26eebecc04b55129a902d1e7b670fe05668c14fa 07-Jan-2016 Vinit Deshpande <vinitd@google.com> Appropriately fail EAP-SIM/AKA when SIM doesn't generate good response [DO NOT MERGE]

This change instructs supplicant to terminate the eapol when bad
reponses are obtained from call to getIccSimChallengeResponse; it
ensures that the failed connections terminate early and connection
times are reduced.

(cherry-picked from master
sha1: 5ebc35f19feab2755a13cf7d5acaeff4bbc78994)

Bug: 23703236
Change-Id: I8eb8edde7a8bb310d73d1b3cc8bc060647e2375f
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
f2de9d11f230272b49c5fd62c98058386b841b8a 14-Jan-2016 Randy Pan <zpan@google.com> Fix multi client scheduler bucket creation
am: 2fb3b7ef14

* commit '2fb3b7ef1446f6963f95600f1a5cf395ee7439ec':
Fix multi client scheduler bucket creation
2fb3b7ef1446f6963f95600f1a5cf395ee7439ec 14-Jan-2016 Randy Pan <zpan@google.com> Fix multi client scheduler bucket creation

Use the real time active regular bucket count value instead of
its initial value when compacting buckets.

Bug: 26550853
Change-Id: I3ae1fb2a741bb56b1e9ceb6ea363b8685ecf1f29
om/android/server/wifi/MultiClientScheduler.java
e5048be9b96c84659631fd5a95a2c80242df859d 14-Jan-2016 Vinit Deshpande <vinitd@google.com> Allow turning off Wi-Fi when emergency call is made [DO NOT MERGE]

Bug: 24147407

Change-Id: I52db1b34df318d0754b1c316806712a61fc3a1f5
om/android/server/wifi/WifiController.java
om/android/server/wifi/WifiServiceImpl.java
ea8d2bc41b1db1f38237f19db344a212e244cf13 14-Jan-2016 xin He <xinhe@google.com> Merge "Initial codes for Quality network selection"
5da1f05c912128e7880c832e7995bdd5884cf7a0 01-Dec-2015 xinhe <xinhe@google.com> Initial codes for Quality network selection

In this change list, the old WifiAutojoin module is
refactored initially. The old WifiAutojoinController is
replaced with a new WifiQualifiedNetworkSelector.
WifiConfiguration, WifiConfigureStore and
WifiStateMachine have been modified accordingly. The new
network selection logic is refactored with a more clear
and deterministci one. To refer to thedescribed in
details, in "Quality Network Selection and Connectivity
Scan Management in N". The link of the document is:
https://docs.google.com/document/d
/1JPTa2NEk-PgjCJ16fIrR6ohV-kDKveDlYDOeiMCB2_c

Also the initial unit test codes are added. Test case of
5GHz network over 2GHz network is added.

cherry-picked from 8f0f666c8bdaf508f191f8590755140b92d970ea
Bug:26012244
Change-Id: I60d676a1589de0e0417fbf44ab75ab0ef7cedc85
om/android/server/wifi/SupplicantStateTracker.java
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiQualifiedNetworkSelection.java
om/android/server/wifi/WifiStateMachine.java
3072998deeec2fbf78fbcfd8bf10d16a8d27dc59 13-Jan-2016 Rebecca Silberstein <silberst@google.com> Merge "Tests for InformationElementUtil" into mm-wireless-dev
am: 611faf5ce1

* commit '611faf5ce1f33711b71294aa0245f164bb3b09da':
Tests for InformationElementUtil
611faf5ce1f33711b71294aa0245f164bb3b09da 13-Jan-2016 Rebecca Silberstein <silberst@google.com> Merge "Tests for InformationElementUtil" into mm-wireless-dev
6a6e335012652ab68aabf56bc98770046629d1a0 13-Jan-2016 Randy Pan <zpan@google.com> Merge changes I259c735c,Ia8006f3e into mm-wireless-dev
am: 932de59143

* commit '932de591430383f0704d1cec2e61b8f2b1657ee0':
Exponential back off scan unit tests
Scanner scheduler support for special scan request
b907b456dfba8417b913508533145e374e40c2b7 13-Jan-2016 xin He <xinhe@google.com> Merge "Initial codes for Quality network selection [DO NOT MERGE]" into mm-wireless-dev
932de591430383f0704d1cec2e61b8f2b1657ee0 13-Jan-2016 Randy Pan <zpan@google.com> Merge changes I259c735c,Ia8006f3e into mm-wireless-dev

* changes:
Exponential back off scan unit tests
Scanner scheduler support for special scan request
9a3910bf92b44ece75c53bb88f05615ff500b64c 13-Jan-2016 Jan Nordqvist <jannq@google.com> Merge "Drop checks for locked WiFi key store when installing keys/certs."
8bfdddc25c3ed7da67baf954cf13052ee81009ab 13-Jan-2016 Vinit Deshpande <vinitd@google.com> Guard against HAL returning null scan results am: 549225687b
am: 0b457a8117

* commit '0b457a8117bf23c996a76ecf89dcc46dfa3b9c50':
Guard against HAL returning null scan results
e920c0f1b632d8edb40c44a6db86440aef3282a1 13-Jan-2016 Vinit Deshpande <vinitd@google.com> Reset idenitities for EAP-SIM networks when SIM is pulled am: fdce524fd0
am: 83a6330e24

* commit '83a6330e24d3b829580504920d292ac2c7f51700':
Reset idenitities for EAP-SIM networks when SIM is pulled
afa00a39e89927b59d4002ed2712c136bec27020 13-Jan-2016 Vinit Deshpande <vinitd@google.com> Appropriately fail EAP-SIM/AKA when SIM doesn\'t generate good response am: 5ebc35f19f
am: 919d54801a

* commit '919d54801a367e9ec9fcdfcfd1133d4a09d29bbe':
Appropriately fail EAP-SIM/AKA when SIM doesn't generate good response
0b457a8117bf23c996a76ecf89dcc46dfa3b9c50 13-Jan-2016 Vinit Deshpande <vinitd@google.com> Guard against HAL returning null scan results
am: 549225687b

* commit '549225687bc441fff055c58c777498f83b8cc29f':
Guard against HAL returning null scan results
5bf4e69ad25b09eeb6b0ba66f33b772b223f7b93 13-Jan-2016 Mitchell Wills <mwills@google.com> Disable registering for scan events in SupplicantWifiScannerImpl
am: 7d2d8c2764

* commit '7d2d8c27647676c51208e417afbb8dd6c6784b7c':
Disable registering for scan events in SupplicantWifiScannerImpl
7d2d8c27647676c51208e417afbb8dd6c6784b7c 13-Jan-2016 Mitchell Wills <mwills@google.com> Disable registering for scan events in SupplicantWifiScannerImpl

This interferes with WifiStateMachine getting scan events when the gscan
HAL is not supported

Bug: 26501100
Change-Id: I660f2457d4277a73be70467a463b9b9cf2944f83
om/android/server/wifi/HalWifiScannerImpl.java
om/android/server/wifi/SupplicantWifiScannerImpl.java
549225687bc441fff055c58c777498f83b8cc29f 13-Jan-2016 Vinit Deshpande <vinitd@google.com> Guard against HAL returning null scan results

Bug: 26374148
Change-Id: I3355f969f237fd4ba50e980f83bcbcacc7e55c84
om/android/server/wifi/WifiNative.java
83a6330e24d3b829580504920d292ac2c7f51700 13-Jan-2016 Vinit Deshpande <vinitd@google.com> Reset idenitities for EAP-SIM networks when SIM is pulled
am: fdce524fd0

* commit 'fdce524fd05844c996cf1c5c0c102a87fde8e32c':
Reset idenitities for EAP-SIM networks when SIM is pulled
919d54801a367e9ec9fcdfcfd1133d4a09d29bbe 13-Jan-2016 Vinit Deshpande <vinitd@google.com> Appropriately fail EAP-SIM/AKA when SIM doesn\'t generate good response
am: 5ebc35f19f

* commit '5ebc35f19feab2755a13cf7d5acaeff4bbc78994':
Appropriately fail EAP-SIM/AKA when SIM doesn't generate good response
8f0f666c8bdaf508f191f8590755140b92d970ea 01-Dec-2015 xinhe <xinhe@google.com> Initial codes for Quality network selection [DO NOT MERGE]

In this change list, the old WifiAutojoin module is
refactored initially. The old WifiAutojoinController is
replaced with a new WifiQualifiedNetworkSelector.
WifiConfiguration, WifiConfigureStore and
WifiStateMachine have been modified accordingly. The new
network selection logic is refactored with a more clear
and deterministci one. To refer to thedescribed in
details, in "Quality Network Selection and Connectivity
Scan Management in N". The link of the document is:
https://docs.google.com/document/d
/1JPTa2NEk-PgjCJ16fIrR6ohV-kDKveDlYDOeiMCB2_c

Also the initial unit test codes are added. Test case of
5GHz network over 2GHz network is added.

Bug:26012244

Change-Id: I8dc240115c0625c0fae13a5b3965f70556040448
om/android/server/wifi/SupplicantStateTracker.java
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiQualifiedNetworkSelection.java
om/android/server/wifi/WifiStateMachine.java
fdce524fd05844c996cf1c5c0c102a87fde8e32c 07-Jan-2016 Vinit Deshpande <vinitd@google.com> Reset idenitities for EAP-SIM networks when SIM is pulled

This change resets identity and anonymous_identity for all
networks that use SIM based auth. This ensures that all cached
data is destroyed when SIM is removed; and newly added SIM
must be authorized on the network to connect again.

Bug: 23703716

Change-Id: I83d80336b2089c73d99214651b64b79443faf7f7
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
5ebc35f19feab2755a13cf7d5acaeff4bbc78994 07-Jan-2016 Vinit Deshpande <vinitd@google.com> Appropriately fail EAP-SIM/AKA when SIM doesn't generate good response

This change instructs supplicant to terminate the eapol when bad
reponses are obtained from call to getIccSimChallengeResponse; it
ensures that the failed connections terminate early and connection
times are reduced.

Bug: 23703236
Change-Id: I8eb8edde7a8bb310d73d1b3cc8bc060647e2375f
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
55b76cb796b79397360603cf327710848f93c48d 08-Jan-2016 Randy Pan <zpan@google.com> Scanner scheduler support for special scan request

Extend the multi client scanner scheduler to support sepcial scan
requests, such as exponential back off scan and context hub scan.

Addressed the checkstyle.py complaints in this file.

Bug: 26236392
Change-Id: Ia8006f3eb84f676cbee909195089397cebd3304b
om/android/server/wifi/MultiClientScheduler.java
18772539a3c8fd0855f5f725e8c6998c0f482eec 12-Jan-2016 Jan Nordqvist <jannq@google.com> Drop checks for locked WiFi key store when installing keys/certs.

The security provided by the PIN lock is not considered to provide
any added value over disk encryption for the protection of the WiFi
key store.
In addition the PIN lock is major hurdle for onboarding 802.1X users
who do need a trust cert installed.

BUG=25887356

Change-Id: I137aecd4b0c8593a48f30043d6f1f9b62b8120ff
om/android/server/wifi/WifiConfigStore.java
da51c12f413d54517aea317e37ba82e45d1e4a30 16-Dec-2015 Rebecca Silberstein <silberst@google.com> Tests for InformationElementUtil

Add tests for parsing InformationElements. Covers multiple types of invalid
input.

In addition, added check to parseInformationElements to check for null
input. If the input byte array is null, returns an empty
InformationElement array.

Bug: 26228026
Change-Id: I49e0f6ca938e07c7d961853279645f8511dbd0c3
om/android/server/wifi/util/InformationElementUtil.java
e5b3ea90b17af7347541534cdeec93fc0a554f1b 08-Jan-2016 Vinit Deshpande <vinitd@google.com> Merge "First WifiStateMachine UnitTests" into mm-wireless-dev
am: 57483a79c2

* commit '57483a79c2f9d5a9fe3e950553d95f3ad75842a3':
First WifiStateMachine UnitTests
eee1d479d8d402a2e78e2f143e957030cfc77749 29-Dec-2015 Vinit Deshpande <vinitd@google.com> First WifiStateMachine UnitTests

Change-Id: I044b54f18f1a75b5b33c3fc9fc71a8da820d2521
om/android/server/wifi/BaseWifiLogger.java
om/android/server/wifi/DummyWifiLogger.java
om/android/server/wifi/FrameworkFacade.java
om/android/server/wifi/SupplicantStateTracker.java
om/android/server/wifi/WifiApConfigStore.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiLogger.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/p2p/WifiP2pServiceImpl.java
7cbde334a29f9914889e98b56f30751976b532d6 28-Dec-2015 Vinit Deshpande <vinitd@google.com> Fix crash caused by a race condition [DO NOT MERGE]

(cherry-picked from master
sha1: ae5144e8dd634f68a5a112e9ad17e31dbd70158b)

Bug: 26271785
Change-Id: Ie3e13eb68596b6e1756cacae5d5f88acc97289bc
om/android/server/wifi/WifiStateMachine.java
7126dc1758b16872ab66313803753d735b988a40 05-Jan-2016 Mitchell Wills <mwills@google.com> Some improvements for WifiScanner scheduler
am: 1a16020f8d

* commit '1a16020f8d611c94797884b212ee6a26817fad82':
Some improvements for WifiScanner scheduler
1a16020f8d611c94797884b212ee6a26817fad82 16-Dec-2015 Mitchell Wills <mwills@google.com> Some improvements for WifiScanner scheduler

Make sure that bands are used instead of channels lists if they can
represent all requested channels.
Only deliver the maximum number of bssids requested and no more.
Make sure chips maximum number of bssids per scan is respected.

Bug: 26217163

Change-Id: Iac9cd9f3983f2e1397aec7802155358516d154bf
om/android/server/wifi/MultiClientScheduler.java
5a37587a6888439f43ef24d9225033357f42222b 05-Jan-2016 Mitchell Wills <mwills@google.com> Add support for oneshot scan API in supplicant WifiScannerImpl
am: 5fa6221c4e

* commit '5fa6221c4e507cbc596b6de77d793ec08d690157':
Add support for oneshot scan API in supplicant WifiScannerImpl
29e270080753e4fb63678389f692bdbe7fac0604 05-Jan-2016 Mitchell Wills <mwills@google.com> Make HAL oneshot wifi scans use wpa_supplicant
am: f2f6f79242

* commit 'f2f6f79242454ff9161f5af772292fa0180436f8':
Make HAL oneshot wifi scans use wpa_supplicant
5fa6221c4e507cbc596b6de77d793ec08d690157 12-Dec-2015 Mitchell Wills <mwills@google.com> Add support for oneshot scan API in supplicant WifiScannerImpl

Implement startSingleScan for in SupplicantWifiScannerImpl
Also some style cleanup in SupplicantWifiScannerImpl
Refactor HalWifiScanner tests to be a base for both supplicant and hal
implementations

Change-Id: Ic6d4db7acda39207861bad8b33ddb433c3917b8b
om/android/server/wifi/HalWifiScannerImpl.java
om/android/server/wifi/SupplicantWifiScannerImpl.java
f2f6f79242454ff9161f5af772292fa0180436f8 04-Nov-2015 Mitchell Wills <mwills@google.com> Make HAL oneshot wifi scans use wpa_supplicant

Currently this code path isn't used, but will be enabled once the
supplicant scanner implementation also supports the seperate oneshot
scan api

Change-Id: I23ce63172b82b9b4b824093885f78064fc064144
om/android/server/wifi/HalWifiScannerImpl.java
om/android/server/wifi/SupplicantWifiScannerImpl.java
om/android/server/wifi/WifiScannerImpl.java
266a90bc1de766ce46ec8dc48a4b485359773c97 05-Jan-2016 Peter Qiu <zqiu@google.com> Send a failure reply when enabling a network with an invalid ID
am: 74b6bb8904

* commit '74b6bb890405612e69a8305be40743ccdc4884d3':
Send a failure reply when enabling a network with an invalid ID
74b6bb890405612e69a8305be40743ccdc4884d3 04-Jan-2016 Peter Qiu <zqiu@google.com> Send a failure reply when enabling a network with an invalid ID

This avoids the caller from hanging when issuing a CMD_ENABLE_NETWORK
command with an invalid network ID. Since CMD_ENABLE_NETWORK is
a synchronous command, reply is expected in all cases.

Bug: 26259840
Change-Id: Idbf4f2cfc13e6eff7c52a2048a12ad690845ec3b
om/android/server/wifi/WifiStateMachine.java
71e47e7653da09f326c9932349123255b1e56046 30-Dec-2015 Vinit Deshpande <vinitd@google.com> Merge "Fix crash caused by a race condition"
8f7a6f619af3c5edd2add7eb399c724ae067077f 29-Dec-2015 Randy Pan <zpan@google.com> Wifi binary exponential back off scan support
am: 062e3f39e3

* commit '062e3f39e37874fedc01f267de5f4cf7dbebe2b4':
Wifi binary exponential back off scan support
062e3f39e37874fedc01f267de5f4cf7dbebe2b4 17-Dec-2015 Randy Pan <zpan@google.com> Wifi binary exponential back off scan support

Hook up the WiFi service and HAL to support binary exponential
back off scan.

Bug: 26236392
Change-Id: Ia176a0351a8a755f8f2b0237aab0122225094baf
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiScanningServiceImpl.java
ae5144e8dd634f68a5a112e9ad17e31dbd70158b 28-Dec-2015 Vinit Deshpande <vinitd@google.com> Fix crash caused by a race condition

Bug: 26271785
Change-Id: Ie3e13eb68596b6e1756cacae5d5f88acc97289bc
om/android/server/wifi/WifiStateMachine.java
0e3ee3c7c14d604774bfd120c3cc6b43a86ad086 19-Dec-2015 Jan Nordqvist <jannq@google.com> Merge "DO NOT MERGE Fixed ConcurrentModificationException in WifiConfigStore." into mm-wireless-dev
e69488000bff995a0a30a7c45322d5ec0522ab6e 19-Dec-2015 Jan Nordqvist <jannq@google.com> DO NOT MERGE Fixed ConcurrentModificationException in WifiConfigStore.

BUG=26241528
BUG=26271352

Change-Id: I96cc0bb247e5be267c5b424942541e9d4e92b300
om/android/server/wifi/hotspot2/osu/OSUManager.java
ca4d852d155e40c55b9f757c1732191917d2ed91 19-Dec-2015 Jan Nordqvist <jannq@google.com> Fixed ConcurrentModificationException in WifiConfigStore.

BUG=26241528
BUG=26271352

Change-Id: I96cc0bb247e5be267c5b424942541e9d4e92b300
om/android/server/wifi/hotspot2/osu/OSUManager.java
5ea42964ba17901a8d724736b450ace6ed48880f 18-Dec-2015 Prerepa Viswanadham <dham@google.com> Declaration of native JNI call in WiFiNative.java

Change-Id: I99bae1b598ba3598413e7089bb6a9e68d9e06346
om/android/server/wifi/WifiNative.java
4d3f7bb45f7d87b6a14e49295d894ba1f81c2371 17-Dec-2015 Erik Kline <ek@google.com> Merge "Address failure to properly include TAG in logging."
b1f57994b3d976cd6ac69297872f5c2ce38f0a2e 17-Dec-2015 Erik Kline <ek@google.com> Address failure to properly include TAG in logging.

Change-Id: I5c4c6f5c840bd243052b2b2dc2b2dbce762496cc
om/android/server/wifi/WifiStateMachine.java
6dd42662e45750910d8743f7f154269c2755df93 19-Nov-2015 Jan Nordqvist <jannq@google.com> DO NOT MERGE Changed to use special "in-memory" icon command to wpa_supplicant.

Hotspot2.0: Icon query changed to use new command.
Cherry-picked from e511ec7a4f53f7204a85075b23318f9f11c46d94
Bug: 24681079
Change-Id: Iac65eddff82763d42193edfb683266e7b0b8d720
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/anqp/I18Name.java
om/android/server/wifi/hotspot2/IconEvent.java
om/android/server/wifi/hotspot2/SupplicantBridge.java
om/android/server/wifi/hotspot2/WifiNetworkAdapter.java
om/android/server/wifi/hotspot2/osu/IconCache.java
om/android/server/wifi/hotspot2/osu/OSUManager.java
om/android/server/wifi/hotspot2/osu/OSUSocketFactory.java
c813356fd99aab102da69524e8144fe273a2ab54 15-Dec-2015 Adam Lesinski <adamlesinski@google.com> Fix issue with WiFi scan reporting
am: a9fa44d1d9

* commit 'a9fa44d1d9c27b0456849421dbcab921c37c2a74':
Fix issue with WiFi scan reporting
a9fa44d1d9c27b0456849421dbcab921c37c2a74 12-Nov-2015 Adam Lesinski <adamlesinski@google.com> Fix issue with WiFi scan reporting

Need to assign the overridden WorkSource to the member
mScanWorkSource in order to properly finish the scan.

Bug:23868900
Change-Id: Iac13583bd1ecf65513a7e655b46f6e19e588a99d
(cherry picked from commit 60e5908f0df75b9fda15c325f279381783b5d07d)
om/android/server/wifi/WifiStateMachine.java
e511ec7a4f53f7204a85075b23318f9f11c46d94 19-Nov-2015 Mitchell Wills <mwills@google.com> Changed to use special "in-memory" icon command to wpa_supplicant.

Hotspot2.0: Icon query changed to use new command.

Bug: 24681079
Change-Id: Iac65eddff82763d42193edfb683266e7b0b8d720
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/anqp/I18Name.java
om/android/server/wifi/hotspot2/IconEvent.java
om/android/server/wifi/hotspot2/SupplicantBridge.java
om/android/server/wifi/hotspot2/WifiNetworkAdapter.java
om/android/server/wifi/hotspot2/osu/IconCache.java
om/android/server/wifi/hotspot2/osu/OSUManager.java
om/android/server/wifi/hotspot2/osu/OSUSocketFactory.java
85f946b14fb6d51ae109d0983261e6721a19d1fa 10-Dec-2015 Randy Pan <zpan@google.com> DO NOT MERGE Revert "fix wifi forget acl"

This reverts commit e65f56fdddd0d7f0b03d6bfe9c979125ded9b7b6.

This is required to get build pass on partner's branch.

Change-Id: Icbb7cefb0d700e5f1236dd0711e94212ad2c7a5f
om/android/server/wifi/WifiServiceImpl.java
41e38d84f562e12198f7db0d45f633712cae6cba 19-Nov-2015 Mitchell Wills <mwills@google.com> Tests for SupplicantWifiScannerImpl

Other small fixes/aids for testing
* deliver full scan results in the order they are returned from
supplicant
* Now use AlarmListener AlarmManager API instead of intents
* Use WifiChannelHelper instead of direct native calls

Change-Id: I3133a21162f598e5e5973ec67ebc9521a3a387ab
om/android/server/wifi/SupplicantWifiScannerImpl.java
297c3acabe7a85eb87240fe3ccf772e57ce6aef7 23-Jul-2015 Mitchell Wills <mwills@google.com> Add multi client batch aware scheduler

WifiScanner can now schedule requests much more intelligently.

Bug: 20956158

Change-Id: Ib852d1d84d8cc798a37660850d5e6f3a206390c1
om/android/server/wifi/MultiClientScheduler.java
om/android/server/wifi/WifiChannelHelper.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiScanningScheduler.java
om/android/server/wifi/WifiScanningService.java
om/android/server/wifi/WifiScanningServiceImpl.java
9ec71f6499e0e3d6f52310a41ff4a59d2fa4f8b2 23-Jul-2015 Mitchell Wills <mwills@google.com> Began implementation of supplicant based WifiScanner HAL

Added WifiScannerImpl with implementations of the HAL scanning
APIs using wpa_supplicant. If the new HAL API is supported then
it is used, otherwise wpa_supplicant is used as a fallback.

Change-Id: Ie9d26b6f0675bba03db8c3327c3e5dcf003a3b16
om/android/server/wifi/HalWifiScannerImpl.java
om/android/server/wifi/SupplicantWifiScannerImpl.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiScannerImpl.java
om/android/server/wifi/WifiScanningServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
36514deaa0890e080185d6d03dd9403b7632ab21 03-Dec-2015 Jan Nordqvist <jannq@google.com> Merge "Network scoring of all WiFi networks, final version."
4b7bc26fb99803f0cedcca16310d345e337f950c 03-Dec-2015 Jan Nordqvist <jannq@google.com> Network scoring of all WiFi networks, final version.

Bug: 25562019
Change-Id: I250cbb823aec6f366bcf2d84e19f7e4a9e75954b
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
4e210ea1c7eb7d3a70792571651181e429b39582 29-Sep-2015 Mitchell Wills <mwills@google.com> Make WifiMonitor a singleton and add explicit event registration

Change-Id: If99cf107abe381d2527a84f7e71c0c8363bff4db
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/p2p/WifiP2pServiceImpl.java
18786eca942042388748b0d98979f21c9dff4a89 20-Nov-2015 Mitchell Wills <mwills@google.com> Turn WifiNative into a singleton for each interface

Change-Id: Ida8225c1c8434f5cffbdfd2ebbc4a7b240976a15
om/android/server/wifi/RttService.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiLogger.java
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiScanningService.java
om/android/server/wifi/WifiScanningServiceImpl.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/hotspot2/SupplicantBridge.java
om/android/server/wifi/p2p/WifiP2pServiceImpl.java
2bf6258af8315ac7797dde8646a7cd7ed77b70e2 02-Dec-2015 xinhe <xinhe@google.com> WiFi not connecting to WiFi when screen OFF am: e26ad459b6
am: 8613b7330a

* commit '8613b7330a8691ea5cbd2ce0d151ef8c6e8a18e8':
WiFi not connecting to WiFi when screen OFF
8613b7330a8691ea5cbd2ce0d151ef8c6e8a18e8 02-Dec-2015 xinhe <xinhe@google.com> WiFi not connecting to WiFi when screen OFF
am: e26ad459b6

* commit 'e26ad459b63271548abbdeba4f8d77fcca9f88bd':
WiFi not connecting to WiFi when screen OFF
cb8d0007e99af74c69494b3ce720b548566a1bee 02-Dec-2015 Peter Qiu <zqiu@google.com> Merge "Remove unused imports"
d21ed8f3eb29718c3eaacbecdb024841efb17c23 01-Dec-2015 Peter Qiu <zqiu@google.com> Remove unused imports

Bug: None
Change-Id: I4ff51b2be3fa367922dea755e3259cd7b67f10ec
om/android/server/wifi/WifiService.java
cb447f89d6338b5599a564b080b6837e4799506e 30-Nov-2015 Jan Nordqvist <jannq@google.com> Merge "Applied changes from comments."
9a069cba2e5ae31ee00d9ec9a3c25bdb7052aa78 25-Nov-2015 Jan Nordqvist <jannq@google.com> Applied changes from comments.

Bug: 25869687
Change-Id: I79a4ae543e7c3797620bf4492f4794523fac8c4d
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/configparse/ConfigBuilder.java
om/android/server/wifi/hotspot2/omadm/MOManager.java
e26ad459b63271548abbdeba4f8d77fcca9f88bd 19-Nov-2015 xinhe <xinhe@google.com> WiFi not connecting to WiFi when screen OFF

When framework toggle PNO too frequently, the lower layer
(supplicant and driver) can have some corner case errors.
Add minimum gap (5s) between two PNO toggle.

Bug: 24777453

Change-Id: Ic360b753c65b77831dc8395834b9ac125f1aa7a1
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
60e5908f0df75b9fda15c325f279381783b5d07d 12-Nov-2015 Adam Lesinski <adamlesinski@google.com> Fix issue with WiFi scan reporting

Need to assign the overridden WorkSource to the member
mScanWorkSource in order to properly finish the scan.

Bug:23868900
Change-Id: Iac13583bd1ecf65513a7e655b46f6e19e588a99d
om/android/server/wifi/WifiStateMachine.java
19531944ccfdfa2293aacfefcf8e8799c2dd6a15 10-Nov-2015 Mitchell Wills <mwills@google.com> Merge "Revert "Remove WifiScanner significant change implementation""
578f7a33d0085559485bccfe7d1e26f813dc081d 10-Nov-2015 Mitchell Wills <mwills@google.com> Revert "Remove WifiScanner significant change implementation"

This reverts commit 7a6ef782e906f22c9426bd594017843d84c92229.

Change-Id: I6f8f667b0aa8cfb69187e0946de145a7f7025b17
om/android/server/wifi/WifiScanningServiceImpl.java
9f743918a412fec9ad5a0386fbf6cf0361313f58 05-Nov-2015 xinhe <xinhe@google.com> Center frequency is incorrectly parsed for 40MHz

b/25499446

Change-Id: Ice9884f860e4b68ec62d87ed24adeab8864beb3f
om/android/server/wifi/util/InformationElementUtil.java
7a6ef782e906f22c9426bd594017843d84c92229 04-Nov-2015 Mitchell Wills <mwills@google.com> Remove WifiScanner significant change implementation

The API is not used or tested and will not be touched in N.

Change-Id: I2bfbd8b33d51f934704cd70bf3618adb8ac39a9e
om/android/server/wifi/WifiScanningServiceImpl.java
8383c1b0fbdf3eb64653849ba65e0b0f9739f190 31-Oct-2015 Mitchell Wills <mwills@google.com> Merge "Remove old API implementations"
aea5ce790c16ba89be7b306cff812fee01d99acb 30-Oct-2015 Mitchell Wills <mwills@google.com> Merge "Moved Wifi InformationElement parsing to a common utility class"
691908111a2cea40d8afa325a2ebc1bc5b197ea1 30-Oct-2015 Mitchell Wills <mwills@google.com> Merge "Moved scan result parsing from WifiStateMachine to WifiNative"
ad3e8e31131c9347dd7a089f70a85ffcd4066c21 29-Oct-2015 Mitchell Wills <mwills@google.com> Don\'t set RSSI to -1 when no value is returned am: 78ca9b3d6f am: 06f83655f7 am: d5f9ae241e
am: 2aedabd814

* commit '2aedabd814e096bbd7e5fe62d3e76c217c67fb1b':
Don't set RSSI to -1 when no value is returned
2aedabd814e096bbd7e5fe62d3e76c217c67fb1b 29-Oct-2015 Mitchell Wills <mwills@google.com> Don\'t set RSSI to -1 when no value is returned am: 78ca9b3d6f am: 06f83655f7
am: d5f9ae241e

* commit 'd5f9ae241e9fc9842e9bea60ff7f128e7292f055':
Don't set RSSI to -1 when no value is returned
06f83655f769d9649cfd51fda485cd553dfca7cf 29-Oct-2015 Mitchell Wills <mwills@google.com> Don\'t set RSSI to -1 when no value is returned
am: 78ca9b3d6f

* commit '78ca9b3d6fb28abc6d52a31791f4b4084af76e65':
Don't set RSSI to -1 when no value is returned
78ca9b3d6fb28abc6d52a31791f4b4084af76e65 26-Oct-2015 Mitchell Wills <mwills@google.com> Don't set RSSI to -1 when no value is returned

Bug: 19928834
Change-Id: I25eebee0dcd01f7e8ea2791ccdcc75cd1066f3c0
om/android/server/wifi/WifiStateMachine.java
814230f58f5cb96db2a75c95a44c3d5890586486 24-Oct-2015 Mitchell Wills <mwills@google.com> Merge "Check if link stats are supported when reporting activity info"
cb7bc8f6401bfae7cf40aff9e45dcd22fb2daf0d 24-Oct-2015 xin He <xinhe@google.com> Merge "[DO NOT MERGE] Fix build breakage introduced by CL 797896" into mnc-dr-dev am: b5cef8e440 am: 9f4c81f701
am: b8487ba5ce

* commit 'b8487ba5ce4de3624af3141d18f1d3c5d3822e8c':
[DO NOT MERGE] Fix build breakage introduced by CL 797896
9f4c81f7018c3c8a5af1e0784b3c7d0a583ec95b 23-Oct-2015 xin He <xinhe@google.com> Merge "[DO NOT MERGE] Fix build breakage introduced by CL 797896" into mnc-dr-dev
am: b5cef8e440

* commit 'b5cef8e440ee5b054d8b38103aa2d6989c7361ef':
[DO NOT MERGE] Fix build breakage introduced by CL 797896
b5cef8e440ee5b054d8b38103aa2d6989c7361ef 23-Oct-2015 xin He <xinhe@google.com> Merge "[DO NOT MERGE] Fix build breakage introduced by CL 797896" into mnc-dr-dev
dd772a1d2fff70ffcb479422bfcf05ba51f2a2ce 23-Oct-2015 xinhe <xinhe@google.com> [DO NOT MERGE] Fix build breakage introduced by CL 797896

Change-Id: I8ba0ca94c814e833816cab17ae328a95823512fd
om/android/server/wifi/WifiStateMachine.java
89dd25f571aa22ac7a573cd7b6671e1fd4dbb547 23-Oct-2015 xin He <xinhe@google.com> Merge "[DO NOT MERGE] EAP-TLS PMKID mismatch error" into mnc-dr-dev am: e8e62c91f8 am: 0b14bbb35f
am: 292b3ecc53

* commit '292b3ecc53acad6b288920eef58dd7db98d4ec2c':
[DO NOT MERGE] EAP-TLS PMKID mismatch error
0b14bbb35f1561e7ab529e32fe529a041610cc68 23-Oct-2015 xin He <xinhe@google.com> Merge "[DO NOT MERGE] EAP-TLS PMKID mismatch error" into mnc-dr-dev
am: e8e62c91f8

* commit 'e8e62c91f883eff9d0d0729b4bf5ffd6007a9ae4':
[DO NOT MERGE] EAP-TLS PMKID mismatch error
e8e62c91f883eff9d0d0729b4bf5ffd6007a9ae4 23-Oct-2015 xin He <xinhe@google.com> Merge "[DO NOT MERGE] EAP-TLS PMKID mismatch error" into mnc-dr-dev
eb5caea63b1eae6c0739dafa129a4e2e56553118 21-Oct-2015 xinhe <xinhe@google.com> [DO NOT MERGE] EAP-TLS PMKID mismatch error

b/24253154

Change-Id: I992a99d46f94e72564d8d1a2c357f6ff1c53a11d
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiStateMachine.java
5d31cedf4024e0f038b4dfc2081016c8631ee8fe 28-Jul-2015 Mitchell Wills <mwills@google.com> Moved Wifi InformationElement parsing to a common utility class

Change-Id: If3e58aa01ad2a75c0f4942428392c0e7f833143c
om/android/server/wifi/WifiNative.java
om/android/server/wifi/hotspot2/NetworkDetail.java
om/android/server/wifi/util/InformationElementUtil.java
2afa54e3c8fa1153302a0d57b0e9b7bee35406ff 20-Jul-2015 Mitchell Wills <mwills@google.com> Moved scan result parsing from WifiStateMachine to WifiNative

Moving the parsing of the RSS (wifi scan results) command out of
WifiStateMachine and into WifiNative

Change-Id: Iafb7fa04cd0d7d848cfbb879a13f6592eff34004
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
2bb02861ac08054f2c06a71c2077e9be4625b9a4 21-Oct-2015 Pavel Zhamaitsiak <pavelz@google.com> Merge "Disable Portable Wi-Fi hotspot in ECM" into mnc-dr-dev am: 2fd94d6887 am: 02d8a99ce6 am: bba10cdfad
am: 1ca800cc05

* commit '1ca800cc054cb74f5c8324792d4eacbff511525d':
Disable Portable Wi-Fi hotspot in ECM
1ca800cc054cb74f5c8324792d4eacbff511525d 21-Oct-2015 Pavel Zhamaitsiak <pavelz@google.com> Merge "Disable Portable Wi-Fi hotspot in ECM" into mnc-dr-dev am: 2fd94d6887 am: 02d8a99ce6
am: bba10cdfad

* commit 'bba10cdfadc2a9ca5db5720e897ee7a4a14b1f16':
Disable Portable Wi-Fi hotspot in ECM
02d8a99ce6c64e6bd4e0e15cd72efe53bf2e7b22 21-Oct-2015 Pavel Zhamaitsiak <pavelz@google.com> Merge "Disable Portable Wi-Fi hotspot in ECM" into mnc-dr-dev
am: 2fd94d6887

* commit '2fd94d6887868f769adc237fd5b9190e3a3569d3':
Disable Portable Wi-Fi hotspot in ECM
1f8a91389bf7d03635c43df52ca73d353d5a5e94 20-Oct-2015 Pavel Zhamaitsiak <pavelz@google.com> Disable Portable Wi-Fi hotspot in ECM

Bug: 24147407
Change-Id: I254f6f70375774ea9de51be369f6b17437ba20ef
om/android/server/wifi/WifiController.java
e3dbf7f9cca0d7706f2c4de020061d7912e45872 20-Oct-2015 Mitchell Wills <mwills@google.com> Merge "Reduce logging levels of some messages in WifiService"
f9946f5663f2d7a9a69cb8b7e82a4ef8b1825c48 19-Oct-2015 Mitchell Wills <mwills@google.com> Reduce logging levels of some messages in WifiService

Some log messages were marked as errors that weren't

Change-Id: I7309143bafea74b5a7ee4d17d3c105656b86100c
om/android/server/wifi/WifiServiceImpl.java
016284c9e9fd219429c230e373d914f98db6a9a1 19-Oct-2015 Xiaohui Chen <xiaohuic@google.com> Merge "fix wifi forget acl"
a15a2ee69156fa6fff09c0dd9b8182cb8fafde1c 16-Oct-2015 xinhe <xinhe@google.com> Security Vulnerability in android::onPnoNetworkFound [DO NOT MERGE]

Ask for system permission to enable ePNO

b/24872703

Change-Id: I8a7aafdb3f4074089777ad6b1402d4bf4954e81a
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiServiceImpl.java
6c72b28e3b26aad3d2036a25aec0b5a2aba712b1 14-Oct-2015 Fyodor Kupolov <fkupolov@google.com> Fix foreground scans for pre-M apps when location is disabled

Wi-Fi scans should be enabled for legacy foreground apps when location is
disabled.

Bug: 23081999
Change-Id: I09ff32ab9845e989ed292824b7aee84d10d260cf
om/android/server/wifi/WifiServiceImpl.java
31d81f38ad711c458aa474cfe42fb289c82112ac 17-Oct-2015 Fyodor Kupolov <fkupolov@google.com> am 9af17998: am be964f00: am 35f3b9ce: Merge "Fix foreground scans for pre-M apps when location is disabled" into mnc-dr-dev

* commit '9af179986539ea927978f61262a33223f39a5f19':
Fix foreground scans for pre-M apps when location is disabled
be964f00e71597f880c051772e8acd1a44b08e17 17-Oct-2015 Fyodor Kupolov <fkupolov@google.com> am 35f3b9ce: Merge "Fix foreground scans for pre-M apps when location is disabled" into mnc-dr-dev

* commit '35f3b9ce41b43de59487b3231aedc64d735593a8':
Fix foreground scans for pre-M apps when location is disabled
35f3b9ce41b43de59487b3231aedc64d735593a8 17-Oct-2015 Fyodor Kupolov <fkupolov@google.com> Merge "Fix foreground scans for pre-M apps when location is disabled" into mnc-dr-dev
7955da2fd9044beb2663227be4faebf024792123 16-Oct-2015 xin He <xinhe@google.com> am 72790f92: am a8249332: am c9bea298: am f2e7f4fa: Merge "Security Vulnerability in android::onPnoNetworkFound" into mnc-dr-dev

* commit '72790f92ae580758df92444b6f96d7a27bb9571d':
Security Vulnerability in android::onPnoNetworkFound
72790f92ae580758df92444b6f96d7a27bb9571d 16-Oct-2015 xin He <xinhe@google.com> am a8249332: am c9bea298: am f2e7f4fa: Merge "Security Vulnerability in android::onPnoNetworkFound" into mnc-dr-dev

* commit 'a8249332821bd9be23df911aa9e0fbe5eac4f22a':
Security Vulnerability in android::onPnoNetworkFound
c9bea298d4b6d4c9920914d3dc8df23e3c595700 16-Oct-2015 xin He <xinhe@google.com> am f2e7f4fa: Merge "Security Vulnerability in android::onPnoNetworkFound" into mnc-dr-dev

* commit 'f2e7f4fa1ac1481cdbc7bf3296321ac0fa159cc6':
Security Vulnerability in android::onPnoNetworkFound
f2e7f4fa1ac1481cdbc7bf3296321ac0fa159cc6 16-Oct-2015 xin He <xinhe@google.com> Merge "Security Vulnerability in android::onPnoNetworkFound" into mnc-dr-dev
20de5ba628240951562958595d5b6ec8edc2b13e 16-Oct-2015 xinhe <xinhe@google.com> Security Vulnerability in android::onPnoNetworkFound

Ask for system permission to enable ePNO

b/24872703

Change-Id: I8a7aafdb3f4074089777ad6b1402d4bf4954e81a
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiServiceImpl.java
b3fe01d22d2e927d4336eb70518673800881d8f2 16-Oct-2015 Mitchell Wills <mwills@google.com> am 799ee792: am 9d864238: am a8ed84c5: DO NOT MERGE Make sure wifi driver is actually turned off when requested

* commit '799ee792f8d985fe1d24638e9d7d6463dd8d39f9':
DO NOT MERGE Make sure wifi driver is actually turned off when requested
9d86423893492156db7fbc1b4f94ef0517ca9220 16-Oct-2015 Mitchell Wills <mwills@google.com> am a8ed84c5: DO NOT MERGE Make sure wifi driver is actually turned off when requested

* commit 'a8ed84c590e48ce3e5b31b2f3d0ddd53a22b6a65':
DO NOT MERGE Make sure wifi driver is actually turned off when requested
a8ed84c590e48ce3e5b31b2f3d0ddd53a22b6a65 05-Aug-2015 Mitchell Wills <mwills@google.com> DO NOT MERGE Make sure wifi driver is actually turned off when requested

Bug: 22808676
Change-Id: Iddcda4ae77235c789a3e6a96b946bb720f73b122
om/android/server/wifi/WifiStateMachine.java
9bf7c88906843aad03d7c96ebda9a5c6b5a9e683 15-Oct-2015 xin He <xinhe@google.com> Merge "Disable networks with no internet connectivity and user confirmed"
edfae468ff546b7d52f8a7693520f27eecd087e4 28-Aug-2015 xinhe <xinhe@google.com> Disable networks with no internet connectivity and user confirmed

This shall ensure that such networks are not configured by PNO
and thus shall avoid unnecessary host wake ups.

b/23398768

Change-Id: I1a3c0789b1bd25c210b0d22dfd8fc3a43be4c9ef
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiStateMachine.java
4baf08217d550ad01b54bfc2b317b91ce83e0f38 15-Oct-2015 Mitchell Wills <mwills@google.com> am d8ca95d6: am 93fb74bd: am 680ac28c: am 4a7d3850: Merge "Prevent corruption of Wifi scan battery stats" into mnc-dr-dev

* commit 'd8ca95d629ed82926832900c1c910e97ad454f1b':
Prevent corruption of Wifi scan battery stats
d8ca95d629ed82926832900c1c910e97ad454f1b 15-Oct-2015 Mitchell Wills <mwills@google.com> am 93fb74bd: am 680ac28c: am 4a7d3850: Merge "Prevent corruption of Wifi scan battery stats" into mnc-dr-dev

* commit '93fb74bd37bc4d2198e751958cd425073e5c2911':
Prevent corruption of Wifi scan battery stats
680ac28ce035a3765d64dd0e747af942e4438e3c 15-Oct-2015 Mitchell Wills <mwills@google.com> am 4a7d3850: Merge "Prevent corruption of Wifi scan battery stats" into mnc-dr-dev

* commit '4a7d385069e9e1a490d6d2a8427536e1506a5801':
Prevent corruption of Wifi scan battery stats
4a7d385069e9e1a490d6d2a8427536e1506a5801 15-Oct-2015 Mitchell Wills <mwills@google.com> Merge "Prevent corruption of Wifi scan battery stats" into mnc-dr-dev
3b8a078d5ed10a614401375e37a97c239244abd7 15-Oct-2015 Fyodor Kupolov <fkupolov@google.com> am a3de81f4: am d8c80cc7: am e2ba917b: Merge "Do not throw an exception if appop\'s result is MODE_IGNORED" into mnc-dr-dev

* commit 'a3de81f4084bca4f66f58c03dc027aa784dcc1a0':
Do not throw an exception if appop's result is MODE_IGNORED
65ada07fcc88600d1a8c77269f62590f630f7aab 14-Oct-2015 Fyodor Kupolov <fkupolov@google.com> Fix foreground scans for pre-M apps when location is disabled

Wi-Fi scans should be enabled for legacy foreground apps when location is
disabled.

Bug: 23081999
Change-Id: I09ff32ab9845e989ed292824b7aee84d10d260cf
om/android/server/wifi/WifiServiceImpl.java
d8c80cc7ff540c103e48cf298d196a6b66548134 15-Oct-2015 Fyodor Kupolov <fkupolov@google.com> am e2ba917b: Merge "Do not throw an exception if appop\'s result is MODE_IGNORED" into mnc-dr-dev

* commit 'e2ba917b13c0271e018457917a6388a2f84e20ab':
Do not throw an exception if appop's result is MODE_IGNORED
e2ba917b13c0271e018457917a6388a2f84e20ab 15-Oct-2015 Fyodor Kupolov <fkupolov@google.com> Merge "Do not throw an exception if appop's result is MODE_IGNORED" into mnc-dr-dev
5683efb3213ad63499399be823f47f60dd869022 15-Oct-2015 Pankaj Kanwar <pkanwar@google.com> am 7d504906: am 98f03db9: am 7af1ef61: am 7b97c836: Merge "Set hs20 property to 1 when connecting to passpoint network" into mnc-dr-dev

* commit '7d5049066cb72d12c76260f8b5dd108bb8248022':
Set hs20 property to 1 when connecting to passpoint network
d3fa2ae3b11d6260a16aff1aa9ec0cd89b0b341d 15-Oct-2015 Pankaj Kanwar <pkanwar@google.com> am 407844c1: am d1a59e62: am a29ea4f6: am 12a1007d: Merge "Fix center frequency parsing bug." into mnc-dr-dev

* commit '407844c12764def74fe9812fab21d77e15c4e49d':
Fix center frequency parsing bug.
7d5049066cb72d12c76260f8b5dd108bb8248022 15-Oct-2015 Pankaj Kanwar <pkanwar@google.com> am 98f03db9: am 7af1ef61: am 7b97c836: Merge "Set hs20 property to 1 when connecting to passpoint network" into mnc-dr-dev

* commit '98f03db90fd6877598b6b8669fb324c70b9cfb91':
Set hs20 property to 1 when connecting to passpoint network
7af1ef61493d25c333561071dc8bbc3da8f0a86b 15-Oct-2015 Pankaj Kanwar <pkanwar@google.com> am 7b97c836: Merge "Set hs20 property to 1 when connecting to passpoint network" into mnc-dr-dev

* commit '7b97c836ad5ef97635329d09f7772f845713aea6':
Set hs20 property to 1 when connecting to passpoint network
7b97c836ad5ef97635329d09f7772f845713aea6 15-Oct-2015 Pankaj Kanwar <pkanwar@google.com> Merge "Set hs20 property to 1 when connecting to passpoint network" into mnc-dr-dev
407844c12764def74fe9812fab21d77e15c4e49d 15-Oct-2015 Pankaj Kanwar <pkanwar@google.com> am d1a59e62: am a29ea4f6: am 12a1007d: Merge "Fix center frequency parsing bug." into mnc-dr-dev

* commit 'd1a59e6237c00c2fd27f2de1b07954b49086304b':
Fix center frequency parsing bug.
a29ea4f648cc12ad81bc258ad11ae3d63cd4921f 15-Oct-2015 Pankaj Kanwar <pkanwar@google.com> am 12a1007d: Merge "Fix center frequency parsing bug." into mnc-dr-dev

* commit '12a1007dc04897e000f91ae43f9ca90cd7441f9d':
Fix center frequency parsing bug.
12a1007dc04897e000f91ae43f9ca90cd7441f9d 15-Oct-2015 Pankaj Kanwar <pkanwar@google.com> Merge "Fix center frequency parsing bug." into mnc-dr-dev
12167e21e1371720b49055ce69a178727d0ae37c 08-Sep-2015 Fyodor Kupolov <fkupolov@google.com> Do not throw an exception if appop's result is MODE_IGNORED

Previously, an exception was thrown when a result of checking for an app op
was MODE_IGNORED. We should return zero results instead.

Bug: 23675817
Bug: 23563867
Change-Id: Iba6b6eca8a0d21acd77b8d388b8bfe3119cac8f9
om/android/server/wifi/WifiServiceImpl.java
03dab7e3fbd1ebbd4a3e7637f8feae5806ab149d 15-Oct-2015 Mitchell Wills <mwills@google.com> Prevent corruption of Wifi scan battery stats

Ensure that the previous wifi scan is noted as completed before noting
that the next one started. This may happen if a scan starts before the
previous one completes.

Bug: 24250984
Change-Id: I2aaa6131cb5dd4b9deae3bea6e19570f6e24632d
om/android/server/wifi/WifiStateMachine.java
56845c30ef2bc7ccfd92764e4c7352aee03ec3a8 14-Oct-2015 Vinit Deshpande <vinitd@google.com> Set hs20 property to 1 when connecting to passpoint network

Setting this property has some consequences - it will stop
using prohibited security parameters when connecting to AP
and will express some capabilities of the STA.

Bug: 24374083
Change-Id: I80abef812b272ce3384a13e7b3c44e56db4cffbd
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiNative.java
e65f56fdddd0d7f0b03d6bfe9c979125ded9b7b6 13-Oct-2015 Xiaohui Chen <xiaohuic@google.com> fix wifi forget acl

In the new multi user enviroment, we should be checking the admin
flag instead of relying on the user id.

Bug: 24909021
Change-Id: Iea6d100fbb2f2503f4a9bcc523db14a8feb67c56
om/android/server/wifi/WifiServiceImpl.java
001a98d838cf251ee4a39d1a3b1879639076f7b1 07-Oct-2015 Mitchell Wills <mwills@google.com> Remove old API implementations

All of these APIs were hidden and are no longer used by anyone. The scan
APIs are being replaced by the new WifiScanner API

Change-Id: Idae554c99ad9db6c37007d1ea066693713b71388
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
46d6996d9b066e3c165a9c1b0b23dc23cf4bf2c8 13-Oct-2015 Mitchell Wills <mwills@google.com> am 79d76ec0: am 6b6673a2: am ca452804: am d3ae426c: When entering disconnected state imediatly start a scan

* commit '79d76ec0a71d727ac21fa5f19feedd597878f619':
When entering disconnected state imediatly start a scan
79d76ec0a71d727ac21fa5f19feedd597878f619 13-Oct-2015 Mitchell Wills <mwills@google.com> am 6b6673a2: am ca452804: am d3ae426c: When entering disconnected state imediatly start a scan

* commit '6b6673a22801bcbb13c5e0beac7e3bfd3a390de6':
When entering disconnected state imediatly start a scan
ca45280461867c973acb736f6e8efe1518c03dc9 13-Oct-2015 Mitchell Wills <mwills@google.com> am d3ae426c: When entering disconnected state imediatly start a scan

* commit 'd3ae426c1b298f038b34171d13d710524779074e':
When entering disconnected state imediatly start a scan
ac1f408138f092fe2a41cb5898163e05979c1cdd 13-Oct-2015 Wei Wang <weiwa@google.com> Fix center frequency parsing bug.

Bug:24881521

Change-Id: I2d4200c7f4ad03af2564fd3321205409cc2c8b84
om/android/server/wifi/WifiNative.java
d3ae426c1b298f038b34171d13d710524779074e 18-Sep-2015 Mitchell Wills <mwills@google.com> When entering disconnected state imediatly start a scan

This reduces the chance of a scan request being scheduled before this
one runs, which causes it to be marked as obsolete.

Bug: 24000670
Change-Id: I78655a8a20e6354aa69cc796dc053803466f2ddf
om/android/server/wifi/WifiStateMachine.java
6f42772cabf49822bf9595d7060d873a4e5caaa6 12-Oct-2015 Pankaj Kanwar <pkanwar@google.com> am 470f5c17: am b14cbd44: am f76c13a4: am a7d7d91e: Merge "Handle supplicant state changes in non-ConnectModeState" into mnc-dr-dev

* commit '470f5c17a744c202080b475a14bbd9b16fcc3b29':
Handle supplicant state changes in non-ConnectModeState
6846e3eeb3769c4173d04f74930b29b6aa85495a 12-Oct-2015 Mitchell Wills <mwills@google.com> am 4666dd2b: am 0dc1746e: am 082dd48c: am 6d88025b: Merge "Don\'t hold on to last scan results if scan is empty" into mnc-dr-dev

* commit '4666dd2b4ee1f8d6faabfe79a64b1a84be5b0700':
Don't hold on to last scan results if scan is empty
470f5c17a744c202080b475a14bbd9b16fcc3b29 12-Oct-2015 Pankaj Kanwar <pkanwar@google.com> am b14cbd44: am f76c13a4: am a7d7d91e: Merge "Handle supplicant state changes in non-ConnectModeState" into mnc-dr-dev

* commit 'b14cbd44f066a43dd6c5de0efe8533ce0cdaaf95':
Handle supplicant state changes in non-ConnectModeState
f76c13a415da5e64aca41083b2c1642844311b3b 12-Oct-2015 Pankaj Kanwar <pkanwar@google.com> am a7d7d91e: Merge "Handle supplicant state changes in non-ConnectModeState" into mnc-dr-dev

* commit 'a7d7d91ebbeb326d9d41e05768aa5f5667e68106':
Handle supplicant state changes in non-ConnectModeState
a7d7d91ebbeb326d9d41e05768aa5f5667e68106 12-Oct-2015 Pankaj Kanwar <pkanwar@google.com> Merge "Handle supplicant state changes in non-ConnectModeState" into mnc-dr-dev
4666dd2b4ee1f8d6faabfe79a64b1a84be5b0700 11-Oct-2015 Mitchell Wills <mwills@google.com> am 0dc1746e: am 082dd48c: am 6d88025b: Merge "Don\'t hold on to last scan results if scan is empty" into mnc-dr-dev

* commit '0dc1746ef6668427ca96920efcaabdad589f2a97':
Don't hold on to last scan results if scan is empty
082dd48cb77c4ba0fccaa13906b32f3219184b37 11-Oct-2015 Mitchell Wills <mwills@google.com> am 6d88025b: Merge "Don\'t hold on to last scan results if scan is empty" into mnc-dr-dev

* commit '6d88025b66d5407bf132f23a7a6cc3fd97f0632b':
Don't hold on to last scan results if scan is empty
5e3dba910eb8c050b1e55e328d394e36c24d63a6 08-Oct-2015 Prerepa Viswanadham <dham@google.com> Handle supplicant state changes in non-ConnectModeState

Due to race conditions, where in supplicant state in WiFi State machine
can get get stuck in ASSOCIATING state, whereas the underlying
supplicant has disconnected. This event is dropped in WiFi StateMachine
if it transitions out to non-ConnectModeState causing state mismatch and
future inability for auto join to kick in and connect.

Bug: 24580325
Change-Id: I9e833f3e3ca01f04f76ad348c92f2b29fef8f817
om/android/server/wifi/WifiStateMachine.java
428079ef0616c7dce48a22ca4a7dbc50506cf3ea 18-Aug-2015 xinhe <xinhe@google.com> Handle duplicate network configuration created by WPS

WPS configurations are created by Supplicant, and may collide with
configuration created by Framework. This change updates framework's
notion configuration with the newly created WPS network.

b/22250876

Change-Id: Ic2505c634d907eb0d7c531b83395ecef7bed2b33
om/android/server/wifi/WifiConfigStore.java
c1155a0d09eac695af5d1c695e592bb25f8ab7d7 06-Oct-2015 Erik Wolsheimer <ewol@google.com> am 34b0cd94: am 5e5f50da: am 87a52147: Avoid calling Class#getSimpleName from WifiStateMachine when not necessary. BUG: 24507822

* commit '34b0cd9454857da7d8a6af827432c16a2cf33f06':
Avoid calling Class#getSimpleName from WifiStateMachine when not necessary. BUG: 24507822
34b0cd9454857da7d8a6af827432c16a2cf33f06 06-Oct-2015 Erik Wolsheimer <ewol@google.com> am 5e5f50da: am 87a52147: Avoid calling Class#getSimpleName from WifiStateMachine when not necessary. BUG: 24507822

* commit '5e5f50da9ee67dc6d081c5aded4f7132cb84882e':
Avoid calling Class#getSimpleName from WifiStateMachine when not necessary. BUG: 24507822
7421421975d8e440bb4bab47eaa2dc8d05270bd7 05-Oct-2015 Mitchell Wills <mwills@google.com> Don't hold on to last scan results if scan is empty

Also remove commented out removal of scan results by age

Bug: 24528851
Change-Id: Iba96310f708b81dfbf313e317c27bee31699b329
om/android/server/wifi/WifiStateMachine.java
87a52147753aebb1ab4721663899c30223a44d5d 01-Oct-2015 Erik Wolsheimer <ewol@google.com> Avoid calling Class#getSimpleName from WifiStateMachine when not necessary.
BUG: 24507822

Change-Id: I7debe415186d6cfb9404ac9ccf309fa1cbd78579
om/android/server/wifi/WifiStateMachine.java
abbe16be5712d85e35937f58377bd4f3053ee6d2 02-Oct-2015 Vinit Deshpande <vinitd@google.com> am e7de3ecd: am b0f387d0: am 7ef581ab: am 70478da8: Persist and use country code reliably

* commit 'e7de3ecd77d05b7b1ef80d391b0af2d0350f74fd':
Persist and use country code reliably
e7de3ecd77d05b7b1ef80d391b0af2d0350f74fd 02-Oct-2015 Vinit Deshpande <vinitd@google.com> am b0f387d0: am 7ef581ab: am 70478da8: Persist and use country code reliably

* commit 'b0f387d0574c8745719af5a7248af399ccef1507':
Persist and use country code reliably
70478da87767198d8a9b9314f890fba1d5997e4d 01-Oct-2015 Vinit Deshpande <vinitd@google.com> Persist and use country code reliably

It looks like we never persisted country code if it wasn't
set on the driver; this is not correct.

Also fixed initial sequence - the cached country code is now
trashed on reboot if config_wifi_revert_country_code_on_cellular_loss
is set. New country codes will be set if telephony stacks
retrieve them; or else, ro.boot.wificountrycode will stick.

Note that there are possible race conditions between telephony
finding country codes and starting Wifi functionality (like SoftAP)
so it is possible that Wifi uses more conservative country code
from ro.boot.wificountrycode even if telephony finds a better
country code later. The situation will recover eventually.

Bug: 24553903

Change-Id: I37bb2f64947ab04a82a0392eb85f521a08147e29
om/android/server/wifi/WifiStateMachine.java
97fffca306a4aa1eac1bdb78d2484ff343cb23d8 02-Oct-2015 Mitchell Wills <mwills@google.com> Merge "Fixed copy-paste typo in WifiNative"
851075f4f345d98de885bd2f6b833944b282097e 17-Jul-2015 Mitchell Wills <mwills@google.com> Fixed copy-paste typo in WifiNative

Change-Id: I97dd29ed17974b24edda024ba4312d9be793a3c5
om/android/server/wifi/WifiNative.java
259b345a237c2b79d465ebd28807d64523f0b0c3 02-Oct-2015 xinhe <xinhe@google.com> am 54cd5e91: am 937c699b: am ac71270e: resolved conflicts for 57b578f2 to cw-e-dev

* commit '54cd5e91a0c8a4ab982d6a96cf1ac5a183ddeebc':
Phone rebooted when trying to select problematic WiFi network
54cd5e91a0c8a4ab982d6a96cf1ac5a183ddeebc 02-Oct-2015 xinhe <xinhe@google.com> am 937c699b: am ac71270e: resolved conflicts for 57b578f2 to cw-e-dev

* commit '937c699bbef40bc1d4bc14de35d5008e2c0eaf24':
Phone rebooted when trying to select problematic WiFi network
57b578f21d16d3b0da0162cb6eb9fa8b29895d8f 30-Sep-2015 xinhe <xinhe@google.com> Phone rebooted when trying to select problematic WiFi network

b/24515222

Change-Id: Id18dcbdae97ad6a5fb22dfd8e9cf7c117a3bffa9
om/android/server/wifi/WifiConfigStore.java
a397a4242d3be2dbd02e3d10b2d9791df2a5e576 28-Sep-2015 Vinit Deshpande <vinitd@google.com> am 709c2b50: am 2da736b7: am b45816dc: am 98e43e5f: Don\'t reset country code on mobile signal loss

* commit '709c2b5024d2ab819a27ccbfdddc4830f911459b':
Don't reset country code on mobile signal loss
709c2b5024d2ab819a27ccbfdddc4830f911459b 28-Sep-2015 Vinit Deshpande <vinitd@google.com> am 2da736b7: am b45816dc: am 98e43e5f: Don\'t reset country code on mobile signal loss

* commit '2da736b76233645068903e44cd1b6e345881136a':
Don't reset country code on mobile signal loss
b45816dc9458590766f7bc79b225e6a6184585bc 28-Sep-2015 Vinit Deshpande <vinitd@google.com> am 98e43e5f: Don\'t reset country code on mobile signal loss

* commit '98e43e5f48a4c87343fc311feda4fa5489948822':
Don't reset country code on mobile signal loss
98e43e5f48a4c87343fc311feda4fa5489948822 27-Sep-2015 Vinit Deshpande <vinitd@google.com> Don't reset country code on mobile signal loss

Since mobile signal is lost too often; resetting country
code on this trigger causes too many changes. This change
restricts resetting country code only on two triggers

1. When airplane mode is turned ON
2. When SIM is removed

all other triggeres to reset country code are ignored.

Bug: 24363012
Change-Id: I5bc4bd8af7461da916c9a7638cf9cb457c73ac8b
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
a7fb235eb00711dbc436e5fea0e4f4e12750c87d 25-Sep-2015 Sharvil Nanavati <sharvil@google.com> am 024f57be: am 362185fa: am d2c4a206: Merge "Fix incorrect comparator implementation leading to IllegalArgumentException." into cw-e-dev

* commit '024f57be6c866dd4b900d71b1cdaa28bd208e355':
Fix incorrect comparator implementation leading to IllegalArgumentException.
024f57be6c866dd4b900d71b1cdaa28bd208e355 25-Sep-2015 Sharvil Nanavati <sharvil@google.com> am 362185fa: am d2c4a206: Merge "Fix incorrect comparator implementation leading to IllegalArgumentException." into cw-e-dev

* commit '362185fa89166f7dfd3a63a6cc576ea116b70389':
Fix incorrect comparator implementation leading to IllegalArgumentException.
d2c4a206cbda822a1c1f575fa29975565e4a8ea3 25-Sep-2015 Sharvil Nanavati <sharvil@google.com> Merge "Fix incorrect comparator implementation leading to IllegalArgumentException." into cw-e-dev
bddf925068d0037a1298ff3ffd1b17ffedb43745 25-Sep-2015 Sharvil Nanavati <sharvil@google.com> Fix incorrect comparator implementation leading to IllegalArgumentException.

The current comparator implementation does not implement the compare()
function according to the interface definition. In particular, the
following clause is violated:

"The implementor must ensure that sgn(compare(x, y)) == -sgn(compare(y, x))
for all x and y."

If a.priority == b.priority, the comparator throws.

Bug: 24223197
Change-Id: Ibff94067de272d8c9372474fa24a161bf95bf6f1
om/android/server/wifi/WifiConfigStore.java
5fc890105154949a0754dd00786bae280a9c8693 25-Sep-2015 Vinit Deshpande <vinitd@google.com> resolved conflicts for 0b17544f to master

Change-Id: I6676066fc97d6959abaa2eb3bce15b551ce66685
0b17544f2c484be1bd9ae15d000c993ee172c36b 25-Sep-2015 Vinit Deshpande <vinitd@google.com> am ae156509: am 828559f9: am 39bf8e13: Merge "Honor country code change in wifi disabled state" into mnc-dr-dev

* commit 'ae15650959a00a014c31042efd560d9dded54bdf':
Honor country code change in wifi disabled state
39bf8e134381411a7a46cc4c2b635c83d630db71 25-Sep-2015 Vinit Deshpande <vinitd@google.com> Merge "Honor country code change in wifi disabled state" into mnc-dr-dev
19d6fba32b3d930764d0476b031e9126ec83e551 24-Sep-2015 Erik Kline <ek@google.com> Merge "IpReachabilityMonitor is now in the android.net.ip package"
6ba920080784e63d938543af984affd402d97aeb 24-Sep-2015 Vinit Deshpande <vinitd@google.com> am 810eeac3: am 8ec7d702: am af14b1fc: am 4689d5dd: Merge "Disable wifi firmware logging by default" into mnc-dr-dev

* commit '810eeac391f074eb4d7fa6b7a023093b850436f7':
Disable wifi firmware logging by default
810eeac391f074eb4d7fa6b7a023093b850436f7 24-Sep-2015 Vinit Deshpande <vinitd@google.com> am 8ec7d702: am af14b1fc: am 4689d5dd: Merge "Disable wifi firmware logging by default" into mnc-dr-dev

* commit '8ec7d702e297ae918d9655dc333efd6359fbc2d0':
Disable wifi firmware logging by default
4689d5dd1c8d028d7b10646db09d1899b8119006 24-Sep-2015 Vinit Deshpande <vinitd@google.com> Merge "Disable wifi firmware logging by default" into mnc-dr-dev
e863a2b7d3010ac197d81fb4ba504e74d8cffad6 18-Sep-2015 Erik Kline <ek@google.com> IpReachabilityMonitor is now in the android.net.ip package

Change-Id: I2e25e53cd41425c8b205fbcf2fad0c61ee8f76c7
om/android/server/wifi/WifiStateMachine.java
e28ce6be22c1389847e77d2be9c8390689cdf395 24-Sep-2015 Vinit Deshpande <vinitd@google.com> Disable wifi firmware logging by default

This is really needed for debugging phase, which is over
now; and disabling it will reduce surface area

Bug: 24317401

Change-Id: I0acf9efc94333cb274d4286df9c853431d86883d
om/android/server/wifi/DummyWifiLogger.java
om/android/server/wifi/WifiLogger.java
om/android/server/wifi/WifiStateMachine.java
1d5cd3938f9191184cd9aea3059a3b62bf3a0372 22-Jul-2015 Jan Nordqvist <jannq@google.com> Hotspot 2.0 relase 2 first cut.

Policy provisioning.
API methods.
Timers for policy and remediation.
Icon and friendly name checking.
Channel bindings for EST.

Change-Id: Ifa7125743ea93d7d4329cb53fd70c99b9b06fffe
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/anqp/ANQPFactory.java
om/android/server/wifi/anqp/Constants.java
om/android/server/wifi/anqp/HSIconFileElement.java
om/android/server/wifi/anqp/HSOsuProvidersElement.java
om/android/server/wifi/anqp/I18Name.java
om/android/server/wifi/anqp/IconInfo.java
om/android/server/wifi/anqp/OSUProvider.java
om/android/server/wifi/anqp/eap/NonEAPInnerAuth.java
om/android/server/wifi/configparse/ConfigBuilder.java
om/android/server/wifi/hotspot2/ANQPData.java
om/android/server/wifi/hotspot2/AnqpCache.java
om/android/server/wifi/hotspot2/NetworkDetail.java
om/android/server/wifi/hotspot2/OMADMAdapter.java
om/android/server/wifi/hotspot2/SupplicantBridge.java
om/android/server/wifi/hotspot2/Utils.java
om/android/server/wifi/hotspot2/WifiNetworkAdapter.java
om/android/server/wifi/hotspot2/asn1/Asn1Boolean.java
om/android/server/wifi/hotspot2/asn1/Asn1Class.java
om/android/server/wifi/hotspot2/asn1/Asn1Constructed.java
om/android/server/wifi/hotspot2/asn1/Asn1Decoder.java
om/android/server/wifi/hotspot2/asn1/Asn1ID.java
om/android/server/wifi/hotspot2/asn1/Asn1Integer.java
om/android/server/wifi/hotspot2/asn1/Asn1Object.java
om/android/server/wifi/hotspot2/asn1/Asn1Octets.java
om/android/server/wifi/hotspot2/asn1/Asn1Oid.java
om/android/server/wifi/hotspot2/asn1/Asn1String.java
om/android/server/wifi/hotspot2/asn1/Asn1Tag.java
om/android/server/wifi/hotspot2/asn1/DecodeException.java
om/android/server/wifi/hotspot2/asn1/OidMappings.java
om/android/server/wifi/hotspot2/est/ESTHandler.java
om/android/server/wifi/hotspot2/omadm/MOManager.java
om/android/server/wifi/hotspot2/omadm/MOTree.java
om/android/server/wifi/hotspot2/omadm/MultiValueMap.java
om/android/server/wifi/hotspot2/omadm/OMAConstants.java
om/android/server/wifi/hotspot2/omadm/OMAConstructed.java
om/android/server/wifi/hotspot2/omadm/OMANode.java
om/android/server/wifi/hotspot2/omadm/OMAScalar.java
om/android/server/wifi/hotspot2/omadm/RequestDetail.java
om/android/server/wifi/hotspot2/omadm/SOAPParser.java
om/android/server/wifi/hotspot2/omadm/XMLNode.java
om/android/server/wifi/hotspot2/osu/ClientKeyManager.java
om/android/server/wifi/hotspot2/osu/ExchangeCompleteResponse.java
om/android/server/wifi/hotspot2/osu/ExecCommand.java
om/android/server/wifi/hotspot2/osu/HTTPHandler.java
om/android/server/wifi/hotspot2/osu/IconCache.java
om/android/server/wifi/hotspot2/osu/OSUCertType.java
om/android/server/wifi/hotspot2/osu/OSUClient.java
om/android/server/wifi/hotspot2/osu/OSUCommand.java
om/android/server/wifi/hotspot2/osu/OSUCommandID.java
om/android/server/wifi/hotspot2/osu/OSUError.java
om/android/server/wifi/hotspot2/osu/OSUInfo.java
om/android/server/wifi/hotspot2/osu/OSUListener.java
om/android/server/wifi/hotspot2/osu/OSUManager.java
om/android/server/wifi/hotspot2/osu/OSUMessageType.java
om/android/server/wifi/hotspot2/osu/OSUOperationStatus.java
om/android/server/wifi/hotspot2/osu/OSUResponse.java
om/android/server/wifi/hotspot2/osu/OSUSocketFactory.java
om/android/server/wifi/hotspot2/osu/OSUStatus.java
om/android/server/wifi/hotspot2/osu/PostDevDataResponse.java
om/android/server/wifi/hotspot2/osu/RequestReason.java
om/android/server/wifi/hotspot2/osu/ResponseFactory.java
om/android/server/wifi/hotspot2/osu/SOAPBuilder.java
om/android/server/wifi/hotspot2/osu/SOAPParser.java
om/android/server/wifi/hotspot2/osu/SPVerifier.java
om/android/server/wifi/hotspot2/osu/UserInputListener.java
om/android/server/wifi/hotspot2/osu/WiFiKeyManager.java
om/android/server/wifi/hotspot2/osu/XMLParser.java
om/android/server/wifi/hotspot2/osu/commands/BrowserURI.java
om/android/server/wifi/hotspot2/osu/commands/ClientCertInfo.java
om/android/server/wifi/hotspot2/osu/commands/GetCertData.java
om/android/server/wifi/hotspot2/osu/commands/MOData.java
om/android/server/wifi/hotspot2/osu/commands/MOURN.java
om/android/server/wifi/hotspot2/osu/commands/OSUCommandData.java
om/android/server/wifi/hotspot2/osu/service/RedirectListener.java
om/android/server/wifi/hotspot2/osu/service/SubscriptionTimer.java
om/android/server/wifi/hotspot2/pps/HomeSP.java
om/android/server/wifi/hotspot2/pps/Policy.java
om/android/server/wifi/hotspot2/pps/SubscriptionParameters.java
om/android/server/wifi/hotspot2/pps/UpdateInfo.java
om/android/server/wifi/hotspot2/utils/HTTPMessage.java
om/android/server/wifi/hotspot2/utils/HTTPRequest.java
om/android/server/wifi/hotspot2/utils/HTTPResponse.java
d3629ea845f3e49cdba20255a83068dced281d09 23-Sep-2015 Vinit Deshpande <vinitd@google.com> Honor country code change in wifi disabled state

Bug: 22937052

Change-Id: I8394531e50c4c6b41c6f376a4eb2d8205bd10af7
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
4351eeda51e8c3763b456a5b402e3c433563382e 21-Sep-2015 xin He <xinhe@google.com> am 514d70b0: am 16b77473: am 60dc786b: am fe710a84: Merge "Disconnection seen when roaming from 2.4Ghz to 5Ghz radio of the same AP" into mnc-dr-dev

* commit '514d70b0ebebed12ffafe3f16b827ab4c052112c':
Disconnection seen when roaming from 2.4Ghz to 5Ghz radio of the same AP
514d70b0ebebed12ffafe3f16b827ab4c052112c 21-Sep-2015 xin He <xinhe@google.com> am 16b77473: am 60dc786b: am fe710a84: Merge "Disconnection seen when roaming from 2.4Ghz to 5Ghz radio of the same AP" into mnc-dr-dev

* commit '16b774739508f3225c60177e7124aac07d2a9683':
Disconnection seen when roaming from 2.4Ghz to 5Ghz radio of the same AP
fe710a84935b653979bba9fe9cbcb6a71f38f78b 21-Sep-2015 xin He <xinhe@google.com> Merge "Disconnection seen when roaming from 2.4Ghz to 5Ghz radio of the same AP" into mnc-dr-dev
07198ad239254a5ce7cbf05b9094a66d1fcd91a8 21-Sep-2015 xin He <xinhe@google.com> am ed4fac77: am a9801ecd: am 1330d2c3: am 8647cf63: Merge "initial wifi with default country code" into mnc-dr-dev

* commit 'ed4fac7752804241d2a8bf91a449af3c221a19b5':
initial wifi with default country code
ed4fac7752804241d2a8bf91a449af3c221a19b5 21-Sep-2015 xin He <xinhe@google.com> am a9801ecd: am 1330d2c3: am 8647cf63: Merge "initial wifi with default country code" into mnc-dr-dev

* commit 'a9801ecd0f622db65c136f81c8fbf0debeaa2429':
initial wifi with default country code
8647cf637681b858b09e277ad65dffe46230b247 21-Sep-2015 xin He <xinhe@google.com> Merge "initial wifi with default country code" into mnc-dr-dev
9652e67414cd32e6aae978b96a8ccac34468053a 21-Sep-2015 Erik Kline <ek@google.com> am e2af37f5: am 5d8bc9e3: am 003075fa: Pass Context to IpReachabilityMonitor

* commit 'e2af37f5397a14e170e9ab3758ee401337fd0424':
Pass Context to IpReachabilityMonitor
003075fad19ffd21ae48c863b26c146e1b135617 17-Sep-2015 Erik Kline <ek@google.com> Pass Context to IpReachabilityMonitor

This is to enable IpReachabilityMonitor to properly request a wakelock
during probes.

Bug: 23197666
Change-Id: Ie8eb8271d7bc11b76e67dbc12b1eb57790784d0b
om/android/server/wifi/WifiStateMachine.java
7de206ddfd3bc193b49e31b3a71dfd88a86df22a 19-Sep-2015 Mitchell Wills <mwills@google.com> am 61497ddb: am b65bfe98: am c5e22bdc: am ed34692d: Make sure to cleanup rssi cmd before starting new one

* commit '61497ddb21d80977e594007981c6b9c44fc8a65b':
Make sure to cleanup rssi cmd before starting new one
61497ddb21d80977e594007981c6b9c44fc8a65b 19-Sep-2015 Mitchell Wills <mwills@google.com> am b65bfe98: am c5e22bdc: am ed34692d: Make sure to cleanup rssi cmd before starting new one

* commit 'b65bfe98f710093b8760a5dc24e738780e3f3c1e':
Make sure to cleanup rssi cmd before starting new one
ed34692d4c4e202748d41f90db397f1cc3dc8320 19-Sep-2015 Mitchell Wills <mwills@google.com> Make sure to cleanup rssi cmd before starting new one

Bug: 24196771
Change-Id: Ied140eac38452c4f914c188ff87c37182d79c5ff
om/android/server/wifi/WifiNative.java
9a37b9eee2e9892e4d05ee25372a5de5c2ea317b 18-Sep-2015 Erik Kline <ek@google.com> Merge "Pass Context to IpReachabilityMonitor"
a6b433d78621ee760428813f4f77682d87352106 17-Sep-2015 Erik Kline <ek@google.com> Pass Context to IpReachabilityMonitor

This is to enable IpReachabilityMonitor to properly request a wakelock
during probes.

Bug: 23197666
Change-Id: Ie8eb8271d7bc11b76e67dbc12b1eb57790784d0b
om/android/server/wifi/WifiStateMachine.java
e3dff88903d6011ed135ba0fa5eb538f9f2bcc0e 18-Sep-2015 Mitchell Wills <mwills@google.com> am fa89695a: am 3ffbae25: am c0ede1c5: am 2b822d60: Remove all scans before scheduling a new scan

* commit 'fa89695aa0f323712e8521844cb93b6d65d0f195':
Remove all scans before scheduling a new scan
fa89695aa0f323712e8521844cb93b6d65d0f195 18-Sep-2015 Mitchell Wills <mwills@google.com> am 3ffbae25: am c0ede1c5: am 2b822d60: Remove all scans before scheduling a new scan

* commit '3ffbae25cbc1ff62175bf7a55932f7a5e7bce949':
Remove all scans before scheduling a new scan
2b822d60e4e623e678e48352b9493c52f349fab5 17-Sep-2015 Mitchell Wills <mwills@google.com> Remove all scans before scheduling a new scan

Bug: 23815756
Change-Id: I6c924f17516fb94c81e3bd2a660be5e5d3becd52
om/android/server/wifi/WifiScanningServiceImpl.java
570beb51bc1daa2eb122d68f5ccac7e0ce840293 11-Sep-2015 xinhe <xinhe@google.com> Disconnection seen when roaming from 2.4Ghz to 5Ghz radio of the same AP

b/22729460

Change-Id: I9ac9dd0dba2bf0179b728607ea0cf9b7f05f6ed9
om/android/server/wifi/WifiStateMachine.java
57f108bfcb288aba5c2b557a4ab77019f45af747 17-Sep-2015 xinhe <xinhe@google.com> initial wifi with default country code

b/24082611

Change-Id: I59c2bf90b679313630919d33bb90e8a51e335437
om/android/server/wifi/WifiStateMachine.java
3781f7eb0ed6ed29f84429244dce5cb5d6ceb248 16-Sep-2015 Lorenzo Colitti <lorenzo@google.com> am a772a520: am 302ebaee: am ab9b5756: am 7e89aecd: Wifi fixes for RSSI offload.

* commit 'a772a520e624362df873985d5a5db9623e2dcd1a':
Wifi fixes for RSSI offload.
a772a520e624362df873985d5a5db9623e2dcd1a 16-Sep-2015 Lorenzo Colitti <lorenzo@google.com> am 302ebaee: am ab9b5756: am 7e89aecd: Wifi fixes for RSSI offload.

* commit '302ebaeee85f367adbe4ddc838aac4cbf8a8f950':
Wifi fixes for RSSI offload.
7e89aecdbe4eea3ae955b2b52dd10191685049f6 14-Sep-2015 Lorenzo Colitti <lorenzo@google.com> Wifi fixes for RSSI offload.

1. When disconnecting, stop RSSI monitoring.
2. If no thresholds are specified, stop offload.
3. If invalid threholds are specified, stop offload.
3. When logging CMD_START_RSSI_MONITORING_OFFLOAD, include the
thresholds as well.
5. Delete stopRssiMonitoring(), which is unused.
6. Minor code and logging simplification.

Bug: 21405941
Bug: 23679346
Bug: 23815756
Change-Id: Iddbd2d3c6a3e2a8f1b283fbe5b41e3e4e3acbfa1
om/android/server/wifi/WifiStateMachine.java
a9f2ed26044349832b022569165cba9a5ba430f1 12-Sep-2015 Daniel Cashman <dcashman@google.com> am 0a9dd7cb: am a6a6c4bc: am d3f1473c: am 7b28f041: Merge "Add DUMP permission check to WifiScanner service." into mnc-dr-dev

* commit '0a9dd7cbf5a38559c6085527706894acfeac87ad':
Add DUMP permission check to WifiScanner service.
a303955fa5ad6cb03502eaaf4cf4e253843b64d4 12-Sep-2015 Prerepa Viswanadham <dham@google.com> resolved conflicts for b7900943 to master

Change-Id: I4b421a8f67bc8651118ff72d471873ddf7a88fbe
0a9dd7cbf5a38559c6085527706894acfeac87ad 12-Sep-2015 Daniel Cashman <dcashman@google.com> am a6a6c4bc: am d3f1473c: am 7b28f041: Merge "Add DUMP permission check to WifiScanner service." into mnc-dr-dev

* commit 'a6a6c4bc83cbaf499292dfaaf2fcb5706d72541b':
Add DUMP permission check to WifiScanner service.
b790094360345d100088ed1b55e7a5083cab3803 12-Sep-2015 Prerepa Viswanadham <dham@google.com> am 4b3b0fc0: am 616c05e5: resolved conflicts for f2c41da8 to cw-e-dev

* commit '4b3b0fc00c6a7206092009b97287b5f5788dbc26':
Process RSSI breach event in L2 connect state; protect from crash that can occur when it comes in Disconnected state.
7b28f0415fb90593190bde734eeece86b0c6ae53 12-Sep-2015 Daniel Cashman <dcashman@google.com> Merge "Add DUMP permission check to WifiScanner service." into mnc-dr-dev
f2c41da8b231d0f4712adcd48af33f91d8785ade 11-Sep-2015 Prerepa Viswanadham <dham@google.com> Process RSSI breach event in L2 connect state; protect from
crash that can occur when it comes in Disconnected state.

Bug: 23847831
Change-Id: I693384c61d43ad377c30ef2797937d1dfd48eeb3
om/android/server/wifi/WifiStateMachine.java
cbf5c1792df8509c1b0de0a1b73d1c004a83e4bf 09-Sep-2015 dcashman <dcashman@google.com> Add DUMP permission check to WifiScanner service.

Bug: 23936840
Change-Id: I0b0e0594f098916f1131e98d8500c33752912395
om/android/server/wifi/WifiScanningServiceImpl.java
1a9d88ad4a89400b9c177089f7db3d424a346b4c 08-Sep-2015 Fyodor Kupolov <fkupolov@google.com> Do not throw an exception if appop's result is MODE_IGNORED

Previously, an exception was thrown when a result of checking for an app op
was MODE_IGNORED. We should return zero results instead.

Bug: 23675817
Change-Id: Iba6b6eca8a0d21acd77b8d388b8bfe3119cac8f9
om/android/server/wifi/WifiServiceImpl.java
29fa7d2ffc3bba55173969309e280328b43eeca1 09-Sep-2015 dcashman <dcashman@google.com> Add DUMP permission check to WifiScanner service.

Bug: 23936840
Change-Id: Ia1853db65bf277ed096c1385097bab2e5f76922d
om/android/server/wifi/WifiScanningServiceImpl.java
ce3d849dd65a1308571a906723c01871752bb9df 09-Sep-2015 Vineeta Srivastava <vsrivastava@google.com> am 05bfc35b: am 3852bd26: am de23839d: am 6e481814: Merge "Revert "Dump more ring buffer data in bugreports"" into mnc-dr-dev

* commit '05bfc35ba7913b119c4c9146681a6421169f4f82':
Revert "Dump more ring buffer data in bugreports"
05bfc35ba7913b119c4c9146681a6421169f4f82 09-Sep-2015 Vineeta Srivastava <vsrivastava@google.com> am 3852bd26: am de23839d: am 6e481814: Merge "Revert "Dump more ring buffer data in bugreports"" into mnc-dr-dev

* commit '3852bd26ca8896818c8a588657fd709ce1c256f3':
Revert "Dump more ring buffer data in bugreports"
de23839d85b92cd0eb4cf20311b1b6e5a3211fa7 09-Sep-2015 Vineeta Srivastava <vsrivastava@google.com> am 6e481814: Merge "Revert "Dump more ring buffer data in bugreports"" into mnc-dr-dev

* commit '6e4818147592bfcdf2f5b54df439e315055135dd':
Revert "Dump more ring buffer data in bugreports"
6e4818147592bfcdf2f5b54df439e315055135dd 09-Sep-2015 Vineeta Srivastava <vsrivastava@google.com> Merge "Revert "Dump more ring buffer data in bugreports"" into mnc-dr-dev
674602ce4a5e0c6df7e67230310ad842deb532e9 09-Sep-2015 Vineeta Srivastava <vsrivastava@google.com> Revert "Dump more ring buffer data in bugreports"

This reverts commit d564996d66942dc11ccbafa70c38ef26320b8b8a.

Bug: 23790222
Change-Id: I28862a3ed9938184d1540b89a878189eefc084f9
om/android/server/wifi/WifiLogger.java
om/android/server/wifi/WifiStateMachine.java
f0332c70db9e19433404218713da89b96b8ee6c3 09-Sep-2015 Lorenzo Colitti <lorenzo@google.com> am 086e0c1f: am 18443a38: am a3ab79e3: am 4d2dbfa9: Merge "Return ERROR_HARDWARE_ERROR if the hardware reports an error." into mnc-dr-dev

* commit '086e0c1f65cee592b892821094ff1b7c21481c05':
Return ERROR_HARDWARE_ERROR if the hardware reports an error.
086e0c1f65cee592b892821094ff1b7c21481c05 09-Sep-2015 Lorenzo Colitti <lorenzo@google.com> am 18443a38: am a3ab79e3: am 4d2dbfa9: Merge "Return ERROR_HARDWARE_ERROR if the hardware reports an error." into mnc-dr-dev

* commit '18443a38077ef1012423b0a47fdbb9032abf5e9e':
Return ERROR_HARDWARE_ERROR if the hardware reports an error.
a3ab79e39a5261ce2034100ee606202e7e783a63 09-Sep-2015 Lorenzo Colitti <lorenzo@google.com> am 4d2dbfa9: Merge "Return ERROR_HARDWARE_ERROR if the hardware reports an error." into mnc-dr-dev

* commit '4d2dbfa9ac535063ce4b32530e24e38af22b4ee2':
Return ERROR_HARDWARE_ERROR if the hardware reports an error.
4d2dbfa9ac535063ce4b32530e24e38af22b4ee2 09-Sep-2015 Lorenzo Colitti <lorenzo@google.com> Merge "Return ERROR_HARDWARE_ERROR if the hardware reports an error." into mnc-dr-dev
a157e67a26205d8c3177f8fe5b8d918ffd115a1a 08-Sep-2015 Vinit Deshpande <vinitd@google.com> am 6208dbb4: am cd793ef9: am c55fc96c: am 6194a637: Support config_wifi_revert_country_code_on_cellular_loss

* commit '6208dbb4fb3319121caade3f6b83d4550a21a3be':
Support config_wifi_revert_country_code_on_cellular_loss
6208dbb4fb3319121caade3f6b83d4550a21a3be 08-Sep-2015 Vinit Deshpande <vinitd@google.com> am cd793ef9: am c55fc96c: am 6194a637: Support config_wifi_revert_country_code_on_cellular_loss

* commit 'cd793ef98272738ef2a3c8d45b26c92094348017':
Support config_wifi_revert_country_code_on_cellular_loss
c55fc96c9bc6abd71a50054d98e8d093540de26d 08-Sep-2015 Vinit Deshpande <vinitd@google.com> am 6194a637: Support config_wifi_revert_country_code_on_cellular_loss

* commit '6194a637d789ec915d58c3f569618cb3ad43a93b':
Support config_wifi_revert_country_code_on_cellular_loss
707f8dba7c1bced3034f1066c3b8d759c8826422 08-Sep-2015 Lorenzo Colitti <lorenzo@google.com> Return ERROR_HARDWARE_ERROR if the hardware reports an error.

Previously we'd just return whatever integer the HAL returned.
This is bad because callers would interpret this integer as a
PacketKeepalive error code and would have no idea what it meant.

Bug: 21405946
Change-Id: I1f1f6a7e00ff8694e1f8ca7b5bf2b045c6e4036d
om/android/server/wifi/WifiStateMachine.java
6194a637d789ec915d58c3f569618cb3ad43a93b 05-Sep-2015 Vinit Deshpande <vinitd@google.com> Support config_wifi_revert_country_code_on_cellular_loss

This change supports config_wifi_revert_country_code_on_cellular_loss;
when this overlay setting is set to true, and ro.boot.wificountrycode
property is set, it will reset wifi chipset to default country code
(designated by ro.boot.wificountrycode) in order to conform with local
regulations.

bug: 21795172

Change-Id: I20bd3a260b639dba331305c6baa39ffb52e2fd6f
om/android/server/wifi/WifiStateMachine.java
108eb1b4b56d86f2df9c5ae08694ed58d7eee2e2 03-Sep-2015 Vinit Deshpande <vinitd@google.com> am 987ae534: am 3775f20e: am fbd5d5db: am d564996d: Dump more ring buffer data in bugreports

* commit '987ae534b1b6a06cd44154a108d6acedc2bcfd88':
Dump more ring buffer data in bugreports
987ae534b1b6a06cd44154a108d6acedc2bcfd88 03-Sep-2015 Vinit Deshpande <vinitd@google.com> am 3775f20e: am fbd5d5db: am d564996d: Dump more ring buffer data in bugreports

* commit '3775f20e2f882bcb355102b125d708f04b750ebc':
Dump more ring buffer data in bugreports
fbd5d5db3a0f589ca76b7bbb2627517f3b4ce884 03-Sep-2015 Vinit Deshpande <vinitd@google.com> am d564996d: Dump more ring buffer data in bugreports

* commit 'd564996d66942dc11ccbafa70c38ef26320b8b8a':
Dump more ring buffer data in bugreports
d564996d66942dc11ccbafa70c38ef26320b8b8a 27-Aug-2015 Vinit Deshpande <vinitd@google.com> Dump more ring buffer data in bugreports

This change caches wifi ring buffer data for last one hour instead
of caching fixed size of data. This will help debug transitional
issues better.

This change also captures firmware dump when IP reachablity is lost.
hopefully, this will help debug elusive connectivity issues.

Bug: 23320188

Change-Id: I03c944967b73aeeb56df05f481e41f90715291f4
om/android/server/wifi/WifiLogger.java
om/android/server/wifi/WifiStateMachine.java
aed0ffae9579a068b37cb7b38f4ed0aa072bd927 28-Aug-2015 Mitchell Wills <mwills@google.com> am 1086377c: am 24a99090: am f424a327: am 85d1a896: am 0553024a: Merge "Revert "Add wake lock that is acquired during full wifi scans"" into mnc-dev

* commit '1086377cf6c1408bf0438a1bfce07a23db30b170':
Revert "Add wake lock that is acquired during full wifi scans"
1086377cf6c1408bf0438a1bfce07a23db30b170 28-Aug-2015 Mitchell Wills <mwills@google.com> am 24a99090: am f424a327: am 85d1a896: am 0553024a: Merge "Revert "Add wake lock that is acquired during full wifi scans"" into mnc-dev

* commit '24a99090a5bf385827734c531e4860c389544ac6':
Revert "Add wake lock that is acquired during full wifi scans"
f424a327159e68051349008ca1dbcad69140295b 28-Aug-2015 Mitchell Wills <mwills@google.com> am 85d1a896: am 0553024a: Merge "Revert "Add wake lock that is acquired during full wifi scans"" into mnc-dev

* commit '85d1a896c94123727d70fcb309ca5355ee73c74e':
Revert "Add wake lock that is acquired during full wifi scans"
85d1a896c94123727d70fcb309ca5355ee73c74e 28-Aug-2015 Mitchell Wills <mwills@google.com> am 0553024a: Merge "Revert "Add wake lock that is acquired during full wifi scans"" into mnc-dev

* commit '0553024a5d7ca6593f61335ead1bade23d3d2e40':
Revert "Add wake lock that is acquired during full wifi scans"
0553024a5d7ca6593f61335ead1bade23d3d2e40 28-Aug-2015 Mitchell Wills <mwills@google.com> Merge "Revert "Add wake lock that is acquired during full wifi scans"" into mnc-dev
c1608581b6fc89bb00bfa4aa1684380fa53e755c 28-Aug-2015 Mitchell Wills <mwills@google.com> Revert "Add wake lock that is acquired during full wifi scans"

This reverts commit b3dd8fb7956874fa23f4095d065fd665b3772aa2.

Change-Id: I0982ca449ee5382d749210859e861135073f963b
Bug: 23540206
om/android/server/wifi/WifiScanningServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
e529e250515e5ad78dc0bda27c62ba5d9c9ed949 28-Aug-2015 Jan Nordqvist <jannq@google.com> am 6a950ac7: am f5c84055: am 90c01769: Merge "Moved domain suffix enforcement setting to WifiConfigStore." into mnc-dev

* commit '6a950ac79fd0e00b065b49888381df66b3794cbb':
Moved domain suffix enforcement setting to WifiConfigStore.
6a950ac79fd0e00b065b49888381df66b3794cbb 28-Aug-2015 Jan Nordqvist <jannq@google.com> am f5c84055: am 90c01769: Merge "Moved domain suffix enforcement setting to WifiConfigStore." into mnc-dev

* commit 'f5c840550f86bd073060ca82f191eadb307ff1dc':
Moved domain suffix enforcement setting to WifiConfigStore.
8f86e4afb100d6943463efd16101917ee281b948 27-Aug-2015 Jan Nordqvist <jannq@google.com> am f2ccc594: am 90c01769: Merge "Moved domain suffix enforcement setting to WifiConfigStore." into mnc-dev

* commit 'f2ccc594030d9a36947973e9b66b269dedf37734':
Moved domain suffix enforcement setting to WifiConfigStore.
f2ccc594030d9a36947973e9b66b269dedf37734 27-Aug-2015 Jan Nordqvist <jannq@google.com> am 90c01769: Merge "Moved domain suffix enforcement setting to WifiConfigStore." into mnc-dev

* commit '90c01769ebbae7d5256ef1e1675c1f21dd94ea70':
Moved domain suffix enforcement setting to WifiConfigStore.
f5c840550f86bd073060ca82f191eadb307ff1dc 27-Aug-2015 Jan Nordqvist <jannq@google.com> am 90c01769: Merge "Moved domain suffix enforcement setting to WifiConfigStore." into mnc-dev

* commit '90c01769ebbae7d5256ef1e1675c1f21dd94ea70':
Moved domain suffix enforcement setting to WifiConfigStore.
90c01769ebbae7d5256ef1e1675c1f21dd94ea70 27-Aug-2015 Jan Nordqvist <jannq@google.com> Merge "Moved domain suffix enforcement setting to WifiConfigStore." into mnc-dev
a472694e74f336e88a77e867c2d66ba4a902fbd8 25-Aug-2015 xin He <xinhe@google.com> am e0673490: am 1ae13301: am ce7c3057: am e766da2d: Merge "Ignore NETWORK_CONNECTION_EVENT when already in ConnectedState" into mnc-dr-dev

* commit 'e0673490b0cd3ea91ea1589bdb9f310fbc61c615':
Ignore NETWORK_CONNECTION_EVENT when already in ConnectedState
e0673490b0cd3ea91ea1589bdb9f310fbc61c615 25-Aug-2015 xin He <xinhe@google.com> am 1ae13301: am ce7c3057: am e766da2d: Merge "Ignore NETWORK_CONNECTION_EVENT when already in ConnectedState" into mnc-dr-dev

* commit '1ae13301608d90146cfeb93bf9d3991689aa0adf':
Ignore NETWORK_CONNECTION_EVENT when already in ConnectedState
ce7c30570b89eea5f474f54df56c5145d5c6a498 25-Aug-2015 xin He <xinhe@google.com> am e766da2d: Merge "Ignore NETWORK_CONNECTION_EVENT when already in ConnectedState" into mnc-dr-dev

* commit 'e766da2dd496d4bcbca4c8ef75c575aaba1752c7':
Ignore NETWORK_CONNECTION_EVENT when already in ConnectedState
e766da2dd496d4bcbca4c8ef75c575aaba1752c7 25-Aug-2015 xin He <xinhe@google.com> Merge "Ignore NETWORK_CONNECTION_EVENT when already in ConnectedState" into mnc-dr-dev
f88d5ab0130eafcfb9ae11f3ba8f3b0f90e3ee8a 25-Aug-2015 Prem Kumar <premk@google.com> am 9baa0526: am b3762801: am 19894873: am 97c6feca: am 83265fd0: Merge "Fire scanResultsAvailableBroadcast as system" into mnc-dev

* commit '9baa05266ef341f8a7dd300f08460fdb775c84dc':
Fire scanResultsAvailableBroadcast as system
9baa05266ef341f8a7dd300f08460fdb775c84dc 25-Aug-2015 Prem Kumar <premk@google.com> am b3762801: am 19894873: am 97c6feca: am 83265fd0: Merge "Fire scanResultsAvailableBroadcast as system" into mnc-dev

* commit 'b3762801604e590c64ad4027ef1e045f3d88aeec':
Fire scanResultsAvailableBroadcast as system
19894873a0930fc5229347f8ae19627864be66ad 25-Aug-2015 Prem Kumar <premk@google.com> am 97c6feca: am 83265fd0: Merge "Fire scanResultsAvailableBroadcast as system" into mnc-dev

* commit '97c6fecadd27d0ecd6557527dd4a7304f9f859cb':
Fire scanResultsAvailableBroadcast as system
97c6fecadd27d0ecd6557527dd4a7304f9f859cb 25-Aug-2015 Prem Kumar <premk@google.com> am 83265fd0: Merge "Fire scanResultsAvailableBroadcast as system" into mnc-dev

* commit '83265fd0ad5f89ed860f76a78f55dc9f3e2d4d27':
Fire scanResultsAvailableBroadcast as system
7ebab34600c9b4388308ef92c59c2fa1adfd9494 25-Aug-2015 Prem Kumar <premk@google.com> am 83265fd0: Merge "Fire scanResultsAvailableBroadcast as system" into mnc-dev

* commit '83265fd0ad5f89ed860f76a78f55dc9f3e2d4d27':
Fire scanResultsAvailableBroadcast as system
83265fd0ad5f89ed860f76a78f55dc9f3e2d4d27 25-Aug-2015 Prem Kumar <premk@google.com> Merge "Fire scanResultsAvailableBroadcast as system" into mnc-dev
5c487a02cbae0e7b5d68e3841b80bf7d9413597b 25-Aug-2015 xinhe <xinhe@google.com> Ignore NETWORK_CONNECTION_EVENT when already in ConnectedState

b/22729460

Change-Id: I86b25d9dd8b41039d7627c86596f71c73018645b
om/android/server/wifi/WifiStateMachine.java
5f30066b5609002673289860cd1cdae49c5e83dc 25-Aug-2015 Jan Nordqvist <jannq@google.com> Moved domain suffix enforcement setting to WifiConfigStore.

Bug: 23359149
Change-Id: I2f66041e5125b1b032da54616b152cf6990c3bc8
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/configparse/ConfigBuilder.java
691fb51e7ac5e4d0b91a4719cd0ed10a8c212e50 21-Aug-2015 Vinit Deshpande <vinitd@google.com> Fire scanResultsAvailableBroadcast as system

In idle mode, WifiService fires it as the calling app; but the apps
can't fire UserHandle.ALL broadcasts.

Bug: 22466691
Change-Id: Ib6d0e1fb570c430184e5af8ba7c796e19b02ba08
om/android/server/wifi/WifiServiceImpl.java
2ab27e892ac48acfb960c18bb68a4ebd2a7570a2 22-Aug-2015 Jan Nordqvist <jannq@google.com> am c39c56f1: am a211a2d6: am af163db0: am 6b56e742: am 57011843: Merge "Fixed incorrect bounds check." into mnc-dev

* commit 'c39c56f15646478c937d9e435bb4de770ceca19a':
Fixed incorrect bounds check.
c39c56f15646478c937d9e435bb4de770ceca19a 22-Aug-2015 Jan Nordqvist <jannq@google.com> am a211a2d6: am af163db0: am 6b56e742: am 57011843: Merge "Fixed incorrect bounds check." into mnc-dev

* commit 'a211a2d62bb05dd8f8dccec1a86003ab3cc6a523':
Fixed incorrect bounds check.
af163db0c3868df7ef0c45c0a0b55ec2535e1e5c 22-Aug-2015 Jan Nordqvist <jannq@google.com> am 6b56e742: am 57011843: Merge "Fixed incorrect bounds check." into mnc-dev

* commit '6b56e742abfd5828f27e799f126ccacfee39dc44':
Fixed incorrect bounds check.
8aaad5e73a9e80b8da5cb3f0cf1d4641205e99ce 21-Aug-2015 Jan Nordqvist <jannq@google.com> am 57011843: Merge "Fixed incorrect bounds check." into mnc-dev

* commit '57011843dc0eb7cf1f2c2052a302ffbbc2f769d6':
Fixed incorrect bounds check.
6b56e742abfd5828f27e799f126ccacfee39dc44 21-Aug-2015 Jan Nordqvist <jannq@google.com> am 57011843: Merge "Fixed incorrect bounds check." into mnc-dev

* commit '57011843dc0eb7cf1f2c2052a302ffbbc2f769d6':
Fixed incorrect bounds check.
57011843dc0eb7cf1f2c2052a302ffbbc2f769d6 21-Aug-2015 Jan Nordqvist <jannq@google.com> Merge "Fixed incorrect bounds check." into mnc-dev
1c99377a2831c520b75f6dd2c7e1f2672be7d73f 21-Aug-2015 Jan Nordqvist <jannq@google.com> Fixed incorrect bounds check.

Bug: 23394258
Change-Id: I3cabd90fc9a863d3ada06dc258da57e90b5863e1
om/android/server/wifi/anqp/IPAddressTypeAvailabilityElement.java
37907ee01ee921eb2f5ad17bdf25c35d6d41c54c 20-Aug-2015 Mitchell Wills <mwills@google.com> am 083c8dd3: am 3cbdc5f2: am 347a7826: am 9cea6662: Merge "Allow SAP enable while STA is enabled (and restore on disable)" into mnc-dr-dev

* commit '083c8dd3d87c5025c2c61cd073209394e3955c4c':
Allow SAP enable while STA is enabled (and restore on disable)
083c8dd3d87c5025c2c61cd073209394e3955c4c 20-Aug-2015 Mitchell Wills <mwills@google.com> am 3cbdc5f2: am 347a7826: am 9cea6662: Merge "Allow SAP enable while STA is enabled (and restore on disable)" into mnc-dr-dev

* commit '3cbdc5f211f8c1e213e9b270930cf6c71bc80d9d':
Allow SAP enable while STA is enabled (and restore on disable)
347a78264315033138ce2defa64ed60626670af2 20-Aug-2015 Mitchell Wills <mwills@google.com> am 9cea6662: Merge "Allow SAP enable while STA is enabled (and restore on disable)" into mnc-dr-dev

* commit '9cea6662a459bd1635ed65be7239549234975da9':
Allow SAP enable while STA is enabled (and restore on disable)
9cea6662a459bd1635ed65be7239549234975da9 20-Aug-2015 Mitchell Wills <mwills@google.com> Merge "Allow SAP enable while STA is enabled (and restore on disable)" into mnc-dr-dev
39ddd1ac0b7bc0c15f690b350dd694808cce6abc 20-Aug-2015 Erik Kline <ek@google.com> am 09b9b8e4: am bc70a41f: am 3b3ff4cd: am 14a4e553: am 195e2b5b: Merge "Also track loss of IPv6 provisioning, not just IPv4" into mnc-dev

* commit '09b9b8e43839f38f2e162138555ce945c0f2b03c':
Also track loss of IPv6 provisioning, not just IPv4
09b9b8e43839f38f2e162138555ce945c0f2b03c 20-Aug-2015 Erik Kline <ek@google.com> am bc70a41f: am 3b3ff4cd: am 14a4e553: am 195e2b5b: Merge "Also track loss of IPv6 provisioning, not just IPv4" into mnc-dev

* commit 'bc70a41f69ce855047ab758e00edcf4f8d64bbfb':
Also track loss of IPv6 provisioning, not just IPv4
3b3ff4cdda3d3c1a735baaf809548b3a8a69418f 20-Aug-2015 Erik Kline <ek@google.com> am 14a4e553: am 195e2b5b: Merge "Also track loss of IPv6 provisioning, not just IPv4" into mnc-dev

* commit '14a4e5532bbb9b962025abbe842d60f52569364c':
Also track loss of IPv6 provisioning, not just IPv4
5ee3629e4c349f1e06b5c62a409f9233c84d34af 20-Aug-2015 Erik Kline <ek@google.com> am 195e2b5b: Merge "Also track loss of IPv6 provisioning, not just IPv4" into mnc-dev

* commit '195e2b5b6822142e7b8b91843aecc5d9f0b252ed':
Also track loss of IPv6 provisioning, not just IPv4
14a4e5532bbb9b962025abbe842d60f52569364c 20-Aug-2015 Erik Kline <ek@google.com> am 195e2b5b: Merge "Also track loss of IPv6 provisioning, not just IPv4" into mnc-dev

* commit '195e2b5b6822142e7b8b91843aecc5d9f0b252ed':
Also track loss of IPv6 provisioning, not just IPv4
195e2b5b6822142e7b8b91843aecc5d9f0b252ed 20-Aug-2015 Erik Kline <ek@google.com> Merge "Also track loss of IPv6 provisioning, not just IPv4" into mnc-dev
61ba5535a4534a97fd3987e9bd0a31498256a5bc 19-Aug-2015 Mitchell Wills <mwills@google.com> Merge "Correctly compute WifiScanner channel count and scan length"
cbc29b608bf589294fe2a3785b0202dcee77b11c 19-Aug-2015 Jan Nordqvist <jannq@google.com> am 1cefbedc: am 92aaceb0: am e364dffa: am b869c6f7: am 8be016e0: Ignoring SSID for Passpoint networks.

* commit '1cefbedc8a860b630da89a3035512ba7528d1e0d':
Ignoring SSID for Passpoint networks.
1cefbedc8a860b630da89a3035512ba7528d1e0d 19-Aug-2015 Jan Nordqvist <jannq@google.com> am 92aaceb0: am e364dffa: am b869c6f7: am 8be016e0: Ignoring SSID for Passpoint networks.

* commit '92aaceb02b9a6132e956a16e8c99d144643fe4cc':
Ignoring SSID for Passpoint networks.
e364dffa30ab2afa81a818f7a34426e8ef7a5a28 19-Aug-2015 Jan Nordqvist <jannq@google.com> am b869c6f7: am 8be016e0: Ignoring SSID for Passpoint networks.

* commit 'b869c6f79a8edc4786311f01b5bad8b7d45effbd':
Ignoring SSID for Passpoint networks.
b869c6f79a8edc4786311f01b5bad8b7d45effbd 19-Aug-2015 Jan Nordqvist <jannq@google.com> am 8be016e0: Ignoring SSID for Passpoint networks.

* commit '8be016e09c31c9d0fb9044a9d3a9008bde559ca8':
Ignoring SSID for Passpoint networks.
f71a07dcc2bc09588ad111cf3ed936fd048f02dd 19-Aug-2015 Jan Nordqvist <jannq@google.com> am 8be016e0: Ignoring SSID for Passpoint networks.

* commit '8be016e09c31c9d0fb9044a9d3a9008bde559ca8':
Ignoring SSID for Passpoint networks.
1f8f2971309aee4de9c35723f6fbca6fcab9a3be 18-Aug-2015 Mitchell Wills <mwills@google.com> Check if link stats are supported when reporting activity info

Bug: 23286362
Change-Id: Ib5629d2547957ae1f6215f719377fad96f4e10f8
om/android/server/wifi/WifiServiceImpl.java
8be016e09c31c9d0fb9044a9d3a9008bde559ca8 19-Aug-2015 Jan Nordqvist <jannq@google.com> Ignoring SSID for Passpoint networks.

Bug: 23108342
Change-Id: I73eec12165cc7d506dbce99cd6752a4ca3232737
om/android/server/wifi/WifiConfigStore.java
50cc4f8cf4c35d5b97aceea4956f37724a91f207 18-Aug-2015 Erik Kline <ek@google.com> Also track loss of IPv6 provisioning, not just IPv4

Bug: 23226635
Change-Id: I2215add147c02021a8389b05545ccf87a1509ce8
om/android/server/wifi/WifiStateMachine.java
b44ff9a5341fdb87d0169984729d077afc3fb806 05-Aug-2015 Mitchell Wills <mwills@google.com> Don't delay wifi driver shutdown

Bug: 22808676
Change-Id: Ia016959a226a77bd350191b69b869583883520d0
om/android/server/wifi/WifiStateMachine.java
84060523b84e860ffd81050a73917721328d5c58 17-Aug-2015 xin He <xinhe@google.com> am bc452a8e: am c95ac1c2: am 4451482d: am 519e3982: Merge "Disconnection seen when roaming from 2.4Ghz to 5Ghz radio of the same AP" into mnc-dr-dev

* commit 'bc452a8ee0ec9d188ae77e099c25af611f7605f1':
Disconnection seen when roaming from 2.4Ghz to 5Ghz radio of the same AP
bc452a8ee0ec9d188ae77e099c25af611f7605f1 17-Aug-2015 xin He <xinhe@google.com> am c95ac1c2: am 4451482d: am 519e3982: Merge "Disconnection seen when roaming from 2.4Ghz to 5Ghz radio of the same AP" into mnc-dr-dev

* commit 'c95ac1c2702babb161d06a259687eca5aeb214b3':
Disconnection seen when roaming from 2.4Ghz to 5Ghz radio of the same AP
4451482db9d679eef6b373bb9d9061568b874eb4 17-Aug-2015 xin He <xinhe@google.com> am 519e3982: Merge "Disconnection seen when roaming from 2.4Ghz to 5Ghz radio of the same AP" into mnc-dr-dev

* commit '519e3982ee6ada654744def6e431b29fe7d10e95':
Disconnection seen when roaming from 2.4Ghz to 5Ghz radio of the same AP
519e3982ee6ada654744def6e431b29fe7d10e95 17-Aug-2015 xin He <xinhe@google.com> Merge "Disconnection seen when roaming from 2.4Ghz to 5Ghz radio of the same AP" into mnc-dr-dev
69a6102e30eabffefa7bfad6a4f016de8110013a 11-Aug-2015 Mitchell Wills <mwills@google.com> Allow SAP enable while STA is enabled (and restore on disable)

This moves the logic of remembering if wifi was enabled when enabling
softap to WifiController and restores the remembered state when
disabling softap.

Bug: 22729316
Change-Id: I83cfe587a0f9660aa3382c485f2f5cf7660af05c
om/android/server/wifi/WifiController.java
845ecd3a1619c1e638aada572d08952608ef9ed4 14-Aug-2015 xinhe <xinhe@google.com> Disconnection seen when roaming from 2.4Ghz to 5Ghz radio of the same AP

b/22729460

Change-Id: I7ed9b2956c05171438fed00449e8aac0aca3709c
om/android/server/wifi/WifiStateMachine.java
c3bf77a2810b67fcaeda388f094141080b2b3970 14-Aug-2015 Mitchell Wills <mwills@google.com> Correctly compute WifiScanner channel count and scan length

Bug: 23218323
Change-Id: I7b126cef6f83cfe4de893299e8b1a8fb87f6bad6
om/android/server/wifi/WifiScanningServiceImpl.java
cdef7c0f7de2a6b582807ec50c1bd4bcf4056cab 14-Aug-2015 Vinit Deshpande <vinitd@google.com> Merge "Fix a crash caused by race of RSSI monitoring and connection events" into mnc-dr-dev
b767cfa8975511aede9bf82397f330930acd2d18 13-Aug-2015 Mitchell Wills <mwills@google.com> am 24d27d46: Merge "Add wake lock that is acquired during full wifi scans" into mnc-dev

* commit '24d27d46ad357c27254b05c49ec33a210aca7436':
Add wake lock that is acquired during full wifi scans
829570a34b9bde87a6b2f8419bd22dbc31c341ad 13-Aug-2015 Mitchell Wills <mwills@google.com> am 9a02fc05: am 386d3542: am 9a6cc8a9: am 363bcd1b: am 24d27d46: Merge "Add wake lock that is acquired during full wifi scans" into mnc-dev

* commit '9a02fc0526dd5bbd5df7edf52ed1c2f7fb0caf23':
Add wake lock that is acquired during full wifi scans
9a02fc0526dd5bbd5df7edf52ed1c2f7fb0caf23 13-Aug-2015 Mitchell Wills <mwills@google.com> am 386d3542: am 9a6cc8a9: am 363bcd1b: am 24d27d46: Merge "Add wake lock that is acquired during full wifi scans" into mnc-dev

* commit '386d3542a5135c1aa941871f9e13345ae0043ae0':
Add wake lock that is acquired during full wifi scans
9a6cc8a9d6d7233780fcd3d75a000acbfcc1c2f2 13-Aug-2015 Mitchell Wills <mwills@google.com> am 363bcd1b: am 24d27d46: Merge "Add wake lock that is acquired during full wifi scans" into mnc-dev

* commit '363bcd1b3f8a04e8a401fb8080eb8b913cdc9fd6':
Add wake lock that is acquired during full wifi scans
363bcd1b3f8a04e8a401fb8080eb8b913cdc9fd6 13-Aug-2015 Mitchell Wills <mwills@google.com> am 24d27d46: Merge "Add wake lock that is acquired during full wifi scans" into mnc-dev

* commit '24d27d46ad357c27254b05c49ec33a210aca7436':
Add wake lock that is acquired during full wifi scans
24d27d46ad357c27254b05c49ec33a210aca7436 13-Aug-2015 Mitchell Wills <mwills@google.com> Merge "Add wake lock that is acquired during full wifi scans" into mnc-dev
d373fa35fe37a9b3153797a951ecbff42536d77c 13-Aug-2015 xinhe <xinhe@google.com> am 2cdba3e0: am b6133b18: am 79e766f9: am eefa1470: am 26c09042: Phone connects to 2.4GHz wifi network when configured for 5GHz only

* commit '2cdba3e06181ba3247854746742e9fe7563a63d3':
Phone connects to 2.4GHz wifi network when configured for 5GHz only
33258d201093aed46ed75f9b9d5e631ebcece54a 13-Aug-2015 xinhe <xinhe@google.com> am 26c09042: Phone connects to 2.4GHz wifi network when configured for 5GHz only

* commit '26c0904253b5f4c6ecaf7a9ce160d93dcb2b1ff7':
Phone connects to 2.4GHz wifi network when configured for 5GHz only
2cdba3e06181ba3247854746742e9fe7563a63d3 13-Aug-2015 xinhe <xinhe@google.com> am b6133b18: am 79e766f9: am eefa1470: am 26c09042: Phone connects to 2.4GHz wifi network when configured for 5GHz only

* commit 'b6133b182b191c23ba490a93797fb0746d5a1468':
Phone connects to 2.4GHz wifi network when configured for 5GHz only
79e766f95dea07e1cdbebb64daef7d9dbc9db78b 13-Aug-2015 xinhe <xinhe@google.com> am eefa1470: am 26c09042: Phone connects to 2.4GHz wifi network when configured for 5GHz only

* commit 'eefa1470d798bd7d07109e2ec4924feb8e0b77c1':
Phone connects to 2.4GHz wifi network when configured for 5GHz only
eefa1470d798bd7d07109e2ec4924feb8e0b77c1 13-Aug-2015 xinhe <xinhe@google.com> am 26c09042: Phone connects to 2.4GHz wifi network when configured for 5GHz only

* commit '26c0904253b5f4c6ecaf7a9ce160d93dcb2b1ff7':
Phone connects to 2.4GHz wifi network when configured for 5GHz only
26c0904253b5f4c6ecaf7a9ce160d93dcb2b1ff7 11-Aug-2015 xinhe <xinhe@google.com> Phone connects to 2.4GHz wifi network when configured for 5GHz only

b/22830798

Change-Id: I164b1fe21d3e7b675420c9688f8cffc03dc27517
om/android/server/wifi/WifiStateMachine.java
b3dd8fb7956874fa23f4095d065fd665b3772aa2 06-Aug-2015 Mitchell Wills <mwills@google.com> Add wake lock that is acquired during full wifi scans

Bug: 22832222
Change-Id: Ia69dc251aa54c1aee9c319c686dd1c88ae7f5f19
om/android/server/wifi/WifiScanningServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
f07075e5000f47cae7c22979fe9c5b4bc0e1d8b5 12-Aug-2015 Fyodor Kupolov <fkupolov@google.com> am f2cdb162: am 2c6d6b38: am 61d442fb: am 274d409a: am 57dd660f: Merge "Legacy foreground apps should continue getting scan results" into mnc-dev

* commit 'f2cdb162a2bcec1e9ab013dd3155d44ea220e4c2':
Legacy foreground apps should continue getting scan results
f2cdb162a2bcec1e9ab013dd3155d44ea220e4c2 12-Aug-2015 Fyodor Kupolov <fkupolov@google.com> am 2c6d6b38: am 61d442fb: am 274d409a: am 57dd660f: Merge "Legacy foreground apps should continue getting scan results" into mnc-dev

* commit '2c6d6b38e0ec8097e503e9a521aa1ed71665f763':
Legacy foreground apps should continue getting scan results
61d442fb70c53c3289d56731599ac77e245d0189 12-Aug-2015 Fyodor Kupolov <fkupolov@google.com> am 274d409a: am 57dd660f: Merge "Legacy foreground apps should continue getting scan results" into mnc-dev

* commit '274d409a81db25afed12b90d7b6db4dee747f82d':
Legacy foreground apps should continue getting scan results
274d409a81db25afed12b90d7b6db4dee747f82d 12-Aug-2015 Fyodor Kupolov <fkupolov@google.com> am 57dd660f: Merge "Legacy foreground apps should continue getting scan results" into mnc-dev

* commit '57dd660fb81e51df080c4b57e1fc171eb5827cb0':
Legacy foreground apps should continue getting scan results
c510c3a277950106fc905a701b2965899eefed37 12-Aug-2015 Fyodor Kupolov <fkupolov@google.com> am 57dd660f: Merge "Legacy foreground apps should continue getting scan results" into mnc-dev

* commit '57dd660fb81e51df080c4b57e1fc171eb5827cb0':
Legacy foreground apps should continue getting scan results
57dd660fb81e51df080c4b57e1fc171eb5827cb0 12-Aug-2015 Fyodor Kupolov <fkupolov@google.com> Merge "Legacy foreground apps should continue getting scan results" into mnc-dev
c16b86a63a77c8a629f4c448e7d07ed143e2591e 12-Aug-2015 Vinit Deshpande <vinitd@google.com> am 1430bfef: am 3c1a2b9d: DO NOT MERGE Fix a crash caused by race of RSSI monitoring and connection events

* commit '1430bfef2f6052a71ce0036dcda28a860c650ee7':
DO NOT MERGE Fix a crash caused by race of RSSI monitoring and connection events
3c1a2b9d7090705382b1fdc1612c63263562a646 11-Aug-2015 Vinit Deshpande <vinitd@google.com> DO NOT MERGE Fix a crash caused by race of RSSI monitoring and connection events

Disconnect can occur during RSSI monitoring; leaving current config
to be undefined.

Bug: 22956360
Change-Id: I54f5a87651a0ab64a9ffda22f4207beb4316d9e4
om/android/server/wifi/WifiStateMachine.java
2df05d93888c996753f77c27cdd1f7e5fbfa0d87 11-Aug-2015 xin He <xinhe@google.com> am 2cf7bd56: am fa83c9cc: am 3f2085b0: am 1294aa45: Merge "Bad Wifi = strange looping of trying to connect" into mnc-dev

* commit '2cf7bd56b36f358b3ce72541289a471140c1323c':
Bad Wifi = strange looping of trying to connect
2cf7bd56b36f358b3ce72541289a471140c1323c 11-Aug-2015 xin He <xinhe@google.com> am fa83c9cc: am 3f2085b0: am 1294aa45: Merge "Bad Wifi = strange looping of trying to connect" into mnc-dev

* commit 'fa83c9ccfa8a2e387d95fa2bbe9ef394e2847bca':
Bad Wifi = strange looping of trying to connect
b8ba77db66a94d88163254cee43893a968d2f9f0 11-Aug-2015 xin He <xinhe@google.com> am 1294aa45: Merge "Bad Wifi = strange looping of trying to connect" into mnc-dev

* commit '1294aa4550666b871239dc22622eefa76ec05206':
Bad Wifi = strange looping of trying to connect
3f2085b0e2dddeb768c6ff042ffeeb7ea1221d46 11-Aug-2015 xin He <xinhe@google.com> am 1294aa45: Merge "Bad Wifi = strange looping of trying to connect" into mnc-dev

* commit '1294aa4550666b871239dc22622eefa76ec05206':
Bad Wifi = strange looping of trying to connect
1294aa4550666b871239dc22622eefa76ec05206 11-Aug-2015 xin He <xinhe@google.com> Merge "Bad Wifi = strange looping of trying to connect" into mnc-dev
34512427a8b0b64c81a3bd94ff1498ad6601a92d 11-Aug-2015 Vinit Deshpande <vinitd@google.com> Fix a crash caused by race of RSSI monitoring and connection events

Disconnect can occur during RSSI monitoring; leaving current config
to be undefined.

Bug: 22956360
Change-Id: I54f5a87651a0ab64a9ffda22f4207beb4316d9e4
om/android/server/wifi/WifiStateMachine.java
82a40869d64684bd8f73001aba80516503f43ed9 07-Aug-2015 xinhe <xinhe@google.com> Bad Wifi = strange looping of trying to connect

b/22682106

Change-Id: I74111c145a9935d8b5d0651035147eade89042db
om/android/server/wifi/WifiConfigStore.java
6b51d3979474b763b2e48afc8d7925fa3f67f60e 06-Aug-2015 Vinit Deshpande <vinitd@google.com> am 2d3ab024: am 0e498b4c: am 67eb2983: am 851a49c6: Merge "Start scan immediately after disconnect is noticed" into mnc-dev

* commit '2d3ab024f870dca4bb0995d859b47e5d888d2946':
Start scan immediately after disconnect is noticed
2d3ab024f870dca4bb0995d859b47e5d888d2946 06-Aug-2015 Vinit Deshpande <vinitd@google.com> am 0e498b4c: am 67eb2983: am 851a49c6: Merge "Start scan immediately after disconnect is noticed" into mnc-dev

* commit '0e498b4c9b5ab25b432a96239f58e1a8076406c0':
Start scan immediately after disconnect is noticed
9a89da6eb4b307ff05ca2b74249c8eefc39038dd 06-Aug-2015 Vinit Deshpande <vinitd@google.com> am 851a49c6: Merge "Start scan immediately after disconnect is noticed" into mnc-dev

* commit '851a49c67efe70b090e8d8f2572ac1f66fbe2730':
Start scan immediately after disconnect is noticed
67eb298371b04d03c0140ccde890f2ecf7bf30c0 06-Aug-2015 Vinit Deshpande <vinitd@google.com> am 851a49c6: Merge "Start scan immediately after disconnect is noticed" into mnc-dev

* commit '851a49c67efe70b090e8d8f2572ac1f66fbe2730':
Start scan immediately after disconnect is noticed
851a49c67efe70b090e8d8f2572ac1f66fbe2730 06-Aug-2015 Vinit Deshpande <vinitd@google.com> Merge "Start scan immediately after disconnect is noticed" into mnc-dev
c0f76bad043a03a911c4121f58e599433dd31a63 06-Aug-2015 xinhe <xinhe@google.com> am 66c09a52: am b97abedb: am 9dc6bda4: resolved conflicts for merge of ee0a0132 to mnc-dr-dev

* commit '66c09a523324b80b9497a73b081ae6b7fe11ebad':
WiFi tethering AP says I can't use 5g in this country while in the US
66c09a523324b80b9497a73b081ae6b7fe11ebad 06-Aug-2015 xinhe <xinhe@google.com> am b97abedb: am 9dc6bda4: resolved conflicts for merge of ee0a0132 to mnc-dr-dev

* commit 'b97abedbc3399762d8c563c38aea953e6b008403':
WiFi tethering AP says I can't use 5g in this country while in the US
9dc6bda43f0767a1ecb3f901d9be0f523e9463f1 06-Aug-2015 xinhe <xinhe@google.com> resolved conflicts for merge of ee0a0132 to mnc-dr-dev

Change-Id: I61046edb56b9b54a759e4964762fa7b01d4eaba1
9affd084ee12ecbf935993884648b947c0d40208 05-Aug-2015 xinhe <xinhe@google.com> am ee0a0132: WiFi tethering AP says I can\'t use 5g in this country while in the US

* commit 'ee0a0132ebb0d7e9baf42e778ea9c094966ffb14':
WiFi tethering AP says I can't use 5g in this country while in the US
c065315c23f78ec462a56aec1aaa4e2a34549b8d 05-Aug-2015 Fyodor Kupolov <fkupolov@google.com> Legacy foreground apps should continue getting scan results

Pre-M apps running in the foreground now get scan results. For legacy apps
running in the background, no results are returned and the error is logged.

Bug: 22891540
Bug: 21852542
Change-Id: Ifc872888556f8c7b665b3bef3a4c02b1f67b0bad
om/android/server/wifi/WifiServiceImpl.java
ee0a0132ebb0d7e9baf42e778ea9c094966ffb14 04-Aug-2015 xinhe <xinhe@google.com> WiFi tethering AP says I can't use 5g in this country while in the US

b/22871989

Change-Id: I63c458c7353ecf84aa716118924364bb8f0f2844
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
d40eb7ad3e3ad904621822b773af8b2532110bbb 05-Aug-2015 xin He <xinhe@google.com> am a8a23321: am f6b387dd: am 0cc09187: am 69a99c03: Merge "Boot loop when SSID has non UTF-8 character in the name" into mnc-dev

* commit 'a8a2332141962f42e41fe9fec6461ac12dff4287':
Boot loop when SSID has non UTF-8 character in the name
a8a2332141962f42e41fe9fec6461ac12dff4287 05-Aug-2015 xin He <xinhe@google.com> am f6b387dd: am 0cc09187: am 69a99c03: Merge "Boot loop when SSID has non UTF-8 character in the name" into mnc-dev

* commit 'f6b387dd7b5d8be3620b171401c778cb535a49a2':
Boot loop when SSID has non UTF-8 character in the name
0f343412244ba8110be9837b71cbd9e953297d6e 05-Aug-2015 xin He <xinhe@google.com> am 69a99c03: Merge "Boot loop when SSID has non UTF-8 character in the name" into mnc-dev

* commit '69a99c03a9c78a507266c18443dc044a7b3e7869':
Boot loop when SSID has non UTF-8 character in the name
0cc09187b578a328f945cd58f0c030c4b713d37e 05-Aug-2015 xin He <xinhe@google.com> am 69a99c03: Merge "Boot loop when SSID has non UTF-8 character in the name" into mnc-dev

* commit '69a99c03a9c78a507266c18443dc044a7b3e7869':
Boot loop when SSID has non UTF-8 character in the name
69a99c03a9c78a507266c18443dc044a7b3e7869 05-Aug-2015 xin He <xinhe@google.com> Merge "Boot loop when SSID has non UTF-8 character in the name" into mnc-dev
d8ce388d48cc171307a588cf955acae687ecef69 05-Aug-2015 Vinit Deshpande <vinitd@google.com> Start scan immediately after disconnect is noticed

We are waiting some 15 second to do this; which can cause
lots of problems - including device going to doze mode.

Bug: 22922868
Change-Id: I654700d053591f463fef876199c7756f103373bc
om/android/server/wifi/WifiStateMachine.java
5cfd8d8b9f241dcad874125a1b5538ee0d6860fe 29-Jul-2015 xinhe <xinhe@google.com> Boot loop when SSID has non UTF-8 character in the name

b/22773761

Change-Id: I24e1579ff1aafde703d2090f93399fd5f299a75a
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiScanningServiceImpl.java
2db5ea10f5ba8aafa983d81ad6ab347dd6f77586 04-Aug-2015 Adam Lesinski <adamlesinski@google.com> am d76cdd8e: Log error when energy info is negative

* commit 'd76cdd8e08476ad5025f07a5d77a8d8f920a0721':
Log error when energy info is negative
94e82231b1b6553113e10b6bade81d30451ed6e2 04-Aug-2015 Adam Lesinski <adamlesinski@google.com> am 3ead4237: am 133d375f: am a7e4384d: am d76cdd8e: Log error when energy info is negative

* commit '3ead4237f7aba6824aab512b48439411ec9ad634':
Log error when energy info is negative
3ead4237f7aba6824aab512b48439411ec9ad634 04-Aug-2015 Adam Lesinski <adamlesinski@google.com> am 133d375f: am a7e4384d: am d76cdd8e: Log error when energy info is negative

* commit '133d375f410aee20611d966a1ba703ae26b7419f':
Log error when energy info is negative
a7e4384d748dcb5d46fe6343288681c43f5d3055 04-Aug-2015 Adam Lesinski <adamlesinski@google.com> am d76cdd8e: Log error when energy info is negative

* commit 'd76cdd8e08476ad5025f07a5d77a8d8f920a0721':
Log error when energy info is negative
d76cdd8e08476ad5025f07a5d77a8d8f920a0721 04-Aug-2015 Adam Lesinski <adamlesinski@google.com> Log error when energy info is negative

Bug:22822659
Change-Id: Iadab004b8dcdccbfae435990357426ec0e197dc2
om/android/server/wifi/WifiServiceImpl.java
ed02133db15058d89c7ac6a0c1e3363bfe053759 03-Aug-2015 Jan Nordqvist <jannq@google.com> am 3dec2dfe: am ff8b1405: am eff8f206: am 0b9684f3: Merge "Failed ANQP responses incorrectly stored as empty data in ANQP cache." into mnc-dev

* commit '3dec2dfeaffd63ef6c93a7785777e136da8661cb':
Failed ANQP responses incorrectly stored as empty data in ANQP cache.
3dec2dfeaffd63ef6c93a7785777e136da8661cb 03-Aug-2015 Jan Nordqvist <jannq@google.com> am ff8b1405: am eff8f206: am 0b9684f3: Merge "Failed ANQP responses incorrectly stored as empty data in ANQP cache." into mnc-dev

* commit 'ff8b14052e9b7103ec836dd0e083880d865a738c':
Failed ANQP responses incorrectly stored as empty data in ANQP cache.
21e58490dd37652850abe27818b2eba64fc58212 03-Aug-2015 Jan Nordqvist <jannq@google.com> am 0b9684f3: Merge "Failed ANQP responses incorrectly stored as empty data in ANQP cache." into mnc-dev

* commit '0b9684f3f0edb76242eda2f7772d9b7cc7662dda':
Failed ANQP responses incorrectly stored as empty data in ANQP cache.
eff8f206d07435447646cbbd930cd24dd82852c0 03-Aug-2015 Jan Nordqvist <jannq@google.com> am 0b9684f3: Merge "Failed ANQP responses incorrectly stored as empty data in ANQP cache." into mnc-dev

* commit '0b9684f3f0edb76242eda2f7772d9b7cc7662dda':
Failed ANQP responses incorrectly stored as empty data in ANQP cache.
0b9684f3f0edb76242eda2f7772d9b7cc7662dda 03-Aug-2015 Jan Nordqvist <jannq@google.com> Merge "Failed ANQP responses incorrectly stored as empty data in ANQP cache." into mnc-dev
6ffe92fafa67feb670e5ed2adf755d124946260a 01-Aug-2015 Vinit Deshpande <vinitd@google.com> am 06de46bd: am 34ce9ef6: am 0c741595: am 1c95611c: Merge "Remove more spammy logs" into mnc-dev

* commit '06de46bdd50dfad82e3a88a10201a4e46191b89c':
Remove more spammy logs
2a2d06101c258ef788e4698ec3884b5e7660f235 01-Aug-2015 Vinit Deshpande <vinitd@google.com> am 34d07e12: am e674d1eb: am 47f5e33b: am eef1bd1f: Merge "Fix incorrect network selection despite enableNetwork(disableOthers)" into mnc-dev

* commit '34d07e121c3213952a141127111f171e00f2e459':
Fix incorrect network selection despite enableNetwork(disableOthers)
ad5291057968db7be29bb284bbdccd05b629c9b8 01-Aug-2015 Dianne Hackborn <hackbod@google.com> am f453980f: am f5f7088d: am 5420f4c0: am 017fabff: Change MNC codename to just M.

* commit 'f453980fe691cf53dcb2b0dcdcd6ba104cd21c45':
Change MNC codename to just M.
06de46bdd50dfad82e3a88a10201a4e46191b89c 01-Aug-2015 Vinit Deshpande <vinitd@google.com> am 34ce9ef6: am 0c741595: am 1c95611c: Merge "Remove more spammy logs" into mnc-dev

* commit '34ce9ef642dd8ae65a918f36659f71b05fde1ab1':
Remove more spammy logs
34d07e121c3213952a141127111f171e00f2e459 01-Aug-2015 Vinit Deshpande <vinitd@google.com> am e674d1eb: am 47f5e33b: am eef1bd1f: Merge "Fix incorrect network selection despite enableNetwork(disableOthers)" into mnc-dev

* commit 'e674d1eb41b5069ac6dd23b00aa3e44955f77ffa':
Fix incorrect network selection despite enableNetwork(disableOthers)
f453980fe691cf53dcb2b0dcdcd6ba104cd21c45 01-Aug-2015 Dianne Hackborn <hackbod@google.com> am f5f7088d: am 5420f4c0: am 017fabff: Change MNC codename to just M.

* commit 'f5f7088dc07bdd9b0c6ddcd3ef92c7d5020593b4':
Change MNC codename to just M.
0c7415958305ba4a90920f9339e3a29f61139202 01-Aug-2015 Vinit Deshpande <vinitd@google.com> am 1c95611c: Merge "Remove more spammy logs" into mnc-dev

* commit '1c95611caf52644154f6c5ddd6cde843b63c5231':
Remove more spammy logs
86ef602ba6a28bee2067eba1df80ee05358b1de0 01-Aug-2015 Vinit Deshpande <vinitd@google.com> am 1c95611c: Merge "Remove more spammy logs" into mnc-dev

* commit '1c95611caf52644154f6c5ddd6cde843b63c5231':
Remove more spammy logs
1c95611caf52644154f6c5ddd6cde843b63c5231 01-Aug-2015 Vinit Deshpande <vinitd@google.com> Merge "Remove more spammy logs" into mnc-dev
42a1bf5e9b21288524d9a5fe90556abefc035879 01-Aug-2015 Jan Nordqvist <jannq@google.com> Failed ANQP responses incorrectly stored as empty data in ANQP cache.

Bug: 22882190
Change-Id: I2793247027579f07301bfc206800827a46af8c4e
om/android/server/wifi/hotspot2/SupplicantBridge.java
c7a79b5523683993b23b8890e7752a1dbfd4d589 01-Aug-2015 Vinit Deshpande <vinitd@google.com> am eef1bd1f: Merge "Fix incorrect network selection despite enableNetwork(disableOthers)" into mnc-dev

* commit 'eef1bd1f89c70d561e7e4ac4299c16e4bd9ef696':
Fix incorrect network selection despite enableNetwork(disableOthers)
47f5e33bd45f8fcb0a73cc07ebe4a49a713a9ad0 01-Aug-2015 Vinit Deshpande <vinitd@google.com> am eef1bd1f: Merge "Fix incorrect network selection despite enableNetwork(disableOthers)" into mnc-dev

* commit 'eef1bd1f89c70d561e7e4ac4299c16e4bd9ef696':
Fix incorrect network selection despite enableNetwork(disableOthers)
eef1bd1f89c70d561e7e4ac4299c16e4bd9ef696 01-Aug-2015 Vinit Deshpande <vinitd@google.com> Merge "Fix incorrect network selection despite enableNetwork(disableOthers)" into mnc-dev
5420f4c0fbd25a006218c399be08d9286bd50d8b 31-Jul-2015 Dianne Hackborn <hackbod@google.com> am 017fabff: Change MNC codename to just M.

* commit '017fabff2169403c27e551b39e87d3b2cd837409':
Change MNC codename to just M.
5252bba57aa6fd3f9a377fff12110e4028aca8cc 31-Jul-2015 Dianne Hackborn <hackbod@google.com> am 017fabff: Change MNC codename to just M.

* commit '017fabff2169403c27e551b39e87d3b2cd837409':
Change MNC codename to just M.
017fabff2169403c27e551b39e87d3b2cd837409 30-Jul-2015 Dianne Hackborn <hackbod@google.com> Change MNC codename to just M.

Change-Id: I04b95d96032bfca6cce5d957ee937d34128121cd
om/android/server/wifi/WifiServiceImpl.java
807f6a8502cc35bd250b903e2315bcdc34c49a92 31-Jul-2015 Vinit Deshpande <vinitd@google.com> Remove more spammy logs

Bug: 20416721

Change-Id: I2ddcc405d120208271e3a4740053987538924690
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiStateMachine.java
c7c402b2ac54f039a311e47a8d2f9b94c9598a61 31-Jul-2015 Shirish Kalele <kalele@google.com> am c2f412ec: am d66d06c5: am 3c40de91: am 8be2ac8c: Allow active network scorer access to scan results.

* commit 'c2f412ecd18cd332962f16f797c06f1419b97914':
Allow active network scorer access to scan results.
c2f412ecd18cd332962f16f797c06f1419b97914 31-Jul-2015 Shirish Kalele <kalele@google.com> am d66d06c5: am 3c40de91: am 8be2ac8c: Allow active network scorer access to scan results.

* commit 'd66d06c56d73c184f161dd6425ded7a4e0e15d54':
Allow active network scorer access to scan results.
0b67197e0a12381c645d972b6a1a700b58a57ff3 31-Jul-2015 Shirish Kalele <kalele@google.com> am 8be2ac8c: Allow active network scorer access to scan results.

* commit '8be2ac8cec40a2000715849b627642bdc87c10b3':
Allow active network scorer access to scan results.
3c40de9172bf0d691e2678ee099dc3e725d03a3b 31-Jul-2015 Shirish Kalele <kalele@google.com> am 8be2ac8c: Allow active network scorer access to scan results.

* commit '8be2ac8cec40a2000715849b627642bdc87c10b3':
Allow active network scorer access to scan results.
afb3e0da51f0c04752db8f049270824311c0e24e 30-Jul-2015 Fyodor Kupolov <fkupolov@google.com> am cf2cde7d: am cdec2f94: am e2019253: am c6b1ed46: Merge "Use PEERS_MAC_ADDRESS permission instead of isSystemProcess" into mnc-dev

* commit 'cf2cde7dde7ca1364e5099bff8f8d6e22c283cb2':
Use PEERS_MAC_ADDRESS permission instead of isSystemProcess
8be2ac8cec40a2000715849b627642bdc87c10b3 30-Jul-2015 Shirish Kalele <kalele@google.com> Allow active network scorer access to scan results.

BTW, AS corrected the import order of a lot of imports. Let me
know if you want it restored.

Bug: 22777873
Change-Id: Ia6ad069b83ecf9c0f07a620dbc98c85161a8e396
om/android/server/wifi/WifiServiceImpl.java
cf2cde7dde7ca1364e5099bff8f8d6e22c283cb2 30-Jul-2015 Fyodor Kupolov <fkupolov@google.com> am cdec2f94: am e2019253: am c6b1ed46: Merge "Use PEERS_MAC_ADDRESS permission instead of isSystemProcess" into mnc-dev

* commit 'cdec2f943441eab742b28e0eb4e8c48fb779ebdc':
Use PEERS_MAC_ADDRESS permission instead of isSystemProcess
c2c9d622a1de69eade77e56fd3aef888e78c8459 30-Jul-2015 Fyodor Kupolov <fkupolov@google.com> am c6b1ed46: Merge "Use PEERS_MAC_ADDRESS permission instead of isSystemProcess" into mnc-dev

* commit 'c6b1ed46dd5fe44da9fca8959f062e7bf6a7a800':
Use PEERS_MAC_ADDRESS permission instead of isSystemProcess
e2019253596def7ad445552d8bc48e7e4735f3cd 30-Jul-2015 Fyodor Kupolov <fkupolov@google.com> am c6b1ed46: Merge "Use PEERS_MAC_ADDRESS permission instead of isSystemProcess" into mnc-dev

* commit 'c6b1ed46dd5fe44da9fca8959f062e7bf6a7a800':
Use PEERS_MAC_ADDRESS permission instead of isSystemProcess
c6b1ed46dd5fe44da9fca8959f062e7bf6a7a800 30-Jul-2015 Fyodor Kupolov <fkupolov@google.com> Merge "Use PEERS_MAC_ADDRESS permission instead of isSystemProcess" into mnc-dev
560c50dedb0a39f2804d300387a3fe6f8a96edbf 27-Jul-2015 Fyodor Kupolov <fkupolov@google.com> Use PEERS_MAC_ADDRESS permission instead of isSystemProcess

A signature-level permission PEERS_MAC_ADDRESS was added to support a
use-case when SystemUI should be able to get the list of WiFi scan results for
Quick Settings. even when location is turned off in Settings.

Bug: 22777873
Bug: 21852542
Bug: 22728628
Change-Id: I68b42725ca5bc81f035f7e351070e5b7c5ff3050
om/android/server/wifi/WifiServiceImpl.java
e84a8320bf381aeffa61ff0a988a8d0641162ae2 30-Jul-2015 Vinit Deshpande <vinitd@google.com> am 7a5af20c: am cd36dbb2: am 41bb2e40: am 84e718d7: Improved wifiscanner logging

* commit '7a5af20c7c2c38fe382b3cc3d2e6b203fac3e86d':
Improved wifiscanner logging
7a5af20c7c2c38fe382b3cc3d2e6b203fac3e86d 30-Jul-2015 Vinit Deshpande <vinitd@google.com> am cd36dbb2: am 41bb2e40: am 84e718d7: Improved wifiscanner logging

* commit 'cd36dbb2832e4559f3d16db9b06372341c27ca99':
Improved wifiscanner logging
50291037eb02c3817d14c4610b04537a39883fad 30-Jul-2015 Vinit Deshpande <vinitd@google.com> am 84e718d7: Improved wifiscanner logging

* commit '84e718d76c7412121b64ed9ac497c8071f0ef5e9':
Improved wifiscanner logging
41bb2e409a6e5418d06b38def7bfcd4187661471 30-Jul-2015 Vinit Deshpande <vinitd@google.com> am 84e718d7: Improved wifiscanner logging

* commit '84e718d76c7412121b64ed9ac497c8071f0ef5e9':
Improved wifiscanner logging
84e718d76c7412121b64ed9ac497c8071f0ef5e9 30-Jul-2015 Vinit Deshpande <vinitd@google.com> Improved wifiscanner logging

Bug: 22833037

Change-Id: I7d39ec370153530fe588a0e7608d790033de197d
om/android/server/wifi/WifiScanningServiceImpl.java
3c5247a46ed8b4fa80bdf18578fba9269c2b1690 29-Jul-2015 Paul Jensen <pauljensen@google.com> am c50fe22d: am 72f0e2f6: am 48d3539f: resolved conflicts for merge of 9b82dc74 to mnc-dr-dev

* commit 'c50fe22d2854612b71c2d25931e00715cc61c721':
Disable WiFi autojoin when user decides via "Stay connected?" dialog
c50fe22d2854612b71c2d25931e00715cc61c721 29-Jul-2015 Paul Jensen <pauljensen@google.com> am 72f0e2f6: am 48d3539f: resolved conflicts for merge of 9b82dc74 to mnc-dr-dev

* commit '72f0e2f6aef6fa31324f3df8b2f8db661c5d33ac':
Disable WiFi autojoin when user decides via "Stay connected?" dialog
48d3539f991d4879d8009f78fa44dea902fb5e3a 29-Jul-2015 Paul Jensen <pauljensen@google.com> resolved conflicts for merge of 9b82dc74 to mnc-dr-dev

Change-Id: I67c8ba7dc94e17eb34fd315c969f02889a1596cc
149a700217f6b8016bcf458cac300d5ac52ba7ca 29-Jul-2015 Paul Jensen <pauljensen@google.com> am 9b82dc74: Merge "Disable WiFi autojoin when user decides via "Stay connected?" dialog" into mnc-dev

* commit '9b82dc749dc3bcb5c9fb57ec35d8030ae7098192':
Disable WiFi autojoin when user decides via "Stay connected?" dialog
9b82dc749dc3bcb5c9fb57ec35d8030ae7098192 29-Jul-2015 Paul Jensen <pauljensen@google.com> Merge "Disable WiFi autojoin when user decides via "Stay connected?" dialog" into mnc-dev
fa51d5cb6d2caad89d841d48719b6cf05f2b5273 29-Jul-2015 Jan Nordqvist <jannq@google.com> am dda245ac: am aaf32c8f: am 84fd44ab: am 57e85b00: Merge "Upped time-out for zero ANQP domain ID from 1 to 5 minutes. Implemented exponential back off for repetetive failing quesries." into mnc-dev

* commit 'dda245ac6ce09bfd3b307fa04a8ff6230bfb98c7':
Upped time-out for zero ANQP domain ID from 1 to 5 minutes. Implemented exponential back off for repetetive failing quesries.
dda245ac6ce09bfd3b307fa04a8ff6230bfb98c7 29-Jul-2015 Jan Nordqvist <jannq@google.com> am aaf32c8f: am 84fd44ab: am 57e85b00: Merge "Upped time-out for zero ANQP domain ID from 1 to 5 minutes. Implemented exponential back off for repetetive failing quesries." into mnc-dev

* commit 'aaf32c8fced463b429103e88342dc02fd8abbad2':
Upped time-out for zero ANQP domain ID from 1 to 5 minutes. Implemented exponential back off for repetetive failing quesries.
bd139462d94f581f8e2e9c906c10ffec0bc18aa9 29-Jul-2015 Vinit Deshpande <vinitd@google.com> Fix incorrect network selection despite enableNetwork(disableOthers)

App selection is overridden by auto-join selection, if network isn't
connected to. This change fixes the problem by adding a timeout during
which auto-join selection isn't allowed to be made.

Bug: 22127532

Change-Id: Ief78b6bf6e69d38ea8f43021e2a5316d52f8809f
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiStateMachine.java
adb8612b067500829948ff003ef0355975ae4293 28-Jul-2015 Jan Nordqvist <jannq@google.com> am 57e85b00: Merge "Upped time-out for zero ANQP domain ID from 1 to 5 minutes. Implemented exponential back off for repetetive failing quesries." into mnc-dev

* commit '57e85b00f16e03c1c7b24f561117131df33e7a04':
Upped time-out for zero ANQP domain ID from 1 to 5 minutes. Implemented exponential back off for repetetive failing quesries.
84fd44abe68148ab83a6dc76a80335015264fd5d 28-Jul-2015 Jan Nordqvist <jannq@google.com> am 57e85b00: Merge "Upped time-out for zero ANQP domain ID from 1 to 5 minutes. Implemented exponential back off for repetetive failing quesries." into mnc-dev

* commit '57e85b00f16e03c1c7b24f561117131df33e7a04':
Upped time-out for zero ANQP domain ID from 1 to 5 minutes. Implemented exponential back off for repetetive failing quesries.
57e85b00f16e03c1c7b24f561117131df33e7a04 28-Jul-2015 Jan Nordqvist <jannq@google.com> Merge "Upped time-out for zero ANQP domain ID from 1 to 5 minutes. Implemented exponential back off for repetetive failing quesries." into mnc-dev
407fa6084ac2796e6562843598b2654f36eb324d 28-Jul-2015 Vinit Deshpande <vinitd@google.com> am 81dddeb9: am 1b8096eb: Fix a race in WifiNative objects

* commit '81dddeb9108efcbec2cb95365dc0303f3b1cdf77':
Fix a race in WifiNative objects
4f14fb2dd825aea180082d3abed71211c1cfecd4 28-Jul-2015 xin He <xinhe@google.com> am 5d31474f: am 6fe0821a: am 34f73ba7: Merge "Framework should not call blacklist API on HAL unless ePNO is enabled" into mnc-dev

* commit '5d31474f28baf2d9f66cac9079fed7f5f9c2b060':
Framework should not call blacklist API on HAL unless ePNO is enabled
312c60d9779c200e8250b8a7ae32eaea01b08b42 13-Jul-2015 Paul Jensen <pauljensen@google.com> Disable WiFi autojoin when user decides via "Stay connected?" dialog

If the user selects "No" in the "Stay connected?" dialog box:
1. Disable autojoining that network in the future, and
2. Disassociate from that network.
Also, correct the name of a constant that was misleading.

Bug:22187193
Change-Id: I14dc9236c57e3ab7d3ec95edc906787cbfbf3c9f
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiStateMachine.java
81dddeb9108efcbec2cb95365dc0303f3b1cdf77 28-Jul-2015 Vinit Deshpande <vinitd@google.com> am 1b8096eb: Fix a race in WifiNative objects

* commit '1b8096ebeb6360ac6f25d81eff36cc6926973e68':
Fix a race in WifiNative objects
1b8096ebeb6360ac6f25d81eff36cc6926973e68 23-Jul-2015 Vinit Deshpande <vinitd@google.com> Fix a race in WifiNative objects

disconnectFromSupplicant doesn't have any synchronization;
so it can cause problems when WifiStateMachine is disconnecting
and P2p statemachine is sending commands.

Bug: 22667667
Change-Id: I92e6ee44618813341e171f84442791a6403a5010
om/android/server/wifi/WifiNative.java
ffdef92ed945b7744f5df5effdbba152e022b0c3 28-Jul-2015 Vinit Deshpande <vinitd@google.com> am a142187a: Merge "Fix a race in WifiNative objects" into mnc-dev

* commit 'a142187a4cd133a193675caf419ea25423eeab85':
Fix a race in WifiNative objects
bc75cd2de4583eabd5efa2e090796ae570a31dc6 28-Jul-2015 Vinit Deshpande <vinitd@google.com> am a142187a: Merge "Fix a race in WifiNative objects" into mnc-dev

* commit 'a142187a4cd133a193675caf419ea25423eeab85':
Fix a race in WifiNative objects
a142187a4cd133a193675caf419ea25423eeab85 28-Jul-2015 Vinit Deshpande <vinitd@google.com> Merge "Fix a race in WifiNative objects" into mnc-dev
5d31474f28baf2d9f66cac9079fed7f5f9c2b060 28-Jul-2015 xin He <xinhe@google.com> am 6fe0821a: am 34f73ba7: Merge "Framework should not call blacklist API on HAL unless ePNO is enabled" into mnc-dev

* commit '6fe0821af95c86df9c5fcc71aeeada863c953250':
Framework should not call blacklist API on HAL unless ePNO is enabled
65fbeb4a190293c618416c7cd0898d4e819259d3 28-Jul-2015 xin He <xinhe@google.com> am 34f73ba7: Merge "Framework should not call blacklist API on HAL unless ePNO is enabled" into mnc-dev

* commit '34f73ba7cbcf3c4ed54898e808caa9d24bc3561c':
Framework should not call blacklist API on HAL unless ePNO is enabled
6fe0821af95c86df9c5fcc71aeeada863c953250 28-Jul-2015 xin He <xinhe@google.com> am 34f73ba7: Merge "Framework should not call blacklist API on HAL unless ePNO is enabled" into mnc-dev

* commit '34f73ba7cbcf3c4ed54898e808caa9d24bc3561c':
Framework should not call blacklist API on HAL unless ePNO is enabled
34f73ba7cbcf3c4ed54898e808caa9d24bc3561c 28-Jul-2015 xin He <xinhe@google.com> Merge "Framework should not call blacklist API on HAL unless ePNO is enabled" into mnc-dev
68aaaa93878daeb9f1cb95baca79ee03154f15f5 24-Jul-2015 xinhe <xinhe@google.com> Framework should not call blacklist API on HAL unless ePNO is enabled

b/22699627

Change-Id: I270d2d628d989dbd03934c9449bf3db6101f28f5
om/android/server/wifi/WifiConfigStore.java
8408fc51cf15e20700b66242ef921b252552e9b1 27-Jul-2015 Mitchell Wills <mwills@google.com> Merge "Removed old code to support PasspointStateMachine"
22286a97a855119b0e28f725e89b1cf98efd6bad 24-Jul-2015 Fyodor Kupolov <fkupolov@google.com> am 13af7314: am b19027f0: Merge "Enforce location permission for apps targeting M" into mnc-dev

* commit '13af7314dce8dbee1a436252ef2bf0db4956fa77':
Enforce location permission for apps targeting M
400be6641e79d90452077f1412a85b9c26761810 24-Jul-2015 xin He <xinhe@google.com> am 8c640956: am fbd35be2: Merge "Restart loop on MRA16G: Abort message:" into mnc-dev

* commit '8c640956f308202f9cdcc3c2a313f1d69e9e118d':
Restart loop on MRA16G: Abort message:
9fb2505ef188e67351988ed9f31363171177fa33 24-Jul-2015 Jan Nordqvist <jannq@google.com> am 6a067c5f: am 7278b8ad: Merge "Added NPE guard around wpa_supplicant results." into mnc-dev

* commit '6a067c5f9e23072f8493f119d5b999ef5e865d0e':
Added NPE guard around wpa_supplicant results.
42c9036be37bb265d03d53ad2c6fd153500c9f62 24-Jul-2015 xin He <xinhe@google.com> am 140333f4: am c28e026a: Merge "Angler Should Not Use Channel 11 for SoftAP" into mnc-dev

* commit '140333f4a79ae4bcf026cd2255bf5a7460d17e75':
Angler Should Not Use Channel 11 for SoftAP
13af7314dce8dbee1a436252ef2bf0db4956fa77 23-Jul-2015 Fyodor Kupolov <fkupolov@google.com> am b19027f0: Merge "Enforce location permission for apps targeting M" into mnc-dev

* commit 'b19027f007c641debd423e3f1fa7f56d891045ef':
Enforce location permission for apps targeting M
8c640956f308202f9cdcc3c2a313f1d69e9e118d 23-Jul-2015 xin He <xinhe@google.com> am fbd35be2: Merge "Restart loop on MRA16G: Abort message:" into mnc-dev

* commit 'fbd35be2ee76cb2f8090f563c8f2666ce0dee607':
Restart loop on MRA16G: Abort message:
6a067c5f9e23072f8493f119d5b999ef5e865d0e 23-Jul-2015 Jan Nordqvist <jannq@google.com> am 7278b8ad: Merge "Added NPE guard around wpa_supplicant results." into mnc-dev

* commit '7278b8ad40ab62383229e458be962d28321158ed':
Added NPE guard around wpa_supplicant results.
140333f4a79ae4bcf026cd2255bf5a7460d17e75 23-Jul-2015 xin He <xinhe@google.com> am c28e026a: Merge "Angler Should Not Use Channel 11 for SoftAP" into mnc-dev

* commit 'c28e026a27212c867d0b863ec65c71b67513b429':
Angler Should Not Use Channel 11 for SoftAP
bb30263048e44498ca263d0114157c14392daeec 23-Jul-2015 Fyodor Kupolov <fkupolov@google.com> am b19027f0: Merge "Enforce location permission for apps targeting M" into mnc-dev

* commit 'b19027f007c641debd423e3f1fa7f56d891045ef':
Enforce location permission for apps targeting M
25eea106cbc3cdaa4deff56c55ae03a023a250a5 23-Jul-2015 xin He <xinhe@google.com> am fbd35be2: Merge "Restart loop on MRA16G: Abort message:" into mnc-dev

* commit 'fbd35be2ee76cb2f8090f563c8f2666ce0dee607':
Restart loop on MRA16G: Abort message:
38062f8b9bc77602b3320dd491b6f70eac988688 23-Jul-2015 Jan Nordqvist <jannq@google.com> am 7278b8ad: Merge "Added NPE guard around wpa_supplicant results." into mnc-dev

* commit '7278b8ad40ab62383229e458be962d28321158ed':
Added NPE guard around wpa_supplicant results.
8d72ce06429c1bf3faeae2d85b896ca6ba279734 23-Jul-2015 xin He <xinhe@google.com> am c28e026a: Merge "Angler Should Not Use Channel 11 for SoftAP" into mnc-dev

* commit 'c28e026a27212c867d0b863ec65c71b67513b429':
Angler Should Not Use Channel 11 for SoftAP
b577f391af2c484e443c19b3df1d62cc0924692a 23-Jul-2015 Vinit Deshpande <vinitd@google.com> Fix a race in WifiNative objects

disconnectFromSupplicant doesn't have any synchronization;
so it can cause problems when WifiStateMachine is disconnecting
and P2p statemachine is sending commands.

Bug: 22667667
Change-Id: I92e6ee44618813341e171f84442791a6403a5010
om/android/server/wifi/WifiNative.java
82414ead13eb2554cf412ad00a30d9e21499bf75 23-Jul-2015 Jan Nordqvist <jannq@google.com> Upped time-out for zero ANQP domain ID from 1 to 5 minutes.
Implemented exponential back off for repetetive failing quesries.

Bug: 22662457
Change-Id: Ie9a8ccb71adc74e38c4a5f2a96431dcbd20b7833
om/android/server/wifi/hotspot2/ANQPData.java
om/android/server/wifi/hotspot2/AnqpCache.java
b19027f007c641debd423e3f1fa7f56d891045ef 23-Jul-2015 Fyodor Kupolov <fkupolov@google.com> Merge "Enforce location permission for apps targeting M" into mnc-dev
fbd35be2ee76cb2f8090f563c8f2666ce0dee607 23-Jul-2015 xin He <xinhe@google.com> Merge "Restart loop on MRA16G: Abort message:" into mnc-dev
7278b8ad40ab62383229e458be962d28321158ed 23-Jul-2015 Jan Nordqvist <jannq@google.com> Merge "Added NPE guard around wpa_supplicant results." into mnc-dev
127f7244183786e6ccae09e81eeccdac31973e69 23-Jul-2015 xinhe <xinhe@google.com> Restart loop on MRA16G: Abort message:

'art/runtime/thread.cc:1320] No pending exception
expected: java.lang.ArrayIndexOutOfBoundsException

b/22591534

Change-Id: Ib8380b38fae8c3b0cb1e8980d397c9bfc98c9b81
om/android/server/wifi/WifiNative.java
086148f550b6e293ef3154265ec32317a10c7217 23-Jul-2015 Mitchell Wills <mwills@google.com> Removed old code to support PasspointStateMachine

Change-Id: Ieb84b84848d42befe963ba5a9be96d508f02ed7d
om/android/server/wifi/WifiMonitor.java
c28e026a27212c867d0b863ec65c71b67513b429 22-Jul-2015 xin He <xinhe@google.com> Merge "Angler Should Not Use Channel 11 for SoftAP" into mnc-dev
5ef40f88bab7e645a5a9e42aeae768d3b916c02c 22-Jul-2015 Jan Nordqvist <jannq@google.com> Added NPE guard around wpa_supplicant results.

Bug: 22661007
Change-Id: I4d8629ba0033599ceb995349ee16139e96970240
om/android/server/wifi/hotspot2/SupplicantBridge.java
e660aa2b9c9ca3a5c7903c37571ca7b91feb4ccf 22-Jul-2015 Fyodor Kupolov <fkupolov@google.com> Enforce location permission for apps targeting M

Enforce location permission for apps targeting M, for legacy apps - log an
error.

Also fixed an issue, when calling uid was not used to check permission.

Bug: 21852542
Change-Id: I8186acbeb4e8a2c5285f05ce3335e9c18a780112
om/android/server/wifi/WifiServiceImpl.java
52b6d4cbf2815d18f35c64af955bf3859907b5c1 17-Jul-2015 xinhe <xinhe@google.com> Angler Should Not Use Channel 11 for SoftAP

b/22541346

Change-Id: I300605d8d305214e81803d5d54549e7c3e5bc5bb
om/android/server/wifi/WifiApConfigStore.java
om/android/server/wifi/WifiStateMachine.java
bfb8d4c62ffd17acfa35e75e60519d8ed93cb16c 18-Jul-2015 Erik Kline <ek@google.com> am 5114ec46: Don\'t ignore our own default values

* commit '5114ec4642ac9624c68aead71dd7b741e27262e7':
Don't ignore our own default values
4c8db7864157490ec3497c22e1d863e0e11c725b 18-Jul-2015 Prerepa Viswanadham <dham@google.com> am 19d76428: Fix build

* commit '19d764282b423ca65aec084bebe5d9bb89dfcc07':
Fix build
7f0c9b01595bebdc4d7b70939fc3444cdcda78da 18-Jul-2015 Prerepa Viswanadham <dham@google.com> am aed5cb65: RSSI monitoring in Wifi state machine

* commit 'aed5cb65d8eefb2eee56a29e33ac3cd8b03312e7':
RSSI monitoring in Wifi state machine
7ab2c03dcfab34f451aee22d689ba0078a28ce10 18-Jul-2015 Prerepa Viswanadham <dham@google.com> am 3bd22ceb: Fix code review comments in WiFi offload CL f7fe4b25bf294f808b99b1e1f25e8a7a62817ef7

* commit '3bd22cebc41ed0786d0e7bd2970a634a8bb0093e':
Fix code review comments in WiFi offload CL f7fe4b25bf294f808b99b1e1f25e8a7a62817ef7
ce9ef32854b10f38c73b311a1e6362e625aba5aa 18-Jul-2015 Prerepa Viswanadham <dham@google.com> am c55e8816: WiFi keep alive offloading service implementation

* commit 'c55e88163b223db0ca6a99ed6ffe91845c30a576':
WiFi keep alive offloading service implementation
8e853fb9dcfe46bcd5be18e12885120e4eae8ca4 18-Jul-2015 Prerepa Viswanadham <dham@google.com> am 50de00cb: Merge "Sample code for RSSI callbacks on wifi." into mnc-dr-dev

* commit '50de00cb49bb5110b5e9a75058468e68f1368f8d':
Sample code for RSSI callbacks on wifi.
5114ec4642ac9624c68aead71dd7b741e27262e7 13-Jul-2015 Erik Kline <ek@google.com> Don't ignore our own default values

Bug: 21407651
Change-Id: I5cd13c460a439a8345efb64f3418dd526660ac89
om/android/server/wifi/WifiStateMachine.java
19d764282b423ca65aec084bebe5d9bb89dfcc07 11-Jul-2015 Prerepa Viswanadham <dham@google.com> Fix build

Change-Id: I02eb29bca90c6bb507511f9e9ad7dec97411ffe0
om/android/server/wifi/WifiStateMachine.java
aed5cb65d8eefb2eee56a29e33ac3cd8b03312e7 10-Jul-2015 Prerepa Viswanadham <dham@google.com> RSSI monitoring in Wifi state machine

Bug: 21405941
Change-Id: I016a073da3bcff9e9f878e1c6eb87bcaa233ef84
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
3bd22cebc41ed0786d0e7bd2970a634a8bb0093e 10-Jul-2015 Prerepa Viswanadham <dham@google.com> Fix code review comments in WiFi offload
CL f7fe4b25bf294f808b99b1e1f25e8a7a62817ef7

Change-Id: I5f0468cf7c84a5031fb86631c27e71c202f4f843
om/android/server/wifi/WifiNative.java
c55e88163b223db0ca6a99ed6ffe91845c30a576 02-Jul-2015 Prerepa Viswanadham <dham@google.com> WiFi keep alive offloading service implementation

Bug: 21405946
Change-Id: If7fe4b25bf294f808b99b1e1f25e8a7a62817ef7
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
50de00cb49bb5110b5e9a75058468e68f1368f8d 18-Jul-2015 Prerepa Viswanadham <dham@google.com> Merge "Sample code for RSSI callbacks on wifi." into mnc-dr-dev
5730605bb29ce630a0ab6611ea3a04ba6553c2d5 18-Jul-2015 xinhe <xinhe@google.com> am 266f3111: Merge "Add API to turn OFF "best network selection" feature" into mnc-dev

* commit '266f3111427002d10ffd85fcea828a2725e540de':
Add API to turn OFF "best network selection" feature
e96078fd4764526c6ab245aac1e763016f00eab3 18-Jul-2015 xinhe <xinhe@google.com> am 266f3111: Merge "Add API to turn OFF "best network selection" feature" into mnc-dev

* commit '266f3111427002d10ffd85fcea828a2725e540de':
Add API to turn OFF "best network selection" feature
266f3111427002d10ffd85fcea828a2725e540de 18-Jul-2015 xinhe <xinhe@google.com> Merge "Add API to turn OFF "best network selection" feature" into mnc-dev
ea3db156b75f448d8a63dc75bd7ce310e607da96 17-Jul-2015 Jan Nordqvist <jannq@google.com> am a9ca951e: Merge "Passpoint: Realm or PLMN match should promote SP match to Roaming" into mnc-dev

* commit 'a9ca951ea5ddd4159ca709f762b224172501e4f1':
Passpoint: Realm or PLMN match should promote SP match to Roaming
a562928cd4969896b56d555198658bdc6fbf3518 17-Jul-2015 Jan Nordqvist <jannq@google.com> am a9ca951e: Merge "Passpoint: Realm or PLMN match should promote SP match to Roaming" into mnc-dev

* commit 'a9ca951ea5ddd4159ca709f762b224172501e4f1':
Passpoint: Realm or PLMN match should promote SP match to Roaming
a9ca951ea5ddd4159ca709f762b224172501e4f1 17-Jul-2015 Jan Nordqvist <jannq@google.com> Merge "Passpoint: Realm or PLMN match should promote SP match to Roaming" into mnc-dev
e1e95ff407e7d5654f9b753ced04ff6ae8137d59 08-Jul-2015 Lorenzo Colitti <lorenzo@google.com> Sample code for RSSI callbacks on wifi.

Bug: 21405941
Change-Id: I08961e766e0ab3872d90868b882e4e2e24ab0c03
om/android/server/wifi/WifiStateMachine.java
55d79585463b7b2c99e7e0ef97f1e44e62898a96 17-Jul-2015 Vinit Deshpande <vinitd@google.com> am af5b4988: Synchronize getScanCapabilities() with other commands

* commit 'af5b49884f189bb171c9dc6c6a4405d97e7912ac':
Synchronize getScanCapabilities() with other commands
f0a605f355cd1425bf2a3e92a4d78a271045574a 16-Jul-2015 Vinit Deshpande <vinitd@google.com> am af5b4988: Synchronize getScanCapabilities() with other commands

* commit 'af5b49884f189bb171c9dc6c6a4405d97e7912ac':
Synchronize getScanCapabilities() with other commands
c2db1a4ff61fdf72be070e0c1cb739e755760bf3 16-Jul-2015 Jan Nordqvist <jannq@google.com> Passpoint: Realm or PLMN match should promote SP match to Roaming

Bug: 22531732
Change-Id: Ie695b0e9c70abe50e26e5bcf516d382c90b7aa87
om/android/server/wifi/anqp/NAIRealmData.java
om/android/server/wifi/anqp/NAIRealmElement.java
om/android/server/wifi/anqp/eap/EAPMethod.java
om/android/server/wifi/hotspot2/AuthMatch.java
om/android/server/wifi/hotspot2/pps/HomeSP.java
af5b49884f189bb171c9dc6c6a4405d97e7912ac 16-Jul-2015 Vinit Deshpande <vinitd@google.com> Synchronize getScanCapabilities() with other commands

This is required to ensure that only one HAL command is
issued at a time by the framework.

Bug: 22480212
Change-Id: Iaf4bf7cf4c34f8804bf4522e96cb7a1903f41cf3
om/android/server/wifi/WifiNative.java
4a2f6028419315f3b104b1a488136774c6907794 16-Jul-2015 Jan Nordqvist <jannq@google.com> am 4aef3283: Fixed incorrect network validation.

* commit '4aef3283bf78e233a11fa34af2c7c38362879625':
Fixed incorrect network validation.
423f02272e956f6836198996e8f862eee703624a 16-Jul-2015 Jan Nordqvist <jannq@google.com> am 4aef3283: Fixed incorrect network validation.

* commit '4aef3283bf78e233a11fa34af2c7c38362879625':
Fixed incorrect network validation.
4aef3283bf78e233a11fa34af2c7c38362879625 16-Jul-2015 Jan Nordqvist <jannq@google.com> Fixed incorrect network validation.

Bug: 22490051
Change-Id: I2d9a39502a10170bb452766fb9078939225dba2e
om/android/server/wifi/WifiServiceImpl.java
d40902df46e1bc3784e52fb59d54c84ead9d60fa 16-Jul-2015 Jan Nordqvist <jannq@google.com> am 026d97e4: Merge "Added dump of ANQP cache to bugreport." into mnc-dev

* commit '026d97e484da6d2dd01f2e3d39d0e214170293f0':
Added dump of ANQP cache to bugreport.
f331075eb4fa3f663746d885cf7c311371e51547 16-Jul-2015 Jan Nordqvist <jannq@google.com> am 026d97e4: Merge "Added dump of ANQP cache to bugreport." into mnc-dev

* commit '026d97e484da6d2dd01f2e3d39d0e214170293f0':
Added dump of ANQP cache to bugreport.
026d97e484da6d2dd01f2e3d39d0e214170293f0 16-Jul-2015 Jan Nordqvist <jannq@google.com> Merge "Added dump of ANQP cache to bugreport." into mnc-dev
a8647b8cb29de22765062714cb265247234c3d32 10-Jul-2015 xinhe <xinhe@google.com> Add API to turn OFF "best network selection" feature

b/14990268

Change-Id: Ifa96a08f4bf9868afc8ddc88e178fc6375e70f8b
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
b374c15f2cfcc25830a7f11e98621c5adbae5619 15-Jul-2015 xinhe <xinhe@google.com> am 98c49c03: Merge "Need to disable 5GHz bands for WiFi tethering in Japan Also fix the wificontroller dose not update state if Softap start failed. This will block further enable STA or re-enable AP." into mnc-dev

* commit '98c49c031b5f0d6d28068aa738d32f952ea6c8cf':
Need to disable 5GHz bands for WiFi tethering in Japan Also fix the wificontroller dose not update state if Softap start failed. This will block further enable STA or re-enable AP.
53f8182196482a0a3c35dee72c7aa947eea1d7ee 15-Jul-2015 xinhe <xinhe@google.com> am 98c49c03: Merge "Need to disable 5GHz bands for WiFi tethering in Japan Also fix the wificontroller dose not update state if Softap start failed. This will block further enable STA or re-enable AP." into mnc-dev

* commit '98c49c031b5f0d6d28068aa738d32f952ea6c8cf':
Need to disable 5GHz bands for WiFi tethering in Japan Also fix the wificontroller dose not update state if Softap start failed. This will block further enable STA or re-enable AP.
6c09f82f502ed1f1344437617b0bc25f89e48d86 15-Jul-2015 Fyodor Kupolov <fkupolov@google.com> am 4ea0748b: Merge "Block results if location is disabled in Settings" into mnc-dev

* commit '4ea0748bf5f8028a7766f9eb694a2eb3ef7bcf57':
Block results if location is disabled in Settings
98c49c031b5f0d6d28068aa738d32f952ea6c8cf 15-Jul-2015 xinhe <xinhe@google.com> Merge "Need to disable 5GHz bands for WiFi tethering in Japan Also fix the wificontroller dose not update state if Softap start failed. This will block further enable STA or re-enable AP." into mnc-dev
db2c70445b3c5ef5742bfcdbdfdbeafe4a40787b 15-Jul-2015 Fyodor Kupolov <fkupolov@google.com> am 4ea0748b: Merge "Block results if location is disabled in Settings" into mnc-dev

* commit '4ea0748bf5f8028a7766f9eb694a2eb3ef7bcf57':
Block results if location is disabled in Settings
9f7795c694d048fdfecc4117cf5ddbd3e6ae1406 14-Jul-2015 Jan Nordqvist <jannq@google.com> Added dump of ANQP cache to bugreport.

Bug: 22410118
Change-Id: Ibc396ecf779087473f5fee0db732baf3ece16aab
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/hotspot2/ANQPData.java
om/android/server/wifi/hotspot2/AnqpCache.java
4ea0748bf5f8028a7766f9eb694a2eb3ef7bcf57 14-Jul-2015 Fyodor Kupolov <fkupolov@google.com> Merge "Block results if location is disabled in Settings" into mnc-dev
f08fd3ea3fda7a74f20fa6bf0a7f77798672e053 14-Jul-2015 Vinit Deshpande <vinitd@google.com> am f33245e1: Merge "Allowing rewrite of Passpoint credential." into mnc-dev

* commit 'f33245e1755794a0b6f1b8bfa7376ead57e68b53':
Allowing rewrite of Passpoint credential.
588e4ba694aba1b5b34aa2596809d8fa80ecb59d 14-Jul-2015 xinhe <xinhe@google.com> Need to disable 5GHz bands for WiFi tethering in Japan
Also fix the wificontroller dose not update state if Softap
start failed. This will block further enable STA or
re-enable AP.

b/22396383

Change-Id: Idb920a79bba7078cda3493211fd4108560dd261d
om/android/server/wifi/WifiController.java
om/android/server/wifi/WifiStateMachine.java
97fca972c995a3eb7cc8632ba6cf1c4626205ecc 14-Jul-2015 Vinit Deshpande <vinitd@google.com> am f33245e1: Merge "Allowing rewrite of Passpoint credential." into mnc-dev

* commit 'f33245e1755794a0b6f1b8bfa7376ead57e68b53':
Allowing rewrite of Passpoint credential.
f33245e1755794a0b6f1b8bfa7376ead57e68b53 14-Jul-2015 Vinit Deshpande <vinitd@google.com> Merge "Allowing rewrite of Passpoint credential." into mnc-dev
2812e1e19291d4f0dbabf7fe23d031d8cd641830 10-Jul-2015 Fyodor Kupolov <fkupolov@google.com> Block results if location is disabled in Settings

Bug: 21852542, 22389679
Change-Id: Ia84b209167308b65387153d37c5e51fb71083fb2
om/android/server/wifi/WifiServiceImpl.java
75551d3fd0effa88131be1d8cfbe47a6e34f20da 10-Jul-2015 Vinit Deshpande <vinitd@google.com> am 0401bed8: Merge "Capture an additional report when user captures a bugreport" into mnc-dev

* commit '0401bed81a8a4ed5b6459dc0b3063aca14827bd7':
Capture an additional report when user captures a bugreport
32044fca97fb7ea60ee55e4527a891d6472440d2 10-Jul-2015 Vinit Deshpande <vinitd@google.com> am 0401bed8: Merge "Capture an additional report when user captures a bugreport" into mnc-dev

* commit '0401bed81a8a4ed5b6459dc0b3063aca14827bd7':
Capture an additional report when user captures a bugreport
0401bed81a8a4ed5b6459dc0b3063aca14827bd7 10-Jul-2015 Vinit Deshpande <vinitd@google.com> Merge "Capture an additional report when user captures a bugreport" into mnc-dev
83e4b27d653d5413eac4a87313df395c72ebd8ee 10-Jul-2015 Prem Kumar <premk@google.com> am ceca87b7: Merge "Added guard around IMSI parameter." into mnc-dev

* commit 'ceca87b79c38c6ef7aeb2a4728e8b82e4fcdb4ac':
Added guard around IMSI parameter.
c3231a1d9c4b124e51ff7bb99c5480c6c1d86e67 10-Jul-2015 Prem Kumar <premk@google.com> am ceca87b7: Merge "Added guard around IMSI parameter." into mnc-dev

* commit 'ceca87b79c38c6ef7aeb2a4728e8b82e4fcdb4ac':
Added guard around IMSI parameter.
9a41261e4f688411a7038781ca959b2007965f06 09-Jul-2015 Vinit Deshpande <vinitd@google.com> Capture an additional report when user captures a bugreport

Currently, all ringbuffer data and memory dump are captured when
an error is discovered. But that leaves a lot of scenarios
where we don't have this data. This change captures this data
on each dupmsys operation as well.

This change also captures firmware memory dump to debug
additional problems.

Bug: 22390445

Change-Id: I1fab1dacc4b11287697e9b7d97670bebc4c4bac5
om/android/server/wifi/WifiLogger.java
om/android/server/wifi/WifiStateMachine.java
ceca87b79c38c6ef7aeb2a4728e8b82e4fcdb4ac 10-Jul-2015 Prem Kumar <premk@google.com> Merge "Added guard around IMSI parameter." into mnc-dev
640187cb348201ed63820cfcb66bdfc1f19cdcc8 10-Jul-2015 Jan Nordqvist <jannq@google.com> Added guard around IMSI parameter.

Bug: 22388499
Change-Id: If68165b8d89f369d83c9d6d19896d1802805cef7
om/android/server/wifi/ConfigurationMap.java
39dc3af67b55e5472b0bbf11ce5932f7496a15d8 09-Jul-2015 Jan Nordqvist <jannq@google.com> Allowing rewrite of Passpoint credential.

Bug: 21779835
Change-Id: I4f1e265bbf222b64935613ef8fa1519a54aab0f8
om/android/server/wifi/WifiConfigStore.java
a75273a202e3b0d22a254abf2f51d0880635723d 09-Jul-2015 Fyodor Kupolov <fkupolov@google.com> am aca3b874: Merge "Check location permission/appop in getScanResults" into mnc-dev

* commit 'aca3b874dfcf503a7de41d13be449557369116ef':
Check location permission/appop in getScanResults
575ff3d863319a19a5ea20925d5a4a6b266ea148 09-Jul-2015 Fyodor Kupolov <fkupolov@google.com> am aca3b874: Merge "Check location permission/appop in getScanResults" into mnc-dev

* commit 'aca3b874dfcf503a7de41d13be449557369116ef':
Check location permission/appop in getScanResults
aca3b874dfcf503a7de41d13be449557369116ef 09-Jul-2015 Fyodor Kupolov <fkupolov@google.com> Merge "Check location permission/appop in getScanResults" into mnc-dev
85964a7ee402dda831e2d78898c872b317d21ff7 09-Jul-2015 Navtej Singh Mann <navtejsingh@google.com> am d2b8f8b2: Merge "Use device capabilities for setting default scan parameters" into mnc-dev

* commit 'd2b8f8b2467928aee672382bc95e3be76235d186':
Use device capabilities for setting default scan parameters
a9345fe9947682d4a5a4e0bc576dc760a15293a6 09-Jul-2015 Navtej Singh Mann <navtejsingh@google.com> am d2b8f8b2: Merge "Use device capabilities for setting default scan parameters" into mnc-dev

* commit 'd2b8f8b2467928aee672382bc95e3be76235d186':
Use device capabilities for setting default scan parameters
d2b8f8b2467928aee672382bc95e3be76235d186 09-Jul-2015 Navtej Singh Mann <navtejsingh@google.com> Merge "Use device capabilities for setting default scan parameters" into mnc-dev
98819c29b449d95c057b8f89e5984f2fabacb1fd 08-Jul-2015 Vinit Deshpande <vinitd@google.com> am 4e17f1cf: Merge "Add information in logs about lost wifi networks" into mnc-dev

* commit '4e17f1cf17db8a1e22e69367257d1e288ee880d0':
Add information in logs about lost wifi networks
49439ff84c31efb3cabca214705fd8dced99acbc 08-Jul-2015 Vinit Deshpande <vinitd@google.com> am 4e17f1cf: Merge "Add information in logs about lost wifi networks" into mnc-dev

* commit '4e17f1cf17db8a1e22e69367257d1e288ee880d0':
Add information in logs about lost wifi networks
4e17f1cf17db8a1e22e69367257d1e288ee880d0 08-Jul-2015 Vinit Deshpande <vinitd@google.com> Merge "Add information in logs about lost wifi networks" into mnc-dev
538fac5da0097cf893f0bbb19e99132fef91df7d 08-Jul-2015 Navtej Singh Mann <navtejsingh@google.com> Use device capabilities for setting default scan parameters

Bug: 22233853
Change-Id: Ib34863cdc24a2396e15aadfb4a77d262efb07ca1
om/android/server/wifi/WifiScanningServiceImpl.java
f5cf5c05f61e5003dd04ccd2a3d55e7b927bef83 07-Jul-2015 xin He <xinhe@google.com> am c87ac34c: Merge "wifi: Fix softAP turn-ON issue in statically linked driver" into mnc-dev

* commit 'c87ac34c595f06504665be11faa97884ee2852af':
wifi: Fix softAP turn-ON issue in statically linked driver
56a132f286849c5730aba2c555f5e323054b08cf 07-Jul-2015 xin He <xinhe@google.com> am c87ac34c: Merge "wifi: Fix softAP turn-ON issue in statically linked driver" into mnc-dev

* commit 'c87ac34c595f06504665be11faa97884ee2852af':
wifi: Fix softAP turn-ON issue in statically linked driver
c87ac34c595f06504665be11faa97884ee2852af 07-Jul-2015 xin He <xinhe@google.com> Merge "wifi: Fix softAP turn-ON issue in statically linked driver" into mnc-dev
699828f0f5b3bcb8d54a3196d325abe78dc4ae22 07-Jul-2015 Jan Nordqvist <jannq@google.com> am 07f11f6f: Reworked code to allow wildcard prefix IMSIs.

* commit '07f11f6f2ee7ec17cb08180035dfb5002aaaf5df':
Reworked code to allow wildcard prefix IMSIs.
299e2bf3b5e8a80747f39fad3def91b59cd9c399 07-Jul-2015 Jan Nordqvist <jannq@google.com> am 07f11f6f: Reworked code to allow wildcard prefix IMSIs.

* commit '07f11f6f2ee7ec17cb08180035dfb5002aaaf5df':
Reworked code to allow wildcard prefix IMSIs.
84649ea634d480be6bee19f155a1da5a4ec93e60 07-Jul-2015 Vinit Deshpande <vinitd@google.com> Add information in logs about lost wifi networks

We have multiple files of interest; this change dumps them
all if we lose networks.

Change-Id: Ie80085834b0dfe7d1c0480fdeac013e7293c6d2c
om/android/server/wifi/WifiConfigStore.java
07f11f6f2ee7ec17cb08180035dfb5002aaaf5df 18-Jun-2015 Jan Nordqvist <jannq@google.com> Reworked code to allow wildcard prefix IMSIs.

Change-Id: I08b7addb8dd407d9fc4f8a32a1fd2f86edde0e7a
om/android/server/wifi/ConfigurationMap.java
om/android/server/wifi/IMSIParameter.java
om/android/server/wifi/SIMAccessor.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/anqp/CellularNetwork.java
om/android/server/wifi/anqp/NAIRealmData.java
om/android/server/wifi/anqp/NAIRealmElement.java
om/android/server/wifi/anqp/eap/EAPMethod.java
om/android/server/wifi/configparse/ConfigBuilder.java
om/android/server/wifi/hotspot2/omadm/MOManager.java
om/android/server/wifi/hotspot2/pps/Credential.java
om/android/server/wifi/hotspot2/pps/HomeSP.java
e87a8da7bb513ca720b0160e3bff8c9f355faabb 20-Jun-2015 Fyodor Kupolov <fkupolov@google.com> Check location permission/appop in getScanResults

Return an empty list if the calling process has no location permission/appop

Bug: 21852542
Change-Id: I0811a497327451c6a1527a3d041eeb8b7e2c81a0
om/android/server/wifi/WifiServiceImpl.java
549b97948785dd9a51a4837fbe86a0b77410bb3b 02-Jul-2015 Pierre Vandwalle <vandwalle@google.com> am b9766f51: Merge changes I03899867,I225e875d into mnc-dev

* commit 'b9766f51bcbd50f178d2c20d61f3d631c699b836':
restart PNO/AutoJoinOffload when a network gets disabled Bug:22062116
add HS20 event strings to the WifiStateMachine logs
41efceef67f2b82908ffc4a4a44c37e5f865b0ca 02-Jul-2015 Vinit Deshpande <vinitd@google.com> am 7e6573a1: Dump multicast lock holders in bugreport

* commit '7e6573a1866812a302c1bfd224a2ed2d5633259f':
Dump multicast lock holders in bugreport
d47b132da465adebb4336329d287de1204d364fe 02-Jul-2015 Vinit Deshpande <vinitd@google.com> am f480e3b4: Merge "Use wifi_reset_log_handler to stop logging" into mnc-dev

* commit 'f480e3b42686d28eaf4b11474969875d65ac2023':
Use wifi_reset_log_handler to stop logging
231a96e57abf245ce558e19e32cc69e96dc0056b 02-Jul-2015 Vinit Deshpande <vinitd@google.com> am a07f06cc: Merge "Fixed bad check for Passpoint being enabled." into mnc-dev

* commit 'a07f06ccec5576e99e2c2c213ceb84cd1425e3fb':
Fixed bad check for Passpoint being enabled.
4b70fae9ca77ba69e5f64894e99b66e163d2496d 02-Jul-2015 Vinit Deshpande <vinitd@google.com> am c0d8226f: More API review feedback

* commit 'c0d8226ffa0e51c143271fead90dd3e8c6594d01':
More API review feedback
3d7490b9b4dadffb7d5e70736108d39db0cf504f 29-Jun-2015 Ravi Joshi <ravij@codeaurora.org> wifi: Fix softAP turn-ON issue in statically linked driver

SoftAP fails to turn-ON on some statically linked driver architectures
in which the interfaces are not available until firmware is reloaded
in the AP mode. The change provides the fix for this issue by loading
the firmware ahead of time to enable to driver to create wlan0 interface.

b/22236507

Change-Id: Icf13184df315c4be8b63024fafe772f0d9c8718b
om/android/server/wifi/WifiStateMachine.java
b9766f51bcbd50f178d2c20d61f3d631c699b836 01-Jul-2015 Pierre Vandwalle <vandwalle@google.com> Merge changes I03899867,I225e875d into mnc-dev

* changes:
restart PNO/AutoJoinOffload when a network gets disabled Bug:22062116
add HS20 event strings to the WifiStateMachine logs
7e6573a1866812a302c1bfd224a2ed2d5633259f 01-Jul-2015 Vinit Deshpande <vinitd@google.com> Dump multicast lock holders in bugreport

Change-Id: I8108b05e0728cfa468d36002c2a1fe578e537c34
om/android/server/wifi/WifiServiceImpl.java
f480e3b42686d28eaf4b11474969875d65ac2023 01-Jul-2015 Vinit Deshpande <vinitd@google.com> Merge "Use wifi_reset_log_handler to stop logging" into mnc-dev
a07f06ccec5576e99e2c2c213ceb84cd1425e3fb 01-Jul-2015 Vinit Deshpande <vinitd@google.com> Merge "Fixed bad check for Passpoint being enabled." into mnc-dev
c0d8226ffa0e51c143271fead90dd3e8c6594d01 30-Jun-2015 Vinit Deshpande <vinitd@google.com> More API review feedback

ScanResult now hides all flags and their values, only methods
are public; and converted roaming consortium to an array of longs
instead of Longs.

Bug: 22179306

Change-Id: I644110dbddd5fa7a7109ac16051845fcc4c4e9d1
om/android/server/wifi/ConfigurationMap.java
om/android/server/wifi/configparse/ConfigBuilder.java
1816209b3c52f1debacd275aec2148cd89ff3444 01-Jul-2015 Pierre Vandwalle <vandwalle@google.com> restart PNO/AutoJoinOffload when a network gets disabled
Bug:22062116

Change-Id: I03899867b1ecfa6985ad57e0ccba8c4e1c9aa5b6
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiStateMachine.java
b797893fc1966803d0c013faac42e6396a37a384 26-Jun-2015 xinhe <xinhe@google.com> Use wifi_reset_log_handler to stop logging

b/22098062

Change-Id: I6bc701ba81a9dad323403a39e3cb385153d2ed88
om/android/server/wifi/WifiLogger.java
om/android/server/wifi/WifiNative.java
35871a9e772c24d409518a3a92232afd590a1af3 30-Jun-2015 Zoltan Szatmary-Ban <szatmz@google.com> am 80270e91: Merge "Clear WiFi bitset variables before reading them from supplicant" into mnc-dev

* commit '80270e911b86a78f7512fed4ad1172c8034b7159':
Clear WiFi bitset variables before reading them from supplicant
80270e911b86a78f7512fed4ad1172c8034b7159 30-Jun-2015 Zoltan Szatmary-Ban <szatmz@google.com> Merge "Clear WiFi bitset variables before reading them from supplicant" into mnc-dev
9d83ed3f43eee232160fb9547338928ce0f8828b 30-Jun-2015 Erik Kline <ek@google.com> am b9084191: Merge "Prune unreachable DNS servers during makeLinkProperties()" into mnc-dev

* commit 'b908419110e3fce25632e27da1c577a345ec01fd':
Prune unreachable DNS servers during makeLinkProperties()
b908419110e3fce25632e27da1c577a345ec01fd 30-Jun-2015 Erik Kline <ek@google.com> Merge "Prune unreachable DNS servers during makeLinkProperties()" into mnc-dev
83e653cbdcb944038927e4c25837895626354e61 26-Jun-2015 Jan Nordqvist <jannq@google.com> Fixed bad check for Passpoint being enabled.

Bug: 21170278
Change-Id: Id4bee1851ace4673688bc0087e9c4fe40f66c25f
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/hotspot2/omadm/MOManager.java
a32bb77d2edbaafe2c76f1f1723d595900e76c09 30-Jun-2015 Vinit Deshpande <vinitd@google.com> am 48cf05de: Merge "Fix potential system crash beacuse of bad Wifi parsing" into mnc-dev

* commit '48cf05de203ced8a11aebe38da58c48ea9952082':
Fix potential system crash beacuse of bad Wifi parsing
48cf05de203ced8a11aebe38da58c48ea9952082 30-Jun-2015 Vinit Deshpande <vinitd@google.com> Merge "Fix potential system crash beacuse of bad Wifi parsing" into mnc-dev
36c1dce4cc0a26b456a17becb7b0745f533d2b58 30-Jun-2015 Pierre Vandwalle <vandwalle@google.com> add HS20 event strings to the WifiStateMachine logs

Change-Id: I225e875dce6b63df872f32c7b0525560f65e4027
om/android/server/wifi/WifiStateMachine.java
2ecfc4b85ef5db62228e69e96a289545c3471a81 29-Jun-2015 Pierre Vandwalle <vandwalle@google.com> am 2a4b11b8: Merge "print kernel time for all messages" into mnc-dev

* commit '2a4b11b86792fc9092daf0f685d29820ee44ea19':
print kernel time for all messages
fb80c4e9859161ba3492b79f485b9e554177c8c1 29-Jun-2015 Vinit Deshpande <vinitd@google.com> Fix potential system crash beacuse of bad Wifi parsing

WifiMonitor may throw an exception on some malformed events
taking the entire system down. This change gauards against
such crash.

Bug: 17698782
Change-Id: Ib855419c5ed24ec174889185c4d0b450403778de
om/android/server/wifi/WifiMonitor.java
2a4b11b86792fc9092daf0f685d29820ee44ea19 29-Jun-2015 Pierre Vandwalle <vandwalle@google.com> Merge "print kernel time for all messages" into mnc-dev
f4c48cbf965d334f319393707b59c6a19149a87c 29-Jun-2015 Erik Kline <ek@google.com> Prune unreachable DNS servers during makeLinkProperties()

Bug: 20733156
Change-Id: Idc61376f25d7b51e2a649f3bc1d8a229cb4a7f95
om/android/server/wifi/WifiStateMachine.java
c589b79dbf7c22e7eb92109551267451fbf8841a 27-Jun-2015 Vinit Deshpande <vinitd@google.com> am a9d408b2: Merge "Re-enable Driver/Firmware based logs" into mnc-dev

* commit 'a9d408b279235dc1f5f8dbf513ae932d56e2c0e9':
Re-enable Driver/Firmware based logs
a9d408b279235dc1f5f8dbf513ae932d56e2c0e9 27-Jun-2015 Vinit Deshpande <vinitd@google.com> Merge "Re-enable Driver/Firmware based logs" into mnc-dev
03d6b9c9942adba095f90c547a8e5a19cd5bebdb 27-Jun-2015 Shirish Kalele <kalele@google.com> am 1efb8a06: Merge "Surface ephemeralness of connection in WifiInfo." into mnc-dev

* commit '1efb8a06775f612c57603a8107ffe87f0ae90b29':
Surface ephemeralness of connection in WifiInfo.
1efb8a06775f612c57603a8107ffe87f0ae90b29 26-Jun-2015 Shirish Kalele <kalele@google.com> Merge "Surface ephemeralness of connection in WifiInfo." into mnc-dev
473b3bc83b29d6ded68e57e28b66a426903a24eb 26-Jun-2015 Pierre Vandwalle <vandwalle@google.com> print kernel time for all messages

Change-Id: Ibae85a2d182b7d7d7246956d0f96afcbc477eaf6
om/android/server/wifi/WifiStateMachine.java
6414301b7b685307e8ae8cea6976ed05cc49b254 25-Jun-2015 Vinit Deshpande <vinitd@google.com> Re-enable Driver/Firmware based logs

Change-Id: If2c929a1156d936ac1a17681d1f171ae1f9dd1bf
om/android/server/wifi/WifiLogger.java
om/android/server/wifi/WifiNative.java
86b1b52530bba4a35e81bd7c5d7d52139fa0c822 25-Jun-2015 Shirish Kalele <kalele@google.com> Surface ephemeralness of connection in WifiInfo.

Bug: 21960219
Change-Id: I3d63633fcb30785328d030660951f9e96f0e53ad
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiStateMachine.java
0fc0c775fb6a493569d51b30020246e9efc000d0 25-Jun-2015 Amarnath Hullur Subramanyam <amarnath@codeaurora.org> am 87e2455e: Wifi: Exit the monitor thread when killSupplicant is issued.

* commit '87e2455ee2a232db01029a93edea179528d1a5c2':
Wifi: Exit the monitor thread when killSupplicant is issued.
c7198df99b1b0176715911de51f5ce76bd446f7f 25-Jun-2015 xin He <xinhe@google.com> am 73375507: Merge "wifi : Fix for Wi-Fi grayed out issue" into mnc-dev

* commit '733755071170d0918ecb856481525b274a75d3e0':
wifi : Fix for Wi-Fi grayed out issue
87e2455ee2a232db01029a93edea179528d1a5c2 09-Jun-2015 Amarnath Hullur Subramanyam <amarnath@codeaurora.org> Wifi: Exit the monitor thread when killSupplicant is issued.

When Wifi is turned off, WifiStateMachine issues terminate command
to the supplicant and waits for the event CTRL-EVENT-TERMINATING.
On receiving this TERMINTING event, WifiMonitor stops further monitoring
of events. In some instances, WifiMonitor fails to receive the event
CTRL-EVENT-TERMINATING and subsequently when Wifi framework times out it
kills the supplicant.
But this recovery logic has an issue where even though the supplicant is
killed, the monitor thread is not stopped from listening the events and
WifiMonitor continues looking for the events. Since at the time of killing
the supplicant monitor_conn is initialized to NULL, internally fabricated
WPA_EVENT_TERMINATING event is issued by the framework. This again leads
to the deinitialization of the wlan0 / p2p0 interfaces while the process
of initialization is in progress. This leads to concurrent actions of
supplicant connection closure and command execution on the control socket.
But wpa control interface library is not designed to concurrently handle
activities on the control and monitor sockets.
To solve this issue, exit the monitor thread when Wifi framework kills
the supplicant explicitly (mConnected is set to FALSE).

b/21899315

Change-Id: Ie22447d5ce73fb0a22da309cca69a620f1974368
om/android/server/wifi/WifiMonitor.java
733755071170d0918ecb856481525b274a75d3e0 25-Jun-2015 xin He <xinhe@google.com> Merge "wifi : Fix for Wi-Fi grayed out issue" into mnc-dev
6ae1a88c51b9db16ce82b4f4752cca54e961be51 05-Jun-2015 Sunil Dutt <usdutt@codeaurora.org> wifi : Fix for Wi-Fi grayed out issue

During the initialization, WiFiMonitor shall try to open the
control/monitor socket interface with the supplicant.On a
failed attempt to open the control interface, WiFiMonitor
thread shall trigger an event SUP_DISCONNECTION_EVENT to
WiFiStateMachine with the expectation that the connection
attempt restarts.In addition,it also removes the interface
from the mIfaceMap.During the restart,WiFiMonitor does not
proceed to open the control interface with the supplicant
if the mIfaceMap does not point to the interface. Thus,do
not remove the interface from mIfaceMap on a failed attempt
to create a control interface with the supplicant to
provision a reinitialization attempt.

b/18798914
Change-Id: Iefb8942a7561699557ea21cb87f4754da024139a
om/android/server/wifi/WifiMonitor.java
725004d112bb6fb87888f28098abae6b4ba7c9e0 24-Jun-2015 Jeremy Joslin <jjoslin@google.com> am 78638d80: Merge "Protect from NPEs." into mnc-dev

* commit '78638d80490e95beb62f46f47f9c98d357830064':
Protect from NPEs.
78638d80490e95beb62f46f47f9c98d357830064 24-Jun-2015 Jeremy Joslin <jjoslin@google.com> Merge "Protect from NPEs." into mnc-dev
9a24f0203bcf9a19419cc00294275449c87dacde 24-Jun-2015 Pierre Vandwalle <vandwalle@google.com> am 36375b66: Merge "prevent calling WifiNEtworkScoreCache.java with null scan result Bug:21957885" into mnc-dev

* commit '36375b663fcb5d3deb0119359b03623717d933aa':
prevent calling WifiNEtworkScoreCache.java with null scan result Bug:21957885
127a2b56e232b7c4f378160a18501113c5fdca11 24-Jun-2015 Jan Nordqvist <jannq@google.com> am 903814ca: Merge "Fixed ArrayIndexOutOfBounds and some more sanity in NetworkDetail." into mnc-dev

* commit '903814ca886b4a090816216d5e8464b65b0121c9':
Fixed ArrayIndexOutOfBounds and some more sanity in NetworkDetail.
36375b663fcb5d3deb0119359b03623717d933aa 24-Jun-2015 Pierre Vandwalle <vandwalle@google.com> Merge "prevent calling WifiNEtworkScoreCache.java with null scan result Bug:21957885" into mnc-dev
903814ca886b4a090816216d5e8464b65b0121c9 24-Jun-2015 Jan Nordqvist <jannq@google.com> Merge "Fixed ArrayIndexOutOfBounds and some more sanity in NetworkDetail." into mnc-dev
be24c9af85b8a6e02b24582418a4608e14396f2a 23-Jun-2015 Jan Nordqvist <jannq@google.com> Fixed ArrayIndexOutOfBounds and some more sanity in NetworkDetail.

Bug: 20304261
Change-Id: I4951b5274d148b1c4848363f915d278fbaa1f7c9
om/android/server/wifi/hotspot2/NetworkDetail.java
be4d4bfef88bb0870e1e8bb464c302a2e54bbed4 23-Jun-2015 Pierre Vandwalle <vandwalle@google.com> prevent calling WifiNEtworkScoreCache.java with null scan result
Bug:21957885

Change-Id: I94039a4f0dd87249a4a431aa3f7c7769713843f4
om/android/server/wifi/WifiAutoJoinController.java
086e68a257abf43dc999433b4de00cd896c06d3a 23-Jun-2015 Jeremy Joslin <jjoslin@google.com> Protect from NPEs.

Protect against possible NPEs in both buildNetworkKey() methods.

BUG:21957885
Change-Id: I6e1ab7ec0d67432470addc29aab3c68cbe005920
om/android/server/wifi/WifiNetworkScoreCache.java
2a76a286cdb57e0ed4f2e7c87b55b3bc1a2294c9 23-Jun-2015 Zoltan Szatmary-Ban <szatmz@google.com> am b724ba81: Merge "Respect all factors in determining editability of a WiFi config" into mnc-dev

* commit 'b724ba818fa8ba5c2887de16250ff46193b0d9ea':
Respect all factors in determining editability of a WiFi config
b724ba818fa8ba5c2887de16250ff46193b0d9ea 23-Jun-2015 Zoltan Szatmary-Ban <szatmz@google.com> Merge "Respect all factors in determining editability of a WiFi config" into mnc-dev
ef5ca2b857f2661c7567a8d91676541f02ee9c8b 23-Jun-2015 Vinit Deshpande <vinitd@google.com> am cd08c5da: Merge "Address API review comments" into mnc-dev

* commit 'cd08c5daab08121d7f4ffc211ce477a412247bc4':
Address API review comments
72ef16c25571a764fa62adabade6f30501fc6497 23-Jun-2015 Vinit Deshpande <vinitd@google.com> am ea6ffb26: Merge "am 364f83d..034205e from mirror-m-wireless-internal-release" into mnc-dev

* commit 'ea6ffb2628c850ab1ef524a10069b9aa6f9798be':
Added config_wifi_hotspot2_enabled.
dont optimize the pno set/clear commands since framework and driver can get out of sync Bug:21734054
add creation/update time to WifiConfiguration fix carry over of validatedInternetAccess Bug:21390908
make sure ephemeral config are written to file Bug:21293078
Support 32 channels from different band per bucket for scanning
Separated auth checking from SP matching.
call setWifiLinkLayerStats Bug:21617639
Missing final keyword.
ANQP cache sweeping.
make sure validatedInternetAccess boolean is written to disk right away Bug:21390908
dont keep bad link score due to txerrors for too long
cd08c5daab08121d7f4ffc211ce477a412247bc4 23-Jun-2015 Vinit Deshpande <vinitd@google.com> Merge "Address API review comments" into mnc-dev
b4ece4e093647267e9b57a5eee2754fa0fc6ae09 23-Jun-2015 Vinit Deshpande <vinitd@google.com> am 364f83d..034205e from mirror-m-wireless-internal-release

034205e Added config_wifi_hotspot2_enabled.
883e4cb Merge "dont optimize the pno set/clear commands since framework and driver can get out of sync Bug:21734054" into m-wireless-dev
2f1c1c7 dont optimize the pno set/clear commands since framework and driver can get out of sync Bug:21734054
d565262 add creation/update time to WifiConfiguration fix carry over of validatedInternetAccess Bug:21390908
40c87db Merge "Support 32 channels from different band per bucket for scanning" into m-wireless-dev
7ee84d8 make sure ephemeral config are written to file Bug:21293078
28fc233 Support 32 channels from different band per bucket for scanning
3baa176 Separated auth checking from SP matching.
486cc89 call setWifiLinkLayerStats Bug:21617639
7a94f84 Missing final keyword.
c465290 ANQP cache sweeping.
890e70d make sure validatedInternetAccess boolean is written to disk right away Bug:21390908

Change-Id: Ibacd79799465f11bd82311391f7a9420e0c50927
cf4fb0f23e3c734832f198400ef51866a3a831a3 22-Jun-2015 Vinit Deshpande <vinitd@google.com> am 5103e301: Merge "Support 32 channels from different band per bucket for scanning" into mnc-dev

* commit '5103e301c3aa2cbfe19d73a22f5ab4d8f548ff3a':
Support 32 channels from different band per bucket for scanning
5103e301c3aa2cbfe19d73a22f5ab4d8f548ff3a 22-Jun-2015 Vinit Deshpande <vinitd@google.com> Merge "Support 32 channels from different band per bucket for scanning" into mnc-dev
554a689e9e2490759c66c7963e26919cab80cc5b 22-Jun-2015 xinhe <xinhe@google.com> am 83c06fcc: Merge "fix SoftAP start failure on deb device" into mnc-dev

* commit '83c06fccd3bb8f3ac748aeee7b774d601f6f54e0':
fix SoftAP start failure on deb device
83c06fccd3bb8f3ac748aeee7b774d601f6f54e0 22-Jun-2015 xinhe <xinhe@google.com> Merge "fix SoftAP start failure on deb device" into mnc-dev
71d0be16c79791a005d60f9d5fa7d2d81e1f8c80 19-Jun-2015 xinhe <xinhe@google.com> fix SoftAP start failure on deb device

This is due to there is no HAL for razor and start softAp
codes need HAL API support

b/21869900
Change-Id: Ibd82dede184dc2fc80aa26961014dc68d837eff8
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
d9f37b2f3df18e96246db93ec4c2a5159b5d3915 13-Jun-2015 Vinit Deshpande <vinitd@google.com> Address API review comments

Added a flags field in ScanResult; along with flag
values and methods to read them.

Changed types of passpoint related fields.

Bug: 21342042

Change-Id: I413960de88b387853d11b9e10f92665e9c06a81b
om/android/server/wifi/ConfigurationMap.java
om/android/server/wifi/ScanDetail.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiScanningServiceImpl.java
om/android/server/wifi/configparse/ConfigBuilder.java
0c853aed098cbdb79694b71b855e99ab150f190b 19-Jun-2015 Pierre Vandwalle <vandwalle@google.com> am 365f5e3b: Merge "make PNO autojoin retries exponential, use elapsedTime instead of upTime for aging out networks Bug:21856344" into mnc-dev

* commit '365f5e3b7221137391949391bde8401e117a0923':
make PNO autojoin retries exponential, use elapsedTime instead of upTime for aging out networks Bug:21856344
365f5e3b7221137391949391bde8401e117a0923 19-Jun-2015 Pierre Vandwalle <vandwalle@google.com> Merge "make PNO autojoin retries exponential, use elapsedTime instead of upTime for aging out networks Bug:21856344" into mnc-dev
7b828c866a69440f6786f4c462ff8b775006a9fa 19-Jun-2015 Adam Lesinski <adamlesinski@google.com> am bbb9dfd2: Merge "Don\'t report internal UIDs to BatteryStats" into mnc-dev

* commit 'bbb9dfd2f4382665d245052693c82a6e0126415f':
Don't report internal UIDs to BatteryStats
5fa961aa35447d2747fb414ad06b701db8e55249 19-Jun-2015 Pierre Vandwalle <vandwalle@google.com> am d9dcc7c6: reload the wifi config when autoconnecting, after updating the config Bug:20299767

* commit 'd9dcc7c6d03a0d93c50bada805ad4047aab8642a':
reload the wifi config when autoconnecting, after updating the config Bug:20299767
cb59612d2af82044ee74e8f595c9a40498db14b4 19-Jun-2015 Pierre Vandwalle <vandwalle@google.com> make PNO autojoin retries exponential, use elapsedTime instead of upTime for aging out networks
Bug:21856344

Change-Id: I99ed09467aba757eb09ceb8e0fe8eaff3fbf5e67
om/android/server/wifi/ScanDetailCache.java
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiStateMachine.java
bbb9dfd2f4382665d245052693c82a6e0126415f 19-Jun-2015 Adam Lesinski <adamlesinski@google.com> Merge "Don't report internal UIDs to BatteryStats" into mnc-dev
d9dcc7c6d03a0d93c50bada805ad4047aab8642a 19-Jun-2015 Pierre Vandwalle <vandwalle@google.com> reload the wifi config when autoconnecting, after updating the config
Bug:20299767

Change-Id: I41f60c1c91778570d63262c608052eb57e99e3d0
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiStateMachine.java
fa67e84b51c4e7f334162f06393dc5b767c340a1 19-Jun-2015 Pierre Vandwalle <vandwalle@google.com> am b9795564: Merge "use the scan result timestamp for aging out networks Bug:21936726" into mnc-dev

* commit 'b9795564613a68ede0c590e9637aad68695e320b':
use the scan result timestamp for aging out networks Bug:21936726
b48af9d5884f7f52f25ca1e14ae5f26037399c9c 19-Jun-2015 Pierre Vandwalle <vandwalle@google.com> am 805243ea: Merge " retry autojoin to pno network after a minute Bug:21740448" into mnc-dev

* commit '805243ea08f55f415d70038f7e0bd1d3a45c1c18':
retry autojoin to pno network after a minute Bug:21740448
1a86f1f7c11aaa9070a356ed2606c2a5d8d19adb 27-May-2015 Zoltan Szatmary-Ban <szatmz@google.com> Respect all factors in determining editability of a WiFi config

Also, use creatorUid instead of lastUpdateName in determining
modifiability of config.

Bug: 21427528
Bug: 21150087
Bug: 21612565
Bug: 21887465
Change-Id: I0f8fb72bf9da1597e08d3dfc631d37b6b4178ff5
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiStateMachine.java
b9795564613a68ede0c590e9637aad68695e320b 19-Jun-2015 Pierre Vandwalle <vandwalle@google.com> Merge "use the scan result timestamp for aging out networks Bug:21936726" into mnc-dev
e3e4fad6e9b2022018a33507e93a39c6446f9916 19-Jun-2015 Pierre Vandwalle <vandwalle@google.com> use the scan result timestamp for aging out networks
Bug:21936726

Change-Id: Icfbae91053663fc7a2ad26a649e2764f5cd5b884
om/android/server/wifi/ScanDetailCache.java
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiStateMachine.java
f0dacfe3c7f894166e87c8a90ef0a645cebc8996 19-Jun-2015 Adam Lesinski <adamlesinski@google.com> Don't report internal UIDs to BatteryStats

Wifi uses special UIDs in the WorkSource for scanning operations
done on its own accord. BatteryStats has no idea what these are,
so just report the WIFI UID when these special UIDs are encountered.

Bug:21929283
Change-Id: Icd81ae0fec049da1f0cdf0a552aae124212af6f1
om/android/server/wifi/WifiStateMachine.java
805243ea08f55f415d70038f7e0bd1d3a45c1c18 19-Jun-2015 Pierre Vandwalle <vandwalle@google.com> Merge " retry autojoin to pno network after a minute Bug:21740448" into mnc-dev
0510c350db16f6bd2930f0a5ace483efbfa681d5 18-Jun-2015 Pierre Vandwalle <vandwalle@google.com> retry autojoin to pno network after a minute
Bug:21740448

Change-Id: I50b91da5f7fb23f5e3366c7e7b79811c89314f72
om/android/server/wifi/ScanDetail.java
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiStateMachine.java
6471778905e0b92bd7a20d8a82e51c307dd0b96f 13-Jun-2015 Navtej Singh Mann <navtejsingh@google.com> Support 32 channels from different band per bucket for scanning


cherry pick: https://partner-android-review.googlesource.com/#/c/215470/

Change-Id: I773621f87b3544bbf5fc30b47d9b88811339ce11
om/android/server/wifi/WifiScanningServiceImpl.java
034205ec8ee3d608546ab9327fb650d9a259efad 12-Jun-2015 Jan Nordqvist <jannq@google.com> Added config_wifi_hotspot2_enabled.

Change-Id: I9c48f9ab9698c167b29af887015442e739af4997
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/hotspot2/omadm/MOManager.java
fdb4e3e460b501148032546ccb8ad633af71faea 18-Jun-2015 Zoltan Szatmary-Ban <szatmz@google.com> Clear WiFi bitset variables before reading them from supplicant

Otherwise if the config that is being filled in may have some bits
already set.
Also refactored repetitive code.

Bug: 21152481
Change-Id: I3506c4b2472577dd355e94d40783c2c1dd31dc98
om/android/server/wifi/WifiConfigStore.java
2f42fca3b01d6379c487379acfe7f3005978cc74 18-Jun-2015 Zoltan Szatmary-Ban <szatmz@google.com> am a233de4a: Make WiFi network history be actually read

* commit 'a233de4a7978d98b515a6c7c27a45b6b55bde5aa':
Make WiFi network history be actually read
a233de4a7978d98b515a6c7c27a45b6b55bde5aa 12-Jun-2015 Zoltan Szatmary-Ban <szatmz@google.com> Make WiFi network history be actually read

Reintroduced mistakenly removed line in WifiConfigStore.readNetworkHistory
which prevented any of the network history being read from file.

Bug: 20846840
Change-Id: Id98404bd40d48b8ee0fce6f668334460348fb495
om/android/server/wifi/WifiConfigStore.java
e7721a15949929558a02e577041295b536222d9f 18-Jun-2015 Pierre Vandwalle <vandwalle@google.com> am c97b98d6: dont optimize the pno set/clear commands since framework and driver can get out of sync Bug:21734054

* commit 'c97b98d6877f6603a6a0eee820576f59e7da5e52':
dont optimize the pno set/clear commands since framework and driver can get out of sync Bug:21734054
c97b98d6877f6603a6a0eee820576f59e7da5e52 18-Jun-2015 Pierre Vandwalle <vandwalle@google.com> dont optimize the pno set/clear commands since framework and driver can get out of sync
Bug:21734054

Change-Id: Ib9646bb871a6cccba6cf77715d7c47b3e0b4b9c1
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
883e4cbb86a7970c568268e254aa2a246c6d12e0 18-Jun-2015 Pierre Vandwalle <vandwalle@google.com> Merge "dont optimize the pno set/clear commands since framework and driver can get out of sync Bug:21734054" into m-wireless-dev
2f1c1c7fec9ebc2ca73c05a479a7669bcc922cf3 18-Jun-2015 Pierre Vandwalle <vandwalle@google.com> dont optimize the pno set/clear commands since framework and driver can get out of sync
Bug:21734054

Change-Id: Ib9646bb871a6cccba6cf77715d7c47b3e0b4b9c1
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
0d607e8c0044f1a2843cc8895a8411611e13f6e7 17-Jun-2015 Jan Nordqvist <jannq@google.com> am 866c5b06: Separated auth checking from SP matching.

* commit '866c5b061e6e762f2627e3467afc0fe6f29c2668':
Separated auth checking from SP matching.
0f6465d58efb630a7ed121f102d56d41e45a9b69 17-Jun-2015 Pierre Vandwalle <vandwalle@google.com> am e63336e9: add creation/update time to WifiConfiguration fix carry over of validatedInternetAccess Bug:21390908

* commit 'e63336e926e60ba9b0cf0702be9bec2718de27d8':
add creation/update time to WifiConfiguration fix carry over of validatedInternetAccess Bug:21390908
866c5b061e6e762f2627e3467afc0fe6f29c2668 12-Jun-2015 Jan Nordqvist <jannq@google.com> Separated auth checking from SP matching.

Bug: 21729565

Change-Id: Ia0617efaf32f4dc9dddc6059322265520f2d5c3a
om/android/server/wifi/ScanDetail.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/anqp/NAIRealmData.java
om/android/server/wifi/anqp/NAIRealmElement.java
om/android/server/wifi/anqp/eap/EAPMethod.java
om/android/server/wifi/hotspot2/AuthMatch.java
om/android/server/wifi/hotspot2/NetworkDetail.java
om/android/server/wifi/hotspot2/pps/HomeSP.java
e63336e926e60ba9b0cf0702be9bec2718de27d8 16-Jun-2015 Pierre Vandwalle <vandwalle@google.com> add creation/update time to WifiConfiguration
fix carry over of validatedInternetAccess
Bug:21390908

Change-Id: I723f4fd740959b2d4f9898846897e37734b2a438
om/android/server/wifi/WifiConfigStore.java
f2a15dbb8e30adb48d77acbb4099e5e9e9622bca 17-Jun-2015 Pierre Vandwalle <vandwalle@google.com> am fb650bfb: make sure ephemeral config are written to file Bug:21293078

* commit 'fb650bfb264b7ff31c927498faf8343b5895c6ab':
make sure ephemeral config are written to file Bug:21293078
cc8d5c1e8e89f36b5b11a5267c457f035b12d6a0 17-Jun-2015 Pierre Vandwalle <vandwalle@google.com> am d745a52d: call setWifiLinkLayerStats Bug:21617639

* commit 'd745a52dc4f929d4a4030f205ed173bdf60eaf10':
call setWifiLinkLayerStats Bug:21617639
39cff8f958e57fb76ff9cff48dae2269c38d87d7 17-Jun-2015 Pierre Vandwalle <vandwalle@google.com> am 39ca3a2f: make sure validatedInternetAccess boolean is written to disk right away Bug:21390908

* commit '39ca3a2fff1e2f7dd8613b094984199b95931671':
make sure validatedInternetAccess boolean is written to disk right away Bug:21390908
fb650bfb264b7ff31c927498faf8343b5895c6ab 12-Jun-2015 Pierre Vandwalle <vandwalle@google.com> make sure ephemeral config are written to file
Bug:21293078

Change-Id: I84346d1a8d766205be57e5e624614a70511f7862
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
d745a52dc4f929d4a4030f205ed173bdf60eaf10 12-Jun-2015 Pierre Vandwalle <vandwalle@google.com> call setWifiLinkLayerStats
Bug:21617639

Change-Id: Idf7d066a20b96ed1e39cdd164b7159d5843c2f99
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
2372d51a055daebbefffcc0b52b77d7da27ac77b 17-Jun-2015 Pierre Vandwalle <vandwalle@google.com> am b53a183e: dont keep bad link score due to txerrors for too long

* commit 'b53a183e0284025e11b4304c50d18c3f80f66e85':
dont keep bad link score due to txerrors for too long
39ca3a2fff1e2f7dd8613b094984199b95931671 11-Jun-2015 Pierre Vandwalle <vandwalle@google.com> make sure validatedInternetAccess boolean is written to disk right away
Bug:21390908

Change-Id: Ia64068bccb84973aac6c26de96c074ffc6f4fae4
om/android/server/wifi/WifiStateMachine.java
b53a183e0284025e11b4304c50d18c3f80f66e85 10-Jun-2015 Pierre Vandwalle <vandwalle@google.com> dont keep bad link score due to txerrors for too long

Change-Id: I181eabc72ca93d29470d46017e9f34df2e71093e
om/android/server/wifi/WifiStateMachine.java
d565262c07df6c7cf58a6f800c77a596ae0e4610 16-Jun-2015 Pierre Vandwalle <vandwalle@google.com> add creation/update time to WifiConfiguration
fix carry over of validatedInternetAccess
Bug:21390908

Change-Id: I723f4fd740959b2d4f9898846897e37734b2a438
om/android/server/wifi/WifiConfigStore.java
63951e369140dbb51d7133499b6c3ac933d377ed 16-Jun-2015 Adam Lesinski <adamlesinski@google.com> am dbfd22cb: Merge "Wifi energy: Use longs for energy calculations" into mnc-dev

* commit 'dbfd22cbc43f79707b8b1844087e31be5900d95f':
Wifi energy: Use longs for energy calculations
dbfd22cbc43f79707b8b1844087e31be5900d95f 16-Jun-2015 Adam Lesinski <adamlesinski@google.com> Merge "Wifi energy: Use longs for energy calculations" into mnc-dev
94a2dd090b7d3823058b7a69cf4653d5663708cd 16-Jun-2015 Adam Lesinski <adamlesinski@google.com> Wifi energy: Use longs for energy calculations

The framework is now using longs to store energy data, so update the code
to do the same.

Change-Id: Ia01d9c13240c9644efcea93b370eca20890964c2
om/android/server/wifi/WifiServiceImpl.java
1588b44785cffb4668565c149af3b705e4d53582 15-Jun-2015 Chris Wren <cwren@android.com> am c0a37e1f: Merge "remove setLatestEventInfo from wifi" into mnc-dev

* commit 'c0a37e1f482f3f42c4f87e0571f28b084ffc7aa9':
remove setLatestEventInfo from wifi
c0a37e1f482f3f42c4f87e0571f28b084ffc7aa9 15-Jun-2015 Chris Wren <cwren@android.com> Merge "remove setLatestEventInfo from wifi" into mnc-dev
40c87dbd7fb69deb32073dd6f9f773053884b0b2 13-Jun-2015 Vinit Deshpande <vinitd@google.com> Merge "Support 32 channels from different band per bucket for scanning" into m-wireless-dev
280c723256c0c4920b98cec32a3ccc3739bf6c7a 13-Jun-2015 Vinit Deshpande <vinitd@google.com> am a1276378: Ensure FW version in bugreport

* commit 'a1276378c5a215774193e745568d6dec0d19a722':
Ensure FW version in bugreport
7ee84d83c86794ad2330563565119d5e31f88891 12-Jun-2015 Pierre Vandwalle <vandwalle@google.com> make sure ephemeral config are written to file
Bug:21293078

Change-Id: I84346d1a8d766205be57e5e624614a70511f7862
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
28fc233963eb95abc077e0aab4fda7d259873ae2 13-Jun-2015 Navtej Singh Mann <navtejsingh@google.com> Support 32 channels from different band per bucket for scanning

Change-Id: I773621f87b3544bbf5fc30b47d9b88811339ce11
om/android/server/wifi/WifiScanningServiceImpl.java
3baa1769b394a44351228f1b6950706d56fe61fa 12-Jun-2015 Jan Nordqvist <jannq@google.com> Separated auth checking from SP matching.

Bug: 21729565

Change-Id: Ia0617efaf32f4dc9dddc6059322265520f2d5c3a
om/android/server/wifi/ScanDetail.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/anqp/NAIRealmData.java
om/android/server/wifi/anqp/NAIRealmElement.java
om/android/server/wifi/anqp/eap/EAPMethod.java
om/android/server/wifi/hotspot2/AuthMatch.java
om/android/server/wifi/hotspot2/NetworkDetail.java
om/android/server/wifi/hotspot2/pps/HomeSP.java
a1276378c5a215774193e745568d6dec0d19a722 10-Jun-2015 Vinit Deshpande <vinitd@google.com> Ensure FW version in bugreport

Change-Id: I851b92a77abe647ed904ed4d55dddfdc0dfff366
om/android/server/wifi/WifiLogger.java
486cc89df3277ce7c7ace55fdfd02ae24ce0d665 12-Jun-2015 Pierre Vandwalle <vandwalle@google.com> call setWifiLinkLayerStats
Bug:21617639

Change-Id: Idf7d066a20b96ed1e39cdd164b7159d5843c2f99
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
7a94f84d2c4c7c34baaba9b87d9565f74b1eebfd 12-Jun-2015 Jan Nordqvist <jannq@google.com> Missing final keyword.

Change-Id: I3fb18c8e0a48283ce4f645db3fea98f5635548c0
om/android/server/wifi/configparse/ConfigBuilder.java
c465290772b735d97cba451c9bc5b6cc76db9147 11-Jun-2015 Jan Nordqvist <jannq@google.com> ANQP cache sweeping.

Bug: 21786417

Change-Id: I44b44dd09c00364b0dc7d21640d5e803ffa6263c
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/hotspot2/AnqpCache.java
290efe67c9f4836f99fc8471c044b79ca1764471 12-Jun-2015 Vinit Deshpande <vinitd@google.com> am 656fad7e: Merge "Disable long running chronograph thread" into mnc-dev

* commit '656fad7edc1c850ad6b092789067d0a742ee158d':
Disable long running chronograph thread
656fad7edc1c850ad6b092789067d0a742ee158d 11-Jun-2015 Vinit Deshpande <vinitd@google.com> Merge "Disable long running chronograph thread" into mnc-dev
bf5f728c6dd10bcdfb184339c3471ffae43b2e5e 11-Jun-2015 Vinit Deshpande <vinitd@google.com> Disable long running chronograph thread

Bug: 21781020
Change-Id: Ia9ad08faf18fd890ee6ce63c83a45938dd7a0a47
om/android/server/wifi/WifiConfigStore.java
2247009c2527c80e7fb00f056aea67d1fe09671b 11-Jun-2015 Chris Wren <cwren@android.com> remove setLatestEventInfo from wifi

Bug: 18510449
Change-Id: I155caaf80d90b15b1a1ee1cc71819358edb4c604
om/android/server/wifi/WifiNotificationController.java
d9db3540d213cef5855c6b9154cb8d4abc6a97e2 11-Jun-2015 Prerepa Viswanadham <dham@google.com> am a6777abf: Don\'t log PSK or password in to bugreport

* commit 'a6777abfc90496801e9942f57fbfa091ba85ae82':
Don't log PSK or password in to bugreport
890e70d78c91e884b00da947cb14841d3186ad90 11-Jun-2015 Pierre Vandwalle <vandwalle@google.com> make sure validatedInternetAccess boolean is written to disk right away
Bug:21390908

Change-Id: Ia64068bccb84973aac6c26de96c074ffc6f4fae4
om/android/server/wifi/WifiStateMachine.java
ad08f977f8dbe97bb7d6b65759979be37fd420d6 11-Jun-2015 Vinit Deshpande <vinitd@google.com> am 35287503: am 05d1550..05d1550 from mirror-m-wireless-internal-release

* commit '352875034165d338738ded4b7b1f1d997e413262':
Dont enable legacy pno if state is not Disconnected or scan is ongoing Bug:21368736
a6777abfc90496801e9942f57fbfa091ba85ae82 11-Jun-2015 Prerepa Viswanadham <dham@google.com> Don't log PSK or password in to bugreport

Bug: 21576757
Change-Id: If74ece7cc541075bee46cf8b80765bd0ac2d367c
om/android/server/wifi/WifiNative.java
77faab4be7695e6adddc1e1e5589ded2e4333fdc 10-Jun-2015 Kyle Wang <kylew@nvidia.com> am 5f63208a: fix the false wifi \'CONNECTED\' broadcast

* commit '5f63208a36a89c83c265efac5391a1ecbeccdf92':
fix the false wifi 'CONNECTED' broadcast
364f83d061817e3632e8259da47a6c39500947b8 10-Jun-2015 Pierre Vandwalle <vandwalle@google.com> dont keep bad link score due to txerrors for too long

Change-Id: I181eabc72ca93d29470d46017e9f34df2e71093e
om/android/server/wifi/WifiStateMachine.java
352875034165d338738ded4b7b1f1d997e413262 10-Jun-2015 Vinit Deshpande <vinitd@google.com> am 05d1550..05d1550 from mirror-m-wireless-internal-release

05d1550 Dont enable legacy pno if state is not Disconnected or scan is ongoing Bug:21368736
5f63208a36a89c83c265efac5391a1ecbeccdf92 04-Jun-2015 Kyle Wang <kylew@nvidia.com> fix the false wifi 'CONNECTED' broadcast

WifiStatemachine should use 'WifiSsid.NONE' instead of 'null' to judge the return
value of WifiInfo#getSSID() which will never be 'null'. Otherwise it will send a
false 'CONNECTED' broadcast first then 'DISCONNECTED' broadcast when we disable
wifi from System Setting GUI.

Change-Id: I9682a69cc3acad1a90d1b4fe96d53d3a28cf8277
om/android/server/wifi/WifiStateMachine.java
05d155034b789d0bcc73deefb29ab6db90e57ddf 09-Jun-2015 Pierre Vandwalle <vandwalle@google.com> Dont enable legacy pno if state is not Disconnected or scan is ongoing
Bug:21368736

Change-Id: I5b87e77b814cda0c1202d647e6ceb2d2e706f223
om/android/server/wifi/WifiStateMachine.java
ba5908f65b0470be02ec7b5c035a3aec22eb0c11 10-Jun-2015 Vinit Deshpande <vinitd@google.com> Temporarily disable wifi logger

It is causing memory corruption; we'll enable it after
that is dealt with.

Bug: 21730601
Bug: 21668637

Change-Id: I0c0d9410b7498f80d937ed4cf494e569d3e51cd4
om/android/server/wifi/WifiLogger.java
c85fd892c72e7d15f7e092f29f6cf095b46783a0 09-Jun-2015 Vinit Deshpande <vinitd@google.com> am 5bee0e4..7ec7de9 from mirror-m-wireless-internal-release

7ec7de9 Fixed PLMN ANQP parsing and added Runtime guard on parsing.
54fcb6c Prevent repeating EAP connection forever

Change-Id: I3006e488d5c422330f4cc2aee0d366351ecc36e1
4a9e6c6f8bd09082e928ae2fbd9d600b9086d3de 09-Jun-2015 Lorenzo Colitti <lorenzo@google.com> Merge "Get rid of the CAPTIVE_PORTAL_CHECK state broadcast." into mnc-dev
9f1d0eda5b026472704575376a9ffbdd6f20581b 08-Jun-2015 Vinit Deshpande <vinitd@google.com> Fixed missing period range in standard buckets [DO NOT MERGE]

Bug: 21596369

Change-Id: I65f6e3dbbd23e753d37df066cb93fc5e5ec9bd44
om/android/server/wifi/WifiScanningServiceImpl.java
448dfc1761ccf6e5bc0aeb29ee585b5c07e02e56 06-Jun-2015 Vinit Deshpande <vinitd@google.com> Capture alert data; and require verbose to capture firmware dump [DO NOT MERGE]

This change starts capturing data on firmware alert. Alerts by
default capture FW memory dump.

It also requires 'wifi verbose debugging' to be enabled to capture
firmware dumps; they are taking too much space.

Change-Id: I9bf8c274eef263be4c2fda62bed128048f36b972
om/android/server/wifi/WifiLogger.java
om/android/server/wifi/WifiStateMachine.java
cb3977a1e54ab258733062137ec5aa78a7720332 06-Jun-2015 Vinit Deshpande <vinitd@google.com> Fix a null pointer exception in logger [DO NOT MERGE]

Bug: 21668637
Change-Id: I677c971cb06fbcb638d9a40f6aee3114d517f0ba
om/android/server/wifi/WifiLogger.java
b755905d087d8224151019e15897e3f63efc244b 09-Jun-2015 Vinit Deshpande <vinitd@google.com> Merge "Fixed missing period range in standard buckets" into mnc-dev
7ec7de9f415179e38a39e7b1be917ba77e3b68eb 09-Jun-2015 Jan Nordqvist <jannq@google.com> Fixed PLMN ANQP parsing and added Runtime guard on parsing.

Bug: 21668177
Change-Id: I36a7bc37752410bed78ab877a69b98f7a952e83d
om/android/server/wifi/anqp/CellularNetwork.java
om/android/server/wifi/hotspot2/SupplicantBridge.java
54fcb6c0a81f6c025dc8574c95593da1c4eafb29 27-Feb-2015 Akihiro Onodera <akihiro.x.onodera@sonymobile.com> Prevent repeating EAP connection forever

Android framework does not handle a message
("Authentication with timed out")
for EAP connection and thus connection retry
happens continuously in case of authentication
timed out.

Change-Id: Iadf99bacc9f89d8d18f91231d9263e5b890ba0b9
om/android/server/wifi/WifiMonitor.java
5bee0e4616e2f8025d60cbfe3eec3e274a68a452 06-Jun-2015 Jan Nordqvist <jannq@google.com> ANQP caching cleaned up.

Disabling all HS2.0 logic with no SPs.

Bug: 21306404
Bug: 21660552

Change-Id: I080e99b5e41ead0b718c9e14514fba3108f19ac9
om/android/server/wifi/ScanDetail.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/hotspot2/ANQPData.java
om/android/server/wifi/hotspot2/AnqpCache.java
om/android/server/wifi/hotspot2/NetworkDetail.java
om/android/server/wifi/hotspot2/SupplicantBridge.java
om/android/server/wifi/hotspot2/Utils.java
f7db07b9cc88ceef2ca3d77414834d0d75b4ece7 06-Jun-2015 Vinit Deshpande <vinitd@google.com> Capture alert data; and require verbose to capture firmware dump

This change starts capturing data on firmware alert. Alerts by
default capture FW memory dump.

It also requires 'wifi verbose debugging' to be enabled to capture
firmware dumps; they are taking too much space.

Change-Id: I9bf8c274eef263be4c2fda62bed128048f36b972
om/android/server/wifi/WifiLogger.java
om/android/server/wifi/WifiStateMachine.java
d27cbe81e1b51f09081c667c275019e63a0399a2 06-Jun-2015 Vinit Deshpande <vinitd@google.com> Fix a null pointer exception in logger

Bug: 21668637
Change-Id: I677c971cb06fbcb638d9a40f6aee3114d517f0ba
om/android/server/wifi/WifiLogger.java
7903814396eaa352c333a85dc7ee3b80acc224e1 08-Jun-2015 Vinit Deshpande <vinitd@google.com> Fixed missing period range in standard buckets

Bug: 21596369

Change-Id: I65f6e3dbbd23e753d37df066cb93fc5e5ec9bd44
om/android/server/wifi/WifiScanningServiceImpl.java
10943fe0f4b3beb8998300b6a2517bbd8bac9f0a 08-Jun-2015 Alex Klyubin <klyubin@google.com> Switch from KeyStore.delKey to KeyStore.delete.

KeyStore.delKey's functionality is now covered by KeyStore.delete.

Bug: 18088752
Change-Id: I71aa8ef21c63744cf60cc85a5e88020229f102da
om/android/server/wifi/WifiConfigStore.java
6eb4db053766557a4ebd2a969e0605b0eb6d68fc 04-Jun-2015 Vinit Deshpande <vinitd@google.com> Shut up a noisy log from WifiStateMachine [DO NOT MERGE]

Bug: 20416721

Change-Id: I675942232f2120a203c531d7ed8f214c3322d7dc
om/android/server/wifi/WifiStateMachine.java
e0f45adde26bd4d238ff157e6769650a99dc5261 05-Jun-2015 Vinit Deshpande <vinitd@google.com> am 70b75cd..09f267b from mirror-m-wireless-internal-release

09f267b prevent false wifi roaming signal Bug:21617059
0bf150b Enable ring buffer logging and auto-logging of failures
550ae08 Merge "fix overflow bug in WifiManager reportActivityInfo Bug:20232188" into m-wireless-dev
7ab5189 Merge "Make autojoin parameters configurable" into m-wireless-dev
7ff782a Make autojoin parameters configurable
f49a59b Issue start/stop HAL along with load/unload driver
9ef23e4b9b75270b052f9abeea9d00edfefa1e6d 05-Jun-2015 Lorenzo Colitti <lorenzo@google.com> Get rid of the CAPTIVE_PORTAL_CHECK state broadcast.

This broadcast is useless, because:

- It is guaranteed to be immediately followed by a CONNECTED
state broadcast.
- The CAPTIVE_PORTAL_CHECK doesn't actually do anything - in
fact, since L CAPTIVE_PORTAL_CHECK happens only after we
transition to CONNECTED state.

The broadcast results in ConnectivityService logspam and makes
the wifi icon flicker on DHCP renew because CAPTIVE_PORTAL_CHECK
is mapped to CONNECTING and not CONNECTED, and we don't display
the wifi icon in CONNECTING.

Bug: 21352084
Change-Id: I70bff6ad98709512388b0b234443bc00a9fc2546
om/android/server/wifi/WifiStateMachine.java
09f267b3bc61f3f472516a406fd64be81dc5ccd5 05-Jun-2015 Pierre Vandwalle <vandwalle@google.com> prevent false wifi roaming signal
Bug:21617059

Change-Id: I3ed85339d177c2c15831c59662f693ba4882919b
om/android/server/wifi/WifiStateMachine.java
c5cdba4fa88dd5653be476377ad97665fe2d4872 04-Jun-2015 Vinit Deshpande <vinitd@google.com> Remove trivial GScan logs

These helped once; but now this is just noise. Also
given that GMSCore starts/stops scans many times it is
taking too much of log real estate.

Bug: 20416721

Change-Id: I965ed919afbac56e123e8d019be84d7d33abf3f9
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiScanningServiceImpl.java
0bf150b2d69ec62df905bc6f8603437dc4caee1f 01-Jun-2015 Vinit Deshpande <vinitd@google.com> Enable ring buffer logging and auto-logging of failures

This change extracts ring buffer data from firmware; and
automatically logs driver/firmware logs when any failure
is detected.

Change-Id: I20c8cc00e8ac1d1b4f35da6d309e972cd8ea5d19
om/android/server/wifi/WifiLogger.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
800f0bd2fd9ef6886a9d2d3fd08e14ec32fa9066 04-Jun-2015 Vinit Deshpande <vinitd@google.com> Shut up a noisy log from WifiStateMachine

Bug: 20416721

Change-Id: I675942232f2120a203c531d7ed8f214c3322d7dc
om/android/server/wifi/WifiStateMachine.java
550ae0842c9ca95facfe8b310de5c6d2a0601a89 03-Jun-2015 Pierre Vandwalle <vandwalle@google.com> Merge "fix overflow bug in WifiManager reportActivityInfo Bug:20232188" into m-wireless-dev
70b75cda33a05e8b6e6724ed08e4e72f6fee0471 03-Jun-2015 Pierre Vandwalle <vandwalle@google.com> fix overflow bug in WifiManager reportActivityInfo
Bug:20232188

Change-Id: I2613ead34398d03ce631974cc1ee3f340ffec55e
om/android/server/wifi/WifiServiceImpl.java
3f6620290d7462f3642c82e535146ce9de5e20b3 03-Jun-2015 Vinit Deshpande <vinitd@google.com> am a40265e..7ab5189 from mirror-m-wireless-internal-release

7ab5189 Merge "Make autojoin parameters configurable" into m-wireless-dev
7ff782a Make autojoin parameters configurable
f49a59b Issue start/stop HAL along with load/unload driver
cbda71c Merge "make WiFi No Network Periodic Scans Interval to 5 minutes Bug:21274132" into m-wireless-dev
c538878 make WiFi No Network Periodic Scans Interval to 5 minutes Bug:21274132
7ab51890d35ee9965fff17fd2d8c2eed4971e288 03-Jun-2015 Pierre Vandwalle <vandwalle@google.com> Merge "Make autojoin parameters configurable" into m-wireless-dev
7ff782a43c621f1ba554948fe6e82069740c0b17 03-Jun-2015 Pierre Vandwalle <vandwalle@google.com> Make autojoin parameters configurable

Fix typos which were preventing autojoin parameters to be
configurable thru /data/misc/wifi/autojoinconfig.txt

Change-Id: Icc3aac71e860c14f75dfc6d2cf29b92b6bfd0962
om/android/server/wifi/WifiConfigStore.java
d03a9283285bb7adef6c687eb3a91fa4a8c4b502 02-Jun-2015 Vinit Deshpande <vinitd@google.com> Fix build breaks from last merge

Change-Id: I6ef088cfd3a796b7455df025b37a017c3a4da483
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiServiceImpl.java
f49a59bda006b13e0118d144e0a4a5f569b2251e 27-May-2015 Vinit Deshpande <vinitd@google.com> Issue start/stop HAL along with load/unload driver

This ensures that HAL is enabled when driver is loaded; and
HAL is torn down when driver is unloaded.

Change-Id: Ia7a3e0a485a37b137750040aaecde7cb92eb59e4
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiScanningServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
cd0af1c9ddcac881f49c815fb9da45433eb50736 02-Jun-2015 Vinit Deshpande <vinitd@google.com> am 21d43c4..9a270a7 from mirror-m-wireless-internal-release

9a270a7 Merge "Removed cert verification from ConfigBuilder." into m-wireless-dev
31891af Minor fixes from comments.
fce249d Merge changes I1da47e51,I5d6b0cbe into m-wireless-dev
0600b63 Removed cert verification from ConfigBuilder.
03a529a Fixed incorrect mnc-mcc matching.
6f3626f dont use wifiscanner pauseScan/restartScan
a203056 fix crash in autojoincontroller Bug:21495346
07a3f9d Fixed sequencing issue for Hotspot 2.0 IMSI matching.
ea748f7 Merge "update current configuration based on wifi SSID whitelist roam" into m-wireless-dev
f71c259 Fix bad logs and a crash while reading configs [DO NOT MERGE]
605c327 Fixed bad network history saving and reading. [DO NOT MERGE]
6dd83f1 Merge "fix handling of command for bssid hot list" into m-wireless-dev
a63da80 fix handling of command for bssid hot list

Change-Id: I1ba36f5939f44551946b4756c2074e02f71cedc9
f72f48afc909bd4b7371559aa034054da979942d 02-Jun-2015 Vinit Deshpande <vinitd@google.com> am 22fd854..6dd83f1 from mirror-m-wireless-internal-release

6dd83f1 Merge "fix handling of command for bssid hot list" into m-wireless-dev
a63da80 fix handling of command for bssid hot list
b090f62 make sure unblacklist thresholds are initialized Bug:21161557
4c94fc6 Wifi: Disable PNO (if enabled) only when the scan is allowed to trigger
be2981a fix enabling autojoin offload based on tx/rx counters
a3e4c84 Move Halutil to vendor/google_testing/comms

Change-Id: I9663436ad92094b1cde0e00d217b1fd9ca728351
cbda71c1f091b9ebcf77242795774e85d35ec992 02-Jun-2015 Pierre Vandwalle <vandwalle@google.com> Merge "make WiFi No Network Periodic Scans Interval to 5 minutes Bug:21274132" into m-wireless-dev
c5388781595174cb9d8e055bc846da8056f56346 02-Jun-2015 Pierre Vandwalle <vandwalle@google.com> make WiFi No Network Periodic Scans Interval to 5 minutes
Bug:21274132

Change-Id: I307f08e38edb6729a318d6cfa1f9310141970c3f
om/android/server/wifi/WifiStateMachine.java
a40265e3235b984099c59dfc5ce155d251fcae9e 02-Jun-2015 Pierre Vandwalle <vandwalle@google.com> Remove quotes around SSID when calling ssid white list API

Change-Id: I20b18e7abbfff869bbe02f42d81b9743132eecfd
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
483cef98baaff3d4de18dc29aa5e5cce2ccd9716 02-Jun-2015 Vinit Deshpande <vinitd@google.com> am 9ccffbb..5a091fb from mirror-m-wireless-internal-release

5a091fb Wifi log spam is still a thing The root cause is that inner class WifiScanningStateMachine of WifiScanningServiceImpl use the log from WifiStateMachine rather than from WifiScanningServiceImpl. Reanme log to logLocal
b66b29a turn off WifiNative DBG
98dca33 FW memory dump should be compressed
e5c48b5 wifi: Do not kill the supplicant on a request to stop it
5caa43b add ssid white list for roam offload
a8e38ba111bac40e374412253fc6b6a542c7714f 02-Jun-2015 Erik Kline <ek@google.com> simplify processing DhcpResults LinkAddress data

Bug: 20451261
Change-Id: Ie95d430da58b94ee8b26e79442a35614cb86e78e
om/android/server/wifi/WifiStateMachine.java
9a270a7dc1a0ad24668ee95dbc93fd42de4c7d44 02-Jun-2015 Vinit Deshpande <vinitd@google.com> Merge "Removed cert verification from ConfigBuilder." into m-wireless-dev
31891afce40b903ada9b24ec12e3648ae6aa27b2 29-May-2015 Jan Nordqvist <jannq@google.com> Minor fixes from comments.

Bug: 21306404
Bug: 21283355
Bug: 21171957

Fixed trust cert validation.

Fixed bad network history saving and reading.
Bug: 21022868

Bug in domain matcher, fixed some log levels.

Finished HS2.0/legacy network persistence consistency.

Change-Id: Ic93093a41dd87d70a386909bdea744b5810c7299
om/android/server/wifi/ConfigurationMap.java
om/android/server/wifi/ScanDetail.java
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/hotspot2/SupplicantBridge.java
om/android/server/wifi/hotspot2/omadm/MOManager.java
om/android/server/wifi/hotspot2/pps/DomainMatcher.java
om/android/server/wifi/hotspot2/pps/HomeSP.java
fce249dbb4390a13f61148680ffe9ade03d584b4 01-Jun-2015 Vinit Deshpande <vinitd@google.com> Merge changes I1da47e51,I5d6b0cbe into m-wireless-dev

* changes:
Fixed incorrect mnc-mcc matching.
Fixed sequencing issue for Hotspot 2.0 IMSI matching.
f9d866f1b4e93593b3411886fd71e729f4a5a205 21-Apr-2015 Stuart Scott <stuartscott@google.com> Network Reset should have a lockdown like Factory Reset.

bug:20332322
Change-Id: I0d40ecf39f48131b7aa64e85a0e77d127cc93fa4
(cherry picked from commit 77860074303214f736aee0a26bf38e796461bf17)
om/android/server/wifi/WifiServiceImpl.java
0600b63042d269dbf99197e188000a134511c978 30-May-2015 Jan Nordqvist <jannq@google.com> Removed cert verification from ConfigBuilder.

Change-Id: Id1036ab1a9fa9302e7260fd5d8e6178e65e6d42a
om/android/server/wifi/configparse/ConfigBuilder.java
03a529ae85d526110f2a715168739618f0775493 29-May-2015 Jan Nordqvist <jannq@google.com> Fixed incorrect mnc-mcc matching.

Change-Id: I1da47e51f00ea2c25a1e99911b6da27c8849c599
om/android/server/wifi/hotspot2/Utils.java
om/android/server/wifi/hotspot2/pps/HomeSP.java
6f3626faf50499dd95aa299bb1011c27ab05776d 29-May-2015 Pierre Vandwalle <vandwalle@google.com> dont use wifiscanner pauseScan/restartScan

Change-Id: Ie73fafdde61a9ff218bf6a96e5f3741f98706fad
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiScanningServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
716921f71ceeda2dc00bdd997f54fe7010b3ed0a 19-May-2015 xinhe <xinhe@google.com> Wifi log spam is still a thing

The root cause is that inner class WifiScanningStateMachine
of WifiScanningServiceImpl use the log from WifiStateMachine
rather than from WifiScanningServiceImpl. Reanme log to logLocal

Bug:20416721

Change-Id: I7ad24c4e98062351940d1f52cab02a5c993159e6
om/android/server/wifi/WifiScanningServiceImpl.java
a20305612380c956fa84b1e80523eb7719f62fd1 28-May-2015 Pierre Vandwalle <vandwalle@google.com> fix crash in autojoincontroller
Bug:21495346

Change-Id: Ib99c9c996bba78369c358a33829269d93b11d324
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiStateMachine.java
07a3f9d97394b97965e6754271fb66c1d6bd1753 28-May-2015 Jan Nordqvist <jannq@google.com> Fixed sequencing issue for Hotspot 2.0 IMSI matching.

Change-Id: I5d6b0cbe85d1598901695f923be33ec672580e2d
om/android/server/wifi/SIMAccessor.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/hotspot2/pps/HomeSP.java
ea748f7778a63f07db20b1c2de89c8060c7cd18e 28-May-2015 Pierre Vandwalle <vandwalle@google.com> Merge "update current configuration based on wifi SSID whitelist roam" into m-wireless-dev
21d43c487ca1f719cd2c170e1fac88c7b62a836a 23-May-2015 Pierre Vandwalle <vandwalle@google.com> update current configuration based on wifi SSID whitelist roam

Change-Id: If5d2010740b5d11749aeb82b825a248566c16aaf
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiStateMachine.java
21e50f97f3a6e8b08b73e0266204eae3e6351742 26-May-2015 Vinit Deshpande <vinitd@google.com> Fix an ANR in WifiSettings

getMatchingPasspointConfig doesn't return any value in
some states; this change fixes that by returning default
value.

Bug: 21362013
Change-Id: Ib63d5fa12cce318482cee8781ce4fb97a23e92ef
om/android/server/wifi/WifiStateMachine.java
f71c25960b4fdaf8c1cc7d42ddcad37fd967b63a 21-May-2015 Vinit Deshpande <vinitd@google.com> Fix bad logs and a crash while reading configs [DO NOT MERGE]

(cherry-picked from 33bc37d3a0de7d0043c43a6e77beaff8d82837af in mnc-dev)

Some users have seen NumberFormatExeptions; while this is not
fully explained, it results in a crash. This change fixes that
by handling the exception.

There is also a misleading log (complains about error writing
file) and there's a spammy log about RSSI.

Bug: 21338785

Change-Id: Ifc7c04785ac6cccced2896ccccbedfbb3470fb01
om/android/server/wifi/WifiConfigStore.java
605c327fbf1562e3e66eef8c1ad56bcbdffb3de5 19-May-2015 Jan Nordqvist <jannq@google.com> Fixed bad network history saving and reading. [DO NOT MERGE]

(cherry-picked from 8bc78bddb29cdd9e845f313fabb08c485aa40c21 in mnc-dev)

Bug: 21022868

Change-Id: I62ebbac09da14d140655af4aa69fb8b50fc703f4
om/android/server/wifi/WifiConfigStore.java
6dd83f1bf785fd06609b7fe717b5b4d5f17c12c0 23-May-2015 Vinit Deshpande <vinitd@google.com> Merge "fix handling of command for bssid hot list" into m-wireless-dev
b92960b9bd5b7bbad332f9dee801937a1f76befa 23-May-2015 Pierre Vandwalle <vandwalle@google.com> make sure unblacklist thresholds are initialized
Bug:21161557

Change-Id: Ibba1bc6b0cd2f15d91521c523a2da6357320c5be
om/android/server/wifi/WifiConfigStore.java
a63da8065016c21cdc59c3055ce23c1de0e356da 23-May-2015 Navtej Singh Mann <navtejsingh@google.com> fix handling of command for bssid hot list

making sure to remove the command from memory
bug: 21169620

Change-Id: If5b39d2b1a16e4cf1ce0eb7cb5e5215f004c3ddb
om/android/server/wifi/WifiNative.java
b090f622d0fd9dcdc22d3f54265b72982a2eeed3 23-May-2015 Pierre Vandwalle <vandwalle@google.com> make sure unblacklist thresholds are initialized
Bug:21161557

Change-Id: Ibba1bc6b0cd2f15d91521c523a2da6357320c5be
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
f00c0f3de27bce2a1cefafae3aefa2f1812a8a53 22-May-2015 Prem Kumar <premk@google.com> Merge "Fix bad logs and a crash while reading configs" into mnc-dev
610b648ee56dc5c4accddb4522cb5fd927e9fa10 22-May-2015 Erik Kline <ek@google.com> Merge "Do some DNAv4/DNAv6 -style probing on roaming." into mnc-dev
33bc37d3a0de7d0043c43a6e77beaff8d82837af 21-May-2015 Vinit Deshpande <vinitd@google.com> Fix bad logs and a crash while reading configs

Some users have seen NumberFormatExeptions; while this is not
fully explained, it results in a crash. This change fixes that
by handling the exception.

There is also a misleading log (complains about error writing
file) and there's a spammy log about RSSI.

Bug: 21338785

Change-Id: Ifc7c04785ac6cccced2896ccccbedfbb3470fb01
om/android/server/wifi/WifiConfigStore.java
49dfc6768889a33eb67102b16faf21667af2a60d 20-May-2015 Vinit Deshpande <vinitd@google.com> Indicate failed scans with EXTRA_RESULTS_UPDATED

This flag indicates if scan was successful and results were
updated. It will be set to false if a scan is not performed
(intentionally) or if it failed to produce any results.

Bug: 20642015

Change-Id: I06a1fdd684932db68891ee28d5a049980f483f0f
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
4c94fc6a884fc17424c76d791a42c3c263b390b2 20-May-2015 Sunil Dutt <usdutt@codeaurora.org> Wifi: Disable PNO (if enabled) only when the scan is allowed to trigger

In WiFi's disconnected state and when a PNO is enabled, a scan
request through an alarm source shall disable the PNO, though
the scan fails to trigger (if cancelled due to cancelDelayedScan).
This commit ensures to disable the PNO only before the scan request
succeeds to trigger.

Change-Id: Ie462011d99644e83314c55e8135f8cbf2b8de5c7
om/android/server/wifi/WifiStateMachine.java
c4a5807e031412bd4529daa46baa8b1bdb06295f 19-May-2015 Erik Kline <ek@google.com> Do some DNAv4/DNAv6 -style probing on roaming.

Bug: 18581716
Bug: 19866451
Bug: 20944464
Change-Id: Id2b2c9755fea8b9c9b6a2760949919bc3fb1abde
om/android/server/wifi/WifiStateMachine.java
4dd753e0a6b133b32a4ee9304415aa6eb4da0fff 21-May-2015 Erik Kline <ek@google.com> Merge "Factor out code that makes a new LinkProperties object" into mnc-dev
0ac0f5b76c61707aededb5f959d6df2b2cead3a4 21-May-2015 Erik Kline <ek@google.com> Factor out code that makes a new LinkProperties object

Change-Id: Ia6a0ccb10da62efc261e6ea6d862e4617b9df739
om/android/server/wifi/WifiStateMachine.java
be2981ae2e3d7d8325fa7815731e45bc64e17f2f 21-May-2015 Pierre Vandwalle <vandwalle@google.com> fix enabling autojoin offload based on tx/rx counters

Change-Id: I2fa7970d249638b17f06763246af15f5308d4d55
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiStateMachine.java
8bc78bddb29cdd9e845f313fabb08c485aa40c21 19-May-2015 Jan Nordqvist <jannq@google.com> Fixed bad network history saving and reading.

Bug: 21022868

Change-Id: I62ebbac09da14d140655af4aa69fb8b50fc703f4
om/android/server/wifi/WifiConfigStore.java
22fd854ef9c1fd6df6542c87e1e26e88a66e1fc3 20-May-2015 Pierre Vandwalle <vandwalle@google.com> enable SSID whitelist

Change-Id: I59e8acb0ea0224bc3c365041913f4f375fb03606
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiStateMachine.java
04d29dfffd4c64bc0eb3f109269c1ad2bde6e363 19-May-2015 Vinit Deshpande <vinitd@google.com> Interpret scan-failed event from wpa_supplicant [DO NOT MERGE]

(cherry-picked from 9057c94158c31e040583617bbce19313adf2e58d)

Scans can fail if there are other scans going on in the
firmware. We can only find out about such failures from
supplicant (it prints out a failure event).

Bug: 20192693

Change-Id: I03fe60bb569430c041258c3a4ab8da2d6b5e9ff2
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
5a091fb6a7f51f701e81a45174c9fd74f97dce22 19-May-2015 xinhe <xinhe@google.com> Wifi log spam is still a thing
The root cause is that inner class WifiScanningStateMachine
of WifiScanningServiceImpl use the log from WifiStateMachine
rather than from WifiScanningServiceImpl. Reanme log to logLocal

Bug:20416721
Change-Id: I7ad24c4e98062351940d1f52cab02a5c993159e6
om/android/server/wifi/WifiScanningServiceImpl.java
9057c94158c31e040583617bbce19313adf2e58d 19-May-2015 Vinit Deshpande <vinitd@google.com> Interpret scan-failed event from wpa_supplicant

Scans can fail if there are other scans going on in the
firmware. We can only find out about such failures from
supplicant (it prints out a failure event).

Bug: 20192693

Change-Id: I03fe60bb569430c041258c3a4ab8da2d6b5e9ff2
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
b66b29a00da970ee75052e24f592c8d6c16bd0ed 19-May-2015 xinhe <xinhe@google.com> turn off WifiNative DBG

Change-Id: Ic1fd2879bad202a022dcfc3d4ed707228ebc1eb0
om/android/server/wifi/WifiNative.java
98dca3397c0049d3cfb9c97e2b021c5ee3a2e1bd 19-May-2015 xinhe <xinhe@google.com> FW memory dump should be compressed

Bug:21271572
Change-Id: Icfcdcc3551c7a83fbd4903fd551dae38498d66ce
om/android/server/wifi/WifiNative.java
e5c48b5cd1325f4cd67a798de4028f2a5567bc10 15-May-2015 Sunil Dutt <usdutt@codeaurora.org> wifi: Do not kill the supplicant on a request to stop it

Supplicant is killed on obtaining the first TERMINATE event when
requested to stop from the framework. This shall result in improper
shutdown of the supplicant without proper cleanup of the resources
allocated for all the interfaces.
Moreover, there is no point in killing the supplicant when the
request itself is to to stop the same. Thus, do not kill the
supplicant on the TERMINATE event.

Change-Id: I9a86e725c83374ed8f9b8f203d75928a5deed851
om/android/server/wifi/WifiStateMachine.java
cbe99401672e263d6043cd1bc0c37d2dd871cac0 19-May-2015 Svet Ganov <svetoslavganov@google.com> Merge "Do not report WiFi and Bluetooth MAC addresses - wifi" into mnc-dev
fab7a7bb20990d4792f00a30eca9be307792b79a 13-May-2015 Svet Ganov <svetoslavganov@google.com> Do not report WiFi and Bluetooth MAC addresses - wifi

As a part of the new runtime permissions work we are limiting
the PII apps can access. BT and WiFi MAC addresses are PII and
based on our research there is no valid use case for app dev
to get these addresses aside of user tracking which we are
trying to limit.

bug:21078858

Change-Id: Id0524ba068ad53542f9904314ac4c8581e98cc5d
om/android/server/wifi/WifiStateMachine.java
5caa43b34e0445ff08bff5931b84ffbc850b2a66 16-May-2015 Pierre Vandwalle <vandwalle@google.com> add ssid white list for roam offload

Change-Id: I9fad659cc6527a271251c7403852dc87ef460207
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
6a95e83c7e411a21cf6f6d912ab8498d2de858c9 18-May-2015 xinhe <xinhe@google.com> Merge remote-tracking branch 'goog/mirror-m-wireless-internal-release' into merging

Change-Id: Iec12d73f244bc58e7fcf1154ea8047a03925c241
9ccffbb6c3fe8eaa7d70cc3076d0dc3c6a9073e7 16-May-2015 Pierre Vandwalle <vandwalle@google.com> add BSSID blacklist to autojoin/roam offload

Change-Id: I7eced80f7406de44e96bebc9a3ac3dc648a23eef
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
4bc2080c7eac7d06913715fc09d242ba515b14cf 15-May-2015 Zoltan Szatmary-Ban <szatmz@google.com> Merge "Restrict Wifi config editability lockdown" into mnc-dev
c3a4a8936ce4b473f89ee130baed34afc8f3186a 15-May-2015 Craig Lafayette <craiglafa@google.com> Check for null return from getRingBufferStatus [DO NOT MERGE]

Bug: 21165036
Change-Id: I4f4fb468b66e233fe88f8dbeda5d1a780bdb0cbe
om/android/server/wifi/WifiStateMachine.java
bffd83b768c3f34305bd61cd857a8c0d2f49bab9 15-May-2015 Craig Lafayette <craiglafa@google.com> Check for null return from getRingBufferStatus

Bug: 21165036
Change-Id: I4f4fb468b66e233fe88f8dbeda5d1a780bdb0cbe
om/android/server/wifi/WifiStateMachine.java
12aeea8779cc4ee74ce390460e9dc4f2a6a94021 14-May-2015 Erik Kline <ek@google.com> create IpReachabilityMonitor only in L2ConnectedState

- revert some previous null avoidance hacks
- create IpReachabilityMonitor only in L2ConnectedState

Bug: 21147252
Bug: 21165241
Change-Id: I648852e358a5165621bcb1c33384d783bac0c9f2
om/android/server/wifi/WifiStateMachine.java
76f41991291f2141f256f06efb3746fa0e1b7974 15-May-2015 Erik Kline <ek@google.com> If the interface at start-up isn't valid don't NPE on missing IpReachabilityMonitor

Bug: 21165241
Change-Id: I2348d6e07daf2a910078b2413d70e711d34a1630
om/android/server/wifi/WifiStateMachine.java
b0b0cc202b7d7aaad7b3f69d73e9b58ea2968b05 06-May-2015 Pierre Vandwalle <vandwalle@google.com> hal based Pno and lazy roam implementation

Change-Id: Ib814ff6d29c8d7f1b579f7c088cd4eb104e5b637
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
b1c872f0353647b658742376709e0060fd025040 15-May-2015 Erik Kline <ek@google.com> Merge "Only notify of new link properties if they are non-null" into mnc-dev
ec3b75eb1487ec4423abc132cebc3ce6efd6d094 14-May-2015 Erik Kline <ek@google.com> Only notify of new link properties if they are non-null

Bug: 21147252
Change-Id: I5552a167425b0d54b22003a3675b560ee0b0da19
om/android/server/wifi/WifiStateMachine.java
a6a56c98a21a07d874abbed2b5f83d8a9be7f2f7 14-May-2015 Lorenzo Colitti <lorenzo@google.com> Merge "Keep track of lastConnectUid in more cases." into mnc-dev
ab99a7a345781a9f3ff07335744c1f2073c44ac6 13-May-2015 Lorenzo Colitti <lorenzo@google.com> Keep track of lastConnectUid in more cases.

1. When we switch from a different network, and the connect
happens via AutoJoinController sending us CMD_AUTO_CONNECT.
2. When we interpret SAVE_NETWORK as a request to connect.
3. When we interpret CMD_ADD_OR_UPDATE_NETWORK as a request to
connect.

We were already keeping track of lastConnectUid when receiving
CMD_ENABLE_NETWORK because WifiConfigStore.enableNetwork takes
care of that.

Bug: 20081183
Change-Id: Icb9873057c30e73ad5a105083aa3d60d31d2ce32
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiStateMachine.java
1227b49a94f33844ad0606b48b591bea4d27b08e 14-May-2015 Vinit Deshpande <vinitd@google.com> Build Fixes after the merge

Change-Id: I6f9d28051b6f4d6688c4b76c1923e57febe31145
om/android/server/wifi/WifiServiceImpl.java
347a9779b10304865e478af01ab95871c7614b29 14-May-2015 Vinit Deshpande <vinitd@google.com> am d7cbebf..6111ff7 from mirror-m-wireless-internal-release

6111ff7 minor fix for warning
e026d53 Added cert path validation for CA cert.
9a64375 Changed SSID consistency check to deal with hidden SSIDs (logging only).
1c03d75 Changed log tag, and fixed a NPE.
7d5357a Disable PDBG in WifiStateMachine

Change-Id: I0100a9e48f383266487c43426a55509cf8868f47
e5bf4b884cbbb435dc9268dff61955bcc2b81471 14-May-2015 Vinit Deshpande <vinitd@google.com> am 03ba4a5..ed3f1dd from mirror-m-wireless-internal-release

ed3f1dd Fix permissions check on WifiScanner APIs
f4b30aa Don't pause/restart scans across network connections
ad99846 Remove old (KK based) batched scan API support
fc42a2c Introduce battery blaming for WifiScanner
87df79e make autojoin more deterministic
d79bb0e Merge "enable background scan as soon as screen is off Bug:20909311" into m-wireless-dev
9ac124e enable background scan as soon as screen is off Bug:20909311
6d0cd10 change wifi Logging header
d4c25fd 5GHz roam configuration

Change-Id: Ib7621b11ca851236f9003947c24c5d84670fac94
28d09d2d947ee5814401d1778b7038db23f1a6ba 14-May-2015 Zoltan Szatmary-Ban <szatmz@google.com> Restrict Wifi config editability lockdown

DO created WiFi configurations are now only locked down
for editing/removing if DISALLOW_CONFIG_WIFI is not set.

Bug: 20719934
Change-Id: Ibd218821ab46cca8396084e2d73ae5ee00b584b3
om/android/server/wifi/WifiConfigStore.java
b86f76f28ae06442e458a8cd4d7ddca210a102ef 12-May-2015 xinhe <xinhe@google.com> Diff SSID 2.5 to 5Ghz auto switching

Bug:20631573
Change-Id: I5e36c38e795429be1a527e79e69b7243395a511f
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
f8229a4bc77f2f8cf23a00ba0930a9bbb520d424 10-Apr-2015 Erik Kline <ek@google.com> Incorporate IpReachabilityMonitor into WifiStateMachine

The IpReachability Monitorcallback sends a new CMD_IP_REACHABILITY_LOST.
This is handled by all L2ConnectedState (sub)states.

Bug: 18581716
Change-Id: Ic107574f954e23545a8ad2b73f5c67f823b20bc9
om/android/server/wifi/WifiStateMachine.java
e026d53099b5220c7184cb4bcee3af0542ffc6ee 12-May-2015 Jan Nordqvist <jannq@google.com> Added cert path validation for CA cert.

Bug: 20862882

Change-Id: I22c7d243422c427908a0def09d4f0519171e0868
om/android/server/wifi/configparse/ConfigBuilder.java
9a64375bfb3431ef8d4ec1f2e97349c106c9c5f0 29-Apr-2015 Jan Nordqvist <jannq@google.com> Changed SSID consistency check to deal with hidden SSIDs (logging only).

Change-Id: I80ef72d6a209571643b49c9fd144144e333f6486
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/hotspot2/NetworkDetail.java
1c03d75c73b9f5fa24a795a0d546f4f56b82ab9b 27-Apr-2015 Jan Nordqvist <jannq@google.com> Changed log tag, and fixed a NPE.

Change-Id: I216a9df2397427a1175ea930c501f47cd843b742
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/configparse/MIMEContainer.java
om/android/server/wifi/hotspot2/AnqpCache.java
om/android/server/wifi/hotspot2/NetworkDetail.java
om/android/server/wifi/hotspot2/SupplicantBridge.java
om/android/server/wifi/hotspot2/Utils.java
om/android/server/wifi/hotspot2/omadm/MOManager.java
om/android/server/wifi/hotspot2/pps/Credential.java
om/android/server/wifi/hotspot2/pps/HomeSP.java
7d5357abafeb8b4a8510cf944685a521996a3940 12-May-2015 Vinit Deshpande <vinitd@google.com> Disable PDBG in WifiStateMachine

Bug: 20416721
Change-Id: I60b177d5e078fe5e11101a114cb368bd3dab915d
om/android/server/wifi/WifiStateMachine.java
d7cbebf7fa9081e294ecab38cfe82709f381e1c9 11-May-2015 Vinit Deshpande <vinitd@google.com> Reduce WifiScanner logs

This change saves debug logs in log buffer; and only
dumps error/warning logs.

Bug: 20416721

Change-Id: I2a658194c45092abe490880224ead76f9297961c
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiScanningServiceImpl.java
f75cae779514830d18a3e69e03e5e4c6aa14d0b9 09-May-2015 xinhe <xinhe@google.com> Unable to turn on Portable WiFi hotspot for 5GHz band[DO NOT MERGE]

Bug:19857413
Change-Id: Ic15c5e643c2c1ed1cafab6809126555ff4a4cc56
om/android/server/wifi/WifiNative.java
de1bebe09457d4c54c81c0ad3a3fd3bf7b0d43a4 12-May-2015 Erik Kline <ek@google.com> Don't spuriously fail link properties comparisons.

Set the TCP buffer size appropriately before checking for equality.

Bug: 18581716
Change-Id: Iaa1e8a14bdfea02d2e610772a27e267eb7359c5e
om/android/server/wifi/WifiStateMachine.java
ed3f1ddf197602340e675ae4357cd0fbb145f078 11-May-2015 Vinit Deshpande <vinitd@google.com> Fix permissions check on WifiScanner APIs

Bug: 19990774

Change-Id: Ibf2f118b918d6cc1b28aea97ad812fe518c4502a
om/android/server/wifi/WifiScanningServiceImpl.java
31ecd2686c8c25987a062b071378f7a78c7bfe98 24-Apr-2015 Vinit Deshpande <vinitd@google.com> Fix more logspam from HAL and WifiStateMachine [DO NOT MERGE]

(cherry-picked from e73629f79c8bd59f0f0857a5101160a4d93b1190)

This change also fixes multiple HAL listening threads
and few more logs from WifiScanner

Bug: 20416721

Change-Id: I58f9940d57b27752287e594ecca394c206eb060f
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiScanningServiceImpl.java
f4b30aacbaf31865c7f31e4902d40ff7fdfe9e41 08-May-2015 Vinit Deshpande <vinitd@google.com> Don't pause/restart scans across network connections

These are to be handled by the firmware; so there is
no need to be proactive.

Bug: 20153728

Change-Id: Id13de1fa2edb06cff4b44f9623967f30d3c5beb6
om/android/server/wifi/WifiStateMachine.java
00ebd8f3776aa8e6f91e9a1ab541f53f389b00b6 22-Apr-2015 Vinit Deshpande <vinitd@google.com> Add WifiScanner data in bugreports [DO NOT MERGE]

This change also adds meat in in dumping the service data
to allow debugging.

cherry-picked from a879e0a04ca77d37e976e1de8e03c5d8e26b3a1b

Change-Id: I2cfed36270d44952d731dd07233a2bc80b204696
om/android/server/wifi/WifiScanningServiceImpl.java
ad9984607c007b15b9eb6601facf821cb57e1555 11-May-2015 Vinit Deshpande <vinitd@google.com> Remove old (KK based) batched scan API support

Bug: 18000475

Change-Id: I0b6054f291cadefb1d153692b61f1c3d2ddab0c1
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
fc42a2cd2d461dc39b6853c130bae7dc69ed68e3 11-May-2015 Vinit Deshpande <vinitd@google.com> Introduce battery blaming for WifiScanner

Bug: 17695516

Change-Id: I0de69718bfc1c8115bcc6f835d1470883ee15322
om/android/server/wifi/WifiScanningServiceImpl.java
829909a64bdac0ea0f30907efc44e27685314225 09-May-2015 xinhe <xinhe@google.com> Unable to turn on Portable WiFi hotspot for 5GHz band

Bug:19857413
Change-Id: Ic15c5e643c2c1ed1cafab6809126555ff4a4cc56
om/android/server/wifi/WifiNative.java
87df79e235c64f7062d0c50658fe1999b1225435 08-May-2015 Pierre Vandwalle <vandwalle@google.com> make autojoin more deterministic

- when registering a user preference, make sure that the preference always
override RSSI based comparison between network, i.e. we will always select
a network prefered by user (provided its RSSI is above autojoin threshold).

Change-Id: Ia0825427014a7d61ac4cf9fccec426826915f24e
om/android/server/wifi/WifiAutoJoinController.java
9ac124e3b281e356ceb5d2faab7932fd77dbe63f 08-May-2015 Pierre Vandwalle <vandwalle@google.com> enable background scan as soon as screen is off
Bug:20909311

Change-Id: Ibb2a0650dbf8e0f56743f9cd4a94b6e39fcc191c
om/android/server/wifi/WifiStateMachine.java
d4c25fd76644d5490700ae69fada4669de5193a1 17-Apr-2015 Pierre Vandwalle <vandwalle@google.com> 5GHz roam configuration

Change-Id: I34a59b6de90bda5198e42c3ecf24e978efc73c93
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
49ec3641622a34f4102d57d2b2ae44d52b9e6426 05-May-2015 Prerepa Viswanadham <dham@google.com> Merge changes from topic 'mwd-merge-050415' into mnc-dev

* changes:
Merge commit '5199fba' into master_merge
Merge commit 'b77b98d' into master_merge
Merge commit '624b4e2' into master_merge
5b3b6f748060cc831d52df06d5456d70d6e7ff9e 04-May-2015 Sanket Padawe <sanketpadawe@google.com> Merge "Add new API for getting netId of current wifi network" into mnc-dev
03ba4a5b108ab2bbdb5d0e7be46ac45c00a6d9ff 28-Apr-2015 xinhe <xinhe@google.com> Initial bring up for debug framework

Change-Id: I0e78897d1440f0b7c56740ff7890e2f3d6a0d951
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiLogger.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
9846078598c3468f8813dbfa58238a1846bd81ef 02-May-2015 Sanket Padawe <sanketpadawe@google.com> Add new API for getting netId of current wifi network

Bug: 17380953
Change-Id: I44030e5ffb32322667e729303487f66af39c665c
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
5fdecb4165634b27b024ece39d488791532d1658 01-May-2015 Vinit Deshpande <vinitd@google.com> Fix unhandled CMD_GET_MATCHING_CONFIG

This causes ANRs, since the request may not get completed
in certain cases (such as scan only mode).

Bug: 20747903
Change-Id: I40388c16bed7d14386c1c3808ceaccb850ad2a13
om/android/server/wifi/WifiStateMachine.java
c308372401d89ad7a4ec1e04e72d25f3fc34ddb4 01-May-2015 Prerepa Viswanadham <dham@google.com> Merge commit '5199fba' into master_merge
7ea679c65dd903b1eca6b68019784244a5a369f4 01-May-2015 Prerepa Viswanadham <dham@google.com> Merge commit '624b4e2' into master_merge

Change-Id: Iaf46e8490ccb35519aaa7db6873db6abf93d48a0
f7767c9fa5cbf3c79cffbef5b23c7957c4a7cf06 30-Apr-2015 Zoltan Szatmary-Ban <szatmz@google.com> Merge "Fix NPE on devices without DPM service" into mnc-dev
230e384850ce825e335bb2cb3e06e676b3e9571a 30-Apr-2015 Zoltan Szatmary-Ban <szatmz@google.com> Fix NPE on devices without DPM service

Bug: 20563108
Change-Id: Ie2bda65c834ddad9db8753f7616c2754072551cd
om/android/server/wifi/WifiConfigStore.java
5199fba99dccfcd89ee7a1a43e4dd545b4106902 21-Apr-2015 Vinit Deshpande <vinitd@google.com> Fix indentation on state chart

Change-Id: I50ea10f375ea215373e11f49a5fd4c1937acf3cf
om/android/server/wifi/WifiStateMachine.java
8f4eb8631b1b3f3a462d43d280d85983af8ae3e9 29-Apr-2015 Jan Nordqvist <jannq@google.com> Fixed a crash matching home SPs

Change-Id: I1a662063c5043ba9f0e318a8d6c12933194d6997
om/android/server/wifi/WifiConfigStore.java
2341febfffd241b111577bc20d82c8d15e6a2f40 28-Apr-2015 Andreas Gampe <agampe@google.com> Wifi: RttService must be public

The class is used outside this package, e.g., SystemServiceManager.
It must be accessible.

(cherry picked from commit eeefcd82f4c80048f7cf49bfc1972bdfce5ecf82)

Change-Id: Ifa07c676794fa07c9e13db33107e1ae40d498cf3
om/android/server/wifi/RttService.java
5b9814fe1afe13f4171c912efa73ba7b54997bb2 28-Apr-2015 Vinit Deshpande <vinitd@google.com> Merge "Fixed FQDN matching of HomeSP." into m-wireless-dev
98b464aee95412a582f8c8b503f0bde7baf122d0 28-Apr-2015 Vinit Deshpande <vinitd@google.com> Merge "Reworked persistence semantics for MO." into m-wireless-dev
49b9bea195f8c4d30bbf3610a444fef3797523c0 28-Apr-2015 Vinit Deshpande <vinitd@google.com> Merge "Fixes related to config persistence in PPS. o Fixed up comparison criteria for rewriting of PPS MO. o Quoting of id_string added to make wpa_supplicant happy. o Expire and creation time of credential fully supported in MO." into m-wireless-dev
ec63e6d7dd5a6f6a4ccf2d55f36571227a846c77 28-Apr-2015 Vinit Deshpande <vinitd@google.com> Merge "Clearing ANQP cache when stopping WiFi service, moved ANQP result handling to DriverStartedState." into m-wireless-dev
eeefcd82f4c80048f7cf49bfc1972bdfce5ecf82 28-Apr-2015 Andreas Gampe <agampe@google.com> Wifi: RttService must be public

The class is used outside this package, e.g., SystemServiceManager.
It must be accessible.

Change-Id: Ifa07c676794fa07c9e13db33107e1ae40d498cf3
om/android/server/wifi/RttService.java
624b4e283031091716075e5b6fcdab0547fef83a 25-Apr-2015 xinhe <xinhe@google.com> Merge "No Permission check for WiFi RTT" into m-wireless-dev
f84b6a49bc64a11be2382869c04523380116cce3 24-Apr-2015 Etan Cohen <etancohen@google.com> Merge commit 'ea5c862' into merge2
a9831bdcf0a2eb278a4f2b3fc290de6f4d7ad0b4 24-Apr-2015 Etan Cohen <etancohen@google.com> Merge commit '218394c' into merge2
bd6653f996468560cf636e513ec5eda8cbb18b18 24-Apr-2015 Etan Cohen <etancohen@google.com> Merge commit '05d2f4e' into merge2
fa0502b4e2171143f133bb46e03143328c15e995 24-Apr-2015 Etan Cohen <etancohen@google.com> Merge commit 'baa9bdf' into merge2
126f922831da97d28e6a52ffb30d36b9f21233d2 24-Apr-2015 Jan Nordqvist <jannq@google.com> Fixed FQDN matching of HomeSP.

Change-Id: I6a958ea992918e76c8417120801cfff9508f199a
om/android/server/wifi/WifiConfigStore.java
54d65cf6fa73fd5717ff3791cedb7a1a7d7fa9a0 24-Apr-2015 Lorenzo Colitti <lorenzo@google.com> Merge "Add logging to the "no internet access detected" prompt."
56286fb3e8823d461e899f621587ea0782a98086 24-Apr-2015 Lorenzo Colitti <lorenzo@google.com> Add logging to the "no internet access detected" prompt.

Bug: 20081183
Change-Id: Ic53745a4742c6dd93804e8fb8e70c2506d790e08
om/android/server/wifi/WifiStateMachine.java
e73629f79c8bd59f0f0857a5101160a4d93b1190 24-Apr-2015 Vinit Deshpande <vinitd@google.com> Fix more logspam from HAL and WifiStateMachine

This change also fixes multiple HAL listening threads
and few more logs from WifiScanner

Bug: 20416721
Change-Id: I58f9940d57b27752287e594ecca394c206eb060f
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiScanningServiceImpl.java
2070c02cdd4fc765747121c9b02caf1b1bab89fb 24-Apr-2015 Jan Nordqvist <jannq@google.com> Reworked persistence semantics for MO.

Change-Id: I03c44ea9dae2c07634bc8ce1508c80ef78f1892a
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/hotspot2/Utils.java
om/android/server/wifi/hotspot2/omadm/MOManager.java
om/android/server/wifi/hotspot2/pps/Credential.java
f3bc3c6dcde09a8e39f0a30febf6ae47e882ce90 24-Apr-2015 Vinit Deshpande <vinitd@google.com> Fix more logspam from HAL and WifiStateMachine

Bug: 20416721

Change-Id: I00eef7c9fbbed1403e73e8184de8956677649b8c
om/android/server/wifi/WifiStateMachine.java
820d73615f338d6c71f2d75aba0ad8410e9eed3e 22-Apr-2015 Jan Nordqvist <jannq@google.com> Fixes related to config persistence in PPS.
o Fixed up comparison criteria for rewriting of PPS MO.
o Quoting of id_string added to make wpa_supplicant happy.
o Expire and creation time of credential fully supported in MO.

Change-Id: If7e8104bdec396837d32d11b63ce2dced9a29e95
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/anqp/eap/EAPMethod.java
om/android/server/wifi/configparse/MIMEContainer.java
om/android/server/wifi/hotspot2/Utils.java
om/android/server/wifi/hotspot2/omadm/MOManager.java
om/android/server/wifi/hotspot2/pps/Credential.java
om/android/server/wifi/hotspot2/pps/HomeSP.java
a879e0a04ca77d37e976e1de8e03c5d8e26b3a1b 22-Apr-2015 Vinit Deshpande <vinitd@google.com> Add WifiScanner data in bugreports

This change also adds meat in in dumping the service data
to allow debugging.

Change-Id: I2cfed36270d44952d731dd07233a2bc80b204696
om/android/server/wifi/WifiScanningServiceImpl.java
bb6942c6b6d129fd8904e341c9ce4a4118ed3e0b 11-Apr-2015 Vinit Deshpande <vinitd@google.com> Fix WifiScanner's getChannelsForBand logspam

Change-Id: Ie0e0ce69877200ea5652f8f11df611cfe7890397
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiScanningServiceImpl.java
b11bfe8318f52585b7fc65cbbe8890aa562eb525 23-Apr-2015 xinhe <xinhe@google.com> No Permission check for WiFi RTT

Bug:19918231
Change-Id: Iee3b8120df3bc2c8c1f02c23c4d43f19b0bdcdb9
om/android/server/wifi/RttService.java
d57f630f6a7a5fca872d2b96fc4cce1905daee5d 15-Apr-2015 xinhe <xinhe@google.com> TDLS enhancement HAL interface update

Bug:15152152
Change-Id: I6ef4924f8db85244723cdee89166811f058fd675
om/android/server/wifi/WifiNative.java
4075f980d4f526723d88b6ae3c1c6af14fdfa355 23-Apr-2015 Dianne Hackborn <hackbod@google.com> Merge "Don't allow scans while device is idle."
8366a82ee1bff4c66d3f3642bf0a60538de5d9da 22-Apr-2015 Jan Nordqvist <jannq@google.com> Clearing ANQP cache when stopping WiFi service, moved ANQP result handling to DriverStartedState.

Change-Id: I8b9aa953cbf1309ff2d0174c8a23946b3f7086a8
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiController.java
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/hotspot2/ANQPData.java
om/android/server/wifi/hotspot2/AnqpCache.java
om/android/server/wifi/hotspot2/SupplicantBridge.java
a818ef7d4d9a1212daed202eb7b583a9badc9441 22-Apr-2015 Zoltan Szatmary-Ban <szatmz@google.com> Merge "WiFi config editability lockdown for Device Owner created configs"
ea5c862ceca7130bfcbcc4c072d6fae3f433b909 22-Apr-2015 xinhe <xinhe@google.com> Merge "listenning key error on RTT" into m-wireless-dev
f95649f33db0a328cb4c0bb5e10c7075e6c828f8 22-Apr-2015 xinhe <xinhe@google.com> listenning key error on RTT

Bug:20309046
Change-Id: Id0a0ee57b549984118e3e64530e2c29c87caaed7
om/android/server/wifi/RttService.java
om/android/server/wifi/WifiNative.java
70be7f18b526243679eaaa5f03b7f53417ecf1c7 11-Apr-2015 Vinit Deshpande <vinitd@google.com> Fix WifiScanner's getChannelsForBand logspam

Change-Id: Ie0e0ce69877200ea5652f8f11df611cfe7890397
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiScanningServiceImpl.java
218394c7dbfc9fb185e9fe405e7bf3a37f42f86e 17-Apr-2015 Jan Nordqvist <jannq@google.com> Changed [gs]etDomSubjectMatch to [gs]etDomainSubjectMatch and added case insensitive matching.

Change-Id: Ic30c8a4a6265b97fe368334c5304275d464fbb79
om/android/server/wifi/configparse/ConfigBuilder.java
om/android/server/wifi/hotspot2/omadm/OMAConstructed.java
51dad1d02cb0c3308ea26df198f3057c69690add 17-Apr-2015 xinhe <xinhe@google.com> HAL crash due to debug

Bug:20299517
Change-Id: Idb60c797f620ef58fdd893d9afbe54355449760f
om/android/server/wifi/WifiNative.java
63cde0cdab3f4f2aadac5e2b3dc5cf1b4a5e30f9 20-Apr-2015 Stuart Scott <stuartscott@google.com> Merge "Move factoryReset to service and protect."
b8671cfafc2830ebddeafcfb2d91f2b39b19019b 09-Apr-2015 Stuart Scott <stuartscott@google.com> Move factoryReset to service and protect.

bug:16161518
Change-Id: I7d099099aaf0a306d0a3c5b63dde0ba5108456c3
om/android/server/wifi/WifiServiceImpl.java
4f930e99b36d7f2547cec17a00ad8166e30af4bb 17-Apr-2015 Vinit Deshpande <vinitd@google.com> Fix a race condition in WifiScanner

Bug: 20337061

Change-Id: I3d401164f2be7a88fae313f31f56f315b54ca160
om/android/server/wifi/WifiScanningServiceImpl.java
05d2f4e6f26834a94b53187e6121379a16749088 17-Apr-2015 Jan Nordqvist <jannq@google.com> Various Passpoint Fixes

- Changed lifecycle of MOManager and confined all PPS access to it.
- Fixed topology issues in the MO.
- Added all HomeSP fields to MO.
- A number of tidy ups: Changed to Java7 diamonds, added curlies, "m_" fixes and dropped a few more PARSE-LOG
- Added anonynmous@realm as anonymous identity to HS2.0 configs.
- Implemented domain_suffix_match for AAA server cert matching.

Change-Id: I79c7a545b396ba3cd409d923c4ee339a1d6fea27
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/anqp/DomainNameElement.java
om/android/server/wifi/configparse/ConfigBuilder.java
om/android/server/wifi/hotspot2/omadm/MOManager.java
om/android/server/wifi/hotspot2/omadm/MOTree.java
om/android/server/wifi/hotspot2/omadm/OMAConstructed.java
om/android/server/wifi/hotspot2/omadm/OMANode.java
om/android/server/wifi/hotspot2/omadm/OMAScalar.java
om/android/server/wifi/hotspot2/pps/Credential.java
om/android/server/wifi/hotspot2/pps/HomeSP.java
baa9bdfd34a95aef26c0099282a7d437739ef8c1 17-Apr-2015 Vinit Deshpande <vinitd@google.com> Merge "Various minor fixes." into m-wireless-dev
d6307b404302949f6dadd14fa0860ff1aec432dc 17-Apr-2015 xinhe <xinhe@google.com> HAL crash due to debug

Bug:20299517
Change-Id: Idb60c797f620ef58fdd893d9afbe54355449760f
om/android/server/wifi/WifiNative.java
4e940bb499f65b4305dbeb2e01237c43c2b0b42d 15-Apr-2015 Jan Nordqvist <jannq@google.com> Various minor fixes.

Change-Id: I227c67740f7c18f059e37b3c41fd18225365c7d1
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/configparse/ConfigBuilder.java
om/android/server/wifi/configparse/MIMEContainer.java
om/android/server/wifi/hotspot2/omadm/MOManager.java
om/android/server/wifi/hotspot2/pps/Credential.java
965101c0a9af6e9194a04b77c22b0e7fcad481a8 16-Apr-2015 Pierre Vandwalle <vandwalle@google.com> Merge commit '5040e99' into mg

Change-Id: I133038f35817681a74664d0ad66594615d35f6e9
c67323bf72e65c3d4d38e99d39bcaedf88683df0 10-Apr-2015 Lorenzo Colitti <lorenzo@google.com> Don't allow apps to trigger explicitlySelected.

Instead, rely on WifiManager to pin these apps to their chosen
network using setProcessDefaultNetwork.

Bug: 20081183
Change-Id: Ic9ae3d4f97ae6dcc0e38fcf8fb5bccfcc02407a5
om/android/server/wifi/WifiStateMachine.java
4f04c06ae450834328d8f5467d19e9d54b16371f 16-Apr-2015 Lorenzo Colitti <lorenzo@google.com> Merge "Fix WifiStateMachine message numbers."
340b59c0d6f9f46c2fd128946f4346277f437c31 15-Apr-2015 Lorenzo Colitti <lorenzo@google.com> Fix WifiStateMachine message numbers.

This fixes two issues:

1. The values here conflict with the values in m-wireless-dev.
2. The 149 was assigned to CMD_ACCEPT_UNVALIDATED, thus hiding
the previous assignment of CMD_REMOVE_USER_CONFIGURATIONS.

Change-Id: I96a305b11a3e1b32984e2a83252e6326fbca7d78
om/android/server/wifi/WifiStateMachine.java
a4a473dfad55b2b9edfe5058779531daf01c82f5 16-Apr-2015 Vinit Deshpande <vinitd@google.com> Merge "am f24e3d7..a547460 from mirror-m-wireless-internal-release"
dd490cf1df37b70a8625dc4ec8e712f740dd1e4a 21-Mar-2015 Pierre Vandwalle <vandwalle@google.com> epno initial implementation

Change-Id: I47ede001aa22089bab099072810d648999104091
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiScanningServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
50bb8f65526b16ca8a354fd485d2ed7a343e97ae 15-Apr-2015 Zoltan Szatmary-Ban <szatmz@google.com> WiFi config editability lockdown for Device Owner created configs

Any WiFi configuration created by an active DO app is neither modifiable
nor removable.

Bug:18930324
Change-Id:I3fa986c10b6ff47d1a897794213c225c8c6f579b
om/android/server/wifi/WifiConfigStore.java
3e351b0c2da2d53bf5b21ffb57df83813d6cc219 06-Apr-2015 Lorenzo Colitti <lorenzo@google.com> Wifi changes for "No internet access detected" prompt.

1. Only set explicitlySelected (which causes ConnectivityService
to display the "No internet access detected, use this network
anyway?") if the connection request came from the system and
not from an app.
2. Don't display the dialog if the saved configuration specifies
that this network is not expected to have an Internet
connection.
3. Save the response of the "no Internet access" dialog in the
wifi configuration.

Bug: 20081183
Change-Id: I4f80245e3aee5075c0833749a28755d20f4da5d6
om/android/server/wifi/WifiStateMachine.java
03b70b37a8a20cb92d860b5015f6762dcb5e75cc 14-Apr-2015 Dianne Hackborn <hackbod@google.com> Don't allow scans while device is idle.

Change-Id: If682daba7948c64872fc07e539e957cbf9f3d31f
om/android/server/wifi/WifiServiceImpl.java
5ee18dc63952ff80f4ea21296a0df4f7b27eafe6 15-Apr-2015 Vinit Deshpande <vinitd@google.com> am f24e3d7..a547460 from mirror-m-wireless-internal-release

a547460 Fix incorrect matching of Passpoint networks
93a1dbd fix RTT crashes runtime This is due to local referencs have been used up Bug:20143987
5faa29d changes to support wifi_logger.h API changes
a7ead3d Corrected and tightened up MO tree and mapping from/to configs.
71cd814 Merge "Use PasspointMatchInfo to select good passpoint network" into m-wireless-dev
0c14982 Merge "Store PasspointMatchInfo in ScanDetailCache" into m-wireless-dev
8eefaf2 Use PasspointMatchInfo to select good passpoint network
4d381bc Store PasspointMatchInfo in ScanDetailCache

Change-Id: If9ce95af4968cee4a458dddf21151eaf015880dc
f7afe8414224cb9a959c18763a489ef33a8265fe 06-Apr-2015 Lorenzo Colitti <lorenzo@google.com> Make connecting to a wifi network set config.lastConnectUid.

Bug: 20081183
Change-Id: I2add0cfe870f18dd3ef98e7a311b5ac75e5438d9
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiStateMachine.java
37f96bc22bc79950a030cb13d19146c2065d4103 14-Apr-2015 Vinit Deshpande <vinitd@google.com> Merge "fix default threshold for wifiscanner scan"
73649368ebda32ba0852280add45387506c226f0 14-Apr-2015 Navtej Singh Mann <navtejsingh@google.com> fix default threshold for wifiscanner scan

Change-Id: Icc74072077a9e948db5874081fe46da84facfa55
om/android/server/wifi/WifiScanningServiceImpl.java
a547460e835d6dfde84eda72df470846d11ba807 11-Apr-2015 Vinit Deshpande <vinitd@google.com> Fix incorrect matching of Passpoint networks

Change-Id: I09cd67d666a781ec6eb2c0f339331d5725149799
om/android/server/wifi/ScanDetailCache.java
om/android/server/wifi/WifiConfigStore.java
6aef95a3cfa0b825ff93c45e95f89cc8c5c85164 11-Apr-2015 Prerepa Viswanadham <dham@google.com> Merge commit '70deeca' into merge_work

Change-Id: I77fdf057818f0bc2742e923e71b248648e152e1a
b2ee665db50bad2a0df9b495fc5d6b1dc40a5328 11-Apr-2015 Prerepa Viswanadham <dham@google.com> Merge commit 'bed4746' into merge_work

Change-Id: Ie8a9a1e34650e8b177b99acd2fbf17b5f70be592
a7ead3d4be45cb69bb5851f1a6f9673e93607fc2 10-Apr-2015 Jan Nordqvist <jannq@google.com> Corrected and tightened up MO tree and mapping from/to configs.

Change-Id: Ia5d8aac3131b5b1985c200b565b692499cc4ae92
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/anqp/eap/EAPMethod.java
om/android/server/wifi/anqp/eap/NonEAPInnerAuth.java
om/android/server/wifi/configparse/ConfigBuilder.java
om/android/server/wifi/hotspot2/SupplicantBridge.java
om/android/server/wifi/hotspot2/omadm/MOManager.java
om/android/server/wifi/hotspot2/pps/Credential.java
8eefaf2c281b44fb7a4d951ba587f447800c4b4f 09-Apr-2015 Vinit Deshpande <vinitd@google.com> Use PasspointMatchInfo to select good passpoint network

This allows selection using various parameters that we care
about; such as WAN metrics et al.

This ignores RSSI based selection of BSSIDs for now; that
may come in later.

Change-Id: Ic88f41a0b26d031c11765e7988deeb092a6472ca
om/android/server/wifi/ScanDetailCache.java
om/android/server/wifi/WifiAutoJoinController.java
4d381bc39f5263effdae73ec99065eb299b806ca 09-Apr-2015 Vinit Deshpande <vinitd@google.com> Store PasspointMatchInfo in ScanDetailCache

This change moves ScanDetailCache as a stand alone class; since
it has lot of logic related sorting and finding candidates.

This will get used in network selection going forward.

Change-Id: If039779f4274dca64fa7aceae62dca26caeae2d4
om/android/server/wifi/ScanDetail.java
om/android/server/wifi/ScanDetailCache.java
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/hotspot2/PasspointMatchInfo.java
d33dc0d01f16ef7c338c3e3c82eaefa9e914ff83 03-Apr-2015 Jan Nordqvist <jannq@google.com> Refined SSID parsing in NetworkDetail.

Change-Id: Iaf5d796df472a501ce188755061600b255181c46
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/hotspot2/NetworkDetail.java
om/android/server/wifi/hotspot2/omadm/MOManager.java
a1edc185d46d85e04930a5e12b465de9fea64afe 19-Mar-2015 Jan Nordqvist <jannq@google.com> Various fixes for Passpoint.

A couple of fixes in AnqpCache, better logging.

Fixed BufferUnderdflowException in NetworkDetail.

Bug: 19888749

Modifications to support WiFi config app.

Rework to fit config builder into apps framework.

API for WiFi config app, 3GPP matching, BufferUnderflowException bug fix and some other fixes.

Fixed a log statement.

Clean up.

Change-Id: I763d47b9c7943a8aa4c94afd2678ccea2dd915cc
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/anqp/eap/EAP.java
om/android/server/wifi/configparse/ConfigBuilder.java
om/android/server/wifi/configparse/MIMEContainer.java
om/android/server/wifi/hotspot2/ANQPData.java
om/android/server/wifi/hotspot2/AnqpCache.java
om/android/server/wifi/hotspot2/NetworkDetail.java
om/android/server/wifi/hotspot2/SupplicantBridge.java
om/android/server/wifi/hotspot2/Utils.java
om/android/server/wifi/hotspot2/omadm/MOManager.java
om/android/server/wifi/hotspot2/omadm/OMAParser.java
om/android/server/wifi/hotspot2/pps/Credential.java
om/android/server/wifi/hotspot2/pps/HomeSP.java
f10f5212bf1b6d35f36509e4c72f8bdd21c5e3bb 06-Apr-2015 Vinit Deshpande <vinitd@google.com> Handle potential buffer underflow when parsing beacons

Bug: 20046298
Change-Id: I7a1dd0caf99131c622ea84fd65883b57eaf8bd41
om/android/server/wifi/WifiStateMachine.java
ccbe820337a230f0827f734aca2c51a244a0837f 04-Apr-2015 Vinit Deshpande <vinitd@google.com> Implement 'Available via Passpoint' feature

This also fixes the issues related to explicit connection
to passpoint AP, and fixes occassional mention of
'connected via Wi-Fi Assistent'

Change-Id: Ib4de956f2ea29709d0212fbcb392815644800e78
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
fe6ed7981b30e478ea620432a48f9517bccf7583 02-Apr-2015 Etan Cohen <etancohen@google.com> Merge commit 'dfc7d48' into merge_yet_again
1b707e1788e3a2be6f341b3d02e4c5700efd7fee 02-Apr-2015 Etan Cohen <etancohen@google.com> Merge commit '78d94b8' into merge_yet_again
05d04f448d8e2d44f9eae8e54f17a7bdf57ca1f7 02-Apr-2015 Etan Cohen <etancohen@google.com> Merge commit 'b151395' into merge_yet_again
a389bb4bb5a30d77d026851d2f57b60d1ef6a5ab 01-Apr-2015 Vinit Deshpande <vinitd@google.com> Fix a crash in auto-join selection

Change-Id: I91b1ded0477b098acbc21ee90a427ea2c0a377a9
om/android/server/wifi/WifiConfigStore.java
33f9ad2442844df078dde3ae67961e7132a8a48d 31-Mar-2015 Vinit Deshpande <vinitd@google.com> When user preference doesn't exist, use built-in security preference

This change implements wpa-personal/enterprise over passpoint over
open network preference by including it as default user preference.
If user preference is present, then it is used, when it is not
present this peference is used.

Change-Id: Iae9e9dd0c33baed85f43361514fd42f34533c5f4
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiStateMachine.java
d0f5ce9218deb720d6ae33113257a1f1c2019af7 31-Mar-2015 Vinit Deshpande <vinitd@google.com> Merge "Stop using scanResultCache, and move to ScanDetailCache" into m-wireless-dev
25ee2d5d30434712b28aef6eec9460035101e493 31-Mar-2015 Vinit Deshpande <vinitd@google.com> Stop using scanResultCache, and move to ScanDetailCache

Change-Id: I28898eb8f1dfc0b8d6a8f9029e94784e99565fa1
om/android/server/wifi/ScanDetail.java
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiStateMachine.java
5f5a449365f9f0a716d4b1ccddb3735d088d7f04 28-Mar-2015 Vinit Deshpande <vinitd@google.com> Merge "Fix a crash in WifiStateMachine"
1d38d75ab764e0d1f89154e34a3fab5b95f2c618 27-Mar-2015 Vinit Deshpande <vinitd@google.com> Fix a crash in WifiStateMachine

Bug: 19949563

Change-Id: I8fc910154783028b57ea3239a79af3376cb1edd9
om/android/server/wifi/WifiStateMachine.java
dfc7d4893df5662f5bbad7a94c662e4b02d685e9 27-Mar-2015 Navtej Singh Mann <navtejsingh@google.com> Add support for DFS channel band selection for scanning

Bug:19963571
Change-Id: I3abc5e2a275cbb1e6058710ace54813029ed071b
om/android/server/wifi/WifiScanningServiceImpl.java
c1072acda7dc8b9d7bc4a9bb0b1177b14ecaf276 27-Mar-2015 xinhe <xinhe@google.com> remove wifi beacon parsing debug log

Bug:19771472
Change-Id: I3b51390d9c825520b6eddea452620f6e07be69ab
om/android/server/wifi/hotspot2/NetworkDetail.java
78d94b854b98a094c8659cdc33b1061a31d43aaf 25-Mar-2015 Vinit Deshpande <vinitd@google.com> Merge "EAP-AKA' : Implementation in WiFiStateMachine" into m-wireless-dev
0db2f21276305cc6dfd0b216be355ab85422d49f 25-Mar-2015 Vinit Deshpande <vinitd@google.com> Merge "fix EAP-SIM End-to-End issue" into m-wireless-dev
0669ce85174cdca56edfc9f3bf131012c07b70fa 25-Mar-2015 Vinit Deshpande <vinitd@google.com> Merge "WIFI: EAP-AKA End-To-End" into m-wireless-dev
b322e956c1ce514ca4edcdfe4c712adb85db7b5b 25-Mar-2015 Vinit Deshpande <vinitd@google.com> Merge "EAP-SIM: handle dynamic identity request [DO NOT MERGE]" into m-wireless-dev
e9f41b0c0220c689f7468c1b2149db7ec1995e32 11-Dec-2014 Jean-Michel Bachot <jean-michel.bachot@intel.com> EAP-AKA' : Implementation in WiFiStateMachine

Use external SIM processor:
retrieve AKA' challenges responses from Telephony stack
Inject AKA'challenges responses to wpa_supplicant

Change-Id: Ic103b25ad58807eebd5e0f8eefe3bfc02397aedc
Signed-off-by: Jean-Michel Bachot <jean-michel.bachot@intel.com>
om/android/server/wifi/WifiStateMachine.java
ea1222cb493a909abdf7066195284efe0d39533a 13-Nov-2014 Honore Tricot <honorex.tricot@intel.com> fix EAP-SIM End-to-End issue

- fix connection issue when sim type is SIM
- avoid challenge attempts when RAND is empty that cause telephony exception

Change-Id: I71dd1f4804e406731d5b84fc792acabc0ee60e8d
Signed-off-by: Honore Tricot <honorex.tricot@intel.com>
om/android/server/wifi/WifiStateMachine.java
f97140d51d14ce0659d381f443c08dbd94dfea28 12-Nov-2014 Honore Tricot <honorex.tricot@intel.com> WIFI: EAP-AKA End-To-End

- Decode UMTS-AUTH form of CTRL-REQ-SIM request
- manage UMTS authentication
- cleanup useless code
- make Native API simAuthResponse usable for both
EAP-SIM and EAP-AKA

Change-Id: Ie24c59d87ba2e6a17a0da25fa3d58803aab423f9
Signed-off-by: Honore Tricot <honorex.tricot@intel.com>
Signed-off-by: Abdelmajid MLAYEH <abdelmajidx.mlayeh@intel.com>
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
ad607d99c372160c7d4b38e755e1b47d6419856e 07-Nov-2014 Honore Tricot <honorex.tricot@intel.com> EAP-SIM: handle dynamic identity request [DO NOT MERGE]

Manage the identity creation based on IMSI and 3gpp realm

Change-Id: I4e9c9e23886729592af941d11c798f2583444925
Signed-off-by: Honore Tricot <honorex.tricot@intel.com>
Signed-off-by: Abdelmajid MLAYEH <abdelmajidx.mlayeh@intel.com>
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
b151395e1d4de62ea8a9254e69e1878d3d1cde28 25-Mar-2015 Vinit Deshpande <vinitd@google.com> Set passpointNetwork flag and a crash on forgetNetwork

Crash is due to an incorrect lookup of WifiConfiguration.

Change-Id: Ib273f820f149fd195c7b4cb9b74ae783b2518550
om/android/server/wifi/ScanDetail.java
om/android/server/wifi/WifiConfigStore.java
2740001002132ed305034de64a58b0805fa4e392 25-Mar-2015 Pierre Vandwalle <vandwalle@google.com> fix typo in wifi power caldulation API

Change-Id: Ie8493ef98a20d1b36fa4dfd582e56c8db04d07a9
om/android/server/wifi/WifiServiceImpl.java
f9f7c4ceed78d380a78c2d79a2af3d0cf473e065 25-Mar-2015 Prerepa Viswanadham <dham@google.com> Fix build after m-wireless-internal-release merge

Change-Id: I79ad5b380c06d2096c19328c4f4258abe110c8d8
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/hotspot2/NetworkDetail.java
84a11a3d54b7c6f043dcf7a874b7c0d45709677a 24-Mar-2015 Pierre Vandwalle <vandwalle@google.com> add WiFi energy calculation

Change-Id: Ic368558be45eed7c1c49096966917166b641d1ac
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
e9418ca9dd1975f84260e491a041cac87381693c 24-Mar-2015 Prerepa Viswanadham <dham@google.com> Merge remote-tracking branch 'goog/mirror-m-wireless-internal-release' into master_merge

Change-Id: Id9033b0a7d6bd3c8ecab1648fc8c67feae18c41c
939177ff615062ec826601d536466875d8457375 23-Mar-2015 xinhe <xinhe@google.com> add Framework for set country code through HAL

Bug:19896389
Change-Id: Idc92e11b75db71ab6b9bc7ee54889bd41c68b9ce
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
b89d5aca82817b0916ab692eb29c578449a286ce 23-Mar-2015 Vinit Deshpande <vinitd@google.com> Set default value of num_scans to 10

Making it same as what we had in m-wireless-dev.

Change-Id: Idc9622e30da5a41245c30223d9bd788f81128c9a
om/android/server/wifi/WifiScanningServiceImpl.java
bae8e9bc7b8c17f55784ce695bc6b76825b2389c 20-Mar-2015 Vinit Deshpande <vinitd@google.com> Merge "Handle bad IEs coming from APs more gracefully"
418d56ca82dbb35f51c866d4d1069979859ecf3e 20-Mar-2015 Vinit Deshpande <vinitd@google.com> Handle bad IEs coming from APs more gracefully

Bug: 19788443
Change-Id: I0c781c74878b57933777171e3c6230d88cb42a1a
om/android/server/wifi/WifiStateMachine.java
c55fc72b3c2fa2f47a52138e53a86460ba87a1c5 19-Mar-2015 Pierre Vandwalle <vandwalle@google.com> fix writing of networkHistory.txt file
Bug:19770620

Change-Id: I469a50ffc5f33101ed5e46eb5603689f2982f30d
om/android/server/wifi/WifiConfigStore.java
24eeb0b725974dd56031205c5dd877040d67cad3 19-Mar-2015 Vinit Deshpande <vinitd@google.com> Merge "Fix an incorrectly merged change to start wifi HAL"
b0b20342e849017c98b33d8c500dff643ec01b6a 19-Mar-2015 Vinit Deshpande <vinitd@google.com> Fix an incorrectly merged change to start wifi HAL

This is breaking quite a few things; softAP doesn't work
nor does GScan etc.

Bug: 19786626
Change-Id: Iaa225be272a81df0272fc16a876ee04124abb748
om/android/server/wifi/WifiNative.java
bcbe8d690aec513cb1b753160b3b4d7e306a9570 19-Mar-2015 Vinit Deshpande <vinitd@google.com> Merge "Disable user consent for connecting to app-added networks"
ac5ef7ed57cc198486d4c411f39ca89192ed6395 19-Mar-2015 Alan Viverette <alanv@google.com> Hide NetworkDetail logspam behind debug flag

Bug: 19771472
Change-Id: I2ea9f6e040bc094fc331dcf46a5af84bc28d0f87
om/android/server/wifi/hotspot2/NetworkDetail.java
0047ccf563baa288777e06c6fe95d3681fcf5ccd 18-Mar-2015 Vinit Deshpande <vinitd@google.com> More bug fixes to enable passpoint

Change-Id: Icbf65a731c93deecc49178f9628b1ee3a9c91a00
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/hotspot2/omadm/MOManager.java
7f3218ac0469ec2064253325708fe17550b43dfa 19-Mar-2015 Vinit Deshpande <vinitd@google.com> Disable user consent for connecting to app-added networks

Bug: 19829426
Change-Id: I6d19600fdf5e2707be0cb11d57c22de2170f04c2
om/android/server/wifi/WifiStateMachine.java
7d6301ead19afdf3de37455e9ed133c25b4938cd 19-Mar-2015 Vinit Deshpande <vinitd@google.com> Fix a runtime crash introduced by incorrect JNI mapping

Change-Id: Ie37d8a8788e8bdc3a5f52b2ff58be3506943bf9d
om/android/server/wifi/WifiNative.java
a0d34d3626bd9631039a485d2d428b1b7de390e2 19-Mar-2015 Pierre Vandwalle <vandwalle@google.com> initial logger stuff

Change-Id: Ie08d4184efe40c91969914ce84a1a6f1d255ec21
om/android/server/wifi/WifiLogger.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
228fedec31770b8469432a513732d4df82987b83 19-Mar-2015 Vinit Deshpande <vinitd@google.com> Merge "Fixed bug in IE parser." into m-wireless-dev
398823d45a240ff90ff2ffab3ff4a8b8646f24c9 19-Mar-2015 Jan Nordqvist <jannq@google.com> Fixed bug in IE parser.

Change-Id: I607081f2a651a7859b53f4b5cdda46c48e1e6480
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/hotspot2/NetworkDetail.java
om/android/server/wifi/hotspot2/omadm/MOManager.java
e9726dc7bb4af2fd9370d6eb83fe6f834b7918ec 18-Mar-2015 xinhe <xinhe@google.com> Merge "Change rtt Framework interface" into m-wireless-dev
12cf388ecf3b2aa5ba66ed680b931fa356ab75b5 13-Mar-2015 xinhe <xinhe@google.com> Change rtt Framework interface

Bug:19735392
Change-Id: Ie64e4609c9804c904836bb37255d4efe9211f39f
om/android/server/wifi/RttService.java
om/android/server/wifi/WifiNative.java
d3fb9cbb12d013dd70e672ace5c41ab18a3679a0 18-Mar-2015 Vinit Deshpande <vinitd@google.com> Connect to passpoint end-to-end

Change-Id: I9bdec486b2a5963ce8858ad1ed322f6d62e6349f
om/android/server/wifi/ScanDetail.java
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/anqp/eap/EAP.java
om/android/server/wifi/hotspot2/NetworkDetail.java
om/android/server/wifi/hotspot2/PasspointMatchInfo.java
om/android/server/wifi/hotspot2/SupplicantBridge.java
om/android/server/wifi/hotspot2/omadm/MOManager.java
om/android/server/wifi/hotspot2/pps/Credential.java
f5d683bceb3aff47282636e425425f3733c0b45f 18-Mar-2015 Pierre Vandwalle <vandwalle@google.com> export API to disable autojoin scan initial implementation
automerge: e2614ba

* commit 'e2614ba1b774529ee68cc4ac189f7492cff89db3':
export API to disable autojoin scan initial implementation
a85a0bf4acd319bb37091565c19b33290bf98618 15-Mar-2015 Vinit Deshpande <vinitd@google.com> Removed older passpoint code that is no longer in use

Change-Id: I03da89238a3abd8c00f694914c41e26ac40fca2e
om/android/server/wifi/passpoint/WifiPasspointCertificate.java
om/android/server/wifi/passpoint/WifiPasspointCertificateHelper.java
om/android/server/wifi/passpoint/WifiPasspointClient.java
om/android/server/wifi/passpoint/WifiPasspointDmClient.java
om/android/server/wifi/passpoint/WifiPasspointDmTreeHelper.java
om/android/server/wifi/passpoint/WifiPasspointHttpClient.java
om/android/server/wifi/passpoint/WifiPasspointService.java
om/android/server/wifi/passpoint/WifiPasspointServiceImpl.java
om/android/server/wifi/passpoint/WifiPasspointSoapClient.java
om/android/server/wifi/passpoint/WifiPasspointStateMachine.java
af955ffa0082189fb688429732427c333f2491ce 12-Mar-2015 Vinit Deshpande <vinitd@google.com> Integration fixes to add/save/restore passpoint networks

Change-Id: Ic7fad523e1fe2bdc7ac9509b5998576b62909fcd
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/hotspot2/omadm/MOManager.java
om/android/server/wifi/hotspot2/omadm/MOTree.java
om/android/server/wifi/hotspot2/omadm/OMAConstructed.java
om/android/server/wifi/hotspot2/omadm/OMANode.java
om/android/server/wifi/hotspot2/omadm/OMAScalar.java
om/android/server/wifi/hotspot2/pps/Credential.java
fea443b1b8807443544dfdb29a9c237b3ccf964a 17-Mar-2015 Jan Nordqvist <jannq@google.com> Tightened up and moved IE parse syntax checking.

Change-Id: I5e764dfb4f4d2d83466ee9659da86679bed403e7

Fixed up previous check in.

Change-Id: I8ef944b23d3cb6c8c426377442890bc366593e47
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/hotspot2/NetworkDetail.java
55482d0e98028d33b3b707498bd6136e209728a0 17-Mar-2015 Vinit Deshpande <vinitd@google.com> Merge "Introduced scoring of PassspointMatchInfo" into m-wireless-dev
cd605289f40664a2bfa051986a544f1d050961da 17-Mar-2015 Jan Nordqvist <jannq@google.com> Introduced scoring of PassspointMatchInfo

Change-Id: Ib284af5c4e6ba4f0a22df90ca907e8be9a7de90c
om/android/server/wifi/hotspot2/PasspointMatchInfo.java
0ebfc80ff9c9db920ed1cea01e3518a7b4b856ac 17-Mar-2015 Lorenzo Colitti <lorenzo@google.com> Merge "Support using the Java DHCP client." into m-wireless-dev
207af567531a0813a9c8651d28bc4bda0ea22088 16-Mar-2015 xinhe <xinhe@google.com> remove wifi beacon parsing debug log

Bug:19771472
Change-Id: Ibb56afdb8edbd25396ac4ab51d685a39f1df9c1f
om/android/server/wifi/hotspot2/NetworkDetail.java
660c10ba84cfa370896750855511d81b50759313 05-Mar-2015 Lorenzo Colitti <lorenzo@google.com> Support using the Java DHCP client.

Change-Id: I296d1481d79cc22420b98a9455f86fd80d02e694
om/android/server/wifi/WifiStateMachine.java
8401b58cd0198a8068cd6ad90215e3cd7fb2c5d0 15-Mar-2015 Vinit Deshpande <vinitd@google.com> am "add 2 side RTT support on scan"

merged from goog/mirror-m-wireless-internal-release
243931f add 2 side RTT support on scan
00367222c429bcbe2f6071f480981a049cf5aaf9 15-Mar-2015 Vinit Deshpande <vinitd@google.com> am "Couple of bug fixes to enable/disable wifi"

merged from goog/mirror-m-wireless-internal-release
e2434ec Couple of bug fixes to enable/disable wifi
8b63d114d1cbfd270f6d2f07675fafa3183b38c7 15-Mar-2015 Vinit Deshpande <vinitd@google.com> am "HS20: Selection code moved to WifiAutoJoinController"

merged from goog/mirror-m-wireless-internal-release
ef1567e HS20: Selection code moved to WifiAutoJoinController
494ea3f652ebb1f5fd626848000a7e52fa1260fe 15-Mar-2015 Vinit Deshpande <vinitd@google.com> am "break missing for P2P_CONNECTION_CHANGED"

merged from goog/mirror-m-wireless-internal-release
8433fd1 break missing for P2P_CONNECTION_CHANGED
3346645330acde6a938289c47654b0a524205100 15-Mar-2015 Vinit Deshpande <vinitd@google.com> am "country code setting broken"

merged from goog/mirror-m-wireless-internal-release
80d14d6 country code setting broken
2c6b0bfdf07eedc5a646af26e4e552aa477b8fc5 15-Mar-2015 Vinit Deshpande <vinitd@google.com> am "Introduce ANQP cache."

merged from goog/mirror-m-wireless-internal-release
751c5a4 Introduce ANQP cache.
ec544b277cb2444f66fa1738027874e057048061 15-Mar-2015 Vinit Deshpande <vinitd@google.com> am "Integrate passpoint with existing Wifi infrastructure"

merged from goog/mirror-m-wireless-internal-release
77f2b82 Integrate passpoint with existing Wifi infrastructure

Change-Id: If4e54914a5c2c37733e488969e85a3a8312bb71d
44c4650300148f52d476708790074ee0ae4ba3dd 15-Mar-2015 Vinit Deshpande <vinitd@google.com> am "Passpoint API - Take 1"

merged from goog/mirror-m-wireless-internal-release
03e92b9 Passpoint API - Take 1
a4decb57ff612b21dade7c732f0a73dd4081947a 15-Mar-2015 Vinit Deshpande <vinitd@google.com> am "Unable to see Tethering/portable Hotspot SSID"

merged from goog/mirror-m-wireless-internal-release
b830d76 Unable to see Tethering/portable Hotspot SSID
9b5fbb7be00bbd41d4efdb1ac6c641f4628b0cd9 15-Mar-2015 Vinit Deshpande <vinitd@google.com> am "get channel list from driver for SoftAP channel selection"

merged from goog/mirror-m-wireless-internal-release
8262822 get channel list from driver for SoftAP channel selection
68cfb779bd412bd016696bd1085c9eeda6501590 15-Mar-2015 Vinit Deshpande <vinitd@google.com> am "Updating scan status after scan for full scan result completed"

merged from goog/mirror-m-wireless-internal-release
2b26ad1 Updating scan status after scan for full scan result completed
0f7a675fa6a6d12db478d0ddb413cbe9e151a478 15-Mar-2015 Vinit Deshpande <vinitd@google.com> am "send network state changed broadcast when BSSID change"

merged from goog/mirror-m-wireless-internal-release
e7c2a0e send network state changed broadcast when BSSID change
8eb05b1d0312b1699d95a20a0375253782374307 15-Mar-2015 Vinit Deshpande <vinitd@google.com> am "Added a comment."

merged from goog/mirror-m-wireless-internal-release
e0a4f90 Added a comment.
08c90dffcc1af42d13394d7893426f1e22dc28c1 15-Mar-2015 Vinit Deshpande <vinitd@google.com> am "Credential/profile storage added, completed network matching and added HS20 Simulator."

merged from goog/mirror-m-wireless-internal-release
71a988c Credential/profile storage added, completed network matching and added HS20 Simulator.
b78e5df0e45617f8bad616934d0014d28ba78788 15-Mar-2015 Vinit Deshpande <vinitd@google.com> am "A few more bug fixes and addition of Icon and Home realm queries."

merged from goog/mirror-m-wireless-internal-release
7b2caa2 A few more bug fixes and addition of Icon and Home realm queries.
d14fd7e3a89abf15e0224599fe38e7f71fda81c2 15-Mar-2015 Vinit Deshpande <vinitd@google.com> am "Fix getScanResults API call for fetching the scan results"

merged from goog/mirror-m-wireless-internal-release
14aadf3 Fix getScanResults API call for fetching the scan results
6e54e0738e517318eb116b4b4768d74966583c4f 15-Mar-2015 Vinit Deshpande <vinitd@google.com> am "Fixed a couple of inconsistencies around method length."

merged from goog/mirror-m-wireless-internal-release
3be1b3f Fixed a couple of inconsistencies around method length.
e6bc410414babb0a9211019816afaaceefa937dc 15-Mar-2015 Vinit Deshpande <vinitd@google.com> am "Bug fixes after test run. First pass all OK."

merged from goog/mirror-m-wireless-internal-release
777f4fc Bug fixes after test run. First pass all OK.
3ae5d2f8ee095a39d180824653e781e9cc76f2d6 15-Mar-2015 Vinit Deshpande <vinitd@google.com> am "Base Hotspot 2.0 code (moved from base)."

merged from goog/mirror-m-wireless-internal-release
6a3903f Base Hotspot 2.0 code (moved from base).
3e1df321a7486739e7f4c3c9d27a9595d91db14b 15-Mar-2015 Vinit Deshpande <vinitd@google.com> am "set softAP on a specified band, including both 2.4 and 5 GHz band"

merged from goog/mirror-m-wireless-internal-release
0e8f0d8 set softAP on a specified band, including both 2.4 and 5 GHz band
e2614ba1b774529ee68cc4ac189f7492cff89db3 13-Mar-2015 Pierre Vandwalle <vandwalle@google.com> export API to disable autojoin scan initial implementation

Change-Id: I504f135ab91c5e483a92306a9b96d70b80f11362
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
73185809f4a44a8ee272afe3e5253496aeb966ce 13-Mar-2015 Lorenzo Colitti <lorenzo@google.com> Don't crash the system when an element is too long.

Change-Id: I09b5ed2713ea470dc410f7f2d9cc84413843023c
om/android/server/wifi/hotspot2/NetworkDetail.java
a7992ef326a670a5a3ae7ccfe6da41649f672104 13-Mar-2015 Vinit Deshpande <vinitd@google.com> am "add 2 side RTT support on scan"

merged from partner/m-wireless-wifi-dev
243931f add 2 side RTT support on scan
2b4e16a18872d4fd2d562aa3196641b07218ef50 10-Mar-2015 Vinit Deshpande <vinitd@google.com> Merge "Workaround multiple onClick events"
4f5ea4c36f490f9427b49b7818deda15a8ef9b94 09-Mar-2015 Vinit Deshpande <vinitd@google.com> Workaround multiple onClick events

User consent dialog box's onClick() event may get called multiple
times on certain occassions. This results in newMessage being sent
twice; which isn't correct.

This change works around that problem by making onClick() work only
on first try. Subsequent onClicks() are ignored.

Bug: 19641226
Change-Id: I6e6ff8cf6921c53670db1f4dfca28b45dd384268
om/android/server/wifi/WifiStateMachine.java
186f7513a080eb1a419b6d83286d62961168a5fe 27-Feb-2015 Adam Lesinski <adamlesinski@google.com> Change to use new Structure

Change-Id: I5c6b23b8e1441d4de9056aa959ddedf297823bec
om/android/server/wifi/WifiServiceImpl.java
b88096a09212ab483e1a7b8b3a6cde011d8fb0e6 07-Mar-2015 Vinit Deshpande <vinitd@google.com> am "Couple of bug fixes to enable/disable wifi"

merged from partner/m-wireless-wifi-dev
e2434ec Couple of bug fixes to enable/disable wifi
a5c1a1d6af3ce2586f41cf44477837a7488d600c 07-Mar-2015 Vinit Deshpande <vinitd@google.com> am "HS20: Selection code moved to WifiAutoJoinController"

merged from partner/m-wireless-wifi-dev
ef1567e HS20: Selection code moved to WifiAutoJoinController
5268e39bcc84eca60a42c98a623583cb3e89206e 07-Mar-2015 Vinit Deshpande <vinitd@google.com> am "break missing for P2P_CONNECTION_CHANGED"

merged from partner/m-wireless-wifi-dev
8433fd1 break missing for P2P_CONNECTION_CHANGED
e1e919cdd71dc4ec0d852e0ba62a1901e6c51e33 07-Mar-2015 Vinit Deshpande <vinitd@google.com> am "country code setting broken"

merged from partner/m-wireless-wifi-dev
80d14d6 country code setting broken
265b87e9aa6d11f6b1ae3023e28b1f58290f907f 07-Mar-2015 Vinit Deshpande <vinitd@google.com> am "Introduce ANQP cache."

merged from partner/m-wireless-wifi-dev
751c5a4 Introduce ANQP cache.
171bc9b46cd9443088412dd3234b220f4d757524 07-Mar-2015 Vinit Deshpande <vinitd@google.com> am "Integrate passpoint with existing Wifi infrastructure"

merged from partner/m-wireless-wifi-dev
77f2b82 Integrate passpoint with existing Wifi infrastructure

Change-Id: I20355d2554ee38509c21aa954d21435c6b9a3716
03ec2b718f384de591ffaa525e5d0e8070aa3c57 07-Mar-2015 Vinit Deshpande <vinitd@google.com> am "Passpoint API - Take 1"

merged from partner/m-wireless-wifi-dev
03e92b9 Passpoint API - Take 1
d061f6840535717fae0d4f29bce6d7435b1cdfb8 07-Mar-2015 Vinit Deshpande <vinitd@google.com> am "Introduce onLost event on bssid hotlist [DO NOT MERGE]"

merged from partner/m-wireless-wifi-dev
d476240 Introduce onLost event on bssid hotlist [DO NOT MERGE]
fd40440cc72f538babcf55d3c1d4d3f4eaa5f1a1 07-Mar-2015 Vinit Deshpande <vinitd@google.com> am "updated number of default scan to cache"

merged from partner/m-wireless-wifi-dev
1ef80d7 updated number of default scan to cache
b67b04466e7b85e9d8150d473088a9a59784220d 07-Mar-2015 Vinit Deshpande <vinitd@google.com> am "Unable to see Tethering/portable Hotspot SSID"

merged from partner/m-wireless-wifi-dev
b830d76 Unable to see Tethering/portable Hotspot SSID
26a5c2826a5a00aa4ed577b038fb34eabf767df5 07-Mar-2015 Vinit Deshpande <vinitd@google.com> am "get channel list from driver for SoftAP channel selection"

merged from partner/m-wireless-wifi-dev
8262822 get channel list from driver for SoftAP channel selection
8a93bedee523ffcf4c243db4610b90400e47a093 07-Mar-2015 Vinit Deshpande <vinitd@google.com> am "Updating scan status after scan for full scan result completed"

merged from partner/m-wireless-wifi-dev
2b26ad1 Updating scan status after scan for full scan result completed
3241c8afcaaed22eb33f9f2aa9e8a6e25ddde335 07-Mar-2015 Vinit Deshpande <vinitd@google.com> am "Enable DFS"

merged from partner/m-wireless-wifi-dev
0465ff5 Enable DFS
9119ee46557d638b5b560e516b6b71e0c10ac7bf 07-Mar-2015 Vinit Deshpande <vinitd@google.com> am "Added a comment."

merged from partner/m-wireless-wifi-dev
e0a4f90 Added a comment.
e84f0749f40f1e795bafcbaf2fe5863399ac4a9b 07-Mar-2015 Vinit Deshpande <vinitd@google.com> am "Credential/profile storage added, completed network matching and added HS20 Simulator."

merged from partner/m-wireless-wifi-dev
71a988c Credential/profile storage added, completed network matching and added HS20 Simulator.
861e86ce6da66c0bea720aaab0815b366f9e0f11 07-Mar-2015 Vinit Deshpande <vinitd@google.com> am "A few more bug fixes and addition of Icon and Home realm queries."

merged from partner/m-wireless-wifi-dev
7b2caa2 A few more bug fixes and addition of Icon and Home realm queries.
7b1242ec1a955d3f342c6739d022ac0f04529581 07-Mar-2015 Vinit Deshpande <vinitd@google.com> am "Fix getScanResults API call for fetching the scan results"

merged from partner/m-wireless-wifi-dev
14aadf3 Fix getScanResults API call for fetching the scan results
ff81d730a25298a6d149a63ebf6679cec464695c 07-Mar-2015 Vinit Deshpande <vinitd@google.com> am "Fixed a couple of inconsistencies around method length."

merged from partner/m-wireless-wifi-dev
3be1b3f Fixed a couple of inconsistencies around method length.
98e35a9d2944d70a593788ce57379bd4ee507ca1 07-Mar-2015 Vinit Deshpande <vinitd@google.com> am "Bug fixes after test run. First pass all OK."

merged from partner/m-wireless-wifi-dev
777f4fc Bug fixes after test run. First pass all OK.
6ac188f37e4b758360222b31dc4f04ca587fb187 07-Mar-2015 Vinit Deshpande <vinitd@google.com> am "Base Hotspot 2.0 code (moved from base)."

merged from partner/m-wireless-wifi-dev
6a3903f Base Hotspot 2.0 code (moved from base).
73ad1c3d81664ed0bd70d063ac8b549c26f3d187 07-Mar-2015 Vinit Deshpande <vinitd@google.com> am "set softAP on a specified band, including both 2.4 and 5 GHz band"

merged from partner/m-wireless-wifi-dev
0e8f0d8 set softAP on a specified band, including both 2.4 and 5 GHz band
019a91c131ceeafe25b2737581cef4296855a061 07-Mar-2015 Vinit Deshpande <vinitd@google.com> am "wifi: Use 'set setband' instead of private 'driver setband' [DO NOT MERGE]"

merged from partner/m-wireless-wifi-dev
03cdd62 wifi: Use 'set setband' instead of private 'driver setband' [DO NOT MERGE]
ac7e8d8178547e03cd0cec34356d95fcaa7c033a 07-Mar-2015 Vinit Deshpande <vinitd@google.com> am "Bring in passpoint code [DO NOT MERGE]"

merged from partner/m-wireless-wifi-dev
e91eb1b Bring in passpoint code [DO NOT MERGE]
f959e53fa53b108a093cfb88f545f14d2ee92fc7 07-Mar-2015 Vinit Deshpande <vinitd@google.com> am "New Additions to WifiScanner APIs [DO NOT MERGE]"

merged from partner/m-wireless-wifi-dev
83a674a New Additions to WifiScanner APIs [DO NOT MERGE]
243931f3474f6235cfcf5c1a55fa2f192ee264ae 02-Mar-2015 xinhe <xinhe@google.com> add 2 side RTT support on scan

Bug:19533713
Change-Id: I3076cba3c7c7d5f234caa7e35ab96dd3f7471aa2
om/android/server/wifi/ScanDetail.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiScanningServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/hotspot2/NetworkDetail.java
e2434ec1d0c1c75709f55dcee5e8943c1d68e6c1 03-Mar-2015 Vinit Deshpande <vinitd@google.com> Couple of bug fixes to enable/disable wifi

It is broken, because we now try to read/write passpoint
configurations. Few null and empty checks are missing in
that code path.

Bug: 19568112

Change-Id: I4bfcbf95e19b050ba40d9df006c0f1e4880414ed
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/hotspot2/omadm/MOManager.java
1e6b232eb572189f976a7813c3b770752be8e3b7 03-Mar-2015 Vinit Deshpande <vinitd@google.com> am 9dadadf7: Resolved conflicts for merge of commit \'c8d832c4\'

* commit '9dadadf7087f9226817712156ce0fe09f350196b':
EAP-SIM: handle dynamic identity request
6cf462d04c29b789f1dd9ce58f966e9a65b70f74 05-Feb-2015 Pierre Vandwalle <vandwalle@google.com> send network state changed broadcast when BSSID change

Change-Id: I1920d8656a9db0aead90787b5049106a5e7ab538
om/android/server/wifi/WifiStateMachine.java
9dadadf7087f9226817712156ce0fe09f350196b 02-Mar-2015 Vinit Deshpande <vinitd@google.com> Resolved conflicts for merge of commit 'c8d832c4'

Change-Id: Ic887b530f9e73cc25249d9b380581712392241fb
ef1567e413c9ed5f5c4fdb9e354861632f7b2f87 25-Feb-2015 Jan Nordqvist <jannq@google.com> HS20: Selection code moved to WifiAutoJoinController

Change-Id: Ic2f713758ec20f98f63d55b4a610e4dca07742fb
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/anqp/HSConnectionCapabilityElement.java
om/android/server/wifi/anqp/IPAddressTypeAvailabilityElement.java
om/android/server/wifi/hotspot2/ANQPData.java
om/android/server/wifi/hotspot2/AnqpCache.java
om/android/server/wifi/hotspot2/NetworkDetail.java
om/android/server/wifi/hotspot2/PasspointMatchInfo.java
om/android/server/wifi/hotspot2/SelectionManager.java
om/android/server/wifi/hotspot2/SupplicantBridge.java
om/android/server/wifi/hotspot2/Utils.java
49bc8dd35845318cd9bc5ce9064fc1ad33bbece8 27-Feb-2015 xinhe <xinhe@google.com> Sprout device falls in a reboot loop when flashed with Master release builds

Bug:19359246
Change-Id: I1711451dbf3117e8fe0ba3bd113c18603ebf82bd
om/android/server/wifi/WifiAutoJoinController.java
8433fd1fc75809033bdd207e80a044b1badfa7b7 26-Feb-2015 xinhe <xinhe@google.com> break missing for P2P_CONNECTION_CHANGED

Bug:19517516
Change-Id: I4368b81b8e757c7223f686070ecdbb0be312a191
om/android/server/wifi/WifiStateMachine.java
80d14d67a956e6c69433470aaa73100898166efa 24-Feb-2015 xinhe <xinhe@google.com> country code setting broken

On branch xin_country_code_opt

Bug:19462483
Change-Id: I18ff2d4d5dc16049386d1e60b82da13a97bb887f
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
751c5a4496b6f90656eb24caa35f584d8976063d 24-Feb-2015 Jan Nordqvist <jannq@google.com> Introduce ANQP cache.

Change-Id: Id9bf948ef4aa810b0c2606bd1b0010a43ee564d7
om/android/server/wifi/hotspot2/AnqpCache.java
77f2b82a2e80af8da52c22d69a76def6d4209757 14-Feb-2015 Jan Nordqvist <jannq@google.com> Integrate passpoint with existing Wifi infrastructure

This change hooks passpoint with rest of the wifi infrastructure.

It includes changes related to passing ANQP and other passpoint
information along with scan results and various fixes to parsing
and selection logic.

Change-Id: Id15ef1aea65dedab3e8e3df0c8a7515974c94021
om/android/server/wifi/ScanDetail.java
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/anqp/ANQPFactory.java
om/android/server/wifi/anqp/CapabilityListElement.java
om/android/server/wifi/anqp/CivicLocationElement.java
om/android/server/wifi/anqp/Constants.java
om/android/server/wifi/anqp/DomainNameElement.java
om/android/server/wifi/anqp/EmergencyNumberElement.java
om/android/server/wifi/anqp/GEOLocationElement.java
om/android/server/wifi/anqp/HSCapabilityListElement.java
om/android/server/wifi/anqp/HSConnectionCapabilityElement.java
om/android/server/wifi/anqp/HSFriendlyNameElement.java
om/android/server/wifi/anqp/HSIconFileElement.java
om/android/server/wifi/anqp/HSOsuProvidersElement.java
om/android/server/wifi/anqp/HSWanMetricsElement.java
om/android/server/wifi/anqp/IPAddressTypeAvailabilityElement.java
om/android/server/wifi/anqp/NAIRealmElement.java
om/android/server/wifi/anqp/NetworkAuthenticationTypeElement.java
om/android/server/wifi/anqp/RoamingConsortiumElement.java
om/android/server/wifi/anqp/ThreeGPPNetworkElement.java
om/android/server/wifi/anqp/VenueNameElement.java
om/android/server/wifi/anqp/eap/EAPMethod.java
om/android/server/wifi/hotspot2/ANQPData.java
om/android/server/wifi/hotspot2/AlarmHandler.java
om/android/server/wifi/hotspot2/Chronograph.java
om/android/server/wifi/hotspot2/NetworkDetail.java
om/android/server/wifi/hotspot2/NetworkInfo.java
om/android/server/wifi/hotspot2/PasspointMatchInfo.java
om/android/server/wifi/hotspot2/SelectionManager.java
om/android/server/wifi/hotspot2/SupplicantBridge.java
om/android/server/wifi/hotspot2/Utils.java
om/android/server/wifi/hotspot2/omadm/MOManager.java
om/android/server/wifi/hotspot2/omadm/OMAConstructed.java
om/android/server/wifi/hotspot2/pps/Credential.java
om/android/server/wifi/hotspot2/pps/DomainMatcher.java
om/android/server/wifi/hotspot2/pps/HomeSP.java
om/android/server/wifi/hotspot2/simulate/HS20Simulator.java
03e92b925a595a1a467290a2d54ca2602cce9b9e 18-Feb-2015 Vinit Deshpande <vinitd@google.com> Passpoint API - Take 1

Added some common fields to WifiConfigurations; which
should be used with WifiEnterpriseConfig. The network
information is saved in a file.

Change-Id: Ica2069900dfc373e14792cbe81a185586e2954cc
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/hotspot2/omadm/MOManager.java
om/android/server/wifi/hotspot2/omadm/MOTree.java
om/android/server/wifi/hotspot2/pps/Credential.java
om/android/server/wifi/hotspot2/pps/HomeSP.java
b8cb150b17b7453d240bbbeb02a0a74353b11b23 07-Nov-2014 Honore Tricot <honorex.tricot@intel.com> EAP-SIM: handle dynamic identity request

Manage the identity creation based on IMSI and 3gpp realm

Change-Id: I4e9c9e23886729592af941d11c798f2583444925
Signed-off-by: Honore Tricot <honorex.tricot@intel.com>
Signed-off-by: Abdelmajid MLAYEH <abdelmajidx.mlayeh@intel.com>
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
d4762401ec14be6bdd2d27aff2478ddbf8d6ce2a 12-Aug-2014 Vinit Deshpande <vinitd@google.com> Introduce onLost event on bssid hotlist [DO NOT MERGE]

Change-Id: I84c3174398fea9a1456fb007586c2c559dd3fe4d
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiScanningServiceImpl.java
1ef80d73f9bee7ef12d3e2d4e0aef11239bba87c 14-Feb-2015 Navtej Singh Mann <navtejsingh@google.com> updated number of default scan to cache

bug: 19354967
Change-Id: Id411529f9bb4aa98975cac64b6bd0bf886f38bdc
om/android/server/wifi/WifiScanningServiceImpl.java
b830d76fbf5fa4077531b516066faa2fdbb92e81 12-Feb-2015 xinhe <xinhe@google.com> Unable to see Tethering/portable Hotspot SSID

Bug:19335638
Change-Id: I4b889841b341d3d9b24faab8bc5dd18b508070cd
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
826282265badbd85c5386573fbced1755696fe83 05-Feb-2015 xinhe <xinhe@google.com> get channel list from driver for SoftAP channel selection

Instead of hard coding the available channel list, we should
get channel list from driver

Bug:19237543
Change-Id: Ibe1fbbdc39a6cf69a0b36cfb9c6b63025d0b914d
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
2b26ad17b41b6cc7c5663aa47a66239cf698794f 05-Feb-2015 Navtej Singh Mann <navtejsingh@google.com> Updating scan status after scan for full scan result completed

Bug: 19099878
Change-Id: Ie63498995d5b92d05231a1481643ee009b47865e
om/android/server/wifi/WifiScanningServiceImpl.java
e7c2a0e042faf1e617771d19b5055046658889a3 05-Feb-2015 Pierre Vandwalle <vandwalle@google.com> send network state changed broadcast when BSSID change

Change-Id: I1920d8656a9db0aead90787b5049106a5e7ab538
om/android/server/wifi/WifiStateMachine.java
faa2ce7f93eef2c436796fb1ea3574e2d1412491 23-Jan-2015 Robin Lee <rgl@google.com> Remove wifi configs when secondary user is deleted

If any WiFi configs have been created for a secondary user then these
should be cleaned up when the user is deleted from Settings.

Bug: 18927999
Change-Id: If4a37085f1b82f30e5f4b44c7f597f4b2d620501
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
0465ff513cdccf7e883a505e14c5b78758e7e458 13-Oct-2014 Vinit Deshpande <vinitd@google.com> Enable DFS

Change-Id: I4a9bc8d6587063388ee763fe31e669cddcad24d0
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
e0a4f90efb6b6e42c1ece5b4a0c9831770f2f7aa 28-Jan-2015 Jan Nordqvist <jannq@google.com> Added a comment.

Change-Id: Ief2e4d0222dab3187c11a8cfdaee7d1236418fa1
om/android/server/wifi/hotspot2/omadm/SOAPParser.java
eb11746ad0052abd576114bdef5e4fa06d17442b 31-Jan-2015 Vinit Deshpande <vinitd@google.com> Merge "Credential/profile storage added, completed network matching and added HS20 Simulator." into m-wireless-wifi-dev
71a988c8e9859244b83cd55bb6b6ee913fcaf95c 28-Jan-2015 Jan Nordqvist <jannq@google.com> Credential/profile storage added, completed network matching and added HS20 Simulator.

Change-Id: I1b27dadf3d65ed0a858dee209df975180a3b90e6
om/android/server/wifi/anqp/CellularNetwork.java
om/android/server/wifi/anqp/Constants.java
om/android/server/wifi/anqp/GenericBlobElement.java
om/android/server/wifi/anqp/NAIRealmData.java
om/android/server/wifi/anqp/RoamingConsortiumElement.java
om/android/server/wifi/anqp/ThreeGPPNetworkElement.java
om/android/server/wifi/anqp/eap/Credential.java
om/android/server/wifi/anqp/eap/EAPMethod.java
om/android/server/wifi/anqp/eap/ExpandedEAPMethod.java
om/android/server/wifi/anqp/eap/InnerAuthEAP.java
om/android/server/wifi/anqp/eap/NonEAPInnerAuth.java
om/android/server/wifi/hotspot2/ANQPData.java
om/android/server/wifi/hotspot2/AuthMatch.java
om/android/server/wifi/hotspot2/NetworkInfo.java
om/android/server/wifi/hotspot2/NetworkKey.java
om/android/server/wifi/hotspot2/PasspointMatch.java
om/android/server/wifi/hotspot2/SelectionManager.java
om/android/server/wifi/hotspot2/Utils.java
om/android/server/wifi/hotspot2/omadm/MOManager.java
om/android/server/wifi/hotspot2/omadm/MOTree.java
om/android/server/wifi/hotspot2/omadm/NodeAttribute.java
om/android/server/wifi/hotspot2/omadm/OMAConstants.java
om/android/server/wifi/hotspot2/omadm/OMAConstructed.java
om/android/server/wifi/hotspot2/omadm/OMAException.java
om/android/server/wifi/hotspot2/omadm/OMANode.java
om/android/server/wifi/hotspot2/omadm/OMAParser.java
om/android/server/wifi/hotspot2/omadm/OMAScalar.java
om/android/server/wifi/hotspot2/omadm/RequestDetail.java
om/android/server/wifi/hotspot2/omadm/SOAPParser.java
om/android/server/wifi/hotspot2/omadm/XMLNode.java
om/android/server/wifi/hotspot2/pps/Credential.java
om/android/server/wifi/hotspot2/pps/DomainMatcher.java
om/android/server/wifi/hotspot2/pps/HomeSP.java
om/android/server/wifi/hotspot2/simulate/HS20Simulator.java
3cc14e1d5f379d855570175840de13922ae6af60 30-Jan-2015 Vinit Deshpande <vinitd@google.com> Merge "A few more bug fixes and addition of Icon and Home realm queries." into m-wireless-wifi-dev
2bfb487edfe1efcc1d8ec21d34b0aa74e422c527 30-Jan-2015 Vinit Deshpande <vinitd@google.com> Merge changes Ia8c19509,I88c6253c,I9ae5eb0d into m-wireless-wifi-dev

* changes:
Fixed a couple of inconsistencies around method length.
Bug fixes after test run. First pass all OK.
Base Hotspot 2.0 code (moved from base).
b4536bc5963dec0b2a6ae0ece3518a62e8aff87f 29-Jan-2015 vandwalle <vandwalle@google.com> am e828e7a7: am 4fa99f57: aggressively blacklist WifiConfiguration for the purpose of switching network

* commit 'e828e7a7f186e57c7709fc30eb6e8dcb5fadab0b':
aggressively blacklist WifiConfiguration for the purpose of switching network
4fa99f57077ab287d6ed1b51cf308c44ce8bbe0b 11-Jan-2015 vandwalle <vandwalle@google.com> aggressively blacklist WifiConfiguration for the purpose of switching network

In cases where networks are not properly configured, WiFi might tries to repeatdly
switch from one network to a bad network, or might try to roam and renew DHCP which can fail.
In KK, WiFi autojoin would try other networks (by cycling to network it sees) and
end up associated to a "good" network. In L release even thought WiFi might pick
a good network it will still repeatedly try to switch to what it thinks is a better
network and fail, thus annoying the user whose connection becomes unstable.

This CL tries to remember networks that have seen multiple DHCP or auth failure in
the past and for those networks it disable roaming temporarily.
That is, if wifi is not associated to any network, it will tries to join a network
aggressively, however if wifi is currently associated to a network, it will not try
to switch to a new network if that new network has seen multiple failure in the past.

The maximum blacklist time is set to 2 days for now.
An example of such situation is:
- user has multiple SSID at home, one of which is incorrectly configured with a wrong password
- broken DHCP situation (potentially: multiple servers on home network, broken implementation incorrecting NAK'ing DHCP requests but properly serving DHCP offer...)
Bug:18792931

Change-Id: Ib09eaaea978c772f630e86696f9a49f18ad708e2
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiStateMachine.java
7b2caa25fb57f2d95e0d0421704c49d3af4b8e6f 23-Jan-2015 Jan Nordqvist <jannq@google.com> A few more bug fixes and addition of Icon and Home realm queries.

Change-Id: I31056c1c6246aafa2f4de106c805d773d67d7731
om/android/server/wifi/anqp/ANQPFactory.java
om/android/server/wifi/anqp/Constants.java
om/android/server/wifi/anqp/HSIconFileElement.java
om/android/server/wifi/anqp/HSWanMetricsElement.java
om/android/server/wifi/anqp/NAIRealmData.java
om/android/server/wifi/anqp/NAIRealmElement.java
om/android/server/wifi/anqp/OSUProvider.java
om/android/server/wifi/anqp/RoamingConsortiumElement.java
om/android/server/wifi/anqp/TestDriver.java
om/android/server/wifi/anqp/eap/Credential.java
om/android/server/wifi/anqp/eap/EAPMethod.java
om/android/server/wifi/anqp/eap/ExpandedEAPMethod.java
om/android/server/wifi/anqp/eap/InnerAuthEAP.java
om/android/server/wifi/anqp/eap/NonEAPInnerAuth.java
om/android/server/wifi/anqp/eap/VendorSpecificAuth.java
14aadf3997f007f53f12e8bec3efaea1a66b44bd 23-Jan-2015 Navtej Singh Mann <navtejsingh@google.com> Fix getScanResults API call for fetching the scan results

Bug: 19110489
Change-Id: I2f31c9cebe05f322535fd1001b10782eea95dcad
om/android/server/wifi/WifiScanningServiceImpl.java
3be1b3fc037bef7fb4448dec89aea3f2e1318853 23-Jan-2015 Jan Nordqvist <jannq@google.com> Fixed a couple of inconsistencies around method length.

Change-Id: Ia8c19509ad6c48ceeeec44e81025a2418bab2a5a
om/android/server/wifi/anqp/eap/Credential.java
om/android/server/wifi/anqp/eap/EAP.java
om/android/server/wifi/anqp/eap/EAPMethod.java
om/android/server/wifi/anqp/eap/ExpandedEAPMethod.java
om/android/server/wifi/anqp/eap/InnerAuthEAP.java
om/android/server/wifi/anqp/eap/NonEAPInnerAuth.java
om/android/server/wifi/anqp/eap/VendorSpecificAuth.java
777f4fc037d3ebd555f10041f8acfb41515b2f4b 23-Jan-2015 Jan Nordqvist <jannq@google.com> Bug fixes after test run. First pass all OK.

Change-Id: I88c6253c44ecceb574b9afb57934bc492eb13c4c
om/android/server/wifi/anqp/ANQPFactory.java
om/android/server/wifi/anqp/Constants.java
om/android/server/wifi/anqp/GEOLocationElement.java
om/android/server/wifi/anqp/HSCapabilityListElement.java
om/android/server/wifi/anqp/OSUProvider.java
om/android/server/wifi/anqp/TestDriver.java
om/android/server/wifi/anqp/VenueNameElement.java
om/android/server/wifi/anqp/eap/Credential.java
om/android/server/wifi/anqp/eap/EAPMethod.java
om/android/server/wifi/anqp/eap/ExpandedEAPMethod.java
om/android/server/wifi/anqp/eap/InnerAuthEAP.java
om/android/server/wifi/anqp/eap/NonEAPInnerAuth.java
6a3903fed590e369b576bddbe1ae2d788768ddfe 23-Jan-2015 Jan Nordqvist <jannq@google.com> Base Hotspot 2.0 code (moved from base).

Change-Id: I9ae5eb0d6ff2cd15c73deaf239465353ab1ee90c
om/android/server/wifi/anqp/ANQPElement.java
om/android/server/wifi/anqp/ANQPFactory.java
om/android/server/wifi/anqp/CapabilityListElement.java
om/android/server/wifi/anqp/CivicLocationElement.java
om/android/server/wifi/anqp/Constants.java
om/android/server/wifi/anqp/DomainNameElement.java
om/android/server/wifi/anqp/EmergencyNumberElement.java
om/android/server/wifi/anqp/GEOLocationElement.java
om/android/server/wifi/anqp/GenericBlobElement.java
om/android/server/wifi/anqp/GenericStringElement.java
om/android/server/wifi/anqp/HSCapabilityListElement.java
om/android/server/wifi/anqp/HSConnectionCapabilityElement.java
om/android/server/wifi/anqp/HSFriendlyNameElement.java
om/android/server/wifi/anqp/HSIconFileElement.java
om/android/server/wifi/anqp/HSOsuProvidersElement.java
om/android/server/wifi/anqp/HSWanMetricsElement.java
om/android/server/wifi/anqp/I18Name.java
om/android/server/wifi/anqp/IPAddressTypeAvailabilityElement.java
om/android/server/wifi/anqp/IconInfo.java
om/android/server/wifi/anqp/NAIRealmData.java
om/android/server/wifi/anqp/NAIRealmElement.java
om/android/server/wifi/anqp/NetworkAuthenticationTypeElement.java
om/android/server/wifi/anqp/OSUProvider.java
om/android/server/wifi/anqp/RoamingConsortiumElement.java
om/android/server/wifi/anqp/ThreeGPPNetworkElement.java
om/android/server/wifi/anqp/VenueNameElement.java
om/android/server/wifi/anqp/eap/AuthParam.java
om/android/server/wifi/anqp/eap/Credential.java
om/android/server/wifi/anqp/eap/EAP.java
om/android/server/wifi/anqp/eap/EAPMethod.java
om/android/server/wifi/anqp/eap/ExpandedEAPMethod.java
om/android/server/wifi/anqp/eap/InnerAuthEAP.java
om/android/server/wifi/anqp/eap/NonEAPInnerAuth.java
om/android/server/wifi/anqp/eap/VendorSpecificAuth.java
om/android/server/wifi/hotspot2/ANQPData.java
om/android/server/wifi/hotspot2/NetworkInfo.java
om/android/server/wifi/hotspot2/NetworkKey.java
om/android/server/wifi/hotspot2/PasspointMatch.java
om/android/server/wifi/hotspot2/SelectionManager.java
om/android/server/wifi/hotspot2/pps/DomainMatcher.java
om/android/server/wifi/hotspot2/pps/HomeSP.java
0e8f0d87d62589d9dda54d5a4941d0309e3ecf2a 08-Jan-2015 xinhe <xinhe@google.com> set softAP on a specified band, including both 2.4 and 5 GHz band

Bug:18929692
Change-Id: Ie51e09901fbb2c3bec3d4780d0ec49819f808b4e
om/android/server/wifi/WifiApConfigStore.java
2e53cbdfeb11c86efea51581b8c5645eff8b1fd5 16-Jan-2015 vandwalle <vandwalle@google.com> am 2f404382: am 80aa8fb1: Merge "prevent null BSSID being inject as scan results Bug:18917134" into lmp-mr1-dev

* commit '2f404382dc1deee76b00d0d03cad2fdf74d543ce':
prevent null BSSID being inject as scan results Bug:18917134
80aa8fb1a21a6df522235287d7b6835cc46310e2 16-Jan-2015 vandwalle <vandwalle@google.com> Merge "prevent null BSSID being inject as scan results Bug:18917134" into lmp-mr1-dev
17cfedf44f00d090553db145cd9749f920096055 15-Jan-2015 Vinit Deshpande <vinitd@google.com> am c9f3c26e: am 9572797c: Merge "Fix an NPE in WifiConfigStore" into lmp-mr1-dev

* commit 'c9f3c26ea33c7f065aa9e3692330bc40befcfb56':
Fix an NPE in WifiConfigStore
9572797c3061128bc8f6654854782b61d1b8c71b 14-Jan-2015 Vinit Deshpande <vinitd@google.com> Merge "Fix an NPE in WifiConfigStore" into lmp-mr1-dev
2f05eff93e2503c9f29a0d7ede62c71c430ccf5f 12-Jan-2015 vandwalle <vandwalle@google.com> prevent null BSSID being inject as scan results
Bug:18917134

Change-Id: I0c4d0a2bd5383bac473a588af89589bf70f47c6c
om/android/server/wifi/WifiStateMachine.java
15bdc5956c2d949e4ea549586903bae87134d8da 13-Jan-2015 Erik Kline <ek@google.com> am d593afb2: am e98d4c27: Merge "Disconnect if we had IPv4 and lost it." into lmp-mr1-dev

* commit 'd593afb2ed618cf456c53a27f18dcf68a92abd8a':
Disconnect if we had IPv4 and lost it.
03cdd624f5da6d62cb731304aa7505921566f69d 08-Jan-2015 Dmitry Shmidt <dimitrysh@google.com> wifi: Use 'set setband' instead of private 'driver setband' [DO NOT MERGE]

Bug: 18936523

Change-Id: Idb12feb5d7dc925f63de4ab57391f5cdd35b8719
Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
om/android/server/wifi/WifiNative.java
e98d4c2729d25123d6b6063e8f1b05e9ce3ca0da 13-Jan-2015 Erik Kline <ek@google.com> Merge "Disconnect if we had IPv4 and lost it." into lmp-mr1-dev
e91eb1bc706fecb97407c00e21d32b1edb56dc88 02-Jan-2015 Vinit Deshpande <vinitd@google.com> Bring in passpoint code [DO NOT MERGE]

This change brings in all the passpoint code from master
to here - so that all development can be done with partners

Change-Id: I9185c35c69630ffb9b4313f973893996051075ed
om/android/server/wifi/passpoint/WifiPasspointCertificate.java
om/android/server/wifi/passpoint/WifiPasspointCertificateHelper.java
om/android/server/wifi/passpoint/WifiPasspointClient.java
om/android/server/wifi/passpoint/WifiPasspointDmClient.java
om/android/server/wifi/passpoint/WifiPasspointDmTreeHelper.java
om/android/server/wifi/passpoint/WifiPasspointHttpClient.java
om/android/server/wifi/passpoint/WifiPasspointService.java
om/android/server/wifi/passpoint/WifiPasspointServiceImpl.java
om/android/server/wifi/passpoint/WifiPasspointSoapClient.java
om/android/server/wifi/passpoint/WifiPasspointStateMachine.java
83a674a18c84ff4f01377bbfd8988699dec93bc2 31-Oct-2014 Vinit Deshpande <vinitd@google.com> New Additions to WifiScanner APIs [DO NOT MERGE]

Added single shot scan, and maxScansToCache. Also fixed getScanResults()
to report scan results to listeners.

Bug: 18087596
Bug: 17694040
Bug: 18059273

Change-Id: Id623ab9ee2ab89c86a35082279331fa609016347
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiScanningServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
537324a497615d07b67ba4582e9aaababd77afd6 09-Jan-2015 Vinit Deshpande <vinitd@google.com> Fix an NPE in WifiConfigStore

Disabling an invalid configuration causes Wifi service
to crash. This change gaurds against bad API call.

Bug: 18904771
Change-Id: I8d853b754cbd4163c17f3d53bf81dc7625c95466
om/android/server/wifi/WifiConfigStore.java
0d5bb1b491f38f6895d99b329936e94639de9a5d 09-Jan-2015 Dmitry Shmidt <dimitrysh@google.com> Merge "wifi: Use 'set setband' instead of private 'driver setband'"
6392b2489fab57547b90443caf0da788db195155 08-Jan-2015 Dmitry Shmidt <dimitrysh@google.com> wifi: Use 'set setband' instead of private 'driver setband'

Bug: 18936523

Change-Id: Idb12feb5d7dc925f63de4ab57391f5cdd35b8719
Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
om/android/server/wifi/WifiNative.java
be4f95bf89f0e22aa6ff39f0398fbedce3ef51a6 08-Jan-2015 Jeff Davidson <jpd@google.com> am 7da9e5b9: am 2c9b6297: Fix incorrect tracking of ephemeral network statistics.

* commit '7da9e5b99176d1b4eb05b39301a625f98ec0e834':
Fix incorrect tracking of ephemeral network statistics.
2c9b6297f3cd74780a084634320d03a413a3b779 08-Jan-2015 Jeff Davidson <jpd@google.com> Fix incorrect tracking of ephemeral network statistics.

The lastUntrustedBSSID variable was being used as an SSID, not a
BSSID, and was not cleared after the untrusted network was
disconnected, causing stats not to increment on new connections if the
last connection was to the same SSID.

So, remove this unnecessary variable, and check the current
WifiConfiguration to determine which network we're currently using, if
any. Increment the connection count only when we are actually going to
associate with the SSID.

This only affects untrusted network flows and should have no impact
when connecting to saved Wi-Fi networks. The only non-statistical
change involves the boost given to the active network, which is
controlled by the NetworkScorer and can be updated dynamically
(outside of the framework).

Bug: 18908655
Change-Id: I5b712a4ff613d8199d0591e568886be0d2419645
om/android/server/wifi/WifiAutoJoinController.java
ac9667902d52ef3efdb53125080419fbbdc7ba80 07-Jan-2015 Erik Kline <ek@google.com> Disconnect if we had IPv4 and lost it.

More specifically, the DHCP_FAILURE case is entered when a
DHCPv4 RENEW fails. Even though we would connect to a network with
no IPv4, when roaming to a "same network" and losing IPv4 it's
probably better to disconnect and start afresh.

Bug: 18867306
Change-Id: Ie667b4f0481ae0510d0dc00db819f4e5d43d98a9
om/android/server/wifi/WifiStateMachine.java
97f6c1c10eef560abd8843282bb6de60d8b499f2 06-Jan-2015 Jeff Davidson <jpd@google.com> am 938e29e7: am 1456ea5d: Merge "Split untrusted NetworkFactory from regular one." into lmp-mr1-dev

* commit '938e29e7c973cb209904e78f2a73f503fa2984c9':
Split untrusted NetworkFactory from regular one.
1456ea5d08ed5a4e697b58ededde4b5a90809d76 06-Jan-2015 Jeff Davidson <jpd@google.com> Merge "Split untrusted NetworkFactory from regular one." into lmp-mr1-dev
e01c64d3cef3561489915a59c756b505690bb7a9 06-Jan-2015 vandwalle <vandwalle@google.com> am 84d31d03: am 104a9803: Keep AutoJoin enabled when user has manually selected a network Bug:18865214

* commit '84d31d03871672ca4ca28c5c8df33d9710d70163':
Keep AutoJoin enabled when user has manually selected a network Bug:18865214
104a9803187593ab25d3784b420077022686dbe4 29-Dec-2014 vandwalle <vandwalle@google.com> Keep AutoJoin enabled when user has manually selected a network
Bug:18865214

Change-Id: Iae9297cd50ebaf12217d12e4c5d55ae05316e917
om/android/server/wifi/WifiStateMachine.java
ebe870ef4051da2fc307114ed3c14927f548d9d4 20-Dec-2014 Jeff Davidson <jpd@google.com> Split untrusted NetworkFactory from regular one.

This ensures that we see all requests for untrusted networks.

Bug: 18815795
Change-Id: I9aaba6095b934fee27a27b20fa3adb2a10648e80
om/android/server/wifi/WifiStateMachine.java
40b037205b28f5a257f0f690a0c39001ffabebfb 19-Dec-2014 vandwalle <vandwalle@google.com> am e25ab227: am e0230c82: Merge "add debug logs to confirm network flapping issue is fixed Bug:18706288" into lmp-mr1-dev

* commit 'e25ab227ca1c9f660dc5b464e28dbe01545a469d':
add debug logs to confirm network flapping issue is fixed Bug:18706288
d562af2fda024c8285d9ca71a1156895b544006c 19-Dec-2014 vandwalle <vandwalle@google.com> am 32ae34b1: am 84070068: Merge "Disable legacy poor Network detection Bug:18723206 Legacy poor network detection was removed from L settings but can still be enabled during an upgrade if it had been manually enabled by user, now really disable it." into lmp-mr1-dev

* commit '32ae34b138ae205e52d16c59ad4a20091de91a66':
Disable legacy poor Network detection Bug:18723206 Legacy poor network detection was removed from L settings but can still be enabled during an upgrade if it had been manually enabled by user, now really disable it.
e0230c8236956c2098e13a0ea837f33ac3ce11ea 18-Dec-2014 vandwalle <vandwalle@google.com> Merge "add debug logs to confirm network flapping issue is fixed Bug:18706288" into lmp-mr1-dev
84070068b0aff877437f4ecbcac8b6f4fe976d32 18-Dec-2014 vandwalle <vandwalle@google.com> Merge "Disable legacy poor Network detection Bug:18723206 Legacy poor network detection was removed from L settings but can still be enabled during an upgrade if it had been manually enabled by user, now really disable it." into lmp-mr1-dev
b95dffce003c523a7b3152a4885fed693546d3e0 18-Dec-2014 Narayan Kamath <narayan@google.com> Remove apache-http use from wifi passpoint code.

Apart from the various open questions about turning of
hostname verification etc, the only big TODO here is how
we should deal with HTTP authentication. It isn't clear what
the spec or standards expect. Basic auth is already supported,
but Digest auth needs a little bit of work to support out of
the box.

bug: 18027885

Change-Id: Ia696ac4e85f8e55e3b9b12310411a7f6639f94ad
om/android/server/wifi/passpoint/WifiPasspointCertificate.java
om/android/server/wifi/passpoint/WifiPasspointHttpClient.java
om/android/server/wifi/passpoint/WifiPasspointSoapClient.java
f57f8918b8c5872ff4bb141fa9e407bec8442e8d 16-Dec-2014 vandwalle <vandwalle@google.com> add debug logs to confirm network flapping issue is fixed
Bug:18706288

Change-Id: I27a86aeb650a63511b667244b0138afbc1bc059e
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiStateMachine.java
0a432eea06b32248839bd314288338f254a0c58f 17-Dec-2014 Jeff Davidson <jpd@google.com> am a4792dde: am 16fdf070: Stabilize ephemeral connections in the face of new BSSIDs.

* commit 'a4792ddeff09238c268f4685201d34a9942c3b3e':
Stabilize ephemeral connections in the face of new BSSIDs.
16fdf07021858fd116d96a5fb00ddb3c166d5ae6 05-Dec-2014 Jeff Davidson <jpd@google.com> Stabilize ephemeral connections in the face of new BSSIDs.

Currently we only check whether the most recently seen BSSID has a
score before deciding to disconnect an ephemeral network. This causes
unnecessary flapping - if multiple BSSIDs are in visible range, and
the scorer likes one of them but has no score for the other (or is
still looking up the score), we will drop the connection.

Instead, as long as we've recently seen a scored BSSID (in the last
minute), we keep the connection alive.

A scorer can still initiate an immediate disconnect from an unwanted
network by nulling scores for all BSSIDs.

The timeout (and whether we use this new behavior at all) is
controlled by a Settings.Global flag.

Bug: 18637384
Change-Id: I6bde3c9eef12caf2cc51c449abffc1c69f60c17f
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiNetworkScoreCache.java
82f9342c26900256a1bf6bef7b40a775116bf57c 12-Dec-2014 vandwalle <vandwalle@google.com> Disable legacy poor Network detection
Bug:18723206
Legacy poor network detection was removed from L settings but can still be enabled during an upgrade if it had been manually enabled by user, now really disable it.

Change-Id: I661b326c6f5dfacfcc5582cea14dc52501740367
om/android/server/wifi/WifiWatchdogStateMachine.java
481e24957680f083af7d235a5bebd678b673b6bd 15-Dec-2014 Vinit Deshpande <vinitd@google.com> Merge changes I8a6da542,I9f51a282,I4a9bc8d6,I84c31743

* changes:
New Additions to WifiScanner APIs
WifiScanner: Fix typo that generates events too quickly
Enable DFS
Introduce onLost event on bssid hotlist
b6077d350d0f9db5b59334956f3d6d1f977a7b94 15-Dec-2014 Jeff Sharkey <jsharkey@android.com> Merge "Use better API for checking UID permission."
611048d11641d9f8136cf2a7065aedbd57095cb9 15-Dec-2014 Jeff Sharkey <jsharkey@android.com> Use better API for checking UID permission.

Avoids crashing system process.

Bug: 18757340
Change-Id: I6b4828be27842496eebb83b4ec4a5e1a25297568
om/android/server/wifi/WifiConfigStore.java
e5cb13ea857a8e419195c5fc22b33146b26dc817 15-Dec-2014 Prem Kumar <premk@google.com> am cab41c14: am 6a0c6896: Merge changes Ieee0b91a,I0093620c into lmp-mr1-dev

* commit 'cab41c14ea42fb652b9cf03d16ee0c70744c74cf':
fix logspam Bug:18589606
Apply 5GHz band preference only when comparing configurations on different bands
f67a8303cbf58f04e0b12fea46387030892010bf 15-Dec-2014 Prem Kumar <premk@google.com> am 01b061ce: am ff8ab9f7: Merge "make sure wificonfiguration scan cache doesnt grow unbounded Bug:18703749" into lmp-mr1-dev

* commit '01b061ce1c3285c2f840673d4253f20cd34e75d8':
make sure wificonfiguration scan cache doesnt grow unbounded Bug:18703749
cb4fcdd41d22ee8733e60aa8ce96f9cbaafeae9f 15-Dec-2014 Prem Kumar <premk@google.com> am 0a9e097e: am 4ff7838d: Merge "autojoin scanning + P2P - discard autojoin scan when both infra and P2P are connected - reduce autojoin scan period when P2P is connected and infra is disconnected Bug:18692653" into lmp-mr1-dev

* commit '0a9e097e3b67bd54d1c405d93786a80031f71ec6':
autojoin scanning + P2P - discard autojoin scan when both infra and P2P are connected - reduce autojoin scan period when P2P is connected and infra is disconnected Bug:18692653
7ba3d8532fbd7e799f29f87951c39ea12e1a3262 15-Dec-2014 Prem Kumar <premk@google.com> am a8cfeb7a: am e9775238: Merge "handle beacons reported with wrong RSSI value of 0 Bug:18654243" into lmp-mr1-dev

* commit 'a8cfeb7a685aa0870aa5bb29afe1cebb3cea93fd':
handle beacons reported with wrong RSSI value of 0 Bug:18654243
6a0c6896aa7f72744f8b3d65b3dcc7ea0c063bc7 14-Dec-2014 Prem Kumar <premk@google.com> Merge changes Ieee0b91a,I0093620c into lmp-mr1-dev

* changes:
fix logspam Bug:18589606
Apply 5GHz band preference only when comparing configurations on different bands
ff8ab9f723c8ecf04aedfc3102676ab498cb14fb 14-Dec-2014 Prem Kumar <premk@google.com> Merge "make sure wificonfiguration scan cache doesnt grow unbounded Bug:18703749" into lmp-mr1-dev
4ff7838d595d2be641da1892507d3333707291e2 14-Dec-2014 Prem Kumar <premk@google.com> Merge "autojoin scanning + P2P - discard autojoin scan when both infra and P2P are connected - reduce autojoin scan period when P2P is connected and infra is disconnected Bug:18692653" into lmp-mr1-dev
e97752385ec67e72f8ae7a772eb7af3014266ace 14-Dec-2014 Prem Kumar <premk@google.com> Merge "handle beacons reported with wrong RSSI value of 0 Bug:18654243" into lmp-mr1-dev
c591ab3b5ff4ac8dade1c7eb88ec83f3572f999b 31-Oct-2014 Vinit Deshpande <vinitd@google.com> New Additions to WifiScanner APIs

Added single shot scan, and maxScansToCache. Also fixed getScanResults()
to report scan results to listeners.

Bug: 18087596
Bug: 17694040
Bug: 18059273

Change-Id: I8a6da5426561e22e72d1e99c5537205b893077dd
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiScanningServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
aa2e127372aea587530601bc9576cb935742d9bf 28-Oct-2014 Vinit Deshpande <vinitd@google.com> WifiScanner: Fix typo that generates events too quickly

Report threshhold used to be 80%, it got changed to 10% in a big
change. Which is likely why we have too early terminations of
batch scans.

This still doesn't explain the reason for long scans though.

Bug: 17905975

Change-Id: I9f51a282645a51d45906d7060093c94ad9886e6c
om/android/server/wifi/WifiScanningServiceImpl.java
90b902d2b5c02af02edd7e60f385196af8823128 13-Oct-2014 Vinit Deshpande <vinitd@google.com> Enable DFS

This change enables DFS channels on the underlying device
if background scanning features (GScan features) are supported.

Change-Id: I4a9bc8d6587063388ee763fe31e669cddcad24d0
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
e9fa5dcd292f2b8bad2c567773c74a1568c513ad 12-Aug-2014 Vinit Deshpande <vinitd@google.com> Introduce onLost event on bssid hotlist

Change-Id: I84c3174398fea9a1456fb007586c2c559dd3fe4d
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiScanningServiceImpl.java
664e639fac1d77ac142845f8920b9478db02c0d1 12-Dec-2014 Vinit Deshpande <vinitd@google.com> am 1ed3619a: am ca98d25a: Merge "Fix an unhandled exception in WifiP2pStateMachine" into lmp-mr1-dev

* commit '1ed3619a94c42879941e714248ccd4abb3bc8b8a':
Fix an unhandled exception in WifiP2pStateMachine
acb5ebbeedbd9a206e2ed82de3a365ceedb27d0c 10-Dec-2014 vandwalle <vandwalle@google.com> fix logspam
Bug:18589606

Change-Id: Ieee0b91ab96ec9392a9b91ac1017a319605425dc
om/android/server/wifi/WifiConfigStore.java
63105d275289943504a292de18e6516e79b15148 10-Dec-2014 vandwalle <vandwalle@google.com> make sure wificonfiguration scan cache doesnt grow unbounded
Bug:18703749

Change-Id: If6452e7dbaaabb164cf2a99b48b3964f4cb86ee5
om/android/server/wifi/WifiConfigStore.java
815788ba7838fc54310baed3deb9b95548e0ce69 11-Dec-2014 vandwalle <vandwalle@google.com> Apply 5GHz band preference only when comparing configurations on different bands

Bug:18589301

Change-Id: I0093620c859940d993c9ea60d9d6cdc86bb2fa58
om/android/server/wifi/WifiAutoJoinController.java
a1c02f0a73ee35e198e2652cd65b8830a163d9dd 10-Dec-2014 vandwalle <vandwalle@google.com> autojoin scanning + P2P
- discard autojoin scan when both infra and P2P are connected
- reduce autojoin scan period when P2P is connected and infra is disconnected
Bug:18692653

Change-Id: Id1891e6a9f2863d8876915cfefd158fb1712b8fe
om/android/server/wifi/WifiStateMachine.java
ca98d25affbc5bc948bf1f9a597a346cf347f27a 11-Dec-2014 Vinit Deshpande <vinitd@google.com> Merge "Fix an unhandled exception in WifiP2pStateMachine" into lmp-mr1-dev
895761ea1de67d382964e381982e59aeea6546a7 11-Dec-2014 vandwalle <vandwalle@google.com> am abd4fa77: am 93a1fdde: adjust network switching thresholds Bug:18589301

* commit 'abd4fa7731235cc3e0df0a2f96f68ea981def0aa':
adjust network switching thresholds Bug:18589301
8ccabb81ad304b80dc8eaa162fd322643461529b 10-Dec-2014 vandwalle <vandwalle@google.com> handle beacons reported with wrong RSSI value of 0
Bug:18654243

Change-Id: Ied2fbc87c7effc23fecb68e9863153d63c0cfba4
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
93a1fddee50a244d31036cddae6b7db6630fd93d 07-Dec-2014 vandwalle <vandwalle@google.com> adjust network switching thresholds
Bug:18589301

Change-Id: Ifa2ae05620207798d24e5e196ff522a71fc0fd48
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
623351a7eb0a8df0ac50e7a8e1b57d5f31aab386 10-Dec-2014 Jason Monk <jmonk@google.com> am 9119b44c: am 88c9369c: Merge "Allow interact-users-full access to scan results" into lmp-mr1-dev

* commit '9119b44c0bc372b00b0395c585dd7dce5d674984':
Allow interact-users-full access to scan results
5ced0cedc941433da1e73e256138feba621fe7b5 10-Dec-2014 Prem Kumar <premk@google.com> am e3f48c70: am 4724608d: Merge changes I0d49fa29,I0acacd3f into lmp-mr1-dev

* commit 'e3f48c70338438ddcf9542b92032e966f84ca5a3':
rework scan logic so as to make use of delayed messages instead of scan alarm
reenable disabled config after a few minutes
03ffb1fd6ac5c8791e993b8a7864824a5660f63d 10-Dec-2014 Jeff Davidson <jpd@google.com> am d3a842ad: am a63fbdbb: Merge "- keep track of ephemeral configurations that are deleted by user - make sure we cleaned up prior ephemeral WiFiconfiguration from wpa_supplicant.conf Bug:18525241" into lmp-mr1-dev

* commit 'd3a842ad0052903fe94b745630dc20cb70ea4058':
- keep track of ephemeral configurations that are deleted by user - make sure we cleaned up prior ephemeral WiFiconfiguration from wpa_supplicant.conf Bug:18525241
84befe36af491f26ae46243017a1aca4dd5b24d5 09-Dec-2014 Vinit Deshpande <vinitd@google.com> Fix an unhandled exception in WifiP2pStateMachine

An exception is thrown when group creation is deemed failed. It is
thrown because an empty peer address is encountered. It is not clear
when the address goes empty (there are no logs); but this change
would prevent resstarting of the framework.

Bug: 18667239

Change-Id: I523646eaa1ff6c8dab9ee99b893ebc4291eee2da
om/android/server/wifi/p2p/WifiP2pServiceImpl.java
88c9369cb6b94c30324893337aa25b1e37a15ff6 08-Dec-2014 Jason Monk <jmonk@google.com> Merge "Allow interact-users-full access to scan results" into lmp-mr1-dev
4724608dce2e37b9c0b260c2c7dcf3161f474df2 06-Dec-2014 Prem Kumar <premk@google.com> Merge changes I0d49fa29,I0acacd3f into lmp-mr1-dev

* changes:
rework scan logic so as to make use of delayed messages instead of scan alarm
reenable disabled config after a few minutes
a63fbdbba96e242280267466b170e311e1f71dc3 06-Dec-2014 Jeff Davidson <jpd@google.com> Merge "- keep track of ephemeral configurations that are deleted by user - make sure we cleaned up prior ephemeral WiFiconfiguration from wpa_supplicant.conf Bug:18525241" into lmp-mr1-dev
8242cc81341c80ab5bc057ffdad99a3a1d95be5c 01-Dec-2014 vandwalle <vandwalle@google.com> rework scan logic so as to make use of delayed messages instead of scan alarm

Bug:18594119
Change-Id: I0d49fa2908d824de6adb125cf862de47f8ba5e91
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiStateMachine.java
abd1740f753ac14e9dec8fced8d3de5059122c2a 05-Dec-2014 vandwalle <vandwalle@google.com> reenable disabled config after a few minutes

This change also loose stale user selection which prevents device to re-join potentially
reenabled configs

Bug:18571727
Change-Id: I0acacd3fb1fbb64a48d0407d7b9e4e5403a93726
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiStateMachine.java
f8704c368e0fee0c7cf7e294d109dece6b72e832 05-Dec-2014 Jason Monk <jmonk@google.com> Allow interact-users-full access to scan results

Allow callers that hold INTERACT_ACROSS_USERS_FULL access to scan
results even if they aren't on the current user.

Bug: 16559573
Change-Id: I27fae71b3cdc1c084777242f21fe4bb692ab7135
om/android/server/wifi/WifiServiceImpl.java
2ce99b40c36ed0352b31aa85d5f9383d5f0506f5 04-Dec-2014 vandwalle <vandwalle@google.com> - keep track of ephemeral configurations that are deleted by user
- make sure we cleaned up prior ephemeral WiFiconfiguration from wpa_supplicant.conf
Bug:18525241

Change-Id: I773cb9b28fe139d1cd5df622619b4a9cf866d6ce
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
1eed8cd5b7a60d9024e2937ee2be602543e1c198 05-Dec-2014 Vinit Deshpande <vinitd@google.com> am 839a47af: am e3939cb4: Read all networks despite message limit of 4096 bytes

* commit '839a47af5b48c487a0af377456e7ceffb3899fb9':
Read all networks despite message limit of 4096 bytes
e3939cb40d9ba3842be105a6e85172dc06e14758 02-Dec-2014 Vinit Deshpande <vinitd@google.com> Read all networks despite message limit of 4096 bytes

This change uses list_network last_id=x form of list_networks to
retrieve all networks saved in the system.

Bug: 18566264
Change-Id: Ie439acd98d39ca32417418944035dcce3068d44b
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiNative.java
c5420c4749f00340820477ebac1bc2bd95747b52 02-Dec-2014 Vinit Deshpande <vinitd@google.com> am 66937154: am 94d2ff04: Merge "Fix an NPE in RttService" into lmp-mr1-dev

* commit '669371548653d8afadd2a727869f14692101dfbe':
Fix an NPE in RttService
94d2ff04bd5a0aaf2a761f15c958034ad54ff5a9 02-Dec-2014 Vinit Deshpande <vinitd@google.com> Merge "Fix an NPE in RttService" into lmp-mr1-dev
b7f4073305a57c4705de7a2c7518865d79f7bbc9 01-Dec-2014 Dianne Hackborn <hackbod@google.com> am 973a14c6: am 935a9c0c: Work on issue #18118255: StateMachine aggressively keeping its own logs...

* commit '973a14c6ec978860dc173225c15894fdb38cc270':
Work on issue #18118255: StateMachine aggressively keeping its own logs...
935a9c0c9e091829ac359a6d99ae3bd69fe9041b 26-Nov-2014 Dianne Hackborn <hackbod@google.com> Work on issue #18118255: StateMachine aggressively keeping its own logs...

...(512KB RAM, 10K objects)

Pull this back to 300 entries on Svelte devices... we also need to reduce
this on non-Svelte devices, but at least right now we desperately need it
fixed on Svelte.

Change-Id: I301bf8a4637c066166a5a69c178d581c072b8dc5
om/android/server/wifi/WifiStateMachine.java
f392c0185c2bea228f89fd42fa4551fa19797e7a 22-Nov-2014 Vinit Deshpande <vinitd@google.com> Fix an NPE in RttService

Bug: 18245283
Change-Id: Ie844353bffcf40baa4db8cad2c18dcc5ffaf5a82
om/android/server/wifi/RttService.java
48a7f5e6dc66c4aae8a12f2d745440b52a11b859 26-Nov-2014 vandwalle <vandwalle@google.com> am ebc42f07: am 0eae6501: Merge "remove dfs channel from location restricted scans" into lmp-mr1-dev

* commit 'ebc42f079714a576e302d228a7278e89bb8bb44d':
remove dfs channel from location restricted scans
304a92524235e70e52023eb9c48bbdb167ebe03f 26-Nov-2014 vandwalle <vandwalle@google.com> am 41ec35fc: am 9f2b1162: register network factory before processing scan results Bug:18512598

* commit '41ec35fc3a0a924a451a2d32b0a4695cd906fe28':
register network factory before processing scan results Bug:18512598
0eae6501fd8144806ab5598bc8e3210f2b18769f 26-Nov-2014 vandwalle <vandwalle@google.com> Merge "remove dfs channel from location restricted scans" into lmp-mr1-dev
5363eb4d62eb9da63021f5b4d07c5ee5d62353b9 26-Nov-2014 vandwalle <vandwalle@google.com> am 8ecac289: am 833dcce8: - dont loose explicitely selected bit when autojoining same network - use scorer only for untrusted networks Bug:18490330 Bug:18368125

* commit '8ecac289ffb059d419a8da62d412641684b748b5':
- dont loose explicitely selected bit when autojoining same network - use scorer only for untrusted networks Bug:18490330 Bug:18368125
9f2b11623eec3b20edc93e30f94b263f287a4ca3 26-Nov-2014 vandwalle <vandwalle@google.com> register network factory before processing scan results
Bug:18512598

Change-Id: I79aa972f686f2c4090012a36dcad13a9e53d5566
om/android/server/wifi/WifiStateMachine.java
9086afccf6938a49eb9a2cd248917c1cb0943942 22-Nov-2014 vandwalle <vandwalle@google.com> remove dfs channel from location restricted scans

Change-Id: I387816c8682e9f595229ecbb20c35711ea1f069b
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
833dcce8f6712f7594f06ea33208e3e106c15afc 23-Nov-2014 vandwalle <vandwalle@google.com> - dont loose explicitely selected bit when autojoining same network
- use scorer only for untrusted networks
Bug:18490330
Bug:18368125

Change-Id: I13f21a2247d071d2e8edc48546c14e0a9e2bc5d6
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiStateMachine.java
faff566684a044cce0da4eab11de79eec964d9fb 21-Nov-2014 Jeff Davidson <jpd@google.com> am 983b8383: Merge "Don\'t enable ephemeral networks when bringing up Wi-Fi." into lmp-mr1-dev automerge: 1a36bf3

* commit '983b8383021303e7a17e9fe72b93b363c5efc8ce':
Don't enable ephemeral networks when bringing up Wi-Fi.
69ca60b59dcaa83a40252615dc11e3bb06f72ee0 20-Nov-2014 vandwalle <vandwalle@google.com> am 98c7b2d0: perform regular autojoin when turning wifi on Bug:18451553 automerge: 68fee36

* commit '98c7b2d0a913c281893b54a43016a66f00006ea1':
perform regular autojoin when turning wifi on Bug:18451553
1a36bf394b991d2b1e4bba0118377a7869f205df 20-Nov-2014 Jeff Davidson <jpd@google.com> Merge "Don't enable ephemeral networks when bringing up Wi-Fi." into lmp-mr1-dev
8d2fd4c1adfb5ab6466d12cbbd21cf6ce9aeddbe 19-Nov-2014 Vinit Deshpande <vinitd@google.com> am bf7ed9bb: am f5a84fcd: Trigger auto-join from WifiManager.reconnect()

* commit 'bf7ed9bbca430d1a38e345240033ad8695611239':
Trigger auto-join from WifiManager.reconnect()
68fee36dac1dda5c596c00ef33fdbc0962e9ec9f 19-Nov-2014 vandwalle <vandwalle@google.com> perform regular autojoin when turning wifi on
Bug:18451553

Change-Id: I729ae360209e852e4e64bed0c584ed076b1281b4
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiStateMachine.java
f5a84fcd66298ee6e96b781d2645422a1571ac07 18-Nov-2014 Vinit Deshpande <vinitd@google.com> Trigger auto-join from WifiManager.reconnect()

Bug: 17397676

Change-Id: I0356c363b90a40a9f9424cf9c50e0d9f1c370414
om/android/server/wifi/WifiStateMachine.java
56686b8275c9e7ec43afdc872893594cb9503d8b 15-Nov-2014 Vinit Deshpande <vinitd@google.com> am fb26896c: Merge "Fix a crash in parsing beacon IEs" into lmp-mr1-dev automerge: fb29a19

* commit 'fb26896cb7b1a39687c5f9dbaa6a71f507c3d80b':
Fix a crash in parsing beacon IEs
4aee7baf77559f7476f21f074cecc08108893eaf 15-Nov-2014 Vinit Deshpande <vinitd@google.com> am 5c1d284b: Merge "Fix connections to unintended networks" into lmp-mr1-dev automerge: 1d1a18d

* commit '5c1d284ba7969107f0b3b6cdb2374623f2458819':
Fix connections to unintended networks
1da241d9e9330e9be2bcbed47bbfa4fbc88e205c 15-Nov-2014 Vinit Deshpande <vinitd@google.com> am ffaf3736: Merge changes I578e0d92,I248695b2 into lmp-mr1-dev automerge: 69f6bd2

* commit 'ffaf3736ec197b62e38d2b248cbed494f4ec70d4':
Handle bad WifiHAL implementation
Don't allow SCAN_REQUEST broadcast to launch apps
fb29a19d6401f75c72be6bacd9171fc974e3b07d 15-Nov-2014 Vinit Deshpande <vinitd@google.com> Merge "Fix a crash in parsing beacon IEs" into lmp-mr1-dev
1d1a18d00e2dfd8b29aee3e3ea48d188c5b630ff 15-Nov-2014 Vinit Deshpande <vinitd@google.com> Merge "Fix connections to unintended networks" into lmp-mr1-dev
69f6bd2ac21ce836de0aa728b887f74addaf8caa 15-Nov-2014 Vinit Deshpande <vinitd@google.com> Merge changes I578e0d92,I248695b2 into lmp-mr1-dev

* changes:
Handle bad WifiHAL implementation
Don't allow SCAN_REQUEST broadcast to launch apps
ebfa1b39d313e987d4bb88440ebfd043965c7dba 14-Nov-2014 Jeff Davidson <jpd@google.com> Don't enable ephemeral networks when bringing up Wi-Fi.

Connections to these networks should only be managed by auto-join. If
we enable these configs then it is possible that the supplicant brings
up an unwanted ephemeral connection that auto-join will immediately
discard, which is wasteful.

Bug: 18389875
Change-Id: I0d3a9a35542eda71401920c0b600dcd2b1e134ba
om/android/server/wifi/WifiConfigStore.java
6defffe263ba70f966477068cb05808672fe4188 14-Nov-2014 vandwalle <vandwalle@google.com> am e7c1afb7: Merge "check for null pointers when processing CMD_START_SCAN" into lmp-mr1-dev automerge: db65f52

* commit 'e7c1afb724650c9bdfcc35e0e3f1fb886ffa49dc':
check for null pointers when processing CMD_START_SCAN
db65f5219f9664b64a9ba40e042c9283c5a4f985 14-Nov-2014 vandwalle <vandwalle@google.com> Merge "check for null pointers when processing CMD_START_SCAN" into lmp-mr1-dev
9ac6950280ea6cefb8f9f3be9cc98d00d8b91585 14-Nov-2014 vandwalle <vandwalle@google.com> fix broken build

Change-Id: I2d0cf58361b7b7b723d2e09d4c6a53c0b5d4e24b
om/android/server/wifi/WifiStateMachine.java
26c480abf7155ea69feea08a4e2a44f481aa3a90 13-Nov-2014 Jeff Davidson <jpd@google.com> Fix call to startScan for untrusted setting change. automerge: d406991
automerge: 828be4f

* commit '828be4fca5e2f51dc481a3188f64663f4e4d05cc':
Fix call to startScan for untrusted setting change.
43f539138be53a3884ce7b97b4d961ce6edee957 13-Nov-2014 vandwalle <vandwalle@google.com> resolve merge conflicts of 75b687a to master.

Change-Id: I1647a8be129a71bef2fcf2b3cad001a2d7c183b3
12ecdb7b85152b47a5469f0942f3e9d811d6d90b 13-Nov-2014 vandwalle <vandwalle@google.com> check for null pointers when processing CMD_START_SCAN

Change-Id: Icc3bcb37d181e6f28673808d5c3239d18c6a482f
om/android/server/wifi/WifiStateMachine.java
d406991cea796c4b75e484bd0d47a85a0f8a4dae 13-Nov-2014 Jeff Davidson <jpd@google.com> Fix call to startScan for untrusted setting change.

Bug: 18221007
Change-Id: Idb526b1f275100ab2a004e7923a032f2e98db6de
om/android/server/wifi/WifiStateMachine.java
005c1ef113192f898499a407dd266393a8d6b076 12-Nov-2014 vandwalle <vandwalle@google.com> - better handling of deleted configurations, only keep a crc32 of deleted SSIDs
- trigger a scan when changing settings allowing use of untrusted networks
Bug:18221007
Bug:18269621

Change-Id: I7eec8913737726a1bf468a96eae562cc567ecfd3
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiStateMachine.java
cce5b9e0eded28096991578e020883484ece8c54 11-Nov-2014 Vinit Deshpande <vinitd@google.com> Fix connections to unintended networks

This change fixes a bug in Wifi state machine - it unintentionally
enables all the networks and results in connecting to a network that
may not have been chosen by AutoJoinController.

Bug: 18266514

Change-Id: I0d5d274819194c0eea4f3812d506a92899f3eb54
om/android/server/wifi/WifiStateMachine.java
cce360ad854cabb238ba0d9290785c26e837749c 12-Nov-2014 Vinit Deshpande <vinitd@google.com> Handle bad WifiHAL implementation

wifi_initialize() may succeed even without any wlan. This crashes
the framework. This change handles such inconsistencies.

Bug: 18337642
Change-Id: I578e0d92ea6b981a1d61469a0f4e870d87843107
om/android/server/wifi/WifiNative.java
cc9395f7b604c626e8c45021b52dad3abff9bd18 07-Nov-2014 Vinit Deshpande <vinitd@google.com> Don't allow SCAN_REQUEST broadcast to launch apps

This change sets the package to Wifi package for all the timer
broadcasts it schedules. This way, the alarm manager won't wake
up any other apps.

Bug: 17611296
Change-Id: I248695b2c4763c799b730a236945e91757dfde16
om/android/server/wifi/WifiStateMachine.java
13672de1d2124fcfb5bd03ebc962eae1ac75816b 12-Nov-2014 vandwalle <vandwalle@google.com> am 56c30f09: Merge "dont blacklist wifi config that have had validated internet status in the past" into lmp-mr1-dev automerge: f93f774

* commit '56c30f0998360fb4690538b90393eb92bb9a8ad3':
dont blacklist wifi config that have had validated internet status in the past
f93f774c884d2fcbeadaf575a3b3fa065da2e3d0 12-Nov-2014 vandwalle <vandwalle@google.com> Merge "dont blacklist wifi config that have had validated internet status in the past" into lmp-mr1-dev
b82f44556947bd8ff6b6032fc5ffa02586ee0d7d 11-Nov-2014 Jeff Davidson <jpd@google.com> am d9666f15: Make use of scorer-specified heuristics in RssiCurve. automerge: 81c9ea6

* commit 'd9666f1578308da4b0eba040903db35ea05132eb':
Make use of scorer-specified heuristics in RssiCurve.
d30127db46224e45554f8964209221bba8ad41d9 08-Nov-2014 vandwalle <vandwalle@google.com> dont blacklist wifi config that have had validated internet status in the past

Change-Id: I4498888ffb1d3189204a553462ff4342239ed2af
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiStateMachine.java
81c9ea6c343bc7f8d87095237e59844a974d0b70 06-Nov-2014 Jeff Davidson <jpd@google.com> Make use of scorer-specified heuristics in RssiCurve.

Treat Byte#MIN_VALUE equivalently to a null score curve. This allows a
scorer to define an RSSI threshold below which a network should not be
used. Currently, any non-null score curve will result in us connecting
to a given network regardless of RSSI.

Also, instead of applying a hard-coded dBm boost to the currently
active network, make use of the boost specified in the RSSI curve
itself, allowing the scorer to fine-tune this boost.

Bug: 15432594
Change-Id: I7a8f5f68ef074827d4b1cfbbed0841448498f179
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiNetworkScoreCache.java
9dac0da5b0c6fefa7f8b4e182faac955df9ff9b3 06-Nov-2014 Jeff Davidson <jpd@google.com> resolved conflicts for merge of 67930f53 to master

Change-Id: I7ec4cd0db477678376dd0cd605bfcd529651be8d
6b7f403e4cef10029159c75bc311142a56099aef 06-Nov-2014 Jeff Davidson <jpd@google.com> Merge "Support conversion of untrusted networks to trusted." into lmp-mr1-dev
3aed1e5a7a7f2ec730c393e2c7d129e3e551a711 05-Nov-2014 Jeff Davidson <jpd@google.com> Support conversion of untrusted networks to trusted.

When the user requests to connect to a network which already has an
untrusted config, we update the existing config and clear the
ephemeral bit rather than creating a new config. We also maintain the
current connection if that ephemeral config matches the currently
connected configuration, and merely tell the system that the network
is now trusted.

The above also applies for AUTO_JOIN_DELETED networks, which are
similarly filtered out from the list of WifiConfigurations.

Bug: 18206275
Change-Id: I1dff7e3c073888c619e6a5c3a40295a44b12e403
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiStateMachine.java
d15374d956a4143ebb851f9ca4910651bd47d7a8 04-Nov-2014 vandwalle <vandwalle@google.com> am 8ae8e251: am 917a6ea4: Merge "propagate noInternetAccess flag and network status" into lmp-mr1-dev

* commit '8ae8e251bf521e8eeb5ad65467cc4e37c42a3c6f':
propagate noInternetAccess flag and network status
917a6ea431a8137e7ceba46ec9efc84c68882dc0 04-Nov-2014 vandwalle <vandwalle@google.com> Merge "propagate noInternetAccess flag and network status" into lmp-mr1-dev
cdc5b747a9c6ff40a38a66bdd8f86dbf11852a7a 04-Nov-2014 vandwalle <vandwalle@google.com> propagate noInternetAccess flag and network status

Change-Id: I7a1ac684c11c3ef93462e02cfc9d6fde3c9b81d7
om/android/server/wifi/WifiStateMachine.java
e7b9e74a9a699e74881e5c98c684567763dfaa35 15-Oct-2014 Vinit Deshpande <vinitd@google.com> Fix a crash in parsing beacon IEs

Sometimes they aren't correct; but we shouldn't crash the system for it

Bug: 17549369
Change-Id: Idafde6a8f86b63ef157e8dbf0937cd796bee476f
om/android/server/wifi/WifiNative.java
ac06587f2505ca1db793ce2a7fc46bcc52fed5c1 03-Nov-2014 Jeff Davidson <jpd@google.com> am 6a9eea91: am 42f181ed: Propagate WifiConfiguration ephemeral bit to ScanResult.

* commit '6a9eea9102b46ca17a5431e5079a47ad1dcd10b5':
Propagate WifiConfiguration ephemeral bit to ScanResult.
42f181ed4277890489be016939209952959d5416 31-Oct-2014 Jeff Davidson <jpd@google.com> Propagate WifiConfiguration ephemeral bit to ScanResult.

Bug: 18206244
Change-Id: I82e8a359db32a84145716b43d8438767959a00b3
om/android/server/wifi/WifiConfigStore.java
d2005e9fa1097b19857aa92dda5e658a07167cc5 31-Oct-2014 vandwalle <vandwalle@google.com> am 727b9213: am efad8ec6: read packet counters before and after DHCP

* commit '727b9213ba72cd2fc45811ef72d25966f70add9a':
read packet counters before and after DHCP
e50ba6f0a30a4e02618b3c9f9d5ad0320a5c264e 30-Oct-2014 Erik Kline <ek@google.com> am 371b6415: Merge "Make isProvisioned() use LinkProperties\' concept of same." into lmp-mr1-dev automerge: cfa3bfe

* commit '371b6415f3fca768373ec340fb6a78a21f6badb5':
Make isProvisioned() use LinkProperties' concept of same.
6d98e3970d8263f7694ad621d755e72c74c9c468 30-Oct-2014 vandwalle <vandwalle@google.com> am 9130e936: print both uptime and milli since boot in the wifi state machine logs automerge: b512032

* commit '9130e93659b974b20756145b0064623c02ed45c5':
print both uptime and milli since boot in the wifi state machine logs
500ab3844f536a8c577a0025266bafb493e4789f 30-Oct-2014 vandwalle <vandwalle@google.com> am 7a05688a: am f9715cc1: various fixes: - Carry over the IP config when self adding a configuration - fix null pointer exception in wificonfigstore, trying to read the IPConfig file Bug:18058314 Bug:18057271

* commit '7a05688a05b34ae33c0a305f3d3b3fc78ce0b00f':
various fixes: - Carry over the IP config when self adding a configuration - fix null pointer exception in wificonfigstore, trying to read the IPConfig file Bug:18058314 Bug:18057271
efad8ec6cb12e5658ee0288cc7e5aa755267aeb6 30-Oct-2014 vandwalle <vandwalle@google.com> read packet counters before and after DHCP

Change-Id: I0c1d94a6d687c2788b71523adae01cde59d34aa7
om/android/server/wifi/WifiStateMachine.java
cfa3bfefdaebf6213a067fa2fc6e377b4f25605a 29-Oct-2014 Erik Kline <ek@google.com> Merge "Make isProvisioned() use LinkProperties' concept of same." into lmp-mr1-dev
b5120326b58f35217dcedc5f19e8cf3eb42b28d0 29-Oct-2014 vandwalle <vandwalle@google.com> print both uptime and milli since boot in the wifi state machine logs

Change-Id: I5521b59efcf1c3fb6d0e2dc62b3db92a27c49ebd
om/android/server/wifi/WifiStateMachine.java
f9715cc118c446695b2a82211881c7d6c5e59761 23-Oct-2014 vandwalle <vandwalle@google.com> various fixes:
- Carry over the IP config when self adding a configuration
- fix null pointer exception in wificonfigstore, trying to read the IPConfig file
Bug:18058314
Bug:18057271

Change-Id: Ia1922f0cf44aa6eaf67928ac392a6ec92431f279
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiStateMachine.java
553f8e37a484fdda61281a0993da59c36de6d26c 28-Oct-2014 Lorenzo Colitti <lorenzo@google.com> am a851b6fc: Merge "Don\'t connect if the NetworkFactory has not requested it." into lmp-mr1-dev automerge: 27fec00

* commit 'a851b6fcb7601d6dd9dcc5793383faafbe8d924e':
Don't connect if the NetworkFactory has not requested it.
27fec00f5028f34adfc9d43a21ef363a33f7277e 28-Oct-2014 Lorenzo Colitti <lorenzo@google.com> Merge "Don't connect if the NetworkFactory has not requested it." into lmp-mr1-dev
0af9c80053bd2736d5bea095b363d6a0c8ce71d0 22-Oct-2014 Lorenzo Colitti <lorenzo@google.com> Don't connect if the NetworkFactory has not requested it.

This fixes persistent oscillations that occur if Ethernet is
plugged in, where wifi connects, gets torn down because its
score is too low, reconnects, ...

Bug: 17632610
Change-Id: Icfeed9b46d97a8868b64a0be3cb83ac2884f3228
om/android/server/wifi/WifiStateMachine.java
6d66b5730446fa4df96c6dcda8612a64ed5bf383 24-Oct-2014 Erik Kline <ek@google.com> Make isProvisioned() use LinkProperties' concept of same.

Change the concept of provisioned to rely on LinkProperties#isProvisioned,
unless a static configuration (possibly incomplete) is in effect.

Bug: 17769720
Change-Id: Ie45e45016d3b33d98097727d49b9c09349fc9021
om/android/server/wifi/WifiStateMachine.java
0babf8db92db534bf5ce274b551aa6d9b8200ced 25-Oct-2014 Vinit Deshpande <vinitd@google.com> am 7078ccd6: am 88daa7e9: Mark configuration as disabled, if it is disabled by WifiManager automerge: b407b98

* commit '7078ccd6c3e9b65ee57ca1bc4726f4db698a3680':
Mark configuration as disabled, if it is disabled by WifiManager
b407b98190bc4a80b58285bbcd4751bf2a94c9b9 25-Oct-2014 Vinit Deshpande <vinitd@google.com> am 88daa7e9: Mark configuration as disabled, if it is disabled by WifiManager

* commit '88daa7e9d975b8b6674157dd6e81d358c7d16393':
Mark configuration as disabled, if it is disabled by WifiManager
88daa7e9d975b8b6674157dd6e81d358c7d16393 24-Oct-2014 Vinit Deshpande <vinitd@google.com> Mark configuration as disabled, if it is disabled by WifiManager

Bug: 17937171

Change-Id: Ic61439868f28899cc1c641c29ebcc8b7bfab35eb
om/android/server/wifi/WifiConfigStore.java
9e0e2c97dc7be69ebb76017e6d3846e8fff130c6 23-Oct-2014 vandwalle <vandwalle@google.com> am 749c23d2: am c1bcb778: am 1ec92c57: - detect that firmware cant stay connected to 5GHz AP and tune down 5GHz preference accordingly - use a long random string so as to obfuscate PSK of WiFiConfiguration we have deleted but keep around in the autojoin database - if

* commit '749c23d2d7dc04dcdb8076ce81a213a86499cc72':
- detect that firmware cant stay connected to 5GHz AP and tune down 5GHz preference accordingly - use a long random string so as to obfuscate PSK of WiFiConfiguration we have deleted but keep around in the autojoin database - if autojoin doesn't find a known network to join, and sees a known network that ConnectivityService never marked as UNWANTED due to bad signal, then add a boost of up to +8dB to this network's autojoin threshold, also includes the boost in the network's score that is sent to connectivity service
c1bcb77843fecb661b5733ed5813e327313ce002 22-Oct-2014 vandwalle <vandwalle@google.com> am 1ec92c57: - detect that firmware cant stay connected to 5GHz AP and tune down 5GHz preference accordingly - use a long random string so as to obfuscate PSK of WiFiConfiguration we have deleted but keep around in the autojoin database - if autojoin doesn\'t find a kn

* commit '1ec92c57244311c7fca3ab6b244a06c2b2b58902':
- detect that firmware cant stay connected to 5GHz AP and tune down 5GHz preference accordingly - use a long random string so as to obfuscate PSK of WiFiConfiguration we have deleted but keep around in the autojoin database - if autojoin doesn't find a known network to join, and sees a known network that ConnectivityService never marked as UNWANTED due to bad signal, then add a boost of up to +8dB to this network's autojoin threshold, also includes the boost in the network's score that is sent to connectivity service
1ec92c57244311c7fca3ab6b244a06c2b2b58902 21-Oct-2014 vandwalle <vandwalle@google.com> - detect that firmware cant stay connected to 5GHz AP and tune down 5GHz preference accordingly
- use a long random string so as to obfuscate PSK of WiFiConfiguration we have deleted but keep around in the autojoin database
- if autojoin doesn't find a known network to join, and sees a known network that ConnectivityService never marked as UNWANTED due to bad signal, then add a boost of up to +8dB to this network's autojoin threshold, also includes the boost in the network's score that is sent to connectivity service

b/17960587
b/18038705
b/18030088
b/17870963

Change-Id: I6cb2c6fdff799453b3d780c43f99d070117e0dc7
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiStateMachine.java
be84b5394d1aefbf408a2b52aa8cb9633d9368d9 18-Oct-2014 vandwalle <vandwalle@google.com> am 327a5a8b: am dd0c5587: Taking into account user join preference more aggressively; add debug info for roaming Bug:17669859 Big:17651877 automerge: 0fd84c2

* commit '327a5a8b601a87fb565385884146ede95b444d4f':
Taking into account user join preference more aggressively; add debug info for roaming Bug:17669859 Big:17651877
0fd84c2577121d02f0d6436c84dcb1dd311911e5 18-Oct-2014 vandwalle <vandwalle@google.com> am dd0c5587: Taking into account user join preference more aggressively; add debug info for roaming Bug:17669859 Big:17651877

* commit 'dd0c558776fcfba3f754bb0cd6533f2c9c23ec1e':
Taking into account user join preference more aggressively; add debug info for roaming Bug:17669859 Big:17651877
dd0c558776fcfba3f754bb0cd6533f2c9c23ec1e 16-Oct-2014 vandwalle <vandwalle@google.com> Taking into account user join preference more aggressively; add debug info for roaming
Bug:17669859
Big:17651877

Change-Id: I3f763f354848d2bc3863f2887bccaf0ff9af426e
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiStateMachine.java
552b5e4984e7b1331e3c0f0d262196d98e49eb3c 16-Oct-2014 vandwalle <vandwalle@google.com> am 55323f85: am 0e89e053: am 6db73827: Merge "fix bssid blacklisting Bug:17960587 Bug:17966377" into lmp-dev

* commit '55323f85677f3c6aed2188fbae68154de61b1589':
fix bssid blacklisting Bug:17960587 Bug:17966377
0e89e0535f4f7b2a48384fc0b7ae779acd0376c7 16-Oct-2014 vandwalle <vandwalle@google.com> am 6db73827: Merge "fix bssid blacklisting Bug:17960587 Bug:17966377" into lmp-dev

* commit '6db73827acdedb707dd3e0f2fa2add833380a3b6':
fix bssid blacklisting Bug:17960587 Bug:17966377
6db73827acdedb707dd3e0f2fa2add833380a3b6 16-Oct-2014 vandwalle <vandwalle@google.com> Merge "fix bssid blacklisting Bug:17960587 Bug:17966377" into lmp-dev
078a7527951b1e8fb7722ab930760730cf54e572 15-Oct-2014 vandwalle <vandwalle@google.com> fix bssid blacklisting
Bug:17960587
Bug:17966377

Change-Id: I6ead5386f961e8bd0705ceea190752dd20f7e38a
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiStateMachine.java
8a5d615e95c6e71b1db7536fb28f3142b63649cb 15-Oct-2014 Jeff Davidson <jpd@google.com> resolved conflicts for merge of fd93b4ce to master

Change-Id: I1c81c9d9a9b8d3709473ee585b5b741624babf7a
8639f6266cb70bf92d1561af43ac2d7b2b97298e 19-Aug-2014 Jeff Davidson <jpd@google.com> Allow connections to untrusted SSIDs when requested.

When at least one NetworkRequest for an untrusted network is active,
autojoin will allow connections to untrusted connections. Upon
successful connection, we tell the framework whether Wifi is currently
connected to a trusted or untrusted network. If all requests for
untrusted networks are withdrawn, and we are currently connected to an
untrusted network, that connection is dropped.

Bug: 15892711
Change-Id: I3f8625996013ee850927fc2290a24c591e3db691
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiStateMachine.java
ad9bd6cf22f910acff81b7f29e2b7ed8e6cb71b8 15-Oct-2014 vandwalle <vandwalle@google.com> am af106831: am 85f2d77b: In case of driver roaming and auth failure, allow for fast reconnect Bug:17747008

* commit 'af1068317050f861fab0c5f097cc311942c13a69':
In case of driver roaming and auth failure, allow for fast reconnect Bug:17747008
85f2d77b1b858c063471951f3a5f93c96bd5e72b 14-Oct-2014 vandwalle <vandwalle@google.com> In case of driver roaming and auth failure, allow for fast reconnect
Bug:17747008

Change-Id: I87eefc5a0952dd5f7159385aa180c02a38d92432
om/android/server/wifi/WifiStateMachine.java
e0aacc7755f2ab48b081a1f119c05382779f306a 12-Oct-2014 vandwalle <vandwalle@google.com> am d2c137ad: am a5283c01: reenable networks completely, 5 mins after DHCP failure blacklist; revert aggressive wifi to cellular handover when handing over due to link speed Bug:17949093 Bug:17947372 Bug:17897698

* commit 'd2c137ad25e6e7f15570b989709b9ea9c3ff701a':
reenable networks completely, 5 mins after DHCP failure blacklist; revert aggressive wifi to cellular handover when handing over due to link speed Bug:17949093 Bug:17947372 Bug:17897698
a5283c01ac413e378e2261050cac3a6d6e9cf385 11-Oct-2014 vandwalle <vandwalle@google.com> reenable networks completely, 5 mins after DHCP failure blacklist; revert aggressive wifi to cellular handover when handing over due to link speed
Bug:17949093
Bug:17947372
Bug:17897698

Change-Id: I1d398238022fd380952cb8dc28f47cc38d0b7b06

Conflicts:
service/java/com/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
74edac0961220f34055e7e35750c2f5de9fe1c74 10-Oct-2014 Joe Farfel <jfarfel@google.com> am 8e599666: am f15171c1: Merge "Change access to P2pStateMachine messenger." into lmp-dev

* commit '8e599666a9fe310dab5996462f2d0298f2df41f2':
Change access to P2pStateMachine messenger.
f15171c10c8df5603c3ba7a2fa80138e151028fc 09-Oct-2014 Joe Farfel <jfarfel@google.com> Merge "Change access to P2pStateMachine messenger." into lmp-dev
6879b31beb6d899a178a3c7c10a5a37470179648 08-Oct-2014 vandwalle <vandwalle@google.com> am 7a693362: am a0708b09: various fixes: - adding debug information to bug report for Bug:16751877 - reenable networks when entering DisconnectedState - dont force MSG_INFO log level at supplicant Bug:16751877 Bug:17811889 Bug:17881399

* commit '7a6933624b11c833632f34750e454331e0b06f96':
various fixes: - adding debug information to bug report for Bug:16751877 - reenable networks when entering DisconnectedState - dont force MSG_INFO log level at supplicant Bug:16751877 Bug:17811889 Bug:17881399
07a55aa0236fc5d1b05c5d54c6ff8d42d881b4bb 07-Oct-2014 Joe Farfel <jfarfel@google.com> Change access to P2pStateMachine messenger.

Allow either LOCATION_HARDWARE (GmsCore has this) or
CONNECTIVITY_INTERNAL permission.

Bug: 17814099
Change-Id: I73aba5361f8654305d783996093e095375087f37
om/android/server/wifi/p2p/WifiP2pServiceImpl.java
a0708b09ad17b086c008ab100aec7143d7613c80 07-Oct-2014 vandwalle <vandwalle@google.com> various fixes:
- adding debug information to bug report for Bug:16751877
- reenable networks when entering DisconnectedState
- dont force MSG_INFO log level at supplicant
Bug:16751877
Bug:17811889
Bug:17881399

Change-Id: I89b4f5c05a1f64f9d1e8c407f62036efa0265043
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
c5199fd4dc2e0a90f7c5fd0d65185e6b2f8916ef 04-Oct-2014 vandwalle <vandwalle@google.com> am da247360: am e0ba94ba: - slightly better network log - add debug option to enable/disable associated full band scans - networkHistory.txt and wpa_supplicant.conf file get out of sync regarding config.status variable Bug:17648443

* commit 'da2473601be1e8917868d16af96f3243516e2a2d':
- slightly better network log - add debug option to enable/disable associated full band scans - networkHistory.txt and wpa_supplicant.conf file get out of sync regarding config.status variable Bug:17648443
e0ba94ba9abde13173ae0de8c8939aa4eb9a9085 01-Oct-2014 vandwalle <vandwalle@google.com> - slightly better network log
- add debug option to enable/disable associated full band scans
- networkHistory.txt and wpa_supplicant.conf file get out of sync regarding config.status variable
Bug:17648443

Change-Id: Ie1c6dac9f94b7d71599734e2263b9456cf6278ee
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiStateMachine.java
3231164e4229c4ea1ea6c26ddf9d89176c84ec61 29-Sep-2014 Vinit Deshpande <vinitd@google.com> am 21478be9: am fb097411: Merge "Don\'t fire SCAN_RESULTS_AVAILABLE broadcast for partial scans" into lmp-dev

* commit '21478be94eb0ea3dacc2bd8a8c84ca190d2edb3c':
Don't fire SCAN_RESULTS_AVAILABLE broadcast for partial scans
6993e3e4292f00534056026c7f98d765cbb06803 27-Sep-2014 Vinit Deshpande <vinitd@google.com> Merge "Separate wifi AP added by applications."
e487a4648dd41881e754f1224aaedead78a0777d 23-Sep-2014 Sky Faber <skyf@google.com> Separate wifi AP added by applications.

-Add dialog before connecting to an app added network
-Remove applicationss APs on uninstall
-Ban apps from modifying networks they don't own.
-Ensure app connections don't modify user preference.

Change-Id: I12943563ef714c4287e13488578f020d136d006d
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
eb06dee93b75e2ad63a7d580c34cd90fc533cec5 27-Sep-2014 Sky Faber <skyf@google.com> Merge "Display p2p alerts for all users."
fb09741166b68bf69dbd0afb22f83a699c5f8a7e 26-Sep-2014 Vinit Deshpande <vinitd@google.com> Merge "Don't fire SCAN_RESULTS_AVAILABLE broadcast for partial scans" into lmp-dev
30165fda6725e82774dc459d006febdcda5f569a 26-Sep-2014 vandwalle <vandwalle@google.com> am 8f92aa6e: am 7736c07a: drop score more aggressively based on link speed, Bug:17514346

* commit '8f92aa6ef6a6563637ea5af4d05a00217a31f1ec':
drop score more aggressively based on link speed, Bug:17514346
765b9dc1c45bbeed87243d21cc5938bd5f1ba0d4 26-Sep-2014 Vinit Deshpande <vinitd@google.com> Don't fire SCAN_RESULTS_AVAILABLE broadcast for partial scans

This ensures that apps don't get partial scan results

Bug: 17612695

Change-Id: Id5d7b9831a54c9fc430f329b4b83b8342f5063ea
om/android/server/wifi/WifiStateMachine.java
7736c07a4cad4e2d86e1ec2f4221c7f788c18d3a 25-Sep-2014 vandwalle <vandwalle@google.com> drop score more aggressively based on link speed, Bug:17514346

Change-Id: Ib7a09adc961d76bc5da49cfff2edd4120175562c
om/android/server/wifi/WifiStateMachine.java
429d1663e81abb122ea8f88a4e1974215bac7e45 25-Sep-2014 vandwalle <vandwalle@google.com> am 8ddd466a: am 5b56b259: Merge "- make rssi poll and wifi scan when associated configurable - fix regression when forgeting network - fix NPE in calculateWifiScore Bug:17564108" into lmp-dev

* commit '8ddd466aaf03fb8fed3f059708ae388109fdfcc4':
- make rssi poll and wifi scan when associated configurable - fix regression when forgeting network - fix NPE in calculateWifiScore Bug:17564108
df69eb27a02b72f7040ad526deacbc7fb91fa581 25-Sep-2014 Vinit Deshpande <vinitd@google.com> am f690498d: am 099e3179: Merge "Introduce config setting for scanning mac OUI" into lmp-dev

* commit 'f690498d0e5b3ec7760b05869d71c5b062b0559d':
Introduce config setting for scanning mac OUI
fc5a12a8ec685c4de2fbb67109d881b175b10898 25-Sep-2014 Sky Faber <skyf@google.com> Merge "Defer CMD_ENABLE_ALL_NETWORKS while doing WPS"
5b56b25942679fa7a608691e70d210c1032d9e4b 25-Sep-2014 vandwalle <vandwalle@google.com> Merge "- make rssi poll and wifi scan when associated configurable - fix regression when forgeting network - fix NPE in calculateWifiScore Bug:17564108" into lmp-dev
099e31798ed1c675a9ad654debac96f975ebcc82 25-Sep-2014 Vinit Deshpande <vinitd@google.com> Merge "Introduce config setting for scanning mac OUI" into lmp-dev
70468b47454c8657e8963932f2e08a3f4d7e3881 25-Sep-2014 vandwalle <vandwalle@google.com> - make rssi poll and wifi scan when associated configurable
- fix regression when forgeting network
- fix NPE in calculateWifiScore
Bug:17564108

Change-Id: I47329b1fb0f23c72886bdd3de99b4f9242d59eec
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiStateMachine.java
65d19a33f71d729b3fab570e5f7ea49211b30cd1 24-Sep-2014 vandwalle <vandwalle@google.com> am cec01e05: am 9d082c38: inconditionally issue the reassociate command in the case of linkdebouncing, dont treat AUTO_SAVE commands coming from autojoincontroller as user triggered WifiManager.SAVE_NETWORK commands Bug:17624613

* commit 'cec01e0566bec2101f9487e7dcb67d93a051d58e':
inconditionally issue the reassociate command in the case of linkdebouncing, dont treat AUTO_SAVE commands coming from autojoincontroller as user triggered WifiManager.SAVE_NETWORK commands Bug:17624613
bbcd5def01d06d260350edaab2af5ebc38545fe3 24-Sep-2014 vandwalle <vandwalle@google.com> am 5a99c7ae: am e0aa0a00: - better sanity check on psk for linking config - black list BSSID in case of repeated DHCP failures - black list network with noInternet connectivity from autojoin - clean up Disconnecting state transition Bug:17512891 Bug:17395269 Bug:1648

* commit '5a99c7ae08a6c8e9d74fcca19b0064145d480d24':
- better sanity check on psk for linking config - black list BSSID in case of repeated DHCP failures - black list network with noInternet connectivity from autojoin - clean up Disconnecting state transition Bug:17512891 Bug:17395269 Bug:16480230 Bug:17518367 Bug:17545859
123e33c0fa492be4f1a8c656cc835ab05c5cda55 24-Sep-2014 Sky Faber <skyf@google.com> Display p2p alerts for all users.

Bug: 17632111
Change-Id: I2caddca5bbac01f13b157bf94c8f395e82e9519a
om/android/server/wifi/p2p/WifiP2pServiceImpl.java
9d082c381274f27dad1e344223189e00148e2124 24-Sep-2014 vandwalle <vandwalle@google.com> inconditionally issue the reassociate command in the case of linkdebouncing, dont treat AUTO_SAVE commands coming from autojoincontroller as user triggered WifiManager.SAVE_NETWORK commands
Bug:17624613

Change-Id: I2c586646bd967cb2d699433b0c228210647f4ee3
om/android/server/wifi/WifiStateMachine.java
eedd70ee3fa7f161ea1f4ae26543ac927e82a681 23-Sep-2014 Vinit Deshpande <vinitd@google.com> Introduce config setting for scanning mac OUI

This setting will allow an OEMs to override the default Google OUI
for scanning.

Bug: 17468465
Change-Id: I3d9a6cf6451bcc98d0cad158bc52c7b3a52cb0ea
om/android/server/wifi/WifiStateMachine.java
e0aa0a004d161173992a0e9af1b431fae91f4a71 19-Sep-2014 vandwalle <vandwalle@google.com> - better sanity check on psk for linking config
- black list BSSID in case of repeated DHCP failures
- black list network with noInternet connectivity from autojoin
- clean up Disconnecting state transition
Bug:17512891
Bug:17395269
Bug:16480230
Bug:17518367
Bug:17545859

Change-Id: I1683a66fd58424ad2177c6508b101fd49392e22a
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
566ef988c372a74f430734d51168200daa39cfde 23-Sep-2014 Vinit Deshpande <vinitd@google.com> am 73ecd8ea: am fa64c3ff: Merge "Synchronize access to supplicant from p2pGetDeviceAddress" into lmp-dev

* commit '73ecd8ea1bf35dbb31df96e18594cd3ac24a8df0':
Synchronize access to supplicant from p2pGetDeviceAddress
fa64c3ff3051dfd8a876786df70e635d3906121f 23-Sep-2014 Vinit Deshpande <vinitd@google.com> Merge "Synchronize access to supplicant from p2pGetDeviceAddress" into lmp-dev
cc04fb0dd7ec593b4731a6ad090527568d4e8312 20-Sep-2014 Robert Greenwalt <rgreenwalt@google.com> am 701b1d7f: am 328fc540: Re-add wifi change permission check.

* commit '701b1d7f23598d6dfd0561c77e5cb6c2b7fee030':
Re-add wifi change permission check.
27f4b0c6ea9533e91863da48cefc80f8b5a88d1e 20-Sep-2014 Vinit Deshpande <vinitd@google.com> Synchronize access to supplicant from p2pGetDeviceAddress

Since it is not calling the native command directly, it needs to
be synchronized just like other commands.

Bug: 17516271
Change-Id: I97ecbc7dc0f476ae52524d513e47c863e6d5ddba
om/android/server/wifi/WifiNative.java
328fc5407927799843c11f2b767a8cf47b89f366 19-Sep-2014 Robert Greenwalt <rgreenwalt@google.com> Re-add wifi change permission check.

Recent change switched to impose the Connectivity permissions
(which were intended but being circumvented) but that removed
the wifi change permission.

bug:17435527
Change-Id: Ibc58605dee767d6a749b1fae867855fd1cb25def
om/android/server/wifi/WifiServiceImpl.java
88e3bdb713f9805cf06beff662cd78a9f1d640aa 18-Sep-2014 vandwalle <vandwalle@google.com> am f125d5b5: am f17f8070: Merge "various fixes:" into lmp-dev

* commit 'f125d5b5918a18d11334fdd0f69cc9bbe63ecd81':
various fixes:
f17f8070a966778bf9e405ed50757ea929bbb545 18-Sep-2014 vandwalle <vandwalle@google.com> Merge "various fixes:" into lmp-dev
7b581f46f6c9bc6edf0edd287d47106712fb2144 17-Sep-2014 vandwalle <vandwalle@google.com> various fixes:

- additional debug logs
- allow a scan result to be associated to mulitple wifi configurations
- additional logs to track 17516271
Bug:17510471

Change-Id: I39975f17494c541989f7f0e0fd8fcf890934ee15
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
32e17445682028a272d0d832886648f370342cea 18-Sep-2014 Robert Greenwalt <rgreenwalt@google.com> am 9252e15f: am 7e1b891b: Merge "Use unified Tethering Permission Check" into lmp-dev

* commit '9252e15fa6c2e2931a32ba1af73f0142a118dc23':
Use unified Tethering Permission Check
7e1b891ba9d144ca026e8684ef8019cc76a53d6e 18-Sep-2014 Robert Greenwalt <rgreenwalt@google.com> Merge "Use unified Tethering Permission Check" into lmp-dev
5eea3d5ccbf3c47ce3ee72b1d42f35f55f641ae7 17-Sep-2014 David Christie <dnchrist@google.com> am 97f9c99a: am 6449b994: Merge "Fix bug where wifi scan only mode is non-functional after toggling airplane mode. Bug: 17507663" into lmp-dev

* commit '97f9c99a7e12aedf1f2991def79bccef98f461c2':
Fix bug where wifi scan only mode is non-functional after toggling airplane mode. Bug: 17507663
34f173a54307c39ffe5dfab52e7ef8166a00539e 17-Sep-2014 Robert Greenwalt <rgreenwalt@google.com> Use unified Tethering Permission Check

The BT and Wifi mechanisms for enabling Tethering did their own
permission checks. This set of changes unifies the check into
a ConnectivityManager function so they can be kept in sync.

bug:17435527
Change-Id: I8c157a5acf56ffbddd349cb6a45160ae7be8541b
om/android/server/wifi/WifiServiceImpl.java
6449b994869c182159a108ae53160edb4f0abe10 17-Sep-2014 David Christie <dnchrist@google.com> Merge "Fix bug where wifi scan only mode is non-functional after toggling airplane mode. Bug: 17507663" into lmp-dev
07a875dc76b3f07afdc521ddf59d7a6774995ac5 17-Sep-2014 Robert Greenwalt <rgreenwalt@google.com> am 8a2fafdf: am fc797cf4: Merge "Add NetworkAgent event for ExplicitlySelected" into lmp-dev

* commit '8a2fafdf1fce098989044f432689d8c7f341bee0':
Add NetworkAgent event for ExplicitlySelected
fc797cf48feed42a76fccef73eeed535e1848702 17-Sep-2014 Robert Greenwalt <rgreenwalt@google.com> Merge "Add NetworkAgent event for ExplicitlySelected" into lmp-dev
892c69ee79493f381890010dcaacc01de51fb18a 17-Sep-2014 vandwalle <vandwalle@google.com> am 4999461c: am 99d385e3: set proper link quality thresholds

* commit '4999461cf9ac0097de22ab4032460408c4d81f76':
set proper link quality thresholds
7b160c8a00773246660caeae9e27090c83ed6ed5 16-Sep-2014 David Christie <dnchrist@google.com> Fix bug where wifi scan only mode is non-functional after toggling airplane mode.
Bug: 17507663

Change-Id: I0d77c2e29b78fdfa8e9f4be31181145cb29c1499
om/android/server/wifi/WifiController.java
om/android/server/wifi/WifiSettingsStore.java
99d385e3b4d34841d6efcfd7cc9bf1d5ae25de14 16-Sep-2014 vandwalle <vandwalle@google.com> set proper link quality thresholds

Bug:17514073

Change-Id: Icf4dbd81e8547bb837c8346c9af5cfc98d7b00ab
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
0ba396aa7f0382b369b89a55773c4e8289ab3f3a 16-Sep-2014 Vinit Deshpande <vinitd@google.com> am 5919271b: am 4d29f96e: Merge "Fix conditions that my leave ScanAlarm running in background" into lmp-dev

* commit '5919271ba37a0a7301c5302487936be3a8a94b93':
Fix conditions that my leave ScanAlarm running in background
6fc37f4abb2bcaa18bdb7cad3384ce637df7aedc 16-Sep-2014 Vinit Deshpande <vinitd@google.com> am 42cc98de: am de5e9a44: Merge "Fix first time notification of available open Wifi" into lmp-dev

* commit '42cc98de5333ad1530ed1e7b81d068776b0a6f6f':
Fix first time notification of available open Wifi
3c935adcb556daabd6a660991de421a9e3dfe035 16-Sep-2014 vandwalle <vandwalle@google.com> am 475b44ed: am 9e806a8d: improve debugging messages & logging

* commit '475b44ed2844754d32a539127fde00004cf6ab63':
improve debugging messages & logging
4d29f96e9085b71b01edb4c3dfd2d5b0bb621fea 16-Sep-2014 Vinit Deshpande <vinitd@google.com> Merge "Fix conditions that my leave ScanAlarm running in background" into lmp-dev
de5e9a44e76cf78d2bac0c60b7420a669393e9f5 16-Sep-2014 Vinit Deshpande <vinitd@google.com> Merge "Fix first time notification of available open Wifi" into lmp-dev
7c8a4effa2442b9d00fd421b443ea9645f8651c8 16-Sep-2014 Vinit Deshpande <vinitd@google.com> Fix conditions that my leave ScanAlarm running in background

This can happen because of race - you could get DISCONNECTED from
supplicant between CMD_SCREEN_STATE_CHANGED (for screen off) and
CMD_ENABLE_BACKGROUND_SCAN - which sets the background scan. This can
cause Disconnected state to leave a scan alarm running.

This change removes that possibility by combining processing of
CMD_ENABLE_BACKGROUND_SCAN into CMD_SCREEN_STATE_CHANGED.

RTC_WAKEUP alarm is also changed to RTC when PNO is supported; so
we shouldn't wake up the AP anymore.

Bug: 17261586

Change-Id: Ic7c3dbf6ed5e042f9ed6b96349bf5ec50e509552
om/android/server/wifi/WifiStateMachine.java
9e806a8d9f297e4de826e65322859a89e4d95c8b 15-Sep-2014 vandwalle <vandwalle@google.com> improve debugging messages & logging

Change-Id: I7c668c24357663fff418c62d21c1fc6cb571590a
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiStateMachine.java
611e252f9d7ed68b65e3a921420489315781f149 14-Sep-2014 vandwalle <vandwalle@google.com> am c506481e: am 17e82884: make wifi cellular handover params configurable

* commit 'c506481edc3bf673ef9cee5816024860e3efe1ee':
make wifi cellular handover params configurable
17e828848eebb4eb11d27ce32d02716334dd6011 13-Sep-2014 vandwalle <vandwalle@google.com> make wifi cellular handover params configurable

Change-Id: Icc1f722d3e0293ec58027770b941fc98dc24ce44
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiStateMachine.java
f9b857e8d434bf7a48b01e283c85f6662b817b34 13-Sep-2014 vandwalle <vandwalle@google.com> am 37a82283: am 0eebae73: various fixes:

* commit '37a82283cf4e4a3e27aac9b4afa38fe23fee08e2':
various fixes:
0eebae7334d6129f7ca1344e4b20199794994358 12-Sep-2014 vandwalle <vandwalle@google.com> various fixes:

- add null pointer check to wifi watchdog state machine
- correctly parse the REQUEST IDENTIY event sent by wpa_supplicant
- make autojoining wificonfiguration more aggressive based on user input
Bug:17469863
Bug:17426395
Bug:17475816

Change-Id: I1785c917c0e570de0edaa02bd0ca6536be9d7c0b
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/WifiWatchdogStateMachine.java
fb7268e9a14ba1620abe12fbc702bd0bd16cb9c5 12-Sep-2014 vandwalle <vandwalle@google.com> am aa5a2e6d: am 448c9536: dont accept CONNECTION_EVENT until roaming is complete

* commit 'aa5a2e6d55625e1a910b0b336721384cb5aeddd1':
dont accept CONNECTION_EVENT until roaming is complete
448c9536a302c58a79e271b1721c08b8882f800e 11-Sep-2014 vandwalle <vandwalle@google.com> dont accept CONNECTION_EVENT until roaming is complete

Change-Id: Iedde560abc9d2f4c3a3b9b9bfc5caaaa5584472e
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiStateMachine.java
98f1919232faf062f15e28dd2ec231a483b617bb 11-Sep-2014 vandwalle <vandwalle@google.com> am 9808208c: am 2f2cf216: make autojoin configurable, clean up BSSID info that may be stake in WifiConfiguration

* commit '9808208c55150f17a7540e86350d275fa68c9a3c':
make autojoin configurable, clean up BSSID info that may be stake in WifiConfiguration
c5e82ad2600416d7eafdde5d1d02400ece28e48a 10-Sep-2014 Vinit Deshpande <vinitd@google.com> Fix first time notification of available open Wifi

There is no networkInfo the first time notification controller starts,
and as a result it is dropping check to find out if open networks are
available.

Bug: 17349359
Change-Id: I09ca0b1cb44a849f2cdfafb1dcdcc943b2586562
om/android/server/wifi/WifiNotificationController.java
2f2cf21662275a0e93d7d7a6ad3d98b4c596dcf0 10-Sep-2014 vandwalle <vandwalle@google.com> make autojoin configurable, clean up BSSID info that may be stake in WifiConfiguration

- allow scans in verifying poor link
Bug:17420929

Change-Id: I310ad60a443d648666ebac49b3eeb56c7e9a0ecc
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiStateMachine.java
ebafddb35b23d40045c8c2dd03c9a2ca4cbab1d8 10-Sep-2014 Vinit Deshpande <vinitd@google.com> am 4158aa44: am 048dd77a: Merge "Secure access to WifiScanner" into lmp-dev

* commit '4158aa4448e876256fce6c73aae9c5affd47d269':
Secure access to WifiScanner
048dd77ab0eb085f708663ee9f6298e703ccda2b 10-Sep-2014 Vinit Deshpande <vinitd@google.com> Merge "Secure access to WifiScanner" into lmp-dev
2f53f4577684ba6e5c53c7405cae3bd8fab2a323 10-Sep-2014 vandwalle <vandwalle@google.com> am 037dd0a1: am b6defc9d: Merge "various fixes:" into lmp-dev

* commit '037dd0a1507797eea3e9a2e85cecfd32d8da0c1d':
various fixes:
b6defc9d7836cb440c0cdb0d1e1031a5fc83a4da 10-Sep-2014 vandwalle <vandwalle@google.com> Merge "various fixes:" into lmp-dev
b664cfeab6f02e24376ea0a15beb83d142f0b14d 09-Sep-2014 vandwalle <vandwalle@google.com> various fixes:

- persist Wificonfiguration.ephemeral
- dont trigger attemptRoam on previous configuration
- treat ADD_OR_UPDATE_NETWORK with highest priority as a user network selection
- add associated scan period in framework/base/core/res/res/

Bug:17202406

Change-Id: Ibd92af49c6b79c6799d90d4b72b72547a4c936ca
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiStateMachine.java
05452aaf01dbb557909c075d697e3e41efc8730f 09-Sep-2014 Vinit Deshpande <vinitd@google.com> am f455e5d2: am a2cf1148: Merge "Implement getAvailableChannels" into lmp-dev

* commit 'f455e5d2c22618c16e2aa7c66c9293d53d222d08':
Implement getAvailableChannels
4c3da5cdf968f37651c40135331f7b9e9ffee4f5 09-Sep-2014 Vinit Deshpande <vinitd@google.com> am d06a7123: am 826cc083: Merge "Fix leaking of WPA2 passcode for newly added networks" into lmp-dev

* commit 'd06a7123bfc9551473f963478a48d7357c6c9ba2':
Fix leaking of WPA2 passcode for newly added networks
a2cf11484151923968065fdb25997c5032d36348 09-Sep-2014 Vinit Deshpande <vinitd@google.com> Merge "Implement getAvailableChannels" into lmp-dev
826cc083fdbef5680ff2052b02789326b44bb322 09-Sep-2014 Vinit Deshpande <vinitd@google.com> Merge "Fix leaking of WPA2 passcode for newly added networks" into lmp-dev
46d6b0ac6d466002e868627488796ce3d6a154aa 09-Sep-2014 Vinit Deshpande <vinitd@google.com> Secure access to WifiScanner

This change implements access control for WifiScanner. It is now
available to only those apps that have CONNECTIVITY_INTERNAL permissions.

Bug: 15088601
Change-Id: I6acc13079b6dac6f190644b6d1a270c271cc679f
om/android/server/wifi/WifiScanningServiceImpl.java
2dbf6c027271518d868ae52ad90789eb2bc3c363 08-Sep-2014 Robert Greenwalt <rgreenwalt@google.com> Add NetworkAgent event for ExplicitlySelected

Lets Wifi tell us when the user selected this AP vs auto-connected.

bug:17396168
Change-Id: I6e067ab62ed49040629aa31fe07ff880d3d542f0
om/android/server/wifi/WifiStateMachine.java
d5eb2cb8bea63e038dfe7c406e313295cba5c3aa 08-Sep-2014 vandwalle <vandwalle@google.com> Merge "adding debug logs"
7963ee6b79a83690ee44ff53d9dbd7c192f2be47 04-Sep-2014 vandwalle <vandwalle@google.com> adding debug logs

- add debug status to WifiStatemachine message handling
- tracking scan requests: add scan request counter and addl debug information
- clean wifi packet stats when we disable RSSI polling
- count home network as >=6 BSSID for the purpose of calculating wifi score

Change-Id: Ic13ef303fdcfe60c0e27f225af4e233b9a2cffaa
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
da33411be39042247b672b854688c31a5dfbdd01 08-Sep-2014 vandwalle <vandwalle@google.com> am 823c46a0: am c9b047b4: dont debounce on locally generated disconnect

* commit '823c46a08fb8617df8e5164305785ccf761dbe3f':
dont debounce on locally generated disconnect
c9b047b4cb480edbb490516746cfcbb4a4eedeea 08-Sep-2014 vandwalle <vandwalle@google.com> dont debounce on locally generated disconnect

Change-Id: Id75a866959fc99828f6143230a9ade3e6a2b81b9
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiStateMachine.java
35a127a1fefece50f8906cc534b24915efdd0660 08-Sep-2014 vandwalle <vandwalle@google.com> am ef302ff4: am 9f3349fa: various fixes:

* commit 'ef302ff47dac49276682ed0335189cf5b951962b':
various fixes:
9f3349fa2cd39d690d1e2b7c3b71ced412e24f2c 05-Sep-2014 vandwalle <vandwalle@google.com> various fixes:

- cleanup setWifiEnable transitions
- dont scan right when entering connected and Disconnected state, instead startScan() adds a 200ms delay before starting the scans, so as to let the state machiine time to process deferred message
- dont forget to send the NetworkStateChanged Broadcast when we set the network detailed state
- autojoin dont attempt to join WifiConfigurations marked as noInternetAccess, unless explicitely selected by the user
- keep stats of user triggered wifi state disabling requests
- fix bad roaming situation when BSSID is specified in network block

Bug:17193677

Change-Id: Ia103a93232f40519c7b4eef07254f32342ea5615
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiStateMachine.java
e61237672316b46d7bec960a199bfbd5bfcca257 06-Sep-2014 Vinit Deshpande <vinitd@google.com> Fix leaking of WPA2 passcode for newly added networks

WifiConfigStore is firing broadcast with incorrect object which leaks
the passcode.

Bug: 17160254
Change-Id: Ia07897778d4b7a9865b883ae2a8bc3b01c58ae6a
om/android/server/wifi/WifiConfigStore.java
efa77c1826499b0a3e57998bd6b3073b107e45d7 06-Sep-2014 Vinit Deshpande <vinitd@google.com> Implement getAvailableChannels

This API allows finding channels by band, so scanning services
can find out which channels to use.

Bug: 16652660
Change-Id: I690825333988a336efa3fc8886297e5b8baf8e1d
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiScanningServiceImpl.java
7fc502d2f1d0653e767b4c5af848f8cce45e6f40 05-Sep-2014 Wenchao Tong <tongwenchao@google.com> am 67f94f00: am 14fd4783: Merge "Fix a bug in the wpa_supplicant parsing code." into lmp-dev

* commit '67f94f00ddb558cf3e908dc31b170d586d085c62':
Fix a bug in the wpa_supplicant parsing code.
14fd4783657cc19da98d964e61de6251d6c317c8 05-Sep-2014 Wenchao Tong <tongwenchao@google.com> Merge "Fix a bug in the wpa_supplicant parsing code." into lmp-dev
f2899b9c94fd1abbd01625dfe320dd3f1bc9cc9c 03-Sep-2014 Wenchao Tong <tongwenchao@google.com> Fix a bug in the wpa_supplicant parsing code.

line.indexOf("ssid=") matches both ssid=xxx and scan_ssid=1.
Fix a typo in the regex to match the end of network block.

Bug: 17363819
Change-Id: Ib240e16988867b9610691b3bf4bcf90130797dc9
om/android/server/wifi/WifiConfigStore.java
a696b72d45c777bc6ce5e3e7a98cd450b1c12579 18-Aug-2014 Sky Faber <skyf@google.com> Defer CMD_ENABLE_ALL_NETWORKS while doing WPS

Bug: 15003359
Change-Id: I3fa0dad30926ed02d9b3f8eff51a200bc5f95c5d
om/android/server/wifi/WifiStateMachine.java
2ee4ecdffaf73ed7070c3b63db1f6fc6367a26a8 01-Sep-2014 vandwalle <vandwalle@google.com> AutoJoin fixes:

- Additional logs
- re-enable all network upon screen on and connection, even for blackliste networks due to auth failure
- watchdog the DisconnectingState
- remove mFrameworkAutoJoin which is not used anymore
- dont remove WPA_PSK configurations, instead mark them as AUTO_JOIN_DELETED and loose their history and keys

Bug:17261906
Bug:17330171
Bug:17339150
Bug:17063789

Change-Id: I12ea25142d0dcfc670d8970ed67624e8573d1ac2

Conflicts:
service/java/com/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiStateMachine.java
ebb7e0cb4572f73325a749539d589ebdefb8635c 04-Sep-2014 vandwalle <vandwalle@google.com> adding debug logs

- add debug status to WifiStatemachine message handling
- tracking scan requests: add scan request counter and addl debug information
- clean wifi packet stats when we disable RSSI polling
- count home network as >=6 BSSID for the purpose of calculating wifi score

Change-Id: Ic13ef303fdcfe60c0e27f225af4e233b9a2cffaa
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
35b1f31d5d44c2476c475483d1b89ca5c510ce31 04-Sep-2014 vandwalle <vandwalle@google.com> am 4950bc23: am 82199a28: help debugging scan issues: - adding additional logs - make handleSCreenStateChanged a message - track sender of the CMD_GET_CONFIGURED_NETWORKS message

* commit '4950bc232d787b68a490fe4e2534719f33fcb6d3':
help debugging scan issues: - adding additional logs - make handleSCreenStateChanged a message - track sender of the CMD_GET_CONFIGURED_NETWORKS message
f4c6a897fbb61e8bb31646db6fed78b579d10574 03-Sep-2014 vandwalle <vandwalle@google.com> Merge "fix processing of CMD_SAVE_NETWORK" into lmp-dev
0ff9728ea843a291b2665c705cfe6f0357e1aa44 03-Sep-2014 vandwalle <vandwalle@google.com> fix processing of CMD_SAVE_NETWORK

Change-Id: Ia42e6f3e983f69b38f899c56afd07da1e78a10b3
om/android/server/wifi/WifiStateMachine.java
79d8f4f1e91e2315724d4d91725f865a7631b487 03-Sep-2014 Vinit Deshpande <vinitd@google.com> am 9eb8a226: am cbdd4310: Merge "Address API Council feedback for WifiAdapter/WPS APIs" into lmp-dev

* commit '9eb8a2269e1021fff345521ef980bbb4b759e186':
Address API Council feedback for WifiAdapter/WPS APIs
82199a285f4a45a46b44eb8253999aa918534753 03-Sep-2014 vandwalle <vandwalle@google.com> help debugging scan issues:
- adding additional logs
- make handleSCreenStateChanged a message
- track sender of the CMD_GET_CONFIGURED_NETWORKS message

Change-Id: I5717d07850ed563193b694a74d236bb8795fbd38
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
cbdd43105d9c12041a0b9edea714526c64542caf 03-Sep-2014 Vinit Deshpande <vinitd@google.com> Merge "Address API Council feedback for WifiAdapter/WPS APIs" into lmp-dev
be3095ed758fca076b9ccb9fdae48f7f865c078a 01-Sep-2014 vandwalle <vandwalle@google.com> AutoJoin fixes:

- Additional logs
- re-enable all network upon screen on and connection, even for blackliste networks due to auth failure
- watchdog the DisconnectingState
- remove mFrameworkAutoJoin which is not used anymore
- dont remove WPA_PSK configurations, instead mark them as AUTO_JOIN_DELETED and loose their history and keys

Bug:17261906
Bug:17330171
Bug:17339150
Bug:17063789

Change-Id: I12ea25142d0dcfc670d8970ed67624e8573d1ac2
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiStateMachine.java
048dc8df2bd9394979dbb090b0cfe8d6627d23e3 29-Aug-2014 Vinit Deshpande <vinitd@google.com> Address API Council feedback for WifiAdapter/WPS APIs

This change addresses concerns from the API review. Things that
are fixed are -

1. WifiAdapter is removed, until we have 'real' support for it
2. All the methods from WifiAdapter are moved to WifiManager
3. Changed WPSListener API names to be onFailed/onSucceeded et al

Bug: 16403303
Bug: 17115004
Change-Id: Ie886334f9381b678deb5f0248b9a5ec21f446949
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
641219d820142a9acae8348ff33fd8c3dfcf18b1 29-Aug-2014 vandwalle <vandwalle@google.com> am 321afd3f: am f143875a: Merge "autojoin fixes:" into lmp-dev

* commit '321afd3fc55247e0e10f94b058f01fd2c705e063':
autojoin fixes:
f143875ade81631bfe4c63e379d6467b1863fbc1 29-Aug-2014 vandwalle <vandwalle@google.com> Merge "autojoin fixes:" into lmp-dev
c679b664b1adf31ba5febb9af128b8e0f65900af 28-Aug-2014 Selim Cinek <cinek@google.com> am b6d5ffaa: am 0d647da4: Colored notifications

* commit 'b6d5ffaa408d285ff69eb59340a28c27e1968e48':
Colored notifications
0d647da4a502c1d3679d700144469460acab3d73 27-Aug-2014 Selim Cinek <cinek@google.com> Colored notifications

Bug: 17128331
Change-Id: I30a31d5da000e021e9891c56da91b0ff9615d4d6
om/android/server/wifi/WifiNotificationController.java
e67ec726c07410073575473c0f50dc737629f5da 26-Aug-2014 vandwalle <vandwalle@google.com> autojoin fixes:

- Bug:17291273
- add persistent Wifi verbose logging option (/data/misc/wifi/autojoinconfig.txt)
- add config option for the associated scans period and backoff (/data/misc/wifi/autojoinconfig.txt)
- dont lock BSSID when roaming to 2.4GHz config
- issue single reassociate on roam
- make extended roaming 5GHz preference consistent with roaming 5GHz preference

Change-Id: I1525349e220cebb1b300753a707eb00fcc9d7d7b
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiStateMachine.java
10ab519ea2e4a3c5665ac047fe0239939512fa6d 26-Aug-2014 vandwalle <vandwalle@google.com> Merge "remove passpoint - DO NOT MERGE" into lmp-dev
cc0016886f5cd1afeb9fbf90b6a26e8bba3aa339 26-Aug-2014 vandwalle <vandwalle@google.com> am b92bc78f: am fdde6bf4: Merge "add radio stats to link layer" into lmp-dev

* commit 'b92bc78feb4112177f28445264a93c9479576469':
add radio stats to link layer
fdde6bf4dc075b4f2807a4940edc2be694b326b6 26-Aug-2014 vandwalle <vandwalle@google.com> Merge "add radio stats to link layer" into lmp-dev
200e8ee5097134010a6edee8d031bb02ff7eeb5a 19-Jul-2014 vandwalle <vandwalle@google.com> add radio stats to link layer

This CL is dependent on I3d2a230b0362520b9f1b2bc3792260116971e106

Change-Id: If7e73ae9813ea79a98744d7f0096316d241998fd

halutil updates for link layer statistics

Change-Id: I00ea13b1a932f40891a0d65026a1c87f01f09587
Signed-off-by: Chilam Ng <chilam@broadcom.com>
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
dc83fc7dcba3de36dc4e5249447f1d1b28276fcd 26-Aug-2014 Vinit Deshpande <vinitd@google.com> am 9b37761d: am 28c7065e: Stop redundant attempt to remove an already removed client

* commit '9b37761d51191c19909225eeadd9cee3cab440c6':
Stop redundant attempt to remove an already removed client
4ae496d2dd90896e1f5b36546a27c0103bf5b6d8 26-Aug-2014 Vinit Deshpande <vinitd@google.com> am c803d224: am 042c54bf: Set scanning mac OUI for mac address rotation

* commit 'c803d224234af1debfe76142f3aefc5de281d8de':
Set scanning mac OUI for mac address rotation
3e883d5461ec819b7db51470e387c4bf0b09ce1f 25-Aug-2014 vandwalle <vandwalle@google.com> remove passpoint - DO NOT MERGE

Change-Id: Ia399d98fa7d1ecff5c06bf4802f70dc22c8e5713
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/passpoint/WifiPasspointService.java
om/android/server/wifi/passpoint/WifiPasspointServiceImpl.java
om/android/server/wifi/passpoint/WifiPasspointStateMachine.java
28c7065e2af36064a230d2647782c5cdadaff2d8 15-Aug-2014 Vinit Deshpande <vinitd@google.com> Stop redundant attempt to remove an already removed client

It seems CMD_CHANNEL_DISCONNECTED can be called multiple times. This
change fixes a null derefence when removing the same client a second
time.

Bug: 17049093
Change-Id: Ic7da6a1e42cdc809cc3f6f042f2502453fee0c91
om/android/server/wifi/WifiScanningServiceImpl.java
042c54bfd5144ce8e720585b2093796e7e28de5e 21-Aug-2014 Vinit Deshpande <vinitd@google.com> Set scanning mac OUI for mac address rotation

This change enables mac address rotation feature if it is
implemented. The OUI being set is Google's OUI; which should
prevent from scanning mac addresses colliding with infra mac
addresses.

This change also stops from linking to Qualcomm's and Marvell's
WifiHAL implementation - since none of the new features are
expected to work with this HAL

Change-Id: I50979a8b20c59f5d40007eb4e0ff945e529cbb49
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
1a8a78bb228e4515fe57250baf75205048187824 23-Aug-2014 Robert Greenwalt <rgreenwalt@google.com> am 92a4f801: am 1d799fd8: Merge "Use new config resource for tcp buffersize" into lmp-dev

* commit '92a4f8010f048d93ffd913bc37153a39b5ed0b48':
Use new config resource for tcp buffersize
1d799fd875b604be33d2aa0a879d93b4b1f79735 23-Aug-2014 Robert Greenwalt <rgreenwalt@google.com> Merge "Use new config resource for tcp buffersize" into lmp-dev
207323e3a43e869bab25ad8451179fe7b8c10654 22-Aug-2014 Vinit Deshpande <vinitd@google.com> am a94c25d8: am 88d6ab0a: Merge "Fix a bug in setting external_sim flag" into lmp-dev

* commit 'a94c25d8f23c39bdf1422636b2a3ab24030c2564':
Fix a bug in setting external_sim flag
88d6ab0af06fa595a7c9b3abc69f1f8b5f18e9cf 22-Aug-2014 Vinit Deshpande <vinitd@google.com> Merge "Fix a bug in setting external_sim flag" into lmp-dev
84f35d45bc81b552c89ba671951242d8422516de 22-Aug-2014 vandwalle <vandwalle@google.com> am 7b3b84c0: am 56d01781: fix spurious disconnect while associating, dont set AP configuration with NULL SSID

* commit '7b3b84c05e838552433a77919b1af4a9fdeea6bd':
fix spurious disconnect while associating, dont set AP configuration with NULL SSID
4d701eca56d62586b0ab8af6ad864bac74a1dcd0 22-Aug-2014 Vinit Deshpande <vinitd@google.com> Fix a bug in setting external_sim flag

It looks like supplicant doesn't like the lowercase
command, it needs uppercase.

Bug: 17176844

Change-Id: If8515f522384cb8ed98bb78c0d50ffc0f383c9ed
om/android/server/wifi/WifiNative.java
3c3c5b64726f04920109e4c8f20a1c58ea7050aa 22-Aug-2014 Robert Greenwalt <rgreenwalt@google.com> Use new config resource for tcp buffersize

bug:16549611
Change-Id: I01ecca0a2a7893c1911cead503594ce9e17fa69e
om/android/server/wifi/WifiStateMachine.java
56d0178183460eed9afbd85e5c0d215e27d5f5bc 21-Aug-2014 vandwalle <vandwalle@google.com> fix spurious disconnect while associating, dont set AP configuration with NULL SSID

Bug:14568953
Bug:17144830

Note: this CL address cases where framework sends spurious disconnect to driver while associating, this issue was only one of the root cause of 17144830, the remaining issues in this bug are "missing scan results" and "wifi chipset disconnects from AP due to missing beacons or receiving deauth from AP"

Change-Id: If888f11bb3c66b55ca8ff991651f9e4457aaea31
om/android/server/wifi/WifiApConfigStore.java
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
0c97b2ae7ca30b9bcb3a0ed81fff43cd87700452 21-Aug-2014 vandwalle <vandwalle@google.com> am 34142b7c: am 0d616ef3: add roam state watchdog.

* commit '34142b7cf3f65e57e674ad41fceefd6091c341c9':
add roam state watchdog.
34142b7cf3f65e57e674ad41fceefd6091c341c9 21-Aug-2014 vandwalle <vandwalle@google.com> am 0d616ef3: add roam state watchdog.

* commit '0d616ef3bf635dff8722e064c0be842676390ed8':
add roam state watchdog.
0d616ef3bf635dff8722e064c0be842676390ed8 20-Aug-2014 vandwalle <vandwalle@google.com> add roam state watchdog.

Bug: 16823537

This CL is dependent on Id9411c8097337b37ac1ce1a6ac8b28b4bda31ff3

Change-Id: Iff32fae2cd67343e63046d58d75fa1e10d9775d0
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiStateMachine.java
f923196b37dea0cc3dee2cca1bd8537ad552232e 20-Aug-2014 vandwalle <vandwalle@google.com> am 3598326d: am 1fd74be7: Merge "debug messages for link loss issues" into lmp-dev

* commit '3598326d44e37cbd0a6ddfab7117fa9e3afa2a30':
debug messages for link loss issues
622f75aff3a3c39969ef960b549b16f11388f24f 20-Aug-2014 Lorenzo Colitti <lorenzo@google.com> am 3820aff5: am 24adb818: Merge "Clear IPv4 addresses when switching from DHCP to static." into lmp-dev

* commit '3820aff51e94d70e0c0f730a710ec89ca7e6d579':
Clear IPv4 addresses when switching from DHCP to static.
3598326d44e37cbd0a6ddfab7117fa9e3afa2a30 20-Aug-2014 vandwalle <vandwalle@google.com> am 1fd74be7: Merge "debug messages for link loss issues" into lmp-dev

* commit '1fd74be7eae25d58cc068e3e2f5eb9269ef4e369':
debug messages for link loss issues
3820aff51e94d70e0c0f730a710ec89ca7e6d579 20-Aug-2014 Lorenzo Colitti <lorenzo@google.com> am 24adb818: Merge "Clear IPv4 addresses when switching from DHCP to static." into lmp-dev

* commit '24adb81839865a6f27fceb8ef709f5c23973cb47':
Clear IPv4 addresses when switching from DHCP to static.
9fdd28a93db1188cfbc207a1c48cc0ecd33590a0 20-Aug-2014 Brian Williammee <bwill@google.com> am 4a6672f9: am 0e916560: Fix copy/paste error in 5GHz connection count

* commit '4a6672f9b14da6a1f937263d88d96b7d963e85e9':
Fix copy/paste error in 5GHz connection count
4a6672f9b14da6a1f937263d88d96b7d963e85e9 20-Aug-2014 Brian Williammee <bwill@google.com> am 0e916560: Fix copy/paste error in 5GHz connection count

* commit '0e916560ab551ac44e6ce0324bdc511f66268944':
Fix copy/paste error in 5GHz connection count
7988fcae6f9cf8be0063a70b42ef58a4fa7feb84 20-Aug-2014 vandwalle <vandwalle@google.com> Merge "remove passpoint, except ANQP - DO NOT MERGE" into lmp-dev
0e916560ab551ac44e6ce0324bdc511f66268944 20-Aug-2014 Brian Williammee <bwill@google.com> Fix copy/paste error in 5GHz connection count

Change-Id: Ic377c5b4b0ab7db060b3b6ec86a3b0a862c32b28
om/android/server/wifi/WifiStateMachine.java
1fd74be7eae25d58cc068e3e2f5eb9269ef4e369 20-Aug-2014 vandwalle <vandwalle@google.com> Merge "debug messages for link loss issues" into lmp-dev
e6574ec7b6b2e7a678da7f77bdaaf31463852b2f 19-Aug-2014 vandwalle <vandwalle@google.com> debug messages for link loss issues

Change-Id: Icbea4bac528eac8f25b8d1f9f1fa79d1ecadb7da
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiStateMachine.java
92e702658bc348fa4504eaef54833859e7413e2a 15-Aug-2014 vandwalle <vandwalle@google.com> remove passpoint, except ANQP - DO NOT MERGE

This CL is dependent on Ic533d1820c470bf2370a92452b37515ef7458f45 and should build when used with this CL


Change-Id: Ic3ae7269f0ca11cec6b7aea5143499e88ecc7149
om/android/server/wifi/passpoint/WifiPasspointCertificate.java
om/android/server/wifi/passpoint/WifiPasspointCertificateHelper.java
om/android/server/wifi/passpoint/WifiPasspointClient.java
om/android/server/wifi/passpoint/WifiPasspointDmClient.java
om/android/server/wifi/passpoint/WifiPasspointDmTreeHelper.java
om/android/server/wifi/passpoint/WifiPasspointHttpClient.java
om/android/server/wifi/passpoint/WifiPasspointServiceImpl.java
om/android/server/wifi/passpoint/WifiPasspointSoapClient.java
om/android/server/wifi/passpoint/WifiPasspointStateMachine.java
6feefc14ba05895b7107fd4029c26add98d81a1f 19-Aug-2014 Lorenzo Colitti <lorenzo@google.com> am 7c236918: am 3b26801d: Stop using LinkProperties for static configuration.

* commit '7c236918b1a9c1329f9f3b79d6fafe806cb5b1e2':
Stop using LinkProperties for static configuration.
7c236918b1a9c1329f9f3b79d6fafe806cb5b1e2 19-Aug-2014 Lorenzo Colitti <lorenzo@google.com> am 3b26801d: Stop using LinkProperties for static configuration.

* commit '3b26801d62a06475b722bbf29cba7f48f376654e':
Stop using LinkProperties for static configuration.
3b26801d62a06475b722bbf29cba7f48f376654e 31-Jul-2014 Lorenzo Colitti <lorenzo@google.com> Stop using LinkProperties for static configuration.

Bug: 16114392
Bug: 16893413
Change-Id: Ib33f35c004e30b6067bb20235ffa43c247d174df
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/p2p/WifiP2pServiceImpl.java
f152a69a5a83eae7b3a8700f6f9257583bf916b8 19-Aug-2014 vandwalle <vandwalle@google.com> am d0c6d2f4: am 8c0a54e9: provide autojoin config threshold, fix bug16990104

* commit 'd0c6d2f436806baf3cd885d38f3f7d4846a4a44f':
provide autojoin config threshold, fix bug16990104
d0c6d2f436806baf3cd885d38f3f7d4846a4a44f 19-Aug-2014 vandwalle <vandwalle@google.com> am 8c0a54e9: provide autojoin config threshold, fix bug16990104

* commit '8c0a54e9b0d3713cab52d06ad8fd7f3a1b6f73a8':
provide autojoin config threshold, fix bug16990104
24adb81839865a6f27fceb8ef709f5c23973cb47 20-Aug-2014 Lorenzo Colitti <lorenzo@google.com> Merge "Clear IPv4 addresses when switching from DHCP to static." into lmp-dev
0ebd6d71cecb5147fad1ca7a7f807aec7ffeddd9 12-Aug-2014 Lorenzo Colitti <lorenzo@google.com> Clear IPv4 addresses when switching from DHCP to static.

This prevents the previous DHCP address from remaining assigned
to the interface, fixing a TODO.


Bug: 16893413
Change-Id: I84e09b8ac0325b839059b2d38086603bd11c7948
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiStateMachine.java
8c0a54e9b0d3713cab52d06ad8fd7f3a1b6f73a8 14-Aug-2014 vandwalle <vandwalle@google.com> provide autojoin config threshold, fix bug16990104

Change-Id: Iac9ec4fe0a721df5f08b90d631025df4d944d088
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiStateMachine.java
e778c763e2b7af0a0b6318a63a5dbb60a85ab031 18-Aug-2014 Robert Greenwalt <rgreenwalt@google.com> am a68451ed: am 0c3dfa47: Merge "Add tcp buffer size data for wifi" into lmp-dev

* commit 'a68451ed609a5b5a8df90f6427f30bd029febe0e':
Add tcp buffer size data for wifi
a68451ed609a5b5a8df90f6427f30bd029febe0e 18-Aug-2014 Robert Greenwalt <rgreenwalt@google.com> am 0c3dfa47: Merge "Add tcp buffer size data for wifi" into lmp-dev

* commit '0c3dfa471750e99231c9bf4d9a53f1e4a2d0daa4':
Add tcp buffer size data for wifi
0c3dfa471750e99231c9bf4d9a53f1e4a2d0daa4 18-Aug-2014 Robert Greenwalt <rgreenwalt@google.com> Merge "Add tcp buffer size data for wifi" into lmp-dev
e693d9490d27bcd91bb1f012bb88ef4c95cdaee3 07-Aug-2014 Robert Greenwalt <rgreenwalt@google.com> Add tcp buffer size data for wifi

bug: 16549611
Change-Id: Ia3819da9d85863a273b93e30c8a9d223ddc7d667
om/android/server/wifi/WifiStateMachine.java
bb7d6266238c60058616fc40163685afad627337 15-Aug-2014 Zoltan Szatmary-Ban <szatmz@google.com> am c244f936: am 97f1a2ce: Merge "Revert "Revert "Revert "Update Trusted Credentials screen in settings"""" into lmp-dev

* commit 'c244f936c12bd7efb8a5860946dfb744b6db7c12':
Revert "Revert "Revert "Update Trusted Credentials screen in settings"""
c244f936c12bd7efb8a5860946dfb744b6db7c12 15-Aug-2014 Zoltan Szatmary-Ban <szatmz@google.com> am 97f1a2ce: Merge "Revert "Revert "Revert "Update Trusted Credentials screen in settings"""" into lmp-dev

* commit '97f1a2ce31c8842c0f0de4660d49233f70c2ea13':
Revert "Revert "Revert "Update Trusted Credentials screen in settings"""
3031a197e564f1d7f5a20f6842dfda487fb50df9 15-Aug-2014 Zoltan Szatmary-Ban <szatmz@google.com> am d057655d: am 71aa1728: Merge "Revert "Revert "Update Trusted Credentials screen in settings""" into lmp-dev

* commit 'd057655df11110adf1dcd0fb8b8e36e5e4c5c386':
Revert "Revert "Update Trusted Credentials screen in settings""
e2713f215ffc8674d4200f0edb681a7a7affe463 15-Aug-2014 Narayan Kamath <narayan@google.com> am 7e986f43: am ee9f7f00: Merge "Revert "Update Trusted Credentials screen in settings"" into lmp-dev

* commit '7e986f43e20789721d5e297ad2519508fed64bae':
Revert "Update Trusted Credentials screen in settings"
61268eb0ab9791e9cb81c15b5b0b7f3ac4cfe33c 15-Aug-2014 Zoltan Szatmary-Ban <szatmz@google.com> am 2224ed34: am 30e6a432: Merge "Update Trusted Credentials screen in settings" into lmp-dev

* commit '2224ed34a881fa3e2be8b5221ea444c05ca5e959':
Update Trusted Credentials screen in settings
9ac1f0a388ab3cf1b0da6a5e98803cf14ab3b5e1 15-Aug-2014 Vinit Deshpande <vinitd@google.com> am 455c3a7e: am ccd5bdb2: Merge "EAP-SIM End-To-End" into lmp-dev

* commit '455c3a7e9e4198a36f56b98f1026ee54f8c0ada4':
EAP-SIM End-To-End
d057655df11110adf1dcd0fb8b8e36e5e4c5c386 15-Aug-2014 Zoltan Szatmary-Ban <szatmz@google.com> am 71aa1728: Merge "Revert "Revert "Update Trusted Credentials screen in settings""" into lmp-dev

* commit '71aa1728f0af364b6d0a032fb615687d3bfce77e':
Revert "Revert "Update Trusted Credentials screen in settings""
7e986f43e20789721d5e297ad2519508fed64bae 15-Aug-2014 Narayan Kamath <narayan@google.com> am ee9f7f00: Merge "Revert "Update Trusted Credentials screen in settings"" into lmp-dev

* commit 'ee9f7f00b3ee67836642f70d7f3d835b9240f09f':
Revert "Update Trusted Credentials screen in settings"
2224ed34a881fa3e2be8b5221ea444c05ca5e959 15-Aug-2014 Zoltan Szatmary-Ban <szatmz@google.com> am 30e6a432: Merge "Update Trusted Credentials screen in settings" into lmp-dev

* commit '30e6a4327b049e291a1cdf19b57571644baba7a2':
Update Trusted Credentials screen in settings
455c3a7e9e4198a36f56b98f1026ee54f8c0ada4 15-Aug-2014 Vinit Deshpande <vinitd@google.com> am ccd5bdb2: Merge "EAP-SIM End-To-End" into lmp-dev

* commit 'ccd5bdb2badfb0db0732c3cd886e1bb31d9669f1':
EAP-SIM End-To-End
97f1a2ce31c8842c0f0de4660d49233f70c2ea13 15-Aug-2014 Zoltan Szatmary-Ban <szatmz@google.com> Merge "Revert "Revert "Revert "Update Trusted Credentials screen in settings"""" into lmp-dev
6e2ae81e7a5a96fe442638d9d2ce9d8d450ee742 15-Aug-2014 Zoltan Szatmary-Ban <szatmz@google.com> Revert "Revert "Revert "Update Trusted Credentials screen in settings"""

This reverts commit fac5b63c2e1ed7ec07a1253ec5b6f42a2a072f1d.

Change-Id: I06bae63f98fce98acf2c9219b54ef0f5adbdaa5b
om/android/server/wifi/passpoint/WifiPasspointSoapClient.java
om/android/server/wifi/passpoint/WifiPasspointStateMachine.java
fac5b63c2e1ed7ec07a1253ec5b6f42a2a072f1d 15-Aug-2014 Zoltan Szatmary-Ban <szatmz@google.com> Revert "Revert "Update Trusted Credentials screen in settings""

This reverts commit 2c1923a320ed038d67bac0912cb99c9d406e96b7.

This should be fine now with all the dependency CLs +2-ed


Change-Id: Ib8348e75f8b79134a42ccfe22582b1b3d185c9c9
om/android/server/wifi/passpoint/WifiPasspointSoapClient.java
om/android/server/wifi/passpoint/WifiPasspointStateMachine.java
2c1923a320ed038d67bac0912cb99c9d406e96b7 15-Aug-2014 Narayan Kamath <narayan@google.com> Revert "Update Trusted Credentials screen in settings"

This reverts commit f1f5c7cba10d7c625e01f5f5c148f1f8c3987eca.

Change-Id: I22ea9fb43ff4fdc5a9360a8571419e8d2e4f4214
om/android/server/wifi/passpoint/WifiPasspointSoapClient.java
om/android/server/wifi/passpoint/WifiPasspointStateMachine.java
ee9f7f00b3ee67836642f70d7f3d835b9240f09f 15-Aug-2014 Narayan Kamath <narayan@google.com> Merge "Revert "Update Trusted Credentials screen in settings"" into lmp-dev
30e6a4327b049e291a1cdf19b57571644baba7a2 15-Aug-2014 Zoltan Szatmary-Ban <szatmz@google.com> Merge "Update Trusted Credentials screen in settings" into lmp-dev
dbd6933aae99302b75683f8463cd17df554dc599 14-Aug-2014 Vinit Deshpande <vinitd@google.com> EAP-SIM End-To-End

This change fixes all remaining issues with EAP-SIM. It now handles
multiple challenges coming from supplicant and corrects supplicant
command syntax.

Change-Id: Idc47b454863aa1990d4f53138f00f312622792d2
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
71aa1728f0af364b6d0a032fb615687d3bfce77e 15-Aug-2014 Zoltan Szatmary-Ban <szatmz@google.com> Merge "Revert "Revert "Update Trusted Credentials screen in settings""" into lmp-dev
610685b32b831b1065449c52f5bc15cdc82d94e7 14-Aug-2014 Vinit Deshpande <vinitd@google.com> am 736c9583: am 981e9669: Fix getAdapters() hang

* commit '736c95830e263d71c9f9fcf57bbde7119aa7b876':
Fix getAdapters() hang
736c95830e263d71c9f9fcf57bbde7119aa7b876 14-Aug-2014 Vinit Deshpande <vinitd@google.com> am 981e9669: Fix getAdapters() hang

* commit '981e966999f4448a682084d6657d07bab2bbc13e':
Fix getAdapters() hang
981e966999f4448a682084d6657d07bab2bbc13e 14-Aug-2014 Vinit Deshpande <vinitd@google.com> Fix getAdapters() hang

getAdapters() hangs in certain Wifi states because there is no code
to generate a default reply. This change adds default reply so it
returns something in all states.

Bug: 16982058

Change-Id: I07cae455c6335e622fbd9a79f3837128e73e302c
om/android/server/wifi/WifiStateMachine.java
67b2c09d788cd0ad9f4ca3daff7f6e2260e378a6 13-Aug-2014 Sky Faber <skyf@google.com> am 77ebb56c: am 2a325cd0: removeNetwork needs to perform owner check against userId not uid.

* commit '77ebb56c9bc1c93dc1ca38cf4f99b5964c43fb9a':
removeNetwork needs to perform owner check against userId not uid.
77ebb56c9bc1c93dc1ca38cf4f99b5964c43fb9a 13-Aug-2014 Sky Faber <skyf@google.com> am 2a325cd0: removeNetwork needs to perform owner check against userId not uid.

* commit '2a325cd07d40941adb93c1284abb263ba650c213':
removeNetwork needs to perform owner check against userId not uid.
2a325cd07d40941adb93c1284abb263ba650c213 12-Aug-2014 Sky Faber <skyf@google.com> removeNetwork needs to perform owner check against userId not uid.

Bug: 16952565
Change-Id: I78666c34fc919bbc96ef92b02445b93b0948f743
om/android/server/wifi/WifiServiceImpl.java
911d6087e0e037c8f401f4c3464977f70e18621a 12-Aug-2014 vandwalle <vandwalle@google.com> am 10e28d77: am 68a6d9ba: Merge "handle supplicant disconnected state change in roaming state + make roaming less erratic" into lmp-dev

* commit '10e28d777a352e341e0734fcebf82f007e3d3465':
handle supplicant disconnected state change in roaming state + make roaming less erratic
10e28d777a352e341e0734fcebf82f007e3d3465 12-Aug-2014 vandwalle <vandwalle@google.com> am 68a6d9ba: Merge "handle supplicant disconnected state change in roaming state + make roaming less erratic" into lmp-dev

* commit '68a6d9ba04f68ec4c76edc049ac827331d10e707':
handle supplicant disconnected state change in roaming state + make roaming less erratic
68a6d9ba04f68ec4c76edc049ac827331d10e707 12-Aug-2014 vandwalle <vandwalle@google.com> Merge "handle supplicant disconnected state change in roaming state + make roaming less erratic" into lmp-dev
c773639ecf8432d1623421a5daff0a36cf1b07bd 12-Aug-2014 Vinit Deshpande <vinitd@google.com> am f78b842d: am 6c6698e2: Merge "Fix non-report of full scan results when scanning bands" into lmp-dev

* commit 'f78b842d3e91fe84be73a3bb1eed64b15fb9c653':
Fix non-report of full scan results when scanning bands
f78b842d3e91fe84be73a3bb1eed64b15fb9c653 12-Aug-2014 Vinit Deshpande <vinitd@google.com> am 6c6698e2: Merge "Fix non-report of full scan results when scanning bands" into lmp-dev

* commit '6c6698e260cbb0ca9a445e0f7122ae4c7c9cb938':
Fix non-report of full scan results when scanning bands
6c6698e260cbb0ca9a445e0f7122ae4c7c9cb938 12-Aug-2014 Vinit Deshpande <vinitd@google.com> Merge "Fix non-report of full scan results when scanning bands" into lmp-dev
63243b616f0e24d2c145d77582cedc2856456bcb 11-Aug-2014 Vinit Deshpande <vinitd@google.com> Fix non-report of full scan results when scanning bands

We use channel lists to report events, unfortunately, channel list is
empty when bands are used. This change looks up the channel list for
the band before firing events based on it.

Bug: 16907772
Change-Id: Iab317ad4ad5bc9d2e9d9c0215f8cbcfc4ea967ad
om/android/server/wifi/WifiScanningServiceImpl.java
c4deee4ba92e100006706fdded64efc207be007d 11-Aug-2014 Vinit Deshpande <vinitd@google.com> am 331505ee: am 03015787: Merge "Fix unreliable onQuiscence event" into lmp-dev

* commit '331505ee7955a91ed5fe00af3009524637ce69d2':
Fix unreliable onQuiscence event
331505ee7955a91ed5fe00af3009524637ce69d2 11-Aug-2014 Vinit Deshpande <vinitd@google.com> am 03015787: Merge "Fix unreliable onQuiscence event" into lmp-dev

* commit '030157871d5deea64f45e4d0914e3bfbf4d94c37':
Fix unreliable onQuiscence event
574d0e02e6a3e0ad4f6544b75efff148c10d8997 11-Aug-2014 Jon Larimer <jlarimer@google.com> am b6139713: am 8e6144b4: Fix null dereference in enableTdls() and enableTdlsWithMacAddress()

* commit 'b613971395c3accdcc6bd2d85cd84fbc55706e4f':
Fix null dereference in enableTdls() and enableTdlsWithMacAddress()
b613971395c3accdcc6bd2d85cd84fbc55706e4f 11-Aug-2014 Jon Larimer <jlarimer@google.com> am 8e6144b4: Fix null dereference in enableTdls() and enableTdlsWithMacAddress()

* commit '8e6144b4059fc2117be23d7222893bc57a33f64d':
Fix null dereference in enableTdls() and enableTdlsWithMacAddress()
8e6144b4059fc2117be23d7222893bc57a33f64d 20-Jun-2014 Jon Larimer <jlarimer@google.com> Fix null dereference in enableTdls() and enableTdlsWithMacAddress()

Change-Id: I37acf88c9adefba240fb8bc8a9e633ddcd823d21
Bug: 15775601
om/android/server/wifi/WifiServiceImpl.java
4dbfefd99e51ab1cca058026c90f8093b099198b 11-Aug-2014 Vinit Deshpande <vinitd@google.com> Fix unreliable onQuiscence event

Turns out that new bssid settings weren't always applied to the
significant wifi change state machine. Also broadened the RSSI
range to trigger events at larger distance.

Bug: 16660861
Change-Id: I02518833a4f900c380198ef47c42a0622c258fd2
om/android/server/wifi/WifiScanningServiceImpl.java
a089077f42c27922872631ccc2c77e1e036bb3a5 10-Aug-2014 Vinit Deshpande <vinitd@google.com> Merge commit '3c3fcca5' into manualmerge

Change-Id: I045c50aa69e4f233516493f8abb31aff27ac38a6
3c3fcca514b9ea2acdd21d572cee21435fea8d79 10-Aug-2014 Vinit Deshpande <vinitd@google.com> am 33b575ca: EAP-SIM End-to-end

* commit '33b575ca6bee66183929f9474b5a161432918604':
EAP-SIM End-to-end
9c2ba85306ddad3cceb533cead8f12725e8c5e04 10-Aug-2014 Brian Carlstrom <bdc@google.com> Move from DERObjectIdentifier to ASN1ObjectIdentifier for bouncycastle 1.51

(cherry picked from commit 942910a5d1e5b72fb53d674fddaf6a1d66ca5c87)

Change-Id: I206024985e8dfde443a9b2cfc2a8b2b76f003f8a
om/android/server/wifi/passpoint/WifiPasspointCertificate.java
942910a5d1e5b72fb53d674fddaf6a1d66ca5c87 10-Aug-2014 Brian Carlstrom <bdc@google.com> Move from DERObjectIdentifier to ASN1ObjectIdentifier for bouncycastle 1.51

Change-Id: I3e0388acc38d83d074ae2059cb3602462728d1a6
om/android/server/wifi/passpoint/WifiPasspointCertificate.java
33b575ca6bee66183929f9474b5a161432918604 09-Aug-2014 Vinit Deshpande <vinitd@google.com> EAP-SIM End-to-end

Change-Id: I9478e6a492c469d57bb020b8f858e523ea6a92d1
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
030157871d5deea64f45e4d0914e3bfbf4d94c37 11-Aug-2014 Vinit Deshpande <vinitd@google.com> Merge "Fix unreliable onQuiscence event" into lmp-dev
97b9c4fef6e372d1f19b333c7a67ff27ef80baf0 08-Aug-2014 vandwalle <vandwalle@google.com> handle supplicant disconnected state change in roaming state + make roaming less erratic

bug: 16753407
bug: 16823537

Change-Id: I47f1073b3775880d261ec2a963732c35454173cf
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiStateMachine.java
e201fc1699b8de2b5067e9ca75bb49954df1c69d 08-Aug-2014 Robert Greenwalt <rgreenwalt@google.com> am d432374e: Merge "Fix reading wifi configurations from the config store." into lmp-dev

* commit 'd432374e5daff944bb5bb27a41d88ea49c99e14d':
Fix reading wifi configurations from the config store.
d432374e5daff944bb5bb27a41d88ea49c99e14d 08-Aug-2014 Robert Greenwalt <rgreenwalt@google.com> Merge "Fix reading wifi configurations from the config store." into lmp-dev
4d3bff566b2cd0c3fd4d118eb6aae42ab3e9b5dd 08-Aug-2014 Lorenzo Colitti <lorenzo@google.com> Fix reading wifi configurations from the config store.

IpConfiguration's readIpAndProxyConfigurations method returns a
SparseArray mapping network IDs to IpConfiguration objects.
Unfortunately WifiConfiguration's readIpAndProxyConfigurations
iterates over the array and attempts to find the network the
configuration is for by looking at the sequence number of the
configuration, not the actual key in the SparseArray.

Bug: 16382665
Change-Id: I3dfef9123382b81a2a22cf5df7a5bb77611059aa
om/android/server/wifi/WifiConfigStore.java
c35361d54d4885c3174499e4ad46d3324387a9bb 08-Aug-2014 Vinit Deshpande <vinitd@google.com> Workaround RTT supported bug

Support for Device to AP rtt should be advertised in
wifi_get_supported_feature_set(). It is not there yet, using
a hardcoded value for now.

Bug: 16854821
Change-Id: Ib468939dc03d91d3f2848fd7ad2f6cbf6013684e
om/android/server/wifi/WifiNative.java
1814928371a30b11af31e2bbe5210c4337ed16f3 06-Aug-2014 Vinit Deshpande <vinitd@google.com> Fix multiple null pointer exceptions in WifiScanningService

Couple can happen because of race conditions and one is happening becuase
of driver failure; which will be addressed separately.

Bug: 16706416
Bug: 16732450
Bug: 16791198

Change-Id: I983cd5fd4077273802a9ad65f76d3c31452e9ebc
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiScanningServiceImpl.java
663ec152411cf88dbc7b9dd50277c844761bea0d 08-Aug-2014 Chelsea Derrick <chelsead@google.com> Merge "Revert "Broadcast wifi credential change from WifiStateMachine. [DO NOT MERGE]"" into lmp-dev
0a0694d89195ac361a02bf73d5bf35b1e9050c6c 07-Aug-2014 Chelsea Derrick <chelsead@google.com> Revert "Broadcast wifi credential change from WifiStateMachine. [DO NOT MERGE]"

This reverts commit a618f986e12b0f68f7b4cdfff51c6fa8baed22d5.

Bug: 16871063
Change-Id: I93623be92f2de41789b16827867f3f95bf0480c5
om/android/server/wifi/WifiStateMachine.java
c7af335ba2adbb95fffacf99828287f93b4b2d38 06-Aug-2014 vandwalle <vandwalle@google.com> Merge "check null pointer on mNetworkAgent" into lmp-dev
6e51388c5b7d7840644570de5bc61edbd173b203 06-Aug-2014 vandwalle <vandwalle@google.com> check null pointer on mNetworkAgent

Bug:16776614

Change-Id: I6af588a0bc7f9048174d359f41f63ac9acb98147
om/android/server/wifi/WifiStateMachine.java
7806f8c800754da0f76d7a0c1a6a590381dac7a8 05-Aug-2014 vandwalle <vandwalle@google.com> add debouncing of the Layer 2 spurious disconnects

Change-Id: I45291d0369977c7a3bdbf65ef10632c203d359b4

Changes to be committed:
modified: service/java/com/android/server/wifi/WifiAutoJoinController.java
modified: service/java/com/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiStateMachine.java
487a655bd40563a1a4ba57bb66c914de8174f4f2 04-Aug-2014 Lorenzo Colitti <lorenzo@google.com> Merge "Unbreak WifiStateMachine IP provisioning logic." into lmp-dev
badd604178e757a65dcff91ab1ff818e3527c8e3 01-Aug-2014 Lorenzo Colitti <lorenzo@google.com> Unbreak WifiStateMachine IP provisioning logic.

The change from switching to CONNECTED based on DHCP to
switching to CONNECTED based on link properties, necessary to
support IPv6-only networks, broke some of WifiStateMachine's
IP provisioning logic. Among other things:

1. DHCP success when roaming would get stuck in ObtainingIpState
state because the updateLinkProperties would see that nothing
had changed and take no action.
2. DHCP timeout would not cause a disconnect. The code to handle
that was just not there. :-(
3. Wifi would notify ConnectivityService that it was ready as
soon as it had an IPv4 address, but before DHCP completed, at
which point the network was unusable because it had no
default route and no DNS server. The network was fixed
immediately afterwards, but it caused a 5-second switching
delay because NetworkMonitor immediately tried to validate,
failed, and waited 5 seconds.
3. Wifi would not reconnect to the current network after a
runtime restart, because the IP address was already there.

All these problems happened because we changed the code from
edge-triggered to level-triggered, but that doesn't work well
in IPv4, because it's not possible to tell from LinkProperties
alone whether IPv4 configuration succeeded on the interface.

This change switches IPv4 provisioning back to being
edge-triggered, which should hopefully fix all the above
problems in the right way. Testing so far includes:

1. Connecting to GoogleGuest works.
2. Connecting to a network without a DHCP server (and without
IPv6) disconnects after 30 seconds, and gives up completely
after 9 tries.
3. Connecting to an IPv6-only network works.
4. Configuring a static IP on GoogleGuest works.
5. Wifi disconnects if a DHCP renewal times out.

I'm not sure how to test roaming.

Bug: 16269674
Bug: 16631731
Bug: 16663980
Bug: 16667349
Change-Id: I8e28c630c54a5f3f66bf0feb9fd328ab452de740
om/android/server/wifi/WifiStateMachine.java
08b2a6f380652e7836687632a10e5183fd7ac689 31-Jul-2014 Lorenzo Colitti <lorenzo@google.com> Clear IP addresses before starting the supplicant.

This is necessary because if the runtime crashes when the
interface has an IPv4 address assigned to it, and wifi reconnects
and gets the same IPv4 address, NetlinkTracker won't tell us
about the address, because nothing has changed. This causes us to
think that we have no IPv4 address, when in fact we do.

Bug: 16631731
Change-Id: I4878408d5fb4c0128657aabb7670e48c689021d8
om/android/server/wifi/WifiStateMachine.java
a232280e191f8a3a2c825d544c6fce77914a37f5 31-Jul-2014 Vinit Deshpande <vinitd@google.com> Merge "Rename HotspotListener to BssidListener" into lmp-dev
b7cc309f06da8a18224057c21ba086f8550367d6 31-Jul-2014 Vinit Deshpande <vinitd@google.com> Rename HotspotListener to BssidListener

And other usage of term Hotspot. This is to be technically correct
with the name usage, should the API become public later.

This change also fixes few outstanding requests from GScan API.These
include

a. An event with scan results when REPORT_AFTER_EACH_SCAN is set.
b. ScanSettings now takes in number of APs as an argument.

Bug: 16633917
Bug: 16631524

Change-Id: Id160f9f14193a37cce5f3ab8d6ea528344b788a0
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiScanningServiceImpl.java
7e170fe5c25a7691ac984f0fedb3939b8bec4119 30-Jul-2014 vandwalle <vandwalle@google.com> Merge "fix getNetworkScore" into lmp-dev
1db63db890fcb9051f402fdfd449eb0b80e2053c 30-Jul-2014 vandwalle <vandwalle@google.com> fix getNetworkScore

Change-Id: I60bc5c458938f662b2550e48839cb455764dc037
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiNetworkScoreCache.java
326120045502363422cf5c52a467163d4bcb703a 30-Jul-2014 vandwalle <vandwalle@google.com> add debug log for RSSI_PKTCNT_FETCH

Change-Id: I54f920e7373febf3874deb194011e98c05eb1a23
om/android/server/wifi/WifiStateMachine.java
f1f5c7cba10d7c625e01f5f5c148f1f8c3987eca 29-Jul-2014 Zoltan Szatmary-Ban <szatmz@google.com> Update Trusted Credentials screen in settings

Trusted credentials for both the primary user and its managed profiles are shown
on the Trusted Credentials fragment. All functionalities (e.g. disabling/enabling
of certificates) remain available.

Bug: 16029580
Change-Id: I76200cca5dce8bf2c042a78dcfbf016f14c3f1ab
om/android/server/wifi/passpoint/WifiPasspointSoapClient.java
om/android/server/wifi/passpoint/WifiPasspointStateMachine.java
c290d8dff6172d5fde7b9dfd74d3a20785dab246 29-Jul-2014 vandwalle <vandwalle@google.com> fix handling DHCP status

Change-Id: Ib4dfc9a1f84d6faaaf71adf63c8e2457e95646fd
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiStateMachine.java
ede507649471f1113e9e1919812115ca5a6bc0c8 29-Jul-2014 vandwalle <vandwalle@google.com> add logs and fix compareWifiConfigurationsWithScorer

Change-Id: I7eeb489b89519bd79d7e3df0fe3ae400debfe566
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiStateMachine.java
6b700edd56b6be91750e01c3a06032b23ac6238a 28-Jul-2014 vandwalle <vandwalle@google.com> Merge "introduce WifiConnectionstatistics" into lmp-dev
c298087de50ea56c31a4ade7ee1e83b313bb63c7 26-Jul-2014 vandwalle <vandwalle@google.com> introduce WifiConnectionstatistics

This CL is dependent on I51fbbf062feb22c5f16b438675519064cc43e160

Change-Id: I10584a447fecd977df3eefd8e2cc028bd26ec0e3
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
02a1f98f2cecb8ae2d466d6f9fab06b473f970dd 26-Jul-2014 Vinit Deshpande <vinitd@google.com> Enable RTT End-to-end

This change includes various fixes to first RTT implementation and
enables RTT APIs end-to-end. Fixes include proper marshalling of
objects across API and service and JNI fixes.

This change also includes fix for another WifiNative bug that causes
crash on startup.

Bug: 15841411


Change-Id: Ie4ba1ffc6c5b42593e931438b3f03e201ff6be71
om/android/server/wifi/RttService.java
om/android/server/wifi/WifiNative.java
c25ff5183d509e8a2ecaf1b52f83cbd7023e6a79 29-Jul-2014 vandwalle <vandwalle@google.com> Merge "add verboser logs for network scorer" into lmp-dev
e8c89583e489d451880471b7cc7659bd9fa802f4 29-Jul-2014 vandwalle <vandwalle@google.com> add verboser logs for network scorer

Change-Id: I8e461615f1ae85cd0712a627561cee329a5fb4e5
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiStateMachine.java
2f3b6d4a82bfb828ba7ce5f7cf4e54ff57821888 29-Jul-2014 vandwalle <vandwalle@google.com> treat all dhcp completion without provisioning as errors

Change-Id: I4f27e166491006a3432e73a490653c6252fbb95d
om/android/server/wifi/WifiStateMachine.java
82d20190c3ec3a080d928a581c40311c66345cc8 24-Jul-2014 vandwalle <vandwalle@google.com> handle IP address loss if DHCP fails

Bug:16525514

Change-Id: I367a024835acf06cf4dda7f357b70494b9981e03
om/android/server/wifi/WifiStateMachine.java
2451dbcc4f9641df188326215b204b798eb70c46 23-Jul-2014 vandwalle <vandwalle@google.com> autojoin fixes:

- make use of network scorer for autojoin
- Bug:16484607

Change-Id: If658d82bb6e3f61ed0476d41b40bb274a1931b2f
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiNetworkScoreCache.java
om/android/server/wifi/WifiStateMachine.java
6751767bfe5d3a82c594e7abba77b27b0aecb28d 18-Jul-2014 Sreeram Ramachandran <sreeram@google.com> Fix WiFi-Direct.

Send explicit commands to netd to add routes for the p2p interface. This already
happens via the tetherInterface() command when we are the group owner, so the
new command is used only when we are not a group owner.

Bug: 15413694

Change-Id: I36effc438d5ac193a77174493bf196cb68a5b97a
om/android/server/wifi/p2p/WifiP2pServiceImpl.java
f01a9c36967a56d0d042e63984c2c17d978d50e3 22-Jul-2014 Robert Greenwalt <rgreenwalt@google.com> Merge "Clean up Verifying state so we don't churn." into lmp-dev
5a5dc2c0e256ec34e75bb5ec92c4726f9bbc918a 21-Jul-2014 vandwalle <vandwalle@google.com> Merge "a few additional logs and code standard rules" into lmp-dev
4dd46ff3cff8e4e66516600ffdac98601e8bf73d 18-Jul-2014 Robert Greenwalt <rgreenwalt@google.com> Clean up Verifying state so we don't churn.

If it goes to disconnected we will actually get unwanted and
do an L2 disconnect. Instead, rely on down scoring.

Change-Id: I87dc52957fd6515920482ba929331567cf7b8253
om/android/server/wifi/WifiStateMachine.java
931338d1533d1bd11ba0e5aebb4e4b7b2c8ab056 18-Jul-2014 vandwalle <vandwalle@google.com> a few additional logs and code standard rules

Change-Id: I932e895fefd7b6c9d8ad58ef99312c980643f2d2
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiStateMachine.java
0821ef3917e8305ceb58c8b9c6f7bc4c6d35252b 18-Jul-2014 Lorenzo Colitti <lorenzo@google.com> Merge "Properly quote WPA enterprise config fields." into lmp-dev
7b051c83f9bb0855ba5442f0dcd471002832c62c 17-Jul-2014 vandwalle <vandwalle@google.com> Merge "fix connecting to OSU server" into lmp-dev
52e79f112225e158c5de12685e55906de5e222b9 17-Jul-2014 vandwalle <vandwalle@google.com> fix connecting to OSU server

Change-Id: I93d50dac9a052736d63300d1cdd3d72d90614e7f
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/passpoint/WifiPasspointStateMachine.java
3249e2d02cd39f6e2fee093d6d8f4833a51001d5 15-Jul-2014 Lorenzo Colitti <lorenzo@google.com> Properly quote WPA enterprise config fields.

When filling in WifiConfiguration variables based on supplicant
state, properly quote WPA enterprise keys that need to be quoted.
Otherwise, when we attempt to set these config keys, we end up
sending commands ike "SET_NETWORK 4 identity foo", which are
invalid because "foo" needs to be quoted.

The list of fields that need to be quoted was based on the code
in WifiEnterpriseConfig.java.

Bug: 15870625
Change-Id: Icf06fbaa133ac5d195791fa4cfbce5d7d1e610bf
om/android/server/wifi/WifiConfigStore.java
baca1d162eb96c4788f25d7cceb1e77c236d231f 17-Jul-2014 Chelsea Derrick <chelsead@google.com> Merge "Broadcast wifi credential change from WifiStateMachine. [DO NOT MERGE]" into lmp-dev
a618f986e12b0f68f7b4cdfff51c6fa8baed22d5 08-Jul-2014 Chelsea Derrick <chelsead@google.com> Broadcast wifi credential change from WifiStateMachine. [DO NOT MERGE]

Bug: 15703353
Change-Id: I62f582ac8cbfd8748c35d73daa2f733665cc0fa8
(cherry picked from commit 09295c2d809d1c7f797eafe039b6b68e7a49c82f)
om/android/server/wifi/WifiStateMachine.java
149d88f0dd42be76c573ac6beef6c25434698a0e 17-Jul-2014 Vinit Deshpande <vinitd@google.com> Merge "Introduce RTT Manager" into lmp-dev
9878c61bbd81176561991be025af44efc67332fe 17-Jun-2014 Wenchao Tong <tongwenchao@google.com> Add a new SystemApi, getPrivilegedConfiguredNetworks(). Part 2 [DO NOT MERGE]

Implements the getPrivilegedConfiguredNetworks() in WifiServiceImpl.

Bug: 15703353
Change-Id: If3eaca3286e77b780272f42a28772d1d8d39db65
(cherry picked from commit 76ddde4965b1460248eb21d0ccebed687c2b3fb3)
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
143657392bf0702a155fe688171a5abbf4c86570 01-Jul-2014 Vinit Deshpande <vinitd@google.com> Introduce RTT Manager

Change-Id: Ic9a16d587897b272f85cdb2b8c52b51bca060d18
om/android/server/wifi/RttService.java
om/android/server/wifi/WifiNative.java
e0e491671f348cceb6e20fdc55438d8cfd2f07f1 15-Jul-2014 Robert Greenwalt <rgreenwalt@google.com> Fix 2.4/5 wifi roaming.

The redesign of wifi ip address optaining assumed we would never
go from have-ip -> have-ip, ie we must lose our ip config before we can
gain an ip config. Unfortunately at least one condition does just this:
Our inter-band roaming
To leave OBTAINING_IP_ADDRESS we need to tweak the code to generate
the success signal even if the new address is the same.

bug:16269674
Change-Id: I340b24839565fa62fd3c7d9d373695d1d4007412
om/android/server/wifi/WifiStateMachine.java
94edde8d382517403591bad66040cea8b00d465e 12-Jul-2014 vandwalle <vandwalle@google.com> Merge "fix null pointer dereference in log message Bug:16211167"
3a2a3d226881cce8a4e511302231d843b0def303 12-Jul-2014 vandwalle <vandwalle@google.com> fix null pointer dereference in log message
Bug:16211167

Change-Id: I1d9092b73cc7015535e0f1503364f6c592fb08c1
om/android/server/wifi/WifiAutoJoinController.java
002ea67f42b0f69a8c9fa4719391f9476567b762 11-Jul-2014 Sky Faber <skyf@google.com> Disallow forget/remove network for secondary users.

Change-Id: I07be23c26f45a77f5998f200bc9682dedbfa7916
om/android/server/wifi/WifiServiceImpl.java
1ecb0083490436303cdb89bc4c46b6743ea0afa8 10-Jul-2014 Sky Faber <skyf@google.com> Re-disable scan for background users.
Temporarily allow FORGET_NETWORK as secondary user.

Bug: 16190728
Bug: 15437477
Change-Id: Ib4241421bcb9d15f6aab30099f4f36aeb9dfcf72
om/android/server/wifi/WifiServiceImpl.java
a632d8a6edd350c7644b593b18eceaa5b368505b 01-Jul-2014 Vinit Deshpande <vinitd@google.com> Introduce Wifi Adapters

This change extracts all the wifi interfaces on the device; and provides
its supported features.

Change-Id: I7fbdbec684d653a6e4bf851797e3065ce222e873
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
12836d34cc6c4497c1fa5adbb956684ecec7578e 27-Jun-2014 Vinit Deshpande <vinitd@google.com> Lower minimum scanning period in WifiScanner

This change also fixes reporting errors - or rather non-reporting
of errors when starting a scan fails in the driver/firmware.

Bug: 15697516

Change-Id: I4af8200a23c2b61b2505424a3832ca47d390fd80
om/android/server/wifi/WifiScanningServiceImpl.java
9c1d6f995555aaaee60648419bc84921f26b1374 10-Jul-2014 Robert Greenwalt <rgreenwalt@google.com> Merge "Refactor wifi p2p's startDhcpServer function"
8b2bd657976c86e0909ad792f6f96ad94db45c28 24-Jun-2014 Lorenzo Colitti <lorenzo@google.com> Keep IPv6 enabled whenever L2 is connected.

Currently we only enable IPv6 (which starts IPv6 configuration)
when DHCP succeeds. This obviously will not work on networks
that don't have IPv6.

Instead, enable IPv6 when we start DHCP, so IPv4 and IPv6
configuration proceed in parallel. Also don't disable IPv6 when
verifying poor link. I believe the reason for doing so was that
the captive portal detection code was IPv4-only, but now with the
multinetwork APIs we can support captive portal detection over
IPv6.

Bug: 9180552
Change-Id: I52c8776f1c910255784981ed77a14693ad52d674
om/android/server/wifi/WifiStateMachine.java
da2ec427a621afecd800f59b8004542d083be92b 10-Jul-2014 Robert Greenwalt <rgreenwalt@google.com> Merge "Get DNS configuration from Netlink too."
12bc7aa45700513cace98ab43f309121c39780ed 10-Jul-2014 Robert Greenwalt <rgreenwalt@google.com> Merge "Decide if IP configuration is complete independently of DHCP"
40ff222cec1bd05879edb53abc75c6deead734ca 01-Jul-2014 vandwalle <vandwalle@google.com> handle IDENTITY message and bssid blacklist

Bug:15990551
Bug:15977507

Change-Id: I78b03915781bd6d5f9f5881c80324a2788b9e837
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
c35d728a15e9270f5642ef79f5245c89d749285f 03-Jul-2014 Sky Faber <skyf@google.com> Enable ability for secondary users to scan for networks, but not forget.

Bug: 15437477
Bug: 14676589
Change-Id: I3f1956265f4877b8c3cba138628b7393c393d175
om/android/server/wifi/WifiServiceImpl.java
c13bd2d66aee1fded082c8ce18e113fcec03cba1 03-Jul-2014 roger.chang <roger.chang@mediatek.com> Hotspot 2.0 - connect R1 used API to stateMachine(1/2)

Change-Id: Id9303af3edb24e858bb2782088cd09eb03d30f72
om/android/server/wifi/passpoint/WifiPasspointServiceImpl.java
om/android/server/wifi/passpoint/WifiPasspointStateMachine.java
232062d1f830937cf635597698cafe17271f4f9f 01-Jul-2014 roger.chang <roger.chang@mediatek.com> Hotsopt 2.0 - code fine tune(1)

- fix AAA trust root empty create credential fail

Change-Id: I1b3df5189de1d6c222661609bc6a9b21be13a076
om/android/server/wifi/passpoint/WifiPasspointCertificate.java
om/android/server/wifi/passpoint/WifiPasspointHttpClient.java
om/android/server/wifi/passpoint/WifiPasspointSoapClient.java
om/android/server/wifi/passpoint/WifiPasspointStateMachine.java
5039609c4772f26731fbf260398e2dba5d815902 30-Jun-2014 roger.chang <roger.chang@mediatek.com> Hotspot 2.0 - random port number

Change-Id: I70178590306ddd6fe79efbee8065919ec57571cd
om/android/server/wifi/passpoint/WifiPasspointStateMachine.java
a43d6d71ad51ce7fe54198d9b60d554208054eb8 24-Jun-2014 Lorenzo Colitti <lorenzo@google.com> Get DNS configuration from Netlink too.

This is required to learn IPv6 DNS servers, which come in from
netlink via RDNSS options in IPv6 Router Advertisements.

Bug: 9180552
Change-Id: I035f4c3cac6d8edd94ff1b3d586d6bd40e0889b1
om/android/server/wifi/WifiStateMachine.java
14be3cde626bd5935f599cd6e0fca72cf1c4695d 23-Jun-2014 Lorenzo Colitti <lorenzo@google.com> Decide if IP configuration is complete independently of DHCP

Currently, WifiStateMachine assumes that IP configuration is
complete and transitions to VerifyingLinkState when it receives a
DHCP_SUCCESS message. This won't work if there no IPv4. Instead,
decide whether IP configuration is complete by examining the
actual configuration inside LinkProperties.

Bug: 9180552
Change-Id: I4499b59030e8e581cce620b57bc4e58b7b7d1ab1
om/android/server/wifi/WifiStateMachine.java
b04dffecf71a3665b2f143c577ec2fbbd5076cdf 02-Jul-2014 Julia Reynolds <juliacr@google.com> Merge "Apply DISALLOW_CONFIG_TETHERING to wireless access points."
13cddb5337418359eb5f9bebd0504fbc5c47fc41 01-Jul-2014 Julia Reynolds <juliacr@google.com> Apply DISALLOW_CONFIG_TETHERING to wireless access points.

Bug: 15852213
Change-Id: I1f1adb8762bf7b694aa92f4b0a393d8e06c610bf
om/android/server/wifi/WifiServiceImpl.java
2c141fc79e1e66c5b5f7dd7307ad7cb8d1e9aaac 02-Jul-2014 Robert Greenwalt <rgreenwalt@google.com> Merge "Simplify the network transition wakelock."
96d15e49bb2d9f22b307b4c9cafd5f51b87667a1 01-Jul-2014 Yuhao Zheng <yuhaozheng@google.com> Add two Passpoint fields to WifiConfiguration

We need two new fields in WifiConfiguration for Hotspot 2.0:
requirePMF & updateIdentifier

Change-Id: I46e5753d50423828f2aa531d469b49a88850e055
om/android/server/wifi/WifiConfigStore.java
10206e44bff4f2844ff318e8be1890b08197a9ba 20-Jun-2014 roger.chang <roger.chang@mediatek.com> Hotspot 2.0 fix launch browser method

Change-Id: I7a1f668c6ddd7e2f0b0498a35dc00954d39aa0d9
om/android/server/wifi/passpoint/WifiPasspointSoapClient.java
b57df70bdf17ba45ef4d18b11414cb24dcbe1fb9 28-Jun-2014 vandwalle <vandwalle@google.com> clean up the connect/disconnect procedure

Change-Id: Iba87591e790106b882d465dbba3ddac120f044d9
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiStateMachine.java
d31e487847b954a9e763c5dd72adbf5efd590814 26-Jun-2014 vandwalle <vandwalle@google.com> dont try to set an obfuscated password into wpa_supplicant

Bug: 15870625

Change-Id: I7d4b15cbd5d9ba6afefafe16f5ba8c0a8510cff3
om/android/server/wifi/WifiConfigStore.java
5394340995ed67c8da3f00b7aae886aec47d6bcc 26-Jun-2014 Robert Greenwalt <rgreenwalt@google.com> Simplify the network transition wakelock.

Make it all internal to ConnectivityService - we know when a network
is lost, so grab a wakelock then.
Moves the call out of WifiStateMachine which was grabbing at bad times
like every dhcp renewal or corp-network roam. These would always
go the full 1 minute and chew up battery.

bug:15595155
Change-Id: I80157a818cc149072cc7706d78c1e79c6e679ab3
om/android/server/wifi/WifiStateMachine.java
a2903b7c6fc2419d48fd9976fa24852370653c4a 26-Jun-2014 vandwalle <vandwalle@google.com> fix a merge issue

Change-Id: Ic1e9bab8ec6cf4b4525d2815b29db8e617960504
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiStateMachine.java
bfd24ffeada0cfc198befdbdc7139c84a9095557 26-Jun-2014 Andres Morales <anmorales@google.com> Merge "piping commands for handover from supplicant"
5c08cc119b92af69997af194cc8b6d0111e37d31 07-Feb-2014 Andres Morales <anmorales@google.com> piping commands for handover from supplicant

supplicant exposes methods to retrieve handover
protocol messages. need to pipe these up to NfcService.

Change-Id: I2696ed4b0ccbaa47a75a303315f554965c5c9dd4
om/android/server/wifi/WifiNative.java
om/android/server/wifi/p2p/WifiP2pServiceImpl.java
dbfe9e532b02797d08c8bdf9915659aef55fff64 25-Jun-2014 vandwalle <vandwalle@google.com> Merge "improve link flapping"
b07da189850a4bfa268f8ab9be7867935eb2ecb5 24-Jun-2014 vandwalle <vandwalle@google.com> improve link flapping

Change-Id: Ie378dde318dccaa566f660c9497bae31d4a9f1ab
om/android/server/wifi/StateChangeResult.java
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiStateMachine.java
8c2ff3f4bfa8d5a1f8c9dd6e74aa9a404452d85d 23-Jun-2014 Robert Greenwalt <rgreenwalt@google.com> Refactor wifi p2p's startDhcpServer function

Add getTetheredDhcpRanges() interface and call it before calling
mNwService.startTethering to update dhcp ranges. This will allow
p2p apps to run well concurently with other tethering apps.

Manual import of AOSP change 81546 by jianzheng.zhou@freescale.com

Change-Id: Iebc62f95bdcedde80e2c1d3e9580d3f625c3b50b
om/android/server/wifi/p2p/WifiP2pServiceImpl.java
51991e784c605a7432a90c9e9a91b080fb106197 20-Jun-2014 Dianne Hackborn <hackbod@google.com> Add tracking of some wifi stats to battery stats.

Change-Id: I50cbd480b8c3ddc4cc8ccbe78b1fe6de98efd9e6
om/android/server/wifi/SupplicantStateTracker.java
om/android/server/wifi/WifiStateMachine.java
4b50786546ce4c4fee555d66028991fe257b8811 20-Jun-2014 vandwalle <vandwalle@google.com> add home network boost, better hadling of 5GHz configurations

Change-Id: I2417844b58e1839cb22649565404d76b792cdc65
om/android/server/wifi/WifiStateMachine.java
c6f06c628ee3583b60ff31a7da442e0ac7b26d97 19-Jun-2014 vandwalle <vandwalle@google.com> autojoin tuning, making LTE handover less aggressive

Bug: 15700122

Change-Id: I2836abf791f8c71c63a901170f247c4030e8e8f9
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
f16e4e5a57160b4355b53d4b91f9097d370546c6 12-Jun-2014 Yuhao Zheng <yuhaozheng@google.com> Passpoint OSU bug fix + API rename

- OSU bug fix
- API rename
- Soap bug fix

https://partner-android-review.googlesource.com/#/c/170602/
https://partner-android-review.googlesource.com/#/c/170809/
om/android/server/wifi/passpoint/WifiPasspointCertificate.java
om/android/server/wifi/passpoint/WifiPasspointSoapClient.java
om/android/server/wifi/passpoint/WifiPasspointStateMachine.java
1671350805f87a3cd05add0097690e97966213d8 17-Jun-2014 Vinit Deshpande <vinitd@google.com> Merge "Fix p2pGetDeviceAddress to work without p2p0 interface"
6bf16b3c45397bf8453b8b47438a77785acc5d9f 17-Jun-2014 Lorenzo Colitti <lorenzo@google.com> Merge "Read IPv6 routes from netlink as well."
4bc47f83a393766db792e1bf2fc81087ded00c3b 17-Jun-2014 Lorenzo Colitti <lorenzo@google.com> Merge "Move netlink updates to a new NetlinkTracker class"
ec474c010a79c12d24c34e79383b328cc53d5ece 13-Jun-2014 Lorenzo Colitti <lorenzo@google.com> Read IPv6 routes from netlink as well.

Bug: 9180552
Change-Id: I926e1ea0ff59a258da2472d8a1d8b4c80727e87e
om/android/server/wifi/WifiStateMachine.java
36286b23c4e30f042ed753a670c2b462ebf13a48 17-Jun-2014 Vinit Deshpande <vinitd@google.com> Fix p2pGetDeviceAddress to work without p2p0 interface

Since there are devices that don't have this interface, we can't risk
failing P2p service initialization for it. This change works around
that problem by issuing STATUS request without targetting it to any
interface. Supplicant seems to be providing the correct MAC address
anyway.

Bug: 10364703
Change-Id: I2318ecc294f665dd4ea5c912e89db73d49b81a7f
om/android/server/wifi/WifiNative.java
d60cf2efc576f016506ebe6d8a83b4a6217b2e0e 10-Jun-2014 Lorenzo Colitti <lorenzo@google.com> Move netlink updates to a new NetlinkTracker class

This will allow us to use this logic on other link types such as
Ethernet, and will also avoid increasing the complexity of
WifiStateMachine as we get more information such as routes and
DNS servers from netlink.

Bug: 9180552
Change-Id: I79034827cb0c5f24d783d7243e04b69e12aa3cc6
om/android/server/wifi/WifiStateMachine.java
faaededaddcc210b9f1710d2ce465cf1d2927332 09-Jun-2014 roger.chang <roger.chang@mediatek.com> Hotspot 2.0 add networkSelection fix bugs

Change-Id: I08479d06475e01d88b6ba1ff6667b5d1d5a63bdb
om/android/server/wifi/passpoint/WifiPasspointStateMachine.java
810ab83f336a6406220ef73b69377290671d6419 13-Jun-2014 vandwalle <vandwalle@google.com> Merge "auto-roam fixes, disable scanning based on traffic at interface"
b97e66604f472f67c233bb8f8d9630bb36131e2c 13-Jun-2014 vandwalle <vandwalle@google.com> auto-roam fixes, disable scanning based on traffic at interface

Bug: 15575229
Bug: 15577651

Change-Id: I1157c7c9b83c1cafd67d4d4f1d4e1e6fc8d95323
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiStateMachine.java
a0d0db0e9e39b04613e4b5c1d9cf51c488fc9af0 12-Jun-2014 Robert Greenwalt <rgreenwalt@google.com> am 1d838f7a: Merge "Make NetworkCapabilities publicly immutable." into lmp-preview-dev

* commit '1d838f7a55fa178d2ab12716b889ad4e381c852f':
Make NetworkCapabilities publicly immutable.
2895934d7762d3ba65daeeb8317f4b2081f5441a 12-Jun-2014 Yuhao Zheng <yuhaozheng@google.com> Merge "Wifi passpoint - linking APIs"
3df4c1f725919d64f0703915da39c61f728626ef 10-Jun-2014 Vinit Deshpande <vinitd@google.com> Support scanning using band specification instead of channels

This change enables scanning with band specification instead of channels,
this should ease app development.

Also includes a bug fix for parcel serialization/deserialization.

Change-Id: Idbffce4805b403bf8fe1efae999cb828e09c2420
om/android/server/wifi/WifiScanningServiceImpl.java
7e13ab5165291aa3685eeeca762a2470e93a10bd 04-Jun-2014 Vinit Deshpande <vinitd@google.com> Fix an NPE in WifiScanner while reporting description

Change-Id: Ie9d12e19e0b8ca98c6ec4c6fa5222a2f28983e64
om/android/server/wifi/WifiScanningServiceImpl.java
daac2ad767f6047409987bb22812ab5f295e54df 02-Jun-2014 Vinit Deshpande <vinitd@google.com> Various WifiScanner fixes

Bug: 14960689 - WifiScanner does not clean up well
Bug: 15314698 - Scan stop working after multiple start/stops
Bug: 15017916 - null exception when Wifi is not enabled

Change-Id: I70712f3c032580341470f70b8be376e0098ec6ac
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiScanningServiceImpl.java
df84f5da0840f0dddfd7ffceb15687a5687890a7 12-Jun-2014 vandwalle <vandwalle@google.com> Merge "auto-roam initial implementation"
4dc6f3a322806b25d50039614cde1b94fe91ab17 11-Jun-2014 vandwalle <vandwalle@google.com> auto-roam initial implementation

Bug:15553951

Change-Id: I04ebca4a4f5a9b408893ce1e9874f08aeff50ba2
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/WifiTrafficPoller.java
bbd06dfb417f205b3d80225a3e713fe9361c19cd 04-Jun-2014 Yuhao Zheng <yuhaozheng@google.com> Wifi passpoint - linking APIs

cherry-pick from kwd:

7801fe Wifi Passpoint - linking credential match API
https://partner-android-review.googlesource.com/#/c/59246/

6cb965 Wifi Passpoint - linking OSU API
https://partner-android-review.googlesource.com/#/c/59333/
om/android/server/wifi/passpoint/WifiPasspointClient.java
om/android/server/wifi/passpoint/WifiPasspointDmClient.java
om/android/server/wifi/passpoint/WifiPasspointServiceImpl.java
om/android/server/wifi/passpoint/WifiPasspointSoapClient.java
om/android/server/wifi/passpoint/WifiPasspointStateMachine.java
1d838f7a55fa178d2ab12716b889ad4e381c852f 12-Jun-2014 Robert Greenwalt <rgreenwalt@google.com> Merge "Make NetworkCapabilities publicly immutable." into lmp-preview-dev
937be0625eb1daa1b9d5a0991a3fe6ab2f4804c7 10-Jun-2014 Robert Greenwalt <rgreenwalt@google.com> Make NetworkCapabilities publicly immutable.

Applying API council comments.

bug: 15142362
Change-Id: Ie0bde68b72656a676d90c0343b9756fe9268d8d6
om/android/server/wifi/WifiStateMachine.java
4b1c8e0159c021f0ae1b53b6ec7431b050d6a899 08-Jun-2014 Robert Greenwalt <rgreenwalt@google.com> Apply LinkProperties API change.

bug:15142362
Change-Id: I1457111da7d3bd09998f7e010febb8bb4c45c8bc
(cherry picked from commit 82d1c6aeadfa24797b314ae2b2a55717df064b57)
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
211737ce4cabcab0552e3453ac6e3c5a4748c158 11-Jun-2014 Sreeram Ramachandran <sreeram@google.com> Merge "Use the updated RouteInfo API."
f62893bfeaebeaa0f6a840b29f1b7f33493c8894 10-Jun-2014 vandwalle <vandwalle@google.com> Merge "remember and report network score"
27355a942653264388e909a4276196ee63e57811 03-Jun-2014 vandwalle <vandwalle@google.com> remember and report network score

Change-Id: Ie54afe724a3618ec3fd557850dbbbb8bbae49ecc
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
82d1c6aeadfa24797b314ae2b2a55717df064b57 08-Jun-2014 Robert Greenwalt <rgreenwalt@google.com> Apply LinkProperties API change.

bug:15142362
Change-Id: I1457111da7d3bd09998f7e010febb8bb4c45c8bc
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
d05472bb94ecc9b870463a843313f2d852bcf5b8 04-Jun-2014 Sreeram Ramachandran <sreeram@google.com> Use the updated RouteInfo API.

Bug: 15142362
Bug: 13885501
Change-Id: I97f1625e037c889b0cddd3db418c42c1d48b26b9
om/android/server/wifi/WifiServiceImpl.java
a16ef45ba07b7704d84a54f8d00a40c7da7696a3 03-Jun-2014 roger.chang <roger.chang@mediatek.com> Hotspot 2.0 add networkSelection(2)

Add policy inspection, it includes
- MinBackhaulThreshold
- SPExclusionList
- RequiredProtoProtTuple
- MaximumBSSLoadValue

Change-Id: Id9525ff1d5487b027295bf9c9136b0bd22121a8e
om/android/server/wifi/passpoint/WifiPasspointStateMachine.java
cf5b8eb8a08c45bd4a82f1f4bb789c8a1b08744f 04-Jun-2014 vandwalle <vandwalle@google.com> resolved conflicts for merge of dfcb187e to master

Change-Id: I740b98b89fb25599a353abbfe919c6e5a0f1c098
83c7dd3d754551c9cf3bd76a50c45ef62a4dab75 31-May-2014 puff wen <puff.wen@mediatek.com> Add class CellularNetwork for plmn parsing and retrieve mcc and mnc.

cherry-picking 2 CLs:
https://partner-android-review.googlesource.com/#/c/58542/
https://partner-android-review.googlesource.com/#/c/59079/

Change-Id: I9e08e4edbf8d52eeda879a0309cf1eba8a7594ea
om/android/server/wifi/passpoint/WifiPasspointStateMachine.java
9e31a73a1218bd611229e672c0c82b4f7775888b 03-Jun-2014 Robert Greenwalt <rgreenwalt@google.com> Merge "Apply refactored NetworkFactory." into lmp-preview-dev
b565662ea98a244c8321afa889a07a1bab95f439 01-Jun-2014 vandwalle <vandwalle@google.com> handle removal of self added configurations

Change-Id: I53122e704d8ef682c6c326b0588649ed9b7ba121
(cherry picked from commit 0e3c67280365eb82fc15362a3b98a2c978bde766)
om/android/server/wifi/WifiConfigStore.java
5c2d5c27293a6df796e56f57b14c2a9aced675bd 28-May-2014 Robert Greenwalt <rgreenwalt@google.com> Apply refactored NetworkFactory.

Make NetworkFactory a concrete class and divide responsibilites between it and NetworkAgent.
Factory will track requests and by default give a single connect/disconnect api for ease
of use. Then NetworkAgent is created and destroyed as needed with very simple logic.

Change-Id: I401c14a6e5466f2fc63b04219b97ff85bb9af291
(cherry picked from commit 7d6e0b86655bf9862ae81fe37c9c8dc3f70d51f9)
om/android/server/wifi/WifiStateMachine.java
8f679e3b9db68bcd29bb33f430ed11ef21065208 03-Jun-2014 Robert Greenwalt <rgreenwalt@google.com> Merge "Apply refactored NetworkFactory."
aff01c338585f4411f61a9aa7ea35201f924ec6c 30-May-2014 vandwalle <vandwalle@google.com> add debug info to wifi configure, check auth method for real before self-adding

Bug:15111865

Change-Id: I095fff870c7871e3cb7ae4b8e99034519eb26fa1
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/WifiTrafficPoller.java
ae84f13d7b7f34ddbf5ac380d98e8d19b3541f6c 29-May-2014 vandwalle <vandwalle@google.com> dont send SSIDs to herrevad if it cannot process them

Bug:15306345

Change-Id: I149870631b875e10ad899e81aaaf65e5f0a1eb7a
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiNative.java
511a412adce5a46c41e61f90c0df6de5fb4e491c 31-May-2014 Yuhao Zheng <yuhaozheng@google.com> WifiService and WifiPasspointService hook up

- add a reference to passpoint service in wifi state machine
- break dependency loop at boot phase

Change-Id: I0acdf02dcb4a62a4e27af8bb3640784ee2691e26
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/passpoint/WifiPasspointService.java
om/android/server/wifi/passpoint/WifiPasspointServiceImpl.java
om/android/server/wifi/passpoint/WifiPasspointStateMachine.java
dfcb187e5608e125fe161d70226c300bd7b781ad 24-May-2014 vandwalle <vandwalle@google.com> logs improvements, fix reading back networkHistory file

Change-Id: Iec4b11a3e0d8820b558abea6cc068a905199896d
om/android/server/wifi/SupplicantStateTracker.java
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
7d6e0b86655bf9862ae81fe37c9c8dc3f70d51f9 28-May-2014 Robert Greenwalt <rgreenwalt@google.com> Apply refactored NetworkFactory.

Make NetworkFactory a concrete class and divide responsibilites between it and NetworkAgent.
Factory will track requests and by default give a single connect/disconnect api for ease
of use. Then NetworkAgent is created and destroyed as needed with very simple logic.

Change-Id: I401c14a6e5466f2fc63b04219b97ff85bb9af291
om/android/server/wifi/WifiStateMachine.java
0557098735094d9a6d1a1fa3f09bc5ea95c09554 02-Jun-2014 Yuhao Zheng <yuhaozheng@google.com> Merge "Hotspot 2.0 add networkSelection(1)"
950365f5e3205a7bdd1e11ff292e126a07e5a353 02-Jun-2014 vandwalle <vandwalle@google.com> Merge "handle removal of self added configurations"
ff6d33bb0e882869ed683887c167ad9445bbfa27 02-Jun-2014 Vinit Deshpande <vinitd@google.com> Merge "DO NOT MERGE: Accommodating API Review feedback for WifiScanner" into lmp-preview-dev
1a325e10086cfdb9e9f9fa7e3f0283ba7839dd37 02-Jun-2014 Vinit Deshpande <vinitd@google.com> Merge "DO NOT MERGE: Fix the stopping of scan after Wifi connection" into lmp-preview-dev
0e3c67280365eb82fc15362a3b98a2c978bde766 01-Jun-2014 vandwalle <vandwalle@google.com> handle removal of self added configurations

Change-Id: I53122e704d8ef682c6c326b0588649ed9b7ba121
om/android/server/wifi/WifiConfigStore.java
fede6134980f4682059f1278eaa0f7629cf532ff 29-May-2014 roger.chang <roger.chang@mediatek.com> Hotspot 2.0 add networkSelection(1)

To generate WifiPasspointPolicy list for AutoJoiner making
network selection easily.
This policy list match all availabled APs information
(Realm/FQDN/HOME_OI...etc) of a device position.

Change-Id: Iad7ba7d69cdc73273e5828e26912a0fe67f2a8ed
om/android/server/wifi/passpoint/WifiPasspointClient.java
om/android/server/wifi/passpoint/WifiPasspointDmClient.java
om/android/server/wifi/passpoint/WifiPasspointSoapClient.java
om/android/server/wifi/passpoint/WifiPasspointStateMachine.java
c3fdd0cb9d67541a3ff83b3643d1af769cf19396 28-May-2014 Yuhao Zheng <yuhaozheng@google.com> More ANQP parsing

Change-Id: Iddc51c1f01201b19a51981b45443cd52ce432c88
om/android/server/wifi/passpoint/WifiPasspointStateMachine.java
f07ad104ae5e538ad009f1f168c834edab016d18 01-Jun-2014 Robert Greenwalt <rgreenwalt@google.com> am 59c5355a: Don\'t tear down early wifi.

* commit '59c5355a48a3311f07d2d8d6c685bf8de734d200':
Don't tear down early wifi.
59c5355a48a3311f07d2d8d6c685bf8de734d200 01-Jun-2014 Robert Greenwalt <rgreenwalt@google.com> Don't tear down early wifi.

This was adding 10 or so seconds to getting on wifi at first boot.
Note this delay goes away with the changes to NetworkFactory later today anyway.

bug: 15363153
Change-Id: Ic764db7288696d697be0db4817fb816861984ef2
om/android/server/wifi/WifiStateMachine.java
ad7319939c424d42fa6a3791c47f613db8ef3cd8 31-May-2014 vandwalle <vandwalle@google.com> Add supplicant debug information
992ae00f25a9cc22cf5db3261bd7e72927069cf7 30-May-2014 vandwalle <vandwalle@google.com> add debug info to wifi configure, check auth method for real before self-adding

Bug:15111865

Change-Id: I095fff870c7871e3cb7ae4b8e99034519eb26fa1
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/WifiTrafficPoller.java
b569a63b0506e6c09875828fa4b005f69f7440e1 31-May-2014 Yuhao Zheng <yuhaozheng@google.com> Merge "Hotspot 2.0 framework - Soap client & certificate clean up"
ac216a3c000a70af47df0e7370b05e186ad1bf2a 31-May-2014 Vinit Deshpande <vinitd@google.com> DO NOT MERGE: Accommodating API Review feedback for WifiScanner

Main changes include

- hiding the API for LMP preview
- moved information elements to ScanResult object
- removed objects from events
- changed API names to be more consistent

cherry-picked from partner:klp-wireless-dev
SHA1 c43626f8e71455af01d8cc1131746d2a53fa688f

Bug: 15191968
Change-Id: Ibe3907366aee85f7d56021a536ae0f9f9fb28b38
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiScanningServiceImpl.java
368b164d5511e105c95d490e250640edd61045d0 31-May-2014 Vinit Deshpande <vinitd@google.com> DO NOT MERGE: Fix the stopping of scan after Wifi connection

We have code that stops kitkat batch scan while we get a new IP address
via DHCP; this exists because ARP multicast packets may be lost if the
wifi radio is off channel for scanning.

We need to do something similar for GScan as well - to avoid getting in
the same problem. This change accomplishes that.

This change also makes all HAL methods static, getting WifiNative closer
to the 'SupplicantManager' role.

cherry-picked from klp-wireless-dev
SHA1 8f343d40a55bc638872a3bb3453b95062bf838ef

Change-Id: Id2b500e37b71ea21a6bca162011abecbd41d90ec
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiScanningServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
8d8b01e14f29a75407b1c6c8db2fd5540db7fbe4 27-May-2014 Ryan Yu <ryan.yu@mediatek.com> Hotspot 2.0 framework - Soap client & certificate clean up

Change-Id: I04e0580644a3ed7a06038806f4da1ed29f4caad5
om/android/server/wifi/passpoint/WifiPasspointCertificate.java
om/android/server/wifi/passpoint/WifiPasspointSoapClient.java
om/android/server/wifi/passpoint/WifiPasspointStateMachine.java
763dbca691cad5f83bafbe439146d97b8631df98 30-May-2014 Vinit Deshpande <vinitd@google.com> Merge "Accomoditing API Review feedback for WifiScanner"
476bee2fef10d060c25c35858b1f7f60803d9f49 29-May-2014 Vinit Deshpande <vinitd@google.com> Accomoditing API Review feedback for WifiScanner

Main changes include

- hiding the API for LMP preview
- moved information elements to ScanResult object
- removed objects from events
- changed API names to be more consistent

cherry-picked from partner:klp-wireless-dev
SHA1 c43626f8e71455af01d8cc1131746d2a53fa688f

Bug: 15191968
Change-Id: Ibe3907366aee85f7d56021a536ae0f9f9fb28b38
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiScanningServiceImpl.java
ac38b54fb67b308fd88c47d0c6ef1ace5ff7595a 30-May-2014 Vinit Deshpande <vinitd@google.com> Merge "Fix the stopping of scan after Wifi connection"
3aaac376c911c46074525904df2b6e9fd8d36a60 30-May-2014 Yuhao Zheng <yuhaozheng@google.com> Build fix

Change-Id: I5e07d9fab451470de2a16fd478676993d9110958
om/android/server/wifi/passpoint/WifiPasspointService.java
76a0e5f47c189bb4b529342f0ef58a5499ae9bf1 16-May-2014 Roger Chang <roger.chang@mediatek.com> Hotspot 2.0 framework - add implementation

Change-Id: Ib3534ff24af333eae11e914ad9d09716a834c99f
om/android/server/wifi/passpoint/DmClient.java
om/android/server/wifi/passpoint/PasspointClient.java
om/android/server/wifi/passpoint/PasspointService.java
om/android/server/wifi/passpoint/PasspointServiceImpl.java
om/android/server/wifi/passpoint/PasspointStateMachine.java
om/android/server/wifi/passpoint/SoapClient.java
om/android/server/wifi/passpoint/WifiPasspointCertificate.java
om/android/server/wifi/passpoint/WifiPasspointCertificateHelper.java
om/android/server/wifi/passpoint/WifiPasspointClient.java
om/android/server/wifi/passpoint/WifiPasspointDmClient.java
om/android/server/wifi/passpoint/WifiPasspointDmTreeHelper.java
om/android/server/wifi/passpoint/WifiPasspointHttpClient.java
om/android/server/wifi/passpoint/WifiPasspointService.java
om/android/server/wifi/passpoint/WifiPasspointServiceImpl.java
om/android/server/wifi/passpoint/WifiPasspointSoapClient.java
om/android/server/wifi/passpoint/WifiPasspointStateMachine.java
om/android/server/wifi/passpoint/WifiTreeHelper.java
b0b1d59786de7ff1fc98e31a16a7d710458bf549 30-May-2014 Vinit Deshpande <vinitd@google.com> Fix the stopping of scan after Wifi connection

We have code that stops kitkat batch scan while we get a new IP address
via DHCP; this exists because ARP multicast packets may be lost if the
wifi radio is off channel for scanning.

We need to do something similar for GScan as well - to avoid getting in
the same problem. This change accomplishes that.

This change also makes all HAL methods static, getting WifiNative closer
to the 'SupplicantManager' role.

cherry-picked from klp-wireless-dev
SHA1 8f343d40a55bc638872a3bb3453b95062bf838ef

Change-Id: Id2b500e37b71ea21a6bca162011abecbd41d90ec
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiScanningServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
c152d90b8d0a7d69f9aed5de086f2992ab4c429e 30-May-2014 vandwalle <vandwalle@google.com> Merge "dont send SSIDs to herrevad if it cannot process them"
21bc54cb37a0085b1c909cb4d55ebb12a2facefb 29-May-2014 vandwalle <vandwalle@google.com> dont send SSIDs to herrevad if it cannot process them

Bug:15306345

Change-Id: I149870631b875e10ad899e81aaaf65e5f0a1eb7a
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiNative.java
c6c2b4218d9f15b5de45a002bff7e84a7ebc99e0 29-May-2014 Andres Morales <anmorales@google.com> am f3f4029b: Change permission to acquire NFC config token

* commit 'f3f4029b3ac41da4cc6a1bc22bae47c750a47048':
Change permission to acquire NFC config token
684e5c60b103d5d8e4f5513cc54ec3965ead6e8f 29-May-2014 Pierre Vandwalle <vandwalle@google.com> Merge "Fix system fatal exception due to Invalid WiFi SSID"
1fcf3c6d2b9ed65573e1e7c55fc5a30ebd364c4f 28-May-2014 Yuhao Zheng <yuhaozheng@google.com> Fix system fatal exception due to Invalid WiFi SSID

Change-Id: I88c3573fa06d95b78897aca8be1a9763dd0b4246
om/android/server/wifi/WifiAutoJoinController.java
f3f4029b3ac41da4cc6a1bc22bae47c750a47048 13-May-2014 Andres Morales <anmorales@google.com> Change permission to acquire NFC config token

The supplicant provides the configuration token
in the standard format for writing to an NFC
tag. Once this token is written to a tag,
tapping that tag will ask the user to confirm
and then connect them to the network referenced
on the tag.

Since this token contains the network
password, it should be accessible only through
the internal permission.

It is implemented via a "sync" call since it
does not depend on the current Wi-Fi state.
Let me know if you see a reason to add it into
the state machine flow and I will do so.

Change-Id: Id1b4624651d0d82cb48bf83fb40ea0cfe7569832
om/android/server/wifi/WifiServiceImpl.java
abde872adced15dfb6781fb71959453d963326db 28-May-2014 Yuhao Zheng <yuhaozheng@google.com> WifiAutoJoinController verbose log fix

Change-Id: I8113292a43bb7092747434825301109ef52a1c7b
om/android/server/wifi/WifiAutoJoinController.java
27f07726cbab1f9f3ccf33cfb7c786f9e5895d2b 28-May-2014 Dave Langemak <dlangemak@google.com> Merge "DO NOT MERGE: lose the STOP_DRIVER command" into lmp-preview-dev
6f1f2a48fe6e88179062760b1075af31ab46822b 23-May-2014 vandwalle <vandwalle@google.com> DO NOT MERGE: lose the STOP_DRIVER command

Change-Id: I8e1ff28d5b79ef53778e0b4d083156cf748a4886
(cherry picked from commit 4a21193ee63c72919e7ead45e1de0643c7abe554)
om/android/server/wifi/WifiStateMachine.java
704a34a19d873cc806ecca44226f811e58cb870d 28-May-2014 Dave Langemak <dlangemak@google.com> Merge "DO NOT MERGE: revert change preventing NULL SSID in a WifiConfiguration" into lmp-preview-dev
89dca79510af1fbe58c831e78edeccdb7db6e4cc 22-May-2014 vandwalle <vandwalle@google.com> DO NOT MERGE: revert change preventing NULL SSID in a WifiConfiguration

Change-Id: I131c429f4897c359004d6eae09f93550b8eaf0b1
(cherry picked from commit e86c962bb99a8b126ed64ddcc6b112161549e26d)
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
627b3e071eb4b495cf91067f12eb47371fcdfe5b 22-May-2014 vandwalle <vandwalle@google.com> DO NOT MERGE :dont try autojoining networks that are too far

Change-Id: I96a0b7283819bbbd312b0838d0a18a9622d15940
(cherry picked from commit 8c9088d11880553458f09377cc60d6eb7e66747b)
om/android/server/wifi/WifiAutoJoinController.java
a37a204ce03e0ee2da68306a1bac58fc4bb8352c 17-Apr-2014 Vinit Deshapnde <vinitd@google.com> Don't reset country code once it is persisted

This change simply ignores resetting of country code by cellular
networks to avoid disconnecting existing wifi connections. It also
defers setting newly found country code until after existing Wifi
connection is torn down.

Also removes some dead code related to resetting of country codes.

cherry-picked from klp-dev
SHA1 b5ee95edf97f83e31e44f72e1b0f95a0c71a97ed

Bug: 13894807
Change-Id: Ie2fcfdd4b3be8ba94542772c132fb1acb6a2c683
(cherry picked from commit f449336da3fc8f8f9b65de3ba359129779511199)
om/android/server/wifi/WifiStateMachine.java
0888ce6f90bdaeee799dd8361ea4781e23a33b87 24-May-2014 vandwalle <vandwalle@google.com> logs improvements, fix reading back networkHistory file

Change-Id: Iec4b11a3e0d8820b558abea6cc068a905199896d
om/android/server/wifi/SupplicantStateTracker.java
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
f6c6d3ccda924ad5f11883bc346b4eb4ada1bc06 24-May-2014 Jeff Davidson <jpd@google.com> Use a consistent network key format in wifi score cache.

This doesn't handle SSID which can't be encoded as UTF-8, but will
work for most SSIDs.

Bug: 15188549
Change-Id: If12e83c4d43ed1b5d686ec1dfb9c1980bb0d4697
om/android/server/wifi/WifiNetworkScoreCache.java
4a21193ee63c72919e7ead45e1de0643c7abe554 23-May-2014 vandwalle <vandwalle@google.com> lose the STOP_DRIVER command

Change-Id: I8e1ff28d5b79ef53778e0b4d083156cf748a4886
om/android/server/wifi/WifiStateMachine.java
ff25461e44187208f06432126ac6e7bd1d3862ea 22-May-2014 vandwalle <vandwalle@google.com> Merge "revert change preventing NULL SSID in a WifiConfiguration"
c84f2cac12c1ee9a5b2d220a620e0bf5e79987c2 22-May-2014 Vinit Deshapnde <vinitd@google.com> Merge "Don't reset country code once it is persisted"
f449336da3fc8f8f9b65de3ba359129779511199 17-Apr-2014 Vinit Deshapnde <vinitd@google.com> Don't reset country code once it is persisted

This change simply ignores resetting of country code by cellular
networks to avoid disconnecting existing wifi connections. It also
defers setting newly found country code until after existing Wifi
connection is torn down.

Also removes some dead code related to resetting of country codes.

cherry-picked from klp-dev
SHA1 b5ee95edf97f83e31e44f72e1b0f95a0c71a97ed

Bug: 13894807
Change-Id: Ie2fcfdd4b3be8ba94542772c132fb1acb6a2c683
om/android/server/wifi/WifiStateMachine.java
e86c962bb99a8b126ed64ddcc6b112161549e26d 22-May-2014 vandwalle <vandwalle@google.com> revert change preventing NULL SSID in a WifiConfiguration

Change-Id: I131c429f4897c359004d6eae09f93550b8eaf0b1
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
f5781f4b916bef6428484ea60f808dc3653ea21f 22-May-2014 vandwalle <vandwalle@google.com> Merge "dont try autojoining networks that are too far"
2390785d4104a6c20459c5e7143c1a7a5bb2481f 22-May-2014 Jason Monk <jmonk@google.com> Merge "No longer require CONNECTIVITY_INTERNAL to set PAC"
8c9088d11880553458f09377cc60d6eb7e66747b 22-May-2014 vandwalle <vandwalle@google.com> dont try autojoining networks that are too far

Change-Id: I96a0b7283819bbbd312b0838d0a18a9622d15940
om/android/server/wifi/WifiAutoJoinController.java
4bcdcfd19e3eaaacc54d8ec65149c6d7faa181af 22-May-2014 vandwalle <vandwalle@google.com> remember last failure and reenable networks disabled by supplicant

bug: 14834820

Change-Id: I3d9725ac7482cd8490b52239135a98dfe0f124a2
om/android/server/wifi/WifiConfigStore.java
afbd80435faf3d3eda6e05fba3573a0ac4e762b6 22-May-2014 vandwalle <vandwalle@google.com> Merge "make verbose logging a wifimanager hidden API"
ed9938883ae2dade81c8be6cd6ceaef3febd5239 22-May-2014 vandwalle <vandwalle@google.com> make verbose logging a wifimanager hidden API

bug: 151386707

Change-Id: Ide885ce96621fe4bab6abf10291bc8441eecad4a
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
4a55fdc530854a4a0c1602d6dbe3e0c8519b1166 22-May-2014 Lorenzo Colitti <lorenzo@google.com> Merge "Properly check return value of readIpAndProxyConfigurations"
5f128f9e971b7120a776f8fafde3a0db889f847d 22-May-2014 Lorenzo Colitti <lorenzo@google.com> Properly check return value of readIpAndProxyConfigurations

On failure, it returns an empty SparseArray, not null.

Change-Id: I5d24fdcfd24eb92657bdca674b1a417508e5af56
om/android/server/wifi/WifiConfigStore.java
04c9a7c99c2ec86636ab43edceb84a2eceaadd04 22-May-2014 vandwalle <vandwalle@google.com> Merge "various autojoin fixes"
453aee50caf7e332e77ab3d995d7c87a958e4fd4 21-May-2014 vandwalle <vandwalle@google.com> various autojoin fixes

Bug:15111865
Bug:15080778
Bug:14994925

Change-Id: I753ff62b48a87db4096fdec18b4de070656cf901
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiStateMachine.java
64c98f4afda6c7970c5d563580165a308d5e7c15 20-May-2014 Jason Monk <jmonk@google.com> No longer require CONNECTIVITY_INTERNAL to set PAC

Since we are adding UI to control/monitor this, it does not need
to be guarded by CONNECTIVITY_INTERNAL anymore.

Bug: 14885470
Change-Id: I01fcc477899e94232e9863d4e46391ad831d249c
om/android/server/wifi/WifiServiceImpl.java
82b91fd1a87ae9000bac54fb44981d5003958de1 21-May-2014 Vinit Deshpande <vinitd@google.com> Make Wifi WPS API available on application layer

Un-hide WPS methods (and required interface classes, etc.) of WifiManager.java to
enable Apps to start/stop the WPS procedure, add a patch for WPS method KEYPAD to
avoid early failure callbacks. (Methods PBC, DISPLAY, KEYPAD tested on 4.4.2_r2.)

Change-Id: I25aafdc4b637c87d754d4fdb70e40a34a569b738
Signed-off-by: Olaf Stoyke <o.stoyke@avm.de>
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiStateMachine.java
e88f9f737f389bcac0825be2684807525a7eb5d4 21-May-2014 Yuhao Zheng <yuhaozheng@google.com> Merge "Temp fix framework/opt fix for Hotspot 2.0"
d66e62e78523abd1eb40694832d97fee7c91953b 21-May-2014 vandwalle <vandwalle@google.com> Merge "autojoin fix: only link equivalently secure configurations"
d2569dc2b19c401200fd2672acf83cfc35f1eb12 21-May-2014 vandwalle <vandwalle@google.com> autojoin fix: only link equivalently secure configurations

Change-Id: I4f3653af6bc7d641138ca41335e40bf5f6f291e4
om/android/server/wifi/WifiConfigStore.java
2b59efa31731126223b0835de93bce22d7fd8b27 21-May-2014 Yuhao Zheng <yuhaozheng@google.com> Temp fix framework/opt fix for Hotspot 2.0

Will bring in more changes later.

Change-Id: Iaa0279e485bd5422c30edbd9867c110e9bf29044
om/android/server/wifi/passpoint/PasspointServiceImpl.java
om/android/server/wifi/passpoint/PasspointStateMachine.java
117be607246604e875de62aa8cdd99700b77a2b4 20-May-2014 vandwalle <vandwalle@google.com> fix enableNetwork() logic:

should not mark forgotten network as selected

Change-Id: I0ebbc3082228feb482611e0a7b40ee8c18340dee
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiStateMachine.java
a3425a631c67eaa0af5d2d378f125ba22d99c3d7 21-May-2014 Lorenzo Colitti <lorenzo@google.com> Merge "Move IP config from WifiConfiguration to IpConfiguration."
3ecf5a032e94b6538a56f94a5b33e50cbc464007 19-Mar-2014 Jaewan Kim <jaewan@google.com> Move IP config from WifiConfiguration to IpConfiguration.

Change-Id: I5d1189682b13f1088848809604690648d8d9ecca
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiServiceImpl.java
9ae6b45c038fa74a9e7285ef4834551dd93da332 20-May-2014 Yuhao Zheng <yuhaozheng@google.com> Fix a boot failure due to Wifi / Wifi Passpoint

Bug: 15060373
Change-Id: I8341a39c849d4135a0549c481cb3327cfca14567
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/passpoint/PasspointStateMachine.java
911a89d6a1e8abb3c3167e9b6d23499aec1b19ef 16-May-2014 Robert Greenwalt <rgreenwalt@google.com> Add a name for the wifi NetworkFactory.

Used only for debugging purposes.
bug:15003007

Change-Id: I717d63363f25c446f8ecf38d933b1a35d744af6e
om/android/server/wifi/WifiStateMachine.java
20104a55edf9fafa332df1a1ea11148a45c902ad 20-May-2014 vandwalle <vandwalle@google.com> Merge "fix for autojoin controller not requesting steen scores"
710b8c148ddbfd509e0e69af8d5dbb6fc8486a0c 20-May-2014 Vinit Deshpande <vinitd@google.com> Implement onPeriodChanged and multiple scans of same channels

This change fixes multiple scans of same channels; and it generates
onPeriodChanged event.

cherry-picked from partner:klp-wireless-dev
SHA1 f5a28231298b2919eb14151997b811d1d10b73e8

Bug: 15000051
Change-Id: I06a4ecc9d45eda4984de50b97b39f623dd0b26d1
om/android/server/wifi/WifiScanningServiceImpl.java
0c8b99a3b78e458a5617cc449e2efe69c5bdd531 16-May-2014 vandwalle <vandwalle@google.com> fix for autojoin controller not requesting steen scores

Change-Id: I2546241c8b1eefe963f840c4a98a3f817694039c
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiNetworkScoreCache.java
9882ff94b6e8bc218461ddb1f838f59fe181f9f7 18-May-2014 Robert Greenwalt <rgreenwalt@google.com> workaround wifi runtime crash

This is not a long term fix, but until the wifi folks fix it this should be sufficient.

bug:15060373
Change-Id: I150ba375046c48066150f3d78438efc316e4c84f
om/android/server/wifi/WifiStateMachine.java
aabe7a9f2f32915fd1f25416a6d2034a844005d6 10-May-2014 vandwalle <vandwalle@google.com> introducing link layer
cherry-picked from klp-wireless-dev-mirror
SHA1: eb8de645540caa6076c34854d8a4e7c22341783f
Change-Id: I5c736c697d38ec17dcde81bdee638048fd688073
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiScanningServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
f1daf9342b66bf134d13fa0a42e929a008f1ca62 14-May-2014 Vinit Deshapnde <vinitd@google.com> Enable more features on WifiScanner

This change enables full scan results and allows overriding wifichange
configuration. There are also minor API changes take relavent parameters.

Change-Id: I6ebcb49f64bd8bc9e5e0c88c3b56eb634783524e
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiScanningServiceImpl.java
741953368eafa247f2820496aaa521bc0e86e9e1 15-May-2014 Navtej Singh Mann <navtejsingh@google.com> Fix failed to start scan again without stop

Fix failed to start scan again without stop

Bug: 14991849

Change-Id: I86fb96912197c1a1926fc99504a2210e2df1898d
om/android/server/wifi/WifiNative.java
5d30d5c2e0eec4db2303da3f225f52da748e2060 12-May-2014 Yuhao Zheng <yuhaozheng@google.com> Hotspot 2.0 framework support -- more functionalities

- WifiMonitor handles more HS20 events
- Passpoint stack parses ANQP results

Bug: 5485670
Change-Id: I5f8e7c80f8024379fe7a6c4394f1faae2040cfba
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/passpoint/PasspointStateMachine.java
e65cebc4284fd320a155a274cb647f73cecabd11 13-May-2014 Navtej Singh Mann <navtejsingh@google.com> Fix NullPointerException while WPS Push button/WPS Pin Entry

Fix NullPointerException in system server while authenticating AP
through WPS Push button/WPS Pin Entry

Bug: 14659351

Change-Id: I4c0616b320c49841fbb1ef0983d170b1178bf542
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiStateMachine.java
446db2d5457456743e4476029e14d7c3bb9f5bcc 10-Apr-2014 Yuhao Zheng <yuhaozheng@google.com> Hotspot 2.0 framework support -- inital implementation

Bug: 5485670
Change-Id: I48a63f5a45e0c217f5b73b4b3c45ea1acee76034
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/hotspot/WifiHotspotService.java
om/android/server/wifi/hotspot/WifiHotspotServiceImpl.java
om/android/server/wifi/passpoint/DmClient.java
om/android/server/wifi/passpoint/PasspointClient.java
om/android/server/wifi/passpoint/PasspointService.java
om/android/server/wifi/passpoint/PasspointServiceImpl.java
om/android/server/wifi/passpoint/PasspointStateMachine.java
om/android/server/wifi/passpoint/SoapClient.java
om/android/server/wifi/passpoint/WifiTreeHelper.java
3137b27bbbaaf87267dea3bf95d1c027931b0b6a 07-May-2014 Navtej Singh Mann <navtejsingh@google.com> Fixed connection to AP with unicode emoji SSID

Fix for connection problem to wifi AP have
SSID of unicode emoji

Bug: 11690983

Change-Id: Icc6de6d49bbf42a1c26ae85bfee343a860ab3fb8
om/android/server/wifi/WifiConfigStore.java
569b093c4afd30787308032c8259af2680a2874f 10-Apr-2014 Navtej Singh Mann <navtejsingh@google.com> Fixed bypass of ConnectivityInternal permission

Removed public function 'getWifiStateMachineMessenger' of
WifiManager to fix bypass of ConnectivityInternal permission
by application, which is security concern

Bug: 13749822

Change-Id: I3ae73e33b77ee8ae0133ca9dc8cc03c504f09e40
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiWatchdogStateMachine.java
ede1310be531a84faa08f02c3fd243448dd936dd 16-May-2014 vandwalle <vandwalle@google.com> restore correct tracking of auth failure; bring up assoc reject info to supplicant

Change-Id: I7eeb110f1f14149f560630848f26f7cc9f5cbb67
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiStateMachine.java
ecd2b88214b5d214fd1f63a9560caff9058912dd 16-May-2014 vandwalle <vandwalle@google.com> fix for devices using enableNetwork API

Change-Id: Idf886dd01892d3f7ca463a44fd76030ddadcd238
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
2278134a58edb57b7c9ecad6753034605e389501 15-May-2014 vandwalle <vandwalle@google.com> Merge "autojoin is to eager to black list networks due to connection failure"
647207cce53bad5ef911e16278d5a2c910cdab92 15-May-2014 Jeff Davidson <jpd@google.com> Fix package names to match directory structure.

Change-Id: Ia208a4c23fa972b4abf4d9ab17555dec71cbc075
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiParser.java
62f1d0ca8ea4466628f6ff179b1f20e1279fa7e0 13-May-2014 vandwalle <vandwalle@google.com> autojoin is to eager to black list networks due to connection failure

Bug: 14834820

Change-Id: I81c05b657b3d218bb4d5f5bf82dd6a8ad3859bd1
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiStateMachine.java
3831a926f6762a3b4c398da51cc67e9d81572458 17-Apr-2014 Robert Greenwalt <rgreenwalt@google.com> Switching to NetworkAgent API

Change-Id: I8c820a17a6b64b8376930ba85ab507e07ce38d36
om/android/server/wifi/WifiStateMachine.java
f656eeed604bdcf2e78fb9fb97b0610a0f19ca99 13-May-2014 vandwalle <vandwalle@google.com> Merge "fix crash on null string in AUTH_FAILURE message handling"
e57857d829f670c62e8d53ffed580681271a272b 13-May-2014 vandwalle <vandwalle@google.com> fix crash on null string in AUTH_FAILURE message handling

Change-Id: I657951f8bb37af778f8d4ab2c9b9d2ab2956220c
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiStateMachine.java
66f8e08b668ebdc4c9b180f90e71cbb4f3e1c37f 13-May-2014 vandwalle <vandwalle@google.com> disable autojoin associated scanning on molly

Bug: 14696701

Autojoin associated scan can interfere with real time streaming (mpeg RTP), hence for now we want to disable those scans on a molly product.

Change-Id: If056032cca91dd47f6fab0c56b4df4c90bc42571
om/android/server/wifi/WifiStateMachine.java
f13817203179f41620514718c8668ae7e418f8af 10-May-2014 Jeff Davidson <jpd@google.com> Add a basic dump() function to WifiNetworkScoreCache.

Will get the current cached set of scan results and dump the current
score for each one depending on the RSSI.

Change-Id: Ic524906aef2bdfe2fa9f9a9e5364c80d028ddfdb
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiNetworkScoreCache.java
952d359198cb1f04c180fc0f795dc316fe97cb5e 08-May-2014 vandwalle <vandwalle@google.com> fix for 14645794 Wifi flakiness triggering multiple crashesin volantis

Change-Id: Id2caa10964bbc02dbeff85ac6193f4be19f7bd39
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiStateMachine.java
d33eac369db516e6fc05ac930e66510e957c12d6 08-May-2014 Vinit Deshpande <vinitd@google.com> Merge "Fix un-intended exposure of P2pStateMachine messenger"
8ab8f170c4b0864b86471ee352271b7d7e12a814 08-May-2014 Vinit Deshpande <vinitd@google.com> Merge changes Ia929b1d5,I8a171201

* changes:
Build fixes for newly imported code from KWD
changes to make halutil more interactive
508198f1ccc45994b418bdc55fdd1d4d2c6e530b 08-May-2014 Vinit Deshapnde <vinitd@google.com> Merge "Initial implementation of WifiScanner"
85b91efd318813370946829e52453810d3fb35cc 08-May-2014 Vinit Deshapnde <vinitd@google.com> Merge "More HAL functionality"
1e0d2b64c03a05da87d59a5f0774e549e82080cc 08-May-2014 vandwalle <vandwalle@google.com> work around supplicant bug

There is a case where supplicant is in an inconsistent internal state:
- it will silently ignore a select/reconnect command sequence to a given network because some state thinks it is already associated to the selected network
- however wlan driver is not, in fact, associated, and the supplicant's own STATUS command will indeed return a non-associated status

This situation doesn't resolve itself until supplicant is asked to join a different network, or issue a disconnect. In the AUTO_CONNECT sequence, it is safe to issue a disconnect because autojoin already has verified that the supplicant's status was not associated or associated to a different network.

In addition, in this change list, autojoin controller should not duplicate the WifiConfiguration from WiFiConfig store if it only wants to modify then before saving back.

Change-Id: If42fb05752fce288fb993fd7b70ef94cdb1f3d25
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiStateMachine.java
f933721551d39adc4924e5f69dcc51c16c520850 12-Apr-2014 Navtej Singh Mann <navtejsingh@google.com> Fix un-intended exposure of P2pStateMachine messenger

Fix un-intended exposure of P2pStateMachine messenger in
WifiP2pServices, added ClientHandler for request from app

Bug: 13931972

Change-Id: I9ebcdfd82ab66f1b843560758b3f3da8cf7c797b
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/p2p/WifiP2pServiceImpl.java
50e20834408a3ee55170f8a34dfaeee26e7403dd 08-May-2014 Vinit Deshapnde <vinitd@google.com> Build fixes for newly imported code from KWD

SystemServer works a bit differently in KWD; and using
libnl_2 is discouraged in master.

Change-Id: Ia929b1d500164a05101d41f6fe0ed18af3597fe9
om/android/server/wifi/WifiScanningService.java
e4e3750390bec0a849a9153348b7c21b2cc8b843 05-May-2014 Vinit Deshapnde <vinitd@google.com> Initial implementation of WifiScanner

This change implements basic functionality of WifiScanner. Following
functionality is enabled

1. Scanning - specify a list of channels to scan
2. Significant change detection
3. AP hotlist

Change-Id: I4fbb2cccbb15df21aae7a81f5d9b17fde2bda8c0
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiScanningService.java
om/android/server/wifi/WifiScanningServiceImpl.java
om/android/server/wifi/WifiService.java
7f9a15d554f69311a0db43347d6473a7c4c46e2e 08-May-2014 Vinit Deshapnde <vinitd@google.com> More HAL functionality

This change implements JNI plugs for delivering events to
WifiNative in framework. Also introduces a test utility.

Also has updated Gscan.h which is made up-to-date with the
promised functionatliy.

Change-Id: I12dd6d9f171e01e4b23ce4839b4022acd5e599cb

Conflicts:
service/Android.mk
om/android/server/wifi/WifiNative.java
f22d23092ab37286a5ef9d257d5bb32c421d2669 06-May-2014 vandwalle <vandwalle@google.com> autojoin initial implementation

Change-Id: Iea4e5c0b8e988e410d2f9885ecaf6317d34cc1d1
om/android/server/wifi/SupplicantStateTracker.java
om/android/server/wifi/WifiAutoJoinController.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiNetworkScoreCache.java
om/android/server/wifi/WifiParser.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/WifiTrafficPoller.java
73281a1523e29b9717d0d952de1faf2b52281c7c 07-May-2014 Jason Monk <jmonk@google.com> Revert "Revert "Fix Build""

This reverts commit 439935a9ec391392a1aea323d7f18c328fea2490.

Change-Id: Idb1661d3d34461848f9812d637b173decd6ee9e7
om/android/server/wifi/WifiConfigStore.java
439935a9ec391392a1aea323d7f18c328fea2490 07-May-2014 Jason Monk <jmonk@google.com> Revert "Fix Build"

This reverts commit 09af645cb252b60bd38747df458c6d93dad23e02.

Change-Id: I3122b7e117f022c3edb1bb439b13fe99a074e78d
om/android/server/wifi/WifiConfigStore.java
09af645cb252b60bd38747df458c6d93dad23e02 07-May-2014 Jason Monk <jmonk@google.com> Fix Build

Change-Id: Idb7e11307f10bd9580a5b92182065c3ef237af91
om/android/server/wifi/WifiConfigStore.java
d4d0c9ad1e3289702ec341521b9bd01b52e9c1d8 07-May-2014 Jason Monk <jmonk@google.com> Support renaming of ProxyProperties to ProxyInfo

Change-Id: Ie4ec0e94b901161af68d8979d8b3cfd0e6009798
om/android/server/wifi/WifiConfigStore.java
97a856eb1fda1585316055bd4912f0000deccb52 26-Mar-2014 Yuhao Zheng <yuhaozheng@google.com> Fix incorrect DISABLE_P2P_TIMED_OUT handling

Likely wifi p2p disable timeout doesn't work, due to the inadvertent use of
a wrong counter. Fixed by using the correct counter.

bug: 13653433
Change-Id: I4a49c039d28c4ac742fab0fc99492f6411156b97
om/android/server/wifi/p2p/WifiP2pServiceImpl.java
0e8c82453d5a7f328ac1edc248457581368cd8c6 07-Apr-2014 Jaewan Kim <jaewan@google.com> Merge "Revert "Refactor IpConfiguration from WifiConfiguration""
b872cd1d58e1666a9066b136e28c49ed62f825ed 07-Apr-2014 Jaewan Kim <jaewan@google.com> Revert "Refactor IpConfiguration from WifiConfiguration"

This reverts commit 9790c81b2d0fb2b8c3790e4dbe6dd9fd5b93bd4d.

Change-Id: Idba522f04dd4a6a16e4829f68f70d3cc19016a81
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiServiceImpl.java
c1580601011dad221059c89c8445370c4f5d9727 07-Apr-2014 Jaewan Kim <jaewan@google.com> Merge "Refactor IpConfiguration from WifiConfiguration"
b59f69faf9e3de740bbe1e55cef70e9e22858c2a 02-Apr-2014 Kenny Guy <kennyguy@google.com> Renaming related users to profiles.

Change-Id: Ia3cb7534e34b971b1996c7b81d2d160466962afe
om/android/server/wifi/WifiServiceImpl.java
f9dba8db09a3a74a47ef076ca0b225bb70052df1 02-Apr-2014 Wei Wang <weiwa@google.com> Merge "Fix stopBatchedScan not working. cherrypick ag/436843"
9bd0507bf45c39dcb6beca7ae885bc790352eda8 02-Apr-2014 Wei Wang <weiwa@google.com> Fix stopBatchedScan not working.
cherrypick ag/436843

Change-Id: I325ea5965bc3863f1fe1179a404c2fa39b3c998e
om/android/server/wifi/WifiStateMachine.java
99b31a89e661626ef8b970abd9de4455fd891299 28-Mar-2014 Yuhao Zheng <yuhaozheng@google.com> Merge "Wifi hotspot service initial hook up"
3c194cb908060978f65ae168ea0ed0606127b422 27-Mar-2014 Vinit Deshapnde <vinitd@google.com> Merge "Explicitly set update_config on supplicant"
3605a4b0e606f331bcebed6ae7629dae527fcf13 25-Mar-2014 Yuhao Zheng <yuhaozheng@google.com> Wifi hotspot service initial hook up

Add a dummy wifi hotspot service for futher development use. This is to
resolve the different between master branch and kwd branch, such that future
development can go into kwd and being auto-merged to master.

bug: 5485670
Change-Id: I96a79dfe47bebd61dfcdb120f3c14028b0ba9bfe
om/android/server/wifi/hotspot/WifiHotspotService.java
om/android/server/wifi/hotspot/WifiHotspotServiceImpl.java
9790c81b2d0fb2b8c3790e4dbe6dd9fd5b93bd4d 19-Mar-2014 Jaewan Kim <jaewan@google.com> Refactor IpConfiguration from WifiConfiguration

Bug: 7606609, Bug: 8687763
Change-Id: Iec5d3237c823c7893fbba3b3209fe2b03a27a583
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiServiceImpl.java
a02919e73b463000769d708fd34ff62b9a866f29 18-Mar-2014 Yuhao Zheng <yuhaozheng@google.com> Fix incorrect tags in WifiP2pService

Looks like a typo, fixed.

Change-Id: Ie8c8d34688a1aa2328c115b3a37033530ff4f841
om/android/server/wifi/p2p/WifiP2pService.java
531869afc345c1a4fb7cd3e8d1b62acdd0963947 11-Mar-2014 Alexandra Gherghina <alexgherghina@google.com> Merge "Modifying wifi service to return the list of wifi networks for related users"
785c09f2ae609a580a620d1a45529881ea958f84 11-Mar-2014 Robert Greenwalt <rgreenwalt@google.com> Merge "Debounce wifi country code info"
fd5470391e5342daa38d00b68ccbccfeacbe6d33 10-Mar-2014 Alexandra Gherghina <alexgherghina@google.com> Modifying wifi service to return the list of wifi networks for related users

Change-Id: I66dd2625d2e3e9d135bad28c6209cf243648c7a6
om/android/server/wifi/WifiServiceImpl.java
e1b4e7479a88f987f7add2d5f9df843b16e9156b 10-Mar-2014 Vinit Deshapnde <vinitd@google.com> Merge "Fix Airplane Mode + reboot interaction for Wifi"
fbba898cf24a6969eb36238edd0f9f879029cdbd 10-Mar-2014 Vinit Deshapnde <vinitd@google.com> Merge "Wifi HAL initial implementation"
13494d0692330ed0f91e7f4e03805473773e7807 08-Mar-2014 Vinit Deshapnde <vinitd@google.com> Fix Airplane Mode + reboot interaction for Wifi

This change fixes two problems - first, if you rebooted phone after
turning on Airplane mode, Wifi controller goes to ScanOnly mode which
may end up in Wifi radio transmissions. Secondly, because of this
incorrect state, the state machine doesn't turn on Wifi once Airplane
mode is turned off.

bug: 11409692
Change-Id: I5fc23f6691bc063fda6be734103a5f11db970946
om/android/server/wifi/WifiController.java
9c22c8ea193360f50ad490368ca6a11af0684362 06-Mar-2014 Robert Greenwalt <rgreenwalt@google.com> Debounce wifi country code info

We're getting signals from the radio and it sometimes drops out for a while.
This change will delay applying an empty country code for 15sec but apply
non-empty country codes immeditately. It uses a sequence number so we only apply
the most recent change, even if it's delayed.

bug:11062898
Change-Id: I9d3a870f3b66296d4b3cbc10c730c9a043c0da96
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
ff2a397afcc14a60ed70f109318a2ee799fed692 04-Mar-2014 Vinit Deshapnde <vinitd@google.com> Merge "Fix an inadvertent change in WifiNative"
0a696d168d7ad98ab5084d2a16e3d02c545a85aa 03-Mar-2014 Vinit Deshapnde <vinitd@google.com> Explicitly set update_config on supplicant

This is to ensure that supplicant always saves network information. It is
possible for this flag to be turned off because supplicant couldn't read
wpa_supplicant.conf; but we never want supplicant to not save new networks.

Bug: 13233891
Change-Id: Ia7273dd65d01c9786be2e7dedfb39d3abe9b56c2
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiStateMachine.java
7ef73dd1b6e43c72b3841723504cd86dc402a134 28-Feb-2014 Vinit Deshapnde <vinitd@google.com> Wifi HAL initial implementation

This change introduces Wifi HAL. It has basic structure that we can expect
most commands and events to follow. Only one command is implemented for
illustration.

Change-Id: I16e4b50f3034214e41ab5d363e2c3f543345609b
om/android/server/wifi/WifiNative.java
64e65668e36bfeb0b634e9a678020ed04434f365 27-Feb-2014 Yuhao Zheng <yuhaozheng@google.com> Merge "Implement new API to scan a given channel set"
9612c46ab647596c88cfc017f7b5e338f0717ce2 26-Feb-2014 Felipe Leme <felipeal@google.com> Merge "Rename fetchRssiAndLinkSpeedNative() into fetchRssiLinkSpeedAndFrequencyNative() and changed it to also set the WiFi frequency. Bug: 12767819"
a0009d14075b5345b8f916c3fb3f2260c938cb9d 06-Feb-2014 Yuhao Zheng <yuhaozheng@google.com> Implement new API to scan a given channel set

Framework implementation for the new scan APIs. Besides implementing the API,
this CL does 2 additional changes:

1. Only count battery consumption if a scan request is accepted by supplicant,
i.e. it won't be counted if it's rejected due to another ongoing scan.

2. If a scan request is rejected, we may buffer the scan request and do it
later, to make sure the specified channels are eventually scanned. On the
other hand, we will try to combine scan requests to avoid repeated scans.
For example, a full scan serves all scan requests.

Bug: 12610436
Change-Id: Ia9edc58c7ddd7a535bfaa0f906f6faaaf5f5d439
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
ae0b5cce21686ad00fd0a3d5aab35fe2152c4737 05-Feb-2014 Vinit Deshapnde <vinitd@google.com> Fix an inadvertent change in WifiNative

wifinative.closeSupplicantConnection() closes sockets that were opened
to talk to supplicant. It was accidentally removed when we moved to
single socket connection to supplicant.

Bug: 12344420
Change-Id: I4242aff17baa91f3cdffaffb264c3bf4f93aaca3
om/android/server/wifi/WifiStateMachine.java
8d4d3c2834917d7725385d31b821ab5a8e35d600 11-Feb-2014 Narayan Kamath <narayan@google.com> Fix build (again).

Change WifiP2pService / WifiService to reflect changes to
the SystemService constructors.

Change-Id: Iad36810c1d3e08bbdca21e76113f9f9dfe79bbae
om/android/server/wifi/WifiService.java
om/android/server/wifi/p2p/WifiP2pService.java
74b0804ef846b9b4888025092dd5c75143b559dc 03-Feb-2014 Felipe Leme <felipeal@google.com> Rename fetchRssiAndLinkSpeedNative() into fetchRssiLinkSpeedAndFrequencyNative() and changed it to also set the WiFi frequency.
Bug: 12767819

Change-Id: Icc5b702475f9047311246da3440d220c67875a4c
om/android/server/wifi/WifiStateMachine.java
3f7ef65ab71619040032aee96b5599849881d6fd 23-Jan-2014 Andres Morales <anmorales@google.com> piping supplicant commands for WPS token setup

Supplicant exposes a command for generating
NFC Wifi tokens as per the Wifi Simple Configuration
specification. This CL export this command to the
framework.

Change-Id: If34e6a71888bfb2b420048eed4fe373566835611
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiStateMachine.java
1c28bb29cb19367d5e3bdbe6d8558d0fd4b8f33e 17-Jan-2014 Vinit Deshapnde <vinitd@google.com> Fix a race in Wifi service startup

For wifi services to function, we currently require network management
and connectivity service to be created. But those in turn require
wifi service pointers. So to resolve the circular dependency, we create
objects first, and then start them. With the refactoring, I increased
the window between creation and starting which is exposing a bug that
already exists - WifiController starts the moment service is created.

This was hidden before because WifiController's thread wouldn't get far
in the short window that existed before; but now that the window is longer
it is dispatching messages trying to setup set without references to
network management and connectivity service. Hence the NPE.

I am delaying the call to start wifi service to fix this.

Bug: 12527004
Change-Id: Ie5842444988d8e6cbcceff50e4f014d410e36ec1
om/android/server/wifi/WifiServiceImpl.java
155b9d09ef9b8ead3ca617afdd91e74070d3f0cb 09-Jan-2014 Vinit Deshpande <vinitd@google.com> Revert "Revert "Move Wifi services to a new git project""

This reverts commit 862f81faba40e9af8fb80744a22e968a298e814e.

Change-Id: I7b15e266a5948749026e01a61d8581746cfd0f5f
om/android/server/wifi/NetworkUpdateResult.java
om/android/server/wifi/README.txt
om/android/server/wifi/StateChangeResult.java
om/android/server/wifi/SupplicantStateTracker.java
om/android/server/wifi/WifiApConfigStore.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiController.java
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiNotificationController.java
om/android/server/wifi/WifiService.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiSettingsStore.java
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/WifiTrafficPoller.java
om/android/server/wifi/WifiWatchdogStateMachine.java
om/android/server/wifi/p2p/WifiP2pService.java
om/android/server/wifi/p2p/WifiP2pServiceImpl.java
862f81faba40e9af8fb80744a22e968a298e814e 08-Jan-2014 Vinit Deshpande <vinitd@google.com> Revert "Move Wifi services to a new git project"

This reverts commit a07c419913bfae2a896fbc29e8f269ee08c4d910.

Change-Id: I1cd35cea1594cdbeae800b9130bc6f885f238b28
om/android/server/wifi/NetworkUpdateResult.java
om/android/server/wifi/README.txt
om/android/server/wifi/StateChangeResult.java
om/android/server/wifi/SupplicantStateTracker.java
om/android/server/wifi/WifiApConfigStore.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiController.java
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiNotificationController.java
om/android/server/wifi/WifiService.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiSettingsStore.java
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/WifiTrafficPoller.java
om/android/server/wifi/WifiWatchdogStateMachine.java
om/android/server/wifi/p2p/WifiP2pService.java
om/android/server/wifi/p2p/WifiP2pServiceImpl.java
a07c419913bfae2a896fbc29e8f269ee08c4d910 18-Dec-2013 Vinit Deshapnde <vinitd@google.com> Move Wifi services to a new git project

Bug: 12175455
Change-Id: I1fa07e29c6a9aae38d9e334d519a9f2445d15613
om/android/server/wifi/NetworkUpdateResult.java
om/android/server/wifi/README.txt
om/android/server/wifi/StateChangeResult.java
om/android/server/wifi/SupplicantStateTracker.java
om/android/server/wifi/WifiApConfigStore.java
om/android/server/wifi/WifiConfigStore.java
om/android/server/wifi/WifiController.java
om/android/server/wifi/WifiMonitor.java
om/android/server/wifi/WifiNative.java
om/android/server/wifi/WifiNotificationController.java
om/android/server/wifi/WifiService.java
om/android/server/wifi/WifiServiceImpl.java
om/android/server/wifi/WifiSettingsStore.java
om/android/server/wifi/WifiStateMachine.java
om/android/server/wifi/WifiTrafficPoller.java
om/android/server/wifi/WifiWatchdogStateMachine.java
om/android/server/wifi/p2p/WifiP2pService.java
om/android/server/wifi/p2p/WifiP2pServiceImpl.java