From patchwork Wed Sep 15 12:02:35 2021
Content-Type: text/plain; charset="utf-8"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
X-Patchwork-Submitter: Pratyush Yadav
X-Patchwork-Id: 77019
X-Patchwork-Delegate: sakari.ailus@iki.fi
Received: from vger.kernel.org ([23.128.96.18])
by www.linuxtv.org with esmtp (Exim 4.92)
(envelope-from )
id 1mQTdH-00BELW-NC; Wed, 15 Sep 2021 12:03:20 +0000
Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand
id S237750AbhIOMEf (ORCPT + 1 other);
Wed, 15 Sep 2021 08:04:35 -0400
Received: from fllv0016.ext.ti.com ([198.47.19.142]:55202 "EHLO
fllv0016.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org
with ESMTP id S237772AbhIOMEd (ORCPT
);
Wed, 15 Sep 2021 08:04:33 -0400
Received: from lelv0266.itg.ti.com ([10.180.67.225])
by fllv0016.ext.ti.com (8.15.2/8.15.2) with ESMTP id 18FC3AlY085483;
Wed, 15 Sep 2021 07:03:10 -0500
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ti.com;
s=ti-com-17Q1; t=1631707390;
bh=kT+jpdgHUgB8WmXpX4IK0Fq/UD51pryiZLI1p3AwL4s=;
h=From:To:CC:Subject:Date:In-Reply-To:References;
b=pq/klfE0Nviq3z3e3+xMhqSQ+Gdx0kdUI/1WICeXTkUTGPUC8BTpEC1CjuSkTqYLz
nzZuyVLcfsGLnOKJ9PgpOyzBFB9ob7f06GhFKOK7ra4JtLk/k66GRMgykyFSNGDkGt
JUPuE/jDmA24jpXWNzJXuvr19+P+npWox8Qyjeso=
Received: from DFLE110.ent.ti.com (dfle110.ent.ti.com [10.64.6.31])
by lelv0266.itg.ti.com (8.15.2/8.15.2) with ESMTPS id 18FC3AhA048962
(version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=FAIL);
Wed, 15 Sep 2021 07:03:10 -0500
Received: from DFLE109.ent.ti.com (10.64.6.30) by DFLE110.ent.ti.com
(10.64.6.31) with Microsoft SMTP Server (version=TLS1_2,
cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2308.14; Wed, 15
Sep 2021 07:03:10 -0500
Received: from lelv0326.itg.ti.com (10.180.67.84) by DFLE109.ent.ti.com
(10.64.6.30) with Microsoft SMTP Server (version=TLS1_2,
cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2308.14 via
Frontend Transport; Wed, 15 Sep 2021 07:03:10 -0500
Received: from pratyush-OptiPlex-790.dhcp.ti.com (ileax41-snat.itg.ti.com
[10.172.224.153])
by lelv0326.itg.ti.com (8.15.2/8.15.2) with ESMTP id 18FC2fD7019246;
Wed, 15 Sep 2021 07:03:06 -0500
From: Pratyush Yadav
To: Mauro Carvalho Chehab
CC: Pratyush Yadav ,
Laurent Pinchart ,
Nikhil Devshatwar ,
Tomi Valkeinen ,
Vignesh Raghavendra , Benoit Parrot ,
Maxime Ripard , Rob Herring ,
Sakari Ailus , =?utf-8?q?Niklas_S=C3=B6derlun?=
=?utf-8?q?d?= ,
, ,
Subject: [PATCH v4 06/11] media: cadence: csi2rx: Populate subdev devnode
Date: Wed, 15 Sep 2021 17:32:35 +0530
Message-ID: <20210915120240.21572-7-p.yadav@ti.com>
X-Mailer: git-send-email 2.33.0
In-Reply-To: <20210915120240.21572-1-p.yadav@ti.com>
References: <20210915120240.21572-1-p.yadav@ti.com>
MIME-Version: 1.0
X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180
Precedence: bulk
List-ID:
X-Mailing-List: linux-media@vger.kernel.org
X-LSpam-Score: -4.8 (----)
X-LSpam-Report: No,
score=-4.8 required=5.0
tests=BAYES_00=-1.9,DKIMWL_WL_HIGH=0.001,DKIM_SIGNED=0.1,DKIM_VALID=-0.1,DKIM_VALID_AU=-0.1,HEADER_FROM_DIFFERENT_DOMAINS=0.5,MAILING_LIST_MULTI=-1,RCVD_IN_DNSWL_MED=-2.3
autolearn=ham autolearn_force=no
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
Reviewed-by: Laurent Pinchart
---
(no changes since v2)
Changes in v2:
- New in v2.
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 edd56c5f2e89..7c3183069db0 100644
--- a/drivers/media/platform/cadence/cdns-csi2rx.c
+++ b/drivers/media/platform/cadence/cdns-csi2rx.c
@@ -602,6 +602,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);