From patchwork Fri Dec 8 09:42:06 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: William Qiu X-Patchwork-Id: 175699 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:bcd1:0:b0:403:3b70:6f57 with SMTP id r17csp5345232vqy; Fri, 8 Dec 2023 01:42:44 -0800 (PST) X-Google-Smtp-Source: AGHT+IEB9CNbSi/IveVno/YmOrXDKQPitWwOd4N6yTwBgqG1nEGFowfIRkTXRALyMnA7QP/Rfl+2 X-Received: by 2002:a05:6a20:2449:b0:18a:f462:5d3c with SMTP id t9-20020a056a20244900b0018af4625d3cmr5102260pzc.12.1702028564621; Fri, 08 Dec 2023 01:42:44 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1702028564; cv=none; d=google.com; s=arc-20160816; b=X/B0bM8lBlmi8CdO0qR6y1+UdqqpF44lPOJR8Otz4XOXaytk/3aK8Qd3OUzkA9D8ZP W6gkZPDoFPYQdz7xmVCeI7/Vn0mR20apHg75MmjCBXxcwJtEU271dGF6MY7ZOI8pohLU lZNQICxwmlziz4+Uvyat1G0L4qHvK4sSNGsV8npnUbtZy+oeymZ1QtYxWd0fCRR/uXpZ L41Bnsxral3+dSpLg/KZaGLVpGBi897sAyQLVhvSNi0Uo4bxL823HWJ05d2YGrZ1nvIo 6mLyKoVJQyGSGV0N5U25MIQC0rWpUBTITciqE3LzcawNWhxjW3wc8AeQqQTGDCK3o829 PUAA== 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=t7d5tY/8c6rDcp6d+W2GH7KHCFZw04gekr1ZWYxbLpc=; fh=T4gzk7+hgrXGjSNvKGZTlbuKXCiuDaGkxvCBgfgONjs=; b=IMpqc8BTKtF9Y5GqpjQ+0lTclOF3mK4Drq2vnXO6bgUcwmR6QN/lqFly74WxydcM0h 1hGW01hSsNCUtKTpMhgU12C9KMuOZBQGInfeolhbFMeB+afuMsG9MaWmCIPxy+MRPDm1 BhDs3Mw//ZKkEAVKuYUP7B7ML1hRchln1jaNJUUXhLlALyxQ75qmNUvSe8LRbCYjyYew biM8v9JDYxUvQqQrVA+BZKl/OG9WLGvyMyaUexUsE597j0k46lkwM/Zc/e0U0yTbcngb 8wG/8/2M6VMZH7FGsMHOHjNURCrfZNV2n/JEv1Ksd39c0gmE0gXpQ85d6EE/iBqH2DPa 1hdA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:4 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from howler.vger.email (howler.vger.email. [2620:137:e000::3:4]) by mx.google.com with ESMTPS id e5-20020a654785000000b005c1cd597808si1290529pgs.692.2023.12.08.01.42.44 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 08 Dec 2023 01:42:44 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:4 as permitted sender) client-ip=2620:137:e000::3:4; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:4 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by howler.vger.email (Postfix) with ESMTP id 685708794398; Fri, 8 Dec 2023 01:42:34 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at howler.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233259AbjLHJmQ convert rfc822-to-8bit (ORCPT + 99 others); Fri, 8 Dec 2023 04:42:16 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43880 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231863AbjLHJmO (ORCPT ); Fri, 8 Dec 2023 04:42:14 -0500 Received: from fd01.gateway.ufhost.com (fd01.gateway.ufhost.com [61.152.239.71]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 6B16B8E; Fri, 8 Dec 2023 01:42:15 -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 fd01.gateway.ufhost.com (Postfix) with ESMTP id 216B48022; Fri, 8 Dec 2023 17:42:12 +0800 (CST) Received: from EXMBX068.cuchost.com (172.16.6.68) by EXMBX165.cuchost.com (172.16.6.75) with Microsoft SMTP Server (TLS) id 15.0.1497.42; Fri, 8 Dec 2023 17:42:12 +0800 Received: from williamqiu-virtual-machine.starfivetech.com (171.223.208.138) by EXMBX068.cuchost.com (172.16.6.68) with Microsoft SMTP Server (TLS) id 15.0.1497.42; Fri, 8 Dec 2023 17:42:10 +0800 From: William Qiu To: , , , CC: Emil Renner Berthing , Rob Herring , Thierry Reding , Philipp Zabel , Krzysztof Kozlowski , Conor Dooley , =?utf-8?q?Uwe_Kleine-K=C3=B6nig?= , "Hal Feng" , Paul Walmsley , Palmer Dabbelt , Albert Ou , William Qiu Subject: [PATCH v9 1/4] dt-bindings: pwm: Add bindings for OpenCores PWM Controller Date: Fri, 8 Dec 2023 17:42:06 +0800 Message-ID: <20231208094209.1910934-2-william.qiu@starfivetech.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231208094209.1910934-1-william.qiu@starfivetech.com> References: <20231208094209.1910934-1-william.qiu@starfivetech.com> MIME-Version: 1.0 X-Originating-IP: [171.223.208.138] X-ClientProxiedBy: EXCAS066.cuchost.com (172.16.6.26) To EXMBX068.cuchost.com (172.16.6.68) X-YovoleRuleAgent: yovoleflag X-Spam-Status: No, score=-0.8 required=5.0 tests=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 howler.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 (howler.vger.email [0.0.0.0]); Fri, 08 Dec 2023 01:42:34 -0800 (PST) X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1784706304280811552 X-GMAIL-MSGID: 1784706304280811552 Add bindings for OpenCores PWM Controller. Signed-off-by: William Qiu Reviewed-by: Hal Feng Reviewed-by: Conor Dooley --- .../bindings/pwm/opencores,pwm.yaml | 55 +++++++++++++++++++ 1 file changed, 55 insertions(+) create mode 100644 Documentation/devicetree/bindings/pwm/opencores,pwm.yaml diff --git a/Documentation/devicetree/bindings/pwm/opencores,pwm.yaml b/Documentation/devicetree/bindings/pwm/opencores,pwm.yaml new file mode 100644 index 000000000000..0b85dd861dfd --- /dev/null +++ b/Documentation/devicetree/bindings/pwm/opencores,pwm.yaml @@ -0,0 +1,55 @@ +# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/pwm/opencores,pwm.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: OpenCores PWM controller + +maintainers: + - William Qiu + +description: + The OpenCores PTC ip core contains a PWM controller. When operating in PWM + mode, the PTC core generates binary signal with user-programmable low and + high periods. All PTC counters and registers are 32-bit. + +allOf: + - $ref: pwm.yaml# + +properties: + compatible: + items: + - enum: + - starfive,jh7100-pwm + - starfive,jh7110-pwm + - const: opencores,pwm-v1 + + reg: + maxItems: 1 + + clocks: + maxItems: 1 + + resets: + maxItems: 1 + + "#pwm-cells": + const: 3 + +required: + - compatible + - reg + - clocks + +additionalProperties: false + +examples: + - | + pwm@12490000 { + compatible = "starfive,jh7110-pwm", "opencores,pwm-v1"; + reg = <0x12490000 0x10000>; + clocks = <&clkgen 181>; + resets = <&rstgen 109>; + #pwm-cells = <3>; + };