riscv: compat: syscall: Add compat_sys_call_table implementation
authorGuo Ren <guoren@linux.alibaba.com>
Tue, 5 Apr 2022 07:13:05 +0000 (15:13 +0800)
committerPalmer Dabbelt <palmer@rivosinc.com>
Tue, 26 Apr 2022 20:36:25 +0000 (13:36 -0700)
commit59c10c52f573faca862cda5ebcdd43831608eb5a
tree786a8dd25890ba8b97f07f01011c02d4a869ad08
parent01abdfeac81b5f56062d0a78f2cdc805db937a75
riscv: compat: syscall: Add compat_sys_call_table implementation

Implement compat sys_call_table and some system call functions:
truncate64, ftruncate64, fallocate, pread64, pwrite64,
sync_file_range, readahead, fadvise64_64 which need argument
translation.

Signed-off-by: Guo Ren <guoren@linux.alibaba.com>
Signed-off-by: Guo Ren <guoren@kernel.org>
Reviewed-by: Arnd Bergmann <arnd@arndb.de>
Tested-by: Heiko Stuebner <heiko@sntech.de>
Link: https://lore.kernel.org/r/20220405071314.3225832-12-guoren@kernel.org
Signed-off-by: Palmer Dabbelt <palmer@rivosinc.com>
13 files changed:
arch/riscv/include/asm/syscall.h
arch/riscv/include/asm/unistd.h
arch/riscv/include/uapi/asm/unistd.h
arch/riscv/kernel/Makefile
arch/riscv/kernel/compat_syscall_table.c [new file with mode: 0644]
arch/riscv/kernel/sys_riscv.c
fs/open.c
fs/read_write.c
fs/sync.c
include/asm-generic/compat.h
include/linux/compat.h
mm/fadvise.c
mm/readahead.c