drm: ignore primary argument when using evdi drivers (#25)

* fix: ignore primary if using evdi drivers for displaylink

* style: removed curly braces from evdi if-check
This commit is contained in:
Khiet Tam Nguyen 2024-07-25 04:14:29 +10:00 committed by GitHub
parent 4a1424e85b
commit e569340c6b
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -622,8 +622,12 @@ bool Aquamarine::CDRMBackend::registerGPU(SP<CSessionDevice> gpu_, SP<CDRMBacken
gpuName = drmName; gpuName = drmName;
auto drmVerName = drmVer->name ? drmVer->name : "unknown";
if (std::string_view(drmVerName) == "evdi")
primary = {};
backend->log(AQ_LOG_DEBUG, backend->log(AQ_LOG_DEBUG,
std::format("drm: Starting backend for {}, with driver {}{}", drmName ? drmName : "unknown", drmVer->name ? drmVer->name : "unknown", std::format("drm: Starting backend for {}, with driver {}{}", drmName ? drmName : "unknown", drmVerName,
(primary ? std::format(" with primary {}", primary->gpu->path) : ""))); (primary ? std::format(" with primary {}", primary->gpu->path) : "")));
drmFreeVersion(drmVer); drmFreeVersion(drmVer);