Skip to contentSkip to conversation

dt-bindings: mips: lantiq: Document Lantiq Xway GPTU

PATCH In review Aleksander Jan Bajkowski 2 participants 5 messages Aug 14, 2025 – Aug 18, 2025

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/2 dt-bindings: mips: lantiq: Document Lantiq Xway GPTU

The Lantiq SoC has six built-in 16-bit general purpose timers (GPTU).

---
 .../mips/lantiq/lantiq,gptu-xway.yaml         | 39 +++++++++++++++++++
 1 file changed, 39 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/mips/lantiq/lantiq,gptu-xway.yaml
Documentation/devicetree/bindings/mips/lantiq/lantiq,gptu-xway.yaml new file +39 -0
new file mode 100644
index 000000000000..fcfc634dd391
@@ -0,0 +1,39 @@
+# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/mips/lantiq/lantiq,gptu-xway.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Lantiq Xway SoC series General Purpose Timer Unit (GPTU)
+
+maintainers:
+  - Aleksander Jan Bajkowski <[email protected]>
+
+properties:
+  compatible:
+    items:
+      - enum:
+          - lantiq,gptu-xway
+
+  reg:
+    maxItems: 1
+
+  interrupts:
+    minItems: 6
+    maxItems: 6
+
+required:
+  - compatible
+  - reg
+  - interrupts
+
+additionalProperties: false
+
+examples:
+  - |
+    gptu@e100a00 {
+        compatible = "lantiq,gptu-xway";
+        reg = <0xe100a00 0x100>;
+        interrupt-parent = <&icu0>;
+        interrupts = <126>, <127>, <128>, <129> ,<130>, <131>;
+    };
Signature · 1 line
2.47.2
#1 lore raw

PATCH 2/2 mips: lantiq: danube: add missing timer interrupts

The driver expects six interrupt lines to be specified.

---
 arch/mips/boot/dts/lantiq/danube.dtsi | 2 ++
 1 file changed, 2 insertions(+)
arch/mips/boot/dts/lantiq/danube.dtsi +2 -0
index 7a7ba66aa534..371d06d1a225 100644
@@ -71,6 +71,8 @@ fpi@10000000 {
 		gptu@e100a00 {
 			compatible = "lantiq,gptu-xway";
 			reg = <0xe100a00 0x100>;
+			interrupt-parent = <&icu0>;
+			interrupts = <126 127 128 129 130 131>;
 		};
 
 		serial@e100c00 {
Signature · 1 line
2.47.2
#2 lore raw
In reply to Aleksander Jan Bajkowski
Quoted 14 lines · Aleksander Jan Bajkowski

The Lantiq SoC has six built-in 16-bit general purpose timers (GPTU).

---
 .../mips/lantiq/lantiq,gptu-xway.yaml         | 39 +++++++++++++++++++
 1 file changed, 39 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/mips/lantiq/lantiq,gptu-xway.yaml
Documentation/devicetree/bindings/mips/lantiq/lantiq,gptu-xway.yaml new file +0 -0
new file mode 100644
index 000000000000..fcfc634dd391

Documentation/devicetree/bindings/mips/lantiq/lantiq,gptu-xway.yaml line 7

Quoted 7 lines
Documentation/devicetree/bindings/mips/lantiq/lantiq,gptu-xway.yaml new file +7 -0
@@ -0,0 +1,39 @@
+# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/mips/lantiq/lantiq,gptu-xway.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Lantiq Xway SoC series General Purpose Timer Unit (GPTU)

"SoC series" implies that you're using the same compatible for multiple devices. Why are you not using device-specific compatibles?

Quoted 6 lines
Documentation/devicetree/bindings/mips/lantiq/lantiq,gptu-xway.yaml new file +6 -0
+
+maintainers:
+  - Aleksander Jan Bajkowski <[email protected]>
+
+properties:
+  compatible:

Documentation/devicetree/bindings/mips/lantiq/lantiq,gptu-xway.yaml line 23

Quoted 10 lines
Documentation/devicetree/bindings/mips/lantiq/lantiq,gptu-xway.yaml new file +10 -0
+    items:
+      - enum:
+          - lantiq,gptu-xway
+
+  reg:
+    maxItems: 1
+
+  interrupts:
+    minItems: 6
+    maxItems: 6

And these interrupts are what exactly? I'd rather an items list explaining what they are tbh.

Quoted 19 lines
Documentation/devicetree/bindings/mips/lantiq/lantiq,gptu-xway.yaml new file +16 -0
+
+required:
+  - compatible
+  - reg
+  - interrupts
+
+additionalProperties: false
+
+examples:
+  - |
+    gptu@e100a00 {
+        compatible = "lantiq,gptu-xway";
+        reg = <0xe100a00 0x100>;
+        interrupt-parent = <&icu0>;
+        interrupts = <126>, <127>, <128>, <129> ,<130>, <131>;
+    };
Signature · 1 line
2.47.2
#3 lore raw
Quoted 9 lines · Conor Dooley
Quoted 8 lines · Aleksander Jan Bajkowski

The Lantiq SoC has six built-in 16-bit general purpose timers (GPTU).

---
  .../mips/lantiq/lantiq,gptu-xway.yaml         | 39 +++++++++++++++++++
  1 file changed, 39 insertions(+)

create mode 100644 Documentation/devicetree/bindings/mips/lantiq/lantiq,gptu-xway.yaml

Quoted 15 lines

Documentation/devicetree/bindings/mips/lantiq/lantiq,gptu-xway.yaml line 7

Quoted 13 lines
Documentation/devicetree/bindings/mips/lantiq/lantiq,gptu-xway.yaml new file +7 -0
new file mode 100644
index 000000000000..fcfc634dd391
@@ -0,0 +1,39 @@
+# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/mips/lantiq/lantiq,gptu-xway.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Lantiq Xway SoC series General Purpose Timer Unit (GPTU)

"SoC series" implies that you're using the same compatible for multiple devices. Why are you not using device-specific compatibles?

This IP Core didn't change in subsequent generations of SoCs, so it had one compatible string. In the next iteration, I will add device-specific compatibles.

#4 lore raw
Quoted 27 lines · Aleksander Jan Bajkowski
Quoted 9 lines · Conor Dooley
Quoted 8 lines · Aleksander Jan Bajkowski

The Lantiq SoC has six built-in 16-bit general purpose timers (GPTU).

---
  .../mips/lantiq/lantiq,gptu-xway.yaml         | 39 +++++++++++++++++++
  1 file changed, 39 insertions(+)

create mode 100644 Documentation/devicetree/bindings/mips/lantiq/lantiq,gptu-xway.yaml

Quoted 15 lines

Documentation/devicetree/bindings/mips/lantiq/lantiq,gptu-xway.yaml line 7

Quoted 13 lines
Documentation/devicetree/bindings/mips/lantiq/lantiq,gptu-xway.yaml new file +7 -0
new file mode 100644
index 000000000000..fcfc634dd391
@@ -0,0 +1,39 @@
+# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/mips/lantiq/lantiq,gptu-xway.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Lantiq Xway SoC series General Purpose Timer Unit (GPTU)

"SoC series" implies that you're using the same compatible for multiple devices. Why are you not using device-specific compatibles?

Quoted 3 lines

This IP Core didn't change in subsequent generations of SoCs, so it had one compatible string. In the next iteration, I will add device-specific compatibles.

You can (and should) use a fallback when you do that, probably to whatever the first device to contain the IP is. The driver need only contain the one fallback compatible.