media: imx-jpeg: Don't fill the description field in struct v4l2_fmtdesc
authorMing Qian <ming.qian@nxp.com>
Wed, 27 Apr 2022 09:25:58 +0000 (10:25 +0100)
committerMauro Carvalho Chehab <mchehab@kernel.org>
Mon, 20 Jun 2022 09:30:29 +0000 (10:30 +0100)
The core will fill this in v4l_fill_fmtdesc(),
ensuring consistent format description names.

Signed-off-by: Ming Qian <ming.qian@nxp.com>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
drivers/media/platform/nxp/imx-jpeg/mxc-jpeg.c

index f36b512bae51f21075cb7684521ad96ecd4d5312..de57101b5df37d36e3104586d48f50b4213073cb 100644 (file)
@@ -389,7 +389,6 @@ static int enum_fmt(const struct mxc_jpeg_fmt *mxc_formats, int n,
        if (i >= n)
                return -EINVAL;
 
-       strscpy(f->description, mxc_formats[i].name, sizeof(f->description));
        f->pixelformat = mxc_formats[i].fourcc;
 
        return 0;
@@ -1646,7 +1645,6 @@ static int mxc_jpeg_enum_fmt_vid_cap(struct file *file, void *priv,
                if (f->index)
                        return -EINVAL;
                f->pixelformat = q_data->fmt->fourcc;
-               strscpy(f->description, q_data->fmt->name, sizeof(f->description));
                return 0;
        }
 }