Skip to content

Commit

Permalink
s390/crashdump: move fill_cpu_elf_notes() prototype to header file
Browse files Browse the repository at this point in the history
Move fill_cpu_elf_notes() prototype to header file.
This way we get compile errors if e.g. the number of function
parameters get changed.
Otherwise it's possible to change just the definition and everything
else still compiles fine, but the result is broken code.

Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
  • Loading branch information
Heiko Carstens authored and Martin Schwidefsky committed Sep 26, 2012
1 parent f6e3869 commit 6b563d8
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
2 changes: 2 additions & 0 deletions arch/s390/include/asm/elf.h
Original file line number Diff line number Diff line change
Expand Up @@ -213,4 +213,6 @@ int arch_setup_additional_pages(struct linux_binprm *, int);
extern unsigned long arch_randomize_brk(struct mm_struct *mm);
#define arch_randomize_brk arch_randomize_brk

void *fill_cpu_elf_notes(void *ptr, struct save_area *sa);

#endif
3 changes: 2 additions & 1 deletion arch/s390/kernel/crash_dump.c
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,9 @@
#include <linux/slab.h>
#include <linux/bootmem.h>
#include <linux/elf.h>
#include <asm/ipl.h>
#include <asm/os_info.h>
#include <asm/elf.h>
#include <asm/ipl.h>

#define PTR_ADD(x, y) (((char *) (x)) + ((unsigned long) (y)))
#define PTR_SUB(x, y) (((char *) (x)) - ((unsigned long) (y)))
Expand Down
3 changes: 1 addition & 2 deletions arch/s390/kernel/machine_kexec.c
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
#include <asm/reset.h>
#include <asm/ipl.h>
#include <asm/diag.h>
#include <asm/elf.h>
#include <asm/asm-offsets.h>
#include <asm/os_info.h>

Expand All @@ -31,8 +32,6 @@ extern const unsigned long long relocate_kernel_len;

#ifdef CONFIG_CRASH_DUMP

void *fill_cpu_elf_notes(void *ptr, struct save_area *sa);

/*
* Create ELF notes for one CPU
*/
Expand Down

0 comments on commit 6b563d8

Please sign in to comment.