Re: [PATCH v3 5/5] media: iris: configure DMA device for vb2 queue on OUTPUT plane

Bryan O'Donoghue
2025-06-27T17:08:45Z

On 27/06/2025 16:48, Vikash Garodia wrote:
> While setting up the vb2 queues, assign "non_pixel" device to manage
> OUTPUT plane buffers i.e bitstream buffers incase of decoder. It prefers
> the non_pixel device(np_dev) when available, falling back to core->dev
> otherwise.
>
> Signed-off-by: Vikash Garodia <quic_vgarodia@quicinc.com>
> ---
> drivers/media/platform/qcom/iris/iris_vb2.c | 4 ++++
> 1 file changed, 4 insertions(+)
>
> diff --git a/drivers/media/platform/qcom/iris/iris_vb2.c b/drivers/media/platform/qcom/iris/iris_vb2.c
> index cdf11feb590b5cb7804db3fcde7282fb1f9f1a1e..01cc337970400d48063c558c1ac039539dbcbaba 100644
> --- a/drivers/media/platform/qcom/iris/iris_vb2.c
> +++ b/drivers/media/platform/qcom/iris/iris_vb2.c
> @@ -159,6 +159,10 @@ int iris_vb2_queue_setup(struct vb2_queue *q,
> *num_planes = 1;
> sizes[0] = f->fmt.pix_mp.plane_fmt[0].sizeimage;
>
> + if (q->type == V4L2_BUF_TYPE_VIDEO_OUTPUT ||
> + q->type == V4L2_BUF_TYPE_VIDEO_OUTPUT_MPLANE)
> + q->dev = core->np_dev ? core->np_dev : core->dev;
> +
> unlock:
> mutex_unlock(&inst->lock);
>
>

q->dev = core->dev;

if (thing || thing_else)
q->dev = core->np_dev;

---
bod