Skip to content

Commit 0f92275

Browse files
arndbgregkh
authored andcommitted
csky, hexagon: fix broken sys_sync_file_range
commit 3339b99 upstream. Both of these architectures require u64 function arguments to be passed in even/odd pairs of registers or stack slots, which in case of sync_file_range would result in a seven-argument system call that is not currently possible. The system call is therefore incompatible with all existing binaries. While it would be possible to implement support for seven arguments like on mips, it seems better to use a six-argument version, either with the normal argument order but misaligned as on most architectures or with the reordered sync_file_range2() calling conventions as on arm and powerpc. Cc: [email protected] Acked-by: Guo Ren <[email protected]> Signed-off-by: Arnd Bergmann <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
1 parent 87936f5 commit 0f92275

File tree

2 files changed

+2
-0
lines changed

2 files changed

+2
-0
lines changed

arch/csky/include/uapi/asm/unistd.h

+1
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
#define __ARCH_WANT_SYS_CLONE3
77
#define __ARCH_WANT_SET_GET_RLIMIT
88
#define __ARCH_WANT_TIME32_SYSCALLS
9+
#define __ARCH_WANT_SYNC_FILE_RANGE2
910
#include <asm-generic/unistd.h>
1011

1112
#define __NR_set_thread_area (__NR_arch_specific_syscall + 0)

arch/hexagon/include/uapi/asm/unistd.h

+1
Original file line numberDiff line numberDiff line change
@@ -36,5 +36,6 @@
3636
#define __ARCH_WANT_SYS_VFORK
3737
#define __ARCH_WANT_SYS_FORK
3838
#define __ARCH_WANT_TIME32_SYSCALLS
39+
#define __ARCH_WANT_SYNC_FILE_RANGE2
3940

4041
#include <asm-generic/unistd.h>

0 commit comments

Comments
 (0)