* [PATCH v6 1/4] dt-bindings: Introduce SoC sleep stats bindings
[not found] <1612448508-9179-1-git-send-email-mkshah@codeaurora.org>
@ 2021-02-04 14:21 ` Maulik Shah
2021-02-04 21:09 ` Rob Herring
` (2 more replies)
2021-02-04 14:21 ` [PATCH v6 3/4] arm64: dts: qcom: sc7180: Enable SoC sleep stats Maulik Shah
1 sibling, 3 replies; 7+ messages in thread
From: Maulik Shah @ 2021-02-04 14:21 UTC (permalink / raw)
To: swboyd, mka, evgreen, bjorn.andersson
Cc: linux-arm-msm, linux-kernel, agross, dianders, linux, rnayak,
ilina, lsrao, Mahesh Sivasubramanian, devicetree, Maulik Shah
From: Mahesh Sivasubramanian <msivasub@codeaurora.org>
Add device binding documentation for Qualcomm Technologies, Inc. (QTI)
SoC sleep stats driver. The driver is used for displaying SoC sleep
statistic maintained by Always On Processor or Resource Power Manager.
Cc: devicetree@vger.kernel.org
Signed-off-by: Mahesh Sivasubramanian <msivasub@codeaurora.org>
Signed-off-by: Lina Iyer <ilina@codeaurora.org>
Signed-off-by: Maulik Shah <mkshah@codeaurora.org>
Reviewed-by: Rob Herring <robh@kernel.org>
Reviewed-by: Bjorn Andersson <bjorn.andersson@linaro.org>
Reviewed-by: Stephen Boyd <swboyd@chromium.org>
---
.../bindings/soc/qcom/soc-sleep-stats.yaml | 46 ++++++++++++++++++++++
1 file changed, 46 insertions(+)
create mode 100644 Documentation/devicetree/bindings/soc/qcom/soc-sleep-stats.yaml
diff --git a/Documentation/devicetree/bindings/soc/qcom/soc-sleep-stats.yaml b/Documentation/devicetree/bindings/soc/qcom/soc-sleep-stats.yaml
new file mode 100644
index 0000000..1e012ba
--- /dev/null
+++ b/Documentation/devicetree/bindings/soc/qcom/soc-sleep-stats.yaml
@@ -0,0 +1,46 @@
+# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/soc/qcom/soc-sleep-stats.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Qualcomm Technologies, Inc. (QTI) SoC sleep stats bindings
+
+maintainers:
+ - Maulik Shah <mkshah@codeaurora.org>
+ - Lina Iyer <ilina@codeaurora.org>
+
+description:
+ Always On Processor/Resource Power Manager maintains statistics of the SoC
+ sleep modes involving powering down of the rails and oscillator clock.
+
+ Statistics includes SoC sleep mode type, number of times low power mode were
+ entered, time of last entry, time of last exit and accumulated sleep duration.
+
+properties:
+ compatible:
+ enum:
+ - qcom,rpmh-sleep-stats
+ - qcom,rpm-sleep-stats
+
+ reg:
+ maxItems: 1
+
+required:
+ - compatible
+ - reg
+
+examples:
+ # Example of rpmh sleep stats
+ - |
+ rpmh-sleep-stats@c3f0000 {
+ compatible = "qcom,rpmh-sleep-stats";
+ reg = <0 0x0c3f0000 0 0x400>;
+ };
+ # Example of rpm sleep stats
+ - |
+ rpm-sleep-stats@4690000 {
+ compatible = "qcom,rpm-sleep-stats";
+ reg = <0 0x04690000 0 0x400>;
+ };
+...
--
QUALCOMM INDIA, on behalf of Qualcomm Innovation Center, Inc. is a member
of Code Aurora Forum, hosted by The Linux Foundation
^ permalink raw reply related [flat|nested] 7+ messages in thread
* [PATCH v6 3/4] arm64: dts: qcom: sc7180: Enable SoC sleep stats
[not found] <1612448508-9179-1-git-send-email-mkshah@codeaurora.org>
2021-02-04 14:21 ` [PATCH v6 1/4] dt-bindings: Introduce SoC sleep stats bindings Maulik Shah
@ 2021-02-04 14:21 ` Maulik Shah
1 sibling, 0 replies; 7+ messages in thread
From: Maulik Shah @ 2021-02-04 14:21 UTC (permalink / raw)
To: swboyd, mka, evgreen, bjorn.andersson
Cc: linux-arm-msm, linux-kernel, agross, dianders, linux, rnayak,
ilina, lsrao, Maulik Shah, devicetree
Add device node for SoC sleep stats driver which provides various
low power mode stats.
Also update the reg size of aoss_qmp device to 0x400.
Cc: devicetree@vger.kernel.org
Signed-off-by: Maulik Shah <mkshah@codeaurora.org>
Reviewed-by: Bjorn Andersson <bjorn.andersson@linaro.org>
---
arch/arm64/boot/dts/qcom/sc7180.dtsi | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/arch/arm64/boot/dts/qcom/sc7180.dtsi b/arch/arm64/boot/dts/qcom/sc7180.dtsi
index 11d4f66..273c896 100644
--- a/arch/arm64/boot/dts/qcom/sc7180.dtsi
+++ b/arch/arm64/boot/dts/qcom/sc7180.dtsi
@@ -3202,7 +3202,7 @@
aoss_qmp: qmp@c300000 {
compatible = "qcom,sc7180-aoss-qmp";
- reg = <0 0x0c300000 0 0x100000>;
+ reg = <0 0x0c300000 0 0x400>;
interrupts = <GIC_SPI 389 IRQ_TYPE_EDGE_RISING>;
mboxes = <&apss_shared 0>;
@@ -3210,6 +3210,11 @@
#power-domain-cells = <1>;
};
+ rpmh-sleep-stats@c3f0000 {
+ compatible = "qcom,rpmh-sleep-stats";
+ reg = <0 0x0c3f0000 0 0x400>;
+ };
+
spmi_bus: spmi@c440000 {
compatible = "qcom,spmi-pmic-arb";
reg = <0 0x0c440000 0 0x1100>,
--
QUALCOMM INDIA, on behalf of Qualcomm Innovation Center, Inc. is a member
of Code Aurora Forum, hosted by The Linux Foundation
^ permalink raw reply related [flat|nested] 7+ messages in thread
* Re: [PATCH v6 1/4] dt-bindings: Introduce SoC sleep stats bindings
2021-02-04 14:21 ` [PATCH v6 1/4] dt-bindings: Introduce SoC sleep stats bindings Maulik Shah
@ 2021-02-04 21:09 ` Rob Herring
2021-02-09 0:23 ` Stephen Boyd
2021-03-12 17:15 ` Bjorn Andersson
2 siblings, 0 replies; 7+ messages in thread
From: Rob Herring @ 2021-02-04 21:09 UTC (permalink / raw)
To: Maulik Shah
Cc: lsrao, linux-arm-msm, mka, linux-kernel, agross, linux,
devicetree, dianders, ilina, Mahesh Sivasubramanian, swboyd,
bjorn.andersson, evgreen, rnayak
On Thu, 04 Feb 2021 19:51:45 +0530, Maulik Shah wrote:
> From: Mahesh Sivasubramanian <msivasub@codeaurora.org>
>
> Add device binding documentation for Qualcomm Technologies, Inc. (QTI)
> SoC sleep stats driver. The driver is used for displaying SoC sleep
> statistic maintained by Always On Processor or Resource Power Manager.
>
> Cc: devicetree@vger.kernel.org
> Signed-off-by: Mahesh Sivasubramanian <msivasub@codeaurora.org>
> Signed-off-by: Lina Iyer <ilina@codeaurora.org>
> Signed-off-by: Maulik Shah <mkshah@codeaurora.org>
> Reviewed-by: Rob Herring <robh@kernel.org>
> Reviewed-by: Bjorn Andersson <bjorn.andersson@linaro.org>
> Reviewed-by: Stephen Boyd <swboyd@chromium.org>
> ---
> .../bindings/soc/qcom/soc-sleep-stats.yaml | 46 ++++++++++++++++++++++
> 1 file changed, 46 insertions(+)
> create mode 100644 Documentation/devicetree/bindings/soc/qcom/soc-sleep-stats.yaml
>
My bot found errors running 'make dt_binding_check' on your patch:
yamllint warnings/errors:
dtschema/dtc warnings/errors:
/builds/robherring/linux-dt-review/Documentation/devicetree/bindings/soc/qcom/soc-sleep-stats.yaml: 'additionalProperties' is a required property
/builds/robherring/linux-dt-review/Documentation/devicetree/bindings/soc/qcom/soc-sleep-stats.yaml: ignoring, error in schema:
warning: no schema found in file: ./Documentation/devicetree/bindings/soc/qcom/soc-sleep-stats.yaml
/builds/robherring/linux-dt-review/Documentation/devicetree/bindings/soc/qcom/soc-sleep-stats.example.dt.yaml: example-0: rpmh-sleep-stats@c3f0000:reg:0: [0, 205455360, 0, 1024] is too long
From schema: /usr/local/lib/python3.8/dist-packages/dtschema/schemas/reg.yaml
/builds/robherring/linux-dt-review/Documentation/devicetree/bindings/soc/qcom/soc-sleep-stats.example.dt.yaml: example-1: rpm-sleep-stats@4690000:reg:0: [0, 73990144, 0, 1024] is too long
From schema: /usr/local/lib/python3.8/dist-packages/dtschema/schemas/reg.yaml
See https://patchwork.ozlabs.org/patch/1436034
This check can fail if there are any dependencies. The base for a patch
series is generally the most recent rc1.
If you already ran 'make dt_binding_check' and didn't see the above
error(s), then make sure 'yamllint' is installed and dt-schema is up to
date:
pip3 install dtschema --upgrade
Please check and re-submit.
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH v6 1/4] dt-bindings: Introduce SoC sleep stats bindings
2021-02-04 14:21 ` [PATCH v6 1/4] dt-bindings: Introduce SoC sleep stats bindings Maulik Shah
2021-02-04 21:09 ` Rob Herring
@ 2021-02-09 0:23 ` Stephen Boyd
2021-03-12 17:14 ` Bjorn Andersson
2021-03-12 17:15 ` Bjorn Andersson
2 siblings, 1 reply; 7+ messages in thread
From: Stephen Boyd @ 2021-02-09 0:23 UTC (permalink / raw)
To: Maulik Shah, bjorn.andersson, evgreen, mka
Cc: linux-arm-msm, linux-kernel, agross, dianders, linux, rnayak,
ilina, lsrao, Mahesh Sivasubramanian, devicetree, Maulik Shah
Quoting Maulik Shah (2021-02-04 06:21:45)
> +
> +description:
> + Always On Processor/Resource Power Manager maintains statistics of the SoC
> + sleep modes involving powering down of the rails and oscillator clock.
> +
> + Statistics includes SoC sleep mode type, number of times low power mode were
> + entered, time of last entry, time of last exit and accumulated sleep duration.
> +
> +properties:
> + compatible:
> + enum:
> + - qcom,rpmh-sleep-stats
> + - qcom,rpm-sleep-stats
> +
> + reg:
> + maxItems: 1
> +
> +required:
> + - compatible
> + - reg
> +
> +examples:
> + # Example of rpmh sleep stats
> + - |
> + rpmh-sleep-stats@c3f0000 {
> + compatible = "qcom,rpmh-sleep-stats";
> + reg = <0 0x0c3f0000 0 0x400>;
> + };
Maybe it should just be another reg property of the rpmh or rpm node?
Then the rpmh driver can create the stats "device" at driver probe time,
or just roll it into the same thing. It looks pretty weird to have a
device in DT for this given that it's not really hardware, more like a
place that the processor writes some stuff about what's going on in the
SoC related to power management.
> + # Example of rpm sleep stats
> + - |
> + rpm-sleep-stats@4690000 {
> + compatible = "qcom,rpm-sleep-stats";
> + reg = <0 0x04690000 0 0x400>;
> + };
> +...
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH v6 1/4] dt-bindings: Introduce SoC sleep stats bindings
2021-02-09 0:23 ` Stephen Boyd
@ 2021-03-12 17:14 ` Bjorn Andersson
0 siblings, 0 replies; 7+ messages in thread
From: Bjorn Andersson @ 2021-03-12 17:14 UTC (permalink / raw)
To: Stephen Boyd
Cc: Maulik Shah, evgreen, mka, linux-arm-msm, linux-kernel, agross,
dianders, linux, rnayak, ilina, lsrao, Mahesh Sivasubramanian,
devicetree
On Mon 08 Feb 18:23 CST 2021, Stephen Boyd wrote:
> Quoting Maulik Shah (2021-02-04 06:21:45)
> > +
> > +description:
> > + Always On Processor/Resource Power Manager maintains statistics of the SoC
> > + sleep modes involving powering down of the rails and oscillator clock.
> > +
> > + Statistics includes SoC sleep mode type, number of times low power mode were
> > + entered, time of last entry, time of last exit and accumulated sleep duration.
> > +
> > +properties:
> > + compatible:
> > + enum:
> > + - qcom,rpmh-sleep-stats
> > + - qcom,rpm-sleep-stats
> > +
> > + reg:
> > + maxItems: 1
> > +
> > +required:
> > + - compatible
> > + - reg
> > +
> > +examples:
> > + # Example of rpmh sleep stats
> > + - |
> > + rpmh-sleep-stats@c3f0000 {
> > + compatible = "qcom,rpmh-sleep-stats";
> > + reg = <0 0x0c3f0000 0 0x400>;
> > + };
>
> Maybe it should just be another reg property of the rpmh or rpm node?
> Then the rpmh driver can create the stats "device" at driver probe time,
> or just roll it into the same thing. It looks pretty weird to have a
> device in DT for this given that it's not really hardware, more like a
> place that the processor writes some stuff about what's going on in the
> SoC related to power management.
>
Given that there is some hardware (although just a chunk of sram) and
that the same driver is used for RPM, which we don't represent on the
mmio bus I think the proposed design makes sense.
Regards,
Bjorn
> > + # Example of rpm sleep stats
> > + - |
> > + rpm-sleep-stats@4690000 {
> > + compatible = "qcom,rpm-sleep-stats";
> > + reg = <0 0x04690000 0 0x400>;
> > + };
> > +...
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH v6 1/4] dt-bindings: Introduce SoC sleep stats bindings
2021-02-04 14:21 ` [PATCH v6 1/4] dt-bindings: Introduce SoC sleep stats bindings Maulik Shah
2021-02-04 21:09 ` Rob Herring
2021-02-09 0:23 ` Stephen Boyd
@ 2021-03-12 17:15 ` Bjorn Andersson
2021-04-06 6:25 ` Maulik Shah
2 siblings, 1 reply; 7+ messages in thread
From: Bjorn Andersson @ 2021-03-12 17:15 UTC (permalink / raw)
To: Maulik Shah
Cc: swboyd, mka, evgreen, linux-arm-msm, linux-kernel, agross,
dianders, linux, rnayak, ilina, lsrao, Mahesh Sivasubramanian,
devicetree
On Thu 04 Feb 08:21 CST 2021, Maulik Shah wrote:
> From: Mahesh Sivasubramanian <msivasub@codeaurora.org>
>
> Add device binding documentation for Qualcomm Technologies, Inc. (QTI)
> SoC sleep stats driver. The driver is used for displaying SoC sleep
> statistic maintained by Always On Processor or Resource Power Manager.
>
> Cc: devicetree@vger.kernel.org
> Signed-off-by: Mahesh Sivasubramanian <msivasub@codeaurora.org>
> Signed-off-by: Lina Iyer <ilina@codeaurora.org>
> Signed-off-by: Maulik Shah <mkshah@codeaurora.org>
> Reviewed-by: Rob Herring <robh@kernel.org>
> Reviewed-by: Bjorn Andersson <bjorn.andersson@linaro.org>
> Reviewed-by: Stephen Boyd <swboyd@chromium.org>
> ---
> .../bindings/soc/qcom/soc-sleep-stats.yaml | 46 ++++++++++++++++++++++
> 1 file changed, 46 insertions(+)
> create mode 100644 Documentation/devicetree/bindings/soc/qcom/soc-sleep-stats.yaml
>
> diff --git a/Documentation/devicetree/bindings/soc/qcom/soc-sleep-stats.yaml b/Documentation/devicetree/bindings/soc/qcom/soc-sleep-stats.yaml
> new file mode 100644
> index 0000000..1e012ba
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/soc/qcom/soc-sleep-stats.yaml
> @@ -0,0 +1,46 @@
> +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
> +%YAML 1.2
> +---
> +$id: http://devicetree.org/schemas/soc/qcom/soc-sleep-stats.yaml#
> +$schema: http://devicetree.org/meta-schemas/core.yaml#
> +
> +title: Qualcomm Technologies, Inc. (QTI) SoC sleep stats bindings
> +
> +maintainers:
> + - Maulik Shah <mkshah@codeaurora.org>
> + - Lina Iyer <ilina@codeaurora.org>
> +
> +description:
> + Always On Processor/Resource Power Manager maintains statistics of the SoC
> + sleep modes involving powering down of the rails and oscillator clock.
> +
> + Statistics includes SoC sleep mode type, number of times low power mode were
> + entered, time of last entry, time of last exit and accumulated sleep duration.
> +
> +properties:
> + compatible:
> + enum:
> + - qcom,rpmh-sleep-stats
> + - qcom,rpm-sleep-stats
> +
> + reg:
> + maxItems: 1
> +
> +required:
> + - compatible
> + - reg
> +
> +examples:
> + # Example of rpmh sleep stats
> + - |
> + rpmh-sleep-stats@c3f0000 {
> + compatible = "qcom,rpmh-sleep-stats";
> + reg = <0 0x0c3f0000 0 0x400>;
The example is built with #address-cells = <1> and #size-cells = <1>, so
this needs to be reg = <0x0c3f0000 0x400>.
Regards,
Bjorn
> + };
> + # Example of rpm sleep stats
> + - |
> + rpm-sleep-stats@4690000 {
> + compatible = "qcom,rpm-sleep-stats";
> + reg = <0 0x04690000 0 0x400>;
> + };
> +...
> --
> QUALCOMM INDIA, on behalf of Qualcomm Innovation Center, Inc. is a member
> of Code Aurora Forum, hosted by The Linux Foundation
>
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH v6 1/4] dt-bindings: Introduce SoC sleep stats bindings
2021-03-12 17:15 ` Bjorn Andersson
@ 2021-04-06 6:25 ` Maulik Shah
0 siblings, 0 replies; 7+ messages in thread
From: Maulik Shah @ 2021-04-06 6:25 UTC (permalink / raw)
To: Bjorn Andersson
Cc: swboyd, mka, evgreen, linux-arm-msm, linux-kernel, agross,
dianders, linux, rnayak, ilina, lsrao, Mahesh Sivasubramanian,
devicetree
Hi,
On 3/12/2021 10:45 PM, Bjorn Andersson wrote:
> On Thu 04 Feb 08:21 CST 2021, Maulik Shah wrote:
>
>> From: Mahesh Sivasubramanian <msivasub@codeaurora.org>
>>
>> Add device binding documentation for Qualcomm Technologies, Inc. (QTI)
>> SoC sleep stats driver. The driver is used for displaying SoC sleep
>> statistic maintained by Always On Processor or Resource Power Manager.
>>
>> Cc: devicetree@vger.kernel.org
>> Signed-off-by: Mahesh Sivasubramanian <msivasub@codeaurora.org>
>> Signed-off-by: Lina Iyer <ilina@codeaurora.org>
>> Signed-off-by: Maulik Shah <mkshah@codeaurora.org>
>> Reviewed-by: Rob Herring <robh@kernel.org>
>> Reviewed-by: Bjorn Andersson <bjorn.andersson@linaro.org>
>> Reviewed-by: Stephen Boyd <swboyd@chromium.org>
>> ---
>> .../bindings/soc/qcom/soc-sleep-stats.yaml | 46 ++++++++++++++++++++++
>> 1 file changed, 46 insertions(+)
>> create mode 100644 Documentation/devicetree/bindings/soc/qcom/soc-sleep-stats.yaml
>>
>> diff --git a/Documentation/devicetree/bindings/soc/qcom/soc-sleep-stats.yaml b/Documentation/devicetree/bindings/soc/qcom/soc-sleep-stats.yaml
>> new file mode 100644
>> index 0000000..1e012ba
>> --- /dev/null
>> +++ b/Documentation/devicetree/bindings/soc/qcom/soc-sleep-stats.yaml
>> @@ -0,0 +1,46 @@
>> +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
>> +%YAML 1.2
>> +---
>> +$id: http://devicetree.org/schemas/soc/qcom/soc-sleep-stats.yaml#
>> +$schema: http://devicetree.org/meta-schemas/core.yaml#
>> +
>> +title: Qualcomm Technologies, Inc. (QTI) SoC sleep stats bindings
>> +
>> +maintainers:
>> + - Maulik Shah <mkshah@codeaurora.org>
>> + - Lina Iyer <ilina@codeaurora.org>
>> +
>> +description:
>> + Always On Processor/Resource Power Manager maintains statistics of the SoC
>> + sleep modes involving powering down of the rails and oscillator clock.
>> +
>> + Statistics includes SoC sleep mode type, number of times low power mode were
>> + entered, time of last entry, time of last exit and accumulated sleep duration.
>> +
>> +properties:
>> + compatible:
>> + enum:
>> + - qcom,rpmh-sleep-stats
>> + - qcom,rpm-sleep-stats
>> +
>> + reg:
>> + maxItems: 1
>> +
>> +required:
>> + - compatible
>> + - reg
>> +
>> +examples:
>> + # Example of rpmh sleep stats
>> + - |
>> + rpmh-sleep-stats@c3f0000 {
>> + compatible = "qcom,rpmh-sleep-stats";
>> + reg = <0 0x0c3f0000 0 0x400>;
> The example is built with #address-cells = <1> and #size-cells = <1>, so
> this needs to be reg = <0x0c3f0000 0x400>.
>
> Regards,
> Bjorn
Thanks, Fixed in v7.
Thanks,
Maulik
>
>> + };
>> + # Example of rpm sleep stats
>> + - |
>> + rpm-sleep-stats@4690000 {
>> + compatible = "qcom,rpm-sleep-stats";
>> + reg = <0 0x04690000 0 0x400>;
>> + };
>> +...
>> --
>> QUALCOMM INDIA, on behalf of Qualcomm Innovation Center, Inc. is a member
>> of Code Aurora Forum, hosted by The Linux Foundation
>>
--
QUALCOMM INDIA, on behalf of Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, hosted by The Linux Foundation
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2021-04-06 6:25 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <1612448508-9179-1-git-send-email-mkshah@codeaurora.org>
2021-02-04 14:21 ` [PATCH v6 1/4] dt-bindings: Introduce SoC sleep stats bindings Maulik Shah
2021-02-04 21:09 ` Rob Herring
2021-02-09 0:23 ` Stephen Boyd
2021-03-12 17:14 ` Bjorn Andersson
2021-03-12 17:15 ` Bjorn Andersson
2021-04-06 6:25 ` Maulik Shah
2021-02-04 14:21 ` [PATCH v6 3/4] arm64: dts: qcom: sc7180: Enable SoC sleep stats Maulik Shah
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).