Received: by 2002:ac2:464d:0:0:0:0:0 with SMTP id s13csp3292111lfo; Mon, 23 May 2022 00:53:15 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwlDcNZ8bzCA4LyLMhMo4AK4Y+lZUWz4reHoGOPQQfczRDxZtyJAGWbzmX8o63F5BSML5ib X-Received: by 2002:a17:902:7048:b0:15f:34c1:bae0 with SMTP id h8-20020a170902704800b0015f34c1bae0mr21522998plt.71.1653292395567; Mon, 23 May 2022 00:53:15 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1653292395; cv=none; d=google.com; s=arc-20160816; b=B0tgAXcldZQHpXwiWdrX8qx5vVbKgBWv2h4GeVsOG9J+LVe9H9XsPQhIFtlMDBr1HZ 8Crxp4Pc5eZCqAhZLxQDRSqnIQDx+VtW0Eygp2HHmgzTGKViejUw5NE+5C799OvyjhT6 prjYy9q/7uG9UBhCFw1tWhixAKy7QIGJYIQK1z+rIzi4sPtMboPAq5bLMc1UdbasZUYM taP2auHsn0dbc3q7y0WTEKhSyB5O9AJYZUvDE8+POjcslglXtCKRNuNZLX2n7vGjOCyu 0LXzz1P4hqslXXomTclOv6NsQAccvyruV0a7S8BoI58jx49rQX+BSV9qYJe4lIqZdv6Z XCPw== 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=ljiErN1mr2t69zzIIj9dfRMuvW56MOhlvXOh9A1Q5uw=; b=PgyKgGufs2NnUAOsHY6xDn9IfDypNZygro3gzThOBA82N7chUCt8o31ndH3zZtGtvG XRMnqAe+4d2kOqZMvchFJRh+h8qaIMGpJJdW4QMsXHuzsqANsSKK7Cc2/cjAdfrrGj4m JIa4y65x1b1o1ZHCrFP11ENSbn14raaZ0E2tEydAJigURrsJqCrWNUht6GO/lGeXdax6 DJltR11ZYIdqKcNEFh4nLzMY39U7WISWPDXK+rxsj5woF7LOrhc6NBiWyvQg0O6U9ReZ zHl9j2LxtqrYSG4xzfooMqY3dg9a3xusrDDsfWhZg3TbmXfTkZvW4mC4leyJOjrL9mIa KtDw== 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:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [2620:137:e000::1:18]) by mx.google.com with ESMTPS id s17-20020a170902b19100b00153b2d165c6si8358447plr.462.2022.05.23.00.53.15 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 23 May 2022 00:53:15 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) client-ip=2620:137:e000::1:18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 5B958606FB; Sun, 22 May 2022 23:59:52 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231268AbiEVP6m (ORCPT + 99 others); Sun, 22 May 2022 11:58:42 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39018 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1349205AbiEVP61 (ORCPT ); Sun, 22 May 2022 11:58:27 -0400 Received: from herzl.nuvoton.co.il (unknown [212.199.177.27]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A2AF23B2B4; Sun, 22 May 2022 08:58:20 -0700 (PDT) Received: from taln60.nuvoton.co.il (ntil-fw [212.199.177.25]) by herzl.nuvoton.co.il (8.13.8/8.13.8) with ESMTP id 24MFp3dS031630; Sun, 22 May 2022 18:51:03 +0300 Received: by taln60.nuvoton.co.il (Postfix, from userid 10070) id AAAB063A4A; Sun, 22 May 2022 18:51:03 +0300 (IDT) From: Tomer Maimon To: avifishman70@gmail.com, tali.perry1@gmail.com, joel@jms.id.au, venture@google.com, yuenn@google.com, benjaminfair@google.com, robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, mturquette@baylibre.com, sboyd@kernel.org, p.zabel@pengutronix.de, gregkh@linuxfoundation.org, daniel.lezcano@linaro.org, tglx@linutronix.de, wim@linux-watchdog.org, linux@roeck-us.net, catalin.marinas@arm.com, will@kernel.org, arnd@arndb.de, olof@lixom.net, jirislaby@kernel.org, shawnguo@kernel.org, bjorn.andersson@linaro.org, geert+renesas@glider.be, marcel.ziswiler@toradex.com, vkoul@kernel.org, biju.das.jz@bp.renesas.com, nobuhiro1.iwamatsu@toshiba.co.jp, robert.hancock@calian.com, j.neuschaefer@gmx.net, lkundrak@v3.sk Cc: soc@kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-clk@vger.kernel.org, linux-serial@vger.kernel.org, linux-watchdog@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Tomer Maimon Subject: [PATCH v1 07/19] dt-binding: clk: npcm845: Add binding for Nuvoton NPCM8XX Clock Date: Sun, 22 May 2022 18:50:34 +0300 Message-Id: <20220522155046.260146-8-tmaimon77@gmail.com> X-Mailer: git-send-email 2.33.0 In-Reply-To: <20220522155046.260146-1-tmaimon77@gmail.com> References: <20220522155046.260146-1-tmaimon77@gmail.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-0.6 required=5.0 tests=BAYES_00,DKIM_ADSP_CUSTOM_MED, FORGED_GMAIL_RCVD,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,RDNS_NONE, SPF_HELO_NONE,SPOOFED_FREEMAIL_NO_RDNS,T_SCC_BODY_TEXT_LINE autolearn=no 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 Nuvoton Arbel BMC NPCM7XX contains an integrated clock controller, which generates and supplies clocks to all modules within the BMC. Signed-off-by: Tomer Maimon --- .../bindings/clock/nuvoton,npcm845-clk.yaml | 68 +++++++++++++++++++ .../dt-bindings/clock/nuvoton,npcm8xx-clock.h | 50 ++++++++++++++ 2 files changed, 118 insertions(+) create mode 100644 Documentation/devicetree/bindings/clock/nuvoton,npcm845-clk.yaml create mode 100644 include/dt-bindings/clock/nuvoton,npcm8xx-clock.h diff --git a/Documentation/devicetree/bindings/clock/nuvoton,npcm845-clk.yaml b/Documentation/devicetree/bindings/clock/nuvoton,npcm845-clk.yaml new file mode 100644 index 000000000000..f305c7c7eaf0 --- /dev/null +++ b/Documentation/devicetree/bindings/clock/nuvoton,npcm845-clk.yaml @@ -0,0 +1,68 @@ +# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/clock/nuvoton,npcm845-clk.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Nuvoton NPCM8XX Clock Controller Binding + +maintainers: + - Tomer Maimon + +description: | + Nuvoton Arbel BMC NPCM8XX contains an integrated clock controller, which + generates and supplies clocks to all modules within the BMC. + +properties: + compatible: + enum: + - nuvoton,npcm845-clk + + reg: + maxItems: 1 + + clocks: + description: + specify the external clocks used by the NPCM8XX clock module. + items: + - description: 25M reference clock + - description: CPU reference clock + - description: MC reference clock + + clock-names: + description: + specify the external clocks names used by the NPCM8XX clock module. + items: + - const: refclk + - const: sysbypck + - const: mcbypck + + '#clock-cells': + const: 1 + description: + See include/dt-bindings/clock/nuvoton,npcm8xx-clock.h for the full + list of NPCM8XX clock IDs. + +required: + - compatible + - reg + - "#clock-cells" + +additionalProperties: false + +examples: + # Clock Control Module node: + - | + + ahb { + #address-cells = <2>; + #size-cells = <2>; + + clk: clock-controller@f0801000 { + compatible = "nuvoton,npcm845-clk"; + reg = <0x0 0xf0801000 0x0 0x1000>; + #clock-cells = <1>; + }; + }; + +... diff --git a/include/dt-bindings/clock/nuvoton,npcm8xx-clock.h b/include/dt-bindings/clock/nuvoton,npcm8xx-clock.h new file mode 100644 index 000000000000..d76f606bf88b --- /dev/null +++ b/include/dt-bindings/clock/nuvoton,npcm8xx-clock.h @@ -0,0 +1,50 @@ +/* SPDX-License-Identifier: GPL-2.0 */ +/* + * Nuvoton NPCM8xx Clock Generator binding + * clock binding number for all clocks supportted by nuvoton,npcm8xx-clk + * + * Copyright (C) 2021 Nuvoton Technologies tomer.maimon@nuvoton.com + * + */ + +#ifndef __DT_BINDINGS_CLOCK_NPCM8XX_H +#define __DT_BINDINGS_CLOCK_NPCM8XX_H + +#define NPCM8XX_CLK_CPU 0 +#define NPCM8XX_CLK_GFX_PIXEL 1 +#define NPCM8XX_CLK_MC 2 +#define NPCM8XX_CLK_ADC 3 +#define NPCM8XX_CLK_AHB 4 +#define NPCM8XX_CLK_TIMER 5 +#define NPCM8XX_CLK_UART 6 +#define NPCM8XX_CLK_UART2 7 +#define NPCM8XX_CLK_MMC 8 +#define NPCM8XX_CLK_SPI3 9 +#define NPCM8XX_CLK_PCI 10 +#define NPCM8XX_CLK_AXI 11 +#define NPCM8XX_CLK_APB4 12 +#define NPCM8XX_CLK_APB3 13 +#define NPCM8XX_CLK_APB2 14 +#define NPCM8XX_CLK_APB1 15 +#define NPCM8XX_CLK_APB5 16 +#define NPCM8XX_CLK_CLKOUT 17 +#define NPCM8XX_CLK_GFX 18 +#define NPCM8XX_CLK_SU 19 +#define NPCM8XX_CLK_SU48 20 +#define NPCM8XX_CLK_SDHC 21 +#define NPCM8XX_CLK_SPI0 22 +#define NPCM8XX_CLK_SPI1 23 +#define NPCM8XX_CLK_SPIX 24 +#define NPCM8XX_CLK_RG 25 +#define NPCM8XX_CLK_RCP 26 +#define NPCM8XX_CLK_PRE_ADC 27 +#define NPCM8XX_CLK_ATB 28 +#define NPCM8XX_CLK_PRE_CLK 29 +#define NPCM8XX_CLK_TH 30 +#define NPCM8XX_CLK_REFCLK 31 +#define NPCM8XX_CLK_SYSBYPCK 32 +#define NPCM8XX_CLK_MCBYPCK 33 + +#define NPCM8XX_NUM_CLOCKS (NPCM8XX_CLK_MCBYPCK + 1) + +#endif -- 2.33.0