keystore: Run Wifi keystore HAL in keystore daemon
The wifi keystore hal will run in the context of the main keystore
daemon.
Also,
Use the new IKeystore::tryGetService() for retrieveing the HAL service.
Bug: 34603782
Test: Able to connect to wifi passpoint networks.
Change-Id: I1436ea83166e5ad17372d98b0fd699c0dd732a11
diff --git a/keystore-engine/keystore_backend_hidl.cpp b/keystore-engine/keystore_backend_hidl.cpp
index 37ad9a1..80a3601 100644
--- a/keystore-engine/keystore_backend_hidl.cpp
+++ b/keystore-engine/keystore_backend_hidl.cpp
@@ -37,7 +37,7 @@
return -1;
}
- sp<IKeystore> service = IKeystore::getService();
+ sp<IKeystore> service = IKeystore::tryGetService();
if (service == NULL) {
ALOGE("could not contact keystore HAL");
return -1;
@@ -64,7 +64,7 @@
return -1;
}
- sp<IKeystore> service = IKeystore::getService();
+ sp<IKeystore> service = IKeystore::tryGetService();
if (service == NULL) {
ALOGE("could not contact keystore HAL");
return -1;