Commit 7fccf032 authored by WANG Cong's avatar WANG Cong Committed by Linus Torvalds

kernel/kexec.c: make 'kimage_terminate' void

Since kimage_terminate() always returns 0, make it void.
Signed-off-by: default avatarWANG Cong <wangcong@zeuux.org>
Signed-off-by: default avatar"Eric W. Biederman" <ebiederm@xmission.com>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent f1d82698
...@@ -589,14 +589,12 @@ static void kimage_free_extra_pages(struct kimage *image) ...@@ -589,14 +589,12 @@ static void kimage_free_extra_pages(struct kimage *image)
kimage_free_page_list(&image->unuseable_pages); kimage_free_page_list(&image->unuseable_pages);
} }
static int kimage_terminate(struct kimage *image) static void kimage_terminate(struct kimage *image)
{ {
if (*image->entry != 0) if (*image->entry != 0)
image->entry++; image->entry++;
*image->entry = IND_DONE; *image->entry = IND_DONE;
return 0;
} }
#define for_each_kimage_entry(image, ptr, entry) \ #define for_each_kimage_entry(image, ptr, entry) \
...@@ -997,9 +995,7 @@ asmlinkage long sys_kexec_load(unsigned long entry, unsigned long nr_segments, ...@@ -997,9 +995,7 @@ asmlinkage long sys_kexec_load(unsigned long entry, unsigned long nr_segments,
if (result) if (result)
goto out; goto out;
} }
result = kimage_terminate(image); kimage_terminate(image);
if (result)
goto out;
} }
/* Install the new kernel, and Uninstall the old */ /* Install the new kernel, and Uninstall the old */
image = xchg(dest_image, image); image = xchg(dest_image, image);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment