diff mbox series

[1/3] dt-bindings: Add dt bindings for flex noc Performance Monitor

Message ID 1574679352-2989-1-git-send-email-shubhrajyoti.datta@gmail.com
State Changes Requested, archived
Headers show
Series [1/3] dt-bindings: Add dt bindings for flex noc Performance Monitor | expand

Checks

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

Commit Message

Shubhrajyoti Datta Nov. 25, 2019, 10:55 a.m. UTC
From: Shubhrajyoti Datta <shubhrajyoti.datta@xilinx.com>

Add dt bindings for flexnoc Performance Monitor.
The flexnoc counters for read and write response and requests are
supported.

Signed-off-by: Shubhrajyoti Datta <shubhrajyoti.datta@xilinx.com>
---
changes from RFC:
moved to schema / yaml

 .../devicetree/bindings/perf/xlnx-flexnoc-pm.yaml  | 45 ++++++++++++++++++++++
 1 file changed, 45 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/perf/xlnx-flexnoc-pm.yaml

Comments

Rob Herring (Arm) Dec. 5, 2019, 6:17 p.m. UTC | #1
On Mon, Nov 25, 2019 at 04:25:50PM +0530, shubhrajyoti.datta@gmail.com wrote:
> From: Shubhrajyoti Datta <shubhrajyoti.datta@xilinx.com>
> 
> Add dt bindings for flexnoc Performance Monitor.
> The flexnoc counters for read and write response and requests are
> supported.
> 
> Signed-off-by: Shubhrajyoti Datta <shubhrajyoti.datta@xilinx.com>
> ---
> changes from RFC:
> moved to schema / yaml
> 
>  .../devicetree/bindings/perf/xlnx-flexnoc-pm.yaml  | 45 ++++++++++++++++++++++
>  1 file changed, 45 insertions(+)
>  create mode 100644 Documentation/devicetree/bindings/perf/xlnx-flexnoc-pm.yaml
> 
> diff --git a/Documentation/devicetree/bindings/perf/xlnx-flexnoc-pm.yaml b/Documentation/devicetree/bindings/perf/xlnx-flexnoc-pm.yaml
> new file mode 100644
> index 0000000..bd0f345
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/perf/xlnx-flexnoc-pm.yaml
> @@ -0,0 +1,45 @@
> +# SPDX-License-Identifier: GPL-2.0-or-later OR BSD-2-Clause

() around the licenses.

Are you good with GPL v10? Make it 'GPL-2.0-only' instead.

> +%YAML 1.2
> +---
> +$id: http://devicetree.org/schemas/perf/xlnx-flexnoc-pm.yaml#
> +$schema: http://devicetree.org/meta-schemas/core.yaml#
> +
> +title: Xilinx flexnoc Performance Monitor device tree bindings
> +
> +maintainers:
> +  - Arnd Bergmann <arnd@arndb.de>
> +  - Greg Kroah-Hartman <gregkh@linuxfoundation.org>

This should be someone familar with this h/w (you).

> +
> +properties:
> +  compatible:
> +    # Versal SoC based boards
> +    items:
> +      - enum:
> +          - xlnx,flexnoc-pm-2.7
> +
> +  reg:
> +    items:
> +      - description: funnel registers
> +      - description: baselpd registers
> +      - description: basefpd registers
> +
> +  reg-names:
> +    # The core schema enforces this is a string array
> +    items:
> +      - const: funnel
> +      - const: baselpd
> +      - const: basefpd
> +
> +required:
> +  - compatible
> +  - reg

No point having 'reg-names' if not required.


Add:

additionalProperties: false

> +
> +examples:
> +  - |
> +    performance-monitor@f0920000 {
> +        compatible = "xlnx,flexnoc-pm-2.7";
> +        reg-names = "funnel", "baselpd", "basefpd";
> +        reg = <0x0 0xf0920000 0x0 0x1000>,
> +              <0x0 0xf0980000 0x0 0x9000>,
> +              <0x0 0xf0b80000 0x0 0x9000>;
> +    };
> -- 
> 2.1.1
>
Shubhrajyoti Datta Dec. 6, 2019, 5:44 a.m. UTC | #2
On Thu, Dec 5, 2019 at 11:47 PM Rob Herring <robh@kernel.org> wrote:
>
> On Mon, Nov 25, 2019 at 04:25:50PM +0530, shubhrajyoti.datta@gmail.com wrote:
> > From: Shubhrajyoti Datta <shubhrajyoti.datta@xilinx.com>
> >
> > Add dt bindings for flexnoc Performance Monitor.
> > The flexnoc counters for read and write response and requests are
> > supported.
> >
> > Signed-off-by: Shubhrajyoti Datta <shubhrajyoti.datta@xilinx.com>
> > ---
> > changes from RFC:
> > moved to schema / yaml
> >
> >  .../devicetree/bindings/perf/xlnx-flexnoc-pm.yaml  | 45 ++++++++++++++++++++++
> >  1 file changed, 45 insertions(+)
> >  create mode 100644 Documentation/devicetree/bindings/perf/xlnx-flexnoc-pm.yaml
> >
> > diff --git a/Documentation/devicetree/bindings/perf/xlnx-flexnoc-pm.yaml b/Documentation/devicetree/bindings/perf/xlnx-flexnoc-pm.yaml
> > new file mode 100644
> > index 0000000..bd0f345
> > --- /dev/null
> > +++ b/Documentation/devicetree/bindings/perf/xlnx-flexnoc-pm.yaml
> > @@ -0,0 +1,45 @@
> > +# SPDX-License-Identifier: GPL-2.0-or-later OR BSD-2-Clause
>
> () around the licenses.
>
> Are you good with GPL v10? Make it 'GPL-2.0-only' instead.
fixed in v2

>
> > +%YAML 1.2
> > +---
> > +$id: http://devicetree.org/schemas/perf/xlnx-flexnoc-pm.yaml#
> > +$schema: http://devicetree.org/meta-schemas/core.yaml#
> > +
> > +title: Xilinx flexnoc Performance Monitor device tree bindings
> > +
> > +maintainers:
> > +  - Arnd Bergmann <arnd@arndb.de>
> > +  - Greg Kroah-Hartman <gregkh@linuxfoundation.org>
>
> This should be someone familar with this h/w (you).
>
fixed in v2
> > +
> > +properties:
> > +  compatible:
> > +    # Versal SoC based boards
> > +    items:
> > +      - enum:
> > +          - xlnx,flexnoc-pm-2.7
> > +
> > +  reg:
> > +    items:
> > +      - description: funnel registers
> > +      - description: baselpd registers
> > +      - description: basefpd registers
> > +
> > +  reg-names:
> > +    # The core schema enforces this is a string array
> > +    items:
> > +      - const: funnel
> > +      - const: baselpd
> > +      - const: basefpd
> > +
> > +required:
> > +  - compatible
> > +  - reg
>
> No point having 'reg-names' if not required.
this I am using to get the addresses.

>
>
> Add:
>
> additionalProperties: false

updated in v2.
>
> > +
> > +examples:
> > +  - |
> > +    performance-monitor@f0920000 {
> > +        compatible = "xlnx,flexnoc-pm-2.7";
> > +        reg-names = "funnel", "baselpd", "basefpd";
> > +        reg = <0x0 0xf0920000 0x0 0x1000>,
> > +              <0x0 0xf0980000 0x0 0x9000>,
> > +              <0x0 0xf0b80000 0x0 0x9000>;
> > +    };
> > --
> > 2.1.1
> >
diff mbox series

Patch

diff --git a/Documentation/devicetree/bindings/perf/xlnx-flexnoc-pm.yaml b/Documentation/devicetree/bindings/perf/xlnx-flexnoc-pm.yaml
new file mode 100644
index 0000000..bd0f345
--- /dev/null
+++ b/Documentation/devicetree/bindings/perf/xlnx-flexnoc-pm.yaml
@@ -0,0 +1,45 @@ 
+# SPDX-License-Identifier: GPL-2.0-or-later OR BSD-2-Clause
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/perf/xlnx-flexnoc-pm.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Xilinx flexnoc Performance Monitor device tree bindings
+
+maintainers:
+  - Arnd Bergmann <arnd@arndb.de>
+  - Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+properties:
+  compatible:
+    # Versal SoC based boards
+    items:
+      - enum:
+          - xlnx,flexnoc-pm-2.7
+
+  reg:
+    items:
+      - description: funnel registers
+      - description: baselpd registers
+      - description: basefpd registers
+
+  reg-names:
+    # The core schema enforces this is a string array
+    items:
+      - const: funnel
+      - const: baselpd
+      - const: basefpd
+
+required:
+  - compatible
+  - reg
+
+examples:
+  - |
+    performance-monitor@f0920000 {
+        compatible = "xlnx,flexnoc-pm-2.7";
+        reg-names = "funnel", "baselpd", "basefpd";
+        reg = <0x0 0xf0920000 0x0 0x1000>,
+              <0x0 0xf0980000 0x0 0x9000>,
+              <0x0 0xf0b80000 0x0 0x9000>;
+    };