3519 Commits

Author SHA1 Message Date
David Su
b1e84779fe frameworks/base/wifi: unpack non-updatable/ folder
Everything remaining in frameworks/base/wifi is non-updatable.
Thus, unpack non-updatable/ folder and move everything under
wifi/.

Bug: 137323948
Test: presubmit
Change-Id: I6e1bd3fe6335b5dbe5f8ffa84a84df6434c95674
2020-12-29 13:01:24 -08:00
Baligh Uddin
09fdba4271 Migrate frameworks/base/wifi & frameworks/base/packages/OsuLogin
Migrate to packages/modules/Wifi.  This CL will be presubmit tested
once migration is complete.  This CL drops the code from
frameworks/base/wifi and migrated to packages/modules/Wifi.
Also adjusts visibility rules in frameworks/base/Android.bp
Bug: 137323948
Test: TH

Change-Id: Id02e28648e922a30d6a81cf92b39eff4ca3cc002
2020-12-23 22:42:10 +00:00
Roshan Pius
46d5d5264f Merge "WifiManager: Remove javadoc reference to multi STA concurrency API" am: 5d3b26484c am: 90a64f7002 am: 5f217f2b9b
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1535862

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Ic27ecb61d60865ca268c9f31886d86f3555350ea
2020-12-23 21:48:59 +00:00
Roshan Pius
be39ce4f19 WifiManager: Remove javadoc reference to multi STA concurrency API
The multi STA concurrency API is not present in AOSP.

Bug: 162602799
Test: None
Change-Id: Iaecedf42890777f6d4507bb81d359e67270ebebb
2020-12-23 20:25:37 +00:00
Roshan Pius
e126101fe6 Merge changes from topic "wifi_transport_info_stage_1"
* changes:
  WifiInfo: Add equals implementation
  Convert WifiInfo to TransportInfo
2020-12-23 19:37:10 +00:00
Roshan Pius
7db76b6723 Merge changes from topic "wifi_transport_info_stage_1"
* changes:
  WifiInfo: Add equals implementation
  Convert WifiInfo to TransportInfo
2020-12-23 18:35:31 +00:00
Les Lee
b241613297 Merge changes from topic "bridged_AP_callback"
* changes:
  wifi: Add callback onConnectedClientsOrInfoChanged handling
  wifi: Add new callback to support use case in bridged mode
2020-12-23 13:53:17 +00:00
Roshan Pius
3653444d02 WifiInfo: Add equals implementation
This is needed for connectivity to compare TransportInfo instances.

Bug: 162602799
Test: atest android.net.wifi
Change-Id: I215b769339f68b76a1b2fa15f66c4527d184b696
Merged-In: I215b769339f68b76a1b2fa15f66c4527d184b696
2020-12-23 00:19:17 -08:00
Roshan Pius
6c5626edfc Convert WifiInfo to TransportInfo
Also, deprecate WifiManager.getConnectionInfo() and add a note to
help apps to migrate. The deprecation is purely cosmetic, no plans to
remove any existing functionality from the WifiManager API.

Bug: 162602799
Test: Compiles
Change-Id: I12c473185dc5518f5684e83c2f49e07271738cb5
Merged-In: I12c473185dc5518f5684e83c2f49e07271738cb5
2020-12-23 00:19:06 -08:00
Roshan Pius
80222a8079 WifiInfo: Add equals implementation
This is needed for connectivity to compare TransportInfo instances.

(cherry-picked from aosp/1508601)

Bug: 162602799
Test: atest android.net.wifi
Change-Id: I215b769339f68b76a1b2fa15f66c4527d184b696
2020-12-22 23:47:49 -08:00
Roshan Pius
36f802a060 Convert WifiInfo to TransportInfo
Also, deprecate WifiManager.getConnectionInfo() and add a note to
help apps to migrate. The deprecation is purely cosmetic, no plans to
remove any existing functionality from the WifiManager API.

(cherry-picked from aosp/1508600)

Bug: 162602799
Test: Compiles
Change-Id: I12c473185dc5518f5684e83c2f49e07271738cb5
2020-12-22 23:47:46 -08:00
Jimmy Chen
7ff19c531f Merge changes from topics "s-security-params-backup-restore", "s-seucrity-params-setup-migration"
* changes:
  wifi: add setSecurityParams APIs for wifi service migration
  wifi: add getSecurityType and createSecurityParamsBySecurityType methods
2020-12-23 05:24:38 +00:00
lesl
e5436af58c wifi: Add callback onConnectedClientsOrInfoChanged handling
Now service will only send onConnectedClientsOrInfoChanged to Manager
side. Add callback handling to dispatch correct callback base on below
scenarios.

1. onInfoChanged(SoftApInfo) will send when a. registration (non bridged) b. non
bridged and info changed
2. onInfoChanged(List) will send when a. registration b. info changed
3. onConnectedClientsChanged(List<WifiClient>) will send  a. registration b. clients changed
4. onConnectedClientsChanged(SoftApInfo, List<WifiClient>) will send
a. when registration and client connected b. client changed on specific
instance. It will also need to handle when info changed(dismisssed), it
means that an instance shutdown. It needs to send empty list if previous
instance has client connected.

AP+AP Part 6 includes:
Support dual SoftApInfo callback
   a. New callback onInfoChanged(List<SoftApInfo>) &
      onConnectedClientsChanged(SoftApInfo, List<WifiClient>)
   b. Callback refactoring
   c. Support shutdown idle instance in bridged mode

Bug: 162686273
Bug: 175351193
Test: FrameworksWifiApiTests
Test: Manual Test, check the log and check SystemUI to confirm clients
update correctly.

Change-Id: Id587125edbb1167f58bba6b50a708be12888490f
2020-12-23 12:42:19 +08:00
David Su
9548db78b0 frameworks/base/wifi: Move migration_samples to non-updatable directory
This is not part of the Wifi module, move it to the non-updatable
directory.

Bug: 176105484
Test: compiles
Merged-In: Ia95e300da9286d79ee57c285c3bfa88ecc98e326
Change-Id: I495b3edc6e7a6bbb7bae287e8bdd88243e72da70
2020-12-22 18:07:34 +00:00
David Su
512ba3c3d1 Split updatable/non-updatable Wifi APIs into separate directories
This creates a clearer boundary between what is updatable
(part of the Wifi module) and what is not updatable (outside
the module).

Bug: 176105484
Test: compiles
Merged-In: Ia95e300da9286d79ee57c285c3bfa88ecc98e326
Change-Id: I1747f52f18210bb05bcc414461bf95aa461577a6
2020-12-22 06:10:40 +00:00
Jimmy Chen
97ff070f4e wifi: add setSecurityParams APIs for wifi service migration
Bug: 162685856
Test: atest FrameworksWifiApiTest
Change-Id: I6b53227a9fb5e68cc2039cb29a8ab3e11bc70bc8
2020-12-22 13:54:14 +08:00
Jimmy Chen
8d0bb8682d wifi: add getSecurityType and createSecurityParamsBySecurityType methods
For backup/restore, it needs to know security type and create a security
params from the security type.

Bug: 162685856
Test: atest FrameworksWifiApiTes
Change-Id: I2a52a288157d7875074f8e20218d564c363b568f
2020-12-22 13:54:14 +08:00
David Su
8814f7f4f2 frameworks/base/wifi: Move migration_samples to non-updatable directory
This is not part of the Wifi module, move it to the non-updatable
directory.

Bug: 176105484
Test: compiles
Change-Id: I38b6eeb6d784cc6e2a87f0161b32be180ade3bdc
2020-12-21 14:50:34 -08:00
David Su
e7cc3ae663 Split updatable/non-updatable Wifi APIs into separate directories
This creates a clearer boundary between what is updatable
(part of the Wifi module) and what is not updatable (outside
the module).

Bug: 176105484
Test: compiles
Change-Id: Ia95e300da9286d79ee57c285c3bfa88ecc98e326
2020-12-21 12:28:29 -08:00
lesl
54028c118f wifi: Add new callback to support use case in bridged mode
In bridged mode, it needs the way to know connected client and info in
each instance. Add callback onConnectedClientsChangedWithApInfo to
provide the link between clients and info

1. onConnectedClientsChanged(SoftApInfo, List<WifiClient>)
2. onInfoChanged(List<SoftApInfo>)

PS: This CL# also refactoring the callback in service side.
Move to Manager side to handle it.
Service side:
onConnectedClientsOrInfoChanged, integrate 4 callbacks to
one callback and pass all of the current infos to Manager.

PS: Convert one callback to 4 callback in Manager side will in another CL#.
Now only handle onConnectedClientsChanged in single AP mode to avoid
block AOSP Setting/SystemUI usage.

Manager side: (public systemApi)
1. onInfoChanged(SoftApInfo)
2. onInfoChanged(List<SoftApInfo>)
3. onConnectedClientsChanged(SoftApInfo, List<WifiClient>)
4. onConnectedClientsChanged(List<WifiClient>)

AP+AP Part 6 includes:
Support dual SoftApInfo callback
   a. New callback onInfoChanged(List<SoftApInfo>) &
      onConnectedClientsChanged(SoftApInfo, List<WifiClient>)
   b. Callback refactoring
   c. Support shutdown idle instance in bridged mode

Bug: 162686273
Test: FrameworksWifiApiTests
Change-Id: I861ad4ece908ec98fd500b249906ee73fff0a72a
2020-12-18 11:22:27 +08:00
Quang Luong
97e9a0ca63 Merge "[WifiCoex] Add @hide API for default coex algorithm enabled or not" 2020-12-17 21:58:07 +00:00
TreeHugger Robot
537fa9c334 Merge "WifiNl80211Manager: improve logging" 2020-12-16 20:21:55 +00:00
David Su
cbc6ab9444 WifiNl80211Manager: improve logging
Log ifaceName & method names.

Bug: 175614847
Test: atest FrameworksWifiApiTests
Change-Id: Idd26fdcd02c9e3fd352a822775ed03b3039bcecc
2020-12-16 08:33:40 -08:00
Chalard Jean
95b575f468 Move module utils to the module package.
Test: FrameworksWifiTest FrameworksNetTest
Change-Id: If5d1e4a58fb2d6d9544e6d01995dabe445cf1f25
Merged-In: I067eeecd458c34b7f2fbfa439072682661ac750c
2020-12-16 11:44:22 +09:00
Quang Luong
f24f4e830d [WifiCoex] Add @hide API for default coex algorithm enabled or not
Add @hide API to return whether the default coex algorithm is enabled or
not for ACTS testing.

Bug: 153651001
Test: build
Change-Id: I4c574c767a8cc2c325139f5f668dd7090efd68b4
2020-12-15 16:02:44 -08:00
Nate Jiang
ac0330133c Merge "[Suggestion] Add listener for user approval status change" 2020-12-15 18:05:34 +00:00
TreeHugger Robot
1ecd270dbe Merge "Wifi: Disable network when detecting carrier eap error" 2020-12-15 07:48:53 +00:00
David Su
74f5161e3d Merge "framework-wifi: Migrate ParceledListSlice to the version from module-utils" 2020-12-14 16:45:40 +00:00
Jimmy Chen
ea1b4b2299 Merge "wifi: create security type for Passpoint R1/R2 and R3" 2020-12-14 08:55:03 +00:00
Roy Want
2aab670722 Merge "Adding setter and getters for setRttBurstSize() in RangingRequest (client)" 2020-12-14 05:13:40 +00:00
Jimmy Chen
3f8b46ebf8 wifi: create security type for Passpoint R1/R2 and R3
Bug: 162685856
Test: atest FrameworksWifiApiTests
Change-Id: I5cda53edd286787c97dfb09d047d582c97e8684b
2020-12-13 15:06:06 +08:00
Jimmy Chen
5082458b5f Merge "softap: Add BAND_60GHZ to SoftApConfiguration" 2020-12-12 04:26:03 +00:00
Roy Want
0f5884ba69 Adding setter and getters for setRttBurstSize() in RangingRequest (client)
Bug: 163355222
Test: adding methods to class. Existing unit tests and 3 additional tests pass.
Change-Id: Ie003e63350faa257f8dbd68d6918961580745cce
2020-12-11 17:49:26 -08:00
Oscar Shu
0c5f84eb71 Merge "Allow setup wizard to call carrier selection APIs" 2020-12-11 01:51:20 +00:00
Jimmy Chen
b7d2443563 Merge "wifi: add security params class for known security types" 2020-12-11 01:46:21 +00:00
Nate Jiang
1bbcd4ef88 [Suggestion] Add listener for user approval status change
Bug: 160648511
Test: atest android.net.wifi
Change-Id: I2a1959a2504e274de83f9cd0e44300222bbe8aac
2020-12-10 17:43:07 -08:00
Les Lee
af6b01e143 Merge "wifi: Add instance identifier in SoftApInfo/WifiClient and infoList callback" 2020-12-10 23:50:45 +00:00
Etan Cohen
0c52537880 Merge "[WIFI] Trigger WiFi recovery mode" 2020-12-10 20:42:35 +00:00
David Su
e4bea7b1c8 framework-wifi: Migrate ParceledListSlice to the version from module-utils
Bug: 175130412
Test: boots up and connects to wifi
Change-Id: Ia0d26ad39e994a7a177db2ef4082ee04bff87e10
2020-12-10 09:18:06 -08:00
Isaac Chiou
48b6f8616f Wifi: Disable network when detecting carrier eap error
Disable network temporarily when detecting carrier eap error

Bug: 148940011
Test: atest FrameworksWifiTests
Test: make sure network can be disabled when detecting carrier eap error
Change-Id: Ide5f8b2a084ce3d72b6ba820393b9fb9b22aff0f
2020-12-10 20:26:30 +08:00
lesl
d3d17acd9c wifi: Add instance identifier in SoftApInfo/WifiClient and infoList callback
1. The framework need to know the instance of the client connected to
know which instance is idled.

2. The framework need to know the instance of the soft AP info.

3. Add infoList callback support for dual APs mode.

AP+AP Part 5 includes:
1. Support forceClientDisconnect in dual AP mode.
2. Support dual SoftApInfo callback
   a. New callback onInfoListChanged
   b. Add instanceIdentifier in SoftApInfo but it is used only in
   framework.
   c. Add instanceIdentifier in WifiClient but it is used only in
   framework.

Bug: 162686273
Test: FrameworksWifiApiTests
Change-Id: I207831ff15a3044316556d61a72542ff35c94e74
2020-12-10 18:07:34 +08:00
Jimmy Chen
6157d1abdf wifi: add security params class for known security types
Bug: 162685856
Test: atest FrameworksWifiApiTests
Change-Id: I020d338b1829f19f6dde8b1969f64cc065f8d796
2020-12-10 16:02:37 +08:00
Les Lee
5b85c391a8 Merge "wifi: Remove internal function, add version checks when using new API" 2020-12-10 06:21:08 +00:00
Etan Cohen
ac1a7a3e1f [WIFI] Trigger WiFi recovery mode
Trigger WiFi recovery. The WiFi chip will get disabled and then
re-enabled. The state at the exit may not match the entry state.

Bug: 175084231
Test: atest com.android.server.wifi
Test: atest android.net.wifi
Test: adb shell cmd wifi trigger-recovery
Change-Id: Ie46bc697dcc003758c5df7c7c9d594e365086c7d
2020-12-09 21:58:17 -08:00
xshu
0ce2a88125 Allow setup wizard to call carrier selection APIs
Bug: 173054916
Test: compile
Change-Id: I38f96e91a27e180a8a2b7b862fe4b67e3ca741f8
2020-12-09 20:10:20 -08:00
Oscar Shu
aeca95853e Merge "Associate RSSI with UCC" 2020-12-09 01:03:15 +00:00
Nate Jiang
b0e9cc91eb Merge "Pipe new flag into passpoint" 2020-12-04 20:17:45 +00:00
Les Lee
a046679e13 Merge "wifi: Add API to indicate (STA) + Bridged AP supported (Part 4)" 2020-12-04 06:43:29 +00:00
Nate Jiang
d5980661db Pipe new flag into passpoint
Pipe oemPaid, oemPrivite, and carrierMerged into passpoint profile

Bug: 172867186
Test: atest android.net.wifi
Change-Id: If253aca1d26fe5575fa9edbdd0d6fe75d9d4ca81
2020-12-04 06:07:19 +00:00
lesl
9f8b4a8e4c wifi: Remove internal function, add version checks when using new API
1. Remove internal function
2. Add the version check in new APIs which miss it before

Bug: 173791707
Test: S module on R base image boots and connects to wifi and SAP
enable succeed.

Change-Id: Ic9ea9fecfa7d39f54a1875ad687fe21c1381124c
2020-12-04 13:59:46 +08:00