]> rtime.felk.cvut.cz Git - zynq/linux.git/commitdiff
drm: xlnx: pl_disp: Enable early callback
authorVishal Sagar <vishal.sagar@xilinx.com>
Sat, 13 Oct 2018 06:32:42 +0000 (12:02 +0530)
committerMichal Simek <michal.simek@xilinx.com>
Mon, 15 Oct 2018 07:38:17 +0000 (09:38 +0200)
Patch adds support for enabling early callback. This enables the
user space applications like kmssink plugin that queue up only one
buffer at a time to not drop any frames due to timeout receiving
vblank event from the driver.
The side effect of enabling this behavior is that the buffer whose
callback function has been called may actually still be scanning
out.

Signed-off-by: Vishal Sagar <vishal.sagar@xilinx.com>
Reviewed-by: Hyun Kwon <hyun.kwon@xilinx.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
drivers/gpu/drm/xlnx/xlnx_pl_disp.c

index 28f5779ac6a28e7e6f785a77e7c0a5f0f2171c67..55f7522873d2bdf6994b522af4f4915bde0647b8 100644 (file)
@@ -179,6 +179,7 @@ static void xlnx_pl_disp_plane_enable(struct drm_plane *plane)
        }
        desc->callback = xlnx_pl_disp->callback;
        desc->callback_param = xlnx_pl_disp->callback_param;
+       xilinx_xdma_set_earlycb(xlnx_dma_chan->dma_chan, desc, true);
 
        if (plane->state->fb->flags == DRM_MODE_FB_ALTERNATE_TOP ||
            plane->state->fb->flags == DRM_MODE_FB_ALTERNATE_BOTTOM) {