From patchwork Thu Dec 14 03:30:56 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ji Sheng Teoh X-Patchwork-Id: 1875949 Return-Path: X-Original-To: incoming-dt@patchwork.ozlabs.org Delivered-To: patchwork-incoming-dt@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=vger.kernel.org (client-ip=2604:1380:45e3:2400::1; helo=sv.mirrors.kernel.org; envelope-from=devicetree+bounces-25089-incoming-dt=patchwork.ozlabs.org@vger.kernel.org; receiver=patchwork.ozlabs.org) Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org [IPv6:2604:1380:45e3:2400::1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4SrHwK01l8z23nF for ; Thu, 14 Dec 2023 14:32:16 +1100 (AEDT) Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id 69FF32823D6 for ; Thu, 14 Dec 2023 03:32:15 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 21A4F17F0; Thu, 14 Dec 2023 03:32:12 +0000 (UTC) X-Original-To: devicetree@vger.kernel.org Received: from ex01.ufhost.com (ex01.ufhost.com [61.152.239.75]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id F3647F2; Wed, 13 Dec 2023 19:32:07 -0800 (PST) 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 ex01.ufhost.com (Postfix) with ESMTP id A239224E2B0; Thu, 14 Dec 2023 11:32:03 +0800 (CST) Received: from EXMBX072.cuchost.com (172.16.6.82) by EXMBX165.cuchost.com (172.16.6.75) with Microsoft SMTP Server (TLS) id 15.0.1497.42; Thu, 14 Dec 2023 11:32:03 +0800 Received: from localhost.localdomain (202.188.176.82) by EXMBX072.cuchost.com (172.16.6.82) with Microsoft SMTP Server (TLS) id 15.0.1497.42; Thu, 14 Dec 2023 11:31:58 +0800 From: Ji Sheng Teoh To: Xingyu Wu , Samin Guo , Wim Van Sebroeck , Guenter Roeck , Rob Herring , Krzysztof Kozlowski , Conor Dooley CC: Ji Sheng Teoh , Ley Foon Tan , , , Subject: [PATCH v3 1/1] dt-bindings: watchdog: starfive,jh7100-wdt: Add compatible for JH8100 Date: Thu, 14 Dec 2023 11:30:56 +0800 Message-ID: <20231214033056.3953143-2-jisheng.teoh@starfivetech.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20231214033056.3953143-1-jisheng.teoh@starfivetech.com> References: <20231214033056.3953143-1-jisheng.teoh@starfivetech.com> Precedence: bulk X-Mailing-List: devicetree@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-ClientProxiedBy: EXCAS064.cuchost.com (172.16.6.24) To EXMBX072.cuchost.com (172.16.6.82) X-YovoleRuleAgent: yovoleflag Add "starfive,jh8100-wdt" compatible string for StarFive's JH8100 watchdog. Since JH8100 watchdog only has 1 reset signal, update binding document to support one reset for "starfive,jh8100-wdt" compatible. Signed-off-by: Ley Foon Tan Signed-off-by: Ji Sheng Teoh --- .../watchdog/starfive,jh7100-wdt.yaml | 48 ++++++++++++++++--- 1 file changed, 42 insertions(+), 6 deletions(-) diff --git a/Documentation/devicetree/bindings/watchdog/starfive,jh7100-wdt.yaml b/Documentation/devicetree/bindings/watchdog/starfive,jh7100-wdt.yaml index 68f3f6fd08a6..79082c5f9971 100644 --- a/Documentation/devicetree/bindings/watchdog/starfive,jh7100-wdt.yaml +++ b/Documentation/devicetree/bindings/watchdog/starfive,jh7100-wdt.yaml @@ -19,14 +19,17 @@ description: isn't cleared, the watchdog will reset the system unless the watchdog reset is disabled. -allOf: - - $ref: watchdog.yaml# - properties: compatible: - enum: - - starfive,jh7100-wdt - - starfive,jh7110-wdt + oneOf: + - items: + - enum: + - starfive,jh7100-wdt + - starfive,jh7110-wdt + - items: + - enum: + - starfive,jh8100-wdt + - const: starfive,jh7110-wdt reg: maxItems: 1 @@ -45,10 +48,33 @@ properties: - const: core resets: + minItems: 1 items: - description: APB reset - description: Core reset +allOf: + - $ref: watchdog.yaml# + + - if: + properties: + compatible: + contains: + enum: + - starfive,jh8100-wdt + then: + properties: + resets: + description: | + Must contain Core reset entry. + maxItems: 1 + else: + properties: + resets: + description: | + Must contain APB reset and Core reset entry. + minItems: 2 + required: - compatible - reg @@ -69,3 +95,13 @@ examples: resets = <&rst 99>, <&rst 100>; }; + + - | + watchdog@12270000 { + compatible = "starfive,jh8100-wdt", "starfive,jh7110-wdt"; + reg = <0x12270000 0x10000>; + clocks = <&clk 78>, + <&clk 79>; + clock-names = "apb", "core"; + resets = <&rst 15>; + };