[PATCH] xen/efi: Show error message for EFI_INVALID_PARAMETER error

Frediano Ziglio posted 1 patch 4 months, 1 week ago
Patches applied successfully (tree, apply log)
git fetch https://gitlab.com/xen-project/patchew/xen tags/patchew/20250624063541.236691-1-frediano.ziglio@cloud.com
xen/common/efi/boot.c | 3 +++
1 file changed, 3 insertions(+)
[PATCH] xen/efi: Show error message for EFI_INVALID_PARAMETER error
Posted by Frediano Ziglio 4 months, 1 week ago
Show string message instead of code.
This happened trying some different ways to boot Xen, specifically
trying loading xen.efi using GRUB2 "linux" command.

Signed-off-by: Frediano Ziglio <frediano.ziglio@cloud.com>
---
 xen/common/efi/boot.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/xen/common/efi/boot.c b/xen/common/efi/boot.c
index fb3b120982..ded7cc129d 100644
--- a/xen/common/efi/boot.c
+++ b/xen/common/efi/boot.c
@@ -329,6 +329,9 @@ static void __init PrintErrMesg(const CHAR16 *mesg, EFI_STATUS ErrCode)
     case EFI_BUFFER_TOO_SMALL:
         mesg = L"Buffer too small";
         break;
+    case EFI_INVALID_PARAMETER:
+        mesg = L"Invalid parameter";
+        break;
     default:
         PrintErr(L"ErrCode: ");
         DisplayUint(ErrCode, 0);
-- 
2.43.0
Re: [PATCH] xen/efi: Show error message for EFI_INVALID_PARAMETER error
Posted by Marek Marczykowski-Górecki 4 months, 1 week ago
On Tue, Jun 24, 2025 at 07:35:39AM +0100, Frediano Ziglio wrote:
> Show string message instead of code.
> This happened trying some different ways to boot Xen, specifically
> trying loading xen.efi using GRUB2 "linux" command.
> 
> Signed-off-by: Frediano Ziglio <frediano.ziglio@cloud.com>

Acked-by: Marek Marczykowski-Górecki <marmarek@invisiblethingslab.com>

> ---
>  xen/common/efi/boot.c | 3 +++
>  1 file changed, 3 insertions(+)
> 
> diff --git a/xen/common/efi/boot.c b/xen/common/efi/boot.c
> index fb3b120982..ded7cc129d 100644
> --- a/xen/common/efi/boot.c
> +++ b/xen/common/efi/boot.c
> @@ -329,6 +329,9 @@ static void __init PrintErrMesg(const CHAR16 *mesg, EFI_STATUS ErrCode)
>      case EFI_BUFFER_TOO_SMALL:
>          mesg = L"Buffer too small";
>          break;
> +    case EFI_INVALID_PARAMETER:
> +        mesg = L"Invalid parameter";
> +        break;
>      default:
>          PrintErr(L"ErrCode: ");
>          DisplayUint(ErrCode, 0);
> -- 
> 2.43.0
> 

-- 
Best Regards,
Marek Marczykowski-Górecki
Invisible Things Lab