]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
boot: drop const from EFI_PHYSICAL_ADDRESS parameter
authorLennart Poettering <lennart@poettering.net>
Wed, 16 Mar 2022 09:34:53 +0000 (10:34 +0100)
committerLennart Poettering <lennart@poettering.net>
Wed, 16 Mar 2022 16:33:28 +0000 (17:33 +0100)
It's not a pointer after all, but a numeric value. As such the const
applies to the value and not the target, but we genreally don#t do that
for value parameters. Hence drop the const.

src/boot/efi/measure.c
src/boot/efi/measure.h

index 992acde527c111638b92b6354461d7e29bc5297e..5c082b537c75867d527b8869a9c1f3aabcaa8b53 100644 (file)
@@ -139,7 +139,7 @@ BOOLEAN tpm_present(void) {
         return tcg2_interface_check() || tcg1_interface_check();
 }
 
-EFI_STATUS tpm_log_event(UINT32 pcrindex, const EFI_PHYSICAL_ADDRESS buffer, UINTN buffer_size, const CHAR16 *description) {
+EFI_STATUS tpm_log_event(UINT32 pcrindex, EFI_PHYSICAL_ADDRESS buffer, UINTN buffer_size, const CHAR16 *description) {
         EFI_TCG *tpm1;
         EFI_TCG2 *tpm2;
 
index ffa49245626cbc383d10e66f114abd8bf2375d38..33c98aaf73323a558814ef55b608a74d6f1bb797 100644 (file)
@@ -6,7 +6,7 @@
 #if ENABLE_TPM
 
 BOOLEAN tpm_present(void);
-EFI_STATUS tpm_log_event(UINT32 pcrindex, const EFI_PHYSICAL_ADDRESS buffer, UINTN buffer_size, const CHAR16 *description);
+EFI_STATUS tpm_log_event(UINT32 pcrindex, EFI_PHYSICAL_ADDRESS buffer, UINTN buffer_size, const CHAR16 *description);
 EFI_STATUS tpm_log_load_options(const CHAR16 *cmdline);
 
 #else
@@ -14,9 +14,11 @@ EFI_STATUS tpm_log_load_options(const CHAR16 *cmdline);
 static inline BOOLEAN tpm_present(void) {
         return FALSE;
 }
-static inline EFI_STATUS tpm_log_event(UINT32 pcrindex, const EFI_PHYSICAL_ADDRESS buffer, UINTN buffer_size, const CHAR16 *description) {
+
+static inline EFI_STATUS tpm_log_event(UINT32 pcrindex, EFI_PHYSICAL_ADDRESS buffer, UINTN buffer_size, const CHAR16 *description) {
         return EFI_SUCCESS;
 }
+
 static inline EFI_STATUS tpm_log_load_options(const CHAR16 *cmdline) {
         return EFI_SUCCESS;
 }