--- drivers/staging/media/imx/imx-media-capture.c | 18 +----------------- 1 file changed, 1 insertion(+), 17 deletions(-) diff --git a/drivers/staging/media/imx/imx-media-capture.c b/drivers/staging/media/imx/imx-media-capture.c index 256039c..688dd7a 100644 --- a/drivers/staging/media/imx/imx-media-capture.c +++ b/drivers/staging/media/imx/imx-media-capture.c @@ -126,28 +126,12 @@ static int capture_enum_frameintervals(struct file *file, void *fh, { struct capture_priv *priv = video_drvdata(file); const struct imx_media_pixfmt *cc; - struct v4l2_subdev_frame_interval_enum fie = { - .index = fival->index, - .pad = priv->src_sd_pad, - .width = fival->width, - .height = fival->height, - .which = V4L2_SUBDEV_FORMAT_ACTIVE, - }; - int ret; cc = imx_media_find_format(fival->pixel_format, CS_SEL_ANY, true); if (!cc) return -EINVAL; - fie.code = cc->codes[0]; - - ret = v4l2_subdev_call(priv->src_sd, pad, enum_frame_interval, - NULL, &fie); - if (ret) - return ret; - - fival->type = V4L2_FRMIVAL_TYPE_DISCRETE; - fival->discrete = fie.interval; + return v4l2_fill_frmivalenum_from_subdev(priv->src_sd, fival, cc->codes[0]); return 0; } -- 1.8.4