Country code is global setting across the Wifi chip
and not really Wifi interface (STA or AP) specific.
Framework should have the ability to set the country
code on a chip level without requiring supplicant
instance to be running. As long as there is at least
one active interface to communicate to kernel driver,
country code can be set and driver should apply the
setting globally.
Bug: 149936939
Test: VTS - VtsHalWifiV1_5TargetTest
Change-Id: I1be5dae34b216a6152d09605d055872d5345507c
The current hostapd use channelParams1_3.bandMask
(changed on ag/13001575), but VTS doesn't
prepare test data:channelParams1_3.bandMask.
Test: atest VtsHalWifiHostapdV1_3TargetTest
Test: atest VtsHalWifiHostapdV1_2TargetTest
Test: atest VtsHalWifiHostapdV1_1TargetTest
Test: atest VtsHalWifiHostapdV1_0TargetTest
Bug: 176139512
Change-Id: Ibdc08acb55b673b464b5c59ae714157941487a5b
Added 2 seconds delay in RTT tests. This helps drivers finish the
current test and process the next test.
Bug: 175605811
Test: VTS test - VtsHalWifiRttV1_4TargetTest
Change-Id: I3bb719b5b75ba960913bd405b2c8a41047689682
Add custom enum for wifi coex restrictions since IfaceType is not
suitable for use as a bitmask flag since it does not represent bit
positions.
Bug: 153651001
Test: build
Change-Id: I15575ea12784a778a3b358eea1b05b75319aa95b
1. The concurrent property name over the limitation.
Rename the property name.
2. When allocate bridged iface name, it needs to increase the idx to
avoid two ifaces use the same name.
Bug: 162686273
Test: atest -c VtsHalWifiApV1_0TargetTest
Test: atest -c VtsHalWifiApV1_4TargetTest
Test: atest -c VtsHalWifiApV1_5TargetTest
Change-Id: I388cdd812bd0448c03ad5ae982547629c1e5eff9
Add HIDL APIs to convey a list of unsafe Wifi channels to the driver for
coex channel avoidance.
Bug: 153651001
Test: build
Change-Id: I8b14f0e2d8855c1f1e363d612617256d8e928f30
SAP Interface idx mechanism.
STA+STA support, AP+AP will use wlan2 & wlan3, single AP use wlan2
STA+STA doesn't support, AP+AP use wlan1 & wlan 2, single AP use
wlan 1
STA+AP doesn't support, AP + AP will take wlan0 & wlan 1 but single AP
use wlan0 (Ideally it should not happen)
Add predefine interface support for bridged AP interface.
(property: ro.vendor.sap.concurrent.interface)
PS: Rename: getApIfaceName to getPredefinedApIfaceName since it
duplicates public HAL API: getApIfaceName
AP+AP Part 4 includes:
1. Support API to indicate Bridged AP supported or not
2. SAP Interface idx mechanism.
Bug: 162686273
Bug: 173999527
Test: atest -c VtsHalWifiApV1_0TargetTest
Test: atest -c VtsHalWifiApV1_4TargetTest
Test: atest -c VtsHalWifiApV1_5TargetTest
Change-Id: I115e294ac2be201cfa3a58cfa0a8a98b481b29de
On a low-end device which does not support STA-SAP concurrency, if STA
is currently enabled and user/app tries to enable SAP, then Wi-Fi needs
to reconfigure and stop Wi-Fi HAL first. Among other stopping actions,
HAL needs to set global_handle_ to nullptr and send "Exit" to
wifi_event_loop then waits no more than kMaxStopCompleteWaitMs. If the
wait times out, then reconfiguration fails and causes Wi-Fi controller
returns to STA mode and creates new STA iface indirectly. In this
process, HAL needs to access global_handle_, but since it was cleared,
we can only get a Native Exception.
Because there is no proper error recovery for UNKNOWN errors, I suggest
to simply set kMaxStopCompleteWaitMs to a higher value to circumvent
this timing issue.
Bug: 173760638
Change-Id: I1b5a0a7a554409704c017ffaf52a767b9424c61e
Support HAL API:resetToFactoryMacAddress to reset the MAC
to factory MAC on each instances in IWifiApIface.
AP+AP Part 3 includes:
1. Support resetToFactoryMac in IWifiApIface.Hal.
2. Vts support for non bridged API.
3. Framework support resetToFactoryMac in bridged Ap.
Test: atest -c VtsHalWifiApV1_5TargetTest
Test: atest -c VtsHalWifiApV1_4TargetTest
Test: atest -c VtsHalWifiApV1_0TargetTest
Bug: 162686273
Change-Id: Ic7f2c0d6f1d8bf46fabfbc874d5f2b74068e43cc
Added below HIDL APIs for DPP STA Enrollee-Responder mode
1. API to start DPP in Enrollee-Responder mode
2. API to generate DPP bootstrap URI
3. API to stop DPP in Enrollee-Responder mode
which internally remove the bootstrap and stop listen.
Bug: 162686712
Test: VTS test
Change-Id: I979b6a7a2fe90f48d478f48da73269fd3f5cb347
If dumpstate closes the reading end of the pipe (likely due to timeout)
and wifi vendor hal attempts to write to the fd it received from
dumpstate, it will receive sig 13 (SIGPIPE), and is then killed.
We should protect wifi vendor hal from the abnormally behaved clients.
Sync patch from ag/12321138. Reference from b/172972545 &
b/161336019#comment29
Bug: 161336019
Bug: 172972545
Test: Manuel Test, Wifi works normally
Change-Id: Ie7de040ac4320f83500c18e74e3c58d63b4df1b7
The bridge interface name will take "ap_br_" + ap interface name.
ex: The ap interface name is "wlan1".
The bridge interface name will be "ap_br_wlan1"
When OEM customize the ap interface name via property
"ro.vendor.wifi.sap.interface".
It will only apply on single AP mode.
i.e.
"ro.vendor.wifi.sap.interface" = "sap0"
Single AP mode: ap interface name = "sap0"
Dual AP mode:
bridge interface name = "ap_br_sap0"
first ap instance name: get from "getSupportedIfaceName" + idx
ex: sap0
second ap instance name: get from "getSupportedIfaceName" + idx + 1
ex: sap1
PS: The VtsHalWifiApV1_5TargetTest will be added in another CL which
will update another SAP related HAL:IWifiApIface.hal.
AP+AP Part 2 includes:
1. Support bridge in libwifi_system_iface
2. WifiHal API
a. createBridgedApIface (Support create bridge mode AP)
b. removeIfaceInstanceFromBridgedApIface (Support remove one of the instance in bridge)
3. Framework:
Create bridge AP when multi-bands configured.
Bug: 162686273
Test: Manual Test (SAP enable normally)
Test: atest -c VtsHalWifiApV1_0TargetTest
Test: atest -c VtsHalWifiApV1_4TargetTest
Change-Id: I8be510778e9772bcf1539e4915384949cbe13127
Older registerCallback is not deprecated until V1.4 HAL correctly.
As a result, their returning codes are still SUCCESS.
Bug: 173570755
Test: atest VtsHalWifiSupplicantV1_0TargetTest \
VtsHalWifiSupplicantV1_1TargetTest \
VtsHalWifiSupplicantV1_2TargetTest
Change-Id: Ib23821d64f53c144d74818fa3ed9aca06cd25a27
AP+AP Part 2 includes:
1. Support bridge in libwifi_system_iface
2. WifiHal
a. createApIface_1_5 (Support create bridge mode AP)
b. removeApIface_1_5 (Support remove one of the instance in bridge)
3. Framework:
Create bridge AP when multi-bands configured.
Bug: 162686273
Test: Manual Test (SAP enable normally)
Change-Id: I518417add566ce4780a7e2e83af14460e6e8a217
Extend the band with 60GHz constant to support starting
AP on the 60GHz band.
Add channel parameters for EDMG (802.11ay, 60GHz channel
bonding).
Bug: 147469374
Test: atest VtsHalWifiHostapdV1_3TargetTest
Change-Id: I8d3ca0c14766dfb4a79c1febcc2bb05f65ba311e
This will be useful for testing/debugging STA + STA & AP + AP feature.
Note: I originally planned to read the entire iface combination from the
property (i.e would be much more flexible), but that is way too complex
and error prone. So, instead pre-define some combinations that we would
want to switch between and use the property as an index.
Bug: 173044646
Test: Manual:
i) adb shell "/vendor/bin/sh -c '/vendor/bin/setprop
persist.vendor.debug.wifi.hal.preset_interface_combination_idx 0'"
ii) adb reboot
iii) Ensure that AP + AP was enabled.
Change-Id: Iea63835c39fce78307a056a5ed94efcbd35cdfb6
The logic to skip the p2p tests on non-p2p devices appear to have
inadventently flipped since d6436731.
Bug: 173134041
Test: atest VtsHalWifiSupplicantV1_1TargetTest
Change-Id: I7945950e8483241e47e308a2c5ad97571d74a769
Having the AP and STA set the same MAC address in tests could cause
unintended failures when WifiApIfaceHidlTest and WifiStaIfaceHidlTest
are executed back to back.
Bug: 172528120
Test: atest VtsHalWifiApV1_4TargetTest VtsHalWifiV1_2TargetTest
Change-Id: I336d21cd896c46b064f16ecfa184a26dab67deaa
The vts use getAidlInstances to check current HIDL version whether or not
exist in the device manifests.
When there are no instances installed, the suite won't be instantiated
Test: atest -c VtsHalWifiHostapdV1_3TargetTest in S GSI + R build
Bug: 172539662
Change-Id: Ia268282eeeb53a092bb5f36ef0426ac213b45a9f