Commit e85e5fdb authored by Andrey Vagin's avatar Andrey Vagin Committed by Pavel Emelyanov

crtools: don't include pstree.h in parasite-syscall.h

pstree and parasite are two different subsystems, so it "should" not
depend on each other.

parasite-syscall uses the pid struct, so this patch moves it in a
separate header.
Signed-off-by: 's avatarAndrey Vagin <avagin@openvz.org>
Signed-off-by: 's avatarPavel Emelyanov <xemul@parallels.com>
parent 96cc0076
#ifndef __CR_PARASITE_SYSCALL_H__ #ifndef __CR_PARASITE_SYSCALL_H__
#define __CR_PARASITE_SYSCALL_H__ #define __CR_PARASITE_SYSCALL_H__
#define BUILTIN_SYSCALL_SIZE 8 #include "pid.h"
#include "list.h"
#include "pstree.h" #define BUILTIN_SYSCALL_SIZE 8
struct parasite_dump_thread; struct parasite_dump_thread;
struct parasite_dump_misc; struct parasite_dump_misc;
......
#ifndef __CR_PID_H__
#define __CR_PID_H__
struct pid {
/*
* The @real pid is used to fetch tasks during dumping stage,
* This is a global pid seen from the context where the dumping
* is running.
*/
pid_t real;
/*
* The @virt pid is one which used in the image itself and keeps
* the pid value to be restored. This pid fetched from the
* dumpee context, because the dumpee might have own pid namespace.
*/
pid_t virt;
};
#endif
...@@ -2,6 +2,7 @@ ...@@ -2,6 +2,7 @@
#define __CR_PSTREE_H__ #define __CR_PSTREE_H__
#include "list.h" #include "list.h"
#include "pid.h"
#include "crtools.h" #include "crtools.h"
#include "protobuf/core.pb-c.h" #include "protobuf/core.pb-c.h"
...@@ -11,22 +12,6 @@ ...@@ -11,22 +12,6 @@
*/ */
#define INIT_PID (1) #define INIT_PID (1)
struct pid {
/*
* The @real pid is used to fetch tasks during dumping stage,
* This is a global pid seen from the context where the dumping
* is running.
*/
pid_t real;
/*
* The @virt pid is one which used in the image itself and keeps
* the pid value to be restored. This pid fetched from the
* dumpee context, because the dumpee might have own pid namespace.
*/
pid_t virt;
};
struct pstree_item { struct pstree_item {
struct pstree_item *parent; struct pstree_item *parent;
struct list_head children; /* list of my children */ struct list_head children; /* list of my children */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment