From patchwork Mon Feb 14 18:43:13 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jacopo Mondi X-Patchwork-Id: 12745998 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 7B652C433EF for ; Mon, 14 Feb 2022 18:44:17 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=HCdnljyRXeEjxiMM7hWYUZBCYSLLF1QeQHlle6dE+Y8=; b=IvWeA+ZE0JNlzL oBMbf++uckRMdE1q/qgOD8yqoHc1ObeqN9CTmjugInO2vm1A4hmUc8904SDvyNChoH4iv2Drs1hZp qG9kKixMnAPAvcsfQsXUllX6ymCA893QVj0q8+NA5/eW9Ewkm7szuio3AjZ1aYev+Pbac4hfRlccQ 8c0/B1F0E3lKHLCuA3jv6tJD4KIlzdbBS9EO5Jh0EbVl/nStI4M+TSvr44dFuj06z+oa/3BTM4sfW KLE1ZC+E8kziAzfREPNF2X/VDEaWqg318awuuOpalqrXi6qqnA6Bbn6LhXnWKV6yzwa52xbZUUugU XVYZSUGtpQBEq+WgZycw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1nJgJa-00GZIq-7H; Mon, 14 Feb 2022 18:43:10 +0000 Received: from relay5-d.mail.gandi.net ([2001:4b98:dc4:8::225]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1nJgIy-00GYxj-NV for linux-arm-kernel@lists.infradead.org; Mon, 14 Feb 2022 18:42:34 +0000 Received: (Authenticated sender: jacopo@jmondi.org) by mail.gandi.net (Postfix) with ESMTPSA id A628A1C0009; Mon, 14 Feb 2022 18:42:27 +0000 (UTC) From: Jacopo Mondi To: slongerbeam@gmail.com, p.zabel@pengutronix.de, shawnguo@kernel.org, s.hauer@pengutronix.de, festevam@gmail.com, mchehab@kernel.org, hverkuil-cisco@xs4all.nl, laurent.pinchart@ideasonboard.com, martin.kepplinger@puri.sm, rmfrfs@gmail.com, xavier.roumegue@oss.nxp.com, alexander.stein@ew.tq-group.com, dorota.czaplejewicz@puri.sm Cc: kernel@pengutronix.de, linux-imx@nxp.com, linux-media@vger.kernel.org, linux-staging@lists.linux.dev, linux-arm-kernel@lists.infradead.org, Jacopo Mondi Subject: [PATCH 3/8] staging: media: imx: Add more compatible strings Date: Mon, 14 Feb 2022 19:43:13 +0100 Message-Id: <20220214184318.409208-4-jacopo@jmondi.org> X-Mailer: git-send-email 2.35.0 In-Reply-To: <20220214184318.409208-1-jacopo@jmondi.org> References: <20220214184318.409208-1-jacopo@jmondi.org> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220214_104232_933435_87233BEB X-CRM114-Status: GOOD ( 11.64 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org The imx7-media-csi driver controls the CSI (CMOS Sensor Interface) peripheral available on several SoC of different generations. The current situation when it comes to compatible strings is rather confused: - Bindings document imx6ul, imx7 and imx8mm - Driver supports imx6ul, imx7 and imx8mq - The IMX8MM and IMX8MQ DTS use the correct compatible strings with a fallback to the generic "imx7-csi" identifier: arch/arm64/boot/dts/freescale/imx8mq.dtsi: compatible = "fsl,imx8mq-csi", arch/arm64/boot/dts/freescale/imx8mm.dtsi: compatible = "fsl,imx8mm-csi", Tidy-up the situation by adding the IMX8MQ compatible string to the bindings documentation andathe IMX8MM identifier to the driver, to allow to distinguish the SoC the CSI peripheral is integrated on in the following patches. Signed-off-by: Jacopo Mondi --- Documentation/devicetree/bindings/media/nxp,imx7-csi.yaml | 1 + drivers/staging/media/imx/imx7-media-csi.c | 2 ++ 2 files changed, 3 insertions(+) diff --git a/Documentation/devicetree/bindings/media/nxp,imx7-csi.yaml b/Documentation/devicetree/bindings/media/nxp,imx7-csi.yaml index 4f7b78265336..0f1505d85111 100644 --- a/Documentation/devicetree/bindings/media/nxp,imx7-csi.yaml +++ b/Documentation/devicetree/bindings/media/nxp,imx7-csi.yaml @@ -21,6 +21,7 @@ properties: - fsl,imx7-csi - fsl,imx6ul-csi - items: + - const: fsl,imx8mq-csi - const: fsl,imx8mm-csi - const: fsl,imx7-csi diff --git a/drivers/staging/media/imx/imx7-media-csi.c b/drivers/staging/media/imx/imx7-media-csi.c index 32311fc0e2a4..59100e409709 100644 --- a/drivers/staging/media/imx/imx7-media-csi.c +++ b/drivers/staging/media/imx/imx7-media-csi.c @@ -162,6 +162,7 @@ enum imx_csi_model { IMX7_CSI_IMX7 = 0, IMX7_CSI_IMX8MQ, + IMX7_CSI_IMX8MM, }; struct imx7_csi { @@ -1277,6 +1278,7 @@ static int imx7_csi_remove(struct platform_device *pdev) static const struct of_device_id imx7_csi_of_match[] = { { .compatible = "fsl,imx8mq-csi", .data = (void *)IMX7_CSI_IMX8MQ }, + { .compatible = "fsl,imx8mm-csi", .data = (void *)IMX7_CSI_IMX8MM }, { .compatible = "fsl,imx7-csi", .data = (void *)IMX7_CSI_IMX7 }, { .compatible = "fsl,imx6ul-csi", .data = (void *)IMX7_CSI_IMX7 }, { },