53 lines
1.6 KiB
Diff
53 lines
1.6 KiB
Diff
From: Alex Gonzalez <alex.gonzalez@digi.com>
|
|
Date: Thu, 17 May 2012 10:46:39 +0200
|
|
Subject: [PATCH] gst-fsl-plugin: Only call MXCFB_SET_OVERLAY_POS with overlay framebuffer.
|
|
|
|
This is just to avoid the ioctl to return an error.
|
|
|
|
Signed-off-by: Alex Gonzalez <alex.gonzalez@digi.com>
|
|
---
|
|
libs/vss/vss_common.c | 22 ++++++++++++++--------
|
|
1 files changed, 14 insertions(+), 8 deletions(-)
|
|
|
|
diff --git a/libs/vss/vss_common.c b/libs/vss/vss_common.c
|
|
index fb80f42..114b45b 100755
|
|
--- a/libs/vss/vss_common.c
|
|
+++ b/libs/vss/vss_common.c
|
|
@@ -686,10 +686,14 @@ _setDeviceConfig(VideoDevice * vd)
|
|
|
|
int fd = _getDevicefd(vd);
|
|
|
|
- /* Workaround for ipu hardware, it need set to 0,0 before change another offset */
|
|
- pos.x = 0;
|
|
- pos.y = 0;
|
|
- VS_IOCTL(fd, MXCFB_SET_OVERLAY_POS, here1, &pos);
|
|
+
|
|
+ VS_IOCTL(fd, FBIOGET_FSCREENINFO, done, &fb_fix);
|
|
+ if( !strcmp(fb_fix.id,"DISP3 FG") ){
|
|
+ /* Workaround for ipu hardware, it need set to 0,0 before change another offset */
|
|
+ pos.x = 0;
|
|
+ pos.y = 0;
|
|
+ VS_IOCTL(fd, MXCFB_SET_OVERLAY_POS, here1, &pos);
|
|
+ }
|
|
here1:
|
|
VS_IOCTL(fd, FBIOBLANK, done, FB_BLANK_POWERDOWN);
|
|
|
|
@@ -711,10 +715,12 @@ here1:
|
|
|
|
VS_IOCTL(fd, FBIOGET_VSCREENINFO, done, &fb_var);
|
|
VS_IOCTL(fd, FBIOGET_FSCREENINFO, done, &fb_fix);
|
|
-
|
|
- pos.x = vd->disp.left;
|
|
- pos.y = vd->disp.top;
|
|
- VS_IOCTL(fd, MXCFB_SET_OVERLAY_POS, here2, &pos);
|
|
+
|
|
+ if( !strcmp(fb_fix.id,"DISP3 FG") ){
|
|
+ pos.x = vd->disp.left;
|
|
+ pos.y = vd->disp.top;
|
|
+ VS_IOCTL(fd, MXCFB_SET_OVERLAY_POS, here2, &pos);
|
|
+ }
|
|
here2:
|
|
|
|
VS_IOCTL(fd, FBIOBLANK, done, FB_BLANK_UNBLANK);
|
|
|