[PATCH] s390/kexec: use vfree to free memory from vmalloc

From: Baoquan He
Date: Thu Nov 18 2021 - 01:37:53 EST


Since it's clear that memory is allocated with vzalloc in ipl_report_finish(),
let's use vfree to free the memory instead since it's more efficient than
kvfree.

This fixes the warning reported by lkp.

Reported-by: kernel test robot <lkp@xxxxxxxxx>
Signed-off-by: Baoquan He <bhe@xxxxxxxxxx>
---
arch/s390/kernel/machine_kexec_file.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/s390/kernel/machine_kexec_file.c b/arch/s390/kernel/machine_kexec_file.c
index 7f51837e9bc2..351a7ff69a43 100644
--- a/arch/s390/kernel/machine_kexec_file.c
+++ b/arch/s390/kernel/machine_kexec_file.c
@@ -329,7 +329,7 @@ int arch_kexec_apply_relocations_add(struct purgatory_info *pi,

int arch_kimage_file_post_load_cleanup(struct kimage *image)
{
- kvfree(image->arch.ipl_buf);
+ vfree(image->arch.ipl_buf);
image->arch.ipl_buf = NULL;

return kexec_image_post_load_cleanup_default(image);
--
2.17.2