diff options
author | Fancy Fang <chen.fang@freescale.com> | 2015-04-15 14:59:08 +0800 |
---|---|---|
committer | Jason Liu <r64343@freescale.com> | 2015-05-08 17:24:51 +0800 |
commit | 7cf1e4309db5d601338367a5d5aca255ad799c4c (patch) | |
tree | 59cc41c777d8f2fed0363a1b685103db0d7481c2 | |
parent | 4c91951380128ff6a7937e4d44457e4ed8fd2740 (diff) |
MLK-10573-2 dma: pxp-v2: add two planes output support
The output channel support two planes YUV formats.
So the output UV buffer should also be configured
in this case.
Signed-off-by: Fancy Fang <chen.fang@freescale.com>
-rw-r--r-- | drivers/dma/pxp/pxp_dma_v2.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/drivers/dma/pxp/pxp_dma_v2.c b/drivers/dma/pxp/pxp_dma_v2.c index c850c5eddcf7..77c405ed461a 100644 --- a/drivers/dma/pxp/pxp_dma_v2.c +++ b/drivers/dma/pxp/pxp_dma_v2.c @@ -407,6 +407,18 @@ static void pxp_set_outbuf(struct pxps *pxp) __raw_writel(out_params->paddr, pxp->base + HW_PXP_OUT_BUF); + if ((out_params->pixel_fmt == PXP_PIX_FMT_NV12) || + (out_params->pixel_fmt == PXP_PIX_FMT_NV21) || + (out_params->pixel_fmt == PXP_PIX_FMT_NV16) || + (out_params->pixel_fmt == PXP_PIX_FMT_NV61)) { + dma_addr_t Y, U; + + Y = out_params->paddr; + U = Y + (out_params->width * out_params->height); + + __raw_writel(U, pxp->base + HW_PXP_OUT_BUF2); + } + if (proc_data->rotate == 90 || proc_data->rotate == 270) __raw_writel(BF_PXP_OUT_LRC_X(out_params->height - 1) | BF_PXP_OUT_LRC_Y(out_params->width - 1), |