From patchwork Tue Mar 14 09:55:53 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bhavya Kapoor X-Patchwork-Id: 69418 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:5915:0:0:0:0:0 with SMTP id v21csp1667896wrd; Tue, 14 Mar 2023 03:10:53 -0700 (PDT) X-Google-Smtp-Source: AK7set+mQKl1R62UpU3+YEG1Ux+Qdfh3jwh0Md6AKX+p3WZnPfj5+LohZVrsrnBXhkKxsK2oqy7O X-Received: by 2002:a05:6a21:9998:b0:d3:73be:3ea2 with SMTP id ve24-20020a056a21999800b000d373be3ea2mr13792737pzb.36.1678788653619; Tue, 14 Mar 2023 03:10:53 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1678788653; cv=none; d=google.com; s=arc-20160816; b=wRZ6Tm3SxAbKqCa1MTllFHkAXNG7JX+zstd4Y4bewvgsG+Udla9CYK8Kf4Z3dtxhEA Q/Y1hB1Y8pSxaDNDMNoRHDzavQQYg9I8WexB7iwEHnH22M5h8H06ROBG9Q4lXrLVNx4X RBKepeFq6P2pw+8gCRbg6ltHPCIlQYDBs89QMLw1vYCjY/vDvv+bDEMJvQCfNQ9LfVB3 tcn6wS6ReTnF5VhxyJeb1mdkoXNLfgQaT3DwNBuLLeBNOAmn0xjxbnFqO4N3SYUTbkDs 75nNamtmuI0FqsrwAkBTcoMKdNIzqMcq6430cfM+13VO6D/FMtrTFe60Qsr7lWBHlqfD xIQA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=9HTrF/bi2rVYtl3gMRYiEks4Hl9aIrD4oAoeLmY90dc=; b=DRm3gBt3UDAK+CHTXg74M5sPFm4MjuKqLojnla9jYKpSURE9QX5DtVQfN8Ny/Cl8ZR rlLW5ppZkLiWsGgpuOb9YZNSJLtRcAb3qN8RVBnYxx47bu957YF7aBsOvzSOamc3OmCD HFUmvAYPJnWPV8paCPw+ixLjJBZ/OSz9LcQMcYbiSnptQsbGmhuHIBgYC9mikhG/ub0b 29YXfc0zZrupLRNXrGKPhM4SZyVsSyy0GijoAwOvbEBFLUuGxa8OVcSwD3De45/IsLWr UkbyStyQsM3FbI48hG9PdVVxoTz1E6ha9Bf897oOQ2Nl0cd6DSzWQ1OjZNNI/7pIW9qh l9Vw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@ti.com header.s=ti-com-17Q1 header.b=P09hzaCR; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 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 (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id e33-20020a630f21000000b0050310fa2a26si1838892pgl.301.2023.03.14.03.10.39; Tue, 14 Mar 2023 03:10:53 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@ti.com header.s=ti-com-17Q1 header.b=P09hzaCR; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 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 S229673AbjCNJ4W (ORCPT + 99 others); Tue, 14 Mar 2023 05:56:22 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33260 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229436AbjCNJ4U (ORCPT ); Tue, 14 Mar 2023 05:56:20 -0400 Received: from fllv0015.ext.ti.com (fllv0015.ext.ti.com [198.47.19.141]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id AF5B27A93A; Tue, 14 Mar 2023 02:56:10 -0700 (PDT) Received: from fllv0034.itg.ti.com ([10.64.40.246]) by fllv0015.ext.ti.com (8.15.2/8.15.2) with ESMTP id 32E9ttUc033245; Tue, 14 Mar 2023 04:55:55 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ti.com; s=ti-com-17Q1; t=1678787755; bh=9HTrF/bi2rVYtl3gMRYiEks4Hl9aIrD4oAoeLmY90dc=; h=From:To:CC:Subject:Date; b=P09hzaCRfz+n6YOnJFi4va1+tLwaEVXRzrmyroQXStEkMYW7mggSpSx+dxyG6yZUM 83fsK8CBcxNEuipC+dnK89WmNM/eTYtlguNn7UohQvOXqWu5iWH5+3xsz198RersTI /xWQMbKDyDq9aA51EQffyoKYHuwWVPy1awxi53X8= Received: from DFLE115.ent.ti.com (dfle115.ent.ti.com [10.64.6.36]) by fllv0034.itg.ti.com (8.15.2/8.15.2) with ESMTPS id 32E9ttIS067606 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=FAIL); Tue, 14 Mar 2023 04:55:55 -0500 Received: from DFLE105.ent.ti.com (10.64.6.26) by DFLE115.ent.ti.com (10.64.6.36) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2507.16; Tue, 14 Mar 2023 04:55:54 -0500 Received: from lelv0327.itg.ti.com (10.180.67.183) by DFLE105.ent.ti.com (10.64.6.26) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2507.16 via Frontend Transport; Tue, 14 Mar 2023 04:55:54 -0500 Received: from localhost (ileaxei01-snat.itg.ti.com [10.180.69.5]) by lelv0327.itg.ti.com (8.15.2/8.15.2) with ESMTP id 32E9tstV003927; Tue, 14 Mar 2023 04:55:54 -0500 From: Bhavya Kapoor To: , CC: , , , , , Subject: [PATCH v5] arm64: dts: ti: k3-j721s2: Add support for ADC nodes Date: Tue, 14 Mar 2023 15:25:53 +0530 Message-ID: <20230314095553.110559-1-b-kapoor@ti.com> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180 X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED, SPF_HELO_PASS,SPF_PASS,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1760253355638775169?= X-GMAIL-MSGID: =?utf-8?q?1760337491721708725?= J721s2 has two instances of 8 channel ADCs in MCU domain. Add support for both ADC nodes. Signed-off-by: Bhavya Kapoor --- Changelog v4->v5: - Modified commit message - removed status = "disabled"; from tscadc nodes Link to v4 : https://lore.kernel.org/all/20230313112834.16156-1-b-kapoor@ti.com/ Testlog : https://gist.github.com/a0498981/058c009e2937b423df02349ca78b4e29 .../dts/ti/k3-j721s2-common-proc-board.dts | 12 ++++++ .../boot/dts/ti/k3-j721s2-mcu-wakeup.dtsi | 38 +++++++++++++++++++ 2 files changed, 50 insertions(+) diff --git a/arch/arm64/boot/dts/ti/k3-j721s2-common-proc-board.dts b/arch/arm64/boot/dts/ti/k3-j721s2-common-proc-board.dts index a7aa6cf08acd..90162a0bb3e6 100644 --- a/arch/arm64/boot/dts/ti/k3-j721s2-common-proc-board.dts +++ b/arch/arm64/boot/dts/ti/k3-j721s2-common-proc-board.dts @@ -309,3 +309,15 @@ &mcu_mcan1 { pinctrl-0 = <&mcu_mcan1_pins_default>; phys = <&transceiver2>; }; + +&tscadc0 { + adc { + ti,adc-channels = <0 1 2 3 4 5 6 7>; + }; +}; + +&tscadc1 { + adc { + ti,adc-channels = <0 1 2 3 4 5 6 7>; + }; +}; diff --git a/arch/arm64/boot/dts/ti/k3-j721s2-mcu-wakeup.dtsi b/arch/arm64/boot/dts/ti/k3-j721s2-mcu-wakeup.dtsi index 0af242aa9816..df8be8803dcb 100644 --- a/arch/arm64/boot/dts/ti/k3-j721s2-mcu-wakeup.dtsi +++ b/arch/arm64/boot/dts/ti/k3-j721s2-mcu-wakeup.dtsi @@ -306,4 +306,42 @@ cpts@3d000 { ti,cpts-periodic-outputs = <2>; }; }; + + tscadc0: tscadc@40200000 { + compatible = "ti,am3359-tscadc"; + reg = <0x00 0x40200000 0x00 0x1000>; + interrupts = ; + power-domains = <&k3_pds 0 TI_SCI_PD_EXCLUSIVE>; + clocks = <&k3_clks 0 0>; + assigned-clocks = <&k3_clks 0 2>; + assigned-clock-rates = <60000000>; + clock-names = "fck"; + dmas = <&main_udmap 0x7400>, + <&main_udmap 0x7401>; + dma-names = "fifo0", "fifo1"; + + adc { + #io-channel-cells = <1>; + compatible = "ti,am3359-adc"; + }; + }; + + tscadc1: tscadc@40210000 { + compatible = "ti,am3359-tscadc"; + reg = <0x00 0x40210000 0x00 0x1000>; + interrupts = ; + power-domains = <&k3_pds 1 TI_SCI_PD_EXCLUSIVE>; + clocks = <&k3_clks 1 0>; + assigned-clocks = <&k3_clks 1 2>; + assigned-clock-rates = <60000000>; + clock-names = "fck"; + dmas = <&main_udmap 0x7402>, + <&main_udmap 0x7403>; + dma-names = "fifo0", "fifo1"; + + adc { + #io-channel-cells = <1>; + compatible = "ti,am3359-adc"; + }; + }; };