All of lore.kernel.org
 help / color / mirror / Atom feed
* [RFC PATCH v9 for 4.15 00/14] Restartable sequences and CPU op vector system calls
@ 2017-10-12 23:03 Mathieu Desnoyers
  2017-10-12 23:03 ` [RFC PATCH v9 for 4.15 01/14] Restartable sequences system call Mathieu Desnoyers
                   ` (13 more replies)
  0 siblings, 14 replies; 113+ messages in thread
From: Mathieu Desnoyers @ 2017-10-12 23:03 UTC (permalink / raw)
  To: Paul E. McKenney, Boqun Feng, Peter Zijlstra, Paul Turner,
	Andrew Hunter, Andy Lutomirski, Dave Watson, Josh Triplett,
	Will Deacon
  Cc: linux-kernel, Mathieu Desnoyers

Hi,

This v9 series addresses the debugger single-stepping problem for
restartable sequences by providing a new cpu_opv "cpu operation vector"
system call, and let userspace defer execution of the critical sections
to the kernel in case a restartable sequence gets restarted.

This cpu_opv system call is inspired from readv/writev system calls.
Instead of a struct io_vec array, it receives a struct cpu_op array as
argument.

This is provided as RFC, feedback is welcome!

Thanks,

Mathieu

Boqun Feng (2):
  Restartable sequences: powerpc architecture support
  Restartable sequences: Wire up powerpc system call

Mathieu Desnoyers (12):
  Restartable sequences system call (v9)
  tracing: instrument restartable sequences
  Restartable sequences: ARM 32 architecture support
  Restartable sequences: wire up ARM 32 system call
  Restartable sequences: x86 32/64 architecture support
  Restartable sequences: wire up x86 32/64 system call
  Provide cpu_opv system call
  cpu_opv: Wire up x86 32/64 system call
  cpu_opv: Wire up powerpc system call
  cpu_opv: Wire up ARM32 system call
  cpu_opv: Implement selftests
  Restartable sequences: Provide self-tests

 MAINTAINERS                                        |   20 +
 arch/Kconfig                                       |    7 +
 arch/arm/Kconfig                                   |    1 +
 arch/arm/kernel/signal.c                           |    7 +
 arch/arm/tools/syscall.tbl                         |    2 +
 arch/powerpc/Kconfig                               |    1 +
 arch/powerpc/include/asm/systbl.h                  |    2 +
 arch/powerpc/include/asm/unistd.h                  |    2 +-
 arch/powerpc/include/uapi/asm/unistd.h             |    2 +
 arch/powerpc/kernel/signal.c                       |    3 +
 arch/x86/Kconfig                                   |    1 +
 arch/x86/entry/common.c                            |    1 +
 arch/x86/entry/syscalls/syscall_32.tbl             |    2 +
 arch/x86/entry/syscalls/syscall_64.tbl             |    2 +
 arch/x86/kernel/signal.c                           |    6 +
 fs/exec.c                                          |    1 +
 include/linux/sched.h                              |   89 ++
 include/trace/events/rseq.h                        |   64 +
 include/uapi/linux/cpu_opv.h                       |   93 ++
 include/uapi/linux/rseq.h                          |  131 ++
 init/Kconfig                                       |   27 +
 kernel/Makefile                                    |    2 +
 kernel/cpu_opv.c                                   | 1000 ++++++++++++++++
 kernel/fork.c                                      |    2 +
 kernel/rseq.c                                      |  354 ++++++
 kernel/sched/core.c                                |   41 +
 kernel/sched/sched.h                               |    2 +
 kernel/sys_ni.c                                    |    4 +
 tools/testing/selftests/cpu-opv/.gitignore         |    1 +
 tools/testing/selftests/cpu-opv/Makefile           |   13 +
 .../testing/selftests/cpu-opv/basic_cpu_opv_test.c |  828 +++++++++++++
 tools/testing/selftests/cpu-opv/cpu-op.c           |  189 +++
 tools/testing/selftests/cpu-opv/cpu-op.h           |   53 +
 tools/testing/selftests/rseq/.gitignore            |    4 +
 tools/testing/selftests/rseq/Makefile              |   13 +
 .../testing/selftests/rseq/basic_percpu_ops_test.c |  319 +++++
 tools/testing/selftests/rseq/basic_test.c          |   97 ++
 tools/testing/selftests/rseq/param_test.c          | 1246 ++++++++++++++++++++
 tools/testing/selftests/rseq/rseq-arm.h            |  159 +++
 tools/testing/selftests/rseq/rseq-ppc.h            |  266 +++++
 tools/testing/selftests/rseq/rseq-x86.h            |  304 +++++
 tools/testing/selftests/rseq/rseq.c                |   78 ++
 tools/testing/selftests/rseq/rseq.h                |  298 +++++
 43 files changed, 5736 insertions(+), 1 deletion(-)
 create mode 100644 include/trace/events/rseq.h
 create mode 100644 include/uapi/linux/cpu_opv.h
 create mode 100644 include/uapi/linux/rseq.h
 create mode 100644 kernel/cpu_opv.c
 create mode 100644 kernel/rseq.c
 create mode 100644 tools/testing/selftests/cpu-opv/.gitignore
 create mode 100644 tools/testing/selftests/cpu-opv/Makefile
 create mode 100644 tools/testing/selftests/cpu-opv/basic_cpu_opv_test.c
 create mode 100644 tools/testing/selftests/cpu-opv/cpu-op.c
 create mode 100644 tools/testing/selftests/cpu-opv/cpu-op.h
 create mode 100644 tools/testing/selftests/rseq/.gitignore
 create mode 100644 tools/testing/selftests/rseq/Makefile
 create mode 100644 tools/testing/selftests/rseq/basic_percpu_ops_test.c
 create mode 100644 tools/testing/selftests/rseq/basic_test.c
 create mode 100644 tools/testing/selftests/rseq/param_test.c
 create mode 100644 tools/testing/selftests/rseq/rseq-arm.h
 create mode 100644 tools/testing/selftests/rseq/rseq-ppc.h
 create mode 100644 tools/testing/selftests/rseq/rseq-x86.h
 create mode 100644 tools/testing/selftests/rseq/rseq.c
 create mode 100644 tools/testing/selftests/rseq/rseq.h

-- 
2.11.0

^ permalink raw reply	[flat|nested] 113+ messages in thread

end of thread, other threads:[~2017-10-23 20:44 UTC | newest]

Thread overview: 113+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-10-12 23:03 [RFC PATCH v9 for 4.15 00/14] Restartable sequences and CPU op vector system calls Mathieu Desnoyers
2017-10-12 23:03 ` [RFC PATCH v9 for 4.15 01/14] Restartable sequences system call Mathieu Desnoyers
2017-10-13  0:36   ` Linus Torvalds
2017-10-13  0:36     ` Linus Torvalds
2017-10-13  9:35     ` Ben Maurer
2017-10-13  9:35       ` Ben Maurer
     [not found]       ` <DM5PR15MB1690DA99E4AA74FBE54CF7F9CF480-kTBAvIqET4EjX1lkf7hTyId3EbNNOtPMvxpqHgZTriW3zl9H0oFU5g@public.gmane.org>
2017-10-13 18:30         ` Linus Torvalds
2017-10-13 18:30           ` Linus Torvalds
     [not found]           ` <CA+55aFzPBES0JOYuZhuNM7NKN+G9ytZQT2daueFPw0j9HGpdGQ-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2017-10-13 20:54             ` Paul E. McKenney
2017-10-13 20:54               ` Paul E. McKenney
     [not found]               ` <20171013205418.GM3521-23VcF4HTsmIX0ybBhKVfKdBPR1lH4CV8@public.gmane.org>
2017-10-13 21:05                 ` Linus Torvalds
2017-10-13 21:05                   ` Linus Torvalds
     [not found]                   ` <CA+55aFwvNS95ByZJTh1yG25QfaD0K0ZByK3iXeeRU8LafFiGFQ-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2017-10-13 21:21                     ` Paul E. McKenney
2017-10-13 21:21                       ` Paul E. McKenney
2017-10-13 21:36                     ` Mathieu Desnoyers
2017-10-13 21:36                       ` Mathieu Desnoyers
2017-10-16 16:04                       ` Carlos O'Donell
2017-10-16 16:04                         ` Carlos O'Donell
2017-10-16 16:46                         ` Andi Kleen
2017-10-16 16:46                           ` Andi Kleen
2017-10-16 22:17                           ` Mathieu Desnoyers
2017-10-16 22:17                             ` Mathieu Desnoyers
     [not found]                             ` <21865534.42661.1508192263844.JavaMail.zimbra-vg+e7yoeK/dWk0Htik3J/w@public.gmane.org>
2017-10-17 16:19                               ` Ben Maurer
2017-10-17 16:19                                 ` Ben Maurer
     [not found]                                 ` <CY4PR15MB168879D6220D976B04FE482CCF4C0-ZVJ2su15u+xeX4ZvlgGe+Yd3EbNNOtPMvxpqHgZTriW3zl9H0oFU5g@public.gmane.org>
2017-10-17 16:33                                   ` Mathieu Desnoyers
2017-10-17 16:33                                     ` Mathieu Desnoyers
     [not found]                                     ` <1292309161.43101.1508258000235.JavaMail.zimbra-vg+e7yoeK/dWk0Htik3J/w@public.gmane.org>
2017-10-17 16:41                                       ` Ben Maurer
2017-10-17 16:41                                         ` Ben Maurer
     [not found]                                         ` <CY4PR15MB16886FD43FB48592F3F5892FCF4C0-ZVJ2su15u+xeX4ZvlgGe+Yd3EbNNOtPMvxpqHgZTriW3zl9H0oFU5g@public.gmane.org>
2017-10-17 17:48                                           ` Mathieu Desnoyers
2017-10-17 17:48                                             ` Mathieu Desnoyers
2017-10-18  6:22                                   ` Greg KH
2017-10-18  6:22                                     ` Greg KH
     [not found]                                     ` <20171018062226.GB18857-U8xfFu+wG4EAvxtiuMwx3w@public.gmane.org>
2017-10-18 16:28                                       ` Mathieu Desnoyers
2017-10-18 16:28                                         ` Mathieu Desnoyers
2017-10-14  3:01           ` Andi Kleen
2017-10-14  3:01             ` Andi Kleen
2017-10-14  4:05             ` Linus Torvalds
2017-10-14  4:05               ` Linus Torvalds
2017-10-14 11:37               ` Mathieu Desnoyers
2017-10-14 11:37                 ` Mathieu Desnoyers
2017-10-13 12:50   ` Florian Weimer
2017-10-13 13:40     ` Mathieu Desnoyers
2017-10-13 13:40       ` Mathieu Desnoyers
2017-10-13 13:56       ` Florian Weimer
2017-10-13 13:56         ` Florian Weimer
2017-10-13 14:27         ` Mathieu Desnoyers
2017-10-13 14:27           ` Mathieu Desnoyers
2017-10-13 17:24           ` Andy Lutomirski
2017-10-13 17:24             ` Andy Lutomirski
     [not found]             ` <CALCETrXccCp8apoyUJV8kWLOavnFnenZoU-fbb6cOVZvWp-fnA-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2017-10-13 17:53               ` Florian Weimer
2017-10-13 17:53                 ` Florian Weimer
     [not found]                 ` <3358e696-43e9-15d3-9634-68e9da79e121-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
2017-10-13 18:17                   ` Andy Lutomirski
2017-10-13 18:17                     ` Andy Lutomirski
     [not found]                     ` <CALCETrVWZxC=mT9p7HTrAwcAdMzaxwa=A-O0uQt79qy1Cpky_g-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2017-10-14 11:53                       ` Mathieu Desnoyers
2017-10-14 11:53                         ` Mathieu Desnoyers
2017-10-18 16:41   ` Ben Maurer
     [not found]     ` <CY4PR15MB1688286D6B1283A1C234BAE6CF4E0-ZVJ2su15u+xeX4ZvlgGe+Yd3EbNNOtPMvxpqHgZTriW3zl9H0oFU5g@public.gmane.org>
2017-10-18 18:11       ` Mathieu Desnoyers
2017-10-18 18:11         ` Mathieu Desnoyers
     [not found]         ` <515879378.43966.1508350299712.JavaMail.zimbra-vg+e7yoeK/dWk0Htik3J/w@public.gmane.org>
2017-10-19 11:35           ` Mathieu Desnoyers
2017-10-19 11:35             ` Mathieu Desnoyers
2017-10-19 17:01             ` Florian Weimer
2017-10-19 17:01               ` Florian Weimer
2017-10-23 17:30           ` Ben Maurer
2017-10-23 17:30             ` Ben Maurer
     [not found]             ` <CY4PR15MB16888F91F41A4A1D322C102CCF460-ZVJ2su15u+xeX4ZvlgGe+Yd3EbNNOtPMvxpqHgZTriW3zl9H0oFU5g@public.gmane.org>
2017-10-23 20:44               ` Mathieu Desnoyers
2017-10-23 20:44                 ` Mathieu Desnoyers
2017-10-12 23:03 ` [RFC PATCH for 4.15 02/14] tracing: instrument restartable sequences Mathieu Desnoyers
2017-10-12 23:03 ` [RFC PATCH for 4.15 03/14] Restartable sequences: ARM 32 architecture support Mathieu Desnoyers
2017-10-12 23:03 ` [RFC PATCH for 4.15 04/14] Restartable sequences: wire up ARM 32 system call Mathieu Desnoyers
2017-10-12 23:03 ` [RFC PATCH for 4.15 05/14] Restartable sequences: x86 32/64 architecture support Mathieu Desnoyers
2017-10-12 23:03 ` [RFC PATCH for 4.15 06/14] Restartable sequences: wire up x86 32/64 system call Mathieu Desnoyers
2017-10-12 23:03 ` [RFC PATCH for 4.15 07/14] Restartable sequences: powerpc architecture support Mathieu Desnoyers
2017-10-12 23:03 ` [RFC PATCH for 4.15 08/14] Restartable sequences: Wire up powerpc system call Mathieu Desnoyers
2017-10-12 23:03 ` [RFC PATCH for 4.15 09/14] Provide cpu_opv " Mathieu Desnoyers
     [not found]   ` <20171012230326.19984-10-mathieu.desnoyers-vg+e7yoeK/dWk0Htik3J/w@public.gmane.org>
2017-10-13 13:57     ` Alan Cox
2017-10-13 13:57       ` Alan Cox
2017-10-13 14:50       ` Mathieu Desnoyers
2017-10-13 14:50         ` Mathieu Desnoyers
     [not found]         ` <854849583.40647.1507906233368.JavaMail.zimbra-vg+e7yoeK/dWk0Htik3J/w@public.gmane.org>
2017-10-14 14:22           ` Mathieu Desnoyers
2017-10-14 14:22             ` Mathieu Desnoyers
2017-10-13 17:20     ` Andy Lutomirski
2017-10-13 17:20       ` Andy Lutomirski
2017-10-14  2:50     ` Andi Kleen
2017-10-14  2:50       ` Andi Kleen
     [not found]       ` <20171014025029.GL2482-1g7Xle2YJi4/4alezvVtWx2eb7JE58TQ@public.gmane.org>
2017-10-14 13:35         ` Mathieu Desnoyers
2017-10-14 13:35           ` Mathieu Desnoyers
2017-10-12 23:03 ` [RFC PATCH for 4.15 10/14] cpu_opv: Wire up x86 32/64 " Mathieu Desnoyers
2017-10-12 23:03 ` [RFC PATCH for 4.15 11/14] cpu_opv: Wire up powerpc " Mathieu Desnoyers
2017-10-12 23:03 ` [RFC PATCH for 4.15 12/14] cpu_opv: Wire up ARM32 " Mathieu Desnoyers
2017-10-12 23:03 ` [RFC PATCH for 4.15 13/14] cpu_opv: Implement selftests Mathieu Desnoyers
2017-10-12 23:03 ` [RFC PATCH for 4.15 14/14] Restartable sequences: Provide self-tests Mathieu Desnoyers
2017-10-16  2:51   ` Michael Ellerman
2017-10-16  2:51     ` Michael Ellerman
2017-10-16 14:23     ` Mathieu Desnoyers
2017-10-16 14:23       ` Mathieu Desnoyers
     [not found]       ` <399058130.42156.1508163782335.JavaMail.zimbra-vg+e7yoeK/dWk0Htik3J/w@public.gmane.org>
2017-10-17 10:38         ` Michael Ellerman
2017-10-17 10:38           ` Michael Ellerman
2017-10-17 13:50           ` Mathieu Desnoyers
2017-10-17 13:50             ` Mathieu Desnoyers
     [not found]     ` <871sm3n6sy.fsf-W0DJWXSxmBNbyGPkN3NxC2scP1bn1w/D@public.gmane.org>
2017-10-16 18:50       ` Mathieu Desnoyers
2017-10-16 18:50         ` Mathieu Desnoyers
     [not found]         ` <1998166049.42520.1508179805908.JavaMail.zimbra-vg+e7yoeK/dWk0Htik3J/w@public.gmane.org>
2017-10-17 10:36           ` Michael Ellerman
2017-10-17 10:36             ` Michael Ellerman
     [not found]             ` <87d15mjc1g.fsf-W0DJWXSxmBNbyGPkN3NxC2scP1bn1w/D@public.gmane.org>
2017-10-17 13:50               ` Mathieu Desnoyers
2017-10-17 13:50                 ` Mathieu Desnoyers
     [not found]                 ` <1618170495.42951.1508248216596.JavaMail.zimbra-vg+e7yoeK/dWk0Htik3J/w@public.gmane.org>
2017-10-18  5:45                   ` Michael Ellerman
2017-10-18  5:45                     ` Michael Ellerman
     [not found]   ` <20171012230326.19984-15-mathieu.desnoyers-vg+e7yoeK/dWk0Htik3J/w@public.gmane.org>
2017-10-16  3:00     ` Michael Ellerman
2017-10-16  3:00       ` Michael Ellerman
2017-10-16  3:48       ` Boqun Feng
2017-10-16  3:48         ` Boqun Feng
2017-10-16 11:48         ` Michael Ellerman
2017-10-16 11:48           ` Michael Ellerman

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.