From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-lj1-f174.google.com (mail-lj1-f174.google.com [209.85.208.174]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id DEDE57263B for ; Sat, 21 Feb 2026 18:36:42 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.208.174 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1771699004; cv=none; b=Q8JL4/eRKKtpmkifxTrhCb61C8nzaZtPvTxqaaK5KEmIhubv3EJvXvNPv/aeKZW7eYsRr/zrYvhDy0bW2JFoKiwCJCTfMhunNTHG0j93I/eOWR420GPNIxcJGOLWl2mqZzWsHFka2BAeHiBMmVM05FScCv/qVu2x3UFNJ64XeOk= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1771699004; c=relaxed/simple; bh=/FvXEaGUoGpzEkjnRI9XUIndReaBxEi1jDlYZjxu8lk=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=qP8cAzAeQETi/mKVzpV9CcigwXFS/em+rn4s+CBpjsQ9e9zUIpplIWVSU15iHyG5wI3LPMYmulDp7tU2ib+kVff0x4UMpmAIsxCOiYvQSzz3f6kwESOHN+oxCEPSvuOYwL7ukmTqPc0jQglUFsvPVu9EEeehf4wu7l5OuiaPCYU= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=krSmEq5W; arc=none smtp.client-ip=209.85.208.174 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="krSmEq5W" Received: by mail-lj1-f174.google.com with SMTP id 38308e7fff4ca-3878de20527so26736991fa.3 for ; Sat, 21 Feb 2026 10:36:42 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1771699001; x=1772303801; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=tuboJBenXywBLFqud7lu9/BOWrHh+KcmgCOX5jvamjk=; b=krSmEq5WyDMCCqTHbN9PG55FVgqUZOnEQmlHKBgEsbHBAkHk00GYUauJtROaEmRTh9 J8w33zzfN6fVVDGrYqjPWGZPinfYJHksPBKS7/LSL3RAKisvPlgjSAyJKV3f3YuQhOla D4XrYWCYARROj9aCHXerwRH7BGzYpb5qO1Sx8//L3VR+T21PRbN6zaVKUf16OXObmk90 mLzJL3sZlVEQSwl6Rc2KCp4roMD+3aAjbYWI2lJWw76DGMdRBYEylR400SKYt54VKN3r 2EpFFB8LNtUnmgmkiA9JBWrTbUx2QpiFzq8e422+gtMYyrzUlbn4GYfkGRMPcfypE1Uw Qcvg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1771699001; x=1772303801; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=tuboJBenXywBLFqud7lu9/BOWrHh+KcmgCOX5jvamjk=; b=TP1Dgat/hlQeOTF2eypK/xv1txRtzneJnMUEt7pJdr1drvNguFS7aAgYAGYj7XufWa qJM3Le+3Ipe/CoPogiPlT7get+HIl2VZ7qlaShb/aeNSnZecIIE7Pa4piDQisq+osmLY TFvz2Xl5CO7H8S013qX/5un07a5tAX2WEIFYDRpHKmn21S8uEBFTDDNmdXNisa5+KXEj pLcnJPxg5uw9vRkrSMiPcvp6smPg/RLiLbC1wdY3mFJsrLtjB1CQFuC1LvCwRwPNwMTn EVMG4Qpol7MWFCecY4cz8T6lbd+o8brljbyVKWQoJ9K9HNNmMleutKauKW17YtemYeTA V7Rg== X-Forwarded-Encrypted: i=1; AJvYcCWfdltVbTCZpzlzGpIYsGKeM5Wg9y3LpWvUxco2olq666hlucVtDA69JCjX/R0rE9S22UJ/4IpE6cmQ@vger.kernel.org X-Gm-Message-State: AOJu0YwR7gzDhDsym0g2nSRiGdsmDTJimwQobpHMgb8ffy6NDsCUdfny WOrsi5OP2iDoEYlyQTXKOQU/hnTJxCWp/jKkmssufdPH7I+1gReR8p8= X-Gm-Gg: AZuq6aLWs18lASMz0uQDhEF1uGRNfrne/Ckw6gQD9Vq+zsK4WDCZnyM0lSwQgXTjV4f bKi98oeGjHCInkUaWJd0rfHCx1LugoWVNk7PbdMUSZdZ1HT38XD1zCnUKtOylBf3o3FPZfcN0L0 ZkzNwuqz4Ej1C4flmvzIXEjwXNh1uLdcjEj+Dh8HeY1hSU4dx4ZEd/LtS+LcaqBkkAeopQYBdCb /IcjQt9gPTs+e48ygERJ9J9vWVLUJO5LLgTH76DBeb1HwbRKucIpaAI1aBrwK+KhtMZpFuJv1dn 5TmjIjjKwAxrhRMlN0gQoJk6g3vklUIccsDletOR1MR3axVZsPl0aM55/zahhmFG3aWhB5FgnFa muH0qGbu+kF/wOIfo4RrCBTpe/kzylqznulmjICstRe+7dcwq7x466U+JSYLwamZ6Gmc9jDnlL/ TGxFaFnQCLMl5VwqLIgWPNdaw7HhKrGAJukdwa X-Received: by 2002:a2e:be94:0:b0:386:eadd:9ddf with SMTP id 38308e7fff4ca-389a5cdd595mr8800811fa.12.1771699000922; Sat, 21 Feb 2026 10:36:40 -0800 (PST) Received: from localhost.localdomain ([178.176.177.46]) by smtp.gmail.com with ESMTPSA id 38308e7fff4ca-389a7af19d4sm5006841fa.42.2026.02.21.10.36.38 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 21 Feb 2026 10:36:40 -0800 (PST) From: Aleksandr Shubin To: linux-kernel@vger.kernel.org Cc: Aleksandr Shubin , =?UTF-8?q?Uwe=20Kleine-K=C3=B6nig?= , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Chen-Yu Tsai , Jernej Skrabec , Samuel Holland , Paul Walmsley , Palmer Dabbelt , Albert Ou , Alexandre Ghiti , Philipp Zabel , Lukas Schmid , Cheo Fusi , linux-pwm@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-sunxi@lists.linux.dev, linux-riscv@lists.infradead.org Subject: [PATCH v13 1/3] dt-bindings: pwm: Add binding for Allwinner D1/T113-S3/R329 PWM controller Date: Sat, 21 Feb 2026 21:35:51 +0300 Message-Id: <20260221183609.95403-2-privatesub2@gmail.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20260221183609.95403-1-privatesub2@gmail.com> References: <20260221183609.95403-1-privatesub2@gmail.com> Precedence: bulk X-Mailing-List: devicetree@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Allwinner's D1, T113-S3 and R329 SoCs have a new pwm controller which is different from the previous pwm-sun4i. The D1 and T113 are identical in terms of peripherals, they differ only in the architecture of the CPU core, and even share the majority of their DT. Because of that, using the same compatible makes sense. The R329 is a different SoC though, and should have a different compatible string added, especially as there is a difference in the number of channels. D1 and T113s SoCs have one PWM controller with 8 channels. R329 SoC has two PWM controllers in both power domains, one of them has 9 channels (CPUX one) and the other has 6 (CPUS one). Add a device tree binding for them. Signed-off-by: Aleksandr Shubin --- .../bindings/pwm/allwinner,sun20i-d1-pwm.yaml | 74 +++++++++++++++++++ 1 file changed, 74 insertions(+) create mode 100644 Documentation/devicetree/bindings/pwm/allwinner,sun20i-d1-pwm.yaml diff --git a/Documentation/devicetree/bindings/pwm/allwinner,sun20i-d1-pwm.yaml b/Documentation/devicetree/bindings/pwm/allwinner,sun20i-d1-pwm.yaml new file mode 100644 index 000000000000..306e14a9c4d5 --- /dev/null +++ b/Documentation/devicetree/bindings/pwm/allwinner,sun20i-d1-pwm.yaml @@ -0,0 +1,74 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/pwm/allwinner,sun20i-d1-pwm.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Allwinner D1, T113-S3 and R329 PWM + +maintainers: + - Aleksandr Shubin + - Brandon Cheo Fusi + +properties: + compatible: + oneOf: + - const: allwinner,sun20i-d1-pwm + - items: + - const: allwinner,sun50i-r329-pwm + - const: allwinner,sun20i-d1-pwm + + reg: + maxItems: 1 + + "#pwm-cells": + const: 3 + + clocks: + items: + - description: Bus clock + - description: 24 MHz oscillator + - description: APB clock + + clock-names: + items: + - const: bus + - const: hosc + - const: apb + + resets: + maxItems: 1 + + allwinner,npwms: + $ref: /schemas/types.yaml#/definitions/uint32 + description: The number of PWM channels configured for this instance + minimum: 1 + maximum: 16 + +unevaluatedProperties: false + +required: + - compatible + - reg + - "#pwm-cells" + - clocks + - clock-names + - resets + - allwinner,npwms + +examples: + - | + #include + #include + + pwm: pwm@2000c00 { + compatible = "allwinner,sun20i-d1-pwm"; + reg = <0x02000c00 0x400>; + clocks = <&ccu CLK_BUS_PWM>, <&dcxo>, <&ccu CLK_APB0>; + clock-names = "bus", "hosc", "apb"; + resets = <&ccu RST_BUS_PWM>; + #pwm-cells = <0x3>; + allwinner,npwms = <8>; + }; + +... -- 2.25.1