@@ -211,11 +211,15 @@ int xvtc_generator_start(struct xvtc_device *xvtc,
xvtc_gen_write(xvtc, XVTC_HSYNC,
(config->hsync_end << XVTC_HSYNC_END_SHIFT) |
(config->hsync_start << XVTC_HSYNC_START_SHIFT));
- xvtc_gen_write(xvtc, XVTC_F0_VBLANK_H, 0);
+ xvtc_gen_write(xvtc, XVTC_F0_VBLANK_H,
+ (config->hsync_start << XVTC_F0_VBLANK_HEND_SHIFT) |
+ (config->hsync_start << XVTC_F0_VBLANK_HSTART_SHIFT));
xvtc_gen_write(xvtc, XVTC_F0_VSYNC_V,
(config->vsync_end << XVTC_F0_VSYNC_VEND_SHIFT) |
(config->vsync_start << XVTC_F0_VSYNC_VSTART_SHIFT));
- xvtc_gen_write(xvtc, XVTC_F0_VSYNC_H, 0);
+ xvtc_gen_write(xvtc, XVTC_F0_VSYNC_H,
+ (config->hsync_start << XVTC_F0_VSYNC_HEND_SHIFT) |
+ (config->hsync_start << XVTC_F0_VSYNC_HSTART_SHIFT));
/* Enable the generator. Set the source of all generator parameters to
* generator registers.
This patch sets the values of VSYNC and VBLANK in Xilinx VTC. The patch was tested using a modified version of this driver and using an HDMI compliance equipment. There is still missing the polarity settings for H/V which would require a change in the interface of this driver. Signed-off-by: Jose Abreu <joabreu@synopsys.com> Cc: Carlos Palminha <palminha@synopsys.com> Cc: Hyun Kwon <hyun.kwon@xilinx.com> Cc: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Cc: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Cc: linux-media@vger.kernel.org --- drivers/media/platform/xilinx/xilinx-vtc.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-)