diff options
author | Paul Walmsley <paul.walmsley@sifive.com> | 2019-10-18 00:00:17 +0200 |
---|---|---|
committer | Paul Walmsley <paul.walmsley@sifive.com> | 2019-10-28 08:46:00 +0100 |
commit | ffaee2728f9b276fc8829abb90f290b5b4b96282 (patch) | |
tree | 5efd0d3e957027088c1e9922dd0a25e7d6c498fb /arch/riscv/kernel/head.h | |
parent | Linux 5.4-rc5 (diff) | |
download | linux-ffaee2728f9b276fc8829abb90f290b5b4b96282.tar.xz linux-ffaee2728f9b276fc8829abb90f290b5b4b96282.zip |
riscv: add prototypes for assembly language functions from head.S
Add prototypes for assembly language functions defined in head.S,
and include these prototypes into C source files that call those
functions.
This patch resolves the following warnings from sparse:
arch/riscv/kernel/setup.c:39:10: warning: symbol 'hart_lottery' was not declared. Should it be static?
arch/riscv/kernel/setup.c:42:13: warning: symbol 'parse_dtb' was not declared. Should it be static?
arch/riscv/kernel/smpboot.c:33:6: warning: symbol '__cpu_up_stack_pointer' was not declared. Should it be static?
arch/riscv/kernel/smpboot.c:34:6: warning: symbol '__cpu_up_task_pointer' was not declared. Should it be static?
arch/riscv/mm/fault.c:25:17: warning: symbol 'do_page_fault' was not declared. Should it be static?
This change should have no functional impact.
Signed-off-by: Paul Walmsley <paul.walmsley@sifive.com>
Diffstat (limited to 'arch/riscv/kernel/head.h')
-rw-r--r-- | arch/riscv/kernel/head.h | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/arch/riscv/kernel/head.h b/arch/riscv/kernel/head.h new file mode 100644 index 000000000000..105fb0496b24 --- /dev/null +++ b/arch/riscv/kernel/head.h @@ -0,0 +1,21 @@ +/* SPDX-License-Identifier: GPL-2.0 */ +/* + * Copyright (C) 2019 SiFive, Inc. + */ +#ifndef __ASM_HEAD_H +#define __ASM_HEAD_H + +#include <linux/linkage.h> +#include <linux/init.h> + +extern atomic_t hart_lottery; + +asmlinkage void do_page_fault(struct pt_regs *regs); +asmlinkage void __init setup_vm(uintptr_t dtb_pa); + +extern void *__cpu_up_stack_pointer[]; +extern void *__cpu_up_task_pointer[]; + +void __init parse_dtb(void); + +#endif /* __ASM_HEAD_H */ |