diff options
| author | 2024-04-11 13:57:14 -0400 | |
|---|---|---|
| committer | 2024-06-12 15:06:21 -0400 | |
| commit | 5c989f5c72c52cba1fc2264525fac2e58bdf9f94 (patch) | |
| tree | 93ec26158f341ba3c054685d8d134b3d8abc6c30 /libs/gui/BLASTBufferQueue.cpp | |
| parent | 9ad62b5e03be7d633dac9c5b9be1b81db45db00c (diff) | |
SF: Isolate modesetting in DisplayModeController
Move the per-display state machine for modesetting from DisplayDevice to
DMC. In lieu of mStateLock, protect display lookup from multiple threads
using a mutex internal to DMC, which fixes the following deadlock:
OneShotTimer::loop
SF::requestDisplayModes
mStateLock
SF::commit
mStateLock
SF::processDisplayChangesLocked (hotplug or resolution change)
Scheduler::demotePacesetterDisplay
OneShotTimer::stop
A notable change is that {initiate,finalize}DisplayModeChange(s) are no
longer called under mStateLock, thanks to DMC's granular, internal lock.
finalizeDisplayModeChange still locks mStateLock for resolution changes.
Add an ActiveModeListener to DMC and register a callback in SF to update
the refresh rate overlay, which still lives in DisplayDevice for now.
Fixes: 329450361
Bug: 241285876
Test: DisplayModeControllerTest
Test: libsurfaceflinger_unittest
Change-Id: I30ec756f134d2d67a70ac8797008dc792eac035e
Diffstat (limited to 'libs/gui/BLASTBufferQueue.cpp')
0 files changed, 0 insertions, 0 deletions