From: CL Wang <cl634@andestech.com>
To: <cl634@andestech.com>, <broonie@kernel.org>,
<linux-spi@vger.kernel.org>, <robh@kernel.org>,
<krzk+dt@kernel.org>, <conor+dt@kernel.org>
Cc: <devicetree@vger.kernel.org>, <linux-kernel@vger.kernel.org>,
<tim609@andestech.com>
Subject: [PATCH V3 1/3] dt-bindings: spi: Add support for ATCSPI200 SPI controller
Date: Mon, 15 Dec 2025 21:23:47 +0800 [thread overview]
Message-ID: <20251215132349.513843-2-cl634@andestech.com> (raw)
In-Reply-To: <20251215132349.513843-1-cl634@andestech.com>
Document devicetree bindings for the Andes ATCSPI200 SPI controller.
Signed-off-by: CL Wang <cl634@andestech.com>
---
Changes for v3:
- Reworked the DT binding to properly describe the compatible fallback
relationship, defining "andestech,qilai-spi" as a platform-specific
compatible that falls back to the generic "andestech,ae350-spi".
- Renamed the DT binding file from 'andestech,qilai-spi.yaml' to
'andestech,ae350-spi.yaml' to match the generic fallback compatible.
- Updated the 'compatible' property to use a 'oneOf' schema, enforcing
the fallback requirement for the specific compatible string.
Changes for v2:
- Dropped the "spi_" prefix from dma-names as suggested.
- Updated the DT binding and documented all compatible strings.
- Added the "andestech,ae350-spi" compatible string.
---
.../bindings/spi/andestech,ae350-spi.yaml | 85 +++++++++++++++++++
1 file changed, 85 insertions(+)
create mode 100644 Documentation/devicetree/bindings/spi/andestech,ae350-spi.yaml
diff --git a/Documentation/devicetree/bindings/spi/andestech,ae350-spi.yaml b/Documentation/devicetree/bindings/spi/andestech,ae350-spi.yaml
new file mode 100644
index 000000000000..78093468dd5e
--- /dev/null
+++ b/Documentation/devicetree/bindings/spi/andestech,ae350-spi.yaml
@@ -0,0 +1,85 @@
+# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/spi/andestech,ae350-spi.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Andes ATCSPI200 SPI controller
+
+maintainers:
+ - CL Wang <cl634@andestech.com>
+
+properties:
+ compatible:
+ oneOf:
+ - items:
+ - enum:
+ - andestech,qilai-spi
+ - const: andestech,ae350-spi
+ - const: andestech,ae350-spi
+
+ reg:
+ maxItems: 1
+
+ clocks:
+ maxItems: 1
+
+ num-cs:
+ description: Number of chip selects supported
+ maxItems: 1
+
+ dmas:
+ items:
+ - description: Transmit FIFO DMA channel
+ - description: Receive FIFO DMA channel
+
+ dma-names:
+ items:
+ - const: tx
+ - const: rx
+
+patternProperties:
+ "@[0-9a-f]+$":
+ type: object
+ additionalProperties: true
+
+ properties:
+ spi-rx-bus-width:
+ enum: [1, 4]
+
+ spi-tx-bus-width:
+ enum: [1, 4]
+
+allOf:
+ - $ref: spi-controller.yaml#
+
+required:
+ - compatible
+ - reg
+ - clocks
+ - dmas
+ - dma-names
+
+unevaluatedProperties: false
+
+examples:
+ - |
+ spi@f0b00000 {
+ compatible = "andestech,ae350-spi";
+ reg = <0xf0b00000 0x100>;
+ clocks = <&clk_spi>;
+ dmas = <&dma0 0>, <&dma0 1>;
+ dma-names = "tx", "rx";
+
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ flash@0 {
+ compatible = "jedec,spi-nor";
+ reg = <0>;
+ spi-tx-bus-width = <4>;
+ spi-rx-bus-width = <4>;
+ spi-cpol;
+ spi-cpha;
+ };
+ };
--
2.34.1
next prev parent reply other threads:[~2025-12-15 13:24 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-12-15 13:23 [PATCH V3 0/3] spi: atcspi200: Add support for Andes ATCSPI200 SPI controller CL Wang
2025-12-15 13:23 ` CL Wang [this message]
2025-12-16 16:37 ` [PATCH V3 1/3] dt-bindings: spi: Add support for " Conor Dooley
2025-12-15 13:23 ` [PATCH V3 2/3] spi: atcspi200: Add ATCSPI200 SPI controller driver CL Wang
2025-12-15 13:23 ` [PATCH V3 3/3] MAINTAINERS: Add MAINTAINERS entry for the " CL Wang
2025-12-18 12:06 ` [PATCH V3 0/3] spi: atcspi200: Add support for Andes ATCSPI200 SPI controller Mark Brown
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20251215132349.513843-2-cl634@andestech.com \
--to=cl634@andestech.com \
--cc=broonie@kernel.org \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=krzk+dt@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-spi@vger.kernel.org \
--cc=robh@kernel.org \
--cc=tim609@andestech.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox