diff mbox series

[v2,2/5] ima: Fix a build issue on 32-bit platforms

Message ID 20220624044811.9682-3-palmer@rivosinc.com (mailing list archive)
State Handled Elsewhere
Headers show
Series Support kexec_file on 32-bit RISC-V | expand

Commit Message

Palmer Dabbelt June 24, 2022, 4:48 a.m. UTC
ima_dump_measurement_list() took an "unsigned long *", but was passed a
size_t.  This triggers build warnings on 32-bit RISC-V.

Signed-off-by: Palmer Dabbelt <palmer@rivosinc.com>
---
 security/integrity/ima/ima_kexec.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Mimi Zohar June 30, 2022, 1:21 p.m. UTC | #1
On Thu, 2022-06-23 at 21:48 -0700, Palmer Dabbelt wrote:
> ima_dump_measurement_list() took an "unsigned long *", but was passed a
> size_t.  This triggers build warnings on 32-bit RISC-V.
> 
> Signed-off-by: Palmer Dabbelt <palmer@rivosinc.com>

Acked-by:  Mimi Zohar <zohar@linux.ibm.com>
diff mbox series

Patch

diff --git a/security/integrity/ima/ima_kexec.c b/security/integrity/ima/ima_kexec.c
index 13753136f03f..f2a94ec3002a 100644
--- a/security/integrity/ima/ima_kexec.c
+++ b/security/integrity/ima/ima_kexec.c
@@ -15,7 +15,7 @@ 
 #include "ima.h"
 
 #ifdef CONFIG_IMA_KEXEC
-static int ima_dump_measurement_list(unsigned long *buffer_size, void **buffer,
+static int ima_dump_measurement_list(size_t *buffer_size, void **buffer,
 				     unsigned long segment_size)
 {
 	struct ima_queue_entry *qe;