From 6ce509085453637ddd3d0a1a88a26fed18072167 Mon Sep 17 00:00:00 2001 From: Etan Cohen Date: Thu, 14 Sep 2017 07:30:57 -0700 Subject: [PATCH] [WIFI][TREBLE] Uprev Wi-Fi HAL 1.2 In preparation for new feature development - uprev the Wi-Fi Treble HAL revision from 1.1 to 1.2. This CL does not contain any functional changes to the HAL itself. Only updating the revision. Bug: 65647646 Test: builds and Wi-Fi runs Change-Id: I8e80e866562a508bf481104a3dbcf2bd8f8015b4 --- wifi/1.2/Android.bp | 73 +++++++++++++++++++ wifi/1.2/Android.mk | 64 ++++++++++++++++ wifi/1.2/IWifi.hal | 29 ++++++++ wifi/1.2/IWifiChip.hal | 27 +++++++ wifi/{1.1 => 1.2}/default/Android.mk | 1 + wifi/{1.1 => 1.2}/default/OWNERS | 0 wifi/{1.1 => 1.2}/default/THREADING.README | 0 .../android.hardware.wifi@1.0-service.rc | 0 .../{1.1 => 1.2}/default/hidl_callback_util.h | 4 +- wifi/{1.1 => 1.2}/default/hidl_return_util.h | 4 +- .../{1.1 => 1.2}/default/hidl_struct_util.cpp | 4 +- wifi/{1.1 => 1.2}/default/hidl_struct_util.h | 4 +- wifi/{1.1 => 1.2}/default/hidl_sync_util.cpp | 4 +- wifi/{1.1 => 1.2}/default/hidl_sync_util.h | 4 +- wifi/{1.1 => 1.2}/default/service.cpp | 4 +- wifi/{1.1 => 1.2}/default/wifi.cpp | 4 +- wifi/{1.1 => 1.2}/default/wifi.h | 9 +-- wifi/{1.1 => 1.2}/default/wifi_ap_iface.cpp | 4 +- wifi/{1.1 => 1.2}/default/wifi_ap_iface.h | 4 +- wifi/{1.1 => 1.2}/default/wifi_chip.cpp | 4 +- wifi/{1.1 => 1.2}/default/wifi_chip.h | 4 +- .../{1.1 => 1.2}/default/wifi_feature_flags.h | 4 +- wifi/{1.1 => 1.2}/default/wifi_legacy_hal.cpp | 4 +- wifi/{1.1 => 1.2}/default/wifi_legacy_hal.h | 4 +- .../default/wifi_legacy_hal_stubs.cpp | 4 +- .../default/wifi_legacy_hal_stubs.h | 4 +- .../default/wifi_mode_controller.cpp | 4 +- .../default/wifi_mode_controller.h | 4 +- wifi/{1.1 => 1.2}/default/wifi_nan_iface.cpp | 4 +- wifi/{1.1 => 1.2}/default/wifi_nan_iface.h | 4 +- wifi/{1.1 => 1.2}/default/wifi_p2p_iface.cpp | 4 +- wifi/{1.1 => 1.2}/default/wifi_p2p_iface.h | 4 +- .../default/wifi_rtt_controller.cpp | 4 +- .../default/wifi_rtt_controller.h | 4 +- wifi/{1.1 => 1.2}/default/wifi_sta_iface.cpp | 4 +- wifi/{1.1 => 1.2}/default/wifi_sta_iface.h | 4 +- .../{1.1 => 1.2}/default/wifi_status_util.cpp | 4 +- wifi/{1.1 => 1.2}/default/wifi_status_util.h | 4 +- wifi/Android.bp | 1 + 39 files changed, 257 insertions(+), 63 deletions(-) create mode 100644 wifi/1.2/Android.bp create mode 100644 wifi/1.2/Android.mk create mode 100644 wifi/1.2/IWifi.hal create mode 100644 wifi/1.2/IWifiChip.hal rename wifi/{1.1 => 1.2}/default/Android.mk (98%) rename wifi/{1.1 => 1.2}/default/OWNERS (100%) rename wifi/{1.1 => 1.2}/default/THREADING.README (100%) rename wifi/{1.1 => 1.2}/default/android.hardware.wifi@1.0-service.rc (100%) rename wifi/{1.1 => 1.2}/default/hidl_callback_util.h (98%) rename wifi/{1.1 => 1.2}/default/hidl_return_util.h (99%) rename wifi/{1.1 => 1.2}/default/hidl_struct_util.cpp (99%) rename wifi/{1.1 => 1.2}/default/hidl_struct_util.h (99%) rename wifi/{1.1 => 1.2}/default/hidl_sync_util.cpp (96%) rename wifi/{1.1 => 1.2}/default/hidl_sync_util.h (96%) rename wifi/{1.1 => 1.2}/default/service.cpp (91%) rename wifi/{1.1 => 1.2}/default/wifi.cpp (99%) rename wifi/{1.1 => 1.2}/default/wifi.h (94%) rename wifi/{1.1 => 1.2}/default/wifi_ap_iface.cpp (98%) rename wifi/{1.1 => 1.2}/default/wifi_ap_iface.h (98%) rename wifi/{1.1 => 1.2}/default/wifi_chip.cpp (99%) rename wifi/{1.1 => 1.2}/default/wifi_chip.h (99%) rename wifi/{1.1 => 1.2}/default/wifi_feature_flags.h (96%) rename wifi/{1.1 => 1.2}/default/wifi_legacy_hal.cpp (99%) rename wifi/{1.1 => 1.2}/default/wifi_legacy_hal.h (99%) rename wifi/{1.1 => 1.2}/default/wifi_legacy_hal_stubs.cpp (99%) rename wifi/{1.1 => 1.2}/default/wifi_legacy_hal_stubs.h (96%) rename wifi/{1.1 => 1.2}/default/wifi_mode_controller.cpp (98%) rename wifi/{1.1 => 1.2}/default/wifi_mode_controller.h (97%) rename wifi/{1.1 => 1.2}/default/wifi_nan_iface.cpp (99%) rename wifi/{1.1 => 1.2}/default/wifi_nan_iface.h (99%) rename wifi/{1.1 => 1.2}/default/wifi_p2p_iface.cpp (98%) rename wifi/{1.1 => 1.2}/default/wifi_p2p_iface.h (97%) rename wifi/{1.1 => 1.2}/default/wifi_rtt_controller.cpp (99%) rename wifi/{1.1 => 1.2}/default/wifi_rtt_controller.h (99%) rename wifi/{1.1 => 1.2}/default/wifi_sta_iface.cpp (99%) rename wifi/{1.1 => 1.2}/default/wifi_sta_iface.h (99%) rename wifi/{1.1 => 1.2}/default/wifi_status_util.cpp (98%) rename wifi/{1.1 => 1.2}/default/wifi_status_util.h (97%) diff --git a/wifi/1.2/Android.bp b/wifi/1.2/Android.bp new file mode 100644 index 0000000000..e9fac3d8e1 --- /dev/null +++ b/wifi/1.2/Android.bp @@ -0,0 +1,73 @@ +// This file is autogenerated by hidl-gen. Do not edit manually. + +filegroup { + name: "android.hardware.wifi@1.2_hal", + srcs: [ + "IWifi.hal", + "IWifiChip.hal", + ], +} + +genrule { + name: "android.hardware.wifi@1.2_genc++", + tools: ["hidl-gen"], + cmd: "$(location hidl-gen) -o $(genDir) -Lc++-sources -randroid.hardware:hardware/interfaces -randroid.hidl:system/libhidl/transport android.hardware.wifi@1.2", + srcs: [ + ":android.hardware.wifi@1.2_hal", + ], + out: [ + "android/hardware/wifi/1.2/WifiAll.cpp", + "android/hardware/wifi/1.2/WifiChipAll.cpp", + ], +} + +genrule { + name: "android.hardware.wifi@1.2_genc++_headers", + tools: ["hidl-gen"], + cmd: "$(location hidl-gen) -o $(genDir) -Lc++-headers -randroid.hardware:hardware/interfaces -randroid.hidl:system/libhidl/transport android.hardware.wifi@1.2", + srcs: [ + ":android.hardware.wifi@1.2_hal", + ], + out: [ + "android/hardware/wifi/1.2/IWifi.h", + "android/hardware/wifi/1.2/IHwWifi.h", + "android/hardware/wifi/1.2/BnHwWifi.h", + "android/hardware/wifi/1.2/BpHwWifi.h", + "android/hardware/wifi/1.2/BsWifi.h", + "android/hardware/wifi/1.2/IWifiChip.h", + "android/hardware/wifi/1.2/IHwWifiChip.h", + "android/hardware/wifi/1.2/BnHwWifiChip.h", + "android/hardware/wifi/1.2/BpHwWifiChip.h", + "android/hardware/wifi/1.2/BsWifiChip.h", + ], +} + +cc_library { + name: "android.hardware.wifi@1.2", + defaults: ["hidl-module-defaults"], + generated_sources: ["android.hardware.wifi@1.2_genc++"], + generated_headers: ["android.hardware.wifi@1.2_genc++_headers"], + export_generated_headers: ["android.hardware.wifi@1.2_genc++_headers"], + vendor_available: true, + vndk: { + enabled: true, + }, + shared_libs: [ + "libhidlbase", + "libhidltransport", + "libhwbinder", + "liblog", + "libutils", + "libcutils", + "android.hardware.wifi@1.0", + "android.hardware.wifi@1.1", + ], + export_shared_lib_headers: [ + "libhidlbase", + "libhidltransport", + "libhwbinder", + "libutils", + "android.hardware.wifi@1.0", + "android.hardware.wifi@1.1", + ], +} diff --git a/wifi/1.2/Android.mk b/wifi/1.2/Android.mk new file mode 100644 index 0000000000..d7380768c3 --- /dev/null +++ b/wifi/1.2/Android.mk @@ -0,0 +1,64 @@ +# This file is autogenerated by hidl-gen. Do not edit manually. + +LOCAL_PATH := $(call my-dir) + +################################################################################ + +include $(CLEAR_VARS) +LOCAL_MODULE := android.hardware.wifi-V1.2-java +LOCAL_MODULE_CLASS := JAVA_LIBRARIES + +intermediates := $(call local-generated-sources-dir, COMMON) + +HIDL := $(HOST_OUT_EXECUTABLES)/hidl-gen$(HOST_EXECUTABLE_SUFFIX) + +LOCAL_JAVA_LIBRARIES := \ + android.hardware.wifi-V1.0-java \ + android.hardware.wifi-V1.1-java \ + android.hidl.base-V1.0-java \ + +LOCAL_NO_STANDARD_LIBRARIES := true +LOCAL_JAVA_LIBRARIES += core-oj hwbinder + +# +# Build IWifi.hal +# +GEN := $(intermediates)/android/hardware/wifi/V1_2/IWifi.java +$(GEN): $(HIDL) +$(GEN): PRIVATE_HIDL := $(HIDL) +$(GEN): PRIVATE_DEPS := $(LOCAL_PATH)/IWifi.hal +$(GEN): PRIVATE_OUTPUT_DIR := $(intermediates) +$(GEN): PRIVATE_CUSTOM_TOOL = \ + $(PRIVATE_HIDL) -o $(PRIVATE_OUTPUT_DIR) \ + -Ljava \ + -randroid.hardware:hardware/interfaces \ + -randroid.hidl:system/libhidl/transport \ + android.hardware.wifi@1.2::IWifi + +$(GEN): $(LOCAL_PATH)/IWifi.hal + $(transform-generated-source) +LOCAL_GENERATED_SOURCES += $(GEN) + +# +# Build IWifiChip.hal +# +GEN := $(intermediates)/android/hardware/wifi/V1_2/IWifiChip.java +$(GEN): $(HIDL) +$(GEN): PRIVATE_HIDL := $(HIDL) +$(GEN): PRIVATE_DEPS := $(LOCAL_PATH)/IWifiChip.hal +$(GEN): PRIVATE_OUTPUT_DIR := $(intermediates) +$(GEN): PRIVATE_CUSTOM_TOOL = \ + $(PRIVATE_HIDL) -o $(PRIVATE_OUTPUT_DIR) \ + -Ljava \ + -randroid.hardware:hardware/interfaces \ + -randroid.hidl:system/libhidl/transport \ + android.hardware.wifi@1.2::IWifiChip + +$(GEN): $(LOCAL_PATH)/IWifiChip.hal + $(transform-generated-source) +LOCAL_GENERATED_SOURCES += $(GEN) +include $(BUILD_JAVA_LIBRARY) + + + +include $(call all-makefiles-under,$(LOCAL_PATH)) diff --git a/wifi/1.2/IWifi.hal b/wifi/1.2/IWifi.hal new file mode 100644 index 0000000000..7f47027510 --- /dev/null +++ b/wifi/1.2/IWifi.hal @@ -0,0 +1,29 @@ +/* + * Copyright 2017 The Android Open Source Project + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package android.hardware.wifi@1.2; + +import @1.1::IWifi; + +/** + * This is the root of the HAL module and is the interface returned when + * loading an implementation of the Wi-Fi HAL. There must be at most one + * module loaded in the system. + * IWifi.getChip() may return either a @1.0::IWifiChip or @1.1::IWifiChip + * or @1.2:IWifiChip + */ +interface IWifi extends @1.1::IWifi { +}; diff --git a/wifi/1.2/IWifiChip.hal b/wifi/1.2/IWifiChip.hal new file mode 100644 index 0000000000..72cbf811ab --- /dev/null +++ b/wifi/1.2/IWifiChip.hal @@ -0,0 +1,27 @@ +/* + * Copyright 2017 The Android Open Source Project + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package android.hardware.wifi@1.2; + +import @1.1::IWifiChip; + +/** + * Interface that represents a chip that must be configured as a single unit. + * The HAL/driver/firmware will be responsible for determining which phy is used + * to perform operations like NAN, RTT, etc. + */ +interface IWifiChip extends @1.1::IWifiChip { +}; diff --git a/wifi/1.1/default/Android.mk b/wifi/1.2/default/Android.mk similarity index 98% rename from wifi/1.1/default/Android.mk rename to wifi/1.2/default/Android.mk index 5758422303..6ce5e8969b 100644 --- a/wifi/1.1/default/Android.mk +++ b/wifi/1.2/default/Android.mk @@ -39,6 +39,7 @@ LOCAL_SRC_FILES := \ LOCAL_SHARED_LIBRARIES := \ android.hardware.wifi@1.0 \ android.hardware.wifi@1.1 \ + android.hardware.wifi@1.2 \ libbase \ libcutils \ libhidlbase \ diff --git a/wifi/1.1/default/OWNERS b/wifi/1.2/default/OWNERS similarity index 100% rename from wifi/1.1/default/OWNERS rename to wifi/1.2/default/OWNERS diff --git a/wifi/1.1/default/THREADING.README b/wifi/1.2/default/THREADING.README similarity index 100% rename from wifi/1.1/default/THREADING.README rename to wifi/1.2/default/THREADING.README diff --git a/wifi/1.1/default/android.hardware.wifi@1.0-service.rc b/wifi/1.2/default/android.hardware.wifi@1.0-service.rc similarity index 100% rename from wifi/1.1/default/android.hardware.wifi@1.0-service.rc rename to wifi/1.2/default/android.hardware.wifi@1.0-service.rc diff --git a/wifi/1.1/default/hidl_callback_util.h b/wifi/1.2/default/hidl_callback_util.h similarity index 98% rename from wifi/1.1/default/hidl_callback_util.h rename to wifi/1.2/default/hidl_callback_util.h index fb13622253..65fe80b8fa 100644 --- a/wifi/1.1/default/hidl_callback_util.h +++ b/wifi/1.2/default/hidl_callback_util.h @@ -51,7 +51,7 @@ class HidlDeathHandler : public android::hardware::hidl_death_recipient { namespace android { namespace hardware { namespace wifi { -namespace V1_1 { +namespace V1_2 { namespace implementation { namespace hidl_callback_util { template @@ -114,7 +114,7 @@ class HidlCallbackHandler { } // namespace hidl_callback_util } // namespace implementation -} // namespace V1_1 +} // namespace V1_2 } // namespace wifi } // namespace hardware } // namespace android diff --git a/wifi/1.1/default/hidl_return_util.h b/wifi/1.2/default/hidl_return_util.h similarity index 99% rename from wifi/1.1/default/hidl_return_util.h rename to wifi/1.2/default/hidl_return_util.h index f36c8bda8a..6fe382c06f 100644 --- a/wifi/1.1/default/hidl_return_util.h +++ b/wifi/1.2/default/hidl_return_util.h @@ -23,7 +23,7 @@ namespace android { namespace hardware { namespace wifi { -namespace V1_1 { +namespace V1_2 { namespace implementation { namespace hidl_return_util { using namespace android::hardware::wifi::V1_0; @@ -126,7 +126,7 @@ Return validateAndCall( } // namespace hidl_util } // namespace implementation -} // namespace V1_1 +} // namespace V1_2 } // namespace wifi } // namespace hardware } // namespace android diff --git a/wifi/1.1/default/hidl_struct_util.cpp b/wifi/1.2/default/hidl_struct_util.cpp similarity index 99% rename from wifi/1.1/default/hidl_struct_util.cpp rename to wifi/1.2/default/hidl_struct_util.cpp index c53cdc596d..1ad838be9d 100644 --- a/wifi/1.1/default/hidl_struct_util.cpp +++ b/wifi/1.2/default/hidl_struct_util.cpp @@ -22,7 +22,7 @@ namespace android { namespace hardware { namespace wifi { -namespace V1_1 { +namespace V1_2 { namespace implementation { namespace hidl_struct_util { @@ -2209,7 +2209,7 @@ bool convertLegacyVectorOfRttResultToHidl( } } // namespace hidl_struct_util } // namespace implementation -} // namespace V1_1 +} // namespace V1_2 } // namespace wifi } // namespace hardware } // namespace android diff --git a/wifi/1.1/default/hidl_struct_util.h b/wifi/1.2/default/hidl_struct_util.h similarity index 99% rename from wifi/1.1/default/hidl_struct_util.h rename to wifi/1.2/default/hidl_struct_util.h index 747fd2f4ab..ee5cbe0811 100644 --- a/wifi/1.1/default/hidl_struct_util.h +++ b/wifi/1.2/default/hidl_struct_util.h @@ -34,7 +34,7 @@ namespace android { namespace hardware { namespace wifi { -namespace V1_1 { +namespace V1_2 { namespace implementation { namespace hidl_struct_util { using namespace android::hardware::wifi::V1_0; @@ -168,7 +168,7 @@ bool convertLegacyVectorOfRttResultToHidl( std::vector* hidl_results); } // namespace hidl_struct_util } // namespace implementation -} // namespace V1_1 +} // namespace V1_2 } // namespace wifi } // namespace hardware } // namespace android diff --git a/wifi/1.1/default/hidl_sync_util.cpp b/wifi/1.2/default/hidl_sync_util.cpp similarity index 96% rename from wifi/1.1/default/hidl_sync_util.cpp rename to wifi/1.2/default/hidl_sync_util.cpp index ba18e344aa..0ee47b4309 100644 --- a/wifi/1.1/default/hidl_sync_util.cpp +++ b/wifi/1.2/default/hidl_sync_util.cpp @@ -23,7 +23,7 @@ std::recursive_mutex g_mutex; namespace android { namespace hardware { namespace wifi { -namespace V1_1 { +namespace V1_2 { namespace implementation { namespace hidl_sync_util { @@ -33,7 +33,7 @@ std::unique_lock acquireGlobalLock() { } // namespace hidl_sync_util } // namespace implementation -} // namespace V1_1 +} // namespace V1_2 } // namespace wifi } // namespace hardware } // namespace android diff --git a/wifi/1.1/default/hidl_sync_util.h b/wifi/1.2/default/hidl_sync_util.h similarity index 96% rename from wifi/1.1/default/hidl_sync_util.h rename to wifi/1.2/default/hidl_sync_util.h index 0e882df50b..8381862785 100644 --- a/wifi/1.1/default/hidl_sync_util.h +++ b/wifi/1.2/default/hidl_sync_util.h @@ -24,13 +24,13 @@ namespace android { namespace hardware { namespace wifi { -namespace V1_1 { +namespace V1_2 { namespace implementation { namespace hidl_sync_util { std::unique_lock acquireGlobalLock(); } // namespace hidl_sync_util } // namespace implementation -} // namespace V1_1 +} // namespace V1_2 } // namespace wifi } // namespace hardware } // namespace android diff --git a/wifi/1.1/default/service.cpp b/wifi/1.2/default/service.cpp similarity index 91% rename from wifi/1.1/default/service.cpp rename to wifi/1.2/default/service.cpp index b4aed6c199..2a6c3247b2 100644 --- a/wifi/1.1/default/service.cpp +++ b/wifi/1.2/default/service.cpp @@ -32,8 +32,8 @@ int main(int /*argc*/, char** argv) { configureRpcThreadpool(1, true /* callerWillJoin */); // Setup hwbinder service - android::sp service = - new android::hardware::wifi::V1_1::implementation::Wifi(); + android::sp service = + new android::hardware::wifi::V1_2::implementation::Wifi(); CHECK_EQ(service->registerAsService(), android::NO_ERROR) << "Failed to register wifi HAL"; diff --git a/wifi/1.1/default/wifi.cpp b/wifi/1.2/default/wifi.cpp similarity index 99% rename from wifi/1.1/default/wifi.cpp rename to wifi/1.2/default/wifi.cpp index c46ef950e9..67fcb651be 100644 --- a/wifi/1.1/default/wifi.cpp +++ b/wifi/1.2/default/wifi.cpp @@ -28,7 +28,7 @@ static constexpr android::hardware::wifi::V1_0::ChipId kChipId = 0; namespace android { namespace hardware { namespace wifi { -namespace V1_1 { +namespace V1_2 { namespace implementation { using hidl_return_util::validateAndCall; using hidl_return_util::validateAndCallWithLock; @@ -199,7 +199,7 @@ WifiStatus Wifi::stopLegacyHalAndDeinitializeModeController( return createWifiStatus(WifiStatusCode::SUCCESS); } } // namespace implementation -} // namespace V1_1 +} // namespace V1_2 } // namespace wifi } // namespace hardware } // namespace android diff --git a/wifi/1.1/default/wifi.h b/wifi/1.2/default/wifi.h similarity index 94% rename from wifi/1.1/default/wifi.h rename to wifi/1.2/default/wifi.h index 3a64cbd490..95ae58f0b1 100644 --- a/wifi/1.1/default/wifi.h +++ b/wifi/1.2/default/wifi.h @@ -20,7 +20,7 @@ #include #include -#include +#include #include #include "hidl_callback_util.h" @@ -31,14 +31,13 @@ namespace android { namespace hardware { namespace wifi { -namespace V1_1 { +namespace V1_2 { namespace implementation { -using namespace android::hardware::wifi::V1_0; /** * Root HIDL interface object used to control the Wifi HAL. */ -class Wifi : public V1_1::IWifi { +class Wifi : public V1_2::IWifi { public: Wifi(); @@ -81,7 +80,7 @@ class Wifi : public V1_1::IWifi { }; } // namespace implementation -} // namespace V1_1 +} // namespace V1_2 } // namespace wifi } // namespace hardware } // namespace android diff --git a/wifi/1.1/default/wifi_ap_iface.cpp b/wifi/1.2/default/wifi_ap_iface.cpp similarity index 98% rename from wifi/1.1/default/wifi_ap_iface.cpp rename to wifi/1.2/default/wifi_ap_iface.cpp index 150a6cc06f..347ffc6db6 100644 --- a/wifi/1.1/default/wifi_ap_iface.cpp +++ b/wifi/1.2/default/wifi_ap_iface.cpp @@ -24,7 +24,7 @@ namespace android { namespace hardware { namespace wifi { -namespace V1_1 { +namespace V1_2 { namespace implementation { using hidl_return_util::validateAndCall; @@ -100,7 +100,7 @@ WifiApIface::getValidFrequenciesForBandInternal(WifiBand band) { return {createWifiStatusFromLegacyError(legacy_status), valid_frequencies}; } } // namespace implementation -} // namespace V1_1 +} // namespace V1_2 } // namespace wifi } // namespace hardware } // namespace android diff --git a/wifi/1.1/default/wifi_ap_iface.h b/wifi/1.2/default/wifi_ap_iface.h similarity index 98% rename from wifi/1.1/default/wifi_ap_iface.h rename to wifi/1.2/default/wifi_ap_iface.h index 608fe6b5ac..b46425be72 100644 --- a/wifi/1.1/default/wifi_ap_iface.h +++ b/wifi/1.2/default/wifi_ap_iface.h @@ -25,7 +25,7 @@ namespace android { namespace hardware { namespace wifi { -namespace V1_1 { +namespace V1_2 { namespace implementation { using namespace android::hardware::wifi::V1_0; @@ -64,7 +64,7 @@ class WifiApIface : public V1_0::IWifiApIface { }; } // namespace implementation -} // namespace V1_1 +} // namespace V1_2 } // namespace wifi } // namespace hardware } // namespace android diff --git a/wifi/1.1/default/wifi_chip.cpp b/wifi/1.2/default/wifi_chip.cpp similarity index 99% rename from wifi/1.1/default/wifi_chip.cpp rename to wifi/1.2/default/wifi_chip.cpp index 2f4023405f..63d17a29ef 100644 --- a/wifi/1.1/default/wifi_chip.cpp +++ b/wifi/1.2/default/wifi_chip.cpp @@ -46,7 +46,7 @@ void invalidateAndClear(sp& iface) { namespace android { namespace hardware { namespace wifi { -namespace V1_1 { +namespace V1_2 { namespace implementation { using hidl_return_util::validateAndCall; @@ -903,7 +903,7 @@ WifiStatus WifiChip::registerDebugRingBufferCallback() { } } // namespace implementation -} // namespace V1_1 +} // namespace V1_2 } // namespace wifi } // namespace hardware } // namespace android diff --git a/wifi/1.1/default/wifi_chip.h b/wifi/1.2/default/wifi_chip.h similarity index 99% rename from wifi/1.1/default/wifi_chip.h rename to wifi/1.2/default/wifi_chip.h index e88100bd23..2b9ca64ed0 100644 --- a/wifi/1.1/default/wifi_chip.h +++ b/wifi/1.2/default/wifi_chip.h @@ -34,7 +34,7 @@ namespace android { namespace hardware { namespace wifi { -namespace V1_1 { +namespace V1_2 { namespace implementation { using namespace android::hardware::wifi::V1_0; @@ -209,7 +209,7 @@ class WifiChip : public V1_1::IWifiChip { }; } // namespace implementation -} // namespace V1_1 +} // namespace V1_2 } // namespace wifi } // namespace hardware } // namespace android diff --git a/wifi/1.1/default/wifi_feature_flags.h b/wifi/1.2/default/wifi_feature_flags.h similarity index 96% rename from wifi/1.1/default/wifi_feature_flags.h rename to wifi/1.2/default/wifi_feature_flags.h index 5939ffbefb..c692cd9330 100644 --- a/wifi/1.1/default/wifi_feature_flags.h +++ b/wifi/1.2/default/wifi_feature_flags.h @@ -20,7 +20,7 @@ namespace android { namespace hardware { namespace wifi { -namespace V1_1 { +namespace V1_2 { namespace implementation { class WifiFeatureFlags { @@ -33,7 +33,7 @@ class WifiFeatureFlags { }; } // namespace implementation -} // namespace V1_1 +} // namespace V1_2 } // namespace wifi } // namespace hardware } // namespace android diff --git a/wifi/1.1/default/wifi_legacy_hal.cpp b/wifi/1.2/default/wifi_legacy_hal.cpp similarity index 99% rename from wifi/1.1/default/wifi_legacy_hal.cpp rename to wifi/1.2/default/wifi_legacy_hal.cpp index a6f6971f38..9176fde9f7 100644 --- a/wifi/1.1/default/wifi_legacy_hal.cpp +++ b/wifi/1.2/default/wifi_legacy_hal.cpp @@ -49,7 +49,7 @@ std::vector makeCharVec(const std::string& str) { namespace android { namespace hardware { namespace wifi { -namespace V1_1 { +namespace V1_2 { namespace implementation { namespace legacy_hal { // Legacy HAL functions accept "C" style function pointers, so use global @@ -1339,7 +1339,7 @@ void WifiLegacyHal::invalidate() { } // namespace legacy_hal } // namespace implementation -} // namespace V1_1 +} // namespace V1_2 } // namespace wifi } // namespace hardware } // namespace android diff --git a/wifi/1.1/default/wifi_legacy_hal.h b/wifi/1.2/default/wifi_legacy_hal.h similarity index 99% rename from wifi/1.1/default/wifi_legacy_hal.h rename to wifi/1.2/default/wifi_legacy_hal.h index 549880398f..d7be1eeb32 100644 --- a/wifi/1.1/default/wifi_legacy_hal.h +++ b/wifi/1.2/default/wifi_legacy_hal.h @@ -27,7 +27,7 @@ namespace android { namespace hardware { namespace wifi { -namespace V1_1 { +namespace V1_2 { namespace implementation { // This is in a separate namespace to prevent typename conflicts between // the legacy HAL types and the HIDL interface types. @@ -304,7 +304,7 @@ class WifiLegacyHal { } // namespace legacy_hal } // namespace implementation -} // namespace V1_1 +} // namespace V1_2 } // namespace wifi } // namespace hardware } // namespace android diff --git a/wifi/1.1/default/wifi_legacy_hal_stubs.cpp b/wifi/1.2/default/wifi_legacy_hal_stubs.cpp similarity index 99% rename from wifi/1.1/default/wifi_legacy_hal_stubs.cpp rename to wifi/1.2/default/wifi_legacy_hal_stubs.cpp index c02e3ba292..48fce6dcc0 100644 --- a/wifi/1.1/default/wifi_legacy_hal_stubs.cpp +++ b/wifi/1.2/default/wifi_legacy_hal_stubs.cpp @@ -20,7 +20,7 @@ namespace android { namespace hardware { namespace wifi { -namespace V1_1 { +namespace V1_2 { namespace implementation { namespace legacy_hal { template @@ -138,7 +138,7 @@ bool initHalFuncTableWithStubs(wifi_hal_fn* hal_fn) { } } // namespace legacy_hal } // namespace implementation -} // namespace V1_1 +} // namespace V1_2 } // namespace wifi } // namespace hardware } // namespace android diff --git a/wifi/1.1/default/wifi_legacy_hal_stubs.h b/wifi/1.2/default/wifi_legacy_hal_stubs.h similarity index 96% rename from wifi/1.1/default/wifi_legacy_hal_stubs.h rename to wifi/1.2/default/wifi_legacy_hal_stubs.h index bfc4c9b864..d560dd4e80 100644 --- a/wifi/1.1/default/wifi_legacy_hal_stubs.h +++ b/wifi/1.2/default/wifi_legacy_hal_stubs.h @@ -20,7 +20,7 @@ namespace android { namespace hardware { namespace wifi { -namespace V1_1 { +namespace V1_2 { namespace implementation { namespace legacy_hal { #include @@ -28,7 +28,7 @@ namespace legacy_hal { bool initHalFuncTableWithStubs(wifi_hal_fn* hal_fn); } // namespace legacy_hal } // namespace implementation -} // namespace V1_1 +} // namespace V1_2 } // namespace wifi } // namespace hardware } // namespace android diff --git a/wifi/1.1/default/wifi_mode_controller.cpp b/wifi/1.2/default/wifi_mode_controller.cpp similarity index 98% rename from wifi/1.1/default/wifi_mode_controller.cpp rename to wifi/1.2/default/wifi_mode_controller.cpp index b8a44c2531..6d184ca5fc 100644 --- a/wifi/1.1/default/wifi_mode_controller.cpp +++ b/wifi/1.2/default/wifi_mode_controller.cpp @@ -48,7 +48,7 @@ int convertIfaceTypeToFirmwareMode(IfaceType type) { namespace android { namespace hardware { namespace wifi { -namespace V1_1 { +namespace V1_2 { namespace implementation { namespace mode_controller { @@ -80,7 +80,7 @@ bool WifiModeController::deinitialize() { } } // namespace mode_controller } // namespace implementation -} // namespace V1_1 +} // namespace V1_2 } // namespace wifi } // namespace hardware } // namespace android diff --git a/wifi/1.1/default/wifi_mode_controller.h b/wifi/1.2/default/wifi_mode_controller.h similarity index 97% rename from wifi/1.1/default/wifi_mode_controller.h rename to wifi/1.2/default/wifi_mode_controller.h index 69845095bc..5619f6771e 100644 --- a/wifi/1.1/default/wifi_mode_controller.h +++ b/wifi/1.2/default/wifi_mode_controller.h @@ -24,7 +24,7 @@ namespace android { namespace hardware { namespace wifi { -namespace V1_1 { +namespace V1_2 { namespace implementation { namespace mode_controller { using namespace android::hardware::wifi::V1_0; @@ -53,7 +53,7 @@ class WifiModeController { } // namespace mode_controller } // namespace implementation -} // namespace V1_1 +} // namespace V1_2 } // namespace wifi } // namespace hardware } // namespace android diff --git a/wifi/1.1/default/wifi_nan_iface.cpp b/wifi/1.2/default/wifi_nan_iface.cpp similarity index 99% rename from wifi/1.1/default/wifi_nan_iface.cpp rename to wifi/1.2/default/wifi_nan_iface.cpp index a111d0610a..93b8902418 100644 --- a/wifi/1.1/default/wifi_nan_iface.cpp +++ b/wifi/1.2/default/wifi_nan_iface.cpp @@ -24,7 +24,7 @@ namespace android { namespace hardware { namespace wifi { -namespace V1_1 { +namespace V1_2 { namespace implementation { using hidl_return_util::validateAndCall; @@ -763,7 +763,7 @@ WifiStatus WifiNanIface::terminateDataPathRequestInternal( } } // namespace implementation -} // namespace V1_1 +} // namespace V1_2 } // namespace wifi } // namespace hardware } // namespace android diff --git a/wifi/1.1/default/wifi_nan_iface.h b/wifi/1.2/default/wifi_nan_iface.h similarity index 99% rename from wifi/1.1/default/wifi_nan_iface.h rename to wifi/1.2/default/wifi_nan_iface.h index 260d8ab4ef..34552eacaf 100644 --- a/wifi/1.1/default/wifi_nan_iface.h +++ b/wifi/1.2/default/wifi_nan_iface.h @@ -27,7 +27,7 @@ namespace android { namespace hardware { namespace wifi { -namespace V1_1 { +namespace V1_2 { namespace implementation { using namespace android::hardware::wifi::V1_0; @@ -133,7 +133,7 @@ class WifiNanIface : public V1_0::IWifiNanIface { }; } // namespace implementation -} // namespace V1_1 +} // namespace V1_2 } // namespace wifi } // namespace hardware } // namespace android diff --git a/wifi/1.1/default/wifi_p2p_iface.cpp b/wifi/1.2/default/wifi_p2p_iface.cpp similarity index 98% rename from wifi/1.1/default/wifi_p2p_iface.cpp rename to wifi/1.2/default/wifi_p2p_iface.cpp index 78e08db970..41c8d0a978 100644 --- a/wifi/1.1/default/wifi_p2p_iface.cpp +++ b/wifi/1.2/default/wifi_p2p_iface.cpp @@ -23,7 +23,7 @@ namespace android { namespace hardware { namespace wifi { -namespace V1_1 { +namespace V1_2 { namespace implementation { using hidl_return_util::validateAndCall; @@ -64,7 +64,7 @@ std::pair WifiP2pIface::getTypeInternal() { } } // namespace implementation -} // namespace V1_1 +} // namespace V1_2 } // namespace wifi } // namespace hardware } // namespace android diff --git a/wifi/1.1/default/wifi_p2p_iface.h b/wifi/1.2/default/wifi_p2p_iface.h similarity index 97% rename from wifi/1.1/default/wifi_p2p_iface.h rename to wifi/1.2/default/wifi_p2p_iface.h index f563a3d314..6b851888ad 100644 --- a/wifi/1.1/default/wifi_p2p_iface.h +++ b/wifi/1.2/default/wifi_p2p_iface.h @@ -25,7 +25,7 @@ namespace android { namespace hardware { namespace wifi { -namespace V1_1 { +namespace V1_2 { namespace implementation { using namespace android::hardware::wifi::V1_0; @@ -57,7 +57,7 @@ class WifiP2pIface : public V1_0::IWifiP2pIface { }; } // namespace implementation -} // namespace V1_1 +} // namespace V1_2 } // namespace wifi } // namespace hardware } // namespace android diff --git a/wifi/1.1/default/wifi_rtt_controller.cpp b/wifi/1.2/default/wifi_rtt_controller.cpp similarity index 99% rename from wifi/1.1/default/wifi_rtt_controller.cpp rename to wifi/1.2/default/wifi_rtt_controller.cpp index 9ef702da14..2fab06c99c 100644 --- a/wifi/1.1/default/wifi_rtt_controller.cpp +++ b/wifi/1.2/default/wifi_rtt_controller.cpp @@ -24,7 +24,7 @@ namespace android { namespace hardware { namespace wifi { -namespace V1_1 { +namespace V1_2 { namespace implementation { using hidl_return_util::validateAndCall; @@ -291,7 +291,7 @@ WifiStatus WifiRttController::disableResponderInternal(uint32_t cmd_id) { return createWifiStatusFromLegacyError(legacy_status); } } // namespace implementation -} // namespace V1_1 +} // namespace V1_2 } // namespace wifi } // namespace hardware } // namespace android diff --git a/wifi/1.1/default/wifi_rtt_controller.h b/wifi/1.2/default/wifi_rtt_controller.h similarity index 99% rename from wifi/1.1/default/wifi_rtt_controller.h rename to wifi/1.2/default/wifi_rtt_controller.h index 543788574a..f1a55da9d8 100644 --- a/wifi/1.1/default/wifi_rtt_controller.h +++ b/wifi/1.2/default/wifi_rtt_controller.h @@ -27,7 +27,7 @@ namespace android { namespace hardware { namespace wifi { -namespace V1_1 { +namespace V1_2 { namespace implementation { /** @@ -97,7 +97,7 @@ class WifiRttController : public V1_0::IWifiRttController { }; } // namespace implementation -} // namespace V1_1 +} // namespace V1_2 } // namespace wifi } // namespace hardware } // namespace android diff --git a/wifi/1.1/default/wifi_sta_iface.cpp b/wifi/1.2/default/wifi_sta_iface.cpp similarity index 99% rename from wifi/1.1/default/wifi_sta_iface.cpp rename to wifi/1.2/default/wifi_sta_iface.cpp index 28f3f02a2a..36228057e4 100644 --- a/wifi/1.1/default/wifi_sta_iface.cpp +++ b/wifi/1.2/default/wifi_sta_iface.cpp @@ -24,7 +24,7 @@ namespace android { namespace hardware { namespace wifi { -namespace V1_1 { +namespace V1_2 { namespace implementation { using hidl_return_util::validateAndCall; @@ -623,7 +623,7 @@ WifiStaIface::getDebugRxPacketFatesInternal() { } } // namespace implementation -} // namespace V1_1 +} // namespace V1_2 } // namespace wifi } // namespace hardware } // namespace android diff --git a/wifi/1.1/default/wifi_sta_iface.h b/wifi/1.2/default/wifi_sta_iface.h similarity index 99% rename from wifi/1.1/default/wifi_sta_iface.h rename to wifi/1.2/default/wifi_sta_iface.h index 587a5de7ba..a8d11a7cfa 100644 --- a/wifi/1.1/default/wifi_sta_iface.h +++ b/wifi/1.2/default/wifi_sta_iface.h @@ -27,7 +27,7 @@ namespace android { namespace hardware { namespace wifi { -namespace V1_1 { +namespace V1_2 { namespace implementation { using namespace android::hardware::wifi::V1_0; @@ -160,7 +160,7 @@ class WifiStaIface : public V1_0::IWifiStaIface { }; } // namespace implementation -} // namespace V1_1 +} // namespace V1_2 } // namespace wifi } // namespace hardware } // namespace android diff --git a/wifi/1.1/default/wifi_status_util.cpp b/wifi/1.2/default/wifi_status_util.cpp similarity index 98% rename from wifi/1.1/default/wifi_status_util.cpp rename to wifi/1.2/default/wifi_status_util.cpp index 3a85e09989..992eb10c89 100644 --- a/wifi/1.1/default/wifi_status_util.cpp +++ b/wifi/1.2/default/wifi_status_util.cpp @@ -19,7 +19,7 @@ namespace android { namespace hardware { namespace wifi { -namespace V1_1 { +namespace V1_2 { namespace implementation { std::string legacyErrorToString(legacy_hal::wifi_error error) { @@ -100,7 +100,7 @@ WifiStatus createWifiStatusFromLegacyError(legacy_hal::wifi_error error) { } } // namespace implementation -} // namespace V1_1 +} // namespace V1_2 } // namespace wifi } // namespace hardware } // namespace android diff --git a/wifi/1.1/default/wifi_status_util.h b/wifi/1.2/default/wifi_status_util.h similarity index 97% rename from wifi/1.1/default/wifi_status_util.h rename to wifi/1.2/default/wifi_status_util.h index cc93d66ca0..e9136b38ca 100644 --- a/wifi/1.1/default/wifi_status_util.h +++ b/wifi/1.2/default/wifi_status_util.h @@ -24,7 +24,7 @@ namespace android { namespace hardware { namespace wifi { -namespace V1_1 { +namespace V1_2 { namespace implementation { using namespace android::hardware::wifi::V1_0; @@ -37,7 +37,7 @@ WifiStatus createWifiStatusFromLegacyError(legacy_hal::wifi_error error, WifiStatus createWifiStatusFromLegacyError(legacy_hal::wifi_error error); } // namespace implementation -} // namespace V1_1 +} // namespace V1_2 } // namespace wifi } // namespace hardware } // namespace android diff --git a/wifi/Android.bp b/wifi/Android.bp index 1153b0c628..14521ee2e8 100644 --- a/wifi/Android.bp +++ b/wifi/Android.bp @@ -4,6 +4,7 @@ subdirs = [ "1.0/vts/functional", "1.1", "1.1/vts/functional", + "1.2", "offload/1.0", "offload/1.0/vts/functional", "supplicant/1.0",