From: Michael Tretter Date: Thu, 3 Dec 2020 11:00:56 +0000 (+0100) Subject: media: allegro: use handler_setup to configure channel X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=21de56fa0789cf1c7e9a6d946f45c79ead04ffd4;p=linux.git media: allegro: use handler_setup to configure channel v4l2_ctrl_handler_setup() calls s_ctrl for all controls of the handler. This ensures that the channel is initialized using the default values of the v4l2-ctrls. Signed-off-by: Michael Tretter Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab --- diff --git a/drivers/media/platform/allegro-dvt/allegro-core.c b/drivers/media/platform/allegro-dvt/allegro-core.c index d7b1cc2b9e6eb..a9a9e9bb04015 100644 --- a/drivers/media/platform/allegro-dvt/allegro-core.c +++ b/drivers/media/platform/allegro-dvt/allegro-core.c @@ -2520,6 +2520,8 @@ static int allegro_open(struct file *file) v4l2_ctrl_cluster(3, &channel->mpeg_video_bitrate_mode); + v4l2_ctrl_handler_setup(handler); + channel->mcu_channel_id = -1; channel->user_id = -1;