Skip to content

Commit e13d32e

Browse files
arndbctmarinas
authored andcommitted
arm64: move early_brk64 prototype to header
The prototype used for calling early_brk64() is in the file that calls it, which is the wrong place, as it is not included for the definition: arch/arm64/kernel/traps.c:1100:12: error: no previous prototype for 'early_brk64' [-Werror=missing-prototypes] Move it to an appropriate header instead. Signed-off-by: Arnd Bergmann <[email protected]> Reviewed-by: Kees Cook <[email protected]> Acked-by: Ard Biesheuvel <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Catalin Marinas <[email protected]>
1 parent 8ada7aa commit e13d32e

File tree

2 files changed

+2
-3
lines changed

2 files changed

+2
-3
lines changed

arch/arm64/include/asm/traps.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,8 @@ void arm64_force_sig_fault(int signo, int code, unsigned long far, const char *s
2929
void arm64_force_sig_mceerr(int code, unsigned long far, short lsb, const char *str);
3030
void arm64_force_sig_ptrace_errno_trap(int errno, unsigned long far, const char *str);
3131

32+
int early_brk64(unsigned long addr, unsigned long esr, struct pt_regs *regs);
33+
3234
/*
3335
* Move regs->pc to next instruction and do necessary setup before it
3436
* is executed.

arch/arm64/mm/fault.c

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -886,9 +886,6 @@ void do_sp_pc_abort(unsigned long addr, unsigned long esr, struct pt_regs *regs)
886886
}
887887
NOKPROBE_SYMBOL(do_sp_pc_abort);
888888

889-
int __init early_brk64(unsigned long addr, unsigned long esr,
890-
struct pt_regs *regs);
891-
892889
/*
893890
* __refdata because early_brk64 is __init, but the reference to it is
894891
* clobbered at arch_initcall time.

0 commit comments

Comments
 (0)