android_kernel_samsung_sm8650/drivers/media/platform/samsung
Laurent Pinchart 83c42283bf media: Prefer designated initializers over memset for subdev pad ops
[ Upstream commit e3a69496a1cde364c74a600d7a370179b58aed29 ]

Structures passed to subdev pad operations are all zero-initialized, but
not always with the same kind of code constructs. While most drivers
used designated initializers, which zero all the fields that are not
specified, when declaring variables, some use memset(). Those two
methods lead to the same end result, and, depending on compiler
optimizations, may even be completely equivalent, but they're not
consistent.

Improve coding style consistency by using designated initializers
instead of calling memset(). Where applicable, also move the variables
to inner scopes of for loops to ensure correct initialization in all
iterations.

Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: Lad Prabhakar <prabhakar.csengg@gmail.com> # For am437x
Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Reviewed-by: Tomi Valkeinen <tomi.valkeinen@ideasonboard.com>
Reviewed-by: Kieran Bingham <kieran.bingham+renesas@ideasonboard.com>
Reviewed-by: Philipp Zabel <p.zabel@pengutronix.de>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2023-05-24 17:32:36 +01:00
..
exynos4-is media: Prefer designated initializers over memset for subdev pad ops 2023-05-24 17:32:36 +01:00
exynos-gsc media: platform: exynos-gsc: fix typo in comment 2022-06-20 10:30:35 +01:00
s3c-camif media: mc: convert pipeline funcs to take media_pad 2022-09-24 09:22:30 +02:00
s5p-g2d media: Kconfig: cleanup VIDEO_DEV dependencies 2022-03-18 05:58:35 +01:00
s5p-jpeg media: platform: samsung: s5p-jpeg: replace ternary operator with max() 2022-06-20 10:30:31 +01:00
s5p-mfc media: s5p-mfc: Fix in register read and write for H264 2023-01-07 11:11:41 +01:00
Kconfig media: platform/*/Kconfig: make manufacturer menus more uniform 2022-03-18 05:58:35 +01:00
Makefile media: platform: Create vendor/{Makefile,Kconfig} files 2022-03-18 05:58:35 +01:00