diff options
author | Prashant Laddha <prladdha@cisco.com> | 2015-09-22 11:27:28 -0300 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@osg.samsung.com> | 2015-11-17 15:05:14 -0200 |
commit | 8d7322f4f753644bd00d3a7a267c43f506a0b9c1 (patch) | |
tree | 727c1feb893e0ab3e9849ba730c0cf6b1066bc80 /drivers/media/v4l2-core | |
parent | 0d51ebd3f41f195e33ed8d9b9d67ed90f6e298ec (diff) |
[media] v4l2-dv-timings: add condition checks for reduced fps
Added a helper function to check necessary conditions required for
reduced fps. The reduced fps is supported for CVT and CEA861 timings.
CVT supports reduced fps only if reduced blanking v2 (indicated by
vsync = 8) is true. Whereas CEA861 supports reduced fps if
V4L2_DV_FL_CAN_REDUCE_FPS flag is true.
Signed-off-by: Prashant Laddha <prladdha@cisco.com>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
Diffstat (limited to 'drivers/media/v4l2-core')
-rw-r--r-- | drivers/media/v4l2-core/v4l2-dv-timings.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/media/v4l2-core/v4l2-dv-timings.c b/drivers/media/v4l2-core/v4l2-dv-timings.c index edb4125d1018..9926d521ea88 100644 --- a/drivers/media/v4l2-core/v4l2-dv-timings.c +++ b/drivers/media/v4l2-core/v4l2-dv-timings.c @@ -210,7 +210,12 @@ bool v4l2_find_dv_timings_cap(struct v4l2_dv_timings *t, fnc, fnc_handle) && v4l2_match_dv_timings(t, v4l2_dv_timings_presets + i, pclock_delta)) { + u32 flags = t->bt.flags & V4L2_DV_FL_REDUCED_FPS; + *t = v4l2_dv_timings_presets[i]; + if (can_reduce_fps(&t->bt)) + t->bt.flags |= flags; + return true; } } |