Jimmy Chen | 2abc352 | 2020-09-11 17:46:34 +0800 | [diff] [blame] | 1 | /* |
| 2 | * Copyright 2020 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 | package android.hardware.wifi.supplicant@1.4; |
| 18 | |
| 19 | import @1.2::ISupplicantP2pIface; |
Jimmy Chen | e162c6c | 2021-03-04 13:56:33 +0800 | [diff] [blame] | 20 | import ISupplicantP2pIfaceCallback; |
Jimmy Chen | 2abc352 | 2020-09-11 17:46:34 +0800 | [diff] [blame] | 21 | |
| 22 | /** |
| 23 | * Interface exposed by the supplicant for each P2P mode network |
| 24 | * interface (e.g p2p0) it controls. |
| 25 | * To use 1.4 features you must cast specific interfaces returned from the |
| 26 | * 1.4 HAL. For example V1_4::ISupplicant::addIface() adds V1_4::ISupplicantIface, |
| 27 | * which can be cast to V1_4::ISupplicantP2pIface. |
| 28 | */ |
| 29 | interface ISupplicantP2pIface extends @1.2::ISupplicantP2pIface { |
| 30 | /** |
| 31 | * Set whether to enable EDMG(802.11ay). Only allowed if hw mode is |HOSTAPD_MODE_IEEE80211AD| |
| 32 | * |
| 33 | * @param enable true to set, false otherwise. |
| 34 | * @return status Status of the operation. |
| 35 | * Possible status codes: |
| 36 | * |SupplicantStatusCode.SUCCESS|, |
| 37 | * |SupplicantStatusCode.FAILURE_UNKNOWN|, |
| 38 | * |SupplicantStatusCode.FAILURE_NETWORK_INVALID| |
| 39 | */ |
| 40 | setEdmg(bool enable) generates (SupplicantStatus status); |
| 41 | |
| 42 | /** |
| 43 | * Get whether EDMG(802.11ay) is enabled for this network. |
| 44 | * |
| 45 | * @return status Status of the operation. |
| 46 | * Possible status codes: |
| 47 | * |SupplicantStatusCode.SUCCESS|, |
| 48 | * |SupplicantStatusCode.FAILURE_NETWORK_INVALID| |
| 49 | * @return enabled true if set, false otherwise. |
| 50 | */ |
| 51 | getEdmg() generates (SupplicantStatus status, bool enabled); |
Jimmy Chen | e162c6c | 2021-03-04 13:56:33 +0800 | [diff] [blame] | 52 | |
| 53 | /** |
| 54 | * Register for callbacks from this interface. |
| 55 | * |
| 56 | * These callbacks are invoked for events that are specific to this interface. |
| 57 | * Registration of multiple callback objects is supported. These objects must |
| 58 | * be automatically deleted when the corresponding client process is dead or |
| 59 | * if this interface is removed. |
| 60 | * |
| 61 | * @param callback An instance of the |ISupplicantP2pIfaceCallback| HIDL |
| 62 | * interface object. |
| 63 | * @return status Status of the operation. |
| 64 | * Possible status codes: |
| 65 | * |SupplicantStatusCode.SUCCESS|, |
| 66 | * |SupplicantStatusCode.FAILURE_UNKNOWN|, |
| 67 | * |SupplicantStatusCode.FAILURE_IFACE_INVALID| |
| 68 | */ |
| 69 | registerCallback_1_4(ISupplicantP2pIfaceCallback callback) |
| 70 | generates (SupplicantStatus status); |
| 71 | |
| 72 | /* |
| 73 | * Set Wifi Display R2 device info. |
| 74 | * |
| 75 | * @param info WFD R2 device info as described in section 5.1.12 of WFD technical |
| 76 | * specification v2.1. |
| 77 | * @return status Status of the operation. |
| 78 | * Possible status codes: |
| 79 | * |SupplicantStatusCode.SUCCESS|, |
| 80 | * |SupplicantStatusCode.FAILURE_UNKNOWN|, |
| 81 | * |SupplicantStatusCode.FAILURE_IFACE_INVALID| |
| 82 | */ |
| 83 | setWfdR2DeviceInfo(uint8_t[4] info) generates (SupplicantStatus status); |
Jimmy Chen | 2abc352 | 2020-09-11 17:46:34 +0800 | [diff] [blame] | 84 | }; |