From: Enrico Scholz Date: Fri, 20 Feb 2004 17:59:21 +0000 (+0000) Subject: added the enter-namespace stuff X-Git-Tag: VERSION_0_10~588 X-Git-Url: http://git.linux-vserver.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3f1f36fd6b3016ddc9b844bd7248a04516b6f6c6;p=util-vserver.git added the enter-namespace stuff git-svn-id: http://svn.linux-vserver.org/svn/util-vserver/trunk@975 94cd875c-1c1d-0410-91d2-eb244daf1a30 --- diff --git a/util-vserver/lib/Makefile-files b/util-vserver/lib/Makefile-files index 0f53752..fedb3e7 100644 --- a/util-vserver/lib/Makefile-files +++ b/util-vserver/lib/Makefile-files @@ -30,7 +30,9 @@ lib_management_SRCS = lib/createskeleton.c \ lib/getvservervdir.c lib_v11_SRCS = lib/syscall_rlimit.c \ lib/syscall_kill.c -lib_v13_SRCS = lib/syscall_getiattr.c \ +lib_v13_SRCS = lib/syscall_enternamespace.c \ + lib/syscall_enternamespace-v13.hc \ + lib/syscall_getiattr.c \ lib/syscall_setiattr.c \ lib/syscall_gettaskxid.c \ lib/syscall_getvxinfo.c diff --git a/util-vserver/lib/virtual.h b/util-vserver/lib/virtual.h index 3abd771..34a7cee 100644 --- a/util-vserver/lib/virtual.h +++ b/util-vserver/lib/virtual.h @@ -50,6 +50,7 @@ #define VC_CAT_VERSION 0 #define VC_CAT_VHOST 2 +#define VC_CAT_PROCALT 10 #define VC_CAT_PROCTRL 12 #define VC_CAT_SCHED 14 @@ -78,6 +79,8 @@ #define VCMD_new_s_context VC_CMD(COMPAT, 1, 1) #define VCMD_set_ipv4root VC_CMD(COMPAT, 2, 3) +#define VCMD_enter_namespace VC_CMD(PROCALT, 1, 0) + /* compatibiliy vserver arguments */ struct vcmd_new_s_context_v1 { diff --git a/util-vserver/lib/vserver.h b/util-vserver/lib/vserver.h index f3080c3..c6eb0f1 100644 --- a/util-vserver/lib/vserver.h +++ b/util-vserver/lib/vserver.h @@ -185,6 +185,9 @@ extern "C" { int vc_get_vhi_name(xid_t xid, vc_uts_type type, char *val, size_t len); + int vc_enter_namespace(xid_t xid); + + uint32_t vc_textlist2flag(char const *, size_t len, char const **err_ptr, size_t *err_len); uint32_t vc_text2flag(char const *, size_t len);