diff options
author | Liu Ying <victor.liu@nxp.com> | 2018-04-12 12:40:48 +0800 |
---|---|---|
committer | Leonard Crestez <leonard.crestez@nxp.com> | 2018-08-24 12:41:33 +0300 |
commit | 573c7c863e3df353a50b295e52c2fe6573a6cc17 (patch) | |
tree | 1c985314d1b5236780b6badf4736378d89c1e39f /drivers/gpu/imx/imx8_dprc.c | |
parent | 087f4898b8bc90da8070c1f97536636f14bfffa8 (diff) |
MLK-18009 drm/imx: dpu: plane: Support deinterlacing via fetchdecode & vscaler
Fetchdecode may work together with vscaler to do bob deinterlacing.
This patch adds the deinterlacing support for DPU DRM plane by using them.
Signed-off-by: Liu Ying <victor.liu@nxp.com>
Diffstat (limited to 'drivers/gpu/imx/imx8_dprc.c')
-rw-r--r-- | drivers/gpu/imx/imx8_dprc.c | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/drivers/gpu/imx/imx8_dprc.c b/drivers/gpu/imx/imx8_dprc.c index c5aea6ef92d7..1acabdf40085 100644 --- a/drivers/gpu/imx/imx8_dprc.c +++ b/drivers/gpu/imx/imx8_dprc.c @@ -319,11 +319,11 @@ void dprc_configure(struct dprc *dprc, unsigned int stream_id, unsigned int x_offset, unsigned int y_offset, unsigned int stride, u32 format, u64 modifier, unsigned long baddr, unsigned long uv_baddr, - bool start, bool aux_start) + bool start, bool aux_start, bool interlace_frame) { const struct dprc_format_info *info = dprc_format_info(format); unsigned int dprc_width = width + x_offset; - unsigned int dprc_height = height + y_offset; + unsigned int dprc_height; unsigned int p1_w, p1_h, p2_w, p2_h; unsigned int prg_stride = width * info->cpp[0]; unsigned int bpp = 8 * info->cpp[0]; @@ -343,6 +343,13 @@ void dprc_configure(struct dprc *dprc, unsigned int stream_id, dprc_dpu_gpr_configure(dprc, stream_id); } + if (interlace_frame) { + height /= 2; + y_offset /= 2; + } + + dprc_height = height + y_offset; + /* disable all control irqs and enable all error irqs */ dprc_write(dprc, IRQ_CTRL_MASK, IRQ_MASK); |