From patchwork Fri Nov 17 09:28:11 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jai Luthra X-Patchwork-Id: 166030 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:9910:0:b0:403:3b70:6f57 with SMTP id i16csp406110vqn; Fri, 17 Nov 2023 01:31:25 -0800 (PST) X-Google-Smtp-Source: AGHT+IGBSoUweZSbn4Jspf6sNIQuAUQ5f5u7AIBAcNfGK+f30PHPxiXxqBqUHuZANivboCtCPi0w X-Received: by 2002:a05:6a00:18a4:b0:6c4:b182:f3d9 with SMTP id x36-20020a056a0018a400b006c4b182f3d9mr20825181pfh.21.1700213485355; Fri, 17 Nov 2023 01:31:25 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1700213485; cv=none; d=google.com; s=arc-20160816; b=RxHr7VVUhsBQIvzVLxA6ZRnEmS0y1z/8Tc5ceRU+c8PRb6lfjLVXsfFNV64tpls0io IBcYERVzXX406i3vOcHgh6qkf8h0uXM4XmxO+XwTJPnp51v/h564B4xUXtX3KFtaTTvb Vir9O/dNcCxJ0CC967JJdFzDMBUgn0EYvPr100V+2bu9a72vzf5een2c58foSzEpUL3n FjnQ7OageWe/zs0McjCdF9kmvAZdGVrjayhkKCY/23R1a1P3rf0G6fQ3HxH5Lplg7lMz YMg2zmAYljgAwkMkVbNE58zq9Kyu7G45NHVrLX1NVzO1JGT73GieBv24ivSeg88YDKSu bCJg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:in-reply-to:references:message-id :content-transfer-encoding:mime-version:subject:date:from :dkim-signature; bh=6ItgAaMkCxt60XJc1WHuFhFNITAxxpb0vOwKj0LoWdI=; fh=gjf50MpIeI4y7DsLDR8KPyZZDZn0L+YVyMCrolRSpx0=; b=R+1HTpefxUcT+3L7/5cnXxwX3Z1rAW263pk1mkwYJyPFGaKTLp3hLN1PqMnICfBgT6 tPwBIxPXejbYaReO0IkYZCY6Td6yVJZwpdSxCsxwu/lPu0su+nfnEKzY2sFkxFKro81I wE4P1mgeivThuBJgcFUZqdGn7WDCSJMNrAFiLEPDfFS7WhCL78DznA8Wb777CFlmUTM7 U2Le859SCXZsfWthdweN8yjgC0Ib8oD9jw7FytPzu1dgwl8VOL98UY2WN/QgT1iLc8D3 2dYCv+atCisDYR7KFQNgyk1uXuNZOgE6BNYqwEH0u1gKIndAJSWnUZjVuC1IEi5TU4+u j+3w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@ti.com header.s=ti-com-17Q1 header.b=UlW6ZzHt; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.35 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Received: from groat.vger.email (groat.vger.email. [23.128.96.35]) by mx.google.com with ESMTPS id t21-20020a056a0021d500b006be264b2734si1600076pfj.29.2023.11.17.01.31.25 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 17 Nov 2023 01:31:25 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.35 as permitted sender) client-ip=23.128.96.35; Authentication-Results: mx.google.com; dkim=pass header.i=@ti.com header.s=ti-com-17Q1 header.b=UlW6ZzHt; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.35 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by groat.vger.email (Postfix) with ESMTP id 88E4D80A2202; Fri, 17 Nov 2023 01:30:51 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at groat.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1345738AbjKQJaT (ORCPT + 30 others); Fri, 17 Nov 2023 04:30:19 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45020 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1345658AbjKQJaH (ORCPT ); Fri, 17 Nov 2023 04:30:07 -0500 Received: from fllv0016.ext.ti.com (fllv0016.ext.ti.com [198.47.19.142]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 8E8D1D4F; Fri, 17 Nov 2023 01:30:02 -0800 (PST) Received: from lelv0266.itg.ti.com ([10.180.67.225]) by fllv0016.ext.ti.com (8.15.2/8.15.2) with ESMTP id 3AH9Ta7a083279; Fri, 17 Nov 2023 03:29:36 -0600 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ti.com; s=ti-com-17Q1; t=1700213376; bh=6ItgAaMkCxt60XJc1WHuFhFNITAxxpb0vOwKj0LoWdI=; h=From:Date:Subject:References:In-Reply-To:To:CC; b=UlW6ZzHthl4vI3IfNBBnCmBsOfXkfzH9hxPpGzYJWGvaYangZLSnIeidxcuVWDapG jAGYJtm6Y4W05A8NG0rrv3STtCpxCjQLqemH8r2pai0W7UzTIkc4BiQ/pox7PlIuG1 +UVwWAN/C1K1+2M959P+Eoe4BqTfmM3k7kei1edE= Received: from DFLE107.ent.ti.com (dfle107.ent.ti.com [10.64.6.28]) by lelv0266.itg.ti.com (8.15.2/8.15.2) with ESMTPS id 3AH9TaVp075663 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=FAIL); Fri, 17 Nov 2023 03:29:36 -0600 Received: from DFLE101.ent.ti.com (10.64.6.22) by DFLE107.ent.ti.com (10.64.6.28) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2507.23; Fri, 17 Nov 2023 03:29:36 -0600 Received: from fllv0039.itg.ti.com (10.64.41.19) by DFLE101.ent.ti.com (10.64.6.22) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2507.23 via Frontend Transport; Fri, 17 Nov 2023 03:29:36 -0600 Received: from localhost (ileaxei01-snat2.itg.ti.com [10.180.69.6]) by fllv0039.itg.ti.com (8.15.2/8.15.2) with ESMTP id 3AH9TZdu017766; Fri, 17 Nov 2023 03:29:36 -0600 From: Jai Luthra Date: Fri, 17 Nov 2023 14:58:11 +0530 Subject: [PATCH v2 3/9] arm64: dts: ti: Enable CSI-RX on AM62A MIME-Version: 1.0 Message-ID: <20231117-csi_dts-v2-3-bf4312194a6b@ti.com> References: <20231117-csi_dts-v2-0-bf4312194a6b@ti.com> In-Reply-To: <20231117-csi_dts-v2-0-bf4312194a6b@ti.com> To: Catalin Marinas , Will Deacon , Nishanth Menon , Vignesh Raghavendra , Tero Kristo , Rob Herring , Krzysztof Kozlowski , Conor Dooley CC: , , , Aradhya Bhatia , Devarsh Thakkar , Vaishnav Achath , Julien Massot , Martyn Welch , Matthias Schiffer , Jai Luthra X-Mailer: b4 0.12.4 X-Developer-Signature: v=1; a=openpgp-sha256; l=3544; i=j-luthra@ti.com; h=from:subject:message-id; bh=UdyZV1rZtSB6XPR1HDnodj8ZtnvMZqzU69UiUMbOr4Y=; b=owEBbQKS/ZANAwAIAUPekfkkmnFFAcsmYgBlVzJuB8Xd1FOnpIN3Z9fQLJkAL1nuj9uftwgPX +g+NOPKpLKJAjMEAAEIAB0WIQRN4NgY5dV16NRar8VD3pH5JJpxRQUCZVcybgAKCRBD3pH5JJpx RSOmD/4ySbeyXBSj9FilWTs2EyMaNB8TQjvxQvGfjjwMCSgt6AG3sH04O4uUnU446505NoA7mPK gAosanwA8my5cvm6R6O169MoB8BjN0AmMYOTMeMzIbnth4wpt4brjz8huChoIVqbfaqkBIIQLyx LeD+nU/t1PoSzTi1L9XYTFqlIxHbjnI43+QaaqOYjQ1oQPuGuU1bR6BGzcb0n4yTx40EpIQMxg5 b3y45gXB3+bHEcJV7WoW9wBKHw8/5i8vJDl8D/lrAwCmNTWrPWmJHLGXwpsFvB7+SCpHylGbikY BP8PsU6dHTF/JV6ixrW7jGw8Ifz6GkF+mYIsuhRuR8JPALVyDRtIpoHDV+ZeFbCnyNo/kTpL12A t/+mkirLyxvOX4EKfXaQgrMSltfjS2BgXHSbhD39en0c3VjAbeKcyDfXcW4VkIGYgFc30hwQU+d gPdwDmHvToYq5G6sWKesihnQIQbx4NLSPwYRjlVKqJk4rZfRjgrcvQ6JmYekDk7t+kCDkmrzSPQ QoniDoeF+xeBBf0NchnThZitK/BnStXyp91s6xpROCi9AtyA4edEo1VIPBK+GlSKHxLmeDm839g uRxFGZ87Tnmy/McDeJMOCPVrVow8KyUEwdU8NZ3QHc6lMer79L+qg6fCh7zr86p4qV9aL7lW8VH 9HsZDA68rvN4pEw== X-Developer-Key: i=j-luthra@ti.com; a=openpgp; fpr=4DE0D818E5D575E8D45AAFC543DE91F9249A7145 X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180 X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIMWL_WL_HIGH,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 groat.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 (groat.vger.email [0.0.0.0]); Fri, 17 Nov 2023 01:30:51 -0800 (PST) X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1782803055558800912 X-GMAIL-MSGID: 1782803055558800912 Add nodes for Cadence DPHY, CSI2RX and TI's pixel-grabbing wrapper. AM62A uses a dedicated BCDMA instance for CSI-RX traffic, so enable that as well. Signed-off-by: Jai Luthra --- arch/arm64/boot/dts/ti/k3-am62a-main.dtsi | 99 +++++++++++++++++++++++++++++++ 1 file changed, 99 insertions(+) diff --git a/arch/arm64/boot/dts/ti/k3-am62a-main.dtsi b/arch/arm64/boot/dts/ti/k3-am62a-main.dtsi index 4ae7fdc5221b..ea70d78eb132 100644 --- a/arch/arm64/boot/dts/ti/k3-am62a-main.dtsi +++ b/arch/arm64/boot/dts/ti/k3-am62a-main.dtsi @@ -144,6 +144,44 @@ main_pktdma: dma-controller@485c0000 { }; }; + dmss_csi: bus@4e000000 { + compatible = "simple-bus"; + #address-cells = <2>; + #size-cells = <2>; + dma-ranges; + ranges = <0x00 0x4e000000 0x00 0x4e000000 0x00 0x300000>; + + ti,sci-dev-id = <198>; + + inta_main_dmss_csi: interrupt-controller@4e0a0000 { + compatible = "ti,sci-inta"; + reg = <0x00 0x4e0a0000 0x00 0x8000>; + #interrupt-cells = <0>; + interrupt-controller; + interrupt-parent = <&gic500>; + msi-controller; + ti,sci = <&dmsc>; + ti,sci-dev-id = <200>; + ti,interrupt-ranges = <0 237 8>; + ti,unmapped-event-sources = <&main_bcdma_csi>; + power-domains = <&k3_pds 182 TI_SCI_PD_EXCLUSIVE>; + }; + + main_bcdma_csi: dma-controller@4e230000 { + compatible = "ti,am62a-dmss-bcdma-csirx"; + reg = <0x00 0x4e230000 0x00 0x100>, + <0x00 0x4e180000 0x00 0x8000>, + <0x00 0x4e100000 0x00 0x10000>; + reg-names = "gcfg", "rchanrt", "ringrt"; + msi-parent = <&inta_main_dmss_csi>; + #dma-cells = <3>; + ti,sci = <&dmsc>; + ti,sci-dev-id = <199>; + ti,sci-rm-range-rchan = <0x21>; + power-domains = <&k3_pds 182 TI_SCI_PD_EXCLUSIVE>; + }; + }; + dmsc: system-controller@44043000 { compatible = "ti,k2g-sci"; reg = <0x00 0x44043000 0x00 0xfe0>; @@ -876,4 +914,65 @@ mcasp2: audio-controller@2b20000 { power-domains = <&k3_pds 192 TI_SCI_PD_EXCLUSIVE>; status = "disabled"; }; + + ti_csi2rx0: ticsi2rx@30102000 { + compatible = "ti,j721e-csi2rx-shim"; + dmas = <&main_bcdma_csi 0 0x5000 0>; + dma-names = "rx0"; + reg = <0x00 0x30102000 0x00 0x1000>; + power-domains = <&k3_pds 182 TI_SCI_PD_EXCLUSIVE>; + #address-cells = <2>; + #size-cells = <2>; + ranges; + status = "disabled"; + + cdns_csi2rx0: csi-bridge@30101000 { + compatible = "ti,j721e-csi2rx", "cdns,csi2rx"; + reg = <0x00 0x30101000 0x00 0x1000>; + clocks = <&k3_clks 182 0>, <&k3_clks 182 3>, <&k3_clks 182 0>, + <&k3_clks 182 0>, <&k3_clks 182 4>, <&k3_clks 182 4>; + clock-names = "sys_clk", "p_clk", "pixel_if0_clk", + "pixel_if1_clk", "pixel_if2_clk", "pixel_if3_clk"; + phys = <&dphy0>; + phy-names = "dphy"; + + ports { + #address-cells = <1>; + #size-cells = <0>; + + csi0_port0: port@0 { + reg = <0>; + status = "disabled"; + }; + + csi0_port1: port@1 { + reg = <1>; + status = "disabled"; + }; + + csi0_port2: port@2 { + reg = <2>; + status = "disabled"; + }; + + csi0_port3: port@3 { + reg = <3>; + status = "disabled"; + }; + + csi0_port4: port@4 { + reg = <4>; + status = "disabled"; + }; + }; + }; + }; + + dphy0: phy@30110000 { + compatible = "cdns,dphy-rx"; + reg = <0x00 0x30110000 0x00 0x1100>; + #phy-cells = <0>; + power-domains = <&k3_pds 185 TI_SCI_PD_EXCLUSIVE>; + status = "disabled"; + }; };