From: Marco Felsch <m.felsch@pengutronix.de>
To: Fabian Pflug <f.pflug@pengutronix.de>
Cc: BAREBOX <barebox@lists.infradead.org>
Subject: Re: [PATCH 2/4] nvmem: ocotp: extend support to query the sticky bit
Date: Thu, 18 Dec 2025 20:16:51 +0100 [thread overview]
Message-ID: <20251218191651.6jcpronwwvlk5cdz@pengutronix.de> (raw)
In-Reply-To: <20251218-v2025-11-0-topic-imx6-field-return-v1-2-3781143198d6@pengutronix.de>
On 25-12-18, Fabian Pflug wrote:
> The i.MX* devices do have an sticky bit which indicates if the
> field-return fuse can be written. Before only support for i.MX8* was
> provided. Extend this for the i.MX6* series.
>
> Signed-off-by: Fabian Pflug <f.pflug@pengutronix.de>
> ---
> drivers/nvmem/ocotp.c | 12 ++++++++----
> 1 file changed, 8 insertions(+), 4 deletions(-)
>
> diff --git a/drivers/nvmem/ocotp.c b/drivers/nvmem/ocotp.c
> index 7bca275404..1f74fddb60 100644
> --- a/drivers/nvmem/ocotp.c
> +++ b/drivers/nvmem/ocotp.c
> @@ -294,7 +294,7 @@ static void imx8m_lock_srk_revoke(struct ocotp_priv *priv)
> writel(val, priv->base + OCOTP_SW_STICKY);
> }
>
> -static bool imx8m_field_return_locked(struct ocotp_priv *priv)
> +static bool imx_field_return_locked(struct ocotp_priv *priv)
Nit: I would mention the rename within the commit message at least.
Reviewed-by: Marco Felsch <m.felsch@pengutronix.de>
> {
> return readl(priv->base + OCOTP_SW_STICKY) & OCOTP_SW_STICKY_FIELD_RETURN_LOCK;
> }
> @@ -990,6 +990,7 @@ static struct imx_ocotp_data imx6q_ocotp_data = {
> .fuse_blow = imx6_fuse_blow_addr,
> .fuse_read = imx6_fuse_read_addr,
> .ctrl = &ocotp_ctrl_reg_default,
> + .field_return_locked = imx_field_return_locked,
> };
>
> static struct imx_ocotp_data imx6sl_ocotp_data = {
> @@ -1002,6 +1003,7 @@ static struct imx_ocotp_data imx6sl_ocotp_data = {
> .fuse_blow = imx6_fuse_blow_addr,
> .fuse_read = imx6_fuse_read_addr,
> .ctrl = &ocotp_ctrl_reg_default,
> + .field_return_locked = imx_field_return_locked,
> };
>
> static struct imx_ocotp_data imx6ul_ocotp_data = {
> @@ -1014,6 +1016,7 @@ static struct imx_ocotp_data imx6ul_ocotp_data = {
> .fuse_blow = imx6_fuse_blow_addr,
> .fuse_read = imx6_fuse_read_addr,
> .ctrl = &ocotp_ctrl_reg_default,
> + .field_return_locked = imx_field_return_locked,
> };
>
> static struct imx_ocotp_data imx6ull_ocotp_data = {
> @@ -1026,6 +1029,7 @@ static struct imx_ocotp_data imx6ull_ocotp_data = {
> .fuse_blow = imx6_fuse_blow_addr,
> .fuse_read = imx6_fuse_read_addr,
> .ctrl = &ocotp_ctrl_reg_default,
> + .field_return_locked = imx_field_return_locked,
> };
>
> static struct imx_ocotp_data vf610_ocotp_data = {
> @@ -1063,7 +1067,7 @@ static struct imx_ocotp_data imx8mp_ocotp_data = {
> .fuse_read = imx6_fuse_read_addr,
> .srk_revoke_locked = imx8m_srk_revoke_locked,
> .lock_srk_revoke = imx8m_lock_srk_revoke,
> - .field_return_locked = imx8m_field_return_locked,
> + .field_return_locked = imx_field_return_locked,
> .ctrl = &ocotp_ctrl_reg_8mp,
> };
>
> @@ -1095,7 +1099,7 @@ static struct imx_ocotp_data imx8mm_ocotp_data = {
> .fuse_read = imx6_fuse_read_addr,
> .srk_revoke_locked = imx8m_srk_revoke_locked,
> .lock_srk_revoke = imx8m_lock_srk_revoke,
> - .field_return_locked = imx8m_field_return_locked,
> + .field_return_locked = imx_field_return_locked,
> .feat = &imx8mm_featctrl_data,
> .ctrl = &ocotp_ctrl_reg_default,
> };
> @@ -1116,7 +1120,7 @@ static struct imx_ocotp_data imx8mn_ocotp_data = {
> .fuse_read = imx6_fuse_read_addr,
> .srk_revoke_locked = imx8m_srk_revoke_locked,
> .lock_srk_revoke = imx8m_lock_srk_revoke,
> - .field_return_locked = imx8m_field_return_locked,
> + .field_return_locked = imx_field_return_locked,
> .feat = &imx8mn_featctrl_data,
> .ctrl = &ocotp_ctrl_reg_default,
> };
>
> --
> 2.47.3
>
>
--
#gernperDu
#CallMeByMyFirstName
Pengutronix e.K. | |
Steuerwalder Str. 21 | https://www.pengutronix.de/ |
31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-9 |
next prev parent reply other threads:[~2025-12-18 19:17 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-12-18 17:36 [PATCH 0/4] i.mx: hab/ocotop: extend field return to i.MX6 Fabian Pflug
2025-12-18 17:36 ` [PATCH 1/4] arm: mach-imx6: use kconfig for field return Fabian Pflug
2025-12-18 19:12 ` Marco Felsch
2025-12-18 17:36 ` [PATCH 2/4] nvmem: ocotp: extend support to query the sticky bit Fabian Pflug
2025-12-18 19:16 ` Marco Felsch [this message]
2025-12-18 17:36 ` [PATCH 3/4] i.MX: HAB: extend field_return support to imx6 Fabian Pflug
2025-12-18 19:23 ` Marco Felsch
2025-12-18 17:36 ` [PATCH 4/4] commands: hab: extend by field_return fuse burn Fabian Pflug
2025-12-18 20:03 ` Marco Felsch
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=20251218191651.6jcpronwwvlk5cdz@pengutronix.de \
--to=m.felsch@pengutronix.de \
--cc=barebox@lists.infradead.org \
--cc=f.pflug@pengutronix.de \
/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