From patchwork Mon Mar 20 13:54:31 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Xingyu Wu X-Patchwork-Id: 72175 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:604a:0:0:0:0:0 with SMTP id j10csp1240789wrt; Mon, 20 Mar 2023 07:14:27 -0700 (PDT) X-Google-Smtp-Source: AK7set86ObQC06Fq/NMnojUobbQ3gqtRf6hgRcALCRhO1hhKlqmwY4HIihKzosvxL71LXojdMIW8 X-Received: by 2002:a17:90b:17cb:b0:229:f4f3:e904 with SMTP id me11-20020a17090b17cb00b00229f4f3e904mr20030311pjb.11.1679321666751; Mon, 20 Mar 2023 07:14:26 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1679321666; cv=none; d=google.com; s=arc-20160816; b=DzgbtyG9Rk85Y15giLn6qPwJ0HbsM6fjl0I33VM4KFc25Vpyu9+nAtcipcrS7CEjeg qadGKjhY+gn2HkxjBLJjpejKbDiU99dZeyynq3CRE6BMTzM//Zue6NGJlvLkp/gwSpyL Igg0RddS+ZMF0Fl9kEvoLuDgwdwFjPDbXgEI2zzK7wtxVE2me3kfbv0s/228gdNJami0 C8jQ1EwQlJDaweg5uRbmbh5in5rVd7qjBe3q7mKX0LV5l2mWvXrYX2nC5yQmFqfhjBMt aZ4mxJsUdlMOz5JVgsK4VMxGnMmMsuEgDWoX5UqaGqQ1uJ4xcSjb3YKQgI49NvgTdJqQ BQpA== 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 :references:in-reply-to:message-id:date:subject:cc:to:from; bh=SxLwvHEZzxGPbli/KErtr0CkgklD292ZnH05Gv/4G2Y=; b=ASfD4ezkKcXCmuvnA1RhyZYJdwNiEZYl4PG8I45/NKUAhpvbCxQgtcdYfn1yS3ebcv 0n6YmKTNbk9/gGyc4PKFfpMGmuDbxC8qfq1EgdJr4+/FZrR6PY4ANbgb9wUyZH2DO55g Vhe941HY5yJMh7090MpSnvNf4acsykXrDCAC98pk6vJrzjmuxhzeAr1qRTURO+Ky8j3d 6ppazgRnR0ecuxazyMkpefXeVZ1rEayscuAHnlRy+my1yZctrQXp/3MgcelnxtxCtkFW zWaqQxoaz6M9mAzZkkdHhn0GnhhVXjLjVQ2NmbP9AxluUhvAqYsAqpeEllFmZfNTQkDl 3OAg== ARC-Authentication-Results: i=1; mx.google.com; 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 Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id c22-20020a17090ab29600b0022c83e223desi2518507pjr.58.2023.03.20.07.14.04; Mon, 20 Mar 2023 07:14:26 -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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231295AbjCTNzU convert rfc822-to-8bit (ORCPT + 99 others); Mon, 20 Mar 2023 09:55:20 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40916 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231649AbjCTNyx (ORCPT ); Mon, 20 Mar 2023 09:54:53 -0400 Received: from fd01.gateway.ufhost.com (fd01.gateway.ufhost.com [61.152.239.71]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4A180126D0; Mon, 20 Mar 2023 06:54:38 -0700 (PDT) Received: from EXMBX165.cuchost.com (unknown [175.102.18.54]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client CN "EXMBX165", Issuer "EXMBX165" (not verified)) by fd01.gateway.ufhost.com (Postfix) with ESMTP id EC37E24E0B4; Mon, 20 Mar 2023 21:54:35 +0800 (CST) Received: from EXMBX061.cuchost.com (172.16.6.61) by EXMBX165.cuchost.com (172.16.6.75) with Microsoft SMTP Server (TLS) id 15.0.1497.42; Mon, 20 Mar 2023 21:54:35 +0800 Received: from localhost.localdomain (183.27.97.64) by EXMBX061.cuchost.com (172.16.6.61) with Microsoft SMTP Server (TLS) id 15.0.1497.42; Mon, 20 Mar 2023 21:54:34 +0800 From: Xingyu Wu To: , , "Daniel Lezcano" , Thomas Gleixner , Krzysztof Kozlowski CC: Rob Herring , Paul Walmsley , Palmer Dabbelt , Albert Ou , Philipp Zabel , Xingyu Wu , Samin Guo , , Conor Dooley Subject: [PATCH v2 1/3] dt-bindings: timer: Add timer for StarFive JH7110 SoC Date: Mon, 20 Mar 2023 21:54:31 +0800 Message-ID: <20230320135433.144832-2-xingyu.wu@starfivetech.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20230320135433.144832-1-xingyu.wu@starfivetech.com> References: <20230320135433.144832-1-xingyu.wu@starfivetech.com> MIME-Version: 1.0 X-Originating-IP: [183.27.97.64] X-ClientProxiedBy: EXCAS066.cuchost.com (172.16.6.26) To EXMBX061.cuchost.com (172.16.6.61) X-YovoleRuleAgent: yovoleflag X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,RCVD_IN_MSPIKE_H2, SPF_HELO_PASS,SPF_PASS 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?1760896396028089027?= X-GMAIL-MSGID: =?utf-8?q?1760896396028089027?= Add bindings for the timer on the JH7110 RISC-V SoC by StarFive Technology Ltd. Signed-off-by: Xingyu Wu Reviewed-by: Krzysztof Kozlowski --- .../bindings/timer/starfive,jh7110-timer.yaml | 95 +++++++++++++++++++ 1 file changed, 95 insertions(+) create mode 100644 Documentation/devicetree/bindings/timer/starfive,jh7110-timer.yaml diff --git a/Documentation/devicetree/bindings/timer/starfive,jh7110-timer.yaml b/Documentation/devicetree/bindings/timer/starfive,jh7110-timer.yaml new file mode 100644 index 000000000000..24b34618f2c8 --- /dev/null +++ b/Documentation/devicetree/bindings/timer/starfive,jh7110-timer.yaml @@ -0,0 +1,95 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/timer/starfive,jh7110-timer.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: StarFive JH7110 Timer +maintainers: + - Xingyu Wu + - Samin Guo + +description: + This timer has four free-running 32 bit counters in StarFive JH7110 SoC. + And each channel(counter) triggers an interrupt when timeout. They support + one-shot mode and continuous-run mode. + +properties: + compatible: + const: starfive,jh7110-timer + + reg: + maxItems: 1 + + interrupts: + items: + - description: channel 0 + - description: channel 1 + - description: channel 2 + - description: channel 3 + + clocks: + items: + - description: timer APB + - description: channel 0 + - description: channel 1 + - description: channel 2 + - description: channel 3 + + clock-names: + items: + - const: apb + - const: ch0 + - const: ch1 + - const: ch2 + - const: ch3 + + resets: + items: + - description: timer APB + - description: channel 0 + - description: channel 1 + - description: channel 2 + - description: channel 3 + + reset-names: + items: + - const: apb + - const: ch0 + - const: ch1 + - const: ch2 + - const: ch3 + +required: + - compatible + - reg + - interrupts + - clocks + - clock-names + - resets + - reset-names + +additionalProperties: false + +examples: + - | + timer@13050000 { + compatible = "starfive,jh7110-timer"; + reg = <0x13050000 0x10000>; + interrupts = <69>, <70>, <71> ,<72>; + clocks = <&clk 124>, + <&clk 125>, + <&clk 126>, + <&clk 127>, + <&clk 128>; + clock-names = "apb", "ch0", "ch1", + "ch2", "ch3"; + resets = <&rst 117>, + <&rst 118>, + <&rst 119>, + <&rst 120>, + <&rst 121>; + reset-names = "apb", "ch0", "ch1", + "ch2", "ch3"; + }; +