Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

dt-bindings: perf: Convert apm,xgene-pmu to DT schema

Convert the Applied Micro X-Gene PMU binding to DT schema format. It is
a straightforward conversion.

Link: https://lore.kernel.org/r/20250812181422.68286-1-robh@kernel.org
Signed-off-by: Rob Herring (Arm) <robh@kernel.org>

+143 -113
+142
Documentation/devicetree/bindings/perf/apm,xgene-pmu.yaml
··· 1 + # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) 2 + %YAML 1.2 3 + --- 4 + $id: http://devicetree.org/schemas/perf/apm,xgene-pmu.yaml# 5 + $schema: http://devicetree.org/meta-schemas/core.yaml# 6 + 7 + title: APM X-Gene SoC PMU 8 + 9 + maintainers: 10 + - Khuong Dinh <khuong@os.amperecomputing.com> 11 + 12 + description: | 13 + This is APM X-Gene SoC PMU (Performance Monitoring Unit) module. 14 + The following PMU devices are supported: 15 + 16 + L3C - L3 cache controller 17 + IOB - IO bridge 18 + MCB - Memory controller bridge 19 + MC - Memory controller 20 + 21 + properties: 22 + compatible: 23 + enum: 24 + - apm,xgene-pmu 25 + - apm,xgene-pmu-v2 26 + 27 + "#address-cells": 28 + const: 2 29 + 30 + "#size-cells": 31 + const: 2 32 + 33 + ranges: true 34 + 35 + reg: 36 + maxItems: 1 37 + 38 + interrupts: 39 + maxItems: 1 40 + 41 + regmap-csw: 42 + $ref: /schemas/types.yaml#/definitions/phandle 43 + 44 + regmap-mcba: 45 + $ref: /schemas/types.yaml#/definitions/phandle 46 + 47 + regmap-mcbb: 48 + $ref: /schemas/types.yaml#/definitions/phandle 49 + 50 + required: 51 + - compatible 52 + - regmap-csw 53 + - regmap-mcba 54 + - regmap-mcbb 55 + - reg 56 + - interrupts 57 + 58 + additionalProperties: 59 + type: object 60 + additionalProperties: false 61 + 62 + properties: 63 + compatible: 64 + enum: 65 + - apm,xgene-pmu-l3c 66 + - apm,xgene-pmu-iob 67 + - apm,xgene-pmu-mcb 68 + - apm,xgene-pmu-mc 69 + 70 + reg: 71 + maxItems: 1 72 + 73 + enable-bit-index: 74 + description: 75 + Specifies which bit enables the associated resource in MCB or MC subnodes. 76 + $ref: /schemas/types.yaml#/definitions/uint32 77 + maximum: 31 78 + 79 + examples: 80 + - | 81 + bus { 82 + #address-cells = <2>; 83 + #size-cells = <2>; 84 + 85 + pmu@78810000 { 86 + compatible = "apm,xgene-pmu-v2"; 87 + reg = <0x0 0x78810000 0x0 0x1000>; 88 + #address-cells = <2>; 89 + #size-cells = <2>; 90 + ranges; 91 + regmap-csw = <&csw>; 92 + regmap-mcba = <&mcba>; 93 + regmap-mcbb = <&mcbb>; 94 + interrupts = <0x0 0x22 0x4>; 95 + 96 + pmul3c@7e610000 { 97 + compatible = "apm,xgene-pmu-l3c"; 98 + reg = <0x0 0x7e610000 0x0 0x1000>; 99 + }; 100 + 101 + pmuiob@7e940000 { 102 + compatible = "apm,xgene-pmu-iob"; 103 + reg = <0x0 0x7e940000 0x0 0x1000>; 104 + }; 105 + 106 + pmucmcb@7e710000 { 107 + compatible = "apm,xgene-pmu-mcb"; 108 + reg = <0x0 0x7e710000 0x0 0x1000>; 109 + enable-bit-index = <0>; 110 + }; 111 + 112 + pmucmcb@7e730000 { 113 + compatible = "apm,xgene-pmu-mcb"; 114 + reg = <0x0 0x7e730000 0x0 0x1000>; 115 + enable-bit-index = <1>; 116 + }; 117 + 118 + pmucmc@7e810000 { 119 + compatible = "apm,xgene-pmu-mc"; 120 + reg = <0x0 0x7e810000 0x0 0x1000>; 121 + enable-bit-index = <0>; 122 + }; 123 + 124 + pmucmc@7e850000 { 125 + compatible = "apm,xgene-pmu-mc"; 126 + reg = <0x0 0x7e850000 0x0 0x1000>; 127 + enable-bit-index = <1>; 128 + }; 129 + 130 + pmucmc@7e890000 { 131 + compatible = "apm,xgene-pmu-mc"; 132 + reg = <0x0 0x7e890000 0x0 0x1000>; 133 + enable-bit-index = <2>; 134 + }; 135 + 136 + pmucmc@7e8d0000 { 137 + compatible = "apm,xgene-pmu-mc"; 138 + reg = <0x0 0x7e8d0000 0x0 0x1000>; 139 + enable-bit-index = <3>; 140 + }; 141 + }; 142 + };
-112
Documentation/devicetree/bindings/perf/apm-xgene-pmu.txt
··· 1 - * APM X-Gene SoC PMU bindings 2 - 3 - This is APM X-Gene SoC PMU (Performance Monitoring Unit) module. 4 - The following PMU devices are supported: 5 - 6 - L3C - L3 cache controller 7 - IOB - IO bridge 8 - MCB - Memory controller bridge 9 - MC - Memory controller 10 - 11 - The following section describes the SoC PMU DT node binding. 12 - 13 - Required properties: 14 - - compatible : Shall be "apm,xgene-pmu" for revision 1 or 15 - "apm,xgene-pmu-v2" for revision 2. 16 - - regmap-csw : Regmap of the CPU switch fabric (CSW) resource. 17 - - regmap-mcba : Regmap of the MCB-A (memory bridge) resource. 18 - - regmap-mcbb : Regmap of the MCB-B (memory bridge) resource. 19 - - reg : First resource shall be the CPU bus PMU resource. 20 - - interrupts : Interrupt-specifier for PMU IRQ. 21 - 22 - Required properties for L3C subnode: 23 - - compatible : Shall be "apm,xgene-pmu-l3c". 24 - - reg : First resource shall be the L3C PMU resource. 25 - 26 - Required properties for IOB subnode: 27 - - compatible : Shall be "apm,xgene-pmu-iob". 28 - - reg : First resource shall be the IOB PMU resource. 29 - 30 - Required properties for MCB subnode: 31 - - compatible : Shall be "apm,xgene-pmu-mcb". 32 - - reg : First resource shall be the MCB PMU resource. 33 - - enable-bit-index : The bit indicates if the according MCB is enabled. 34 - 35 - Required properties for MC subnode: 36 - - compatible : Shall be "apm,xgene-pmu-mc". 37 - - reg : First resource shall be the MC PMU resource. 38 - - enable-bit-index : The bit indicates if the according MC is enabled. 39 - 40 - Example: 41 - csw: csw@7e200000 { 42 - compatible = "apm,xgene-csw", "syscon"; 43 - reg = <0x0 0x7e200000 0x0 0x1000>; 44 - }; 45 - 46 - mcba: mcba@7e700000 { 47 - compatible = "apm,xgene-mcb", "syscon"; 48 - reg = <0x0 0x7e700000 0x0 0x1000>; 49 - }; 50 - 51 - mcbb: mcbb@7e720000 { 52 - compatible = "apm,xgene-mcb", "syscon"; 53 - reg = <0x0 0x7e720000 0x0 0x1000>; 54 - }; 55 - 56 - pmu: pmu@78810000 { 57 - compatible = "apm,xgene-pmu-v2"; 58 - #address-cells = <2>; 59 - #size-cells = <2>; 60 - ranges; 61 - regmap-csw = <&csw>; 62 - regmap-mcba = <&mcba>; 63 - regmap-mcbb = <&mcbb>; 64 - reg = <0x0 0x78810000 0x0 0x1000>; 65 - interrupts = <0x0 0x22 0x4>; 66 - 67 - pmul3c@7e610000 { 68 - compatible = "apm,xgene-pmu-l3c"; 69 - reg = <0x0 0x7e610000 0x0 0x1000>; 70 - }; 71 - 72 - pmuiob@7e940000 { 73 - compatible = "apm,xgene-pmu-iob"; 74 - reg = <0x0 0x7e940000 0x0 0x1000>; 75 - }; 76 - 77 - pmucmcb@7e710000 { 78 - compatible = "apm,xgene-pmu-mcb"; 79 - reg = <0x0 0x7e710000 0x0 0x1000>; 80 - enable-bit-index = <0>; 81 - }; 82 - 83 - pmucmcb@7e730000 { 84 - compatible = "apm,xgene-pmu-mcb"; 85 - reg = <0x0 0x7e730000 0x0 0x1000>; 86 - enable-bit-index = <1>; 87 - }; 88 - 89 - pmucmc@7e810000 { 90 - compatible = "apm,xgene-pmu-mc"; 91 - reg = <0x0 0x7e810000 0x0 0x1000>; 92 - enable-bit-index = <0>; 93 - }; 94 - 95 - pmucmc@7e850000 { 96 - compatible = "apm,xgene-pmu-mc"; 97 - reg = <0x0 0x7e850000 0x0 0x1000>; 98 - enable-bit-index = <1>; 99 - }; 100 - 101 - pmucmc@7e890000 { 102 - compatible = "apm,xgene-pmu-mc"; 103 - reg = <0x0 0x7e890000 0x0 0x1000>; 104 - enable-bit-index = <2>; 105 - }; 106 - 107 - pmucmc@7e8d0000 { 108 - compatible = "apm,xgene-pmu-mc"; 109 - reg = <0x0 0x7e8d0000 0x0 0x1000>; 110 - enable-bit-index = <3>; 111 - }; 112 - };
+1 -1
MAINTAINERS
··· 1895 1895 M: Khuong Dinh <khuong@os.amperecomputing.com> 1896 1896 S: Supported 1897 1897 F: Documentation/admin-guide/perf/xgene-pmu.rst 1898 - F: Documentation/devicetree/bindings/perf/apm-xgene-pmu.txt 1898 + F: Documentation/devicetree/bindings/perf/apm,xgene-pmu.yaml 1899 1899 F: drivers/perf/xgene_pmu.c 1900 1900 1901 1901 APPLIED MICRO QT2025 PHY DRIVER