diff options
author | Hans Verkuil <hans.verkuil@cisco.com> | 2013-08-15 13:05:59 +0200 |
---|---|---|
committer | Mauro Carvalho Chehab <m.chehab@samsung.com> | 2013-08-24 09:26:27 +0200 |
commit | 11d034c8b60c3eebc2a12f5e99a200f55a786230 (patch) | |
tree | 145305d5d3f61259f6fd373185b55ed3a6fd7ad2 /drivers/media/i2c/ad9389b.c | |
parent | [media] v4l2-dv-timings: add v4l2_print_dv_timings helper (diff) | |
download | linux-11d034c8b60c3eebc2a12f5e99a200f55a786230.tar.xz linux-11d034c8b60c3eebc2a12f5e99a200f55a786230.zip |
[media] ad9389b/adv7604/ths8200: use new v4l2_print_dv_timings helper
These three drivers all have code to log the dv_timings contents. Replace
that code with the new helper function.
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
Diffstat (limited to 'drivers/media/i2c/ad9389b.c')
-rw-r--r-- | drivers/media/i2c/ad9389b.c | 17 |
1 files changed, 4 insertions, 13 deletions
diff --git a/drivers/media/i2c/ad9389b.c b/drivers/media/i2c/ad9389b.c index 92cdb25c73f7..1c6d352acfa0 100644 --- a/drivers/media/i2c/ad9389b.c +++ b/drivers/media/i2c/ad9389b.c @@ -443,20 +443,11 @@ static int ad9389b_log_status(struct v4l2_subdev *sd) vic_detect, vic_sent); } } - if (state->dv_timings.type == V4L2_DV_BT_656_1120) { - struct v4l2_bt_timings *bt = bt = &state->dv_timings.bt; - u32 frame_width = V4L2_DV_BT_FRAME_WIDTH(bt); - u32 frame_height = V4L2_DV_BT_FRAME_HEIGHT(bt); - u32 frame_size = frame_width * frame_height; - - v4l2_info(sd, "timings: %ux%u%s%u (%ux%u). Pix freq. = %u Hz. Polarities = 0x%x\n", - bt->width, bt->height, bt->interlaced ? "i" : "p", - frame_size > 0 ? (unsigned)bt->pixelclock / frame_size : 0, - frame_width, frame_height, - (unsigned)bt->pixelclock, bt->polarities); - } else { + if (state->dv_timings.type == V4L2_DV_BT_656_1120) + v4l2_print_dv_timings(sd->name, "timings: ", + &state->dv_timings, false); + else v4l2_info(sd, "no timings set\n"); - } return 0; } |