2
0
mirror of https://github.com/checkpoint-restore/criu synced 2025-08-22 09:58:09 +00:00
criu/include/fs-magic.h
Tycho Andersen f020bef776 remap: add a dead pid /proc remap
If a file like /proc/20/mountinfo is open, but 20 is a zombie (or doesn't exist
any more), we can't read this file at all, so a link remap won't work. Instead,
we add a new remap, called the dead process remap, which forks a TASK_HELPER as
that dead pid so that the restore task can open the new /proc/20/mountinfo
instead.

This commit also adds a new stage CR_STATE_RESTORE_SHARED. Since new
TASK_HELPERS are added when loading the shared resource images, we need to wait
to start forking tasks until after these resources are loaded.

v2: fix a mutex bug

Signed-off-by: Tycho Andersen <tycho.andersen@canonical.com>
Signed-off-by: Pavel Emelyanov <xemul@parallels.com>
2014-09-19 17:42:48 +04:00

49 lines
815 B
C

#ifndef __CR_FS_MAGIC_H__
#define __CR_FS_MAGIC_H__
#include <sys/vfs.h>
/*
* Gather magic numbers in case if distros
* do not provide appropriate entry in
* linux/magic.h.
*/
#ifndef NFS_SUPER_MAGIC
# define NFS_SUPER_MAGIC 0x6969
#endif
#ifndef PIPEFS_MAGIC
# define PIPEFS_MAGIC 0x50495045
#endif
#ifndef ANON_INODE_FS_MAGIC
# define ANON_INODE_FS_MAGIC 0x09041934
#endif
#ifndef TMPFS_MAGIC
# define TMPFS_MAGIC 0x01021994
#endif
#ifndef SOCKFS_MAGIC
# define SOCKFS_MAGIC 0x534f434b
#endif
#ifndef DEVPTS_SUPER_MAGIC
#define DEVPTS_SUPER_MAGIC 0x1cd1
#endif
#ifndef BTRFS_SUPER_MAGIC
#define BTRFS_SUPER_MAGIC 0x9123683E
#endif
#ifndef AUFS_SUPER_MAGIC
#define AUFS_SUPER_MAGIC 0x61756673
#endif
#ifndef PROC_SUPER_MAGIC
#define PROC_SUPER_MAGIC 0x9fa0
#endif
#endif /* __CR_FS_MAGIC_H__ */