riscv: fix compile failure with EXPORT_SYMBOL() & !MMU

When support for !MMU was added, the declaration of
__asm_copy_to_user() & __asm_copy_from_user() were #ifdefed
out hence their EXPORT_SYMBOL() give an error message like:
.../riscv_ksyms.c:13:15: error: '__asm_copy_to_user' undeclared here
.../riscv_ksyms.c:14:15: error: '__asm_copy_from_user' undeclared here

Since these symbols are not defined with !MMU it's wrong to export them.
Same for __clear_user() (even though this one is also declared in
include/asm-generic/uaccess.h and thus doesn't give an error message).

Fix this by doing the EXPORT_SYMBOL() directly where these symbols
are defined: inside lib/uaccess.S itself.

Fixes: 6bd33e1ece52 ("riscv: fix compile failure with EXPORT_SYMBOL() & !MMU")
Reported-by: kbuild test robot <lkp@intel.com>
Cc: Christoph Hellwig <hch@lst.de>
Cc: Palmer Dabbelt <palmer@dabbelt.com>
Cc: Paul Walmsley <paul.walmsley@sifive.com>
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
Signed-off-by: Paul Walmsley <paul.walmsley@sifive.com>

authored by Luc Van Oostenryck and committed by Paul Walmsley 4d47ce15 46cf053e

Changed files
+4 -3
arch
riscv
-3
arch/riscv/kernel/riscv_ksyms.c
··· 9 9 /* 10 10 * Assembly functions that may be used (directly or indirectly) by modules 11 11 */ 12 - EXPORT_SYMBOL(__clear_user); 13 - EXPORT_SYMBOL(__asm_copy_to_user); 14 - EXPORT_SYMBOL(__asm_copy_from_user); 15 12 EXPORT_SYMBOL(memset); 16 13 EXPORT_SYMBOL(memcpy);
+4
arch/riscv/lib/uaccess.S
··· 1 1 #include <linux/linkage.h> 2 + #include <asm-generic/export.h> 2 3 #include <asm/asm.h> 3 4 #include <asm/csr.h> 4 5 ··· 67 66 j 3b 68 67 ENDPROC(__asm_copy_to_user) 69 68 ENDPROC(__asm_copy_from_user) 69 + EXPORT_SYMBOL(__asm_copy_to_user) 70 + EXPORT_SYMBOL(__asm_copy_from_user) 70 71 71 72 72 73 ENTRY(__clear_user) ··· 111 108 bltu a0, a3, 5b 112 109 j 3b 113 110 ENDPROC(__clear_user) 111 + EXPORT_SYMBOL(__clear_user) 114 112 115 113 .section .fixup,"ax" 116 114 .balign 4