Commit Graph

4 Commits

Author SHA1 Message Date
Lais Andrade
db8ffbb077 Remove cleanup after bench loop from setAmplitude test
Fix error on waiting for long vibration callback that might have been
already cleared by the HAL when vibration finished. Test run crash log:

FORTIFY: pthread_mutex_lock called on a destroyed mutex (0xf5a83bbc)

Keep all test cleanup logic in teardown methods.

Bug: 329899022
Change-Id: If7c13296b870e792063a9ad7b307d57fb5c333aa
Test: atest VibratorHalIntegrationBenchmark
2024-03-26 12:03:10 +00:00
Lais Andrade
59a5d543b0 Fix binder transaction errors on vibrator benchmark tests
Setup binder process thread pool for vibrator HAL benchmark tests to fix
binder transaction errors of the type:

E Vibrator: Failed completion callback: -129

This change also adds checks for HAL results, which will cause them to
fail earlier with a useful error message when the device reaches a bad
state. This should avoid timeout failures for the whole test suite.

Other fixes:

- Fix vibrator.on(ms) tests to use a valid max duration value
  (previously failing with illegal argument);
- Use a smaller fixed # of iterations on tests that iterate on vibrate
  calls, and add wait for vibration to be complete to measure the HAL
  in a more stable state;
- Skip getSupportedAlwaysOnEffects on devices without capability;

Fix: 329239120
Bug: 329899022
Bug: 329203383
Test: atest VibratorHalIntegrationBenchmark
Change-Id: Id541a62745320a601934fd3f176f8ba42b5a7b2d
2024-03-20 13:54:13 +00:00
Adrian Roos
77659428e3 vibrator HAL bench: Fix broken benchmarks
Fixes an issue with the benchmarks, where they would skip unsupported
situations by early returning without reaching the measure loop and
without notifying the framework.

The framework would then retry the exact same scenario indefinitely.

To fix, makes sure every early return also calls SkipWithMessage.

Fixes: 302845046
Test: adb shell /tmp/foobar/VibratorHalIntegrationBenchmark --v=2
Change-Id: Ib52b8c4d94755a0961bcfb40d508482e5c49cb52
2024-02-09 19:49:32 +00:00
Lais Andrade
e29acd8194 Move vibrator HAL benchmarks to interfaces/vibrator
The benchmarks are relying only with the HAL interfaces, so they can be
moved outside the pixel folder and integrated with continuous native
metric tests.

Bug: b/159981541
Test: N/A, just moving tests
Change-Id: I54e7155d12eb844df7f77e8c5d232949426546d2
2020-08-07 13:51:04 +00:00