[CRIU] [PATCH 03/12] build: Move @protobuf dir into @images
Cyrill Gorcunov
gorcunov at openvz.org
Fri Feb 12 10:05:09 PST 2016
But keep @protobuf as a symlink: we have
this path encoded in sources. Gonna be
removed with time.
Signed-off-by: Cyrill Gorcunov <gorcunov at openvz.org>
---
images/Makefile | 115 ++++++++++++++++++++
images/binfmt-misc.proto | 10 ++
images/cgroup.proto | 38 +++++++
images/core-aarch64.proto | 19 ++++
images/core-arm.proto | 35 ++++++
images/core-ppc64.proto | 48 +++++++++
images/core-x86.proto | 63 +++++++++++
images/core.proto | 104 ++++++++++++++++++
images/cpuinfo.proto | 36 +++++++
images/creds.proto | 21 ++++
images/eventfd.proto | 8 ++
images/eventpoll.proto | 15 +++
images/ext-file.proto | 6 ++
images/fdinfo.proto | 27 +++++
images/fh.proto | 21 ++++
images/fifo.proto | 4 +
images/file-lock.proto | 8 ++
images/fown.proto | 7 ++
images/fs.proto | 5 +
images/fsnotify.proto | 57 ++++++++++
images/ghost-file.proto | 14 +++
images/google/protobuf/descriptor.proto | 1 +
images/inventory.proto | 16 +++
images/ipc-desc.proto | 9 ++
images/ipc-msg.proto | 12 +++
images/ipc-sem.proto | 6 ++
images/ipc-shm.proto | 6 ++
images/ipc-var.proto | 14 +++
images/mm.proto | 30 ++++++
images/mnt.proto | 47 ++++++++
images/netdev.proto | 39 +++++++
images/ns.proto | 6 ++
images/opts.proto | 14 +++
images/packet-sock.proto | 44 ++++++++
images/pagemap.proto | 11 ++
images/pipe-data.proto | 5 +
images/pipe.proto | 9 ++
images/pstree.proto | 7 ++
images/regfile.proto | 12 +++
images/remap-file-path.proto | 11 ++
images/rlimit.proto | 4 +
images/rpc.proto | 172 ++++++++++++++++++++++++++++++
images/sa.proto | 8 ++
images/seccomp.proto | 8 ++
images/siginfo.proto | 7 ++
images/signalfd.proto | 9 ++
images/sk-inet.proto | 40 +++++++
images/sk-netlink.proto | 17 +++
images/sk-opts.proto | 29 +++++
images/sk-packet.proto | 4 +
images/sk-unix.proto | 48 +++++++++
images/stats.proto | 28 +++++
images/tcp-stream.proto | 19 ++++
images/time.proto | 4 +
images/timer.proto | 27 +++++
images/timerfd.proto | 17 +++
images/tty.proto | 73 +++++++++++++
images/tun.proto | 15 +++
images/userns.proto | 10 ++
images/utsns.proto | 4 +
images/vma.proto | 23 ++++
protobuf | 1 +
protobuf/Makefile | 115 --------------------
protobuf/binfmt-misc.proto | 10 --
protobuf/cgroup.proto | 38 -------
protobuf/core-aarch64.proto | 19 ----
protobuf/core-arm.proto | 35 ------
protobuf/core-ppc64.proto | 48 ---------
protobuf/core-x86.proto | 63 -----------
protobuf/core.proto | 104 ------------------
protobuf/cpuinfo.proto | 36 -------
protobuf/creds.proto | 21 ----
protobuf/eventfd.proto | 8 --
protobuf/eventpoll.proto | 15 ---
protobuf/ext-file.proto | 6 --
protobuf/fdinfo.proto | 27 -----
protobuf/fh.proto | 21 ----
protobuf/fifo.proto | 4 -
protobuf/file-lock.proto | 8 --
protobuf/fown.proto | 7 --
protobuf/fs.proto | 5 -
protobuf/fsnotify.proto | 57 ----------
protobuf/ghost-file.proto | 14 ---
protobuf/google/protobuf/descriptor.proto | 1 -
protobuf/inventory.proto | 16 ---
protobuf/ipc-desc.proto | 9 --
protobuf/ipc-msg.proto | 12 ---
protobuf/ipc-sem.proto | 6 --
protobuf/ipc-shm.proto | 6 --
protobuf/ipc-var.proto | 14 ---
protobuf/mm.proto | 30 ------
protobuf/mnt.proto | 47 --------
protobuf/netdev.proto | 39 -------
protobuf/ns.proto | 6 --
protobuf/opts.proto | 14 ---
protobuf/packet-sock.proto | 44 --------
protobuf/pagemap.proto | 11 --
protobuf/pipe-data.proto | 5 -
protobuf/pipe.proto | 9 --
protobuf/pstree.proto | 7 --
protobuf/regfile.proto | 12 ---
protobuf/remap-file-path.proto | 11 --
protobuf/rlimit.proto | 4 -
protobuf/rpc.proto | 172 ------------------------------
protobuf/sa.proto | 8 --
protobuf/seccomp.proto | 8 --
protobuf/siginfo.proto | 7 --
protobuf/signalfd.proto | 9 --
protobuf/sk-inet.proto | 40 -------
protobuf/sk-netlink.proto | 17 ---
protobuf/sk-opts.proto | 29 -----
protobuf/sk-packet.proto | 4 -
protobuf/sk-unix.proto | 48 ---------
protobuf/stats.proto | 28 -----
protobuf/tcp-stream.proto | 19 ----
protobuf/time.proto | 4 -
protobuf/timer.proto | 27 -----
protobuf/timerfd.proto | 17 ---
protobuf/tty.proto | 73 -------------
protobuf/tun.proto | 15 ---
protobuf/userns.proto | 10 --
protobuf/utsns.proto | 4 -
protobuf/vma.proto | 23 ----
123 files changed, 1527 insertions(+), 1526 deletions(-)
create mode 100644 images/Makefile
create mode 100644 images/binfmt-misc.proto
create mode 100644 images/cgroup.proto
create mode 100644 images/core-aarch64.proto
create mode 100644 images/core-arm.proto
create mode 100644 images/core-ppc64.proto
create mode 100644 images/core-x86.proto
create mode 100644 images/core.proto
create mode 100644 images/cpuinfo.proto
create mode 100644 images/creds.proto
create mode 100644 images/eventfd.proto
create mode 100644 images/eventpoll.proto
create mode 100644 images/ext-file.proto
create mode 100644 images/fdinfo.proto
create mode 100644 images/fh.proto
create mode 100644 images/fifo.proto
create mode 100644 images/file-lock.proto
create mode 100644 images/fown.proto
create mode 100644 images/fs.proto
create mode 100644 images/fsnotify.proto
create mode 100644 images/ghost-file.proto
create mode 120000 images/google/protobuf/descriptor.proto
create mode 100644 images/inventory.proto
create mode 100644 images/ipc-desc.proto
create mode 100644 images/ipc-msg.proto
create mode 100644 images/ipc-sem.proto
create mode 100644 images/ipc-shm.proto
create mode 100644 images/ipc-var.proto
create mode 100644 images/mm.proto
create mode 100644 images/mnt.proto
create mode 100644 images/netdev.proto
create mode 100644 images/ns.proto
create mode 100644 images/opts.proto
create mode 100644 images/packet-sock.proto
create mode 100644 images/pagemap.proto
create mode 100644 images/pipe-data.proto
create mode 100644 images/pipe.proto
create mode 100644 images/pstree.proto
create mode 100644 images/regfile.proto
create mode 100644 images/remap-file-path.proto
create mode 100644 images/rlimit.proto
create mode 100644 images/rpc.proto
create mode 100644 images/sa.proto
create mode 100644 images/seccomp.proto
create mode 100644 images/siginfo.proto
create mode 100644 images/signalfd.proto
create mode 100644 images/sk-inet.proto
create mode 100644 images/sk-netlink.proto
create mode 100644 images/sk-opts.proto
create mode 100644 images/sk-packet.proto
create mode 100644 images/sk-unix.proto
create mode 100644 images/stats.proto
create mode 100644 images/tcp-stream.proto
create mode 100644 images/time.proto
create mode 100644 images/timer.proto
create mode 100644 images/timerfd.proto
create mode 100644 images/tty.proto
create mode 100644 images/tun.proto
create mode 100644 images/userns.proto
create mode 100644 images/utsns.proto
create mode 100644 images/vma.proto
create mode 120000 protobuf
delete mode 100644 protobuf/Makefile
delete mode 100644 protobuf/binfmt-misc.proto
delete mode 100644 protobuf/cgroup.proto
delete mode 100644 protobuf/core-aarch64.proto
delete mode 100644 protobuf/core-arm.proto
delete mode 100644 protobuf/core-ppc64.proto
delete mode 100644 protobuf/core-x86.proto
delete mode 100644 protobuf/core.proto
delete mode 100644 protobuf/cpuinfo.proto
delete mode 100644 protobuf/creds.proto
delete mode 100644 protobuf/eventfd.proto
delete mode 100644 protobuf/eventpoll.proto
delete mode 100644 protobuf/ext-file.proto
delete mode 100644 protobuf/fdinfo.proto
delete mode 100644 protobuf/fh.proto
delete mode 100644 protobuf/fifo.proto
delete mode 100644 protobuf/file-lock.proto
delete mode 100644 protobuf/fown.proto
delete mode 100644 protobuf/fs.proto
delete mode 100644 protobuf/fsnotify.proto
delete mode 100644 protobuf/ghost-file.proto
delete mode 120000 protobuf/google/protobuf/descriptor.proto
delete mode 100644 protobuf/inventory.proto
delete mode 100644 protobuf/ipc-desc.proto
delete mode 100644 protobuf/ipc-msg.proto
delete mode 100644 protobuf/ipc-sem.proto
delete mode 100644 protobuf/ipc-shm.proto
delete mode 100644 protobuf/ipc-var.proto
delete mode 100644 protobuf/mm.proto
delete mode 100644 protobuf/mnt.proto
delete mode 100644 protobuf/netdev.proto
delete mode 100644 protobuf/ns.proto
delete mode 100644 protobuf/opts.proto
delete mode 100644 protobuf/packet-sock.proto
delete mode 100644 protobuf/pagemap.proto
delete mode 100644 protobuf/pipe-data.proto
delete mode 100644 protobuf/pipe.proto
delete mode 100644 protobuf/pstree.proto
delete mode 100644 protobuf/regfile.proto
delete mode 100644 protobuf/remap-file-path.proto
delete mode 100644 protobuf/rlimit.proto
delete mode 100644 protobuf/rpc.proto
delete mode 100644 protobuf/sa.proto
delete mode 100644 protobuf/seccomp.proto
delete mode 100644 protobuf/siginfo.proto
delete mode 100644 protobuf/signalfd.proto
delete mode 100644 protobuf/sk-inet.proto
delete mode 100644 protobuf/sk-netlink.proto
delete mode 100644 protobuf/sk-opts.proto
delete mode 100644 protobuf/sk-packet.proto
delete mode 100644 protobuf/sk-unix.proto
delete mode 100644 protobuf/stats.proto
delete mode 100644 protobuf/tcp-stream.proto
delete mode 100644 protobuf/time.proto
delete mode 100644 protobuf/timer.proto
delete mode 100644 protobuf/timerfd.proto
delete mode 100644 protobuf/tty.proto
delete mode 100644 protobuf/tun.proto
delete mode 100644 protobuf/userns.proto
delete mode 100644 protobuf/utsns.proto
delete mode 100644 protobuf/vma.proto
diff --git a/images/Makefile b/images/Makefile
new file mode 100644
index 000000000000..12089a2192ab
--- /dev/null
+++ b/images/Makefile
@@ -0,0 +1,115 @@
+proto-obj-y += stats.o
+proto-obj-y += core.o
+proto-obj-y += core-x86.o
+proto-obj-y += core-arm.o
+proto-obj-y += core-aarch64.o
+proto-obj-y += core-ppc64.o
+proto-obj-y += cpuinfo.o
+proto-obj-y += inventory.o
+proto-obj-y += fdinfo.o
+proto-obj-y += fown.o
+proto-obj-y += ns.o
+proto-obj-y += regfile.o
+proto-obj-y += ghost-file.o
+proto-obj-y += fifo.o
+proto-obj-y += remap-file-path.o
+proto-obj-y += eventfd.o
+proto-obj-y += eventpoll.o
+proto-obj-y += fh.o
+proto-obj-y += fsnotify.o
+proto-obj-y += signalfd.o
+proto-obj-y += fs.o
+proto-obj-y += pstree.o
+proto-obj-y += pipe.o
+proto-obj-y += tcp-stream.o
+proto-obj-y += sk-packet.o
+proto-obj-y += mnt.o
+proto-obj-y += pipe-data.o
+proto-obj-y += sa.o
+proto-obj-y += timer.o
+proto-obj-y += timerfd.o
+proto-obj-y += mm.o
+proto-obj-y += sk-opts.o
+proto-obj-y += sk-unix.o
+proto-obj-y += sk-inet.o
+proto-obj-y += tun.o
+proto-obj-y += sk-netlink.o
+proto-obj-y += packet-sock.o
+proto-obj-y += ipc-var.o
+proto-obj-y += ipc-desc.o
+proto-obj-y += ipc-shm.o
+proto-obj-y += ipc-msg.o
+proto-obj-y += ipc-sem.o
+proto-obj-y += utsns.o
+proto-obj-y += creds.o
+proto-obj-y += vma.o
+proto-obj-y += netdev.o
+proto-obj-y += tty.o
+proto-obj-y += file-lock.o
+proto-obj-y += rlimit.o
+proto-obj-y += pagemap.o
+proto-obj-y += siginfo.o
+proto-obj-y += rpc.o
+proto-obj-y += ext-file.o
+proto-obj-y += cgroup.o
+proto-obj-y += userns.o
+proto-obj-y += google/protobuf/descriptor.o # To make protoc-c happy and compile opts.proto
+proto-obj-y += opts.o
+proto-obj-y += seccomp.o
+proto-obj-y += binfmt-misc.o
+proto-obj-y += time.o
+
+CFLAGS += -I$(obj)/
+
+#
+# Generates a set of names from protobuf "import" directive.
+# The names are bare, ie no suffixes.
+define gen-proto-dep-names
+$(shell grep "^[[:blank:]]*import[[:blank:]]" $(1) | \
+ sed -e 's/[[:blank:]]*import[[:blank:]]*//' \
+ -e 's/[\";]//g' \
+ -e 's/\.proto//g' | \
+ sort | uniq)
+endef
+
+#
+# Generates rules needed to compile protobuf files.
+define gen-proto-rules
+$(obj)/$(1).pb-c.c $(obj)/$(1).pb-c.h: $(obj)/$(1).proto $(addsuffix .pb-c.c,$(addprefix $(obj)/,$(2)))
+ $$(E) " PBCC " $$@
+ $$(Q) protoc-c --proto_path=$(obj)/ --c_out=$(obj)/ $$<
+ifeq ($(PROTOUFIX),y)
+ $$(Q) sed -i -e 's/4294967295/0xFFFFFFFF/g' $$@
+ $$(Q) sed -i -e 's/4294967295/0xFFFFFFFF/g' $$(patsubst %.c,%.h,$$@)
+ $$(Q) sed -i -e 's/4294967295/0xFFFFFFFF/g' $$(patsubst %.h,%.c,$$@)
+endif
+$(obj)/$(1).pb-c.d: $(obj)/$(1).pb-c.c $(addsuffix .pb-c.d,$(addprefix $(obj)/,$(2)))
+ $$(E) " DEP " $$@
+ $$(Q) $$(CC) -M -MT $$@ -MT $(patsubst %.d,%.o,$$@) $$(CFLAGS) $$< -o $$@
+endef
+
+$(foreach file, $(proto-obj-y), \
+ $(eval $(call gen-proto-rules,$(file:.o=), \
+ $(call gen-proto-dep-names, \
+ $(addprefix $(obj)/,$(file:.o=.proto))))))
+
+$(obj)/%.o: $(obj)/%.pb-c.c $(obj)/%.pb-c.h
+ $(E) " CC " $@
+ $(Q) $(CC) -c $(CFLAGS) $< -o $@
+
+$(obj)/built-in.o: $(addprefix $(obj)/,$(proto-obj-y))
+ $(E) " LINK " $@
+ $(Q) $(LD) $(ldflags-y) -r -o $@ $^
+
+_all += $(obj)/built-in.o
+
+ifneq ($(MAKECMDGOALS),clean)
+-include $(addprefix $(obj)/,$(proto-obj-y:.o=.pb-c.d))
+endif
+
+cleanup-y += $(obj)/*.c.d $(obj)/*.pb-c.c $(obj)/*.pb-c.h
+cleanup-y += $(obj)/google/protobuf/*.d
+cleanup-y += $(obj)/google/protobuf/*.h
+cleanup-y += $(obj)/google/protobuf/*.c
+cleanup-y += $(obj)/google/protobuf/*.o
+cleanup-y += $(obj)/*.d $(obj)/*.i $(obj)/*.s $(obj)/*.o
diff --git a/images/binfmt-misc.proto b/images/binfmt-misc.proto
new file mode 100644
index 000000000000..a6b2f8c477da
--- /dev/null
+++ b/images/binfmt-misc.proto
@@ -0,0 +1,10 @@
+message binfmt_misc_entry {
+ required string name = 1;
+ required bool enabled = 2;
+ required string interpreter = 3;
+ optional string flags = 4;
+ optional string extension = 5;
+ optional string magic = 6;
+ optional string mask = 7;
+ optional int32 offset = 8;
+}
diff --git a/images/cgroup.proto b/images/cgroup.proto
new file mode 100644
index 000000000000..dcd2fe81227d
--- /dev/null
+++ b/images/cgroup.proto
@@ -0,0 +1,38 @@
+message cgroup_perms {
+ required uint32 mode = 1;
+ required uint32 uid = 2;
+ required uint32 gid = 3;
+}
+
+message cgroup_prop_entry {
+ required string name = 1;
+ required string value = 2;
+ optional cgroup_perms perms = 3;
+}
+
+message cgroup_dir_entry {
+ required string dir_name = 1;
+ repeated cgroup_dir_entry children = 2;
+ repeated cgroup_prop_entry properties = 3;
+ optional cgroup_perms dir_perms = 4;
+}
+
+message cg_controller_entry {
+ repeated string cnames = 1;
+ repeated cgroup_dir_entry dirs = 2;
+}
+
+message cg_member_entry {
+ required string name = 1;
+ required string path = 2;
+}
+
+message cg_set_entry {
+ required uint32 id = 1;
+ repeated cg_member_entry ctls = 2;
+}
+
+message cgroup_entry {
+ repeated cg_set_entry sets = 1;
+ repeated cg_controller_entry controllers = 2;
+}
diff --git a/images/core-aarch64.proto b/images/core-aarch64.proto
new file mode 100644
index 000000000000..dfcead9adebc
--- /dev/null
+++ b/images/core-aarch64.proto
@@ -0,0 +1,19 @@
+message user_aarch64_regs_entry {
+ repeated uint64 regs = 1;
+ required uint64 sp = 2;
+ required uint64 pc = 3;
+ required uint64 pstate = 4;
+}
+
+message user_aarch64_fpsimd_context_entry {
+ repeated uint64 vregs = 1;
+ required uint32 fpsr = 2;
+ required uint32 fpcr = 3;
+}
+
+message thread_info_aarch64 {
+ required uint64 clear_tid_addr = 1;
+ required uint64 tls = 2;
+ required user_aarch64_regs_entry gpregs = 3;
+ required user_aarch64_fpsimd_context_entry fpsimd = 4;
+}
diff --git a/images/core-arm.proto b/images/core-arm.proto
new file mode 100644
index 000000000000..31d3a61427dc
--- /dev/null
+++ b/images/core-arm.proto
@@ -0,0 +1,35 @@
+message user_arm_regs_entry {
+ required uint32 r0 = 1;
+ required uint32 r1 = 2;
+ required uint32 r2 = 3;
+ required uint32 r3 = 4;
+ required uint32 r4 = 5;
+ required uint32 r5 = 6;
+ required uint32 r6 = 7;
+ required uint32 r7 = 8;
+ required uint32 r8 = 9;
+ required uint32 r9 = 10;
+ required uint32 r10 = 11;
+ required uint32 fp = 12;
+ required uint32 ip = 13;
+ required uint32 sp = 14;
+ required uint32 lr = 15;
+ required uint32 pc = 16;
+ required uint32 cpsr = 17;
+ required uint32 orig_r0 = 18;
+}
+
+message user_arm_vfpstate_entry {
+ repeated uint64 vfp_regs = 1;
+ required uint32 fpscr = 2;
+ required uint32 fpexc = 3;
+ required uint32 fpinst = 4;
+ required uint32 fpinst2 = 5;
+}
+
+message thread_info_arm {
+ required uint64 clear_tid_addr = 1;
+ required uint32 tls = 2;
+ required user_arm_regs_entry gpregs = 3;
+ required user_arm_vfpstate_entry fpstate = 4;
+}
diff --git a/images/core-ppc64.proto b/images/core-ppc64.proto
new file mode 100644
index 000000000000..d616453053de
--- /dev/null
+++ b/images/core-ppc64.proto
@@ -0,0 +1,48 @@
+message user_ppc64_regs_entry {
+ // Following is the list of regiters starting at r0.
+ repeated uint64 gpr = 1;
+ required uint64 nip = 2;
+ required uint64 msr = 3;
+ required uint64 orig_gpr3 = 4;
+ required uint64 ctr = 5;
+ required uint64 link = 6;
+ required uint64 xer = 7;
+ required uint64 ccr = 8;
+ required uint64 trap = 9;
+}
+
+message user_ppc64_fpstate_entry {
+ // Following is the list of regiters starting at fpr0
+ repeated uint64 fpregs = 1;
+}
+
+message user_ppc64_vrstate_entry {
+ // Altivec registers
+ // The vector registers are 128bit registers (VSR[32..63]).
+ // The following vregs entry will store first the high part then the
+ // low one:
+ // VR0 = vrregs[0] << 64 | vrregs[1];
+ // VR1 = vrregs[2] << 64 | vrregs[3];
+ // ..
+ // The last entry stores in a 128bit field the VSCR which is a 32bit
+ // value returned by the kernel in a 128 field.
+ repeated uint64 vrregs = 1;
+ required uint32 vrsave = 2;
+}
+
+message user_ppc64_vsxstate_entry {
+ // VSX registers
+ // The vector-scale registers are 128bit registers (VSR[0..64]).
+ // Since there is an overlapping over the VSX registers by the FPR and
+ // the Altivec registers, only the lower part of the first 32 VSX
+ // registers have to be saved.
+ repeated uint64 vsxregs = 1;
+}
+
+message thread_info_ppc64 {
+ required uint64 clear_tid_addr = 1;
+ required user_ppc64_regs_entry gpregs = 2;
+ optional user_ppc64_fpstate_entry fpstate = 3;
+ optional user_ppc64_vrstate_entry vrstate = 4;
+ optional user_ppc64_vsxstate_entry vsxstate = 5;
+}
diff --git a/images/core-x86.proto b/images/core-x86.proto
new file mode 100644
index 000000000000..f88ec06a046a
--- /dev/null
+++ b/images/core-x86.proto
@@ -0,0 +1,63 @@
+import "opts.proto";
+
+message user_x86_regs_entry {
+ required uint64 r15 = 1;
+ required uint64 r14 = 2;
+ required uint64 r13 = 3;
+ required uint64 r12 = 4;
+ required uint64 bp = 5;
+ required uint64 bx = 6;
+ required uint64 r11 = 7;
+ required uint64 r10 = 8;
+ required uint64 r9 = 9;
+ required uint64 r8 = 10;
+ required uint64 ax = 11;
+ required uint64 cx = 12;
+ required uint64 dx = 13;
+ required uint64 si = 14;
+ required uint64 di = 15;
+ required uint64 orig_ax = 16;
+ required uint64 ip = 17;
+ required uint64 cs = 18;
+ required uint64 flags = 19;
+ required uint64 sp = 20;
+ required uint64 ss = 21;
+ required uint64 fs_base = 22;
+ required uint64 gs_base = 23;
+ required uint64 ds = 24;
+ required uint64 es = 25;
+ required uint64 fs = 26;
+ required uint64 gs = 27;
+}
+
+message user_x86_xsave_entry {
+ required uint64 xstate_bv = 1;
+ repeated uint32 ymmh_space = 2;
+}
+
+message user_x86_fpregs_entry {
+
+ /* fxsave data */
+ required uint32 cwd = 1;
+ required uint32 swd = 2;
+ required uint32 twd = 3;
+ required uint32 fop = 4;
+ required uint64 rip = 5;
+ required uint64 rdp = 6;
+ required uint32 mxcsr = 7;
+ required uint32 mxcsr_mask = 8;
+ repeated uint32 st_space = 9;
+ repeated uint32 xmm_space = 10;
+
+ /* Unused, but present for backward compatibility */
+ repeated uint32 padding = 11;
+
+ /* xsave extension */
+ optional user_x86_xsave_entry xsave = 13;
+}
+
+message thread_info_x86 {
+ required uint64 clear_tid_addr = 1[(criu).hex = true];
+ required user_x86_regs_entry gpregs = 2[(criu).hex = true];
+ required user_x86_fpregs_entry fpregs = 3;
+}
diff --git a/images/core.proto b/images/core.proto
new file mode 100644
index 000000000000..6def5d9a13f1
--- /dev/null
+++ b/images/core.proto
@@ -0,0 +1,104 @@
+import "core-x86.proto";
+import "core-arm.proto";
+import "core-aarch64.proto";
+import "core-ppc64.proto";
+
+import "rlimit.proto";
+import "timer.proto";
+import "creds.proto";
+
+import "siginfo.proto";
+
+import "opts.proto";
+
+/*
+ * These match the SECCOMP_MODE_* flags from <linux/seccomp.h>.
+ */
+enum seccomp_mode {
+ disabled = 0;
+ strict = 1;
+ filter = 2;
+};
+
+message task_core_entry {
+ required uint32 task_state = 1;
+ required uint32 exit_code = 2;
+
+ required uint32 personality = 3;
+ required uint32 flags = 4;
+ required uint64 blk_sigset = 5[(criu).hex = true];
+
+ required string comm = 6;
+
+ optional task_timers_entry timers = 7;
+ optional task_rlimits_entry rlimits = 8;
+
+ optional uint32 cg_set = 9;
+
+ optional signal_queue_entry signals_s = 10;
+
+ optional seccomp_mode seccomp_mode = 11;
+ optional uint32 seccomp_filter = 12;
+
+ optional uint32 loginuid = 13;
+
+ optional int32 oom_score_adj = 14;
+}
+
+message task_kobj_ids_entry {
+ required uint32 vm_id = 1;
+ required uint32 files_id = 2;
+ required uint32 fs_id = 3;
+ required uint32 sighand_id = 4;
+
+ optional uint32 pid_ns_id = 5;
+ optional uint32 net_ns_id = 6;
+ optional uint32 ipc_ns_id = 7;
+ optional uint32 uts_ns_id = 8;
+ optional uint32 mnt_ns_id = 9;
+ optional uint32 user_ns_id = 10;
+}
+
+message thread_sas_entry {
+ required uint64 ss_sp = 1;
+ required uint64 ss_size = 2;
+ required uint32 ss_flags = 3;
+}
+
+message thread_core_entry {
+ required uint64 futex_rla = 1;
+ required uint32 futex_rla_len = 2;
+ optional sint32 sched_nice = 3;
+ optional uint32 sched_policy = 4;
+ optional uint32 sched_prio = 5;
+ optional uint64 blk_sigset = 6;
+ optional thread_sas_entry sas = 7;
+ optional uint32 pdeath_sig = 8;
+
+ optional signal_queue_entry signals_p = 9;
+ optional creds_entry creds = 10;
+}
+
+message task_rlimits_entry {
+ repeated rlimit_entry rlimits = 1;
+};
+
+message core_entry {
+ enum march {
+ UNKNOWN = 0;
+ X86_64 = 1;
+ ARM = 2;
+ AARCH64 = 3;
+ PPC64 = 4;
+ }
+
+ required march mtype = 1;
+ optional thread_info_x86 thread_info = 2;
+ optional thread_info_arm ti_arm = 6;
+ optional thread_info_aarch64 ti_aarch64 = 8;
+ optional thread_info_ppc64 ti_ppc64 = 9;
+
+ optional task_core_entry tc = 3;
+ optional task_kobj_ids_entry ids = 4;
+ optional thread_core_entry thread_core = 5;
+}
diff --git a/images/cpuinfo.proto b/images/cpuinfo.proto
new file mode 100644
index 000000000000..f5de73aa20e9
--- /dev/null
+++ b/images/cpuinfo.proto
@@ -0,0 +1,36 @@
+message cpuinfo_x86_entry {
+ enum vendor {
+ UNKNOWN = 0;
+ INTEL = 1;
+ AMD = 2;
+ }
+
+ required vendor vendor_id = 1;
+ required uint32 cpu_family = 2;
+ required uint32 model = 3;
+ required uint32 stepping = 4;
+ required uint32 capability_ver = 5;
+ repeated uint32 capability = 6;
+
+ optional string model_id = 7;
+}
+
+message cpuinfo_ppc64_entry {
+ enum endianness {
+ BIGENDIAN = 0;
+ LITTLEENDIAN = 1;
+ }
+
+ required endianness endian = 1;
+ repeated uint64 hwcap = 2;
+}
+
+message cpuinfo_entry {
+ /*
+ * Usually on SMP system there should be same CPUs
+ * installed, but it might happen that system carries
+ * various CPUs so @repeated used.
+ */
+ repeated cpuinfo_x86_entry x86_entry = 1;
+ repeated cpuinfo_ppc64_entry ppc64_entry = 2;
+}
diff --git a/images/creds.proto b/images/creds.proto
new file mode 100644
index 000000000000..1bf840513bed
--- /dev/null
+++ b/images/creds.proto
@@ -0,0 +1,21 @@
+message creds_entry {
+ required uint32 uid = 1;
+ required uint32 gid = 2;
+ required uint32 euid = 3;
+ required uint32 egid = 4;
+ required uint32 suid = 5;
+ required uint32 sgid = 6;
+ required uint32 fsuid = 7;
+ required uint32 fsgid = 8;
+
+ repeated uint32 cap_inh = 9;
+ repeated uint32 cap_prm = 10;
+ repeated uint32 cap_eff = 11;
+ repeated uint32 cap_bnd = 12;
+
+ required uint32 secbits = 13;
+
+ repeated uint32 groups = 14;
+
+ optional string lsm_profile = 15;
+}
diff --git a/images/eventfd.proto b/images/eventfd.proto
new file mode 100644
index 000000000000..cc3a7032f1c7
--- /dev/null
+++ b/images/eventfd.proto
@@ -0,0 +1,8 @@
+import "fown.proto";
+
+message eventfd_file_entry {
+ required uint32 id = 1;
+ required uint32 flags = 2;
+ required fown_entry fown = 3;
+ required uint64 counter = 4;
+}
diff --git a/images/eventpoll.proto b/images/eventpoll.proto
new file mode 100644
index 000000000000..c40675582f92
--- /dev/null
+++ b/images/eventpoll.proto
@@ -0,0 +1,15 @@
+import "fown.proto";
+
+message eventpoll_tfd_entry {
+ required uint32 id = 1;
+ required uint32 tfd = 2;
+ required uint32 events = 3;
+ required uint64 data = 4;
+}
+
+message eventpoll_file_entry {
+ required uint32 id = 1;
+ required uint32 flags = 2;
+ required fown_entry fown = 3;
+ repeated eventpoll_tfd_entry tfd = 4;
+}
diff --git a/images/ext-file.proto b/images/ext-file.proto
new file mode 100644
index 000000000000..82b1b689eac5
--- /dev/null
+++ b/images/ext-file.proto
@@ -0,0 +1,6 @@
+import "fown.proto";
+
+message ext_file_entry {
+ required uint32 id = 1;
+ required fown_entry fown = 5;
+}
diff --git a/images/fdinfo.proto b/images/fdinfo.proto
new file mode 100644
index 000000000000..ac80f6260ffd
--- /dev/null
+++ b/images/fdinfo.proto
@@ -0,0 +1,27 @@
+enum fd_types {
+ UND = 0;
+ REG = 1;
+ PIPE = 2;
+ FIFO = 3;
+ INETSK = 4;
+ UNIXSK = 5;
+ EVENTFD = 6;
+ EVENTPOLL = 7;
+ INOTIFY = 8;
+ SIGNALFD = 9;
+ PACKETSK = 10;
+ TTY = 11;
+ FANOTIFY = 12;
+ NETLINKSK = 13;
+ NS = 14;
+ TUNF = 15;
+ EXT = 16;
+ TIMERFD = 17;
+}
+
+message fdinfo_entry {
+ required uint32 id = 1;
+ required uint32 flags = 2;
+ required fd_types type = 3;
+ required uint32 fd = 4;
+}
diff --git a/images/fh.proto b/images/fh.proto
new file mode 100644
index 000000000000..bda17c9434ae
--- /dev/null
+++ b/images/fh.proto
@@ -0,0 +1,21 @@
+import "opts.proto";
+
+enum fh_entry_sizes {
+ min_entries = 16;
+}
+
+message fh_entry {
+ required uint32 bytes = 1;
+ required uint32 type = 2;
+
+ /* The minimum is fh_n_handle repetitions */
+ repeated uint64 handle = 3;
+ optional string path = 4;
+ optional uint32 mnt_id = 5;
+}
+
+message irmap_cache_entry {
+ required uint32 dev = 1 [(criu).dev = true, (criu).odev = true];
+ required uint64 inode = 2;
+ required string path = 3;
+}
diff --git a/images/fifo.proto b/images/fifo.proto
new file mode 100644
index 000000000000..c7938c093570
--- /dev/null
+++ b/images/fifo.proto
@@ -0,0 +1,4 @@
+message fifo_entry {
+ required uint32 id = 1;
+ required uint32 pipe_id = 2;
+}
diff --git a/images/file-lock.proto b/images/file-lock.proto
new file mode 100644
index 000000000000..e0aaaa4a64b3
--- /dev/null
+++ b/images/file-lock.proto
@@ -0,0 +1,8 @@
+message file_lock_entry {
+ required uint32 flag = 1;
+ required uint32 type = 2;
+ required int32 pid = 3;
+ required int32 fd = 4;
+ required int64 start = 5;
+ required int64 len = 6;
+}
diff --git a/images/fown.proto b/images/fown.proto
new file mode 100644
index 000000000000..f83779ec4f99
--- /dev/null
+++ b/images/fown.proto
@@ -0,0 +1,7 @@
+message fown_entry {
+ required uint32 uid = 1;
+ required uint32 euid = 2;
+ required uint32 signum = 3;
+ required uint32 pid_type = 4;
+ required uint32 pid = 5;
+}
diff --git a/images/fs.proto b/images/fs.proto
new file mode 100644
index 000000000000..d962a77fd668
--- /dev/null
+++ b/images/fs.proto
@@ -0,0 +1,5 @@
+message fs_entry {
+ required uint32 cwd_id = 1;
+ required uint32 root_id = 2;
+ optional uint32 umask = 3;
+}
diff --git a/images/fsnotify.proto b/images/fsnotify.proto
new file mode 100644
index 000000000000..fbe724cb355a
--- /dev/null
+++ b/images/fsnotify.proto
@@ -0,0 +1,57 @@
+import "opts.proto";
+import "fh.proto";
+import "fown.proto";
+
+message inotify_wd_entry {
+ required uint32 id = 1;
+ required uint64 i_ino = 2;
+ required uint32 mask = 3 [(criu).hex = true];
+ required uint32 ignored_mask = 4 [(criu).hex = true];
+ required uint32 s_dev = 5 [(criu).dev = true];
+ required uint32 wd = 6;
+ required fh_entry f_handle = 7;
+}
+
+message inotify_file_entry {
+ required uint32 id = 1;
+ required uint32 flags = 2 [(criu).hex = true];
+ required fown_entry fown = 4;
+ repeated inotify_wd_entry wd = 5;
+}
+
+enum mark_type {
+ INODE = 1;
+ MOUNT = 2;
+}
+
+message fanotify_inode_mark_entry {
+ required uint64 i_ino = 1;
+ required fh_entry f_handle = 2;
+}
+
+message fanotify_mount_mark_entry {
+ required uint32 mnt_id = 1;
+}
+
+message fanotify_mark_entry {
+ required uint32 id = 1;
+ required mark_type type = 2;
+
+ required uint32 mflags = 3 [(criu).hex = true];
+ required uint32 mask = 4 [(criu).hex = true];
+ required uint32 ignored_mask = 5 [(criu).hex = true];
+ required uint32 s_dev = 6 [(criu).dev = true];
+
+ optional fanotify_inode_mark_entry ie = 7;
+ optional fanotify_mount_mark_entry me = 8;
+}
+
+message fanotify_file_entry {
+ required uint32 id = 1;
+ required uint32 flags = 2 [(criu).hex = true];
+ required fown_entry fown = 3;
+
+ required uint32 faflags = 4 [(criu).hex = true];
+ required uint32 evflags = 5 [(criu).hex = true];
+ repeated fanotify_mark_entry mark = 6;
+}
diff --git a/images/ghost-file.proto b/images/ghost-file.proto
new file mode 100644
index 000000000000..db056dbcfd4d
--- /dev/null
+++ b/images/ghost-file.proto
@@ -0,0 +1,14 @@
+import "opts.proto";
+import "time.proto";
+
+message ghost_file_entry {
+ required uint32 uid = 1;
+ required uint32 gid = 2;
+ required uint32 mode = 3;
+
+ optional uint32 dev = 4 [(criu).dev = true];
+ optional uint64 ino = 5;
+ optional uint32 rdev = 6 [(criu).dev = true, (criu).odev = true];
+ optional timeval atim = 7;
+ optional timeval mtim = 8;
+}
diff --git a/images/google/protobuf/descriptor.proto b/images/google/protobuf/descriptor.proto
new file mode 120000
index 000000000000..07a4c9add618
--- /dev/null
+++ b/images/google/protobuf/descriptor.proto
@@ -0,0 +1 @@
+/usr/include/google/protobuf/descriptor.proto
\ No newline at end of file
diff --git a/images/inventory.proto b/images/inventory.proto
new file mode 100644
index 000000000000..a107bb11fe93
--- /dev/null
+++ b/images/inventory.proto
@@ -0,0 +1,16 @@
+import "core.proto";
+
+enum lsmtype {
+ NO_LSM = 0;
+ SELINUX = 1;
+ APPARMOR = 2;
+}
+
+message inventory_entry {
+ required uint32 img_version = 1;
+ optional bool fdinfo_per_id = 2;
+ optional task_kobj_ids_entry root_ids = 3;
+ optional bool ns_per_id = 4;
+ optional uint32 root_cg_set = 5;
+ optional lsmtype lsmtype = 6;
+}
diff --git a/images/ipc-desc.proto b/images/ipc-desc.proto
new file mode 100644
index 000000000000..2a705ac31bb7
--- /dev/null
+++ b/images/ipc-desc.proto
@@ -0,0 +1,9 @@
+message ipc_desc_entry {
+ required uint32 key = 1;
+ required uint32 uid = 2;
+ required uint32 gid = 3;
+ required uint32 cuid = 4;
+ required uint32 cgid = 5;
+ required uint32 mode = 6;
+ required uint32 id = 7;
+}
diff --git a/images/ipc-msg.proto b/images/ipc-msg.proto
new file mode 100644
index 000000000000..6e42f9bb1974
--- /dev/null
+++ b/images/ipc-msg.proto
@@ -0,0 +1,12 @@
+import "ipc-desc.proto";
+
+message ipc_msg {
+ required uint64 mtype = 1;
+ required uint32 msize = 2;
+}
+
+message ipc_msg_entry {
+ required ipc_desc_entry desc = 1;
+ required uint32 qbytes = 2;
+ required uint32 qnum = 3;
+}
diff --git a/images/ipc-sem.proto b/images/ipc-sem.proto
new file mode 100644
index 000000000000..4ec65be4af8c
--- /dev/null
+++ b/images/ipc-sem.proto
@@ -0,0 +1,6 @@
+import "ipc-desc.proto";
+
+message ipc_sem_entry {
+ required ipc_desc_entry desc = 1;
+ required uint32 nsems = 2;
+}
diff --git a/images/ipc-shm.proto b/images/ipc-shm.proto
new file mode 100644
index 000000000000..b402e8e035c6
--- /dev/null
+++ b/images/ipc-shm.proto
@@ -0,0 +1,6 @@
+import "ipc-desc.proto";
+
+message ipc_shm_entry {
+ required ipc_desc_entry desc = 1;
+ required uint64 size = 2;
+}
diff --git a/images/ipc-var.proto b/images/ipc-var.proto
new file mode 100644
index 000000000000..4acda692ab28
--- /dev/null
+++ b/images/ipc-var.proto
@@ -0,0 +1,14 @@
+message ipc_var_entry {
+ repeated uint32 sem_ctls = 1;
+ required uint32 msg_ctlmax = 2;
+ required uint32 msg_ctlmnb = 3;
+ required uint32 msg_ctlmni = 4;
+ required uint32 auto_msgmni = 5;
+ required uint64 shm_ctlmax = 6;
+ required uint64 shm_ctlall = 7;
+ required uint32 shm_ctlmni = 8;
+ required uint32 shm_rmid_forced = 9;
+ required uint32 mq_queues_max = 10;
+ required uint32 mq_msg_max = 11;
+ required uint32 mq_msgsize_max = 12;
+}
diff --git a/images/mm.proto b/images/mm.proto
new file mode 100644
index 000000000000..7dc48427d18f
--- /dev/null
+++ b/images/mm.proto
@@ -0,0 +1,30 @@
+import "opts.proto";
+import "vma.proto";
+
+message aio_ring_entry {
+ required uint64 id = 1;
+ required uint32 nr_req = 2;
+ required uint32 ring_len = 3;
+}
+
+message mm_entry {
+ required uint64 mm_start_code = 1 [(criu).hex = true];
+ required uint64 mm_end_code = 2 [(criu).hex = true];
+ required uint64 mm_start_data = 3 [(criu).hex = true];
+ required uint64 mm_end_data = 4 [(criu).hex = true];
+ required uint64 mm_start_stack = 5 [(criu).hex = true];
+ required uint64 mm_start_brk = 6 [(criu).hex = true];
+ required uint64 mm_brk = 7 [(criu).hex = true];
+ required uint64 mm_arg_start = 8 [(criu).hex = true];
+ required uint64 mm_arg_end = 9 [(criu).hex = true];
+ required uint64 mm_env_start = 10 [(criu).hex = true];
+ required uint64 mm_env_end = 11 [(criu).hex = true];
+ required uint32 exe_file_id = 12;
+
+ repeated uint64 mm_saved_auxv = 13;
+
+ repeated vma_entry vmas = 14;
+
+ optional int32 dumpable = 15;
+ repeated aio_ring_entry aios = 16;
+}
diff --git a/images/mnt.proto b/images/mnt.proto
new file mode 100644
index 000000000000..39022832614f
--- /dev/null
+++ b/images/mnt.proto
@@ -0,0 +1,47 @@
+import "opts.proto";
+
+enum fstype {
+ UNSUPPORTED = 0;
+ PROC = 1;
+ SYSFS = 2;
+ DEVTMPFS = 3;
+ BINFMT_MISC = 4;
+ TMPFS = 5;
+ DEVPTS = 6;
+ SIMFS = 7;
+ PSTORE = 8;
+ SECURITYFS = 9;
+ FUSECTL = 10;
+ DEBUGFS = 11;
+ CGROUP = 12;
+ AUFS = 13;
+ MQUEUE = 14;
+ FUSE = 15;
+ AUTO = 16;
+ OVERLAYFS = 17;
+};
+
+message mnt_entry {
+ required uint32 fstype = 1;
+ required uint32 mnt_id = 2;
+ required uint32 root_dev = 3 [(criu).dev = true];
+ required uint32 parent_mnt_id = 4;
+ required uint32 flags = 5 [(criu).hex = true];
+
+ required string root = 6;
+ required string mountpoint = 7;
+ required string source = 8;
+ required string options = 9;
+
+ optional uint32 shared_id = 10;
+ optional uint32 master_id = 11;
+
+ optional bool with_plugin = 12;
+ optional bool ext_mount = 13;
+
+ optional string fsname = 14;
+ optional bool internal_sharing = 15;
+
+ optional bool deleted = 16;
+ optional uint32 sb_flags = 17 [(criu).hex = true];
+}
diff --git a/images/netdev.proto b/images/netdev.proto
new file mode 100644
index 000000000000..dafa2bd8fe3b
--- /dev/null
+++ b/images/netdev.proto
@@ -0,0 +1,39 @@
+import "opts.proto";
+import "tun.proto";
+
+enum nd_type {
+ LOOPBACK = 1;
+ VETH = 2;
+ TUN = 3;
+ /*
+ * External link -- for those CRIU only dumps and restores
+ * link parameters such as flags, address, MTU, etc. The
+ * existence of the link on restore should be provided
+ * by the setup-namespaces script.
+ */
+ EXTLINK = 4;
+ /*
+ * Virtuozzo specific device.
+ */
+ VENET = 5;
+ BRIDGE = 6;
+}
+
+message net_device_entry {
+ required nd_type type = 1;
+ required uint32 ifindex = 2;
+ required uint32 mtu = 3;
+ required uint32 flags = 4 [(criu).hex = true];
+ required string name = 5;
+
+ optional tun_link_entry tun = 6;
+
+ optional bytes address = 7;
+
+ repeated int32 conf = 8;
+}
+
+message netns_entry {
+ repeated int32 def_conf = 1;
+ repeated int32 all_conf = 2;
+}
diff --git a/images/ns.proto b/images/ns.proto
new file mode 100644
index 000000000000..f053adce3642
--- /dev/null
+++ b/images/ns.proto
@@ -0,0 +1,6 @@
+message ns_file_entry {
+ required uint32 id = 1;
+ required uint32 ns_id = 2;
+ required uint32 ns_cflag = 3;
+ required uint32 flags = 4;
+}
diff --git a/images/opts.proto b/images/opts.proto
new file mode 100644
index 000000000000..18ea7b6481b6
--- /dev/null
+++ b/images/opts.proto
@@ -0,0 +1,14 @@
+import "google/protobuf/descriptor.proto";
+
+message CRIU_Opts {
+ optional bool hex = 1; // Idicate that CRIT should treat this field as hex.
+ optional bool ipadd = 2; // The field is IPv4/v6 address
+ optional string flags = 3;
+ optional bool dev = 4; // Device major:minor packed
+ optional bool odev = 5; // ... in old format
+}
+
+extend google.protobuf.FieldOptions {
+ // Registered unique number to use for all kinds of custom options.
+ optional CRIU_Opts criu = 1018;
+}
diff --git a/images/packet-sock.proto b/images/packet-sock.proto
new file mode 100644
index 000000000000..745ecf8e2fa6
--- /dev/null
+++ b/images/packet-sock.proto
@@ -0,0 +1,44 @@
+import "opts.proto";
+import "fown.proto";
+import "sk-opts.proto";
+
+message packet_mclist {
+ required uint32 index = 1;
+ required uint32 type = 2;
+ required bytes addr = 3;
+}
+
+message packet_ring {
+ required uint32 block_size = 1;
+ required uint32 block_nr = 2;
+ required uint32 frame_size = 3;
+ required uint32 frame_nr = 4;
+
+ required uint32 retire_tmo = 5;
+ required uint32 sizeof_priv = 6;
+ required uint32 features = 7;
+}
+
+message packet_sock_entry {
+ required uint32 id = 1;
+ required uint32 type = 2;
+ required uint32 protocol = 3;
+ required uint32 flags = 4 [(criu).hex = true];
+ required uint32 ifindex = 5;
+
+ required fown_entry fown = 6;
+ required sk_opts_entry opts = 7;
+
+ required uint32 version = 8;
+ required uint32 reserve = 9;
+ required bool aux_data = 10;
+ required bool orig_dev = 11;
+ required bool vnet_hdr = 12;
+ required bool loss = 13;
+ required uint32 timestamp = 14;
+ required uint32 copy_thresh = 15;
+ repeated packet_mclist mclist = 16;
+ optional uint32 fanout = 17 [ default = 0xffffffff ];
+ optional packet_ring rx_ring = 18;
+ optional packet_ring tx_ring = 19;
+}
diff --git a/images/pagemap.proto b/images/pagemap.proto
new file mode 100644
index 000000000000..b492488c748b
--- /dev/null
+++ b/images/pagemap.proto
@@ -0,0 +1,11 @@
+import "opts.proto";
+
+message pagemap_head {
+ required uint32 pages_id = 1;
+}
+
+message pagemap_entry {
+ required uint64 vaddr = 1 [(criu).hex = true];
+ required uint32 nr_pages = 2;
+ optional bool in_parent = 3;
+}
diff --git a/images/pipe-data.proto b/images/pipe-data.proto
new file mode 100644
index 000000000000..555f0394d825
--- /dev/null
+++ b/images/pipe-data.proto
@@ -0,0 +1,5 @@
+message pipe_data_entry {
+ required uint32 pipe_id = 1;
+ required uint32 bytes = 2;
+ optional uint32 size = 3;
+}
diff --git a/images/pipe.proto b/images/pipe.proto
new file mode 100644
index 000000000000..d374430bf95a
--- /dev/null
+++ b/images/pipe.proto
@@ -0,0 +1,9 @@
+import "opts.proto";
+import "fown.proto";
+
+message pipe_entry {
+ required uint32 id = 1;
+ required uint32 pipe_id = 2;
+ required uint32 flags = 3 [(criu).hex = true];
+ required fown_entry fown = 4;
+}
diff --git a/images/pstree.proto b/images/pstree.proto
new file mode 100644
index 000000000000..6cbcfd3e3bad
--- /dev/null
+++ b/images/pstree.proto
@@ -0,0 +1,7 @@
+message pstree_entry {
+ required uint32 pid = 1;
+ required uint32 ppid = 2;
+ required uint32 pgid = 3;
+ required uint32 sid = 4;
+ repeated uint32 threads = 5;
+}
diff --git a/images/regfile.proto b/images/regfile.proto
new file mode 100644
index 000000000000..3a9456fdcc4d
--- /dev/null
+++ b/images/regfile.proto
@@ -0,0 +1,12 @@
+import "opts.proto";
+import "fown.proto";
+
+message reg_file_entry {
+ required uint32 id = 1;
+ required uint32 flags = 2 [(criu).flags = "rfile.flags"];
+ required uint64 pos = 3;
+ required fown_entry fown = 5;
+ required string name = 6;
+ optional sint32 mnt_id = 7 [default = -1];
+ optional uint64 size = 8;
+}
diff --git a/images/remap-file-path.proto b/images/remap-file-path.proto
new file mode 100644
index 000000000000..68549746bad8
--- /dev/null
+++ b/images/remap-file-path.proto
@@ -0,0 +1,11 @@
+enum remap_type {
+ LINKED = 0;
+ GHOST = 1;
+ PROCFS = 2;
+};
+
+message remap_file_path_entry {
+ required uint32 orig_id = 1;
+ required uint32 remap_id = 2;
+ optional remap_type remap_type = 3;
+}
diff --git a/images/rlimit.proto b/images/rlimit.proto
new file mode 100644
index 000000000000..bcf1134b4fea
--- /dev/null
+++ b/images/rlimit.proto
@@ -0,0 +1,4 @@
+message rlimit_entry {
+ required uint64 cur = 1;
+ required uint64 max = 2;
+}
diff --git a/images/rpc.proto b/images/rpc.proto
new file mode 100644
index 000000000000..4f6ed8df1fc7
--- /dev/null
+++ b/images/rpc.proto
@@ -0,0 +1,172 @@
+message criu_page_server_info {
+ optional string address = 1;
+ optional int32 port = 2;
+ optional int32 pid = 3;
+ optional int32 fd = 4;
+}
+
+message criu_veth_pair {
+ required string if_in = 1;
+ required string if_out = 2;
+};
+
+message ext_mount_map {
+ required string key = 1;
+ required string val = 2;
+};
+
+message inherit_fd {
+ required string key = 1;
+ required int32 fd = 2;
+};
+
+message cgroup_root {
+ optional string ctrl = 1;
+ required string path = 2;
+};
+
+message unix_sk {
+ required uint32 inode = 1;
+};
+
+enum criu_cg_mode {
+ IGNORE = 0;
+ NONE = 1;
+ PROPS = 2;
+ SOFT = 3;
+ FULL = 4;
+ STRICT = 5;
+ DEFAULT = 6;
+};
+
+message criu_opts {
+ required int32 images_dir_fd = 1;
+ optional int32 pid = 2; /* if not set on dump, will dump requesting process */
+
+ optional bool leave_running = 3;
+ optional bool ext_unix_sk = 4;
+ optional bool tcp_established = 5;
+ optional bool evasive_devices = 6;
+ optional bool shell_job = 7;
+ optional bool file_locks = 8;
+ optional int32 log_level = 9 [default = 2];
+ optional string log_file = 10; /* No subdirs are allowed. Consider using work-dir */
+
+ optional criu_page_server_info ps = 11;
+
+ optional bool notify_scripts = 12;
+
+ optional string root = 13;
+ optional string parent_img = 14;
+ optional bool track_mem = 15;
+ optional bool auto_dedup = 16;
+
+ optional int32 work_dir_fd = 17;
+ optional bool link_remap = 18;
+ repeated criu_veth_pair veths = 19;
+
+ optional uint32 cpu_cap = 20 [default = 0xffffffff];
+ optional bool force_irmap = 21;
+ repeated string exec_cmd = 22;
+
+ repeated ext_mount_map ext_mnt = 23;
+ optional bool manage_cgroups = 24; /* backward compatibility */
+ repeated cgroup_root cg_root = 25;
+
+ optional bool rst_sibling = 26; /* swrk only */
+ repeated inherit_fd inherit_fd = 27; /* swrk only */
+
+ optional bool auto_ext_mnt = 28;
+ optional bool ext_sharing = 29;
+ optional bool ext_masters = 30;
+
+ repeated string skip_mnt = 31;
+ repeated string enable_fs = 32;
+
+ repeated unix_sk unix_sk_ino = 33;
+
+ optional criu_cg_mode manage_cgroups_mode = 34;
+ optional uint32 ghost_limit = 35 [default = 0x100000];
+ repeated string irmap_scan_paths = 36;
+ repeated string external = 37;
+}
+
+message criu_dump_resp {
+ optional bool restored = 1;
+}
+
+message criu_restore_resp {
+ required int32 pid = 1;
+}
+
+message criu_notify {
+ optional string script = 1;
+ optional int32 pid = 2;
+}
+
+enum criu_req_type {
+ EMPTY = 0;
+ DUMP = 1;
+ RESTORE = 2;
+ CHECK = 3;
+ PRE_DUMP = 4;
+ PAGE_SERVER = 5;
+
+ NOTIFY = 6;
+
+ CPUINFO_DUMP = 7;
+ CPUINFO_CHECK = 8;
+
+ FEATURE_CHECK = 9;
+}
+
+/*
+ * List of features which can queried via
+ * CRIU_REQ_TYPE__FEATURE_CHECK
+ */
+message criu_features {
+ optional bool mem_track = 1;
+}
+
+/*
+ * Request -- each type corresponds to must-be-there
+ * request arguments of respective type
+ */
+
+message criu_req {
+ required criu_req_type type = 1;
+
+ optional criu_opts opts = 2;
+ optional bool notify_success = 3;
+
+ /*
+ * When set service won't close the connection but
+ * will wait for more req-s to appear. Works not
+ * for all request types.
+ */
+ optional bool keep_open = 4;
+ /*
+ * 'features' can be used to query which features
+ * are supported by the installed criu/kernel
+ * via RPC.
+ */
+ optional criu_features features = 5;
+}
+
+/*
+ * Response -- it states whether the request was served
+ * and additional request-specific information
+ */
+
+message criu_resp {
+ required criu_req_type type = 1;
+ required bool success = 2;
+
+ optional criu_dump_resp dump = 3;
+ optional criu_restore_resp restore = 4;
+ optional criu_notify notify = 5;
+ optional criu_page_server_info ps = 6;
+
+ optional int32 cr_errno = 7;
+ optional criu_features features = 8;
+}
diff --git a/images/sa.proto b/images/sa.proto
new file mode 100644
index 000000000000..e5099100b8b1
--- /dev/null
+++ b/images/sa.proto
@@ -0,0 +1,8 @@
+import "opts.proto";
+
+message sa_entry {
+ required uint64 sigaction = 1 [(criu).hex = true];
+ required uint64 flags = 2 [(criu).hex = true];
+ required uint64 restorer = 3 [(criu).hex = true];
+ required uint64 mask = 4 [(criu).hex = true];
+}
diff --git a/images/seccomp.proto b/images/seccomp.proto
new file mode 100644
index 000000000000..03b248cc0eef
--- /dev/null
+++ b/images/seccomp.proto
@@ -0,0 +1,8 @@
+message seccomp_filter {
+ required bytes filter = 1;
+ optional uint32 prev = 2;
+}
+
+message seccomp_entry {
+ repeated seccomp_filter seccomp_filters = 1;
+}
diff --git a/images/siginfo.proto b/images/siginfo.proto
new file mode 100644
index 000000000000..c3630f9c00f6
--- /dev/null
+++ b/images/siginfo.proto
@@ -0,0 +1,7 @@
+message siginfo_entry {
+ required bytes siginfo = 1;
+}
+
+message signal_queue_entry {
+ repeated siginfo_entry signals = 1;
+}
diff --git a/images/signalfd.proto b/images/signalfd.proto
new file mode 100644
index 000000000000..0af21598d4d6
--- /dev/null
+++ b/images/signalfd.proto
@@ -0,0 +1,9 @@
+import "opts.proto";
+import "fown.proto";
+
+message signalfd_entry {
+ required uint32 id = 1;
+ required uint32 flags = 2 [(criu).hex = true];
+ required fown_entry fown = 3;
+ required uint64 sigmask = 4 [(criu).hex = true];
+};
diff --git a/images/sk-inet.proto b/images/sk-inet.proto
new file mode 100644
index 000000000000..a2770dfae803
--- /dev/null
+++ b/images/sk-inet.proto
@@ -0,0 +1,40 @@
+import "opts.proto";
+import "fown.proto";
+import "sk-opts.proto";
+
+message ip_opts_entry {
+ optional bool freebind = 1;
+}
+
+message inet_sk_entry {
+ /*
+ * We have two IDs here -- id and ino. The first one
+ * is used when restoring socket behind a file descriprot.
+ * The fdinfo image's id is it. The second one is used
+ * in sk-inet.c internally, in particular we identify
+ * a TCP stream to restore into this socket using the
+ * ino value.
+ */
+ required uint32 id = 1;
+ required uint32 ino = 2;
+ required uint32 family = 3;
+ required uint32 type = 4;
+ required uint32 proto = 5;
+ required uint32 state = 6;
+ required uint32 src_port = 7;
+ required uint32 dst_port = 8;
+ required uint32 flags = 9 [(criu).hex = true];
+ required uint32 backlog = 10;
+
+ repeated uint32 src_addr = 11 [(criu).ipadd = true];
+ repeated uint32 dst_addr = 12 [(criu).ipadd = true];
+
+ required fown_entry fown = 13;
+ required sk_opts_entry opts = 14;
+ optional bool v6only = 15;
+ optional ip_opts_entry ip_opts = 16;
+
+ /* for ipv6, we need to send the ifindex to bind(); we keep the ifname
+ * here and convert it on restore */
+ optional string ifname = 17;
+}
diff --git a/images/sk-netlink.proto b/images/sk-netlink.proto
new file mode 100644
index 000000000000..bca533c308cb
--- /dev/null
+++ b/images/sk-netlink.proto
@@ -0,0 +1,17 @@
+import "opts.proto";
+import "fown.proto";
+import "sk-opts.proto";
+
+message netlink_sk_entry {
+ required uint32 id = 1;
+ required uint32 ino = 2;
+ required uint32 protocol = 3;
+ required uint32 state = 4;
+ required uint32 flags = 6 [(criu).hex = true];
+ required uint32 portid = 7;
+ repeated uint32 groups = 8;
+ required uint32 dst_portid = 9;
+ required uint32 dst_group = 10;
+ required fown_entry fown = 11;
+ required sk_opts_entry opts = 12;
+}
diff --git a/images/sk-opts.proto b/images/sk-opts.proto
new file mode 100644
index 000000000000..1d21651a1c2f
--- /dev/null
+++ b/images/sk-opts.proto
@@ -0,0 +1,29 @@
+message sk_opts_entry {
+ required uint32 so_sndbuf = 1;
+ required uint32 so_rcvbuf = 2;
+
+ required uint64 so_snd_tmo_sec = 3;
+ required uint64 so_snd_tmo_usec = 4;
+ required uint64 so_rcv_tmo_sec = 5;
+ required uint64 so_rcv_tmo_usec = 6;
+ optional bool reuseaddr = 7;
+
+ optional uint32 so_priority = 8;
+ optional uint32 so_rcvlowat = 9;
+ optional uint32 so_mark = 10;
+ optional bool so_passcred = 11;
+ optional bool so_passsec = 12;
+ optional bool so_dontroute = 13;
+ optional bool so_no_check = 14;
+
+ optional string so_bound_dev = 15;
+
+ repeated fixed64 so_filter = 16;
+}
+
+enum sk_shutdown {
+ NONE = 0;
+ READ = 1;
+ WRITE = 2;
+ BOTH = 3;
+}
diff --git a/images/sk-packet.proto b/images/sk-packet.proto
new file mode 100644
index 000000000000..10ef5c936e35
--- /dev/null
+++ b/images/sk-packet.proto
@@ -0,0 +1,4 @@
+message sk_packet_entry {
+ required uint32 id_for = 1;
+ required uint32 length = 2;
+}
diff --git a/images/sk-unix.proto b/images/sk-unix.proto
new file mode 100644
index 000000000000..aa2bcf7e109c
--- /dev/null
+++ b/images/sk-unix.proto
@@ -0,0 +1,48 @@
+import "opts.proto";
+import "fown.proto";
+import "sk-opts.proto";
+
+message file_perms_entry {
+ required uint32 mode = 1;
+ required uint32 uid = 2;
+ required uint32 gid = 3;
+}
+
+message unix_sk_entry {
+ /*
+ * Few words about why we need both -- id and ino.
+ *
+ * The former one is used to link file descriptor from
+ * fdinfo image with the unix_sk_entry that should be
+ * opened under it.
+ *
+ * The latter one ties together unix peers -- the peer
+ * member on this structure is the ino one of its peer
+ * and simetimes vise-versa.
+ */
+ required uint32 id = 1;
+ required uint32 ino = 2;
+ required uint32 type = 3;
+ required uint32 state = 4;
+ required uint32 flags = 5 [(criu).hex = true];
+ required uint32 uflags = 6 [(criu).hex = true];
+ required uint32 backlog = 7;
+ required uint32 peer = 8;
+ required fown_entry fown = 9;
+ required sk_opts_entry opts = 10;
+
+ /*
+ * Abstract name may contain \0 at any point,
+ * so we need to carry it as byte sequence...
+ */
+ required bytes name = 11;
+
+ optional sk_shutdown shutdown = 12;
+
+ optional file_perms_entry file_perms = 13;
+
+ /*
+ * Relative socket name may have prefix.
+ */
+ optional string name_dir = 14;
+}
diff --git a/images/stats.proto b/images/stats.proto
new file mode 100644
index 000000000000..16acf3400486
--- /dev/null
+++ b/images/stats.proto
@@ -0,0 +1,28 @@
+// This one contains statistics about dump/restore process
+message dump_stats_entry {
+ required uint32 freezing_time = 1;
+ required uint32 frozen_time = 2;
+ required uint32 memdump_time = 3;
+ required uint32 memwrite_time = 4;
+
+ required uint64 pages_scanned = 5;
+ required uint64 pages_skipped_parent = 6;
+ required uint64 pages_written = 7;
+
+ optional uint32 irmap_resolve = 8;
+}
+
+message restore_stats_entry {
+ required uint64 pages_compared = 1;
+ required uint64 pages_skipped_cow = 2;
+
+ required uint32 forking_time = 3;
+ required uint32 restore_time = 4;
+
+ optional uint64 pages_restored = 5;
+}
+
+message stats_entry {
+ optional dump_stats_entry dump = 1;
+ optional restore_stats_entry restore = 2;
+}
diff --git a/images/tcp-stream.proto b/images/tcp-stream.proto
new file mode 100644
index 000000000000..59c053e45cff
--- /dev/null
+++ b/images/tcp-stream.proto
@@ -0,0 +1,19 @@
+import "opts.proto";
+
+message tcp_stream_entry {
+ required uint32 inq_len = 1;
+ required uint32 inq_seq = 2;
+ required uint32 outq_len = 3; /* unsent and sent data in the send queue*/
+ required uint32 outq_seq = 4;
+
+ required uint32 opt_mask = 5 [(criu).hex = true]; /* TCPI_OPT_ bits */
+ required uint32 snd_wscale = 6;
+ required uint32 mss_clamp = 7;
+ optional uint32 rcv_wscale = 8;
+ optional uint32 timestamp = 9;
+
+ optional bool cork = 10;
+ optional bool nodelay = 11;
+
+ optional uint32 unsq_len = 12; /* unsent data in the send queue */
+}
diff --git a/images/time.proto b/images/time.proto
new file mode 100644
index 000000000000..09cdf42a6525
--- /dev/null
+++ b/images/time.proto
@@ -0,0 +1,4 @@
+message timeval {
+ required uint64 tv_sec = 1;
+ required uint64 tv_usec = 2;
+}
diff --git a/images/timer.proto b/images/timer.proto
new file mode 100644
index 000000000000..c584dec6dc6f
--- /dev/null
+++ b/images/timer.proto
@@ -0,0 +1,27 @@
+message itimer_entry {
+ required uint64 isec = 1;
+ required uint64 iusec = 2;
+ required uint64 vsec = 3;
+ required uint64 vusec = 4;
+}
+
+message posix_timer_entry {
+ required uint32 it_id = 1;
+ required uint32 clock_id = 2;
+ required uint32 si_signo = 3;
+ required uint32 it_sigev_notify = 4;
+ required uint64 sival_ptr = 5;
+ required uint32 overrun = 6;
+
+ required uint64 isec = 7;
+ required uint64 insec = 8;
+ required uint64 vsec = 9;
+ required uint64 vnsec = 10;
+}
+
+message task_timers_entry {
+ required itimer_entry real = 1;
+ required itimer_entry virt = 2;
+ required itimer_entry prof = 3;
+ repeated posix_timer_entry posix = 4;
+}
diff --git a/images/timerfd.proto b/images/timerfd.proto
new file mode 100644
index 000000000000..9e3ba6709e2c
--- /dev/null
+++ b/images/timerfd.proto
@@ -0,0 +1,17 @@
+import "opts.proto";
+import "fown.proto";
+
+message timerfd_entry {
+ required uint32 id = 1;
+ required uint32 flags = 2 [(criu).hex = true];
+ required fown_entry fown = 3;
+
+ required uint32 clockid = 4;
+ required uint64 ticks = 5;
+ required uint32 settime_flags = 6 [(criu).hex = true];
+
+ required uint64 vsec = 7;
+ required uint64 vnsec = 8;
+ required uint64 isec = 9;
+ required uint64 insec = 10;
+}
diff --git a/images/tty.proto b/images/tty.proto
new file mode 100644
index 000000000000..4b5a70c20a88
--- /dev/null
+++ b/images/tty.proto
@@ -0,0 +1,73 @@
+import "opts.proto";
+import "fown.proto";
+
+message winsize_entry {
+ required uint32 ws_row = 1;
+ required uint32 ws_col = 2;
+ required uint32 ws_xpixel = 3;
+ required uint32 ws_ypixel = 4;
+};
+
+message termios_entry {
+ required uint32 c_iflag = 1;
+ required uint32 c_oflag = 2;
+ required uint32 c_cflag = 3;
+ required uint32 c_lflag = 4;
+ required uint32 c_line = 5;
+ required uint32 c_ispeed = 6;
+ required uint32 c_ospeed = 7;
+
+ repeated uint32 c_cc = 8;
+}
+
+message tty_pty_entry {
+ required uint32 index = 1;
+}
+
+enum TtyType {
+ UNKNOWN = 0;
+ PTY = 1;
+ CONSOLE = 2;
+ VT = 3;
+ CTTY = 4;
+ EXT_TTY = 5;
+}
+
+message tty_info_entry {
+ required uint32 id = 1;
+
+ required TtyType type = 2;
+
+ required bool locked = 3; /* Unix98 PTY only */
+ required bool exclusive = 4;
+ required bool packet_mode = 5; /* Unix98 PTY only */
+
+ required uint32 sid = 6;
+ required uint32 pgrp = 7;
+
+ /*
+ * Convenient for printing errors and such, with this
+ * device encoded we can figure out major and minor
+ * numbers.
+ */
+ required uint32 rdev = 8;
+
+ optional termios_entry termios = 9;
+ optional termios_entry termios_locked = 10;
+ optional winsize_entry winsize = 11;
+
+ /*
+ * These are optional fields which presense depends on
+ * TTY type.
+ */
+ optional tty_pty_entry pty = 12;
+ optional uint32 dev = 13;
+};
+
+message tty_file_entry {
+ required uint32 id = 1;
+ required uint32 tty_info_id = 2;
+
+ required uint32 flags = 3 [(criu).hex = true];
+ required fown_entry fown = 4;
+}
diff --git a/images/tun.proto b/images/tun.proto
new file mode 100644
index 000000000000..4798166e58c8
--- /dev/null
+++ b/images/tun.proto
@@ -0,0 +1,15 @@
+import "opts.proto";
+
+message tunfile_entry {
+ required uint32 id = 1;
+ optional string netdev = 2;
+ optional bool detached = 3;
+};
+
+message tun_link_entry {
+ required uint32 flags = 1 [(criu).hex = true];
+ required int32 owner = 2;
+ required int32 group = 3;
+ required uint32 vnethdr = 4;
+ required uint32 sndbuf = 5;
+};
diff --git a/images/userns.proto b/images/userns.proto
new file mode 100644
index 000000000000..9428549619b8
--- /dev/null
+++ b/images/userns.proto
@@ -0,0 +1,10 @@
+message uid_gid_extent {
+ required uint32 first = 1;
+ required uint32 lower_first = 2;
+ required uint32 count = 3;
+}
+
+message userns_entry {
+ repeated uid_gid_extent uid_map = 1;
+ repeated uid_gid_extent gid_map = 2;
+}
diff --git a/images/utsns.proto b/images/utsns.proto
new file mode 100644
index 000000000000..cf0a752b71ea
--- /dev/null
+++ b/images/utsns.proto
@@ -0,0 +1,4 @@
+message utsns_entry {
+ required string nodename = 1;
+ required string domainname = 2;
+}
diff --git a/images/vma.proto b/images/vma.proto
new file mode 100644
index 000000000000..e65070711228
--- /dev/null
+++ b/images/vma.proto
@@ -0,0 +1,23 @@
+import "opts.proto";
+
+message vma_entry {
+ required uint64 start = 1 [(criu).hex = true];
+ required uint64 end = 2 [(criu).hex = true];
+ required uint64 pgoff = 3;
+ required uint64 shmid = 4;
+ required uint32 prot = 5 [(criu).flags = "mmap.prot" ];
+ required uint32 flags = 6 [(criu).flags = "mmap.flags" ];
+ required uint32 status = 7 [(criu).flags = "mmap.status" ];
+ /*
+ * This fd thing is unused in the image, it was lost
+ * while switching from execve restore model. It is
+ * -1 by default.
+ */
+ required sint64 fd = 8;
+
+ /* madvise flags bitmap */
+ optional uint64 madv = 9 [(criu).hex = true];
+
+ /* file status flags */
+ optional uint32 fdflags = 10 [(criu).hex = true];
+}
diff --git a/protobuf b/protobuf
new file mode 120000
index 000000000000..5e798fa0ef25
--- /dev/null
+++ b/protobuf
@@ -0,0 +1 @@
+images
\ No newline at end of file
diff --git a/protobuf/Makefile b/protobuf/Makefile
deleted file mode 100644
index 12089a2192ab..000000000000
--- a/protobuf/Makefile
+++ /dev/null
@@ -1,115 +0,0 @@
-proto-obj-y += stats.o
-proto-obj-y += core.o
-proto-obj-y += core-x86.o
-proto-obj-y += core-arm.o
-proto-obj-y += core-aarch64.o
-proto-obj-y += core-ppc64.o
-proto-obj-y += cpuinfo.o
-proto-obj-y += inventory.o
-proto-obj-y += fdinfo.o
-proto-obj-y += fown.o
-proto-obj-y += ns.o
-proto-obj-y += regfile.o
-proto-obj-y += ghost-file.o
-proto-obj-y += fifo.o
-proto-obj-y += remap-file-path.o
-proto-obj-y += eventfd.o
-proto-obj-y += eventpoll.o
-proto-obj-y += fh.o
-proto-obj-y += fsnotify.o
-proto-obj-y += signalfd.o
-proto-obj-y += fs.o
-proto-obj-y += pstree.o
-proto-obj-y += pipe.o
-proto-obj-y += tcp-stream.o
-proto-obj-y += sk-packet.o
-proto-obj-y += mnt.o
-proto-obj-y += pipe-data.o
-proto-obj-y += sa.o
-proto-obj-y += timer.o
-proto-obj-y += timerfd.o
-proto-obj-y += mm.o
-proto-obj-y += sk-opts.o
-proto-obj-y += sk-unix.o
-proto-obj-y += sk-inet.o
-proto-obj-y += tun.o
-proto-obj-y += sk-netlink.o
-proto-obj-y += packet-sock.o
-proto-obj-y += ipc-var.o
-proto-obj-y += ipc-desc.o
-proto-obj-y += ipc-shm.o
-proto-obj-y += ipc-msg.o
-proto-obj-y += ipc-sem.o
-proto-obj-y += utsns.o
-proto-obj-y += creds.o
-proto-obj-y += vma.o
-proto-obj-y += netdev.o
-proto-obj-y += tty.o
-proto-obj-y += file-lock.o
-proto-obj-y += rlimit.o
-proto-obj-y += pagemap.o
-proto-obj-y += siginfo.o
-proto-obj-y += rpc.o
-proto-obj-y += ext-file.o
-proto-obj-y += cgroup.o
-proto-obj-y += userns.o
-proto-obj-y += google/protobuf/descriptor.o # To make protoc-c happy and compile opts.proto
-proto-obj-y += opts.o
-proto-obj-y += seccomp.o
-proto-obj-y += binfmt-misc.o
-proto-obj-y += time.o
-
-CFLAGS += -I$(obj)/
-
-#
-# Generates a set of names from protobuf "import" directive.
-# The names are bare, ie no suffixes.
-define gen-proto-dep-names
-$(shell grep "^[[:blank:]]*import[[:blank:]]" $(1) | \
- sed -e 's/[[:blank:]]*import[[:blank:]]*//' \
- -e 's/[\";]//g' \
- -e 's/\.proto//g' | \
- sort | uniq)
-endef
-
-#
-# Generates rules needed to compile protobuf files.
-define gen-proto-rules
-$(obj)/$(1).pb-c.c $(obj)/$(1).pb-c.h: $(obj)/$(1).proto $(addsuffix .pb-c.c,$(addprefix $(obj)/,$(2)))
- $$(E) " PBCC " $$@
- $$(Q) protoc-c --proto_path=$(obj)/ --c_out=$(obj)/ $$<
-ifeq ($(PROTOUFIX),y)
- $$(Q) sed -i -e 's/4294967295/0xFFFFFFFF/g' $$@
- $$(Q) sed -i -e 's/4294967295/0xFFFFFFFF/g' $$(patsubst %.c,%.h,$$@)
- $$(Q) sed -i -e 's/4294967295/0xFFFFFFFF/g' $$(patsubst %.h,%.c,$$@)
-endif
-$(obj)/$(1).pb-c.d: $(obj)/$(1).pb-c.c $(addsuffix .pb-c.d,$(addprefix $(obj)/,$(2)))
- $$(E) " DEP " $$@
- $$(Q) $$(CC) -M -MT $$@ -MT $(patsubst %.d,%.o,$$@) $$(CFLAGS) $$< -o $$@
-endef
-
-$(foreach file, $(proto-obj-y), \
- $(eval $(call gen-proto-rules,$(file:.o=), \
- $(call gen-proto-dep-names, \
- $(addprefix $(obj)/,$(file:.o=.proto))))))
-
-$(obj)/%.o: $(obj)/%.pb-c.c $(obj)/%.pb-c.h
- $(E) " CC " $@
- $(Q) $(CC) -c $(CFLAGS) $< -o $@
-
-$(obj)/built-in.o: $(addprefix $(obj)/,$(proto-obj-y))
- $(E) " LINK " $@
- $(Q) $(LD) $(ldflags-y) -r -o $@ $^
-
-_all += $(obj)/built-in.o
-
-ifneq ($(MAKECMDGOALS),clean)
--include $(addprefix $(obj)/,$(proto-obj-y:.o=.pb-c.d))
-endif
-
-cleanup-y += $(obj)/*.c.d $(obj)/*.pb-c.c $(obj)/*.pb-c.h
-cleanup-y += $(obj)/google/protobuf/*.d
-cleanup-y += $(obj)/google/protobuf/*.h
-cleanup-y += $(obj)/google/protobuf/*.c
-cleanup-y += $(obj)/google/protobuf/*.o
-cleanup-y += $(obj)/*.d $(obj)/*.i $(obj)/*.s $(obj)/*.o
diff --git a/protobuf/binfmt-misc.proto b/protobuf/binfmt-misc.proto
deleted file mode 100644
index a6b2f8c477da..000000000000
--- a/protobuf/binfmt-misc.proto
+++ /dev/null
@@ -1,10 +0,0 @@
-message binfmt_misc_entry {
- required string name = 1;
- required bool enabled = 2;
- required string interpreter = 3;
- optional string flags = 4;
- optional string extension = 5;
- optional string magic = 6;
- optional string mask = 7;
- optional int32 offset = 8;
-}
diff --git a/protobuf/cgroup.proto b/protobuf/cgroup.proto
deleted file mode 100644
index dcd2fe81227d..000000000000
--- a/protobuf/cgroup.proto
+++ /dev/null
@@ -1,38 +0,0 @@
-message cgroup_perms {
- required uint32 mode = 1;
- required uint32 uid = 2;
- required uint32 gid = 3;
-}
-
-message cgroup_prop_entry {
- required string name = 1;
- required string value = 2;
- optional cgroup_perms perms = 3;
-}
-
-message cgroup_dir_entry {
- required string dir_name = 1;
- repeated cgroup_dir_entry children = 2;
- repeated cgroup_prop_entry properties = 3;
- optional cgroup_perms dir_perms = 4;
-}
-
-message cg_controller_entry {
- repeated string cnames = 1;
- repeated cgroup_dir_entry dirs = 2;
-}
-
-message cg_member_entry {
- required string name = 1;
- required string path = 2;
-}
-
-message cg_set_entry {
- required uint32 id = 1;
- repeated cg_member_entry ctls = 2;
-}
-
-message cgroup_entry {
- repeated cg_set_entry sets = 1;
- repeated cg_controller_entry controllers = 2;
-}
diff --git a/protobuf/core-aarch64.proto b/protobuf/core-aarch64.proto
deleted file mode 100644
index dfcead9adebc..000000000000
--- a/protobuf/core-aarch64.proto
+++ /dev/null
@@ -1,19 +0,0 @@
-message user_aarch64_regs_entry {
- repeated uint64 regs = 1;
- required uint64 sp = 2;
- required uint64 pc = 3;
- required uint64 pstate = 4;
-}
-
-message user_aarch64_fpsimd_context_entry {
- repeated uint64 vregs = 1;
- required uint32 fpsr = 2;
- required uint32 fpcr = 3;
-}
-
-message thread_info_aarch64 {
- required uint64 clear_tid_addr = 1;
- required uint64 tls = 2;
- required user_aarch64_regs_entry gpregs = 3;
- required user_aarch64_fpsimd_context_entry fpsimd = 4;
-}
diff --git a/protobuf/core-arm.proto b/protobuf/core-arm.proto
deleted file mode 100644
index 31d3a61427dc..000000000000
--- a/protobuf/core-arm.proto
+++ /dev/null
@@ -1,35 +0,0 @@
-message user_arm_regs_entry {
- required uint32 r0 = 1;
- required uint32 r1 = 2;
- required uint32 r2 = 3;
- required uint32 r3 = 4;
- required uint32 r4 = 5;
- required uint32 r5 = 6;
- required uint32 r6 = 7;
- required uint32 r7 = 8;
- required uint32 r8 = 9;
- required uint32 r9 = 10;
- required uint32 r10 = 11;
- required uint32 fp = 12;
- required uint32 ip = 13;
- required uint32 sp = 14;
- required uint32 lr = 15;
- required uint32 pc = 16;
- required uint32 cpsr = 17;
- required uint32 orig_r0 = 18;
-}
-
-message user_arm_vfpstate_entry {
- repeated uint64 vfp_regs = 1;
- required uint32 fpscr = 2;
- required uint32 fpexc = 3;
- required uint32 fpinst = 4;
- required uint32 fpinst2 = 5;
-}
-
-message thread_info_arm {
- required uint64 clear_tid_addr = 1;
- required uint32 tls = 2;
- required user_arm_regs_entry gpregs = 3;
- required user_arm_vfpstate_entry fpstate = 4;
-}
diff --git a/protobuf/core-ppc64.proto b/protobuf/core-ppc64.proto
deleted file mode 100644
index d616453053de..000000000000
--- a/protobuf/core-ppc64.proto
+++ /dev/null
@@ -1,48 +0,0 @@
-message user_ppc64_regs_entry {
- // Following is the list of regiters starting at r0.
- repeated uint64 gpr = 1;
- required uint64 nip = 2;
- required uint64 msr = 3;
- required uint64 orig_gpr3 = 4;
- required uint64 ctr = 5;
- required uint64 link = 6;
- required uint64 xer = 7;
- required uint64 ccr = 8;
- required uint64 trap = 9;
-}
-
-message user_ppc64_fpstate_entry {
- // Following is the list of regiters starting at fpr0
- repeated uint64 fpregs = 1;
-}
-
-message user_ppc64_vrstate_entry {
- // Altivec registers
- // The vector registers are 128bit registers (VSR[32..63]).
- // The following vregs entry will store first the high part then the
- // low one:
- // VR0 = vrregs[0] << 64 | vrregs[1];
- // VR1 = vrregs[2] << 64 | vrregs[3];
- // ..
- // The last entry stores in a 128bit field the VSCR which is a 32bit
- // value returned by the kernel in a 128 field.
- repeated uint64 vrregs = 1;
- required uint32 vrsave = 2;
-}
-
-message user_ppc64_vsxstate_entry {
- // VSX registers
- // The vector-scale registers are 128bit registers (VSR[0..64]).
- // Since there is an overlapping over the VSX registers by the FPR and
- // the Altivec registers, only the lower part of the first 32 VSX
- // registers have to be saved.
- repeated uint64 vsxregs = 1;
-}
-
-message thread_info_ppc64 {
- required uint64 clear_tid_addr = 1;
- required user_ppc64_regs_entry gpregs = 2;
- optional user_ppc64_fpstate_entry fpstate = 3;
- optional user_ppc64_vrstate_entry vrstate = 4;
- optional user_ppc64_vsxstate_entry vsxstate = 5;
-}
diff --git a/protobuf/core-x86.proto b/protobuf/core-x86.proto
deleted file mode 100644
index f88ec06a046a..000000000000
--- a/protobuf/core-x86.proto
+++ /dev/null
@@ -1,63 +0,0 @@
-import "opts.proto";
-
-message user_x86_regs_entry {
- required uint64 r15 = 1;
- required uint64 r14 = 2;
- required uint64 r13 = 3;
- required uint64 r12 = 4;
- required uint64 bp = 5;
- required uint64 bx = 6;
- required uint64 r11 = 7;
- required uint64 r10 = 8;
- required uint64 r9 = 9;
- required uint64 r8 = 10;
- required uint64 ax = 11;
- required uint64 cx = 12;
- required uint64 dx = 13;
- required uint64 si = 14;
- required uint64 di = 15;
- required uint64 orig_ax = 16;
- required uint64 ip = 17;
- required uint64 cs = 18;
- required uint64 flags = 19;
- required uint64 sp = 20;
- required uint64 ss = 21;
- required uint64 fs_base = 22;
- required uint64 gs_base = 23;
- required uint64 ds = 24;
- required uint64 es = 25;
- required uint64 fs = 26;
- required uint64 gs = 27;
-}
-
-message user_x86_xsave_entry {
- required uint64 xstate_bv = 1;
- repeated uint32 ymmh_space = 2;
-}
-
-message user_x86_fpregs_entry {
-
- /* fxsave data */
- required uint32 cwd = 1;
- required uint32 swd = 2;
- required uint32 twd = 3;
- required uint32 fop = 4;
- required uint64 rip = 5;
- required uint64 rdp = 6;
- required uint32 mxcsr = 7;
- required uint32 mxcsr_mask = 8;
- repeated uint32 st_space = 9;
- repeated uint32 xmm_space = 10;
-
- /* Unused, but present for backward compatibility */
- repeated uint32 padding = 11;
-
- /* xsave extension */
- optional user_x86_xsave_entry xsave = 13;
-}
-
-message thread_info_x86 {
- required uint64 clear_tid_addr = 1[(criu).hex = true];
- required user_x86_regs_entry gpregs = 2[(criu).hex = true];
- required user_x86_fpregs_entry fpregs = 3;
-}
diff --git a/protobuf/core.proto b/protobuf/core.proto
deleted file mode 100644
index 6def5d9a13f1..000000000000
--- a/protobuf/core.proto
+++ /dev/null
@@ -1,104 +0,0 @@
-import "core-x86.proto";
-import "core-arm.proto";
-import "core-aarch64.proto";
-import "core-ppc64.proto";
-
-import "rlimit.proto";
-import "timer.proto";
-import "creds.proto";
-
-import "siginfo.proto";
-
-import "opts.proto";
-
-/*
- * These match the SECCOMP_MODE_* flags from <linux/seccomp.h>.
- */
-enum seccomp_mode {
- disabled = 0;
- strict = 1;
- filter = 2;
-};
-
-message task_core_entry {
- required uint32 task_state = 1;
- required uint32 exit_code = 2;
-
- required uint32 personality = 3;
- required uint32 flags = 4;
- required uint64 blk_sigset = 5[(criu).hex = true];
-
- required string comm = 6;
-
- optional task_timers_entry timers = 7;
- optional task_rlimits_entry rlimits = 8;
-
- optional uint32 cg_set = 9;
-
- optional signal_queue_entry signals_s = 10;
-
- optional seccomp_mode seccomp_mode = 11;
- optional uint32 seccomp_filter = 12;
-
- optional uint32 loginuid = 13;
-
- optional int32 oom_score_adj = 14;
-}
-
-message task_kobj_ids_entry {
- required uint32 vm_id = 1;
- required uint32 files_id = 2;
- required uint32 fs_id = 3;
- required uint32 sighand_id = 4;
-
- optional uint32 pid_ns_id = 5;
- optional uint32 net_ns_id = 6;
- optional uint32 ipc_ns_id = 7;
- optional uint32 uts_ns_id = 8;
- optional uint32 mnt_ns_id = 9;
- optional uint32 user_ns_id = 10;
-}
-
-message thread_sas_entry {
- required uint64 ss_sp = 1;
- required uint64 ss_size = 2;
- required uint32 ss_flags = 3;
-}
-
-message thread_core_entry {
- required uint64 futex_rla = 1;
- required uint32 futex_rla_len = 2;
- optional sint32 sched_nice = 3;
- optional uint32 sched_policy = 4;
- optional uint32 sched_prio = 5;
- optional uint64 blk_sigset = 6;
- optional thread_sas_entry sas = 7;
- optional uint32 pdeath_sig = 8;
-
- optional signal_queue_entry signals_p = 9;
- optional creds_entry creds = 10;
-}
-
-message task_rlimits_entry {
- repeated rlimit_entry rlimits = 1;
-};
-
-message core_entry {
- enum march {
- UNKNOWN = 0;
- X86_64 = 1;
- ARM = 2;
- AARCH64 = 3;
- PPC64 = 4;
- }
-
- required march mtype = 1;
- optional thread_info_x86 thread_info = 2;
- optional thread_info_arm ti_arm = 6;
- optional thread_info_aarch64 ti_aarch64 = 8;
- optional thread_info_ppc64 ti_ppc64 = 9;
-
- optional task_core_entry tc = 3;
- optional task_kobj_ids_entry ids = 4;
- optional thread_core_entry thread_core = 5;
-}
diff --git a/protobuf/cpuinfo.proto b/protobuf/cpuinfo.proto
deleted file mode 100644
index f5de73aa20e9..000000000000
--- a/protobuf/cpuinfo.proto
+++ /dev/null
@@ -1,36 +0,0 @@
-message cpuinfo_x86_entry {
- enum vendor {
- UNKNOWN = 0;
- INTEL = 1;
- AMD = 2;
- }
-
- required vendor vendor_id = 1;
- required uint32 cpu_family = 2;
- required uint32 model = 3;
- required uint32 stepping = 4;
- required uint32 capability_ver = 5;
- repeated uint32 capability = 6;
-
- optional string model_id = 7;
-}
-
-message cpuinfo_ppc64_entry {
- enum endianness {
- BIGENDIAN = 0;
- LITTLEENDIAN = 1;
- }
-
- required endianness endian = 1;
- repeated uint64 hwcap = 2;
-}
-
-message cpuinfo_entry {
- /*
- * Usually on SMP system there should be same CPUs
- * installed, but it might happen that system carries
- * various CPUs so @repeated used.
- */
- repeated cpuinfo_x86_entry x86_entry = 1;
- repeated cpuinfo_ppc64_entry ppc64_entry = 2;
-}
diff --git a/protobuf/creds.proto b/protobuf/creds.proto
deleted file mode 100644
index 1bf840513bed..000000000000
--- a/protobuf/creds.proto
+++ /dev/null
@@ -1,21 +0,0 @@
-message creds_entry {
- required uint32 uid = 1;
- required uint32 gid = 2;
- required uint32 euid = 3;
- required uint32 egid = 4;
- required uint32 suid = 5;
- required uint32 sgid = 6;
- required uint32 fsuid = 7;
- required uint32 fsgid = 8;
-
- repeated uint32 cap_inh = 9;
- repeated uint32 cap_prm = 10;
- repeated uint32 cap_eff = 11;
- repeated uint32 cap_bnd = 12;
-
- required uint32 secbits = 13;
-
- repeated uint32 groups = 14;
-
- optional string lsm_profile = 15;
-}
diff --git a/protobuf/eventfd.proto b/protobuf/eventfd.proto
deleted file mode 100644
index cc3a7032f1c7..000000000000
--- a/protobuf/eventfd.proto
+++ /dev/null
@@ -1,8 +0,0 @@
-import "fown.proto";
-
-message eventfd_file_entry {
- required uint32 id = 1;
- required uint32 flags = 2;
- required fown_entry fown = 3;
- required uint64 counter = 4;
-}
diff --git a/protobuf/eventpoll.proto b/protobuf/eventpoll.proto
deleted file mode 100644
index c40675582f92..000000000000
--- a/protobuf/eventpoll.proto
+++ /dev/null
@@ -1,15 +0,0 @@
-import "fown.proto";
-
-message eventpoll_tfd_entry {
- required uint32 id = 1;
- required uint32 tfd = 2;
- required uint32 events = 3;
- required uint64 data = 4;
-}
-
-message eventpoll_file_entry {
- required uint32 id = 1;
- required uint32 flags = 2;
- required fown_entry fown = 3;
- repeated eventpoll_tfd_entry tfd = 4;
-}
diff --git a/protobuf/ext-file.proto b/protobuf/ext-file.proto
deleted file mode 100644
index 82b1b689eac5..000000000000
--- a/protobuf/ext-file.proto
+++ /dev/null
@@ -1,6 +0,0 @@
-import "fown.proto";
-
-message ext_file_entry {
- required uint32 id = 1;
- required fown_entry fown = 5;
-}
diff --git a/protobuf/fdinfo.proto b/protobuf/fdinfo.proto
deleted file mode 100644
index ac80f6260ffd..000000000000
--- a/protobuf/fdinfo.proto
+++ /dev/null
@@ -1,27 +0,0 @@
-enum fd_types {
- UND = 0;
- REG = 1;
- PIPE = 2;
- FIFO = 3;
- INETSK = 4;
- UNIXSK = 5;
- EVENTFD = 6;
- EVENTPOLL = 7;
- INOTIFY = 8;
- SIGNALFD = 9;
- PACKETSK = 10;
- TTY = 11;
- FANOTIFY = 12;
- NETLINKSK = 13;
- NS = 14;
- TUNF = 15;
- EXT = 16;
- TIMERFD = 17;
-}
-
-message fdinfo_entry {
- required uint32 id = 1;
- required uint32 flags = 2;
- required fd_types type = 3;
- required uint32 fd = 4;
-}
diff --git a/protobuf/fh.proto b/protobuf/fh.proto
deleted file mode 100644
index bda17c9434ae..000000000000
--- a/protobuf/fh.proto
+++ /dev/null
@@ -1,21 +0,0 @@
-import "opts.proto";
-
-enum fh_entry_sizes {
- min_entries = 16;
-}
-
-message fh_entry {
- required uint32 bytes = 1;
- required uint32 type = 2;
-
- /* The minimum is fh_n_handle repetitions */
- repeated uint64 handle = 3;
- optional string path = 4;
- optional uint32 mnt_id = 5;
-}
-
-message irmap_cache_entry {
- required uint32 dev = 1 [(criu).dev = true, (criu).odev = true];
- required uint64 inode = 2;
- required string path = 3;
-}
diff --git a/protobuf/fifo.proto b/protobuf/fifo.proto
deleted file mode 100644
index c7938c093570..000000000000
--- a/protobuf/fifo.proto
+++ /dev/null
@@ -1,4 +0,0 @@
-message fifo_entry {
- required uint32 id = 1;
- required uint32 pipe_id = 2;
-}
diff --git a/protobuf/file-lock.proto b/protobuf/file-lock.proto
deleted file mode 100644
index e0aaaa4a64b3..000000000000
--- a/protobuf/file-lock.proto
+++ /dev/null
@@ -1,8 +0,0 @@
-message file_lock_entry {
- required uint32 flag = 1;
- required uint32 type = 2;
- required int32 pid = 3;
- required int32 fd = 4;
- required int64 start = 5;
- required int64 len = 6;
-}
diff --git a/protobuf/fown.proto b/protobuf/fown.proto
deleted file mode 100644
index f83779ec4f99..000000000000
--- a/protobuf/fown.proto
+++ /dev/null
@@ -1,7 +0,0 @@
-message fown_entry {
- required uint32 uid = 1;
- required uint32 euid = 2;
- required uint32 signum = 3;
- required uint32 pid_type = 4;
- required uint32 pid = 5;
-}
diff --git a/protobuf/fs.proto b/protobuf/fs.proto
deleted file mode 100644
index d962a77fd668..000000000000
--- a/protobuf/fs.proto
+++ /dev/null
@@ -1,5 +0,0 @@
-message fs_entry {
- required uint32 cwd_id = 1;
- required uint32 root_id = 2;
- optional uint32 umask = 3;
-}
diff --git a/protobuf/fsnotify.proto b/protobuf/fsnotify.proto
deleted file mode 100644
index fbe724cb355a..000000000000
--- a/protobuf/fsnotify.proto
+++ /dev/null
@@ -1,57 +0,0 @@
-import "opts.proto";
-import "fh.proto";
-import "fown.proto";
-
-message inotify_wd_entry {
- required uint32 id = 1;
- required uint64 i_ino = 2;
- required uint32 mask = 3 [(criu).hex = true];
- required uint32 ignored_mask = 4 [(criu).hex = true];
- required uint32 s_dev = 5 [(criu).dev = true];
- required uint32 wd = 6;
- required fh_entry f_handle = 7;
-}
-
-message inotify_file_entry {
- required uint32 id = 1;
- required uint32 flags = 2 [(criu).hex = true];
- required fown_entry fown = 4;
- repeated inotify_wd_entry wd = 5;
-}
-
-enum mark_type {
- INODE = 1;
- MOUNT = 2;
-}
-
-message fanotify_inode_mark_entry {
- required uint64 i_ino = 1;
- required fh_entry f_handle = 2;
-}
-
-message fanotify_mount_mark_entry {
- required uint32 mnt_id = 1;
-}
-
-message fanotify_mark_entry {
- required uint32 id = 1;
- required mark_type type = 2;
-
- required uint32 mflags = 3 [(criu).hex = true];
- required uint32 mask = 4 [(criu).hex = true];
- required uint32 ignored_mask = 5 [(criu).hex = true];
- required uint32 s_dev = 6 [(criu).dev = true];
-
- optional fanotify_inode_mark_entry ie = 7;
- optional fanotify_mount_mark_entry me = 8;
-}
-
-message fanotify_file_entry {
- required uint32 id = 1;
- required uint32 flags = 2 [(criu).hex = true];
- required fown_entry fown = 3;
-
- required uint32 faflags = 4 [(criu).hex = true];
- required uint32 evflags = 5 [(criu).hex = true];
- repeated fanotify_mark_entry mark = 6;
-}
diff --git a/protobuf/ghost-file.proto b/protobuf/ghost-file.proto
deleted file mode 100644
index db056dbcfd4d..000000000000
--- a/protobuf/ghost-file.proto
+++ /dev/null
@@ -1,14 +0,0 @@
-import "opts.proto";
-import "time.proto";
-
-message ghost_file_entry {
- required uint32 uid = 1;
- required uint32 gid = 2;
- required uint32 mode = 3;
-
- optional uint32 dev = 4 [(criu).dev = true];
- optional uint64 ino = 5;
- optional uint32 rdev = 6 [(criu).dev = true, (criu).odev = true];
- optional timeval atim = 7;
- optional timeval mtim = 8;
-}
diff --git a/protobuf/google/protobuf/descriptor.proto b/protobuf/google/protobuf/descriptor.proto
deleted file mode 120000
index 07a4c9add618..000000000000
--- a/protobuf/google/protobuf/descriptor.proto
+++ /dev/null
@@ -1 +0,0 @@
-/usr/include/google/protobuf/descriptor.proto
\ No newline at end of file
diff --git a/protobuf/inventory.proto b/protobuf/inventory.proto
deleted file mode 100644
index a107bb11fe93..000000000000
--- a/protobuf/inventory.proto
+++ /dev/null
@@ -1,16 +0,0 @@
-import "core.proto";
-
-enum lsmtype {
- NO_LSM = 0;
- SELINUX = 1;
- APPARMOR = 2;
-}
-
-message inventory_entry {
- required uint32 img_version = 1;
- optional bool fdinfo_per_id = 2;
- optional task_kobj_ids_entry root_ids = 3;
- optional bool ns_per_id = 4;
- optional uint32 root_cg_set = 5;
- optional lsmtype lsmtype = 6;
-}
diff --git a/protobuf/ipc-desc.proto b/protobuf/ipc-desc.proto
deleted file mode 100644
index 2a705ac31bb7..000000000000
--- a/protobuf/ipc-desc.proto
+++ /dev/null
@@ -1,9 +0,0 @@
-message ipc_desc_entry {
- required uint32 key = 1;
- required uint32 uid = 2;
- required uint32 gid = 3;
- required uint32 cuid = 4;
- required uint32 cgid = 5;
- required uint32 mode = 6;
- required uint32 id = 7;
-}
diff --git a/protobuf/ipc-msg.proto b/protobuf/ipc-msg.proto
deleted file mode 100644
index 6e42f9bb1974..000000000000
--- a/protobuf/ipc-msg.proto
+++ /dev/null
@@ -1,12 +0,0 @@
-import "ipc-desc.proto";
-
-message ipc_msg {
- required uint64 mtype = 1;
- required uint32 msize = 2;
-}
-
-message ipc_msg_entry {
- required ipc_desc_entry desc = 1;
- required uint32 qbytes = 2;
- required uint32 qnum = 3;
-}
diff --git a/protobuf/ipc-sem.proto b/protobuf/ipc-sem.proto
deleted file mode 100644
index 4ec65be4af8c..000000000000
--- a/protobuf/ipc-sem.proto
+++ /dev/null
@@ -1,6 +0,0 @@
-import "ipc-desc.proto";
-
-message ipc_sem_entry {
- required ipc_desc_entry desc = 1;
- required uint32 nsems = 2;
-}
diff --git a/protobuf/ipc-shm.proto b/protobuf/ipc-shm.proto
deleted file mode 100644
index b402e8e035c6..000000000000
--- a/protobuf/ipc-shm.proto
+++ /dev/null
@@ -1,6 +0,0 @@
-import "ipc-desc.proto";
-
-message ipc_shm_entry {
- required ipc_desc_entry desc = 1;
- required uint64 size = 2;
-}
diff --git a/protobuf/ipc-var.proto b/protobuf/ipc-var.proto
deleted file mode 100644
index 4acda692ab28..000000000000
--- a/protobuf/ipc-var.proto
+++ /dev/null
@@ -1,14 +0,0 @@
-message ipc_var_entry {
- repeated uint32 sem_ctls = 1;
- required uint32 msg_ctlmax = 2;
- required uint32 msg_ctlmnb = 3;
- required uint32 msg_ctlmni = 4;
- required uint32 auto_msgmni = 5;
- required uint64 shm_ctlmax = 6;
- required uint64 shm_ctlall = 7;
- required uint32 shm_ctlmni = 8;
- required uint32 shm_rmid_forced = 9;
- required uint32 mq_queues_max = 10;
- required uint32 mq_msg_max = 11;
- required uint32 mq_msgsize_max = 12;
-}
diff --git a/protobuf/mm.proto b/protobuf/mm.proto
deleted file mode 100644
index 7dc48427d18f..000000000000
--- a/protobuf/mm.proto
+++ /dev/null
@@ -1,30 +0,0 @@
-import "opts.proto";
-import "vma.proto";
-
-message aio_ring_entry {
- required uint64 id = 1;
- required uint32 nr_req = 2;
- required uint32 ring_len = 3;
-}
-
-message mm_entry {
- required uint64 mm_start_code = 1 [(criu).hex = true];
- required uint64 mm_end_code = 2 [(criu).hex = true];
- required uint64 mm_start_data = 3 [(criu).hex = true];
- required uint64 mm_end_data = 4 [(criu).hex = true];
- required uint64 mm_start_stack = 5 [(criu).hex = true];
- required uint64 mm_start_brk = 6 [(criu).hex = true];
- required uint64 mm_brk = 7 [(criu).hex = true];
- required uint64 mm_arg_start = 8 [(criu).hex = true];
- required uint64 mm_arg_end = 9 [(criu).hex = true];
- required uint64 mm_env_start = 10 [(criu).hex = true];
- required uint64 mm_env_end = 11 [(criu).hex = true];
- required uint32 exe_file_id = 12;
-
- repeated uint64 mm_saved_auxv = 13;
-
- repeated vma_entry vmas = 14;
-
- optional int32 dumpable = 15;
- repeated aio_ring_entry aios = 16;
-}
diff --git a/protobuf/mnt.proto b/protobuf/mnt.proto
deleted file mode 100644
index 39022832614f..000000000000
--- a/protobuf/mnt.proto
+++ /dev/null
@@ -1,47 +0,0 @@
-import "opts.proto";
-
-enum fstype {
- UNSUPPORTED = 0;
- PROC = 1;
- SYSFS = 2;
- DEVTMPFS = 3;
- BINFMT_MISC = 4;
- TMPFS = 5;
- DEVPTS = 6;
- SIMFS = 7;
- PSTORE = 8;
- SECURITYFS = 9;
- FUSECTL = 10;
- DEBUGFS = 11;
- CGROUP = 12;
- AUFS = 13;
- MQUEUE = 14;
- FUSE = 15;
- AUTO = 16;
- OVERLAYFS = 17;
-};
-
-message mnt_entry {
- required uint32 fstype = 1;
- required uint32 mnt_id = 2;
- required uint32 root_dev = 3 [(criu).dev = true];
- required uint32 parent_mnt_id = 4;
- required uint32 flags = 5 [(criu).hex = true];
-
- required string root = 6;
- required string mountpoint = 7;
- required string source = 8;
- required string options = 9;
-
- optional uint32 shared_id = 10;
- optional uint32 master_id = 11;
-
- optional bool with_plugin = 12;
- optional bool ext_mount = 13;
-
- optional string fsname = 14;
- optional bool internal_sharing = 15;
-
- optional bool deleted = 16;
- optional uint32 sb_flags = 17 [(criu).hex = true];
-}
diff --git a/protobuf/netdev.proto b/protobuf/netdev.proto
deleted file mode 100644
index dafa2bd8fe3b..000000000000
--- a/protobuf/netdev.proto
+++ /dev/null
@@ -1,39 +0,0 @@
-import "opts.proto";
-import "tun.proto";
-
-enum nd_type {
- LOOPBACK = 1;
- VETH = 2;
- TUN = 3;
- /*
- * External link -- for those CRIU only dumps and restores
- * link parameters such as flags, address, MTU, etc. The
- * existence of the link on restore should be provided
- * by the setup-namespaces script.
- */
- EXTLINK = 4;
- /*
- * Virtuozzo specific device.
- */
- VENET = 5;
- BRIDGE = 6;
-}
-
-message net_device_entry {
- required nd_type type = 1;
- required uint32 ifindex = 2;
- required uint32 mtu = 3;
- required uint32 flags = 4 [(criu).hex = true];
- required string name = 5;
-
- optional tun_link_entry tun = 6;
-
- optional bytes address = 7;
-
- repeated int32 conf = 8;
-}
-
-message netns_entry {
- repeated int32 def_conf = 1;
- repeated int32 all_conf = 2;
-}
diff --git a/protobuf/ns.proto b/protobuf/ns.proto
deleted file mode 100644
index f053adce3642..000000000000
--- a/protobuf/ns.proto
+++ /dev/null
@@ -1,6 +0,0 @@
-message ns_file_entry {
- required uint32 id = 1;
- required uint32 ns_id = 2;
- required uint32 ns_cflag = 3;
- required uint32 flags = 4;
-}
diff --git a/protobuf/opts.proto b/protobuf/opts.proto
deleted file mode 100644
index 18ea7b6481b6..000000000000
--- a/protobuf/opts.proto
+++ /dev/null
@@ -1,14 +0,0 @@
-import "google/protobuf/descriptor.proto";
-
-message CRIU_Opts {
- optional bool hex = 1; // Idicate that CRIT should treat this field as hex.
- optional bool ipadd = 2; // The field is IPv4/v6 address
- optional string flags = 3;
- optional bool dev = 4; // Device major:minor packed
- optional bool odev = 5; // ... in old format
-}
-
-extend google.protobuf.FieldOptions {
- // Registered unique number to use for all kinds of custom options.
- optional CRIU_Opts criu = 1018;
-}
diff --git a/protobuf/packet-sock.proto b/protobuf/packet-sock.proto
deleted file mode 100644
index 745ecf8e2fa6..000000000000
--- a/protobuf/packet-sock.proto
+++ /dev/null
@@ -1,44 +0,0 @@
-import "opts.proto";
-import "fown.proto";
-import "sk-opts.proto";
-
-message packet_mclist {
- required uint32 index = 1;
- required uint32 type = 2;
- required bytes addr = 3;
-}
-
-message packet_ring {
- required uint32 block_size = 1;
- required uint32 block_nr = 2;
- required uint32 frame_size = 3;
- required uint32 frame_nr = 4;
-
- required uint32 retire_tmo = 5;
- required uint32 sizeof_priv = 6;
- required uint32 features = 7;
-}
-
-message packet_sock_entry {
- required uint32 id = 1;
- required uint32 type = 2;
- required uint32 protocol = 3;
- required uint32 flags = 4 [(criu).hex = true];
- required uint32 ifindex = 5;
-
- required fown_entry fown = 6;
- required sk_opts_entry opts = 7;
-
- required uint32 version = 8;
- required uint32 reserve = 9;
- required bool aux_data = 10;
- required bool orig_dev = 11;
- required bool vnet_hdr = 12;
- required bool loss = 13;
- required uint32 timestamp = 14;
- required uint32 copy_thresh = 15;
- repeated packet_mclist mclist = 16;
- optional uint32 fanout = 17 [ default = 0xffffffff ];
- optional packet_ring rx_ring = 18;
- optional packet_ring tx_ring = 19;
-}
diff --git a/protobuf/pagemap.proto b/protobuf/pagemap.proto
deleted file mode 100644
index b492488c748b..000000000000
--- a/protobuf/pagemap.proto
+++ /dev/null
@@ -1,11 +0,0 @@
-import "opts.proto";
-
-message pagemap_head {
- required uint32 pages_id = 1;
-}
-
-message pagemap_entry {
- required uint64 vaddr = 1 [(criu).hex = true];
- required uint32 nr_pages = 2;
- optional bool in_parent = 3;
-}
diff --git a/protobuf/pipe-data.proto b/protobuf/pipe-data.proto
deleted file mode 100644
index 555f0394d825..000000000000
--- a/protobuf/pipe-data.proto
+++ /dev/null
@@ -1,5 +0,0 @@
-message pipe_data_entry {
- required uint32 pipe_id = 1;
- required uint32 bytes = 2;
- optional uint32 size = 3;
-}
diff --git a/protobuf/pipe.proto b/protobuf/pipe.proto
deleted file mode 100644
index d374430bf95a..000000000000
--- a/protobuf/pipe.proto
+++ /dev/null
@@ -1,9 +0,0 @@
-import "opts.proto";
-import "fown.proto";
-
-message pipe_entry {
- required uint32 id = 1;
- required uint32 pipe_id = 2;
- required uint32 flags = 3 [(criu).hex = true];
- required fown_entry fown = 4;
-}
diff --git a/protobuf/pstree.proto b/protobuf/pstree.proto
deleted file mode 100644
index 6cbcfd3e3bad..000000000000
--- a/protobuf/pstree.proto
+++ /dev/null
@@ -1,7 +0,0 @@
-message pstree_entry {
- required uint32 pid = 1;
- required uint32 ppid = 2;
- required uint32 pgid = 3;
- required uint32 sid = 4;
- repeated uint32 threads = 5;
-}
diff --git a/protobuf/regfile.proto b/protobuf/regfile.proto
deleted file mode 100644
index 3a9456fdcc4d..000000000000
--- a/protobuf/regfile.proto
+++ /dev/null
@@ -1,12 +0,0 @@
-import "opts.proto";
-import "fown.proto";
-
-message reg_file_entry {
- required uint32 id = 1;
- required uint32 flags = 2 [(criu).flags = "rfile.flags"];
- required uint64 pos = 3;
- required fown_entry fown = 5;
- required string name = 6;
- optional sint32 mnt_id = 7 [default = -1];
- optional uint64 size = 8;
-}
diff --git a/protobuf/remap-file-path.proto b/protobuf/remap-file-path.proto
deleted file mode 100644
index 68549746bad8..000000000000
--- a/protobuf/remap-file-path.proto
+++ /dev/null
@@ -1,11 +0,0 @@
-enum remap_type {
- LINKED = 0;
- GHOST = 1;
- PROCFS = 2;
-};
-
-message remap_file_path_entry {
- required uint32 orig_id = 1;
- required uint32 remap_id = 2;
- optional remap_type remap_type = 3;
-}
diff --git a/protobuf/rlimit.proto b/protobuf/rlimit.proto
deleted file mode 100644
index bcf1134b4fea..000000000000
--- a/protobuf/rlimit.proto
+++ /dev/null
@@ -1,4 +0,0 @@
-message rlimit_entry {
- required uint64 cur = 1;
- required uint64 max = 2;
-}
diff --git a/protobuf/rpc.proto b/protobuf/rpc.proto
deleted file mode 100644
index 4f6ed8df1fc7..000000000000
--- a/protobuf/rpc.proto
+++ /dev/null
@@ -1,172 +0,0 @@
-message criu_page_server_info {
- optional string address = 1;
- optional int32 port = 2;
- optional int32 pid = 3;
- optional int32 fd = 4;
-}
-
-message criu_veth_pair {
- required string if_in = 1;
- required string if_out = 2;
-};
-
-message ext_mount_map {
- required string key = 1;
- required string val = 2;
-};
-
-message inherit_fd {
- required string key = 1;
- required int32 fd = 2;
-};
-
-message cgroup_root {
- optional string ctrl = 1;
- required string path = 2;
-};
-
-message unix_sk {
- required uint32 inode = 1;
-};
-
-enum criu_cg_mode {
- IGNORE = 0;
- NONE = 1;
- PROPS = 2;
- SOFT = 3;
- FULL = 4;
- STRICT = 5;
- DEFAULT = 6;
-};
-
-message criu_opts {
- required int32 images_dir_fd = 1;
- optional int32 pid = 2; /* if not set on dump, will dump requesting process */
-
- optional bool leave_running = 3;
- optional bool ext_unix_sk = 4;
- optional bool tcp_established = 5;
- optional bool evasive_devices = 6;
- optional bool shell_job = 7;
- optional bool file_locks = 8;
- optional int32 log_level = 9 [default = 2];
- optional string log_file = 10; /* No subdirs are allowed. Consider using work-dir */
-
- optional criu_page_server_info ps = 11;
-
- optional bool notify_scripts = 12;
-
- optional string root = 13;
- optional string parent_img = 14;
- optional bool track_mem = 15;
- optional bool auto_dedup = 16;
-
- optional int32 work_dir_fd = 17;
- optional bool link_remap = 18;
- repeated criu_veth_pair veths = 19;
-
- optional uint32 cpu_cap = 20 [default = 0xffffffff];
- optional bool force_irmap = 21;
- repeated string exec_cmd = 22;
-
- repeated ext_mount_map ext_mnt = 23;
- optional bool manage_cgroups = 24; /* backward compatibility */
- repeated cgroup_root cg_root = 25;
-
- optional bool rst_sibling = 26; /* swrk only */
- repeated inherit_fd inherit_fd = 27; /* swrk only */
-
- optional bool auto_ext_mnt = 28;
- optional bool ext_sharing = 29;
- optional bool ext_masters = 30;
-
- repeated string skip_mnt = 31;
- repeated string enable_fs = 32;
-
- repeated unix_sk unix_sk_ino = 33;
-
- optional criu_cg_mode manage_cgroups_mode = 34;
- optional uint32 ghost_limit = 35 [default = 0x100000];
- repeated string irmap_scan_paths = 36;
- repeated string external = 37;
-}
-
-message criu_dump_resp {
- optional bool restored = 1;
-}
-
-message criu_restore_resp {
- required int32 pid = 1;
-}
-
-message criu_notify {
- optional string script = 1;
- optional int32 pid = 2;
-}
-
-enum criu_req_type {
- EMPTY = 0;
- DUMP = 1;
- RESTORE = 2;
- CHECK = 3;
- PRE_DUMP = 4;
- PAGE_SERVER = 5;
-
- NOTIFY = 6;
-
- CPUINFO_DUMP = 7;
- CPUINFO_CHECK = 8;
-
- FEATURE_CHECK = 9;
-}
-
-/*
- * List of features which can queried via
- * CRIU_REQ_TYPE__FEATURE_CHECK
- */
-message criu_features {
- optional bool mem_track = 1;
-}
-
-/*
- * Request -- each type corresponds to must-be-there
- * request arguments of respective type
- */
-
-message criu_req {
- required criu_req_type type = 1;
-
- optional criu_opts opts = 2;
- optional bool notify_success = 3;
-
- /*
- * When set service won't close the connection but
- * will wait for more req-s to appear. Works not
- * for all request types.
- */
- optional bool keep_open = 4;
- /*
- * 'features' can be used to query which features
- * are supported by the installed criu/kernel
- * via RPC.
- */
- optional criu_features features = 5;
-}
-
-/*
- * Response -- it states whether the request was served
- * and additional request-specific information
- */
-
-message criu_resp {
- required criu_req_type type = 1;
- required bool success = 2;
-
- optional criu_dump_resp dump = 3;
- optional criu_restore_resp restore = 4;
- optional criu_notify notify = 5;
- optional criu_page_server_info ps = 6;
-
- optional int32 cr_errno = 7;
- optional criu_features features = 8;
-}
diff --git a/protobuf/sa.proto b/protobuf/sa.proto
deleted file mode 100644
index e5099100b8b1..000000000000
--- a/protobuf/sa.proto
+++ /dev/null
@@ -1,8 +0,0 @@
-import "opts.proto";
-
-message sa_entry {
- required uint64 sigaction = 1 [(criu).hex = true];
- required uint64 flags = 2 [(criu).hex = true];
- required uint64 restorer = 3 [(criu).hex = true];
- required uint64 mask = 4 [(criu).hex = true];
-}
diff --git a/protobuf/seccomp.proto b/protobuf/seccomp.proto
deleted file mode 100644
index 03b248cc0eef..000000000000
--- a/protobuf/seccomp.proto
+++ /dev/null
@@ -1,8 +0,0 @@
-message seccomp_filter {
- required bytes filter = 1;
- optional uint32 prev = 2;
-}
-
-message seccomp_entry {
- repeated seccomp_filter seccomp_filters = 1;
-}
diff --git a/protobuf/siginfo.proto b/protobuf/siginfo.proto
deleted file mode 100644
index c3630f9c00f6..000000000000
--- a/protobuf/siginfo.proto
+++ /dev/null
@@ -1,7 +0,0 @@
-message siginfo_entry {
- required bytes siginfo = 1;
-}
-
-message signal_queue_entry {
- repeated siginfo_entry signals = 1;
-}
diff --git a/protobuf/signalfd.proto b/protobuf/signalfd.proto
deleted file mode 100644
index 0af21598d4d6..000000000000
--- a/protobuf/signalfd.proto
+++ /dev/null
@@ -1,9 +0,0 @@
-import "opts.proto";
-import "fown.proto";
-
-message signalfd_entry {
- required uint32 id = 1;
- required uint32 flags = 2 [(criu).hex = true];
- required fown_entry fown = 3;
- required uint64 sigmask = 4 [(criu).hex = true];
-};
diff --git a/protobuf/sk-inet.proto b/protobuf/sk-inet.proto
deleted file mode 100644
index a2770dfae803..000000000000
--- a/protobuf/sk-inet.proto
+++ /dev/null
@@ -1,40 +0,0 @@
-import "opts.proto";
-import "fown.proto";
-import "sk-opts.proto";
-
-message ip_opts_entry {
- optional bool freebind = 1;
-}
-
-message inet_sk_entry {
- /*
- * We have two IDs here -- id and ino. The first one
- * is used when restoring socket behind a file descriprot.
- * The fdinfo image's id is it. The second one is used
- * in sk-inet.c internally, in particular we identify
- * a TCP stream to restore into this socket using the
- * ino value.
- */
- required uint32 id = 1;
- required uint32 ino = 2;
- required uint32 family = 3;
- required uint32 type = 4;
- required uint32 proto = 5;
- required uint32 state = 6;
- required uint32 src_port = 7;
- required uint32 dst_port = 8;
- required uint32 flags = 9 [(criu).hex = true];
- required uint32 backlog = 10;
-
- repeated uint32 src_addr = 11 [(criu).ipadd = true];
- repeated uint32 dst_addr = 12 [(criu).ipadd = true];
-
- required fown_entry fown = 13;
- required sk_opts_entry opts = 14;
- optional bool v6only = 15;
- optional ip_opts_entry ip_opts = 16;
-
- /* for ipv6, we need to send the ifindex to bind(); we keep the ifname
- * here and convert it on restore */
- optional string ifname = 17;
-}
diff --git a/protobuf/sk-netlink.proto b/protobuf/sk-netlink.proto
deleted file mode 100644
index bca533c308cb..000000000000
--- a/protobuf/sk-netlink.proto
+++ /dev/null
@@ -1,17 +0,0 @@
-import "opts.proto";
-import "fown.proto";
-import "sk-opts.proto";
-
-message netlink_sk_entry {
- required uint32 id = 1;
- required uint32 ino = 2;
- required uint32 protocol = 3;
- required uint32 state = 4;
- required uint32 flags = 6 [(criu).hex = true];
- required uint32 portid = 7;
- repeated uint32 groups = 8;
- required uint32 dst_portid = 9;
- required uint32 dst_group = 10;
- required fown_entry fown = 11;
- required sk_opts_entry opts = 12;
-}
diff --git a/protobuf/sk-opts.proto b/protobuf/sk-opts.proto
deleted file mode 100644
index 1d21651a1c2f..000000000000
--- a/protobuf/sk-opts.proto
+++ /dev/null
@@ -1,29 +0,0 @@
-message sk_opts_entry {
- required uint32 so_sndbuf = 1;
- required uint32 so_rcvbuf = 2;
-
- required uint64 so_snd_tmo_sec = 3;
- required uint64 so_snd_tmo_usec = 4;
- required uint64 so_rcv_tmo_sec = 5;
- required uint64 so_rcv_tmo_usec = 6;
- optional bool reuseaddr = 7;
-
- optional uint32 so_priority = 8;
- optional uint32 so_rcvlowat = 9;
- optional uint32 so_mark = 10;
- optional bool so_passcred = 11;
- optional bool so_passsec = 12;
- optional bool so_dontroute = 13;
- optional bool so_no_check = 14;
-
- optional string so_bound_dev = 15;
-
- repeated fixed64 so_filter = 16;
-}
-
-enum sk_shutdown {
- NONE = 0;
- READ = 1;
- WRITE = 2;
- BOTH = 3;
-}
diff --git a/protobuf/sk-packet.proto b/protobuf/sk-packet.proto
deleted file mode 100644
index 10ef5c936e35..000000000000
--- a/protobuf/sk-packet.proto
+++ /dev/null
@@ -1,4 +0,0 @@
-message sk_packet_entry {
- required uint32 id_for = 1;
- required uint32 length = 2;
-}
diff --git a/protobuf/sk-unix.proto b/protobuf/sk-unix.proto
deleted file mode 100644
index aa2bcf7e109c..000000000000
--- a/protobuf/sk-unix.proto
+++ /dev/null
@@ -1,48 +0,0 @@
-import "opts.proto";
-import "fown.proto";
-import "sk-opts.proto";
-
-message file_perms_entry {
- required uint32 mode = 1;
- required uint32 uid = 2;
- required uint32 gid = 3;
-}
-
-message unix_sk_entry {
- /*
- * Few words about why we need both -- id and ino.
- *
- * The former one is used to link file descriptor from
- * fdinfo image with the unix_sk_entry that should be
- * opened under it.
- *
- * The latter one ties together unix peers -- the peer
- * member on this structure is the ino one of its peer
- * and simetimes vise-versa.
- */
- required uint32 id = 1;
- required uint32 ino = 2;
- required uint32 type = 3;
- required uint32 state = 4;
- required uint32 flags = 5 [(criu).hex = true];
- required uint32 uflags = 6 [(criu).hex = true];
- required uint32 backlog = 7;
- required uint32 peer = 8;
- required fown_entry fown = 9;
- required sk_opts_entry opts = 10;
-
- /*
- * Abstract name may contain \0 at any point,
- * so we need to carry it as byte sequence...
- */
- required bytes name = 11;
-
- optional sk_shutdown shutdown = 12;
-
- optional file_perms_entry file_perms = 13;
-
- /*
- * Relative socket name may have prefix.
- */
- optional string name_dir = 14;
-}
diff --git a/protobuf/stats.proto b/protobuf/stats.proto
deleted file mode 100644
index 16acf3400486..000000000000
--- a/protobuf/stats.proto
+++ /dev/null
@@ -1,28 +0,0 @@
-// This one contains statistics about dump/restore process
-message dump_stats_entry {
- required uint32 freezing_time = 1;
- required uint32 frozen_time = 2;
- required uint32 memdump_time = 3;
- required uint32 memwrite_time = 4;
-
- required uint64 pages_scanned = 5;
- required uint64 pages_skipped_parent = 6;
- required uint64 pages_written = 7;
-
- optional uint32 irmap_resolve = 8;
-}
-
-message restore_stats_entry {
- required uint64 pages_compared = 1;
- required uint64 pages_skipped_cow = 2;
-
- required uint32 forking_time = 3;
- required uint32 restore_time = 4;
-
- optional uint64 pages_restored = 5;
-}
-
-message stats_entry {
- optional dump_stats_entry dump = 1;
- optional restore_stats_entry restore = 2;
-}
diff --git a/protobuf/tcp-stream.proto b/protobuf/tcp-stream.proto
deleted file mode 100644
index 59c053e45cff..000000000000
--- a/protobuf/tcp-stream.proto
+++ /dev/null
@@ -1,19 +0,0 @@
-import "opts.proto";
-
-message tcp_stream_entry {
- required uint32 inq_len = 1;
- required uint32 inq_seq = 2;
- required uint32 outq_len = 3; /* unsent and sent data in the send queue*/
- required uint32 outq_seq = 4;
-
- required uint32 opt_mask = 5 [(criu).hex = true]; /* TCPI_OPT_ bits */
- required uint32 snd_wscale = 6;
- required uint32 mss_clamp = 7;
- optional uint32 rcv_wscale = 8;
- optional uint32 timestamp = 9;
-
- optional bool cork = 10;
- optional bool nodelay = 11;
-
- optional uint32 unsq_len = 12; /* unsent data in the send queue */
-}
diff --git a/protobuf/time.proto b/protobuf/time.proto
deleted file mode 100644
index 09cdf42a6525..000000000000
--- a/protobuf/time.proto
+++ /dev/null
@@ -1,4 +0,0 @@
-message timeval {
- required uint64 tv_sec = 1;
- required uint64 tv_usec = 2;
-}
diff --git a/protobuf/timer.proto b/protobuf/timer.proto
deleted file mode 100644
index c584dec6dc6f..000000000000
--- a/protobuf/timer.proto
+++ /dev/null
@@ -1,27 +0,0 @@
-message itimer_entry {
- required uint64 isec = 1;
- required uint64 iusec = 2;
- required uint64 vsec = 3;
- required uint64 vusec = 4;
-}
-
-message posix_timer_entry {
- required uint32 it_id = 1;
- required uint32 clock_id = 2;
- required uint32 si_signo = 3;
- required uint32 it_sigev_notify = 4;
- required uint64 sival_ptr = 5;
- required uint32 overrun = 6;
-
- required uint64 isec = 7;
- required uint64 insec = 8;
- required uint64 vsec = 9;
- required uint64 vnsec = 10;
-}
-
-message task_timers_entry {
- required itimer_entry real = 1;
- required itimer_entry virt = 2;
- required itimer_entry prof = 3;
- repeated posix_timer_entry posix = 4;
-}
diff --git a/protobuf/timerfd.proto b/protobuf/timerfd.proto
deleted file mode 100644
index 9e3ba6709e2c..000000000000
--- a/protobuf/timerfd.proto
+++ /dev/null
@@ -1,17 +0,0 @@
-import "opts.proto";
-import "fown.proto";
-
-message timerfd_entry {
- required uint32 id = 1;
- required uint32 flags = 2 [(criu).hex = true];
- required fown_entry fown = 3;
-
- required uint32 clockid = 4;
- required uint64 ticks = 5;
- required uint32 settime_flags = 6 [(criu).hex = true];
-
- required uint64 vsec = 7;
- required uint64 vnsec = 8;
- required uint64 isec = 9;
- required uint64 insec = 10;
-}
diff --git a/protobuf/tty.proto b/protobuf/tty.proto
deleted file mode 100644
index 4b5a70c20a88..000000000000
--- a/protobuf/tty.proto
+++ /dev/null
@@ -1,73 +0,0 @@
-import "opts.proto";
-import "fown.proto";
-
-message winsize_entry {
- required uint32 ws_row = 1;
- required uint32 ws_col = 2;
- required uint32 ws_xpixel = 3;
- required uint32 ws_ypixel = 4;
-};
-
-message termios_entry {
- required uint32 c_iflag = 1;
- required uint32 c_oflag = 2;
- required uint32 c_cflag = 3;
- required uint32 c_lflag = 4;
- required uint32 c_line = 5;
- required uint32 c_ispeed = 6;
- required uint32 c_ospeed = 7;
-
- repeated uint32 c_cc = 8;
-}
-
-message tty_pty_entry {
- required uint32 index = 1;
-}
-
-enum TtyType {
- UNKNOWN = 0;
- PTY = 1;
- CONSOLE = 2;
- VT = 3;
- CTTY = 4;
- EXT_TTY = 5;
-}
-
-message tty_info_entry {
- required uint32 id = 1;
-
- required TtyType type = 2;
-
- required bool locked = 3; /* Unix98 PTY only */
- required bool exclusive = 4;
- required bool packet_mode = 5; /* Unix98 PTY only */
-
- required uint32 sid = 6;
- required uint32 pgrp = 7;
-
- /*
- * Convenient for printing errors and such, with this
- * device encoded we can figure out major and minor
- * numbers.
- */
- required uint32 rdev = 8;
-
- optional termios_entry termios = 9;
- optional termios_entry termios_locked = 10;
- optional winsize_entry winsize = 11;
-
- /*
- * These are optional fields which presense depends on
- * TTY type.
- */
- optional tty_pty_entry pty = 12;
- optional uint32 dev = 13;
-};
-
-message tty_file_entry {
- required uint32 id = 1;
- required uint32 tty_info_id = 2;
-
- required uint32 flags = 3 [(criu).hex = true];
- required fown_entry fown = 4;
-}
diff --git a/protobuf/tun.proto b/protobuf/tun.proto
deleted file mode 100644
index 4798166e58c8..000000000000
--- a/protobuf/tun.proto
+++ /dev/null
@@ -1,15 +0,0 @@
-import "opts.proto";
-
-message tunfile_entry {
- required uint32 id = 1;
- optional string netdev = 2;
- optional bool detached = 3;
-};
-
-message tun_link_entry {
- required uint32 flags = 1 [(criu).hex = true];
- required int32 owner = 2;
- required int32 group = 3;
- required uint32 vnethdr = 4;
- required uint32 sndbuf = 5;
-};
diff --git a/protobuf/userns.proto b/protobuf/userns.proto
deleted file mode 100644
index 9428549619b8..000000000000
--- a/protobuf/userns.proto
+++ /dev/null
@@ -1,10 +0,0 @@
-message uid_gid_extent {
- required uint32 first = 1;
- required uint32 lower_first = 2;
- required uint32 count = 3;
-}
-
-message userns_entry {
- repeated uid_gid_extent uid_map = 1;
- repeated uid_gid_extent gid_map = 2;
-}
diff --git a/protobuf/utsns.proto b/protobuf/utsns.proto
deleted file mode 100644
index cf0a752b71ea..000000000000
--- a/protobuf/utsns.proto
+++ /dev/null
@@ -1,4 +0,0 @@
-message utsns_entry {
- required string nodename = 1;
- required string domainname = 2;
-}
diff --git a/protobuf/vma.proto b/protobuf/vma.proto
deleted file mode 100644
index e65070711228..000000000000
--- a/protobuf/vma.proto
+++ /dev/null
@@ -1,23 +0,0 @@
-import "opts.proto";
-
-message vma_entry {
- required uint64 start = 1 [(criu).hex = true];
- required uint64 end = 2 [(criu).hex = true];
- required uint64 pgoff = 3;
- required uint64 shmid = 4;
- required uint32 prot = 5 [(criu).flags = "mmap.prot" ];
- required uint32 flags = 6 [(criu).flags = "mmap.flags" ];
- required uint32 status = 7 [(criu).flags = "mmap.status" ];
- /*
- * This fd thing is unused in the image, it was lost
- * while switching from execve restore model. It is
- * -1 by default.
- */
- required sint64 fd = 8;
-
- /* madvise flags bitmap */
- optional uint64 madv = 9 [(criu).hex = true];
-
- /* file status flags */
- optional uint32 fdflags = 10 [(criu).hex = true];
-}
--
2.5.0
More information about the CRIU
mailing list