From 9d42bdf378cd83ffead8c6ae6a3cad69529ac015 Mon Sep 17 00:00:00 2001 From: Enrico Scholz Date: Wed, 14 Apr 2004 23:19:51 +0000 Subject: [PATCH] renamed files so that their names are corresponding the kernel API. Especially, *_context was renamed to ctx_*, and *flags* to *cflags*. git-svn-id: http://svn.linux-vserver.org/svn/util-vserver/trunk@1449 94cd875c-1c1d-0410-91d2-eb244daf1a30 --- util-vserver/lib/Makefile-files | 26 +++++++++++----------- .../lib/{flags-compat.c => cflags-compat.c} | 4 ++-- util-vserver/lib/{flags-v13.c => cflags-v13.c} | 4 ++-- .../{flags_list-compat.c => cflags_list-compat.c} | 4 ++-- .../lib/{flags_list-v13.c => cflags_list-v13.c} | 4 ++-- ...eatecontext-v13.hc => syscall_ctxcreate-v13.hc} | 4 ++-- ...syscall_createcontext.c => syscall_ctxcreate.c} | 6 ++--- ...atecontext-v13.hc => syscall_ctxmigrate-v13.hc} | 4 ++-- ...scall_migratecontext.c => syscall_ctxmigrate.c} | 6 ++--- ...ll_getflags-v13.hc => syscall_getcflags-v13.hc} | 4 ++-- .../{syscall_getflags.c => syscall_getcflags.c} | 6 ++--- ...ll_setflags-v13.hc => syscall_setcflags-v13.hc} | 4 ++-- .../{syscall_setflags.c => syscall_setcflags.c} | 6 ++--- 13 files changed, 41 insertions(+), 41 deletions(-) rename util-vserver/lib/{flags-compat.c => cflags-compat.c} (95%) rename util-vserver/lib/{flags-v13.c => cflags-v13.c} (96%) rename util-vserver/lib/{flags_list-compat.c => cflags_list-compat.c} (93%) rename util-vserver/lib/{flags_list-v13.c => cflags_list-v13.c} (93%) rename util-vserver/lib/{syscall_createcontext-v13.hc => syscall_ctxcreate-v13.hc} (89%) rename util-vserver/lib/{syscall_createcontext.c => syscall_ctxcreate.c} (89%) rename util-vserver/lib/{syscall_migratecontext-v13.hc => syscall_ctxmigrate-v13.hc} (89%) rename util-vserver/lib/{syscall_migratecontext.c => syscall_ctxmigrate.c} (88%) rename util-vserver/lib/{syscall_getflags-v13.hc => syscall_getcflags-v13.hc} (89%) rename util-vserver/lib/{syscall_getflags.c => syscall_getcflags.c} (87%) rename util-vserver/lib/{syscall_setflags-v13.hc => syscall_setcflags-v13.hc} (88%) rename util-vserver/lib/{syscall_setflags.c => syscall_setcflags.c} (87%) diff --git a/util-vserver/lib/Makefile-files b/util-vserver/lib/Makefile-files index 621856e..0f2bfcc 100644 --- a/util-vserver/lib/Makefile-files +++ b/util-vserver/lib/Makefile-files @@ -19,8 +19,8 @@ lib_VERSION = 0.0.0 -lib_compat_SRCS = lib/flags-compat.c \ - lib/flags_list-compat.c +lib_compat_SRCS = lib/cflags-compat.c \ + lib/cflags_list-compat.c lib_legacy_SRCS = lib/getprocentry-legacy.c lib_management_SRCS = lib/createskeleton.c \ lib/getvserverbyctx.c \ @@ -37,7 +37,11 @@ lib_v11_SRCS = lib/syscall_rlimit.c \ lib/syscall_rlimit-v11.hc \ lib/syscall_kill.c \ lib/syscall_kill-v11.hc -lib_v13_SRCS = lib/syscall_enternamespace.c \ +lib_v13_SRCS = lib/syscall_ctxmigrate.c \ + lib/syscall_ctxmigrate-v13.hc \ + lib/syscall_ctxcreate.c \ + lib/syscall_ctxcreate-v13.hc \ + lib/syscall_enternamespace.c \ lib/syscall_enternamespace-v13.hc \ lib/syscall_setnamespace.c \ lib/syscall_setnamespace-v13.hc \ @@ -61,26 +65,22 @@ lib_v13_SRCS = lib/syscall_enternamespace.c \ lib/syscall_setvhiname.c \ lib/syscall_setvhiname-v13.hc \ lib/syscall_setvhiname-olduts.hc \ - lib/syscall_createcontext.c \ - lib/syscall_createcontext-v13.hc \ - lib/syscall_migratecontext.c \ - lib/syscall_migratecontext-v13.hc \ lib/syscall_getccaps.c \ lib/syscall_getccaps-v13.hc \ - lib/syscall_getflags.c \ - lib/syscall_getflags-v13.hc \ + lib/syscall_getcflags.c \ + lib/syscall_getcflags-v13.hc \ lib/syscall_setccaps.c \ lib/syscall_setccaps-v13.hc \ - lib/syscall_setflags.c \ - lib/syscall_setflags-v13.hc \ + lib/syscall_setcflags.c \ + lib/syscall_setcflags-v13.hc \ lib/syscall_setsched.c \ lib/syscall_setsched-v13.hc \ lib/bcaps-v13.c \ lib/bcaps_list-v13.c \ lib/ccaps-v13.c \ lib/ccaps_list-v13.c \ - lib/flags-v13.c \ - lib/flags_list-v13.c + lib/cflags-v13.c \ + lib/cflags_list-v13.c PKGCONFIG_FILES = lib/util-vserver diff --git a/util-vserver/lib/flags-compat.c b/util-vserver/lib/cflags-compat.c similarity index 95% rename from util-vserver/lib/flags-compat.c rename to util-vserver/lib/cflags-compat.c index 784e950..efc11f4 100644 --- a/util-vserver/lib/flags-compat.c +++ b/util-vserver/lib/cflags-compat.c @@ -42,7 +42,7 @@ static struct { }; uint_least32_t -vc_text2flag_compat(char const *str, size_t len) +vc_text2cflag_compat(char const *str, size_t len) { size_t i; if (len==0) len=strlen(str); @@ -56,7 +56,7 @@ vc_text2flag_compat(char const *str, size_t len) } char const * -vc_hiflag2text_compat(uint_least32_t val) +vc_hicflag2text_compat(uint_least32_t val) { size_t i; size_t idx; diff --git a/util-vserver/lib/flags-v13.c b/util-vserver/lib/cflags-v13.c similarity index 96% rename from util-vserver/lib/flags-v13.c rename to util-vserver/lib/cflags-v13.c index 4b089b3..754e42b 100644 --- a/util-vserver/lib/flags-v13.c +++ b/util-vserver/lib/cflags-v13.c @@ -55,7 +55,7 @@ static struct Mapping_uint64 const VALUES[] = { }; uint_least64_t -vc_text2flag(char const *str, size_t len) +vc_text2cflag(char const *str, size_t len) { ssize_t idx = utilvserver_value2text_uint64(str, len, VALUES, DIM_OF(VALUES)); @@ -64,7 +64,7 @@ vc_text2flag(char const *str, size_t len) } char const * -vc_loflag2text(uint_least64_t *val) +vc_locflag2text(uint_least64_t *val) { ssize_t idx = utilvserver_text2value_uint64(val, VALUES, DIM_OF(VALUES)); diff --git a/util-vserver/lib/flags_list-compat.c b/util-vserver/lib/cflags_list-compat.c similarity index 93% rename from util-vserver/lib/flags_list-compat.c rename to util-vserver/lib/cflags_list-compat.c index e6255cc..692bacc 100644 --- a/util-vserver/lib/flags_list-compat.c +++ b/util-vserver/lib/cflags_list-compat.c @@ -24,7 +24,7 @@ #include uint_least32_t -vc_list2flag_compat(char const *str, size_t len, +vc_list2cflag_compat(char const *str, size_t len, struct vc_err_listparser *err) { uint32_t res = 0; @@ -39,7 +39,7 @@ vc_list2flag_compat(char const *str, size_t len, if (cnt>=len) { cnt=len; len=0; } else len-=(cnt+1); - tmp = vc_text2flag_compat(str,cnt); + tmp = vc_text2cflag_compat(str,cnt); if (tmp!=0) res |= tmp; else { diff --git a/util-vserver/lib/flags_list-v13.c b/util-vserver/lib/cflags_list-v13.c similarity index 93% rename from util-vserver/lib/flags_list-v13.c rename to util-vserver/lib/cflags_list-v13.c index f7f9502..ea14e64 100644 --- a/util-vserver/lib/flags_list-v13.c +++ b/util-vserver/lib/cflags_list-v13.c @@ -26,7 +26,7 @@ #include int -vc_list2flag(char const *str, size_t len, +vc_list2cflag(char const *str, size_t len, struct vc_err_listparser *err, struct vc_ctx_flags *flags) { @@ -34,5 +34,5 @@ vc_list2flag(char const *str, size_t len, err ? &err->ptr : 0, err ? &err->len : 0, &flags->flagword, &flags->mask, - vc_text2flag); + vc_text2cflag); } diff --git a/util-vserver/lib/syscall_createcontext-v13.hc b/util-vserver/lib/syscall_ctxcreate-v13.hc similarity index 89% rename from util-vserver/lib/syscall_createcontext-v13.hc rename to util-vserver/lib/syscall_ctxcreate-v13.hc index a4a634e..2899f2b 100644 --- a/util-vserver/lib/syscall_createcontext-v13.hc +++ b/util-vserver/lib/syscall_ctxcreate-v13.hc @@ -21,9 +21,9 @@ #endif static inline ALWAYSINLINE int -vc_create_context_v13(xid_t xid) +vc_ctx_create_v13(xid_t xid) { - xid_t res = vserver(VCMD_create_context, CTX_USER2KERNEL(xid), 0); + xid_t res = vserver(VCMD_ctx_create, CTX_USER2KERNEL(xid), 0); return CTX_KERNEL2USER(res); } diff --git a/util-vserver/lib/syscall_createcontext.c b/util-vserver/lib/syscall_ctxcreate.c similarity index 89% rename from util-vserver/lib/syscall_createcontext.c rename to util-vserver/lib/syscall_ctxcreate.c index 7a94017..b175a0b 100644 --- a/util-vserver/lib/syscall_createcontext.c +++ b/util-vserver/lib/syscall_ctxcreate.c @@ -25,13 +25,13 @@ #include "linuxvirtual.h" #if defined(VC_ENABLE_API_V13) -# include "syscall_createcontext-v13.hc" +# include "syscall_ctxcreate-v13.hc" #endif #if defined(VC_ENABLE_API_V13) xid_t -vc_create_context(xid_t xid) +vc_ctx_create(xid_t xid) { - CALL_VC(CALL_VC_V13A(vc_create_context, xid)); + CALL_VC(CALL_VC_V13A(vc_ctx_create, xid)); } #endif diff --git a/util-vserver/lib/syscall_migratecontext-v13.hc b/util-vserver/lib/syscall_ctxmigrate-v13.hc similarity index 89% rename from util-vserver/lib/syscall_migratecontext-v13.hc rename to util-vserver/lib/syscall_ctxmigrate-v13.hc index 9c42625..bc18a19 100644 --- a/util-vserver/lib/syscall_migratecontext-v13.hc +++ b/util-vserver/lib/syscall_ctxmigrate-v13.hc @@ -21,7 +21,7 @@ #endif static inline ALWAYSINLINE int -vc_migrate_context_v13(xid_t xid) +vc_ctx_migrate_v13(xid_t xid) { - return vserver(VCMD_migrate_context, CTX_USER2KERNEL(xid), 0); + return vserver(VCMD_ctx_migrate, CTX_USER2KERNEL(xid), 0); } diff --git a/util-vserver/lib/syscall_migratecontext.c b/util-vserver/lib/syscall_ctxmigrate.c similarity index 88% rename from util-vserver/lib/syscall_migratecontext.c rename to util-vserver/lib/syscall_ctxmigrate.c index 796298d..d98da5c 100644 --- a/util-vserver/lib/syscall_migratecontext.c +++ b/util-vserver/lib/syscall_ctxmigrate.c @@ -25,13 +25,13 @@ #include "linuxvirtual.h" #if defined(VC_ENABLE_API_V13) -# include "syscall_migratecontext-v13.hc" +# include "syscall_ctxmigrate-v13.hc" #endif #if defined(VC_ENABLE_API_V13) int -vc_migrate_context(xid_t xid) +vc_ctx_migrate(xid_t xid) { - CALL_VC(CALL_VC_V13A(vc_migrate_context, xid)); + CALL_VC(CALL_VC_V13A(vc_ctx_migrate, xid)); } #endif diff --git a/util-vserver/lib/syscall_getflags-v13.hc b/util-vserver/lib/syscall_getcflags-v13.hc similarity index 89% rename from util-vserver/lib/syscall_getflags-v13.hc rename to util-vserver/lib/syscall_getcflags-v13.hc index fc7a73a..18916a9 100644 --- a/util-vserver/lib/syscall_getflags-v13.hc +++ b/util-vserver/lib/syscall_getcflags-v13.hc @@ -21,7 +21,7 @@ #endif static inline ALWAYSINLINE int -vc_get_flags_v13(xid_t xid, struct vc_ctx_flags *flags) +vc_get_cflags_v13(xid_t xid, struct vc_ctx_flags *flags) { struct vcmd_ctx_flags_v0 k_flags; int res; @@ -31,7 +31,7 @@ vc_get_flags_v13(xid_t xid, struct vc_ctx_flags *flags) return -1; } - res = vserver(VCMD_get_flags, CTX_USER2KERNEL(xid), &k_flags); + res = vserver(VCMD_get_cflags, CTX_USER2KERNEL(xid), &k_flags); flags->flagword = k_flags.flagword; flags->mask = k_flags.mask; diff --git a/util-vserver/lib/syscall_getflags.c b/util-vserver/lib/syscall_getcflags.c similarity index 87% rename from util-vserver/lib/syscall_getflags.c rename to util-vserver/lib/syscall_getcflags.c index e52eb1a..5f447a5 100644 --- a/util-vserver/lib/syscall_getflags.c +++ b/util-vserver/lib/syscall_getcflags.c @@ -25,13 +25,13 @@ #include "linuxvirtual.h" #if defined(VC_ENABLE_API_V13) -# include "syscall_getflags-v13.hc" +# include "syscall_getcflags-v13.hc" #endif #if defined(VC_ENABLE_API_V13) int -vc_get_flags(xid_t xid, struct vc_ctx_flags *flags) +vc_get_cflags(xid_t xid, struct vc_ctx_flags *flags) { - CALL_VC(CALL_VC_V13A(vc_get_flags, xid, flags)); + CALL_VC(CALL_VC_V13A(vc_get_cflags, xid, flags)); } #endif diff --git a/util-vserver/lib/syscall_setflags-v13.hc b/util-vserver/lib/syscall_setcflags-v13.hc similarity index 88% rename from util-vserver/lib/syscall_setflags-v13.hc rename to util-vserver/lib/syscall_setcflags-v13.hc index a445bc2..1a79f7f 100644 --- a/util-vserver/lib/syscall_setflags-v13.hc +++ b/util-vserver/lib/syscall_setcflags-v13.hc @@ -21,7 +21,7 @@ #endif static inline ALWAYSINLINE int -vc_set_flags_v13(xid_t xid, struct vc_ctx_flags const *flags) +vc_set_cflags_v13(xid_t xid, struct vc_ctx_flags const *flags) { struct vcmd_ctx_flags_v0 k_flags; @@ -33,5 +33,5 @@ vc_set_flags_v13(xid_t xid, struct vc_ctx_flags const *flags) k_flags.flagword = flags->flagword; k_flags.mask = flags->mask; - return vserver(VCMD_set_flags, CTX_USER2KERNEL(xid), &k_flags); + return vserver(VCMD_set_cflags, CTX_USER2KERNEL(xid), &k_flags); } diff --git a/util-vserver/lib/syscall_setflags.c b/util-vserver/lib/syscall_setcflags.c similarity index 87% rename from util-vserver/lib/syscall_setflags.c rename to util-vserver/lib/syscall_setcflags.c index 37d8947..baafcae 100644 --- a/util-vserver/lib/syscall_setflags.c +++ b/util-vserver/lib/syscall_setcflags.c @@ -25,18 +25,18 @@ #include "linuxvirtual.h" #if defined(VC_ENABLE_API_V13) -# include "syscall_setflags-v13.hc" +# include "syscall_setcflags-v13.hc" #endif #if defined(VC_ENABLE_API_V13) int -vc_set_flags(xid_t xid, struct vc_ctx_flags const *flags) +vc_set_cflags(xid_t xid, struct vc_ctx_flags const *flags) { if (flags==0) { errno = EFAULT; return -1; } - CALL_VC(CALL_VC_V13A(vc_set_flags, xid, flags)); + CALL_VC(CALL_VC_V13A(vc_set_cflags, xid, flags)); } #endif -- 1.8.1.5