diff --git a/cr-dump.c b/cr-dump.c index 39e4555c7..d907a3e8d 100644 --- a/cr-dump.c +++ b/cr-dump.c @@ -63,6 +63,7 @@ #include "mem.h" #include "vdso.h" #include "page-pipe.h" +#include "posix-timer.h" #include "vdso.h" #include "cr-service.h" diff --git a/include/posix-timer.h b/include/posix-timer.h new file mode 100644 index 000000000..70b007f64 --- /dev/null +++ b/include/posix-timer.h @@ -0,0 +1,24 @@ +#ifndef __CR_PROC_POSIX_TIMER_H__ +#define __CR_PROC_POSIX_TIMER_H__ + +struct str_posix_timer { + long it_id; + int clock_id; + int si_signo; + int it_sigev_notify; + void * sival_ptr; +}; + +struct proc_posix_timer { + struct list_head list; + struct str_posix_timer spt; +}; + +struct proc_posix_timers_stat { + int timer_n; + struct list_head timers; +}; + +extern int parse_posix_timers(pid_t pid, struct proc_posix_timers_stat * args); + +#endif diff --git a/include/proc_parse.h b/include/proc_parse.h index 71bf00b44..553a8bbc0 100644 --- a/include/proc_parse.h +++ b/include/proc_parse.h @@ -3,7 +3,6 @@ #include #include "asm/types.h" -#include "restorer.h" #include "image.h" #include "list.h" @@ -128,16 +127,6 @@ struct mount_info { struct list_head postpone; }; -struct proc_posix_timer { - struct list_head list; - struct str_posix_timer spt; -}; - -struct proc_posix_timers_stat { - int timer_n; - struct list_head timers; -}; - extern struct mount_info *mnt_entry_alloc(); extern void mnt_entry_free(struct mount_info *mi); @@ -162,8 +151,6 @@ extern int parse_fdinfo(int fd, int type, extern int parse_cpuinfo_features(int (*handler)(char *tok)); extern int parse_file_locks(void); -extern int parse_posix_timers(pid_t pid, struct proc_posix_timers_stat * args); - struct pid; extern int parse_threads(int pid, struct pid **_t, int *_n); diff --git a/include/restorer.h b/include/restorer.h index e76d68d4c..6ddf8feb7 100644 --- a/include/restorer.h +++ b/include/restorer.h @@ -14,6 +14,7 @@ #include "crtools.h" #include "asm/restorer.h" +#include "posix-timer.h" #include "vdso.h" #include @@ -55,14 +56,6 @@ struct rst_sched_param { int prio; }; -struct str_posix_timer { - long it_id; - int clock_id; - int si_signo; - int it_sigev_notify; - void * sival_ptr; -}; - struct restore_posix_timer { struct str_posix_timer spt; struct itimerspec val; diff --git a/parasite-syscall.c b/parasite-syscall.c index ea8f19a3a..92f14a1c4 100644 --- a/parasite-syscall.c +++ b/parasite-syscall.c @@ -22,6 +22,7 @@ #include "namespaces.h" #include "kerndat.h" #include "pstree.h" +#include "posix-timer.h" #include "net.h" #include "mem.h" #include "restorer.h" diff --git a/proc_parse.c b/proc_parse.c index 96d9055d8..ea59cf72f 100644 --- a/proc_parse.c +++ b/proc_parse.c @@ -18,6 +18,7 @@ #include "file-lock.h" #include "pstree.h" #include "fsnotify.h" +#include "posix-timer.h" #include "kerndat.h" #include "vdso.h" diff --git a/security.c b/security.c index 1901145ea..27eaf2ed9 100644 --- a/security.c +++ b/security.c @@ -3,6 +3,8 @@ #include "proc_parse.h" #include "log.h" +#include "protobuf/creds.pb-c.h" + /* * UID and GID of user requesting for C/R */