Revert "wifi: remove wifi instance name string check"
This reverts commit 1c50a59eae
.
Reason for revert: This was not needed. Does not fix the issue at hand.
Bug: 161951052
Test: atest VtsHalWifiSupplicantV1_1TargetTest
Change-Id: I872a1b3e87f17a43eb3c22c930e916c7e5e2d2a6
This commit is contained in:
parent
0cd6bffb74
commit
533a44d096
1 changed files with 8 additions and 0 deletions
|
@ -52,6 +52,10 @@ namespace {
|
|||
// Helper function to initialize the driver and firmware to STA mode
|
||||
// using the vendor HAL HIDL interface.
|
||||
void initilializeDriverAndFirmware(const std::string& wifi_instance_name) {
|
||||
// Skip if wifi instance is not set.
|
||||
if (wifi_instance_name == "") {
|
||||
return;
|
||||
}
|
||||
if (getWifi(wifi_instance_name) != nullptr) {
|
||||
sp<IWifiChip> wifi_chip = getWifiChip(wifi_instance_name);
|
||||
ChipModeId mode_id;
|
||||
|
@ -65,6 +69,10 @@ void initilializeDriverAndFirmware(const std::string& wifi_instance_name) {
|
|||
// Helper function to deinitialize the driver and firmware
|
||||
// using the vendor HAL HIDL interface.
|
||||
void deInitilializeDriverAndFirmware(const std::string& wifi_instance_name) {
|
||||
// Skip if wifi instance is not set.
|
||||
if (wifi_instance_name == "") {
|
||||
return;
|
||||
}
|
||||
if (getWifi(wifi_instance_name) != nullptr) {
|
||||
stopWifi(wifi_instance_name);
|
||||
} else {
|
||||
|
|
Loading…
Reference in a new issue