From: Julia Lawall Date: Tue, 8 Aug 2017 10:58:29 +0000 (-0400) Subject: media: staging: media: atomisp: constify video_subdev structures X-Git-Tag: v5.15~9827^2~747 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=65058214f5c2ebe844916b92d1bece64fd00206e;p=platform%2Fkernel%2Flinux-starfive.git media: staging: media: atomisp: constify video_subdev structures These structures are both stored in fields of v4l2_subdev_ops structures, all of which are const, so these structures can be const as well. Done with the help of Coccinelle. Signed-off-by: Julia Lawall Signed-off-by: Mauro Carvalho Chehab --- diff --git a/drivers/staging/media/atomisp/i2c/ap1302.c b/drivers/staging/media/atomisp/i2c/ap1302.c index bacffbe..de687c6 100644 --- a/drivers/staging/media/atomisp/i2c/ap1302.c +++ b/drivers/staging/media/atomisp/i2c/ap1302.c @@ -1098,7 +1098,7 @@ static const struct v4l2_ctrl_config ctrls[] = { }, }; -static struct v4l2_subdev_sensor_ops ap1302_sensor_ops = { +static const struct v4l2_subdev_sensor_ops ap1302_sensor_ops = { .g_skip_frames = ap1302_g_skip_frames, }; diff --git a/drivers/staging/media/atomisp/i2c/mt9m114.c b/drivers/staging/media/atomisp/i2c/mt9m114.c index 448e072..36a0636 100644 --- a/drivers/staging/media/atomisp/i2c/mt9m114.c +++ b/drivers/staging/media/atomisp/i2c/mt9m114.c @@ -1806,7 +1806,7 @@ static const struct v4l2_subdev_video_ops mt9m114_video_ops = { .g_frame_interval = mt9m114_g_frame_interval, }; -static struct v4l2_subdev_sensor_ops mt9m114_sensor_ops = { +static const struct v4l2_subdev_sensor_ops mt9m114_sensor_ops = { .g_skip_frames = mt9m114_g_skip_frames, };