Linux-ARM-Kernel Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Frank Li <Frank.li@nxp.com>
To: Pankaj Gupta <pankaj.gupta@nxp.com>
Cc: Jonathan Corbet <corbet@lwn.net>, 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-doc@vger.kernel.org" <linux-doc@vger.kernel.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"devicetree@vger.kernel.org" <devicetree@vger.kernel.org>,
	"imx@lists.linux.dev" <imx@lists.linux.dev>,
	"linux-arm-kernel@lists.infradead.org"
	<linux-arm-kernel@lists.infradead.org>
Subject: Re: [PATCH v14 4/6] firmware: imx: add driver for NXP EdgeLock Enclave
Date: Fri, 4 Apr 2025 12:50:02 -0400	[thread overview]
Message-ID: <Z/ANuvgHRRTUWV0x@lizhi-Precision-Tower-5810> (raw)
In-Reply-To: <AM9PR04MB8604F5E033F9C0985F29BD5F95AE2@AM9PR04MB8604.eurprd04.prod.outlook.com>

On Thu, Apr 03, 2025 at 05:02:08AM +0000, Pankaj Gupta wrote:
> On Wed, Apr 02, 2025 at 06:15:12AM +0000, Pankaj Gupta wrote:
> >> >> diff --git a/drivers/firmware/imx/se_ctrl.h
> >> >> b/drivers/firmware/imx/se_ctrl.h new file mode 100644 index
> >> >> 000000000000..177623f3890e
> >> >> --- /dev/null
> >> >> +++ b/drivers/firmware/imx/se_ctrl.h
> >> >> @@ -0,0 +1,84 @@
> >> >> +/* SPDX-License-Identifier: GPL-2.0+ */
> >> >> +/*
> >> >> + * Copyright 2025 NXP
> >> >> + */
> >> >> +
> >> >> +#ifndef SE_MU_H
> >> >> +#define SE_MU_H
> >> >> +
> >> >> +#include <linux/miscdevice.h>
> >> >> +#include <linux/semaphore.h>
> >> >> +#include <linux/mailbox_client.h>
> >> >> +
> >>
> >> ....
> >>
> >> >> +};
> >> >> +
> >> >> +struct se_if_defines {
> >> >> +	const u8 se_if_type;
> >> >> +	const u8 se_instance_id;
> >> Getting used at drivers/firmware/imx/se_ctrl.c:320
>
> >	dev_info(dev, "i.MX secure-enclave: %s%d interface to firmware,
> configured.",
> >		 SE_TYPE_STR_HSM,
> >		 priv->if_defs->se_instance_id);
>
> > You only print value, don't actual use it. It should be safe remove it
>
> > Frank
>
> No, it is not just used for print.
> This variable is used to construct the device name as well, in 5/6 patch.
>
> Moreover, it is needed for other SoC like i.MX8DXL, i.MX95, i.MX94, there
> are multiple instances of same secure-enclave type.
> It will be used to identify the intended instance later.

But it all is 0 now. Add it back when it really need in future.

Frank
>
> >>
> >> > This is not used actually, you can remove it
> >> Getting used at drivers/firmware/imx/se_ctrl.c:347
> >>
> >> >> +	u8 cmd_tag;
> >> >> +	u8 rsp_tag;
> >> >> +	u8 success_tag;
> >> >> +	u8 base_api_ver;
> >> >> +	u8 fw_api_ver;
> >> >> +};
> >> >> +
> >> >> +struct se_if_priv {
> >> >> +	struct device *dev;
> >> >> +
>
>




  reply	other threads:[~2025-04-04 16:53 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-03-26 18:37 [PATCH v14 0/6] v14: firmware: imx: driver for NXP secure-enclave Pankaj Gupta
2025-03-26 15:04 ` Frank Li
2025-03-26 18:37 ` [PATCH v14 1/6] Documentation/firmware: add imx/se to other_interfaces Pankaj Gupta
2025-03-26 18:37 ` [PATCH v14 2/6] dt-bindings: arm: fsl: add imx-se-fw binding doc Pankaj Gupta
2025-03-26 18:37 ` [PATCH v14 3/6] arm64: dts: imx8ulp-evk: add nxp secure enclave firmware Pankaj Gupta
2025-03-26 15:03   ` Frank Li
2025-03-26 18:38 ` [PATCH v14 4/6] firmware: imx: add driver for NXP EdgeLock Enclave Pankaj Gupta
2025-03-26 15:33   ` Frank Li
2025-04-01 11:51     ` Pankaj Gupta
     [not found]     ` <AM9PR04MB86040127423D0A657103589D95AC2@AM9PR04MB8604.eurprd04.prod.outlook.com>
2025-04-02  6:14       ` Pankaj Gupta
     [not found]     ` <AM9PR04MB86048345C11F8878146AFE9A95AC2@AM9PR04MB8604.eurprd04.prod.outlook.com>
2025-04-02  6:15       ` Pankaj Gupta
     [not found]     ` <AM9PR04MB8604C02C27C8C43FF89B95DC95AC2@AM9PR04MB8604.eurprd04.prod.outlook.com>
2025-04-02  6:15       ` Pankaj Gupta
2025-04-02 21:20         ` Frank Li
2025-04-03  5:02           ` Pankaj Gupta
2025-04-04 16:50             ` Frank Li [this message]
2025-03-26 18:38 ` [PATCH v14 5/6] firmware: imx: device context dedicated to priv Pankaj Gupta
2025-03-26 15:34   ` Frank Li
2025-03-26 18:38 ` [PATCH v14 6/6] firmware: drivers: imx: adds miscdev Pankaj Gupta
2025-03-26 16:00   ` Frank Li
     [not found]     ` <AM9PR04MB8604940F813742ACA6CA307595AC2@AM9PR04MB8604.eurprd04.prod.outlook.com>
2025-04-02  6:19       ` Pankaj Gupta

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=Z/ANuvgHRRTUWV0x@lizhi-Precision-Tower-5810 \
    --to=frank.li@nxp.com \
    --cc=conor+dt@kernel.org \
    --cc=corbet@lwn.net \
    --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-doc@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=pankaj.gupta@nxp.com \
    --cc=robh@kernel.org \
    --cc=s.hauer@pengutronix.de \
    --cc=shawnguo@kernel.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