Add an API to the Vendor HAL to create an AP
or Bridged AP iface using vendor-specific
parameters.
Bug: 296069900
Test: m
Change-Id: I4bc05195a6e0b539b426d994e59f9f61a78c1255
diff --git a/wifi/aidl/Android.bp b/wifi/aidl/Android.bp
index 7bc8ae7..ac95f85 100644
--- a/wifi/aidl/Android.bp
+++ b/wifi/aidl/Android.bp
@@ -27,6 +27,9 @@
srcs: [
"android/hardware/wifi/*.aidl",
],
+ imports: [
+ "android.hardware.wifi.common-V1",
+ ],
stability: "vintf",
backend: {
java: {
@@ -42,6 +45,9 @@
enabled: false,
},
},
+ cpp: {
+ enabled: false,
+ },
},
versions_with_info: [
{
@@ -49,6 +55,5 @@
imports: [],
},
],
- frozen: true,
-
+ frozen: false,
}
diff --git a/wifi/aidl/aidl_api/android.hardware.wifi/current/android/hardware/wifi/IWifiChip.aidl b/wifi/aidl/aidl_api/android.hardware.wifi/current/android/hardware/wifi/IWifiChip.aidl
index 4ea2081..2d7fe03 100644
--- a/wifi/aidl/aidl_api/android.hardware.wifi/current/android/hardware/wifi/IWifiChip.aidl
+++ b/wifi/aidl/aidl_api/android.hardware.wifi/current/android/hardware/wifi/IWifiChip.aidl
@@ -83,6 +83,7 @@
void triggerSubsystemRestart();
void enableStaChannelForPeerNetwork(in int channelCategoryEnableFlag);
void setMloMode(in android.hardware.wifi.IWifiChip.ChipMloMode mode);
+ @PropagateAllowBlocking android.hardware.wifi.IWifiApIface createApOrBridgedApIface(in android.hardware.wifi.IfaceConcurrencyType iface, in android.hardware.wifi.common.OuiKeyedData[] vendorData);
const int NO_POWER_CAP_CONSTANT = 0x7FFFFFFF;
@Backing(type="int") @VintfStability
enum FeatureSetMask {
diff --git a/wifi/aidl/android/hardware/wifi/IWifiChip.aidl b/wifi/aidl/android/hardware/wifi/IWifiChip.aidl
index c1caa7e..733ff62 100644
--- a/wifi/aidl/android/hardware/wifi/IWifiChip.aidl
+++ b/wifi/aidl/android/hardware/wifi/IWifiChip.aidl
@@ -33,6 +33,7 @@
import android.hardware.wifi.WifiIfaceMode;
import android.hardware.wifi.WifiRadioCombination;
import android.hardware.wifi.WifiUsableChannel;
+import android.hardware.wifi.common.OuiKeyedData;
/**
* Interface that represents a chip that must be configured as a single unit.
@@ -1149,4 +1150,27 @@
*
*/
void setMloMode(in ChipMloMode mode);
+
+ /**
+ * Create an AP or bridged AP iface on the chip using vendor-provided configuration parameters.
+ *
+ * Depending on the mode the chip is configured in, the interface creation
+ * may fail (code: |WifiStatusCode.ERROR_NOT_AVAILABLE|) if we've already
+ * reached the maximum allowed (specified in |ChipIfaceCombination|) number
+ * of ifaces of the AP or AP_BRIDGED type.
+ *
+ * @param iface IfaceConcurrencyType to be created. Takes one of
+ |IfaceConcurrencyType.AP| or |IfaceConcurrencyType.AP_BRIDGED|
+ * @param vendorData Vendor-provided configuration data as a list of |OuiKeyedData|.
+ * @return AIDL interface object representing the iface if
+ * successful, null otherwise.
+ * @throws ServiceSpecificException with one of the following values:
+ * |WifiStatusCode.ERROR_WIFI_CHIP_INVALID|,
+ * |WifiStatusCode.ERROR_NOT_SUPPORTED|,
+ * |WifiStatusCode.ERROR_NOT_AVAILABLE|,
+ * |WifiStatusCode.ERROR_INVALID_ARGS|
+ */
+ @PropagateAllowBlocking
+ IWifiApIface createApOrBridgedApIface(
+ in IfaceConcurrencyType iface, in OuiKeyedData[] vendorData);
}