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

Skip to content
Commit ab0c7403 authored by Martijn Coenen's avatar Martijn Coenen
Browse files

Increase timeout waiting for ExternalStorageService to bind.

We've observed occasions where it can take a long time for the
system_server main thread to come around to handling the bind of the
service, for example because it's handling long-running jobs:

06-04 08:19:27.544  1000  1532  1532 W Looper  : Slow dispatch took
2044ms main h=com.android.server.job.JobSchedulerService$JobHandler
c=null m=1

Delays like this can cause us to fail binding to the external storage
service for a user, and reset the whole storage stack, leading to
unexpected results, especially if we timed out for trying to mount user
10, while user 0 has already been successfully mounted.

Increase the timeout to 20 seconds; this gives us a lot more time to
complete the bind. At the same time, we want to avoid risking holding
the vold lock for too and/or any deadlocks.

Add a WTF for when we do hit the timeout, to get a better grasp on how
common this is.

Bug: 158452122
Test: Boot device
Change-Id: Ia8f6f121448f6b5e484fd3e8cca845fdd89afc23
parent 475cf183
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment