diff options
author | Jacopo Mondi <jacopo+renesas@jmondi.org> | 2021-06-16 15:46:03 +0300 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab+huawei@kernel.org> | 2021-06-17 12:27:41 +0300 |
commit | f78723eb627554213048918caa02a42cae66884e (patch) | |
tree | 5c1fabd3177cb33e041c1100755edcd431e35e04 /drivers/media/i2c/max9286.c | |
parent | 3de09c7ae70d544b13b4da74fa3ebd4c25eb9ab9 (diff) | |
download | linux-f78723eb627554213048918caa02a42cae66884e.tar.xz |
media: i2c: max9286: Rename reverse_channel_mv
Rename the reverse_channel_mv variable to init_rev_chan_mv as
the next patch will cache the reverse channel amplitude in
a new driver variable.
Signed-off-by: Jacopo Mondi <jacopo+renesas@jmondi.org>
Reviewed-by: Kieran Bingham <kieran.bingham+renesas@ideasonboard.com>
Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Diffstat (limited to 'drivers/media/i2c/max9286.c')
-rw-r--r-- | drivers/media/i2c/max9286.c | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/drivers/media/i2c/max9286.c b/drivers/media/i2c/max9286.c index e3c23916b926..22021e90e322 100644 --- a/drivers/media/i2c/max9286.c +++ b/drivers/media/i2c/max9286.c @@ -163,7 +163,8 @@ struct max9286_priv { unsigned int mux_channel; bool mux_open; - u32 reverse_channel_mv; + /* The initial reverse control channel amplitude. */ + u32 init_rev_chan_mv; struct v4l2_ctrl_handler ctrls; struct v4l2_ctrl *pixelrate; @@ -563,7 +564,7 @@ static int max9286_notify_bound(struct v4l2_async_notifier *notifier, * - Disable auto-ack as communication on the control channel are now * stable. */ - if (priv->reverse_channel_mv < 170) + if (priv->init_rev_chan_mv < 170) max9286_reverse_channel_setup(priv, 170); max9286_check_config_link(priv, priv->source_mask); @@ -972,7 +973,7 @@ static int max9286_setup(struct max9286_priv *priv) * only. This should be disabled after the mux is initialised. */ max9286_configure_i2c(priv, true); - max9286_reverse_channel_setup(priv, priv->reverse_channel_mv); + max9286_reverse_channel_setup(priv, priv->init_rev_chan_mv); /* * Enable GMSL links, mask unused ones and autodetect link @@ -1237,9 +1238,9 @@ static int max9286_parse_dt(struct max9286_priv *priv) if (of_property_read_u32(dev->of_node, "maxim,reverse-channel-microvolt", &reverse_channel_microvolt)) - priv->reverse_channel_mv = 170; + priv->init_rev_chan_mv = 170; else - priv->reverse_channel_mv = reverse_channel_microvolt / 1000U; + priv->init_rev_chan_mv = reverse_channel_microvolt / 1000U; priv->route_mask = priv->source_mask; |