summaryrefslogtreecommitdiffstats
path: root/arch
diff options
context:
space:
mode:
authorAlan Kao <alankao@andestech.com>2018-05-08 11:21:57 +0800
committerPalmer Dabbelt <palmer@sifive.com>2018-06-11 09:04:03 -0700
commit1dd985229d5fc19359250bc0e4235aff217672b2 (patch)
tree44dfa5f5f8a5d1c50fa066ca7d80b23a9aa76058 /arch
parent889d746edd02a4498d80df3a12017d484cc78e5c (diff)
downloadop-kernel-dev-1dd985229d5fc19359250bc0e4235aff217672b2.zip
op-kernel-dev-1dd985229d5fc19359250bc0e4235aff217672b2.tar.gz
riscv/ftrace: Export _mcount when DYNAMIC_FTRACE isn't set
The EXPORT_SYMBOL(_mcount) for RISC-V ended up inside a CONFIG_DYNAMIC_FTRACE ifdef. If you enable modules without enabling CONFIG_DYNAMIC_FTRACE then you'll get a build error without this patch because the modules won't be able to find _mcount. The new behavior is to export _mcount whenever CONFIG_FUNCTION_TRACER is defined. This matches what every other architecture is doing. Signed-off-by: Alan Kao <alankao@andestech.com> Cc: Greentime Hu <greentime@andestech.com> Cc: Zong Li <zong@andestech.com> Signed-off-by: Palmer Dabbelt <palmer@sifive.com>
Diffstat (limited to 'arch')
-rw-r--r--arch/riscv/kernel/mcount.S2
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/riscv/kernel/mcount.S b/arch/riscv/kernel/mcount.S
index ce9bdc5..5721624 100644
--- a/arch/riscv/kernel/mcount.S
+++ b/arch/riscv/kernel/mcount.S
@@ -126,5 +126,5 @@ do_trace:
RESTORE_ABI_STATE
ret
ENDPROC(_mcount)
-EXPORT_SYMBOL(_mcount)
#endif
+EXPORT_SYMBOL(_mcount)
OpenPOWER on IntegriCloud