arch: add do_page_fault prototypes

do_page_fault() is missing a declaration on a couple of architectures:

arch/alpha/mm/fault.c:85:1: error: no previous prototype for 'do_page_fault' [-Werror=missing-prototypes]
arch/csky/mm/fault.c:187:17: error: no previous prototype for 'do_page_fault' [-Werror=missing-prototypes]
arch/mips/mm/fault.c:323:17: error: no previous prototype for 'do_page_fault' [-Werror=missing-prototypes]
arch/nios2/mm/fault.c:43:17: error: no previous prototype for 'do_page_fault' [-Werror=missing-prototypes]
arch/sh/mm/fault.c:389:27: error: no previous prototype for 'do_page_fault' [-Werror=missing-prototypes]

Since the calling conventions are architecture specific here,
add separate prototypes for each one.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
This commit is contained in:
Arnd Bergmann 2023-11-06 12:20:13 +01:00
parent 1d6571a879
commit 23f8c1823b
5 changed files with 12 additions and 0 deletions

View File

@ -183,6 +183,8 @@ ev4_switch_mm(struct mm_struct *prev_mm, struct mm_struct *next_mm,
}
extern void __load_new_mm_context(struct mm_struct *);
asmlinkage void do_page_fault(unsigned long address, unsigned long mmcsr,
long cause, struct pt_regs *regs);
#ifdef CONFIG_SMP
#define check_mmu_context() \

View File

@ -55,4 +55,6 @@ asmlinkage void trap_c(struct pt_regs *regs);
asmlinkage void do_notify_resume(struct pt_regs *regs,
unsigned long thread_info_flags);
asmlinkage void do_page_fault(struct pt_regs *regs);
#endif /* __ASM_CSKY_TRAPS_H */

View File

@ -39,4 +39,7 @@ extern char except_vec_nmi[];
register_nmi_notifier(&fn##_nb); \
})
asmlinkage void do_page_fault(struct pt_regs *regs,
unsigned long write, unsigned long address);
#endif /* _ASM_TRAPS_H */

View File

@ -14,6 +14,8 @@
#ifndef __ASSEMBLY__
void _exception(int signo, struct pt_regs *regs, int code, unsigned long addr);
void do_page_fault(struct pt_regs *regs, unsigned long cause,
unsigned long address);
#endif
#endif /* _ASM_NIOS2_TRAPS_H */

View File

@ -43,6 +43,9 @@ static inline void trigger_address_error(void)
asmlinkage void do_address_error(struct pt_regs *regs,
unsigned long writeaccess,
unsigned long address);
asmlinkage void do_page_fault(struct pt_regs *regs,
unsigned long error_code,
unsigned long address);
asmlinkage void do_divide_error(unsigned long r4);
asmlinkage void do_reserved_inst(void);
asmlinkage void do_illegal_slot_inst(void);