diff mbox series

[v4,07/10] dt-bindings: mips: Add loongson boards

Message ID 20200221050942.507775-8-jiaxun.yang@flygoat.com
State Changes Requested, archived
Headers show
Series Modernize Loongson64 Machine v4 | expand

Checks

Context Check Description
robh/checkpatch success
robh/dt-meta-schema success

Commit Message

Jiaxun Yang Feb. 21, 2020, 5:09 a.m. UTC
Prepare for later dts.

Signed-off-by: Jiaxun Yang <jiaxun.yang@flygoat.com>
---
 .../bindings/mips/loongson/devices.yaml       | 29 +++++++++++++++++++
 1 file changed, 29 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/mips/loongson/devices.yaml

Comments

Rob Herring (Arm) Feb. 26, 2020, 4:52 p.m. UTC | #1
On Fri, Feb 21, 2020 at 01:09:22PM +0800, Jiaxun Yang wrote:
> Prepare for later dts.
> 
> Signed-off-by: Jiaxun Yang <jiaxun.yang@flygoat.com>
> ---
>  .../bindings/mips/loongson/devices.yaml       | 29 +++++++++++++++++++
>  1 file changed, 29 insertions(+)
>  create mode 100644 Documentation/devicetree/bindings/mips/loongson/devices.yaml
> 
> diff --git a/Documentation/devicetree/bindings/mips/loongson/devices.yaml b/Documentation/devicetree/bindings/mips/loongson/devices.yaml
> new file mode 100644
> index 000000000000..32bec784da87
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/mips/loongson/devices.yaml
> @@ -0,0 +1,29 @@
> +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
> +%YAML 1.2
> +---
> +$id: http://devicetree.org/schemas/mips/loongson/devices.yaml#
> +$schema: http://devicetree.org/meta-schemas/core.yaml#
> +
> +title: Loongson based Platforms Device Tree Bindings
> +
> +maintainers:
> +  - Jiaxun Yang <jiaxun.yang@flygoat.com>
> +description: |
> +  Devices with a Loongson CPU shall have the following properties.

Perhaps some details about the platform.

> +  Note that generic device is used for built-in dtbs and will be
> +  patched during boot on firmware without OF support.

That's a kernel detail that doesn't belong here. (BTW, built-in dtb 
support is intended as a transition step for bootloaders without dtb 
knowledge. It's not the recommended way and shouldn't be used on new 
platforms).

> +
> +properties:
> +  $nodename:
> +    const: '/'
> +  compatible:
> +    oneOf:
> +
> +      - description: Generic Loongson3 4Core + RS780E
> +        items:
> +          - const: loongson,loongson3-4core-rs780e
> +
> +      - description: Generic Loongson3 8Core + RS780E
> +        items:
> +          - const: loongson,loongson3-8core-rs780e
> +...
> -- 
> 2.25.0
> 
>
Jiaxun Yang Feb. 29, 2020, 2:28 a.m. UTC | #2
---- 在 星期四, 2020-02-27 00:52:11 Rob Herring <robh@kernel.org> 撰写 ----
 > On Fri, Feb 21, 2020 at 01:09:22PM +0800, Jiaxun Yang wrote:
 > > Prepare for later dts.
 > > 
 > > Signed-off-by: Jiaxun Yang <jiaxun.yang@flygoat.com>
 > > ---
 > >  .../bindings/mips/loongson/devices.yaml       | 29 +++++++++++++++++++
 > >  1 file changed, 29 insertions(+)
 > >  create mode 100644 Documentation/devicetree/bindings/mips/loongson/devices.yaml
 > > 
 > > diff --git a/Documentation/devicetree/bindings/mips/loongson/devices.yaml b/Documentation/devicetree/bindings/mips/loongson/devices.yaml
 > > new file mode 100644
 > > index 000000000000..32bec784da87
 > > --- /dev/null
 > > +++ b/Documentation/devicetree/bindings/mips/loongson/devices.yaml
 > > @@ -0,0 +1,29 @@
 > > +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
 > > +%YAML 1.2
 > > +---
 > > +$id: http://devicetree.org/schemas/mips/loongson/devices.yaml#
 > > +$schema: http://devicetree.org/meta-schemas/core.yaml#
 > > +
 > > +title: Loongson based Platforms Device Tree Bindings
 > > +
 > > +maintainers:
 > > +  - Jiaxun Yang <jiaxun.yang@flygoat.com>
 > > +description: |
 > > +  Devices with a Loongson CPU shall have the following properties.
 > 
 > Perhaps some details about the platform.
 > 
 > > +  Note that generic device is used for built-in dtbs and will be
 > > +  patched during boot on firmware without OF support.
 > 
 > That's a kernel detail that doesn't belong here. (BTW, built-in dtb 
 > support is intended as a transition step for bootloaders without dtb 
 > knowledge. It's not the recommended way and shouldn't be used on new 
 > platforms).

Yes, it's used to deal with legacy platforms.
Will drop this line in next version.

Thanks.

 > 
 > > +
 > > +properties:
 > > +  $nodename:
 > > +    const: '/'
 > > +  compatible:
 > > +    oneOf:
 > > +
 > > +      - description: Generic Loongson3 4Core + RS780E
 > > +        items:
 > > +          - const: loongson,loongson3-4core-rs780e
 > > +
 > > +      - description: Generic Loongson3 8Core + RS780E
 > > +        items:
 > > +          - const: loongson,loongson3-8core-rs780e
 > > +...
 > > -- 
 > > 2.25.0
 > > 
 > > 
 >
diff mbox series

Patch

diff --git a/Documentation/devicetree/bindings/mips/loongson/devices.yaml b/Documentation/devicetree/bindings/mips/loongson/devices.yaml
new file mode 100644
index 000000000000..32bec784da87
--- /dev/null
+++ b/Documentation/devicetree/bindings/mips/loongson/devices.yaml
@@ -0,0 +1,29 @@ 
+# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/mips/loongson/devices.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Loongson based Platforms Device Tree Bindings
+
+maintainers:
+  - Jiaxun Yang <jiaxun.yang@flygoat.com>
+description: |
+  Devices with a Loongson CPU shall have the following properties.
+  Note that generic device is used for built-in dtbs and will be
+  patched during boot on firmware without OF support.
+
+properties:
+  $nodename:
+    const: '/'
+  compatible:
+    oneOf:
+
+      - description: Generic Loongson3 4Core + RS780E
+        items:
+          - const: loongson,loongson3-4core-rs780e
+
+      - description: Generic Loongson3 8Core + RS780E
+        items:
+          - const: loongson,loongson3-8core-rs780e
+...