aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNikhil Devshatwar2017-05-04 04:38:01 -0500
committerNikhil Devshatwar2017-05-11 04:33:38 -0500
commit7e63575f149d1a5a4a052d6211131676d4ccc655 (patch)
tree8d84b2d4f0346964f4b9a5d83a80a0516ac03971
parentf221e462afd8461517b1dd9d8ef04b67a07275fa (diff)
downloadomapdrmtest-7e63575f149d1a5a4a052d6211131676d4ccc655.tar.gz
omapdrmtest-7e63575f149d1a5a4a052d6211131676d4ccc655.tar.xz
omapdrmtest-7e63575f149d1a5a4a052d6211131676d4ccc655.zip
display-kms: Call SetCrtc at init time
Some monitors have a preferred mode which can be different than the application selected mode. It might be the case the selected mode is not It is expected that the DRM application should set the right mode before starting to use any of the planes. Make sure that the display-kms backend sets up the right mode by calling setCrtc before using any of the planes. This is done by allocating a buffer and calling post_buffer as part of the init hook. Fixes: LCPD-9401 Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
-rw-r--r--util/display-kms.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/util/display-kms.c b/util/display-kms.c
index 58746ed..89c480e 100644
--- a/util/display-kms.c
+++ b/util/display-kms.c
@@ -564,6 +564,7 @@ disp_kms_open(int argc, char **argv)
564{ 564{
565 struct display_kms *disp_kms = NULL; 565 struct display_kms *disp_kms = NULL;
566 struct display *disp; 566 struct display *disp;
567 struct buffer **bufs;
567 int i; 568 int i;
568 569
569 disp_kms = calloc(1, sizeof(*disp_kms)); 570 disp_kms = calloc(1, sizeof(*disp_kms));
@@ -687,6 +688,9 @@ disp_kms_open(int argc, char **argv)
687 MSG("using %d connectors, %dx%d display, multiplanar: %d", 688 MSG("using %d connectors, %dx%d display, multiplanar: %d",
688 disp_kms->connectors_count, disp->width, disp->height, disp->multiplanar); 689 disp_kms->connectors_count, disp->width, disp->height, disp->multiplanar);
689 690
691 bufs = disp_get_buffers(disp, 1);
692 disp_post_buffer(disp, bufs[0]);
693
690 return disp; 694 return disp;
691 695
692fail: 696fail: