1 /*
2  * Copyright (C) 2022 The Android Open Source Project
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  *      http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16 
17 #ifndef WIFI_FEATURE_FLAGS_H_
18 #define WIFI_FEATURE_FLAGS_H_
19 
20 #include <aidl/android/hardware/wifi/IWifiChip.h>
21 
22 namespace aidl {
23 namespace android {
24 namespace hardware {
25 namespace wifi {
26 namespace feature_flags {
27 
28 namespace chip_mode_ids {
29 // These mode ID's should be unique (even across combo versions). Refer to
30 // handleChipConfiguration() for its usage.
31 constexpr uint32_t kInvalid = UINT32_MAX;
32 // Mode ID's for V1
33 constexpr uint32_t kV1Sta = 0;
34 constexpr uint32_t kV1Ap = 1;
35 // Mode ID for V3
36 constexpr uint32_t kV3 = 3;
37 }  // namespace chip_mode_ids
38 
39 class WifiFeatureFlags {
40   public:
41     WifiFeatureFlags();
42     virtual ~WifiFeatureFlags() = default;
43 
44     virtual std::vector<IWifiChip::ChipMode> getChipModes(bool is_primary);
45 
46   private:
47     std::vector<IWifiChip::ChipMode> getChipModesForPrimary();
48 };
49 
50 }  // namespace feature_flags
51 }  // namespace wifi
52 }  // namespace hardware
53 }  // namespace android
54 }  // namespace aidl
55 
56 #endif  // WIFI_FEATURE_FLAGS_H_
57