On Fri, Mar 21, 2025 at 08:31:09AM -0700, Matthew Gerlach wrote: > Convert the device tree bindings for the Altera Stratix10 SoCFPGA ECC > Manager from text to yaml. > > Signed-off-by: Matthew Gerlach <matthew.gerlach@xxxxxxxxxx> > --- > v2: > - Fix $id: path. > - Remove unneeded '|'. > - Move vendor properties last (but before child nodes). > - Add appropriate blank lines. > - Don't break ABI. > - Avoid changing existing DTSI and DTS. > --- > .../edac/altr,socfpga-s10-ecc-manager.yaml | 280 ++++++++++++++++++ > .../bindings/edac/socfpga-eccmgr.txt | 150 ---------- > MAINTAINERS | 5 + > 3 files changed, 285 insertions(+), 150 deletions(-) > create mode 100644 Documentation/devicetree/bindings/edac/altr,socfpga-s10-ecc-manager.yaml > > diff --git a/Documentation/devicetree/bindings/edac/altr,socfpga-s10-ecc-manager.yaml b/Documentation/devicetree/bindings/edac/altr,socfpga-s10-ecc-manager.yaml > new file mode 100644 > index 000000000000..a908bb4df60f > --- /dev/null > +++ b/Documentation/devicetree/bindings/edac/altr,socfpga-s10-ecc-manager.yaml > @@ -0,0 +1,280 @@ > +# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause) > +# Copyright (C) 2025 Altera Corporation > +%YAML 1.2 > +--- > +$id: http://devicetree.org/schemas/edac/altr,socfpga-s10-ecc-manager.yaml# > +$schema: http://devicetree.org/meta-schemas/core.yaml# > + > +title: Altera Stratix10 SoCFPGA ECC Manager (ARM64) > + > +maintainers: > + - Matthew Gerlach <matthew.gerlach@xxxxxxxxxx > + > +description: > + The Stratix10 implementation of the SoCFPGA ECC Manager counts and corrects > + single bit errors. Double bit errors are treated as SErrors in ARM64. This > + implementation requires access to registers only available to the Secure > + Device Manager (SDM) via Secure Monitor Calls (SMC). > + > +properties: > + > + compatible: > + $ref: /schemas/types.yaml#/definitions/string-array compatible already has a type, drop this. Elsewhere too. > + description: list of compatibles Don't need generic descriptions. Drop. > + items: > + - const: altr,socfpga-s10-ecc-manager > + - const: altr,socfpga-a10-ecc-manager This doesn't work for socfpga_arria10.dtsi. You need: oneOf: - items: - const: altr,socfpga-s10-ecc-manager - const: altr,socfpga-a10-ecc-manager - const: altr,socfpga-a10-ecc-manager Make sure the other compatibles pass validation too. > + > + "#address-cells": > + const: 1 > + > + "#size-cells": > + const: 1 > + > + interrupts: > + maxItems: 1 > + > + interrupt-controller: true > + > + "#interrupt-cells": > + const: 2 > + > + ranges: true > + > + altr,sysmgr-syscon: > + maxItems: 1 $ref: /schemas/types.yaml#/definitions/phandle And a description of what this is for. > + > + sdramedac: > + type: object > + additionalProperties: false > + > + properties: > + compatible: > + const: altr,sdram-edac-s10 > + > + interrupts: > + maxItems: 1 > + > + altr,sdr-syscon: > + $ref: /schemas/types.yaml#/definitions/phandle > + description: phandle to SDRAM parent > + > + required: > + - compatible > + - interrupts > + - altr,sdr-syscon > + > + ocram-ecc@ff8cc000: > + type: object > + additionalProperties: false > + > + properties: > + compatible: > + $ref: /schemas/types.yaml#/definitions/string-array > + description: list of compatibles > + items: > + - const: altr,socfpga-s10-ocram-ecc > + - const: altr,socfpga-a10-ocram-ecc > + > + reg: > + maxItems: 1 > + > + interrupts: > + maxItems: 1 > + > + altr,ecc-parent: > + $ref: /schemas/types.yaml#/definitions/phandle > + description: phandle to OCRAM parent > + > + required: > + - compatible > + - reg > + - interrupts > + - altr,ecc-parent > + > + usb0-ecc@ff8c4000: > + type: object > + additionalProperties: false > + > + properties: > + compatible: > + $ref: /schemas/types.yaml#/definitions/string-array > + description: list of compatibles > + items: > + - const: altr,socfpga-s10-usb-ecc > + - const: altr,socfpga-usb-ecc > + > + reg: > + maxItems: 1 > + > + interrupts: > + maxItems: 1 > + > + altr,ecc-parent: > + $ref: /schemas/types.yaml#/definitions/phandle > + description: phandle to USB parent > + > + required: > + - compatible > + - reg > + - interrupts > + - altr,ecc-parent > + > + emac0-rx-ecc@ff8c0000: > + type: object > + additionalProperties: false > + > + properties: > + compatible: > + $ref: /schemas/types.yaml#/definitions/string-array > + description: list of compatibles > + items: > + - const: altr,socfpga-s10-eth-mac-ecc > + - const: altr,socfpga-eth-mac-ecc > + > + reg: > + maxItems: 1 > + > + interrupts: > + maxItems: 1 > + > + altr,ecc-parent: > + $ref: /schemas/types.yaml#/definitions/phandle > + description: phandle to ethernet parent > + > + required: > + - compatible > + - reg > + - interrupts > + - altr,ecc-parent > + > + emac0-tx-ecc@ff8c0400: > + type: object > + additionalProperties: false > + > + properties: > + compatible: > + $ref: /schemas/types.yaml#/definitions/string-array > + description: list of compatibles > + items: > + - const: altr,socfpga-s10-eth-mac-ecc > + - const: altr,socfpga-eth-mac-ecc > + > + reg: > + maxItems: 1 > + > + interrupts: > + maxItems: 1 > + > + altr,ecc-parent: > + $ref: /schemas/types.yaml#/definitions/phandle > + description: phandle to ethernet parent > + > + required: > + - compatible > + - reg > + - interrupts > + - altr,ecc-parent > + > + sdmmca-ecc@ff8c8c00: > + type: object > + additionalProperties: false > + > + properties: > + compatible: > + $ref: /schemas/types.yaml#/definitions/string-array > + description: list of compatibles > + items: > + - const: altr,socfpga-s10-sdmmc-ecc > + - const: altr,socfpga-sdmmc-ecc > + > + reg: > + maxItems: 1 > + > + interrupts: > + maxItems: 2 > + > + altr,ecc-parent: > + $ref: /schemas/types.yaml#/definitions/phandle > + description: phandle to ethernet parent SD/MMC parent? Rob