Update setAfcChannelAllowance
Use a new structure to passdown:
- AFC information queried based on frequency
- AFC information queried based on channel number
- expiration time
This change is per chip vendor request. Based on AFC server support,
either frequency based information or channel based information may be
empty. If both are empty, then it indicate the driver should not allow
any standard power transmission on 6Ghz.
Bug: 262791660
Test: compile
Test: Manually verified information is passed down with local framework
change
Change-Id: Id1d014a6113f6863b98ef8239a5a52d3863aa758
diff --git a/wifi/aidl/default/wifi_chip.cpp b/wifi/aidl/default/wifi_chip.cpp
index dd24e6b..e4c2d44 100644
--- a/wifi/aidl/default/wifi_chip.cpp
+++ b/wifi/aidl/default/wifi_chip.cpp
@@ -701,9 +701,9 @@
}
ndk::ScopedAStatus WifiChip::setAfcChannelAllowance(
- const std::vector<AvailableAfcFrequencyInfo>& availableAfcFrequencyInfo) {
+ const AfcChannelAllowance& afcChannelAllowance) {
return validateAndCall(this, WifiStatusCode::ERROR_WIFI_CHIP_INVALID,
- &WifiChip::setAfcChannelAllowanceInternal, availableAfcFrequencyInfo);
+ &WifiChip::setAfcChannelAllowanceInternal, afcChannelAllowance);
}
ndk::ScopedAStatus WifiChip::triggerSubsystemRestart() {
@@ -1431,8 +1431,12 @@
}
ndk::ScopedAStatus WifiChip::setAfcChannelAllowanceInternal(
- const std::vector<AvailableAfcFrequencyInfo>& availableAfcFrequencyInfo) {
- LOG(INFO) << "setAfcChannelAllowance is not yet supported " << availableAfcFrequencyInfo.size();
+ const AfcChannelAllowance& afcChannelAllowance) {
+ LOG(INFO) << "setAfcChannelAllowance is not yet supported. availableAfcFrequencyInfos size="
+ << afcChannelAllowance.availableAfcFrequencyInfos.size()
+ << " availableAfcChannelInfos size="
+ << afcChannelAllowance.availableAfcChannelInfos.size()
+ << " availabilityExpireTimeMs=" << afcChannelAllowance.availabilityExpireTimeMs;
return createWifiStatus(WifiStatusCode::ERROR_NOT_SUPPORTED);
}