[CRIU] [PATCH 03/16] mm: add a macros to determing private vma-s (v2)

Andrey Vagin avagin at openvz.org
Wed Nov 14 12:19:12 EST 2012


Now this macros returns true only for anon | priv vmas.
It will be expanded to file | priv in a follow patch.

v2: check flags together.

Signed-off-by: Andrey Vagin <avagin at openvz.org>
---
 include/restorer.h | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/include/restorer.h b/include/restorer.h
index 44b30ec..4fc7a13 100644
--- a/include/restorer.h
+++ b/include/restorer.h
@@ -272,4 +272,6 @@ find_shmem(struct shmems *shmems, unsigned long shmid)
 /* the restorer_blob_offset__ prefix is added by gen_offsets.sh */
 #define restorer_sym(rblob, name)	((void *)(rblob) + restorer_blob_offset__##name)
 
+#define vma_priv(vma) (vma_entry_is(vma, VMA_AREA_REGULAR | VMA_ANON_PRIVATE))
+
 #endif /* CR_RESTORER_H__ */
-- 
1.7.11.7



More information about the CRIU mailing list