Linux EFI development
 help / color / mirror / Atom feed
From: "Ard Biesheuvel" <ardb@kernel.org>
To: "Vincent Mailhol" <mailhol@kernel.org>,
	"Ilias Apalodimas" <ilias.apalodimas@linaro.org>
Cc: linux-efi@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] efi: make efi_guid_to_str() take a const GUID pointer
Date: Thu, 23 Jul 2026 08:44:48 +0200	[thread overview]
Message-ID: <4ab2fe3a-f828-4f79-b13b-217c48d76ceb@app.fastmail.com> (raw)
In-Reply-To: <20260722-efi_guid_to_str-const-guid-v1-1-c12a105da2ee@kernel.org>



On Wed, 22 Jul 2026, at 23:22, Vincent Mailhol wrote:
> efi_guid_to_str() only formats the GUID through the byte array passed to
> the UUID printf formatter. It does not modify the GUID contents.
>
> Make the input pointer const so callers can stringify GUIDs from const
> data without a cast.
>
> Signed-off-by: Vincent Mailhol <mailhol@kernel.org>
> ---
>  include/linux/efi.h | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>

Applied, thanks.

> diff --git a/include/linux/efi.h b/include/linux/efi.h
> index ccbc35479684..cf5cc85e3fc8 100644
> --- a/include/linux/efi.h
> +++ b/include/linux/efi.h
> @@ -705,7 +705,7 @@ efi_guidcmp (efi_guid_t left, efi_guid_t right)
>  }
> 
>  static inline char *
> -efi_guid_to_str(efi_guid_t *guid, char *out)
> +efi_guid_to_str(const efi_guid_t *guid, char *out)
>  {
>  	sprintf(out, "%pUl", guid->b);
>          return out;
>
> ---
> base-commit: 1590cf0329716306e948a8fc29f1d3ee87d3989f
> change-id: 20260722-efi_guid_to_str-const-guid-a5b2accc7f0a
>
> Best regards,
> -- 
> Vincent Mailhol <mailhol@kernel.org>

      reply	other threads:[~2026-07-23  6:45 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-07-22 21:22 [PATCH] efi: make efi_guid_to_str() take a const GUID pointer Vincent Mailhol
2026-07-23  6:44 ` Ard Biesheuvel [this message]

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=4ab2fe3a-f828-4f79-b13b-217c48d76ceb@app.fastmail.com \
    --to=ardb@kernel.org \
    --cc=ilias.apalodimas@linaro.org \
    --cc=linux-efi@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mailhol@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