summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSteven Moreland <smoreland@google.com>2022-01-15 01:13:01 +0000
committerSteven Moreland <smoreland@google.com>2022-01-15 01:14:55 +0000
commit2fcf57e9fd260db88c8abfa014eab775b86db76b (patch)
treed450324808ea41c5c48f0578424710b9c5addf14
parent81cae0aa35d4f1da4f1db054dc8c37ac72902022 (diff)
downloadlibhwbinder-2fcf57e9fd260db88c8abfa014eab775b86db76b.tar.gz
The comments here were wrong. I*::getService only waits for HIDL services which are declared in the VINTF manifest. This test usually passed before because testing the passthrough service gave enough time for the server to start. Fixes: 206700689 Test: atest libhwbinder_benchmark Change-Id: Ibaac31fde82d6cbd2c03aac362fd26ba48f9165f
-rw-r--r--vts/performance/Benchmark.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/vts/performance/Benchmark.cpp b/vts/performance/Benchmark.cpp
index f995ec7..87185f5 100644
--- a/vts/performance/Benchmark.cpp
+++ b/vts/performance/Benchmark.cpp
@@ -82,7 +82,6 @@ static void BM_sendVec(benchmark::State& state, sp<IBenchmark> service) {
}
static void BM_sendVec_passthrough(benchmark::State& state) {
- // getService automatically retries
sp<IBenchmark> service = IBenchmark::getService(gServiceName, true /* getStub */);
if (service == nullptr) {
state.SkipWithError("Failed to retrieve benchmark service.");
@@ -94,7 +93,7 @@ static void BM_sendVec_passthrough(benchmark::State& state) {
}
static void BM_sendVec_binderize(benchmark::State& state) {
- // getService automatically retries
+ android::hardware::details::waitForHwService(IBenchmark::descriptor, gServiceName);
sp<IBenchmark> service = IBenchmark::getService(gServiceName);
if (service == nullptr) {
state.SkipWithError("Failed to retrieve benchmark service.");