From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-15.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id C11CFC07E94 for ; Fri, 4 Jun 2021 13:49:07 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id A4BC4613FF for ; Fri, 4 Jun 2021 13:49:07 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231189AbhFDNux (ORCPT ); Fri, 4 Jun 2021 09:50:53 -0400 Received: from perceval.ideasonboard.com ([213.167.242.64]:35150 "EHLO perceval.ideasonboard.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231183AbhFDNuw (ORCPT ); Fri, 4 Jun 2021 09:50:52 -0400 Received: from pendragon.ideasonboard.com (62-78-145-57.bb.dnainternet.fi [62.78.145.57]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id 23ED29E5; Fri, 4 Jun 2021 15:49:05 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1622814545; bh=J7kNVuVP/YcmA2Sit/QfOWAoaDF6mM7hQ6Y+vCwDCbY=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=kFuS0Z907LtLMagXNN67X+GWZ2hZQI8CEhISpnNecqH2HGhClLLLX5BLUQJbU5NFU gr+syxaieW3NDbaAfimCTWqA2ZFS0JJr71qkzomu1dQ0AqDck+MbxwRs7oMOdx5Ssj laQOg//KApOL0n28sxnZnpRT7NRSQGorATdnXsvA= Date: Fri, 4 Jun 2021 16:48:52 +0300 From: Laurent Pinchart To: Tomi Valkeinen Cc: Pratyush Yadav , Lokesh Vutla , linux-media@vger.kernel.org Subject: Re: [PATCH v3 22/38] media: ti-vpe: cal: set field always to V4L2_FIELD_NONE Message-ID: References: <20210524110909.672432-1-tomi.valkeinen@ideasonboard.com> <20210524110909.672432-23-tomi.valkeinen@ideasonboard.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20210524110909.672432-23-tomi.valkeinen@ideasonboard.com> Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org Hi Tomi, Thank you for the patch. On Mon, May 24, 2021 at 02:08:53PM +0300, Tomi Valkeinen wrote: > cal_camerarx_sd_set_fmt() accepts any value for the format field, but > there should be no reason to have any other value accepted than > V4L2_FIELD_NONE. So set the field always to V4L2_FIELD_NONE. > > Signed-off-by: Tomi Valkeinen Reviewed-by: Laurent Pinchart > --- > drivers/media/platform/ti-vpe/cal-camerarx.c | 6 ++---- > 1 file changed, 2 insertions(+), 4 deletions(-) > > diff --git a/drivers/media/platform/ti-vpe/cal-camerarx.c b/drivers/media/platform/ti-vpe/cal-camerarx.c > index a8cca30f3f51..f2ea2bdb9ea3 100644 > --- a/drivers/media/platform/ti-vpe/cal-camerarx.c > +++ b/drivers/media/platform/ti-vpe/cal-camerarx.c > @@ -705,10 +705,7 @@ static int cal_camerarx_sd_set_fmt(struct v4l2_subdev *sd, > if (!fmtinfo) > fmtinfo = &cal_formats[0]; > > - /* > - * Clamp the size, update the code. The field and colorspace are > - * accepted as-is. > - */ > + /* Clamp the size, update the code. The colorspace is accepted as-is. */ > bpp = ALIGN(fmtinfo->bpp, 8); > > format->format.width = clamp_t(unsigned int, format->format.width, > @@ -718,6 +715,7 @@ static int cal_camerarx_sd_set_fmt(struct v4l2_subdev *sd, > CAL_MIN_HEIGHT_LINES, > CAL_MAX_HEIGHT_LINES); > format->format.code = fmtinfo->code; > + format->format.field = V4L2_FIELD_NONE; > > /* Store the format and propagate it to the source pad. */ > fmt = cal_camerarx_get_pad_format(phy, sd_state, -- Regards, Laurent Pinchart