From f2a740fde139e37968779572f0ccbc2b3324d851 Mon Sep 17 00:00:00 2001 From: =?utf8?q?St=C3=A9phane=20Graber?= Date: Wed, 3 Jun 2015 19:37:59 -0400 Subject: [PATCH] Revert bdev.h to the way it was MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Instead of re-defining MS_ options all over the place, just revert the last change to bdev.h so we have all the defines in there again. Signed-off-by: Stéphane Graber --- src/lxc/bdev.c | 8 -------- src/lxc/bdev.h | 26 ++++++++++++++++++++++++++ src/lxc/cgfs.c | 4 ---- 3 files changed, 26 insertions(+), 12 deletions(-) diff --git a/src/lxc/bdev.c b/src/lxc/bdev.c index 0094f68fc..53465b1c6 100644 --- a/src/lxc/bdev.c +++ b/src/lxc/bdev.c @@ -63,14 +63,6 @@ #define LO_FLAGS_AUTOCLEAR 4 #endif -#ifndef MS_REC -#define MS_REC 16384 -#endif - -#ifndef MS_SLAVE -#define MS_SLAVE (1<<19) -#endif - #define DEFAULT_FS_SIZE 1073741824 #define DEFAULT_FSTYPE "ext3" diff --git a/src/lxc/bdev.h b/src/lxc/bdev.h index 2144c1926..ce4170867 100644 --- a/src/lxc/bdev.h +++ b/src/lxc/bdev.h @@ -31,6 +31,32 @@ #include #include + +/* define constants if the kernel/glibc headers don't define them */ +#ifndef MS_DIRSYNC +#define MS_DIRSYNC 128 +#endif + +#ifndef MS_REC +#define MS_REC 16384 +#endif + +#ifndef MNT_DETACH +#define MNT_DETACH 2 +#endif + +#ifndef MS_SLAVE +#define MS_SLAVE (1<<19) +#endif + +#ifndef MS_RELATIME +#define MS_RELATIME (1 << 21) +#endif + +#ifndef MS_STRICTATIME +#define MS_STRICTATIME (1 << 24) +#endif + struct bdev; struct bdev_ops { diff --git a/src/lxc/cgfs.c b/src/lxc/cgfs.c index dd156afd3..fcb3cde15 100644 --- a/src/lxc/cgfs.c +++ b/src/lxc/cgfs.c @@ -55,10 +55,6 @@ #include #endif -#ifndef MS_RELATIME -#define MS_RELATIME (1<<21) -#endif - struct cgroup_hierarchy; struct cgroup_meta_data; struct cgroup_mount_point; -- 2.47.3