aboutsummaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorGravatar Sakari Ailus <sakari.ailus@linux.intel.com> 2020-09-30 13:49:15 +0200
committerGravatar Mauro Carvalho Chehab <mchehab+huawei@kernel.org> 2020-11-16 10:31:13 +0100
commit1726b976a6aa58d0182a3094db266072acf6bb66 (patch)
treeae69ddfdabf6b700ad01766f605be10d33b8dfb4 /drivers
parentmedia: dt-bindings: convert CODA VPU bindings to yaml (diff)
downloadlinux-1726b976a6aa58d0182a3094db266072acf6bb66.tar.gz
linux-1726b976a6aa58d0182a3094db266072acf6bb66.tar.bz2
linux-1726b976a6aa58d0182a3094db266072acf6bb66.zip
media: adv748x: Zero entire struct v4l2_fwnode_endpoint
The v4l2_fwnode_parse_endpoint() function can make use of defaults in multiple bus types. To use this feature, all callers must zero the rest of the fields of this struct, too. All other drivers appear to do that already apart from this one. Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com> Reviewed-by: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/media/i2c/adv748x/adv748x-core.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/media/i2c/adv748x/adv748x-core.c b/drivers/media/i2c/adv748x/adv748x-core.c
index 1fe7f97c6d52..ae8b7ebf3830 100644
--- a/drivers/media/i2c/adv748x/adv748x-core.c
+++ b/drivers/media/i2c/adv748x/adv748x-core.c
@@ -589,14 +589,13 @@ static int adv748x_parse_csi2_lanes(struct adv748x_state *state,
unsigned int port,
struct device_node *ep)
{
- struct v4l2_fwnode_endpoint vep;
+ struct v4l2_fwnode_endpoint vep = { .bus_type = V4L2_MBUS_CSI2_DPHY };
unsigned int num_lanes;
int ret;
if (port != ADV748X_PORT_TXA && port != ADV748X_PORT_TXB)
return 0;
- vep.bus_type = V4L2_MBUS_CSI2_DPHY;
ret = v4l2_fwnode_endpoint_parse(of_fwnode_handle(ep), &vep);
if (ret)
return ret;