|
Pablo Greco |
d6c4c4 |
From 520e902d864930e2d4f329983d9ae9781a24231f Mon Sep 17 00:00:00 2001
|
|
Pablo Greco |
d6c4c4 |
From: Peter Jones <pjones@redhat.com>
|
|
Pablo Greco |
d6c4c4 |
Date: Mon, 2 Oct 2017 18:18:30 -0400
|
|
Pablo Greco |
d6c4c4 |
Subject: [PATCH 3/3] Make get_cert_list() use efi_status_to_str() to print
|
|
Pablo Greco |
d6c4c4 |
error messages.
|
|
Pablo Greco |
d6c4c4 |
|
|
Pablo Greco |
d6c4c4 |
Signed-off-by: Peter Jones <pjones@redhat.com>
|
|
Pablo Greco |
d6c4c4 |
---
|
|
Pablo Greco |
d6c4c4 |
security/integrity/platform_certs/load_uefi.c | 6 ++++--
|
|
Pablo Greco |
d6c4c4 |
1 file changed, 4 insertions(+), 2 deletions(-)
|
|
Pablo Greco |
d6c4c4 |
|
|
Pablo Greco |
d6c4c4 |
diff --git a/security/integrity/platform_certs/load_uefi.c b/security/integrity/platform_certs/load_uefi.c
|
|
Pablo Greco |
d6c4c4 |
index 9ef34c44fd1..13a2826715d 100644
|
|
Pablo Greco |
d6c4c4 |
--- a/security/integrity/platform_certs/load_uefi.c
|
|
Pablo Greco |
d6c4c4 |
+++ b/security/integrity/platform_certs/load_uefi.c
|
|
Pablo Greco |
d6c4c4 |
@@ -51,7 +51,8 @@ static __init int get_cert_list(efi_char16_t *name, efi_guid_t *guid,
|
|
Pablo Greco |
d6c4c4 |
}
|
|
Pablo Greco |
d6c4c4 |
|
|
Pablo Greco |
d6c4c4 |
if (status != EFI_BUFFER_TOO_SMALL) {
|
|
Pablo Greco |
d6c4c4 |
- pr_err("Couldn't get size: 0x%lx\n", status);
|
|
Pablo Greco |
d6c4c4 |
+ pr_err("Couldn't get size: %s (0x%lx)\n",
|
|
Pablo Greco |
d6c4c4 |
+ efi_status_to_str(status), status);
|
|
Pablo Greco |
d6c4c4 |
return efi_status_to_err(status);
|
|
Pablo Greco |
d6c4c4 |
}
|
|
Pablo Greco |
d6c4c4 |
|
|
Pablo Greco |
d6c4c4 |
@@ -64,7 +65,8 @@ static __init int get_cert_list(efi_char16_t *name, efi_guid_t *guid,
|
|
Pablo Greco |
d6c4c4 |
status = efi.get_variable(name, guid, NULL, &lsize, db);
|
|
Pablo Greco |
d6c4c4 |
if (status != EFI_SUCCESS) {
|
|
Pablo Greco |
d6c4c4 |
kfree(db);
|
|
Pablo Greco |
d6c4c4 |
- pr_err("Error reading db var: 0x%lx\n", status);
|
|
Pablo Greco |
d6c4c4 |
+ pr_err("Error reading db var: %s (0x%lx)\n",
|
|
Pablo Greco |
d6c4c4 |
+ efi_status_to_str(status), status);
|
|
Pablo Greco |
d6c4c4 |
return efi_status_to_err(status);
|
|
Pablo Greco |
d6c4c4 |
}
|
|
Pablo Greco |
d6c4c4 |
|
|
Pablo Greco |
d6c4c4 |
--
|
|
Pablo Greco |
d6c4c4 |
2.15.0
|
|
Pablo Greco |
d6c4c4 |
|