Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp296411pxj; Fri, 28 May 2021 04:19:21 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyqj6TRd+KqkN6dC4Dx8Q9TRRhRN+iG8+u58hgiV/JoX5i4yzCn0N2RH5C5aFSiIiZE23qL X-Received: by 2002:a17:906:32c3:: with SMTP id k3mr8155576ejk.95.1622200761259; Fri, 28 May 2021 04:19:21 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1622200761; cv=none; d=google.com; s=arc-20160816; b=i8QnvZOcsD5yY54yioeFxcxgjNR08UcpRSE6kFbV9cHTTQwe/lsv+XicUWq4aADS46 qw4UF3w2jUGkAgtBNGtg0v6AlSz1PlNF4ytQ1Dy5InZRowKh7AME75t0wjHUW0Y2gkzE Jiilae5pA56LAOjb7FJ0/wIw65UJlsWsN2uKfcD8i7rSrqAnISBqJo3QTyUtnKd6PbTH u/k7MaInEHD1E4XqsQJCg1syK9HIu71s5nsym7RMtALiJmgrctuOaf08jKNxwRnDx2QG QPy63zhToIipwBmku/rX82Sqje1VM5Pqx8/DtahyKDDh6Mj+dSvXv8KM/16ZCLeqj/p8 aXqQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:user-agent:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=nu/t+eRoAY6NtRobRU6f3fX1UwivEdiSbjMIVTJEhRI=; b=vym/yeRtp517dMzTxKiwgYqcVdK6EH8oY12App8QFlg63WudagHytpSZl7BBaLYTTo wue7AbSGs422flH1l74t3Brg1XR4j9W0wJhGmKYNE1mou4KqLwdlN9PUPR4mUir7eYwK 8u0rO7m/tc04Qzvu4fpPj4q5ixeG03E879T2w7CkNQd0t6hMBjCkRAhsCMPlQhfM2F7y uestKjDfUyX2WJUUxHd9zK8Bm3HKKit1THx2cxs9pxwfZq0s6XPuIE2Lr3ueqj227nKO tCtEkGApPEpjbsC+S4EqjqHgvwpvrk3iVsqSjcPIzq6VsQsgHRclzgVxnTyXkHD6PcN6 QiSA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@ti.com header.s=ti-com-17Q1 header.b=otvU6YfV; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id i12si4642938edr.394.2021.05.28.04.18.50; Fri, 28 May 2021 04:19:21 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@ti.com header.s=ti-com-17Q1 header.b=otvU6YfV; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235760AbhE1HZu (ORCPT + 99 others); Fri, 28 May 2021 03:25:50 -0400 Received: from fllv0015.ext.ti.com ([198.47.19.141]:60792 "EHLO fllv0015.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234447AbhE1HZt (ORCPT ); Fri, 28 May 2021 03:25:49 -0400 Received: from lelv0266.itg.ti.com ([10.180.67.225]) by fllv0015.ext.ti.com (8.15.2/8.15.2) with ESMTP id 14S7O5Sk130782; Fri, 28 May 2021 02:24:05 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ti.com; s=ti-com-17Q1; t=1622186645; bh=nu/t+eRoAY6NtRobRU6f3fX1UwivEdiSbjMIVTJEhRI=; h=Date:From:To:CC:Subject:References:In-Reply-To; b=otvU6YfVvMb0VmTfNfLokxvoHGITg5Yqi+Bg+rqneUxQeQU2hHXR1nsy8ADTT+ODj UKffTmjq+TT/E03XgDbRKrsSR7kdKMa9jK1D8xYlG2KiTEailf5y6KtRIkpnTc1V3R BGUBsVhf6bxHEjX7l5zTRtw1lu6o95vdcNLI32pA= Received: from DLEE113.ent.ti.com (dlee113.ent.ti.com [157.170.170.24]) by lelv0266.itg.ti.com (8.15.2/8.15.2) with ESMTPS id 14S7O5U8036400 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=FAIL); Fri, 28 May 2021 02:24:05 -0500 Received: from DLEE101.ent.ti.com (157.170.170.31) by DLEE113.ent.ti.com (157.170.170.24) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2176.2; Fri, 28 May 2021 02:24:05 -0500 Received: from fllv0039.itg.ti.com (10.64.41.19) by DLEE101.ent.ti.com (157.170.170.31) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2176.2 via Frontend Transport; Fri, 28 May 2021 02:24:05 -0500 Received: from localhost (ileax41-snat.itg.ti.com [10.172.224.153]) by fllv0039.itg.ti.com (8.15.2/8.15.2) with ESMTP id 14S7O4dV114575; Fri, 28 May 2021 02:24:04 -0500 Date: Fri, 28 May 2021 12:54:03 +0530 From: Pratyush Yadav To: Tomi Valkeinen CC: Maxime Ripard , Mauro Carvalho Chehab , Rob Herring , Kishon Vijay Abraham I , Vinod Koul , Peter Ujfalusi , Steve Longerbeam , Benoit Parrot , , , , , , Vignesh Raghavendra , Chunfeng Yun , Laurent Pinchart Subject: Re: [PATCH v2 10/18] media: cadence: csi2rx: Populate subdev devnode Message-ID: <20210528072401.2vdrtjdiepnr72vv@ti.com> References: <20210526152308.16525-1-p.yadav@ti.com> <20210526152308.16525-11-p.yadav@ti.com> <9c38a72c-18e8-1e54-b3b4-85ff5d47857a@ideasonboard.com> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Disposition: inline In-Reply-To: <9c38a72c-18e8-1e54-b3b4-85ff5d47857a@ideasonboard.com> User-Agent: NeoMutt/20171215 X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180 Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 28/05/21 10:16AM, Tomi Valkeinen wrote: > On 26/05/2021 18:23, Pratyush Yadav wrote: > > The devnode can be used by media-ctl and other userspace tools to > > perform configurations on the subdev. Without it, media-ctl returns > > ENOENT when setting format on the sensor subdev. > > > > Signed-off-by: Pratyush Yadav > > --- > > > > (no changes since v1) > > > > drivers/media/platform/cadence/cdns-csi2rx.c | 1 + > > 1 file changed, 1 insertion(+) > > > > diff --git a/drivers/media/platform/cadence/cdns-csi2rx.c b/drivers/media/platform/cadence/cdns-csi2rx.c > > index 1df21f462f3c..49bed63d5faa 100644 > > --- a/drivers/media/platform/cadence/cdns-csi2rx.c > > +++ b/drivers/media/platform/cadence/cdns-csi2rx.c > > @@ -613,6 +613,7 @@ static int csi2rx_probe(struct platform_device *pdev) > > csi2rx->pads[CSI2RX_PAD_SINK].flags = MEDIA_PAD_FL_SINK; > > for (i = CSI2RX_PAD_SOURCE_STREAM0; i < CSI2RX_PAD_MAX; i++) > > csi2rx->pads[i].flags = MEDIA_PAD_FL_SOURCE; > > + csi2rx->subdev.flags |= V4L2_SUBDEV_FL_HAS_DEVNODE; > > ret = media_entity_pads_init(&csi2rx->subdev.entity, CSI2RX_PAD_MAX, > > csi2rx->pads); > > > > I don't understand this one. There's nothing to configure in cdns-csi2rx > from userspace, as far as I can see, so why is the dev node needed? And why > would the lack of csi2rx dev node cause sensor subdev config to fail? Sensor config does not fail. But when I run media-ctl to set the format on /dev/media0, I get an error message that comes because the devnode for the bridge does not exist. I was not 100% sure about this patch but I figured if media-ctl expects it then it should be exposed. I don't mind dropping this patch. Just want to make sure what the right thing to do here is. Should every element of the pipeline have a devnode or not? -- Regards, Pratyush Yadav Texas Instruments Inc.