mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Rodolfo Giometti <giometti@enneenne.com>
To: Yann Gautier <yann.gautier@foss.st.com>,
	Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>
Cc: Maxime Coquelin <mcoquelin.stm32@gmail.com>,
	Alexandre Torgue <alexandre.torgue@foss.st.com>,
	Eric Fourmont <eric.fourmont-ext@st.com>,
	linux-kernel@vger.kernel.org
Subject: Re: [V1 2/2] drivers soc: add support for ST stm32mp13xx family
Date: Wed, 21 May 2025 17:44:18 +0200	[thread overview]
Message-ID: <cf69b49a-e2bf-44a9-ad7b-df01572457b0@enneenne.com> (raw)
In-Reply-To: <815b3972-8258-445a-a028-fd1707c7c1be@foss.st.com>

On 20/05/25 18:58, Yann Gautier wrote:
> On 5/19/25 15:08, Rodolfo Giometti wrote:

[snip]

>> +static int __init stm32mp13_soc_get_rpn_uid(u32 *rpn, u32 uid[3])
>> +{
>> +    struct device_node *np;
>> +    void __iomem *regs;
>> +    static const struct of_device_id devids[] = {
>> +        { .compatible = "st,stm32mp13-bsec" },
>> +        { },
>> +    };
> 
> As said by Krzysztof, you cannot access the OTP fuses this way.
> There is already a driver for that: drivers/nvmem/stm32-romem.c.
> And the information there should be accessed through nvmem framework.
> 
> For the UID, you should add this in your first patch:
>              uid_otp: uid-otp@34 {
>                  reg = <0x34 0xc>;
>              };
> 
> And add &part_number_otp and &uid_otp to your driver nvmem-cells property:
> nvmem-cells = <&cfg0_otp>, <&part_number_otp>, <&uid_otp>;

I see, but since the device is called by the device_initcall(), when I try to 
use the nvmem framework I always get the EPROBE_DEFER error. :(

Ciao,

Rodolfo

-- 
GNU/Linux Solutions                  e-mail: giometti@enneenne.com
Linux Device Driver                          giometti@linux.it
Embedded Systems                     phone:  +39 349 2432127
UNIX programming


  reply	other threads:[~2025-05-21 15:44 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-05-19 13:08 [V1 0/2] Add SoC support for stm32mp13xx CPUs Rodolfo Giometti
2025-05-19 13:08 ` [V1 1/2] arm stm32mp131.dtsi: add "encoding_mode" nvmem definition Rodolfo Giometti
2025-05-19 18:35   ` Krzysztof Kozlowski
2025-05-19 18:36     ` Krzysztof Kozlowski
2025-05-20  8:26   ` Yann Gautier
2025-05-20 16:29     ` Yann Gautier
2025-05-19 13:08 ` [V1 2/2] drivers soc: add support for ST stm32mp13xx family Rodolfo Giometti
2025-05-19 18:34   ` Krzysztof Kozlowski
2025-05-20  9:01     ` Rodolfo Giometti
2025-05-20  9:15       ` Krzysztof Kozlowski
2025-05-20  8:55   ` Alexandre TORGUE
2025-05-26 10:56     ` Rodolfo Giometti
2025-05-20 16:58   ` Yann Gautier
2025-05-21 15:44     ` Rodolfo Giometti [this message]
2025-05-21 16:37       ` Krzysztof Kozlowski

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=cf69b49a-e2bf-44a9-ad7b-df01572457b0@enneenne.com \
    --to=giometti@enneenne.com \
    --cc=alexandre.torgue@foss.st.com \
    --cc=eric.fourmont-ext@st.com \
    --cc=krzysztof.kozlowski+dt@linaro.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mcoquelin.stm32@gmail.com \
    --cc=yann.gautier@foss.st.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®