summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPaul Burton <paul.burton@mips.com>2018-06-14 13:22:44 -0400
committerPaul Burton <paul.burton@mips.com>2018-06-20 00:14:09 -0400
commite426b3754a2cb8bb45b71283fdac0cfc6d247db7 (patch)
tree63bc5558e854258e9c8371b8263731ffe19d0dcc
parent9bcf53598dfe1bd8caaf8e03738d3cc51d45904e (diff)
MIPS: Wire up the restartable sequences (rseq) syscall
Wire up the restartable sequences (rseq) syscall for MIPS. This was introduced by commit d7822b1e24f2 ("rseq: Introduce restartable sequences system call") & MIPS now supports the prerequisites. Signed-off-by: Paul Burton <paul.burton@mips.com> Reviewed-by: James Hogan <jhogan@kernel.org> Patchwork: https://patchwork.linux-mips.org/patch/19525/ Cc: Ralf Baechle <ralf@linux-mips.org> Cc: Mathieu Desnoyers <mathieu.desnoyers@efficios.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Paul E. McKenney <paulmck@linux.vnet.ibm.com> Cc: Boqun Feng <boqun.feng@gmail.com> Cc: linux-mips@linux-mips.org Cc: linux-kernel@vger.kernel.org
-rw-r--r--arch/mips/include/uapi/asm/unistd.h15
-rw-r--r--arch/mips/kernel/scall32-o32.S1
-rw-r--r--arch/mips/kernel/scall64-64.S1
-rw-r--r--arch/mips/kernel/scall64-n32.S1
-rw-r--r--arch/mips/kernel/scall64-o32.S1
5 files changed, 13 insertions, 6 deletions
diff --git a/arch/mips/include/uapi/asm/unistd.h b/arch/mips/include/uapi/asm/unistd.h
index bb05e9916a5f..170bf0b5b250 100644
--- a/arch/mips/include/uapi/asm/unistd.h
+++ b/arch/mips/include/uapi/asm/unistd.h
@@ -388,17 +388,18 @@
388#define __NR_pkey_alloc (__NR_Linux + 364) 388#define __NR_pkey_alloc (__NR_Linux + 364)
389#define __NR_pkey_free (__NR_Linux + 365) 389#define __NR_pkey_free (__NR_Linux + 365)
390#define __NR_statx (__NR_Linux + 366) 390#define __NR_statx (__NR_Linux + 366)
391#define __NR_rseq (__NR_Linux + 367)
391 392
392 393
393/* 394/*
394 * Offset of the last Linux o32 flavoured syscall 395 * Offset of the last Linux o32 flavoured syscall
395 */ 396 */
396#define __NR_Linux_syscalls 366 397#define __NR_Linux_syscalls 367
397 398
398#endif /* _MIPS_SIM == _MIPS_SIM_ABI32 */ 399#endif /* _MIPS_SIM == _MIPS_SIM_ABI32 */
399 400
400#define __NR_O32_Linux 4000 401#define __NR_O32_Linux 4000
401#define __NR_O32_Linux_syscalls 366 402#define __NR_O32_Linux_syscalls 367
402 403
403#if _MIPS_SIM == _MIPS_SIM_ABI64 404#if _MIPS_SIM == _MIPS_SIM_ABI64
404 405
@@ -733,16 +734,17 @@
733#define __NR_pkey_alloc (__NR_Linux + 324) 734#define __NR_pkey_alloc (__NR_Linux + 324)
734#define __NR_pkey_free (__NR_Linux + 325) 735#define __NR_pkey_free (__NR_Linux + 325)
735#define __NR_statx (__NR_Linux + 326) 736#define __NR_statx (__NR_Linux + 326)
737#define __NR_rseq (__NR_Linux + 327)
736 738
737/* 739/*
738 * Offset of the last Linux 64-bit flavoured syscall 740 * Offset of the last Linux 64-bit flavoured syscall
739 */ 741 */
740#define __NR_Linux_syscalls 326 742#define __NR_Linux_syscalls 327
741 743
742#endif /* _MIPS_SIM == _MIPS_SIM_ABI64 */ 744#endif /* _MIPS_SIM == _MIPS_SIM_ABI64 */
743 745
744#define __NR_64_Linux 5000 746#define __NR_64_Linux 5000
745#define __NR_64_Linux_syscalls 326 747#define __NR_64_Linux_syscalls 327
746 748
747#if _MIPS_SIM == _MIPS_SIM_NABI32 749#if _MIPS_SIM == _MIPS_SIM_NABI32
748 750
@@ -1081,15 +1083,16 @@
1081#define __NR_pkey_alloc (__NR_Linux + 328) 1083#define __NR_pkey_alloc (__NR_Linux + 328)
1082#define __NR_pkey_free (__NR_Linux + 329) 1084#define __NR_pkey_free (__NR_Linux + 329)
1083#define __NR_statx (__NR_Linux + 330) 1085#define __NR_statx (__NR_Linux + 330)
1086#define __NR_rseq (__NR_Linux + 331)
1084 1087
1085/* 1088/*
1086 * Offset of the last N32 flavoured syscall 1089 * Offset of the last N32 flavoured syscall
1087 */ 1090 */
1088#define __NR_Linux_syscalls 330 1091#define __NR_Linux_syscalls 331
1089 1092
1090#endif /* _MIPS_SIM == _MIPS_SIM_NABI32 */ 1093#endif /* _MIPS_SIM == _MIPS_SIM_NABI32 */
1091 1094
1092#define __NR_N32_Linux 6000 1095#define __NR_N32_Linux 6000
1093#define __NR_N32_Linux_syscalls 330 1096#define __NR_N32_Linux_syscalls 331
1094 1097
1095#endif /* _UAPI_ASM_UNISTD_H */ 1098#endif /* _UAPI_ASM_UNISTD_H */
diff --git a/arch/mips/kernel/scall32-o32.S b/arch/mips/kernel/scall32-o32.S
index a9a7d78803cd..842ff1612893 100644
--- a/arch/mips/kernel/scall32-o32.S
+++ b/arch/mips/kernel/scall32-o32.S
@@ -590,3 +590,4 @@ EXPORT(sys_call_table)
590 PTR sys_pkey_alloc 590 PTR sys_pkey_alloc
591 PTR sys_pkey_free /* 4365 */ 591 PTR sys_pkey_free /* 4365 */
592 PTR sys_statx 592 PTR sys_statx
593 PTR sys_rseq
diff --git a/arch/mips/kernel/scall64-64.S b/arch/mips/kernel/scall64-64.S
index 65d5aeeb9bdb..558830d1e5ba 100644
--- a/arch/mips/kernel/scall64-64.S
+++ b/arch/mips/kernel/scall64-64.S
@@ -439,4 +439,5 @@ EXPORT(sys_call_table)
439 PTR sys_pkey_alloc 439 PTR sys_pkey_alloc
440 PTR sys_pkey_free /* 5325 */ 440 PTR sys_pkey_free /* 5325 */
441 PTR sys_statx 441 PTR sys_statx
442 PTR sys_rseq
442 .size sys_call_table,.-sys_call_table 443 .size sys_call_table,.-sys_call_table
diff --git a/arch/mips/kernel/scall64-n32.S b/arch/mips/kernel/scall64-n32.S
index cbf190ef9e8a..293f0b0119f3 100644
--- a/arch/mips/kernel/scall64-n32.S
+++ b/arch/mips/kernel/scall64-n32.S
@@ -434,4 +434,5 @@ EXPORT(sysn32_call_table)
434 PTR sys_pkey_alloc 434 PTR sys_pkey_alloc
435 PTR sys_pkey_free 435 PTR sys_pkey_free
436 PTR sys_statx /* 6330 */ 436 PTR sys_statx /* 6330 */
437 PTR sys_rseq
437 .size sysn32_call_table,.-sysn32_call_table 438 .size sysn32_call_table,.-sysn32_call_table
diff --git a/arch/mips/kernel/scall64-o32.S b/arch/mips/kernel/scall64-o32.S
index 9ebe3e2403b1..f13a08de8078 100644
--- a/arch/mips/kernel/scall64-o32.S
+++ b/arch/mips/kernel/scall64-o32.S
@@ -583,4 +583,5 @@ EXPORT(sys32_call_table)
583 PTR sys_pkey_alloc 583 PTR sys_pkey_alloc
584 PTR sys_pkey_free /* 4365 */ 584 PTR sys_pkey_free /* 4365 */
585 PTR sys_statx 585 PTR sys_statx
586 PTR sys_rseq
586 .size sys32_call_table,.-sys32_call_table 587 .size sys32_call_table,.-sys32_call_table