media: staging: media: rkvdec: Constify static struct v4l2_m2m_ops

The only usage of rkvdec_m2m_ops is to pass its address to v4l2_m2m_init(),
which takes a pointer to const v4l2_m2m_ops as argument. Make it const
to allow the compiler to put it in read-only memory.

Signed-off-by: Rikard Falkeborn <rikard.falkeborn@gmail.com>
Reviewed-by: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar>
Reviewed-by: Kieran Bingham <kieran.bingham+renesas@ideasonboard.com>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
This commit is contained in:
Rikard Falkeborn 2021-10-13 00:11:44 +02:00 committed by Mauro Carvalho Chehab
parent 61b20ddec9
commit 3016296016

View File

@ -712,7 +712,7 @@ static void rkvdec_device_run(void *priv)
rkvdec_job_finish(ctx, VB2_BUF_STATE_ERROR);
}
static struct v4l2_m2m_ops rkvdec_m2m_ops = {
static const struct v4l2_m2m_ops rkvdec_m2m_ops = {
.device_run = rkvdec_device_run,
};