linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: Markus Elfring <Markus.Elfring@web.de>
To: Pankaj Gupta <pankaj.gupta@nxp.com>,
	imx@lists.linux.dev, devicetree@vger.kernel.org,
	linux-doc@vger.kernel.org, kernel-janitors@vger.kernel.org,
	kernel@pengutronix.de, linux-arm-kernel@lists.infradead.org
Cc: LKML <linux-kernel@vger.kernel.org>,
	Conor Dooley <conor+dt@kernel.org>,
	Fabio Estevam <festevam@gmail.com>,
	Jonathan Corbet <corbet@lwn.net>,
	Krzysztof Kozlowski <krzk+dt@kernel.org>,
	Rob Herring <robh@kernel.org>,
	Sascha Hauer <s.hauer@pengutronix.de>,
	Shawn Guo <shawnguo@kernel.org>
Subject: Re: [PATCH v5 4/5] firmware: imx: add driver for NXP EdgeLock Enclave
Date: Fri, 12 Jul 2024 20:42:53 +0200	[thread overview]
Message-ID: <0d5656d6-91f1-40b2-828f-c844465f8da4@web.de> (raw)
In-Reply-To: <20240712-imx-se-if-v5-4-66a79903a872@nxp.com>

…
> +++ b/drivers/firmware/imx/ele_common.c
> @@ -0,0 +1,264 @@
> +int ele_msg_send(struct se_if_priv *priv, void *tx_msg)
> +{
> +	if (header->tag == priv->cmd_tag)
> +		lockdep_assert_held(&priv->se_if_cmd_lock);
> +
> +	scoped_guard(mutex, &priv->se_if_lock);
…

I interpret the documentation for this programming interface in the way
that such code may usually be used together with a (compound) statement.
https://elixir.bootlin.com/linux/v6.10-rc7/source/include/linux/cleanup.h#L137

How do you think about to apply a statement like “guard(mutex)(&priv->se_if_lock);” instead?
https://elixir.bootlin.com/linux/v6.10-rc7/source/include/linux/mutex.h#L196

Regards,
Markus


  reply	other threads:[~2024-07-12 18:43 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-07-12  6:19 [PATCH v5 0/5] Changes in v5: Pankaj Gupta
2024-07-12  6:19 ` [PATCH v5 1/5] Documentation/firmware: add imx/se to other_interfaces Pankaj Gupta
2024-07-12  6:19 ` [PATCH v5 2/5] dt-bindings: arm: fsl: add imx-se-fw binding doc Pankaj Gupta
2024-07-12 18:03   ` Rob Herring
2024-07-15  7:56     ` [EXT] " Pankaj Gupta
2024-07-18  5:11       ` Pankaj Gupta
2024-07-19 10:08         ` Pankaj Gupta
2024-07-12  6:19 ` [PATCH v5 3/5] arm64: dts: imx8ulp-evk: add nxp secure enclave firmware Pankaj Gupta
2024-07-12  6:19 ` [PATCH v5 4/5] firmware: imx: add driver for NXP EdgeLock Enclave Pankaj Gupta
2024-07-12 18:42   ` Markus Elfring [this message]
2024-07-13 17:56   ` Amit Singh Tomar
2024-07-15  9:02     ` [EXT] " Pankaj Gupta
2024-07-16  3:20       ` Amit Singh Tomar
2024-07-12  6:20 ` [PATCH v5 5/5] firmware: imx: adds miscdev Pankaj Gupta
2024-07-12 22:19   ` Frank Li
2024-07-15 10:56     ` Sascha Hauer
2024-07-16  4:50     ` Pankaj Gupta
2024-07-16 12:54       ` Fabio Estevam
2024-07-15  7:24   ` Amit Singh Tomar
2024-07-15  9:03     ` [EXT] " Pankaj Gupta
2024-07-16  3:30       ` Amit Singh Tomar
2024-07-12 18:15 ` [PATCH v5 0/5] Changes in v5: Markus Elfring

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=0d5656d6-91f1-40b2-828f-c844465f8da4@web.de \
    --to=markus.elfring@web.de \
    --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-janitors@vger.kernel.org \
    --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;
as well as URLs for NNTP newsgroup(s).