diff options
author | Tomi Valkeinen <tomi.valkeinen@ti.com> | 2016-12-12 12:26:26 +0200 |
---|---|---|
committer | Tomi Valkeinen <tomi.valkeinen@ti.com> | 2016-12-12 12:26:28 +0200 |
commit | 4f97a45fba58743a1ccd1f905cc5207d4d5045bf (patch) | |
tree | 47262648377a768459ccffd600ee4954cbdb72df | |
parent | 4f57f877a13f49c6e8f7cb11288bd948817aea74 (diff) |
kmstest: use resman to get primary planes
We need to ensure that a primary plane is not already in use.
ResourceManager does this for us.
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
-rw-r--r-- | utils/kmstest.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/utils/kmstest.cpp b/utils/kmstest.cpp index 43cb557..3a98468 100644 --- a/utils/kmstest.cpp +++ b/utils/kmstest.cpp @@ -939,9 +939,11 @@ int main(int argc, char **argv) vector<OutputInfo> outputs = setups_to_outputs(card, output_args); + ResourceManager resman(card); + if (card.has_atomic()) { for (OutputInfo& o : outputs) { - o.primary_plane = o.crtc->get_primary_plane(); + o.primary_plane = resman.reserve_primary_plane(o.crtc); if (!o.fbs.empty() && !o.primary_plane) EXIT("Could not get primary plane for crtc '%u'", o.crtc->id()); |