diff options
author | Xia Jiang <xia.jiang@mediatek.com> | 2020-08-14 10:11:37 +0300 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab+huawei@kernel.org> | 2020-08-28 16:18:56 +0300 |
commit | cc5fd1668f5fdddce4f367ec10514674a01fe09c (patch) | |
tree | 950d2a7a90c1ebddc333f0aae3b78a4476415128 /drivers/media/platform/mtk-jpeg | |
parent | 6869a2de456a588a3c6b7bf123306faa3d490417 (diff) | |
download | linux-cc5fd1668f5fdddce4f367ec10514674a01fe09c.tar.xz |
media: platform: Change the fixed device node number to unfixed value
The driver can be instantiated multiple times, e.g. for a decoder and
an encoder. Moreover, other drivers could coexist on the same system.
This makes the static video node number assignment pointless, so switch
to automatic assignment instead.
Reviewed-by: Tomasz Figa <tfiga@chromium.org>
Signed-off-by: Xia Jiang <xia.jiang@mediatek.com>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Diffstat (limited to 'drivers/media/platform/mtk-jpeg')
-rw-r--r-- | drivers/media/platform/mtk-jpeg/mtk_jpeg_core.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/media/platform/mtk-jpeg/mtk_jpeg_core.c b/drivers/media/platform/mtk-jpeg/mtk_jpeg_core.c index f4264f429df9..feac4057c0b7 100644 --- a/drivers/media/platform/mtk-jpeg/mtk_jpeg_core.c +++ b/drivers/media/platform/mtk-jpeg/mtk_jpeg_core.c @@ -1154,7 +1154,7 @@ static int mtk_jpeg_probe(struct platform_device *pdev) jpeg->dec_vdev->device_caps = V4L2_CAP_STREAMING | V4L2_CAP_VIDEO_M2M_MPLANE; - ret = video_register_device(jpeg->dec_vdev, VFL_TYPE_VIDEO, 3); + ret = video_register_device(jpeg->dec_vdev, VFL_TYPE_VIDEO, -1); if (ret) { v4l2_err(&jpeg->v4l2_dev, "Failed to register video device\n"); goto err_dec_vdev_register; |