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

Commit e1468a87 authored by Atneya Nair's avatar Atneya Nair
Browse files

[soundtrigger] Move audio session out of lock

Similar to I67b8b2ee484be7c7aefb26d9df64689e5e3f5d00 --

Acquiring audio session holds the STM lock -> APS lock -> Aflinger lock,
which can be blocked by calls into the audio HAL. Since the HAL also
calls back to the ST fwk synchronously (which grabs the STM lock) this
can cross deadlock.

Again, as a spot fix, pull this call out of the lock, which is fine,
since there is no atomicity required between ST and APM, as the audio
session is simply a set of allocated port ids. The STM lock should be
dropped as we call higher up, so we shouldn't deadlock on a higher level
lock either.

Test: manual assistant hotword
Test: manual now playing
Flag: EXEMPT bugfix
Bug: 391620601
Change-Id: I052e3b58925bde088d9df9d1d37f7c775dcd89c0
parent 8c4f5b3f
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