summaryrefslogtreecommitdiffstats
path: root/drivers/media/i2c/adv7180.c
diff options
context:
space:
mode:
authorNiklas Söderlund2016-04-02 19:42:18 +0200
committerMauro Carvalho Chehab2016-04-20 21:06:05 +0200
commitd0fadc869349e0469abc80109d4251be432736bd (patch)
tree6c6b6a16bf7c4ab0a136abac7b8f431e3f7dff0d /drivers/media/i2c/adv7180.c
parent[media] Staging: media: bcm2048: defined region_configs[] array as const array (diff)
downloadkernel-qcow2-linux-d0fadc869349e0469abc80109d4251be432736bd.tar.gz
kernel-qcow2-linux-d0fadc869349e0469abc80109d4251be432736bd.tar.xz
kernel-qcow2-linux-d0fadc869349e0469abc80109d4251be432736bd.zip
[media] adv7180: Add g_std operation
Add support to get the standard to the adv7180 driver. Signed-off-by: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
Diffstat (limited to 'drivers/media/i2c/adv7180.c')
-rw-r--r--drivers/media/i2c/adv7180.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/drivers/media/i2c/adv7180.c b/drivers/media/i2c/adv7180.c
index ff57c1dcb8af..d680d7656e2f 100644
--- a/drivers/media/i2c/adv7180.c
+++ b/drivers/media/i2c/adv7180.c
@@ -434,6 +434,15 @@ out:
return ret;
}
+static int adv7180_g_std(struct v4l2_subdev *sd, v4l2_std_id *norm)
+{
+ struct adv7180_state *state = to_state(sd);
+
+ *norm = state->curr_norm;
+
+ return 0;
+}
+
static int adv7180_set_power(struct adv7180_state *state, bool on)
{
u8 val;
@@ -719,6 +728,7 @@ static int adv7180_g_mbus_config(struct v4l2_subdev *sd,
static const struct v4l2_subdev_video_ops adv7180_video_ops = {
.s_std = adv7180_s_std,
+ .g_std = adv7180_g_std,
.querystd = adv7180_querystd,
.g_input_status = adv7180_g_input_status,
.s_routing = adv7180_s_routing,