efi: make efi_guid_to_str() take a const GUID pointer

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>
Signed-off-by: Ard Biesheuvel <ardb@kernel.org>
This commit is contained in:
Vincent Mailhol 2026-07-22 23:22:25 +02:00 committed by Ard Biesheuvel
parent 4b2c033b5b
commit 01787ed2fd

View File

@ -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;