summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTomi Valkeinen <tomi.valkeinen@ti.com>2016-09-30 10:19:43 +0300
committerTomi Valkeinen <tomi.valkeinen@ti.com>2016-09-30 10:19:43 +0300
commit1852a37054072aca377cc0e46d88d8b6d8c575a6 (patch)
tree759d447949ef7dc88f468fe8a906a8f7e9ff1c11
parent7785a21f35c0bfb7a9eaec0ab2a4ace45f241c96 (diff)
kmstest: enable display even if crtc doesn't have fb
With atomic modesetting we can enable the crtc without a primary plane. This allows enabling only a plane on the screen. Change set_crtcs_n_planes() to allow this. Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
-rw-r--r--utils/kmstest.cpp22
1 files changed, 11 insertions, 11 deletions
diff --git a/utils/kmstest.cpp b/utils/kmstest.cpp
index 5fb46f9..52e4614 100644
--- a/utils/kmstest.cpp
+++ b/utils/kmstest.cpp
@@ -670,20 +670,20 @@ static void set_crtcs_n_planes(Card& card, const vector<OutputInfo>& outputs)
auto conn = o.connector;
auto crtc = o.crtc;
- if (!o.fbs.empty()) {
- auto fb = o.fbs[0];
+ blobs.emplace_back(o.mode.to_blob(card));
+ Blob* mode_blob = blobs.back().get();
- blobs.emplace_back(o.mode.to_blob(card));
- Blob* mode_blob = blobs.back().get();
+ req.add(conn, {
+ { "CRTC_ID", crtc->id() },
+ });
- req.add(conn, {
- { "CRTC_ID", crtc->id() },
- });
+ req.add(crtc, {
+ { "ACTIVE", 1 },
+ { "MODE_ID", mode_blob->id() },
+ });
- req.add(crtc, {
- { "ACTIVE", 1 },
- { "MODE_ID", mode_blob->id() },
- });
+ if (!o.fbs.empty()) {
+ auto fb = o.fbs[0];
req.add(o.primary_plane, {
{ "FB_ID", fb->id() },