[CRIU] [PATCH 64/78] headers: Move lock.h into include/common/

Cyrill Gorcunov gorcunov at openvz.org
Mon Nov 7 08:36:49 PST 2016


Signed-off-by: Cyrill Gorcunov <gorcunov at openvz.org>
---
 criu/cr-restore.c                       | 2 +-
 criu/files.c                            | 2 +-
 criu/fsnotify.c                         | 2 +-
 criu/include/files.h                    | 2 +-
 criu/include/parasite.h                 | 2 +-
 criu/include/restorer.h                 | 2 +-
 criu/include/rst_info.h                 | 2 +-
 criu/include/shmem.h                    | 2 +-
 criu/infect-rpc.c                       | 2 +-
 criu/infect-util.c                      | 2 +-
 criu/infect.c                           | 2 +-
 criu/log.c                              | 2 +-
 criu/pie/parasite.c                     | 2 +-
 criu/pie/restorer.c                     | 2 +-
 criu/pstree.c                           | 2 +-
 criu/uffd.c                             | 2 +-
 {criu/include => include/common}/lock.h | 8 ++++----
 17 files changed, 20 insertions(+), 20 deletions(-)
 rename {criu/include => include/common}/lock.h (97%)

diff --git a/criu/cr-restore.c b/criu/cr-restore.c
index 834e30740006..a340167c06e0 100644
--- a/criu/cr-restore.c
+++ b/criu/cr-restore.c
@@ -38,7 +38,7 @@
 #include "restorer.h"
 #include "sockets.h"
 #include "sk-packet.h"
-#include "lock.h"
+#include "common/lock.h"
 #include "files.h"
 #include "files-reg.h"
 #include "pipes.h"
diff --git a/criu/files.c b/criu/files.c
index 21af891e99de..52b05bb5ee08 100644
--- a/criu/files.c
+++ b/criu/files.c
@@ -22,7 +22,7 @@
 #include "common/list.h"
 #include "rst-malloc.h"
 #include "util-pie.h"
-#include "lock.h"
+#include "common/lock.h"
 #include "sockets.h"
 #include "pstree.h"
 #include "tty.h"
diff --git a/criu/fsnotify.c b/criu/fsnotify.c
index b1b495db361a..a6e47a8213d4 100644
--- a/criu/fsnotify.c
+++ b/criu/fsnotify.c
@@ -35,7 +35,7 @@
 #include "file-ids.h"
 #include "criu-log.h"
 #include "common/list.h"
-#include "lock.h"
+#include "common/lock.h"
 #include "irmap.h"
 #include "cr_options.h"
 #include "namespaces.h"
diff --git a/criu/include/files.h b/criu/include/files.h
index 153e7b30043a..229c0d2e6f16 100644
--- a/criu/include/files.h
+++ b/criu/include/files.h
@@ -6,7 +6,7 @@
 #include "int.h"
 #include "common/compiler.h"
 #include "fcntl.h"
-#include "lock.h"
+#include "common/lock.h"
 #include "common/list.h"
 #include "pid.h"
 #include "rst_info.h"
diff --git a/criu/include/parasite.h b/criu/include/parasite.h
index 37734c7e8411..21db35d76b8a 100644
--- a/criu/include/parasite.h
+++ b/criu/include/parasite.h
@@ -12,7 +12,7 @@
 
 #include "image.h"
 #include "util-pie.h"
-#include "lock.h"
+#include "common/lock.h"
 #include "infect-rpc.h"
 
 #include "images/vma.pb-c.h"
diff --git a/criu/include/restorer.h b/criu/include/restorer.h
index 1deff1e55979..1d7fc91a81e3 100644
--- a/criu/include/restorer.h
+++ b/criu/include/restorer.h
@@ -9,7 +9,7 @@
 #include "int.h"
 #include "common/compiler.h"
 #include <compel/asm/fpu.h>
-#include "lock.h"
+#include "common/lock.h"
 #include "util.h"
 #include "asm/restorer.h"
 #include "config.h"
diff --git a/criu/include/rst_info.h b/criu/include/rst_info.h
index 71110a147ffe..26f61bcf35a3 100644
--- a/criu/include/rst_info.h
+++ b/criu/include/rst_info.h
@@ -1,7 +1,7 @@
 #ifndef __CR_RST_INFO_H__
 #define __CR_RST_INFO_H__
 
-#include "lock.h"
+#include "common/lock.h"
 #include "common/list.h"
 #include "vma.h"
 
diff --git a/criu/include/shmem.h b/criu/include/shmem.h
index 3d190bdb3f6e..63e7e9f6311a 100644
--- a/criu/include/shmem.h
+++ b/criu/include/shmem.h
@@ -2,7 +2,7 @@
 #define __CR_SHMEM_H__
 
 #include "int.h"
-#include "lock.h"
+#include "common/lock.h"
 #include "images/vma.pb-c.h"
 
 struct _VmaEntry;
diff --git a/criu/infect-rpc.c b/criu/infect-rpc.c
index c8b97a297f6d..0994bcb35a0a 100644
--- a/criu/infect-rpc.c
+++ b/criu/infect-rpc.c
@@ -1,7 +1,7 @@
 #include "log.h"
 #include "common/bug.h"
 #include "common/xmalloc.h"
-#include "lock.h"
+#include "common/lock.h"
 
 #include "infect.h"
 #include "infect-priv.h"
diff --git a/criu/infect-util.c b/criu/infect-util.c
index 4c0537fdc512..275e2ec8181e 100644
--- a/criu/infect-util.c
+++ b/criu/infect-util.c
@@ -1,7 +1,7 @@
 #include "int.h"
 #include "log.h"
 #include "common/bug.h"
-#include "lock.h"
+#include "common/lock.h"
 #include "util-pie.h"
 
 #include "infect-rpc.h"
diff --git a/criu/infect.c b/criu/infect.c
index fa9f270a5b0a..cd6f1a9b87e9 100644
--- a/criu/infect.c
+++ b/criu/infect.c
@@ -14,7 +14,7 @@
 #include "criu-log.h"
 #include "common/bug.h"
 #include "common/xmalloc.h"
-#include "lock.h"
+#include "common/lock.h"
 
 #include <compel/plugins/std/syscall-codes.h>
 #include <compel/plugins/std/asm/syscall-types.h>
diff --git a/criu/log.c b/criu/log.c
index 274361f31db2..4174355cff6e 100644
--- a/criu/log.c
+++ b/criu/log.c
@@ -18,7 +18,7 @@
 #include "cr_options.h"
 #include "servicefd.h"
 #include "rst-malloc.h"
-#include "lock.h"
+#include "common/lock.h"
 #include "string.h"
 
 #define DEFAULT_LOGFD		STDERR_FILENO
diff --git a/criu/pie/parasite.c b/criu/pie/parasite.c
index 120c80ca5da7..d926fdd62fa9 100644
--- a/criu/pie/parasite.c
+++ b/criu/pie/parasite.c
@@ -13,7 +13,7 @@
 #include "config.h"
 #include "fcntl.h"
 #include "prctl.h"
-#include "lock.h"
+#include "common/lock.h"
 #include "parasite-vdso.h"
 #include "criu-log.h"
 #include "tty.h"
diff --git a/criu/pie/restorer.c b/criu/pie/restorer.c
index c3425222182d..b7871c4493c2 100644
--- a/criu/pie/restorer.c
+++ b/criu/pie/restorer.c
@@ -33,7 +33,7 @@
 #include "vma.h"
 #include "uffd.h"
 
-#include "lock.h"
+#include "common/lock.h"
 #include "restorer.h"
 #include "aio.h"
 #include "seccomp.h"
diff --git a/criu/pstree.c b/criu/pstree.c
index ec1f7ee02dcc..943518d98fea 100644
--- a/criu/pstree.c
+++ b/criu/pstree.c
@@ -7,7 +7,7 @@
 #include "cr_options.h"
 #include "pstree.h"
 #include "rst-malloc.h"
-#include "lock.h"
+#include "common/lock.h"
 #include "namespaces.h"
 #include "files.h"
 #include "tty.h"
diff --git a/criu/uffd.c b/criu/uffd.c
index c96a8185373c..8cc2ec97354a 100644
--- a/criu/uffd.c
+++ b/criu/uffd.c
@@ -36,7 +36,7 @@
 #include <compel/plugins/std/syscall-codes.h>
 #include "restorer.h"
 #include "page-xfer.h"
-#include "lock.h"
+#include "common/lock.h"
 #include "rst-malloc.h"
 
 #undef  LOG_PREFIX
diff --git a/criu/include/lock.h b/include/common/lock.h
similarity index 97%
rename from criu/include/lock.h
rename to include/common/lock.h
index e73ff9171759..e993a71c9bdc 100644
--- a/criu/include/lock.h
+++ b/include/common/lock.h
@@ -1,5 +1,5 @@
-#ifndef __CR_LOCK_H__
-#define __CR_LOCK_H__
+#ifndef __CR_COMMON_LOCK_H__
+#define __CR_COMMON_LOCK_H__
 
 #include <stdint.h>
 #include <linux/futex.h>
@@ -7,7 +7,7 @@
 #include <limits.h>
 #include <errno.h>
 
-#include "atomic.h"
+#include "common/asm/atomic.h"
 
 #define LOCK_BUG_ON(condition)							\
 	if ((condition))							\
@@ -155,4 +155,4 @@ static inline void mutex_unlock(mutex_t *m)
 	LOCK_BUG_ON(sys_futex((uint32_t *)&m->raw.counter, FUTEX_WAKE, 1, NULL, NULL, 0) < 0);
 }
 
-#endif /* __CR_LOCK_H__ */
+#endif /* __CR_COMMON_LOCK_H__ */
-- 
2.7.4



More information about the CRIU mailing list