From: Bartosz Golaszewski Date: Fri, 18 Oct 2024 13:13:51 +0000 (+0200) Subject: media: v4l2-core: constify the class struct X-Git-Tag: v6.13-rc1~149^2~81 X-Git-Url: https://git.kernel.dk/?a=commitdiff_plain;h=2b744cb1a5a42d2428d9c39930be5c2fb89c588f;p=linux-block.git media: v4l2-core: constify the class struct All functions that take the class address as argument expect a const pointer so we can make the video class constant. Signed-off-by: Bartosz Golaszewski Signed-off-by: Hans Verkuil --- diff --git a/drivers/media/v4l2-core/v4l2-dev.c b/drivers/media/v4l2-core/v4l2-dev.c index dbd6fba93179..5bcaeeba4d09 100644 --- a/drivers/media/v4l2-core/v4l2-dev.c +++ b/drivers/media/v4l2-core/v4l2-dev.c @@ -229,7 +229,7 @@ static void v4l2_device_release(struct device *cd) v4l2_device_put(v4l2_dev); } -static struct class video_class = { +static const struct class video_class = { .name = VIDEO_NAME, .dev_groups = video_device_groups, };