Roshan Pius | 3e2d671 | 2016-10-06 13:16:23 -0700 | [diff] [blame] | 1 | /* |
| 2 | * Copyright (C) 2016 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 | |
Roshan Pius | 3e2d671 | 2016-10-06 13:16:23 -0700 | [diff] [blame] | 17 | #include <android-base/logging.h> |
| 18 | |
Roshan Pius | 907d4a2 | 2016-10-27 12:48:12 -0700 | [diff] [blame] | 19 | #include "hidl_return_util.h" |
Roshan Pius | f5f51fd | 2016-12-01 13:54:24 -0800 | [diff] [blame] | 20 | #include "hidl_struct_util.h" |
Roshan Pius | 907d4a2 | 2016-10-27 12:48:12 -0700 | [diff] [blame] | 21 | #include "wifi_nan_iface.h" |
Roshan Pius | 734fea0 | 2016-10-11 08:30:28 -0700 | [diff] [blame] | 22 | #include "wifi_status_util.h" |
Roshan Pius | 3e2d671 | 2016-10-06 13:16:23 -0700 | [diff] [blame] | 23 | |
| 24 | namespace android { |
| 25 | namespace hardware { |
| 26 | namespace wifi { |
| 27 | namespace V1_0 { |
| 28 | namespace implementation { |
Roshan Pius | 907d4a2 | 2016-10-27 12:48:12 -0700 | [diff] [blame] | 29 | using hidl_return_util::validateAndCall; |
Roshan Pius | 3e2d671 | 2016-10-06 13:16:23 -0700 | [diff] [blame] | 30 | |
Roshan Pius | 6cedc97 | 2016-10-28 10:11:17 -0700 | [diff] [blame] | 31 | WifiNanIface::WifiNanIface( |
| 32 | const std::string& ifname, |
| 33 | const std::weak_ptr<legacy_hal::WifiLegacyHal> legacy_hal) |
Roshan Pius | f5f51fd | 2016-12-01 13:54:24 -0800 | [diff] [blame] | 34 | : ifname_(ifname), legacy_hal_(legacy_hal), is_valid_(true) { |
| 35 | // Register all the callbacks here. these should be valid for the lifetime |
| 36 | // of the object. Whenever the mode changes legacy HAL will remove |
| 37 | // all of these callbacks. |
| 38 | legacy_hal::NanCallbackHandlers callback_handlers; |
| 39 | |
| 40 | // Callback for response. |
| 41 | callback_handlers.on_notify_response = [&]( |
| 42 | legacy_hal::transaction_id id, const legacy_hal::NanResponseMsg& msg) { |
| 43 | NanResponseMsgHeader hidl_header; |
| 44 | if (!hidl_struct_util::convertLegacyNanResponseHeaderToHidl(msg, |
| 45 | &hidl_header)) { |
| 46 | LOG(ERROR) << "Failed to convert nan response header"; |
| 47 | return; |
| 48 | } |
| 49 | // TODO: This is a union in the legacy HAL. Need to convert to appropriate |
| 50 | // callback based on type. |
| 51 | // Assuming |NanPublishResponseMsg| type here. |
| 52 | NanPublishResponse hidl_body; |
| 53 | if (!hidl_struct_util::convertLegacyNanPublishResponseToHidl( |
| 54 | msg.body.publish_response, &hidl_body)) { |
| 55 | LOG(ERROR) << "Failed to convert nan publish response"; |
| 56 | return; |
| 57 | } |
| 58 | NanPublishResponseMsg hidl_msg; |
| 59 | hidl_msg.header = hidl_header; |
| 60 | hidl_msg.body = hidl_body; |
| 61 | for (const auto& callback : event_callbacks_) { |
Steven Moreland | b643842 | 2017-01-03 17:06:57 -0800 | [diff] [blame] | 62 | if (!callback->notifyPublishResponse(id, hidl_msg).isOk()) { |
Roshan Pius | f5f51fd | 2016-12-01 13:54:24 -0800 | [diff] [blame] | 63 | LOG(ERROR) << "Failed to invoke the callback"; |
| 64 | } |
| 65 | } |
| 66 | }; |
| 67 | // TODO: Register the remaining callbacks. |
| 68 | legacy_hal::wifi_error legacy_status = |
| 69 | legacy_hal_.lock()->nanRegisterCallbackHandlers(callback_handlers); |
| 70 | if (legacy_status != legacy_hal::WIFI_SUCCESS) { |
| 71 | LOG(ERROR) << "Failed to register nan callbacks. Invalidating object"; |
| 72 | invalidate(); |
| 73 | } |
| 74 | } |
Roshan Pius | 3e2d671 | 2016-10-06 13:16:23 -0700 | [diff] [blame] | 75 | |
| 76 | void WifiNanIface::invalidate() { |
| 77 | legacy_hal_.reset(); |
Roshan Pius | 0c92d44 | 2016-10-27 17:38:53 -0700 | [diff] [blame] | 78 | event_callbacks_.clear(); |
Roshan Pius | 3e2d671 | 2016-10-06 13:16:23 -0700 | [diff] [blame] | 79 | is_valid_ = false; |
| 80 | } |
| 81 | |
Roshan Pius | 907d4a2 | 2016-10-27 12:48:12 -0700 | [diff] [blame] | 82 | bool WifiNanIface::isValid() { |
| 83 | return is_valid_; |
| 84 | } |
| 85 | |
Roshan Pius | 734fea0 | 2016-10-11 08:30:28 -0700 | [diff] [blame] | 86 | Return<void> WifiNanIface::getName(getName_cb hidl_status_cb) { |
Roshan Pius | 907d4a2 | 2016-10-27 12:48:12 -0700 | [diff] [blame] | 87 | return validateAndCall(this, |
| 88 | WifiStatusCode::ERROR_WIFI_IFACE_INVALID, |
| 89 | &WifiNanIface::getNameInternal, |
| 90 | hidl_status_cb); |
Roshan Pius | 3e2d671 | 2016-10-06 13:16:23 -0700 | [diff] [blame] | 91 | } |
| 92 | |
Roshan Pius | 0c92d44 | 2016-10-27 17:38:53 -0700 | [diff] [blame] | 93 | Return<void> WifiNanIface::registerEventCallback( |
| 94 | const sp<IWifiNanIfaceEventCallback>& callback, |
| 95 | registerEventCallback_cb hidl_status_cb) { |
| 96 | return validateAndCall(this, |
| 97 | WifiStatusCode::ERROR_WIFI_IFACE_INVALID, |
| 98 | &WifiNanIface::registerEventCallbackInternal, |
| 99 | hidl_status_cb, |
| 100 | callback); |
| 101 | } |
| 102 | |
| 103 | Return<void> WifiNanIface::enableRequest(uint32_t cmd_id, |
| 104 | const NanEnableRequest& msg, |
| 105 | enableRequest_cb hidl_status_cb) { |
| 106 | return validateAndCall(this, |
| 107 | WifiStatusCode::ERROR_WIFI_IFACE_INVALID, |
| 108 | &WifiNanIface::enableRequestInternal, |
| 109 | hidl_status_cb, |
| 110 | cmd_id, |
| 111 | msg); |
| 112 | } |
| 113 | |
| 114 | Return<void> WifiNanIface::disableRequest(uint32_t cmd_id, |
| 115 | disableRequest_cb hidl_status_cb) { |
| 116 | return validateAndCall(this, |
| 117 | WifiStatusCode::ERROR_WIFI_IFACE_INVALID, |
| 118 | &WifiNanIface::disableRequestInternal, |
| 119 | hidl_status_cb, |
| 120 | cmd_id); |
| 121 | } |
| 122 | |
| 123 | Return<void> WifiNanIface::publishRequest(uint32_t cmd_id, |
| 124 | const NanPublishRequest& msg, |
| 125 | publishRequest_cb hidl_status_cb) { |
| 126 | return validateAndCall(this, |
| 127 | WifiStatusCode::ERROR_WIFI_IFACE_INVALID, |
| 128 | &WifiNanIface::publishRequestInternal, |
| 129 | hidl_status_cb, |
| 130 | cmd_id, |
| 131 | msg); |
| 132 | } |
| 133 | |
| 134 | Return<void> WifiNanIface::publishCancelRequest( |
| 135 | uint32_t cmd_id, |
| 136 | const NanPublishCancelRequest& msg, |
| 137 | publishCancelRequest_cb hidl_status_cb) { |
| 138 | return validateAndCall(this, |
| 139 | WifiStatusCode::ERROR_WIFI_IFACE_INVALID, |
| 140 | &WifiNanIface::publishCancelRequestInternal, |
| 141 | hidl_status_cb, |
| 142 | cmd_id, |
| 143 | msg); |
| 144 | } |
| 145 | |
| 146 | Return<void> WifiNanIface::subscribeRequest( |
| 147 | uint32_t cmd_id, |
| 148 | const NanSubscribeRequest& msg, |
| 149 | subscribeRequest_cb hidl_status_cb) { |
| 150 | return validateAndCall(this, |
| 151 | WifiStatusCode::ERROR_WIFI_IFACE_INVALID, |
| 152 | &WifiNanIface::subscribeRequestInternal, |
| 153 | hidl_status_cb, |
| 154 | cmd_id, |
| 155 | msg); |
| 156 | } |
| 157 | |
| 158 | Return<void> WifiNanIface::subscribeCancelRequest( |
| 159 | uint32_t cmd_id, |
| 160 | const NanSubscribeCancelRequest& msg, |
| 161 | subscribeCancelRequest_cb hidl_status_cb) { |
| 162 | return validateAndCall(this, |
| 163 | WifiStatusCode::ERROR_WIFI_IFACE_INVALID, |
| 164 | &WifiNanIface::subscribeCancelRequestInternal, |
| 165 | hidl_status_cb, |
| 166 | cmd_id, |
| 167 | msg); |
| 168 | } |
| 169 | |
| 170 | Return<void> WifiNanIface::transmitFollowupRequest( |
| 171 | uint32_t cmd_id, |
| 172 | const NanTransmitFollowupRequest& msg, |
| 173 | transmitFollowupRequest_cb hidl_status_cb) { |
| 174 | return validateAndCall(this, |
| 175 | WifiStatusCode::ERROR_WIFI_IFACE_INVALID, |
| 176 | &WifiNanIface::transmitFollowupRequestInternal, |
| 177 | hidl_status_cb, |
| 178 | cmd_id, |
| 179 | msg); |
| 180 | } |
| 181 | |
| 182 | Return<void> WifiNanIface::configRequest(uint32_t cmd_id, |
| 183 | const NanConfigRequest& msg, |
| 184 | configRequest_cb hidl_status_cb) { |
| 185 | return validateAndCall(this, |
| 186 | WifiStatusCode::ERROR_WIFI_IFACE_INVALID, |
| 187 | &WifiNanIface::configRequestInternal, |
| 188 | hidl_status_cb, |
| 189 | cmd_id, |
| 190 | msg); |
| 191 | } |
| 192 | |
| 193 | Return<void> WifiNanIface::beaconSdfPayloadRequest( |
| 194 | uint32_t cmd_id, |
| 195 | const NanBeaconSdfPayloadRequest& msg, |
| 196 | beaconSdfPayloadRequest_cb hidl_status_cb) { |
| 197 | return validateAndCall(this, |
| 198 | WifiStatusCode::ERROR_WIFI_IFACE_INVALID, |
| 199 | &WifiNanIface::beaconSdfPayloadRequestInternal, |
| 200 | hidl_status_cb, |
| 201 | cmd_id, |
| 202 | msg); |
| 203 | } |
| 204 | |
| 205 | Return<void> WifiNanIface::getVersion(getVersion_cb hidl_status_cb) { |
| 206 | return validateAndCall(this, |
| 207 | WifiStatusCode::ERROR_WIFI_IFACE_INVALID, |
| 208 | &WifiNanIface::getVersionInternal, |
| 209 | hidl_status_cb); |
| 210 | } |
| 211 | |
| 212 | Return<void> WifiNanIface::getCapabilities(uint32_t cmd_id, |
| 213 | getCapabilities_cb hidl_status_cb) { |
| 214 | return validateAndCall(this, |
| 215 | WifiStatusCode::ERROR_WIFI_IFACE_INVALID, |
| 216 | &WifiNanIface::getCapabilitiesInternal, |
| 217 | hidl_status_cb, |
| 218 | cmd_id); |
| 219 | } |
| 220 | |
| 221 | Return<void> WifiNanIface::dataInterfaceCreate( |
| 222 | uint32_t cmd_id, |
| 223 | const hidl_string& iface_name, |
| 224 | dataInterfaceCreate_cb hidl_status_cb) { |
| 225 | return validateAndCall(this, |
| 226 | WifiStatusCode::ERROR_WIFI_IFACE_INVALID, |
| 227 | &WifiNanIface::dataInterfaceCreateInternal, |
| 228 | hidl_status_cb, |
| 229 | cmd_id, |
| 230 | iface_name); |
| 231 | } |
| 232 | |
| 233 | Return<void> WifiNanIface::dataInterfaceDelete( |
| 234 | uint32_t cmd_id, |
| 235 | const hidl_string& iface_name, |
| 236 | dataInterfaceDelete_cb hidl_status_cb) { |
| 237 | return validateAndCall(this, |
| 238 | WifiStatusCode::ERROR_WIFI_IFACE_INVALID, |
| 239 | &WifiNanIface::dataInterfaceDeleteInternal, |
| 240 | hidl_status_cb, |
| 241 | cmd_id, |
| 242 | iface_name); |
| 243 | } |
| 244 | |
| 245 | Return<void> WifiNanIface::dataRequestInitiator( |
| 246 | uint32_t cmd_id, |
| 247 | const NanDataPathInitiatorRequest& msg, |
| 248 | dataRequestInitiator_cb hidl_status_cb) { |
| 249 | return validateAndCall(this, |
| 250 | WifiStatusCode::ERROR_WIFI_IFACE_INVALID, |
| 251 | &WifiNanIface::dataRequestInitiatorInternal, |
| 252 | hidl_status_cb, |
| 253 | cmd_id, |
| 254 | msg); |
| 255 | } |
| 256 | |
| 257 | Return<void> WifiNanIface::dataIndicationResponse( |
| 258 | uint32_t cmd_id, |
| 259 | const NanDataPathIndicationResponse& msg, |
| 260 | dataIndicationResponse_cb hidl_status_cb) { |
| 261 | return validateAndCall(this, |
| 262 | WifiStatusCode::ERROR_WIFI_IFACE_INVALID, |
| 263 | &WifiNanIface::dataIndicationResponseInternal, |
| 264 | hidl_status_cb, |
| 265 | cmd_id, |
| 266 | msg); |
| 267 | } |
| 268 | |
| 269 | Return<void> WifiNanIface::dataEnd(uint32_t cmd_id, |
| 270 | const NanDataPathEndRequest& msg, |
| 271 | dataEnd_cb hidl_status_cb) { |
| 272 | return validateAndCall(this, |
| 273 | WifiStatusCode::ERROR_WIFI_IFACE_INVALID, |
| 274 | &WifiNanIface::dataEndInternal, |
| 275 | hidl_status_cb, |
| 276 | cmd_id, |
| 277 | msg); |
| 278 | } |
| 279 | |
Roshan Pius | 734fea0 | 2016-10-11 08:30:28 -0700 | [diff] [blame] | 280 | Return<void> WifiNanIface::getType(getType_cb hidl_status_cb) { |
Roshan Pius | 907d4a2 | 2016-10-27 12:48:12 -0700 | [diff] [blame] | 281 | return validateAndCall(this, |
| 282 | WifiStatusCode::ERROR_WIFI_IFACE_INVALID, |
| 283 | &WifiNanIface::getTypeInternal, |
| 284 | hidl_status_cb); |
| 285 | } |
| 286 | |
| 287 | std::pair<WifiStatus, std::string> WifiNanIface::getNameInternal() { |
| 288 | return {createWifiStatus(WifiStatusCode::SUCCESS), ifname_}; |
| 289 | } |
| 290 | |
| 291 | std::pair<WifiStatus, IfaceType> WifiNanIface::getTypeInternal() { |
| 292 | return {createWifiStatus(WifiStatusCode::SUCCESS), IfaceType::NAN}; |
Roshan Pius | 3e2d671 | 2016-10-06 13:16:23 -0700 | [diff] [blame] | 293 | } |
| 294 | |
Roshan Pius | 0c92d44 | 2016-10-27 17:38:53 -0700 | [diff] [blame] | 295 | WifiStatus WifiNanIface::registerEventCallbackInternal( |
| 296 | const sp<IWifiNanIfaceEventCallback>& callback) { |
| 297 | // TODO(b/31632518): remove the callback when the client is destroyed |
| 298 | event_callbacks_.emplace_back(callback); |
| 299 | return createWifiStatus(WifiStatusCode::SUCCESS); |
| 300 | } |
| 301 | |
Roshan Pius | f5f51fd | 2016-12-01 13:54:24 -0800 | [diff] [blame] | 302 | WifiStatus WifiNanIface::enableRequestInternal(uint32_t cmd_id, |
| 303 | const NanEnableRequest& msg) { |
| 304 | legacy_hal::NanEnableRequest legacy_msg; |
| 305 | if (!hidl_struct_util::convertHidlNanEnableRequestToLegacy(msg, |
| 306 | &legacy_msg)) { |
| 307 | return createWifiStatus(WifiStatusCode::ERROR_INVALID_ARGS); |
| 308 | } |
| 309 | legacy_hal::wifi_error legacy_status = |
| 310 | legacy_hal_.lock()->nanEnableRequest(cmd_id, legacy_msg); |
| 311 | return createWifiStatusFromLegacyError(legacy_status); |
Roshan Pius | 0c92d44 | 2016-10-27 17:38:53 -0700 | [diff] [blame] | 312 | } |
| 313 | |
Roshan Pius | f5f51fd | 2016-12-01 13:54:24 -0800 | [diff] [blame] | 314 | WifiStatus WifiNanIface::disableRequestInternal(uint32_t cmd_id) { |
| 315 | legacy_hal::wifi_error legacy_status = |
| 316 | legacy_hal_.lock()->nanDisableRequest(cmd_id); |
| 317 | return createWifiStatusFromLegacyError(legacy_status); |
Roshan Pius | 0c92d44 | 2016-10-27 17:38:53 -0700 | [diff] [blame] | 318 | } |
| 319 | |
Roshan Pius | f5f51fd | 2016-12-01 13:54:24 -0800 | [diff] [blame] | 320 | WifiStatus WifiNanIface::publishRequestInternal(uint32_t cmd_id, |
| 321 | const NanPublishRequest& msg) { |
| 322 | legacy_hal::NanPublishRequest legacy_msg; |
| 323 | if (!hidl_struct_util::convertHidlNanPublishRequestToLegacy(msg, |
| 324 | &legacy_msg)) { |
| 325 | return createWifiStatus(WifiStatusCode::ERROR_INVALID_ARGS); |
| 326 | } |
| 327 | legacy_hal::wifi_error legacy_status = |
| 328 | legacy_hal_.lock()->nanPublishRequest(cmd_id, legacy_msg); |
| 329 | return createWifiStatusFromLegacyError(legacy_status); |
Roshan Pius | 0c92d44 | 2016-10-27 17:38:53 -0700 | [diff] [blame] | 330 | } |
| 331 | |
| 332 | WifiStatus WifiNanIface::publishCancelRequestInternal( |
Roshan Pius | f5f51fd | 2016-12-01 13:54:24 -0800 | [diff] [blame] | 333 | uint32_t cmd_id, const NanPublishCancelRequest& msg) { |
| 334 | legacy_hal::NanPublishCancelRequest legacy_msg; |
| 335 | if (!hidl_struct_util::convertHidlNanPublishCancelRequestToLegacy( |
| 336 | msg, &legacy_msg)) { |
| 337 | return createWifiStatus(WifiStatusCode::ERROR_INVALID_ARGS); |
| 338 | } |
| 339 | legacy_hal::wifi_error legacy_status = |
| 340 | legacy_hal_.lock()->nanPublishCancelRequest(cmd_id, legacy_msg); |
| 341 | return createWifiStatusFromLegacyError(legacy_status); |
Roshan Pius | 0c92d44 | 2016-10-27 17:38:53 -0700 | [diff] [blame] | 342 | } |
Roshan Pius | f5f51fd | 2016-12-01 13:54:24 -0800 | [diff] [blame] | 343 | |
Roshan Pius | 0c92d44 | 2016-10-27 17:38:53 -0700 | [diff] [blame] | 344 | WifiStatus WifiNanIface::subscribeRequestInternal( |
Roshan Pius | f5f51fd | 2016-12-01 13:54:24 -0800 | [diff] [blame] | 345 | uint32_t cmd_id, const NanSubscribeRequest& msg) { |
| 346 | legacy_hal::NanSubscribeRequest legacy_msg; |
| 347 | if (!hidl_struct_util::convertHidlNanSubscribeRequestToLegacy(msg, |
| 348 | &legacy_msg)) { |
| 349 | return createWifiStatus(WifiStatusCode::ERROR_INVALID_ARGS); |
| 350 | } |
| 351 | legacy_hal::wifi_error legacy_status = |
| 352 | legacy_hal_.lock()->nanSubscribeRequest(cmd_id, legacy_msg); |
| 353 | return createWifiStatusFromLegacyError(legacy_status); |
Roshan Pius | 0c92d44 | 2016-10-27 17:38:53 -0700 | [diff] [blame] | 354 | } |
Roshan Pius | f5f51fd | 2016-12-01 13:54:24 -0800 | [diff] [blame] | 355 | |
Roshan Pius | 0c92d44 | 2016-10-27 17:38:53 -0700 | [diff] [blame] | 356 | WifiStatus WifiNanIface::subscribeCancelRequestInternal( |
| 357 | uint32_t /* cmd_id */, const NanSubscribeCancelRequest& /* msg */) { |
| 358 | // TODO implement |
| 359 | return createWifiStatus(WifiStatusCode::SUCCESS); |
| 360 | } |
| 361 | WifiStatus WifiNanIface::transmitFollowupRequestInternal( |
| 362 | uint32_t /* cmd_id */, const NanTransmitFollowupRequest& /* msg */) { |
| 363 | // TODO implement |
| 364 | return createWifiStatus(WifiStatusCode::SUCCESS); |
| 365 | } |
| 366 | WifiStatus WifiNanIface::configRequestInternal( |
| 367 | uint32_t /* cmd_id */, const NanConfigRequest& /* msg */) { |
| 368 | // TODO implement |
| 369 | return createWifiStatus(WifiStatusCode::SUCCESS); |
| 370 | } |
| 371 | WifiStatus WifiNanIface::beaconSdfPayloadRequestInternal( |
| 372 | uint32_t /* cmd_id */, const NanBeaconSdfPayloadRequest& /* msg */) { |
| 373 | // TODO implement |
| 374 | return createWifiStatus(WifiStatusCode::SUCCESS); |
| 375 | } |
| 376 | std::pair<WifiStatus, NanVersion> WifiNanIface::getVersionInternal() { |
| 377 | // TODO implement |
| 378 | return {createWifiStatus(WifiStatusCode::SUCCESS), 0}; |
| 379 | } |
| 380 | WifiStatus WifiNanIface::getCapabilitiesInternal(uint32_t /* cmd_id */) { |
| 381 | // TODO implement |
| 382 | return createWifiStatus(WifiStatusCode::SUCCESS); |
| 383 | } |
| 384 | WifiStatus WifiNanIface::dataInterfaceCreateInternal( |
| 385 | uint32_t /* cmd_id */, const std::string& /* iface_name */) { |
| 386 | // TODO implement |
| 387 | return createWifiStatus(WifiStatusCode::SUCCESS); |
| 388 | } |
| 389 | WifiStatus WifiNanIface::dataInterfaceDeleteInternal( |
| 390 | uint32_t /* cmd_id */, const std::string& /* iface_name */) { |
| 391 | // TODO implement |
| 392 | return createWifiStatus(WifiStatusCode::SUCCESS); |
| 393 | } |
| 394 | WifiStatus WifiNanIface::dataRequestInitiatorInternal( |
| 395 | uint32_t /* cmd_id */, const NanDataPathInitiatorRequest& /* msg */) { |
| 396 | // TODO implement |
| 397 | return createWifiStatus(WifiStatusCode::SUCCESS); |
| 398 | } |
| 399 | WifiStatus WifiNanIface::dataIndicationResponseInternal( |
| 400 | uint32_t /* cmd_id */, const NanDataPathIndicationResponse& /* msg */) { |
| 401 | // TODO implement |
| 402 | return createWifiStatus(WifiStatusCode::SUCCESS); |
| 403 | } |
| 404 | WifiStatus WifiNanIface::dataEndInternal( |
| 405 | uint32_t /* cmd_id */, const NanDataPathEndRequest& /* msg */) { |
| 406 | // TODO implement |
| 407 | return createWifiStatus(WifiStatusCode::SUCCESS); |
| 408 | } |
Roshan Pius | 3e2d671 | 2016-10-06 13:16:23 -0700 | [diff] [blame] | 409 | } // namespace implementation |
| 410 | } // namespace V1_0 |
| 411 | } // namespace wifi |
| 412 | } // namespace hardware |
| 413 | } // namespace android |