devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Alexander Stein <alexander.stein@ew.tq-group.com>
To: "Peng Fan (OSS)" <peng.fan@oss.nxp.com>, Peng Fan <peng.fan@nxp.com>
Cc: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>,
	Rob Herring <robh@kernel.org>,
	Krzysztof Kozlowski <krzk+dt@kernel.org>,
	Conor Dooley <conor+dt@kernel.org>,
	Shawn Guo <shawnguo@kernel.org>,
	Sascha Hauer <s.hauer@pengutronix.de>,
	Pengutronix Kernel Team <kernel@pengutronix.de>,
	Fabio Estevam <festevam@gmail.com>,
	"linux-arm-kernel@lists.infradead.org"
	<linux-arm-kernel@lists.infradead.org>,
	"devicetree@vger.kernel.org" <devicetree@vger.kernel.org>,
	"imx@lists.linux.dev" <imx@lists.linux.dev>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH v5 2/2] nvmem: imx-ocotp-ele: Support accessing controller for i.MX9
Date: Wed, 15 Jan 2025 07:56:03 +0100	[thread overview]
Message-ID: <6018578.MhkbZ0Pkbq@steina-w> (raw)
In-Reply-To: <PAXPR04MB84598515572A669E5856379F88182@PAXPR04MB8459.eurprd04.prod.outlook.com>

Hi,

Am Dienstag, 14. Januar 2025, 09:35:41 CET schrieb Peng Fan:
> > Subject: Re: [PATCH v5 2/2] nvmem: imx-ocotp-ele: Support accessing
> > controller for i.MX9
> > 
> > Hi,
> > 
> > Am Samstag, 11. Januar 2025, 13:41:58 CET schrieb Peng Fan:
> > > > Subject: Re: [PATCH v5 2/2] nvmem: imx-ocotp-ele: Support
> > accessing
> > > > controller for i.MX9
> > > >
> > > > Hi,
> > > >
> > > > Am Donnerstag, 9. Januar 2025, 04:34:18 CET schrieb Peng Fan:
> > > > > On Wed, Jan 08, 2025 at 11:15:40AM +0100, Alexander Stein
> > wrote:
> > > > > >Hi Peng,
> > > > > >
> > > > > >Am Mittwoch, 8. Januar 2025, 08:00:18 CET schrieb Peng Fan
> > (OSS):
> > > > > >> From: Peng Fan <peng.fan@nxp.com>
> > > > > >>
> > > > > >> i.MX9 OCOTP supports a specific peripheral or function being
> > > > fused
> > > > > >> which means disabled, so
> > > > > >>  - Introduce ocotp_access_gates to be container of efuse gate
> > > > > >> info
> > > > > >>  - Iterate all nodes to check accessing permission. If not
> > > > > >>    allowed to be accessed, detach the node
> > > > > >>
> > > > > >> Signed-off-by: Peng Fan <peng.fan@nxp.com>
> > > > > >> ---
> > > > > >>  drivers/nvmem/imx-ocotp-ele.c | 172
> > > > > >> +++++++++++++++++++++++++++++++++++++++++-
> > > > > >>  1 file changed, 171 insertions(+), 1 deletion(-)
> > > > > >>
> > > > > [....]
> > > > > >> +
> > > > > >> +	return imx_ele_ocotp_access_control(priv);
> > > > > >
> > > > > >In [1] you mentioned devlink should solve the probe order. How
> > > > does
> > > > > >this play when the driver is compiled in (e.g. ethernet for NFS
> > > > > >boot) but this OCOTP driver is just a module?
> > > > >
> > > > > OCOTP needs to built in for using devlink. Or the users needs to
> > > > > be built as module.
> > > >
> > > > I don't like this kind of assumption. Would it make more sense to
> > > > make CONFIG_NVMEM_IMX_OCOTP_ELE as bool instead of tristate?
> > >
> > > No. Users could setup their own system with this driver build in or
> > > built related drivers as modules.
> > 
> > Sure, but if the kernel locks/fails/panics while accessing peripherals just
> > because of the kernel config seems at east very unfortunate to me.
> > How is someone supposed to analyze/debug this?
> > 
> > > At least for Android GKI, this driver needs to be as module.
> > 
> > Any particular reason this needs to be a module?
> 
> Android has a minimal kernel which is controlled by Google.
> Vendors could only built modules based on Google's Image.
> 
> Updating this to y in upstream, means we need to change
> it back to m in NXP downstream android kernel.

Ok, that's an Android thing.

> If you need it built in, you could modify your downstream
> config, right?

I'm not saying I need a built-in. My concern is that a wrong Kconfig will
result in silent errors/lockups.

Best regards,
Alexander
-- 
TQ-Systems GmbH | Mühlstraße 2, Gut Delling | 82229 Seefeld, Germany
Amtsgericht München, HRB 105018
Geschäftsführer: Detlef Schneider, Rüdiger Stahl, Stefan Schneider
http://www.tq-group.com/



  reply	other threads:[~2025-01-15  6:56 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-01-08  7:00 [PATCH v5 0/2] Make i.MX9 OCOTP work as accessing controller Peng Fan (OSS)
2025-01-08  7:00 ` [PATCH v5 1/2] dt-bindings: nvmem: imx-ocotp: Introduce #access-controller-cells Peng Fan (OSS)
2025-01-08  7:00 ` [PATCH v5 2/2] nvmem: imx-ocotp-ele: Support accessing controller for i.MX9 Peng Fan (OSS)
2025-01-08 10:15   ` Alexander Stein
2025-01-09  3:34     ` Peng Fan
2025-01-09 10:34       ` Alexander Stein
2025-01-11 12:41         ` Peng Fan
2025-01-13 12:16           ` Alexander Stein
2025-01-14  8:35             ` Peng Fan
2025-01-15  6:56               ` Alexander Stein [this message]
2025-01-16  2:09                 ` Peng Fan
2025-01-16 15:47                   ` Alexander Stein

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=6018578.MhkbZ0Pkbq@steina-w \
    --to=alexander.stein@ew.tq-group.com \
    --cc=conor+dt@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=festevam@gmail.com \
    --cc=imx@lists.linux.dev \
    --cc=kernel@pengutronix.de \
    --cc=krzk+dt@kernel.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=peng.fan@nxp.com \
    --cc=peng.fan@oss.nxp.com \
    --cc=robh@kernel.org \
    --cc=s.hauer@pengutronix.de \
    --cc=shawnguo@kernel.org \
    --cc=srinivas.kandagatla@linaro.org \
    /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;
as well as URLs for NNTP newsgroup(s).