This patch adds the definition for the nvmem location "encoding_mode"
related to the "cpu0" node.
Signed-off-by: Rodolfo Giometti <giometti@enneenne.com>
---
arch/arm/boot/dts/st/stm32mp131.dtsi | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/arch/arm/boot/dts/st/stm32mp131.dtsi b/arch/arm/boot/dts/st/stm32mp131.dtsi
index e555717c0048..52bf497e26bb 100644
--- a/arch/arm/boot/dts/st/stm32mp131.dtsi
+++ b/arch/arm/boot/dts/st/stm32mp131.dtsi
@@ -24,6 +24,9 @@ cpu0: cpu@0 {
clocks = <&scmi_perf 0>;
clock-names = "cpu";
#cooling-cells = <2>;
+
+ nvmem-cells = <&encoding_mode_otp>;
+ nvmem-cell-names = "encoding_mode";
};
};
@@ -1167,6 +1170,10 @@ part_number_otp: part-number-otp@4 {
reg = <0x4 0x2>;
bits = <0 12>;
};
+ encoding_mode_otp: encoding-mode-otp@4 {
+ reg = <0x0 0x1>;
+ bits = <0 9>;
+ };
vrefint: vrefin-cal@52 {
reg = <0x52 0x2>;
};
--
2.25.1
On 5/19/25 15:08, Rodolfo Giometti wrote:
> This patch adds the definition for the nvmem location "encoding_mode"
> related to the "cpu0" node.
>
> Signed-off-by: Rodolfo Giometti <giometti@enneenne.com>
> ---
> arch/arm/boot/dts/st/stm32mp131.dtsi | 7 +++++++
> 1 file changed, 7 insertions(+)
>
> diff --git a/arch/arm/boot/dts/st/stm32mp131.dtsi b/arch/arm/boot/dts/st/stm32mp131.dtsi
> index e555717c0048..52bf497e26bb 100644
> --- a/arch/arm/boot/dts/st/stm32mp131.dtsi
> +++ b/arch/arm/boot/dts/st/stm32mp131.dtsi
> @@ -24,6 +24,9 @@ cpu0: cpu@0 {
> clocks = <&scmi_perf 0>;
> clock-names = "cpu";
> #cooling-cells = <2>;
> +
> + nvmem-cells = <&encoding_mode_otp>;
> + nvmem-cell-names = "encoding_mode";
> };
> };
>
> @@ -1167,6 +1170,10 @@ part_number_otp: part-number-otp@4 {
> reg = <0x4 0x2>;
> bits = <0 12>;
> };
> + encoding_mode_otp: encoding-mode-otp@4 {
This node should end with @0 instead of 4.
It should also be placed before part-number-otp node.
> + reg = <0x0 0x1>;
If I'm not mistaken, this should be:
reg = <0x0 0x2>;
Best regards,
Yann
> + bits = <0 9>;
> + };
> vrefint: vrefin-cal@52 {
> reg = <0x52 0x2>;
> };
On 5/20/25 10:26, Yann Gautier wrote:
> On 5/19/25 15:08, Rodolfo Giometti wrote:
>> This patch adds the definition for the nvmem location "encoding_mode"
>> related to the "cpu0" node.
>>
>> Signed-off-by: Rodolfo Giometti <giometti@enneenne.com>
>> ---
>> arch/arm/boot/dts/st/stm32mp131.dtsi | 7 +++++++
>> 1 file changed, 7 insertions(+)
>>
>> diff --git a/arch/arm/boot/dts/st/stm32mp131.dtsi
>> b/arch/arm/boot/dts/st/stm32mp131.dtsi
>> index e555717c0048..52bf497e26bb 100644
>> --- a/arch/arm/boot/dts/st/stm32mp131.dtsi
>> +++ b/arch/arm/boot/dts/st/stm32mp131.dtsi
>> @@ -24,6 +24,9 @@ cpu0: cpu@0 {
>> clocks = <&scmi_perf 0>;
>> clock-names = "cpu";
>> #cooling-cells = <2>;
>> +
>> + nvmem-cells = <&encoding_mode_otp>;
>> + nvmem-cell-names = "encoding_mode";
>> };
>> };
>> @@ -1167,6 +1170,10 @@ part_number_otp: part-number-otp@4 {
>> reg = <0x4 0x2>;
>> bits = <0 12>;
>> };
>> + encoding_mode_otp: encoding-mode-otp@4 {
>
> This node should end with @0 instead of 4.
> It should also be placed before part-number-otp node.
I forgot that this node already was in TF-A, with a different name.
This is better to align it here, the the node would become:
cfg0_otp: cfg0-otp@0 {
reg = <0x0 0x2>;
bits = <0 9>;
};
Best regards,
Yann
>
>> + reg = <0x0 0x1>;
>
> If I'm not mistaken, this should be:
> reg = <0x0 0x2>;
>
>
> Best regards,
> Yann
>
>> + bits = <0 9>;
>> + };
>> vrefint: vrefin-cal@52 {
>> reg = <0x52 0x2>;
>> };
>
On 19/05/2025 15:08, Rodolfo Giometti wrote:
> This patch adds the definition for the nvmem location "encoding_mode"
Please do not use "This commit/patch/change", but imperative mood. See
longer explanation here:
https://elixir.bootlin.com/linux/v5.17.1/source/Documentation/process/submitting-patches.rst#L95
> related to the "cpu0" node.
>
> Signed-off-by: Rodolfo Giometti <giometti@enneenne.com>
> ---
> arch/arm/boot/dts/st/stm32mp131.dtsi | 7 +++++++
Please use subject prefixes matching the subsystem. You can get them for
example with `git log --oneline -- DIRECTORY_OR_FILE` on the directory
your patch is touching. For bindings, the preferred subjects are
explained here:
https://www.kernel.org/doc/html/latest/devicetree/bindings/submitting-patches.html#i-for-patch-submitters
Please use scripts/get_maintainers.pl to get a list of necessary people
and lists to CC (and consider --no-git-fallback argument, so you will
not CC people just because they made one commit years ago). It might
happen, that command when run on an older kernel, gives you outdated
entries. Therefore please be sure you base your patches on recent Linux
kernel.
Tools like b4 or scripts/get_maintainer.pl provide you proper list of
people, so fix your workflow. Tools might also fail if you work on some
ancient tree (don't, instead use mainline) or work on fork of kernel
(don't, instead use mainline). Just use b4 and everything should be
fine, although remember about `b4 prep --auto-to-cc` if you added new
patches to the patchset.
> 1 file changed, 7 insertions(+)
>
> diff --git a/arch/arm/boot/dts/st/stm32mp131.dtsi b/arch/arm/boot/dts/st/stm32mp131.dtsi
> index e555717c0048..52bf497e26bb 100644
> --- a/arch/arm/boot/dts/st/stm32mp131.dtsi
> +++ b/arch/arm/boot/dts/st/stm32mp131.dtsi
> @@ -24,6 +24,9 @@ cpu0: cpu@0 {
> clocks = <&scmi_perf 0>;
> clock-names = "cpu";
> #cooling-cells = <2>;
> +
> + nvmem-cells = <&encoding_mode_otp>;
> + nvmem-cell-names = "encoding_mode";
Are you sure this passes dtbs_check?
Best regards,
Krzysztof
On 19/05/2025 20:35, Krzysztof Kozlowski wrote: > On 19/05/2025 15:08, Rodolfo Giometti wrote: >> This patch adds the definition for the nvmem location "encoding_mode" > > Please do not use "This commit/patch/change", but imperative mood. See > longer explanation here: > https://elixir.bootlin.com/linux/v5.17.1/source/Documentation/process/submitting-patches.rst#L95 > ... and please use standard email subjects, so with the PATCH keyword in the title. `git format-patch -vX` helps here to create proper versioned patches. Another useful tool is b4. Skipping the PATCH keyword makes filtering of emails more difficult thus making the review process less convenient. Best regards, Krzysztof
© 2016 - 2025 Red Hat, Inc.