Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 6424f29c authored by Greg Kaiser's avatar Greg Kaiser
Browse files

Allow longer init timeout on some devices

Finding the Bluetooth HAL within 0.5 seconds isn't a strict
requirement, but failing to do so will give a slow Bluetooth start
up for users, so we generally want to give an error in that case.

However, some devices have very limited hardware resources
and use lazy HALs for Bluetooth, which can result in us expecting
this to sometimes take longer.

Devices are able to set the ro.hw_timeout_multiplier property to
indicate this.  However, we cap this multiplier at 2, because we
don't have an arbitrary amount of time for Bluetooth startup.

Bug: 285748554, 357043853
Test: m mokey_go32-trunk_staging-userdebug; Confirmed on a slow device with this multiplier set that we're able to take longer than 500ms to init, but still not get an error; compiled a one-off version which introduced a usleep() and confirmed the error message gave the correct number of milliseconds for the timeout.
Flags: EXEMPT for bug fix
Change-Id: Id520cd7ce6a972919a289485a75cba94cbe45057
parent c746b8fc
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment