[CRIU] [PATCH 00/14] Refactor pid_ns helpers creation
Kirill Tkhai
ktkhai at virtuozzo.com
Mon May 15 06:04:38 PDT 2017
This series mostly simplifies do_create_pid_ns_helper(), which
is currently too large and complex. It uses patches from
"[PATCH 0/3] Synchronize forking on mutex" patchset to escape
of ns_last_pid file lock.
Patch [1/14] was already sent as separate fix, and it's
repeated here because I created the series over it, and
don't want travis errors.
The result of patchset is decreasing of do_create_pid_ns_helper()
code and improving its readability. See the final result
in patch [13/14].
https://travis-ci.org/tkhai/criu/builds/232407624
---
Kirill Tkhai (14):
pid_ns: Destroy helpers via kill()
restore: Simplify do_fork_with_pid()
restore: Simplify do_fork_with_pid() #2
restore: Delete excess code in call_clone_fn()
restore: Always set real pid in restore_task_with_children()
pid_ns: Rename do_destroy_pid_ns_helper()
pid_ns: Pass namespace init task to do_create_pid_ns_helper()
pid_ns: Simplify do_create_pid_ns_helper() using ns helpers
pid_ns: Move parent pid_ns's helper check to create_pid_ns_helper()
namespace: Group unlocking/closing operations in do_create_pid_ns_helper()
forking: Introduce last_pid_mutex and helpers
forking: Use last_pid_mutex for synchronization during clone()
pid_ns: Do cleanups in do_create_pid_ns_helper()
pid_ns: Close sk in case of pid_ns_helper_sock() fails
criu/cr-restore.c | 78 ++++++++++------------
criu/include/rst_info.h | 13 ++++
criu/namespaces.c | 168 ++++++++++++++++++-----------------------------
criu/pie/restorer.c | 34 ++++------
4 files changed, 128 insertions(+), 165 deletions(-)
--
Signed-off-by: Kirill Tkhai <ktkhai at virtuozzo.com>
More information about the CRIU
mailing list