The IMX219 datasheet uses the terms FRM_LENGTH and LINE_LENGTH instead of VTS/HTS. Signed-off-by: Jai Luthra <jai.luthra@xxxxxxxxxxxxxxxx> --- drivers/media/i2c/imx219.c | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/drivers/media/i2c/imx219.c b/drivers/media/i2c/imx219.c index 0486bbc046cb9c36afd911eb799c1b010a01d496..6c4a72d88cdd2bdd05f2273786110c9f2818e44f 100644 --- a/drivers/media/i2c/imx219.c +++ b/drivers/media/i2c/imx219.c @@ -70,9 +70,8 @@ #define IMX219_EXPOSURE_MAX 65535 /* V_TIMING internal */ -#define IMX219_REG_VTS CCI_REG16(0x0160) -#define IMX219_VTS_MAX 0xffff - +#define IMX219_REG_FRM_LENGTH CCI_REG16(0x0160) +#define IMX219_FLL_MAX 0xffff #define IMX219_VBLANK_MIN 32 /* HBLANK control - read only */ @@ -418,7 +417,7 @@ static int imx219_set_ctrl(struct v4l2_ctrl *ctrl) imx219->hflip->val | imx219->vflip->val << 1, &ret); break; case V4L2_CID_VBLANK: - cci_write(imx219->regmap, IMX219_REG_VTS, + cci_write(imx219->regmap, IMX219_REG_FRM_LENGTH, format->height + ctrl->val, &ret); break; case V4L2_CID_TEST_PATTERN_RED: @@ -493,7 +492,7 @@ static int imx219_init_controls(struct imx219 *imx219) /* Initial vblank/hblank/exposure parameters based on current mode */ imx219->vblank = v4l2_ctrl_new_std(ctrl_hdlr, &imx219_ctrl_ops, V4L2_CID_VBLANK, IMX219_VBLANK_MIN, - IMX219_VTS_MAX - mode->height, 1, + IMX219_FLL_MAX - mode->height, 1, mode->vts_def - mode->height); hblank = IMX219_PPL_DEFAULT - mode->width; imx219->hblank = v4l2_ctrl_new_std(ctrl_hdlr, &imx219_ctrl_ops, @@ -847,7 +846,7 @@ static int imx219_set_pad_format(struct v4l2_subdev *sd, /* Update limits and set FPS to default */ __v4l2_ctrl_modify_range(imx219->vblank, IMX219_VBLANK_MIN, - IMX219_VTS_MAX - mode->height, 1, + IMX219_FLL_MAX - mode->height, 1, mode->vts_def - mode->height); __v4l2_ctrl_s_ctrl(imx219->vblank, mode->vts_def - mode->height); -- 2.47.1