summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLiao Yuanhong <liaoyuanhong@vivo.com>2025-08-25 20:33:05 +0800
committerAndrew Morton <akpm@linux-foundation.org>2025-09-13 17:32:49 -0700
commit13818f7b8c85c89aa97a430f8116490c1b833470 (patch)
tree58a4f349d9284a91aff29d13a5c075fb8981a8bf
parent493977de1469b9898e178c9aab5fd498c4083da7 (diff)
kexec_core: remove redundant 0 value initialization
The kimage struct is already zeroed by kzalloc(). It's redundant to initialize image->head to 0. Link: https://lkml.kernel.org/r/20250825123307.306634-1-liaoyuanhong@vivo.com Signed-off-by: Liao Yuanhong <liaoyuanhong@vivo.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
-rw-r--r--kernel/kexec_core.c1
1 files changed, 0 insertions, 1 deletions
diff --git a/kernel/kexec_core.c b/kernel/kexec_core.c
index 31203f0bacaf..fa00b239c5d9 100644
--- a/kernel/kexec_core.c
+++ b/kernel/kexec_core.c
@@ -233,7 +233,6 @@ struct kimage *do_kimage_alloc_init(void)
if (!image)
return NULL;
- image->head = 0;
image->entry = &image->head;
image->last_entry = &image->head;
image->control_page = ~0; /* By default this does not apply */