From patchwork Mon Aug 14 10:16:01 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Xingyu Wu X-Patchwork-Id: 135356 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:b824:0:b0:3f2:4152:657d with SMTP id z4csp2688120vqi; Mon, 14 Aug 2023 04:53:03 -0700 (PDT) X-Google-Smtp-Source: AGHT+IG+hdp9b7Tk80ex1pnSx3EFw9UZnFLsMO5xWsg8Mvx6ISYDUYanITSP6+1QqamRUF7U/UiY X-Received: by 2002:a17:907:b0b:b0:987:47b3:6e34 with SMTP id h11-20020a1709070b0b00b0098747b36e34mr6904502ejl.67.1692013982544; Mon, 14 Aug 2023 04:53:02 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1692013982; cv=none; d=google.com; s=arc-20160816; b=unOlPGbnG2WGs+cPMGn7qUzvG6hB27dYFsf6crUTGOU0D0WVJxTqiSVR3RQRVilcJe sjErzWcHpI1p58Ssu3CZ3W6ebe7CM+D70cdJ4mz9W5WSo7269g4yfX36QNrmbBizvKGR k04x0tKHnrj3FjdexQhY2B7GgKEagtqRm1OI5dMP6BH+JCOr4ZuJdq8zF0bt6ebEfzGW DralTEl19jg/OOzpGk93eJexy01THl3bL19hIKQqyYk8ASQgoRD38EJ473WW2MHVKDL9 LtZf7XYKHKhNN23+OTStzwGzR2OHrKLijuM7+5c0ojAFPUscKOM1VkPlgygYqWD+mWrc zBhg== 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=vNmpNAVj9Eje1F42IE0e85PayPa1YskFbQ8fI10DX/Y=; fh=7Xnm9Z0nUSA40NYdx1QmwG6X9BDZo4g7q932jkK4sso=; b=iSqCqueudCaF7XJS+9DgT5OYTsFTSd+pSTRmT02yJDJw+iE8aatBok2BbP1sBshB/x +diSAo1NeGGRyCte1wFVeio8arowKPw+qPdWSPxDxg4TYVN/1E9agq0ggGcRKicW1pci UxyMRVK5gnW9+XPj6Xzr784+TWnL7Ls9nE2fclHmO5Zf62d816YVDe9eyPROd67oVbTC LQqob9mtXL6aNivzQu4W4fvLKeZJllV6BPc2MpHQKxHqFeUsN0DSmLO0NFoIVXvKQEbV HuYDzJJmz/1bHkiePsYQlyojUkT+YFE3NbdMrFJ2HTOWWCs4XHjljJR1iCu+Mr7Kr1LZ vY+Q== 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 e9-20020a170906080900b0098debb6fa67si7337049ejd.495.2023.08.14.04.52.38; Mon, 14 Aug 2023 04:53:02 -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 S236798AbjHNKQ4 convert rfc822-to-8bit (ORCPT + 99 others); Mon, 14 Aug 2023 06:16:56 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38800 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236795AbjHNKQV (ORCPT ); Mon, 14 Aug 2023 06:16:21 -0400 Received: from fd01.gateway.ufhost.com (fd01.gateway.ufhost.com [61.152.239.71]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id DD79E10EA; Mon, 14 Aug 2023 03:16:06 -0700 (PDT) Received: from EXMBX166.cuchost.com (unknown [175.102.18.54]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client CN "EXMBX166", Issuer "EXMBX166" (not verified)) by fd01.gateway.ufhost.com (Postfix) with ESMTP id 697A282A9; Mon, 14 Aug 2023 18:16:05 +0800 (CST) Received: from EXMBX061.cuchost.com (172.16.6.61) by EXMBX166.cuchost.com (172.16.6.76) with Microsoft SMTP Server (TLS) id 15.0.1497.42; Mon, 14 Aug 2023 18:16:05 +0800 Received: from localhost.localdomain (183.27.98.20) by EXMBX061.cuchost.com (172.16.6.61) with Microsoft SMTP Server (TLS) id 15.0.1497.42; Mon, 14 Aug 2023 18:16:04 +0800 From: Xingyu Wu To: Daniel Lezcano , Thomas Gleixner , Emil Renner Berthing CC: , , "Rob Herring" , Krzysztof Kozlowski , Paul Walmsley , Palmer Dabbelt , Albert Ou , Philipp Zabel , Xingyu Wu , Samin Guo , , Conor Dooley Subject: [PATCH v4 1/3] dt-bindings: timer: Add timer for StarFive JH7110 SoC Date: Mon, 14 Aug 2023 18:16:01 +0800 Message-ID: <20230814101603.166951-2-xingyu.wu@starfivetech.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20230814101603.166951-1-xingyu.wu@starfivetech.com> References: <20230814101603.166951-1-xingyu.wu@starfivetech.com> MIME-Version: 1.0 X-Originating-IP: [183.27.98.20] X-ClientProxiedBy: EXCAS062.cuchost.com (172.16.6.22) 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_DNSWL_BLOCKED,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: INBOX X-GMAIL-THRID: 1774205253660681771 X-GMAIL-MSGID: 1774205253660681771 Add bindings for the timer on the JH7110 RISC-V SoC by StarFive Technology Ltd. Reviewed-by: Krzysztof Kozlowski Signed-off-by: Xingyu Wu --- .../bindings/timer/starfive,jh7110-timer.yaml | 96 +++++++++++++++++++ 1 file changed, 96 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..9a2dac11eb06 --- /dev/null +++ b/Documentation/devicetree/bindings/timer/starfive,jh7110-timer.yaml @@ -0,0 +1,96 @@ +# 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"; + }; +