1
0
Fork 0

drm_hwcomposer: Add flag for blocking commits

Add a flag to specify whether a commit should be blocking or not.
Default the flag to false, which matches the current behavior.

Change-Id: Ib8f332d8d4d6b8ae1d12f86a980cec8e3efc9da0
Signed-off-by: Drew Davenport <ddavenport@google.com>
This commit is contained in:
Drew Davenport 2024-11-07 10:41:14 -07:00
parent fe70c80d71
commit bcc587d30b
2 changed files with 2 additions and 1 deletions

View file

@ -101,7 +101,7 @@ auto DrmAtomicStateManager::CommitFrame(AtomicCommitArgs &args) -> int {
}
}
bool nonblock = true;
bool nonblock = !args.blocking;
if (args.active) {
nonblock = false;

View file

@ -33,6 +33,7 @@ namespace android {
struct AtomicCommitArgs {
/* inputs. All fields are optional, but at least one has to be specified */
bool test_only = false;
bool blocking = false;
std::optional<DrmMode> display_mode;
std::optional<bool> active;
std::shared_ptr<DrmKmsPlan> composition;