upstream: [media] v4l2-dv-timings: fix CVT calculation
authorMartin Bugge <marbugge@cisco.com>
Wed, 14 Aug 2013 07:58:38 +0000 (04:58 -0300)
committerChanho Park <chanho61.park@samsung.com>
Tue, 18 Nov 2014 02:55:19 +0000 (11:55 +0900)
commit507a7d9aec3f00fd3e4aa30040a570b13141995c
tree675bb9694ab8ab42f13141a42d36350c3c13ab5a
parent89982c944c9bee6ee5ac2b29ef9fa8f8c86a23f1
upstream: [media] v4l2-dv-timings: fix CVT calculation

This patch fixes two errors that caused incorrect format detections:
The first bug is in the calculation of the vertical backporch: the combined
period of vsync and backporch must *exceed* a certain minimum value, and not
be equal to it.
The second bug is a rounding error in the reduced blanking calculation:
expand the ideal_duty_cylce to be in parts per ten thousand to avoid
rounding errors.

Signed-off-by: Martin Bugge <marbugge@cisco.com>
Cc: Mats Randgaard <matrandg@cisco.com>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
drivers/media/v4l2-core/v4l2-dv-timings.c