Received: by 2002:a05:7412:419a:b0:f3:1519:9f41 with SMTP id i26csp1383062rdh; Fri, 24 Nov 2023 11:07:14 -0800 (PST) X-Google-Smtp-Source: AGHT+IF8TMbRnBe+rbiOJ/cyGa83y93+3bn+8iV2Djk8QKRh7904YscvUqAO/WGTegKSCEWxnpL0 X-Received: by 2002:a54:440b:0:b0:3b6:daff:f502 with SMTP id k11-20020a54440b000000b003b6dafff502mr3799712oiw.58.1700852833731; Fri, 24 Nov 2023 11:07:13 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1700852833; cv=none; d=google.com; s=arc-20160816; b=HYdmD6I4v+lZQzwjwRcmurQNjjir2TCJtNadMePhVP7/ekxz8whTOWnpEhqsk/ewlX zWeMHXhfYka4vU8uLV239jwLy25SNBemFeGI6lLmiJEFCZTeeMlyDqjM8MdhkxE13HU4 Zq4OkX1RZQ9DDYY/zMMIHwWiybECh+HUAVmCZpt8nf0Lnw8I/eI6ef33e9Gw9cuXYYcH GRC8W/LfWpgovMmsPe6N+/Og7BBPthSrN3ARoT1dHIQCZK4abzxSkLdE+T6FdTSH0cRn q5G9c21o0pjBDqX8EKQmc0d519PM7psta5E7GDXFBQp91YrC//DdRoF3tAGf5bGEbVgj eI9g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=GrKnSqtf9ojWzcl4hPFMMp5Uk99fd/GGP0S4WyrYlzU=; fh=ruoDMs1XjTQg/Qi06uum55ZqjqXkyZve0PDlmh1knaY=; b=RjPnl18HhYP/tHGBOtok3YiZ8azUCFI2UtLSK4lhEW4MzvbhkPL4Brn6vJy+DllUxi EsELUfLpKH8vTz101WuTTCwWyk1sYbhJOl9qUBNOP5vaZ2usmNXUyfy/tbymMJps4PgN belrP2aXQap+Je+arss+p6PbpchBoCoeI6S6SzC99RLqbBCMSfsqWv2dzfkAmoA0MP+A A0BVxS6Q3wyhgiEmb78hv5+o7ISeHT+0fNIix/wULoIRC/NpLvISt5srRG83eQb7Ig7g 3tvY4f7UfPodFYbtaQ5lc2NZ8a6lyAZ5dVEK60K65DkFzulMaoBzKX2CvemSGfstoPA7 iVPw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass (test mode) header.i=@ideasonboard.com header.s=mail header.b=q5kbixME; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:2 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from agentk.vger.email (agentk.vger.email. [2620:137:e000::3:2]) by mx.google.com with ESMTPS id ef7-20020a056808234700b003ae067122aasi1538405oib.126.2023.11.24.11.07.13 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 24 Nov 2023 11:07:13 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:2 as permitted sender) client-ip=2620:137:e000::3:2; Authentication-Results: mx.google.com; dkim=pass (test mode) header.i=@ideasonboard.com header.s=mail header.b=q5kbixME; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:2 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by agentk.vger.email (Postfix) with ESMTP id A93648035E61; Fri, 24 Nov 2023 11:06:59 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at agentk.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1345950AbjKXTGe (ORCPT + 99 others); Fri, 24 Nov 2023 14:06:34 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54344 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1345941AbjKXTGd (ORCPT ); Fri, 24 Nov 2023 14:06:33 -0500 Received: from perceval.ideasonboard.com (perceval.ideasonboard.com [IPv6:2001:4b98:dc2:55:216:3eff:fef7:d647]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 122252703; Fri, 24 Nov 2023 11:06:32 -0800 (PST) Received: from pendragon.ideasonboard.com (213-243-189-158.bb.dnainternet.fi [213.243.189.158]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id 1BBEE1434; Fri, 24 Nov 2023 20:05:57 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1700852757; bh=yBfr7fbPq7YEO13cj00kaacBd89zDINg5rGSJKgDp4k=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=q5kbixMEN9ox7v8gcUk184bNSZqOlXt/TuzXyE/wMKQdStmA6JEuUFW+7dnTKtixo Zi+D9cQjZ4P/yk0XoXPzMUg2iY3yyEY5GqADP3by8nU3k/rHB5BRRW8FluKwoQcvOU yzw9YkFjFje5zWXe4livKPzSYluM8NYC8LCmuCYI= Date: Fri, 24 Nov 2023 21:06:36 +0200 From: Laurent Pinchart To: Tommaso Merciai Cc: linuxfancy@googlegroups.com, Sakari Ailus , Steve Longerbeam , Mauro Carvalho Chehab , linux-media@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] media: ov5640: add missing v4l2_subdev_init_finalize Message-ID: <20231124190636.GA15686@pendragon.ideasonboard.com> References: <20231124184913.2574925-1-tomm.merciai@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on agentk.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (agentk.vger.email [0.0.0.0]); Fri, 24 Nov 2023 11:06:59 -0800 (PST) On Fri, Nov 24, 2023 at 08:02:07PM +0100, Tommaso Merciai wrote: > On Fri, Nov 24, 2023 at 07:49:13PM +0100, Tommaso Merciai wrote: > > After the ov5640 configurations steps let's add v4l2_subdev_init_finalize > > that finalizes the initialization of the subdevice. > > > > References: > > - https://linuxtv.org/downloads/v4l-dvb-apis/driver-api/v4l2-subdev.html > > > > Signed-off-by: Tommaso Merciai > > --- > > drivers/media/i2c/ov5640.c | 6 ++++++ > > 1 file changed, 6 insertions(+) > > > > diff --git a/drivers/media/i2c/ov5640.c b/drivers/media/i2c/ov5640.c > > index 3f79a3b77044..338eea802ab8 100644 > > --- a/drivers/media/i2c/ov5640.c > > +++ b/drivers/media/i2c/ov5640.c > > @@ -3924,6 +3924,12 @@ static int ov5640_probe(struct i2c_client *client) > > if (ret) > > goto entity_cleanup; > > > > + ret = v4l2_subdev_init_finalize(&sensor->sd); > > + if (ret < 0) { > > + dev_err(dev, "subdev init error: %d\n", ret); > > + goto entity_cleanup; > > + } > > + > > ret = ov5640_sensor_resume(dev); > > if (ret) { > > dev_err(dev, "failed to power on\n"); > > Ignore this patch please. I forget the cleanup part. And you also forgot the conversion to the V4L2 subdev active state API :-) See commit e8a5b1df000e ("media: i2c: imx219: Use subdev active state") for an example. -- Regards, Laurent Pinchart