Commit bffba473 authored by Laurent Pinchart's avatar Laurent Pinchart Committed by Mauro Carvalho Chehab

[media] v4l: vsp1: Fix tri-planar format support through DRM API

The vsp1 driver supports tri-planar formats, but the DRM API only passes
two memory addresses. Add a third one.
Signed-off-by: default avatarLaurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@s-opensource.com>
parent 47b4bafd
...@@ -276,12 +276,12 @@ int vsp1_du_atomic_update(struct device *dev, unsigned int rpf_index, ...@@ -276,12 +276,12 @@ int vsp1_du_atomic_update(struct device *dev, unsigned int rpf_index,
} }
dev_dbg(vsp1->dev, dev_dbg(vsp1->dev,
"%s: RPF%u: (%u,%u)/%ux%u -> (%u,%u)/%ux%u (%08x), pitch %u dma { %pad, %pad } zpos %u\n", "%s: RPF%u: (%u,%u)/%ux%u -> (%u,%u)/%ux%u (%08x), pitch %u dma { %pad, %pad, %pad } zpos %u\n",
__func__, rpf_index, __func__, rpf_index,
cfg->src.left, cfg->src.top, cfg->src.width, cfg->src.height, cfg->src.left, cfg->src.top, cfg->src.width, cfg->src.height,
cfg->dst.left, cfg->dst.top, cfg->dst.width, cfg->dst.height, cfg->dst.left, cfg->dst.top, cfg->dst.width, cfg->dst.height,
cfg->pixelformat, cfg->pitch, &cfg->mem[0], &cfg->mem[1], cfg->pixelformat, cfg->pitch, &cfg->mem[0], &cfg->mem[1],
cfg->zpos); &cfg->mem[2], cfg->zpos);
/* Store the format, stride, memory buffer address, crop and compose /* Store the format, stride, memory buffer address, crop and compose
* rectangles and Z-order position and for the input. * rectangles and Z-order position and for the input.
...@@ -301,7 +301,7 @@ int vsp1_du_atomic_update(struct device *dev, unsigned int rpf_index, ...@@ -301,7 +301,7 @@ int vsp1_du_atomic_update(struct device *dev, unsigned int rpf_index,
rpf->mem.addr[0] = cfg->mem[0]; rpf->mem.addr[0] = cfg->mem[0];
rpf->mem.addr[1] = cfg->mem[1]; rpf->mem.addr[1] = cfg->mem[1];
rpf->mem.addr[2] = 0; rpf->mem.addr[2] = cfg->mem[2];
vsp1->drm->inputs[rpf_index].crop = cfg->src; vsp1->drm->inputs[rpf_index].crop = cfg->src;
vsp1->drm->inputs[rpf_index].compose = cfg->dst; vsp1->drm->inputs[rpf_index].compose = cfg->dst;
......
...@@ -26,7 +26,7 @@ int vsp1_du_setup_lif(struct device *dev, unsigned int width, ...@@ -26,7 +26,7 @@ int vsp1_du_setup_lif(struct device *dev, unsigned int width,
struct vsp1_du_atomic_config { struct vsp1_du_atomic_config {
u32 pixelformat; u32 pixelformat;
unsigned int pitch; unsigned int pitch;
dma_addr_t mem[2]; dma_addr_t mem[3];
struct v4l2_rect src; struct v4l2_rect src;
struct v4l2_rect dst; struct v4l2_rect dst;
unsigned int alpha; unsigned int alpha;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment