diff -u linux-3.9.4-vs2.3.6.4/drivers/md/dm.c linux-3.9.4-vs2.3.6.4/drivers/md/dm.c --- linux-3.9.4-vs2.3.6.4/drivers/md/dm.c 2013-05-31 14:47:11.000000000 +0000 +++ linux-3.9.4-vs2.3.6.4/drivers/md/dm.c 2013-05-31 14:47:11.000000000 +0000 @@ -126,7 +126,7 @@ rwlock_t map_lock; atomic_t holders; atomic_t open_count; - xid_t xid; + vxid_t xid; unsigned long flags; @@ -554,7 +554,7 @@ /* * Get the xid associated with a dm device */ -xid_t dm_get_xid(struct mapped_device *md) +vxid_t dm_get_xid(struct mapped_device *md) { return md->xid; } diff -u linux-3.9.4-vs2.3.6.4/drivers/md/dm.h linux-3.9.4-vs2.3.6.4/drivers/md/dm.h --- linux-3.9.4-vs2.3.6.4/drivers/md/dm.h 2013-05-31 14:47:11.000000000 +0000 +++ linux-3.9.4-vs2.3.6.4/drivers/md/dm.h 2013-05-31 14:47:11.000000000 +0000 @@ -46,7 +46,7 @@ struct dm_table; struct dm_md_mempools; -xid_t dm_get_xid(struct mapped_device *md); +vxid_t dm_get_xid(struct mapped_device *md); /*----------------------------------------------------------------- * Internal table functions. diff -u linux-3.9.4-vs2.3.6.4/drivers/net/tun.c linux-3.9.4-vs2.3.6.4/drivers/net/tun.c --- linux-3.9.4-vs2.3.6.4/drivers/net/tun.c 2013-05-31 20:01:45.000000000 +0000 +++ linux-3.9.4-vs2.3.6.4/drivers/net/tun.c 2013-05-31 20:01:45.000000000 +0000 @@ -165,7 +165,7 @@ unsigned int flags; kuid_t owner; kgid_t group; - nid_t nid; + vnid_t nid; struct net_device *dev; netdev_features_t set_features; @@ -1962,7 +1962,7 @@ return -EPERM; /* Set nid owner of the device */ - tun->nid = (nid_t) arg; + tun->nid = (vnid_t) arg; tun_debug(KERN_INFO, tun, "nid owner set to %u\n", tun->nid); break; reverted: --- linux-3.9.4-vs2.3.6.4/drivers/staging/csr/csr_wifi_hip_xbv.c 2013-05-31 14:47:11.000000000 +0000 +++ linux-3.9.4/drivers/staging/csr/csr_wifi_hip_xbv.c 2013-02-19 13:58:32.000000000 +0000 @@ -55,7 +55,7 @@ { char t_name[4]; u32 t_len; +} tag_t; -} ctag_t; #define TAG_EQ(i, v) (((i)[0] == (v)[0]) && \ @@ -90,7 +90,7 @@ u32 ptr; } xbv_stack_t; +static s32 read_tag(card_t *card, ct_t *ct, tag_t *tag); -static s32 read_tag(card_t *card, ct_t *ct, ctag_t *tag); static s32 read_bytes(card_t *card, ct_t *ct, void *buf, u32 len); static s32 read_uint(card_t *card, ct_t *ct, u32 *u, u32 len); static s32 xbv_check(xbv1_t *fwinfo, const xbv_stack_t *stack, @@ -160,7 +160,7 @@ CsrResult xbv1_parse(card_t *card, fwreadfn_t readfn, void *dlpriv, xbv1_t *fwinfo) { ct_t ct; + tag_t tag; - ctag_t tag; xbv_stack_t stack; ct.dlpriv = dlpriv; @@ -505,7 +505,7 @@ } +static s32 read_tag(card_t *card, ct_t *ct, tag_t *tag) -static s32 read_tag(card_t *card, ct_t *ct, ctag_t *tag) { u8 buf[8]; s32 n; diff -u linux-3.9.4-vs2.3.6.4/fs/devpts/inode.c linux-3.9.4-vs2.3.6.4/fs/devpts/inode.c --- linux-3.9.4-vs2.3.6.4/fs/devpts/inode.c 2013-05-31 15:42:25.000000000 +0000 +++ linux-3.9.4-vs2.3.6.4/fs/devpts/inode.c 2013-05-31 15:42:25.000000000 +0000 @@ -42,7 +42,7 @@ int ret = -EACCES; /* devpts is xid tagged */ - if (vx_check((xid_t)i_tag_read(inode), VS_WATCH_P | VS_IDENT)) + if (vx_check((vxid_t)i_tag_read(inode), VS_WATCH_P | VS_IDENT)) ret = generic_permission(inode, mask); return ret; } @@ -363,11 +363,11 @@ static int devpts_filter(struct dentry *de) { - xid_t xid = 0; + vxid_t xid = 0; /* devpts is xid tagged */ if (de && de->d_inode) - xid = (xid_t)i_tag_read(de->d_inode); + xid = (vxid_t)i_tag_read(de->d_inode); #ifdef CONFIG_VSERVER_WARN_DEVPTS else vxwprintk_task(1, "devpts " VS_Q("%.*s") " without inode.", @@ -435,7 +435,7 @@ inode->i_fop = &devpts_dir_operations; set_nlink(inode, 2); /* devpts is xid tagged */ - i_tag_write(inode, (tag_t)vx_current_xid()); + i_tag_write(inode, (vtag_t)vx_current_xid()); s->s_root = d_make_root(inode); if (s->s_root) @@ -639,7 +639,7 @@ inode->i_mtime = inode->i_atime = inode->i_ctime = CURRENT_TIME; init_special_inode(inode, S_IFCHR|opts->mode, device); /* devpts is xid tagged */ - i_tag_write(inode, (tag_t)vx_current_xid()); + i_tag_write(inode, (vtag_t)vx_current_xid()); inode->i_op = &devpts_file_inode_operations; inode->i_private = priv; diff -u linux-3.9.4-vs2.3.6.4/fs/hostfs/hostfs.h linux-3.9.4-vs2.3.6.4/fs/hostfs/hostfs.h --- linux-3.9.4-vs2.3.6.4/fs/hostfs/hostfs.h 2013-05-31 14:47:11.000000000 +0000 +++ linux-3.9.4-vs2.3.6.4/fs/hostfs/hostfs.h 2013-05-31 14:47:11.000000000 +0000 @@ -42,7 +42,7 @@ unsigned short ia_mode; uid_t ia_uid; gid_t ia_gid; - tag_t ia_tag; + vtag_t ia_tag; loff_t ia_size; struct timespec ia_atime; struct timespec ia_mtime; diff -u linux-3.9.4-vs2.3.6.4/fs/locks.c linux-3.9.4-vs2.3.6.4/fs/locks.c --- linux-3.9.4-vs2.3.6.4/fs/locks.c 2013-05-31 15:53:57.000000000 +0000 +++ linux-3.9.4-vs2.3.6.4/fs/locks.c 2013-05-31 15:53:57.000000000 +0000 @@ -808,7 +808,7 @@ } static int __posix_lock_file(struct inode *inode, struct file_lock *request, - struct file_lock *conflock, xid_t xid) + struct file_lock *conflock, vxid_t xid) { struct file_lock *fl; struct file_lock *new_fl = NULL; diff -u linux-3.9.4-vs2.3.6.4/fs/mount.h linux-3.9.4-vs2.3.6.4/fs/mount.h --- linux-3.9.4-vs2.3.6.4/fs/mount.h 2013-05-31 14:47:11.000000000 +0000 +++ linux-3.9.4-vs2.3.6.4/fs/mount.h 2013-05-31 14:47:11.000000000 +0000 @@ -49,7 +49,7 @@ int mnt_expiry_mark; /* true if marked for expiry */ int mnt_pinned; int mnt_ghosts; - tag_t mnt_tag; /* tagging used for vfsmount */ + vtag_t mnt_tag; /* tagging used for vfsmount */ }; #define MNT_NS_INTERNAL ERR_PTR(-EINVAL) /* distinct from any mnt_namespace */ diff -u linux-3.9.4-vs2.3.6.4/fs/namei.c linux-3.9.4-vs2.3.6.4/fs/namei.c --- linux-3.9.4-vs2.3.6.4/fs/namei.c 2013-06-01 09:00:16.000000000 +0000 +++ linux-3.9.4-vs2.3.6.4/fs/namei.c 2013-06-01 09:00:16.000000000 +0000 @@ -291,7 +291,7 @@ if (inode->i_sb->s_magic == DEVPTS_SUPER_MAGIC) { /* devpts is xid tagged */ if (S_ISDIR(inode->i_mode) || - vx_check((xid_t)i_tag_read(inode), VS_IDENT | VS_WATCH_P)) + vx_check((vxid_t)i_tag_read(inode), VS_IDENT | VS_WATCH_P)) return 0; /* just pretend we didn't find anything */ @@ -333,7 +333,7 @@ } else { if (dx_notagcheck(inode->i_sb) || - dx_check((xid_t)i_tag_read(inode), + dx_check((vxid_t)i_tag_read(inode), DX_HOSTID | DX_ADMIN | DX_WATCH | DX_IDENT)) return 0; } diff -u linux-3.9.4-vs2.3.6.4/fs/namespace.c linux-3.9.4-vs2.3.6.4/fs/namespace.c --- linux-3.9.4-vs2.3.6.4/fs/namespace.c 2013-05-31 18:47:18.000000000 +0000 +++ linux-3.9.4-vs2.3.6.4/fs/namespace.c 2013-05-31 18:47:18.000000000 +0000 @@ -1665,7 +1665,7 @@ * do loopback mount. */ static int do_loopback(struct path *path, const char *old_name, - tag_t tag, unsigned long flags, int mnt_flags) + vtag_t tag, unsigned long flags, int mnt_flags) { LIST_HEAD(umount_list); struct path old_path; @@ -1746,7 +1746,7 @@ * on it - tough luck. */ static int do_remount(struct path *path, int flags, int mnt_flags, - void *data, xid_t xid) + void *data, vxid_t xid) { int err; struct super_block *sb = path->mnt->mnt_sb; @@ -2230,7 +2230,7 @@ struct path path; int retval = 0; int mnt_flags = 0; - tag_t tag = 0; + vtag_t tag = 0; /* Discard magic */ if ((flags & MS_MGC_MSK) == MS_MGC_VAL) diff -u linux-3.9.4-vs2.3.6.4/fs/nfsd/auth.c linux-3.9.4-vs2.3.6.4/fs/nfsd/auth.c --- linux-3.9.4-vs2.3.6.4/fs/nfsd/auth.c 2013-05-31 14:47:11.000000000 +0000 +++ linux-3.9.4-vs2.3.6.4/fs/nfsd/auth.c 2013-05-31 14:47:11.000000000 +0000 @@ -39,7 +39,7 @@ new->fsuid = rqstp->rq_cred.cr_uid; new->fsgid = rqstp->rq_cred.cr_gid; /* FIXME: this desperately needs a tag :) - new->xid = (xid_t)INOTAG_TAG(DX_TAG_NFSD, cred.cr_uid, cred.cr_gid, 0); + new->xid = (vxid_t)INOTAG_TAG(DX_TAG_NFSD, cred.cr_uid, cred.cr_gid, 0); */ rqgi = rqstp->rq_cred.cr_group_info; diff -u linux-3.9.4-vs2.3.6.4/fs/proc/base.c linux-3.9.4-vs2.3.6.4/fs/proc/base.c --- linux-3.9.4-vs2.3.6.4/fs/proc/base.c 2013-05-31 14:47:11.000000000 +0000 +++ linux-3.9.4-vs2.3.6.4/fs/proc/base.c 2013-05-31 14:47:11.000000000 +0000 @@ -1535,7 +1535,7 @@ rcu_read_unlock(); } /* procfs is xid tagged */ - i_tag_write(inode, (tag_t)vx_task_xid(task)); + i_tag_write(inode, (vtag_t)vx_task_xid(task)); security_task_to_inode(task, inode); out: diff -u linux-3.9.4-vs2.3.6.4/include/linux/fs.h linux-3.9.4-vs2.3.6.4/include/linux/fs.h --- linux-3.9.4-vs2.3.6.4/include/linux/fs.h 2013-05-31 14:47:11.000000000 +0000 +++ linux-3.9.4-vs2.3.6.4/include/linux/fs.h 2013-05-31 14:47:11.000000000 +0000 @@ -707,7 +707,7 @@ return from_kgid(&init_user_ns, inode->i_gid); } -static inline tag_t i_tag_read(const struct inode *inode) +static inline vtag_t i_tag_read(const struct inode *inode) { return from_ktag(&init_user_ns, inode->i_tag); } @@ -722,7 +722,7 @@ inode->i_gid = make_kgid(&init_user_ns, gid); } -static inline void i_tag_write(struct inode *inode, tag_t tag) +static inline void i_tag_write(struct inode *inode, vtag_t tag) { inode->i_tag = make_ktag(&init_user_ns, tag); } @@ -801,7 +801,7 @@ loff_t f_pos; struct fown_struct f_owner; const struct cred *f_cred; - xid_t f_xid; + vxid_t f_xid; struct file_ra_state f_ra; u64 f_version; @@ -953,7 +953,7 @@ struct file *fl_file; loff_t fl_start; loff_t fl_end; - xid_t fl_xid; + vxid_t fl_xid; struct fasync_struct * fl_fasync; /* for lease break notifications */ /* for lease breaks: */ diff -u linux-3.9.4-vs2.3.6.4/include/linux/ipc.h linux-3.9.4-vs2.3.6.4/include/linux/ipc.h --- linux-3.9.4-vs2.3.6.4/include/linux/ipc.h 2013-05-31 14:47:11.000000000 +0000 +++ linux-3.9.4-vs2.3.6.4/include/linux/ipc.h 2013-05-31 14:47:11.000000000 +0000 @@ -16,7 +16,7 @@ key_t key; kuid_t uid; kgid_t gid; - xid_t xid; + vxid_t xid; kuid_t cuid; kgid_t cgid; umode_t mode; diff -u linux-3.9.4-vs2.3.6.4/include/linux/loop.h linux-3.9.4-vs2.3.6.4/include/linux/loop.h --- linux-3.9.4-vs2.3.6.4/include/linux/loop.h 2013-05-31 14:47:11.000000000 +0000 +++ linux-3.9.4-vs2.3.6.4/include/linux/loop.h 2013-05-31 14:47:11.000000000 +0000 @@ -41,7 +41,7 @@ struct loop_func_table *lo_encryption; __u32 lo_init[2]; kuid_t lo_key_owner; /* Who set the key */ - xid_t lo_xid; + vxid_t lo_xid; int (*ioctl)(struct loop_device *, int cmd, unsigned long arg); diff -u linux-3.9.4-vs2.3.6.4/include/linux/sched.h linux-3.9.4-vs2.3.6.4/include/linux/sched.h --- linux-3.9.4-vs2.3.6.4/include/linux/sched.h 2013-06-03 17:32:54.000000000 +0000 +++ linux-3.9.4-vs2.3.6.4/include/linux/sched.h 2013-06-03 17:32:54.000000000 +0000 @@ -1402,9 +1402,9 @@ struct vx_info *vx_info; struct nx_info *nx_info; - xid_t xid; - nid_t nid; - tag_t tag; + vxid_t xid; + vnid_t nid; + vtag_t tag; /* Thread group tracking */ u32 parent_exec_id; diff -u linux-3.9.4-vs2.3.6.4/include/linux/types.h linux-3.9.4-vs2.3.6.4/include/linux/types.h --- linux-3.9.4-vs2.3.6.4/include/linux/types.h 2013-05-31 14:47:11.000000000 +0000 +++ linux-3.9.4-vs2.3.6.4/include/linux/types.h 2013-05-31 14:47:11.000000000 +0000 @@ -32,9 +32,9 @@ typedef __kernel_gid32_t gid_t; typedef __kernel_uid16_t uid16_t; typedef __kernel_gid16_t gid16_t; -typedef unsigned int xid_t; -typedef unsigned int nid_t; -typedef unsigned int tag_t; +typedef unsigned int vxid_t; +typedef unsigned int vnid_t; +typedef unsigned int vtag_t; typedef unsigned long uintptr_t; diff -u linux-3.9.4-vs2.3.6.4/include/linux/uidgid.h linux-3.9.4-vs2.3.6.4/include/linux/uidgid.h --- linux-3.9.4-vs2.3.6.4/include/linux/uidgid.h 2013-05-31 14:47:11.000000000 +0000 +++ linux-3.9.4-vs2.3.6.4/include/linux/uidgid.h 2013-05-31 14:47:11.000000000 +0000 @@ -28,7 +28,7 @@ } kgid_t; typedef struct { - tag_t val; + vtag_t val; } ktag_t; #define KUIDT_INIT(value) (kuid_t){ value } @@ -45,7 +45,7 @@ return gid.val; } -static inline tag_t __ktag_val(ktag_t tag) +static inline vtag_t __ktag_val(ktag_t tag) { return tag.val; } @@ -54,7 +54,7 @@ typedef uid_t kuid_t; typedef gid_t kgid_t; -typedef tag_t ktag_t; +typedef vtag_t ktag_t; static inline uid_t __kuid_val(kuid_t uid) { @@ -66,7 +66,7 @@ return gid; } -static inline tag_t __ktag_val(ktag_t tag) +static inline vtag_t __ktag_val(ktag_t tag) { return tag; } @@ -163,7 +163,7 @@ extern uid_t from_kuid(struct user_namespace *to, kuid_t uid); extern gid_t from_kgid(struct user_namespace *to, kgid_t gid); -extern tag_t from_ktag(struct user_namespace *to, ktag_t tag); +extern vtag_t from_ktag(struct user_namespace *to, ktag_t tag); extern uid_t from_kuid_munged(struct user_namespace *to, kuid_t uid); extern gid_t from_kgid_munged(struct user_namespace *to, kgid_t gid); @@ -190,7 +190,7 @@ return KGIDT_INIT(gid); } -static inline ktag_t make_ktag(struct user_namespace *from, tag_t tag) +static inline ktag_t make_ktag(struct user_namespace *from, vtag_t tag) { return KTAGT_INIT(tag); } @@ -205,7 +205,7 @@ return __kgid_val(kgid); } -static inline tag_t from_ktag(struct user_namespace *to, ktag_t ktag) +static inline vtag_t from_ktag(struct user_namespace *to, ktag_t ktag) { return __ktag_val(ktag); } diff -u linux-3.9.4-vs2.3.6.4/include/linux/vs_context.h linux-3.9.4-vs2.3.6.4/include/linux/vs_context.h --- linux-3.9.4-vs2.3.6.4/include/linux/vs_context.h 2013-05-31 14:47:11.000000000 +0000 +++ linux-3.9.4-vs2.3.6.4/include/linux/vs_context.h 2013-05-31 14:47:11.000000000 +0000 @@ -209,7 +209,7 @@ static inline void __enter_vx_admin(struct vx_info_save *vxis) { vxis->vxi = xchg(¤t->vx_info, NULL); - vxis->xid = xchg(¤t->xid, (xid_t)0); + vxis->xid = xchg(¤t->xid, (vxid_t)0); } static inline void __leave_vx_admin(struct vx_info_save *vxis) diff -u linux-3.9.4-vs2.3.6.4/include/linux/vs_dlimit.h linux-3.9.4-vs2.3.6.4/include/linux/vs_dlimit.h --- linux-3.9.4-vs2.3.6.4/include/linux/vs_dlimit.h 2013-05-31 14:47:11.000000000 +0000 +++ linux-3.9.4-vs2.3.6.4/include/linux/vs_dlimit.h 2013-05-31 14:47:11.000000000 +0000 @@ -46,7 +46,7 @@ #define __dlimit_char(d) ((d) ? '*' : ' ') static inline int __dl_alloc_space(struct super_block *sb, - tag_t tag, dlsize_t nr, const char *file, int line) + vtag_t tag, dlsize_t nr, const char *file, int line) { struct dl_info *dli = NULL; int ret = 0; @@ -72,7 +72,7 @@ } static inline void __dl_free_space(struct super_block *sb, - tag_t tag, dlsize_t nr, const char *_file, int _line) + vtag_t tag, dlsize_t nr, const char *_file, int _line) { struct dl_info *dli = NULL; @@ -97,7 +97,7 @@ } static inline int __dl_alloc_inode(struct super_block *sb, - tag_t tag, const char *_file, int _line) + vtag_t tag, const char *_file, int _line) { struct dl_info *dli; int ret = 0; @@ -119,7 +119,7 @@ } static inline void __dl_free_inode(struct super_block *sb, - tag_t tag, const char *_file, int _line) + vtag_t tag, const char *_file, int _line) { struct dl_info *dli; @@ -140,7 +140,7 @@ sb, tag, __dlimit_char(dli), _file, _line); } -static inline void __dl_adjust_block(struct super_block *sb, tag_t tag, +static inline void __dl_adjust_block(struct super_block *sb, vtag_t tag, unsigned long long *free_blocks, unsigned long long *root_blocks, const char *_file, int _line) { diff -u linux-3.9.4-vs2.3.6.4/include/linux/vs_tag.h linux-3.9.4-vs2.3.6.4/include/linux/vs_tag.h --- linux-3.9.4-vs2.3.6.4/include/linux/vs_tag.h 2013-05-31 14:47:11.000000000 +0000 +++ linux-3.9.4-vs2.3.6.4/include/linux/vs_tag.h 2013-05-31 14:47:11.000000000 +0000 @@ -27,7 +27,7 @@ * check current context for ADMIN/WATCH and * optionally against supplied argument */ -static inline int __dx_check(tag_t cid, tag_t id, unsigned int mode) +static inline int __dx_check(vtag_t cid, vtag_t id, unsigned int mode) { if (mode & DX_ARG_MASK) { if ((mode & DX_IDENT) && (id == cid)) diff -u linux-3.9.4-vs2.3.6.4/include/linux/vserver/context.h linux-3.9.4-vs2.3.6.4/include/linux/vserver/context.h --- linux-3.9.4-vs2.3.6.4/include/linux/vserver/context.h 2013-05-31 14:47:11.000000000 +0000 +++ linux-3.9.4-vs2.3.6.4/include/linux/vserver/context.h 2013-05-31 14:47:11.000000000 +0000 @@ -29,7 +29,7 @@ struct vx_info { struct hlist_node vx_hlist; /* linked list of contexts */ - xid_t vx_id; /* context id */ + vxid_t vx_id; /* context id */ atomic_t vx_usecnt; /* usage count */ atomic_t vx_tasks; /* tasks count */ struct vx_info *vx_parent; /* parent context */ @@ -80,7 +80,7 @@ struct vx_info_save { struct vx_info *vxi; - xid_t xid; + vxid_t xid; }; @@ -100,7 +100,7 @@ extern struct vx_info *lookup_or_create_vx_info(int); extern int get_xid_list(int, unsigned int *, int); -extern int xid_is_hashed(xid_t); +extern int xid_is_hashed(vxid_t); extern int vx_migrate_task(struct task_struct *, struct vx_info *, int); diff -u linux-3.9.4-vs2.3.6.4/include/linux/vserver/dlimit.h linux-3.9.4-vs2.3.6.4/include/linux/vserver/dlimit.h --- linux-3.9.4-vs2.3.6.4/include/linux/vserver/dlimit.h 2013-05-31 14:47:11.000000000 +0000 +++ linux-3.9.4-vs2.3.6.4/include/linux/vserver/dlimit.h 2013-05-31 14:47:11.000000000 +0000 @@ -18,7 +18,7 @@ struct dl_info { struct hlist_node dl_hlist; /* linked list of contexts */ struct rcu_head dl_rcu; /* the rcu head */ - tag_t dl_tag; /* context tag */ + vtag_t dl_tag; /* context tag */ atomic_t dl_usecnt; /* usage count */ atomic_t dl_refcnt; /* reference count */ @@ -39,7 +39,7 @@ extern void rcu_free_dl_info(struct rcu_head *); extern void unhash_dl_info(struct dl_info *); -extern struct dl_info *locate_dl_info(struct super_block *, tag_t); +extern struct dl_info *locate_dl_info(struct super_block *, vtag_t); struct kstatfs; diff -u linux-3.9.4-vs2.3.6.4/include/linux/vserver/network.h linux-3.9.4-vs2.3.6.4/include/linux/vserver/network.h --- linux-3.9.4-vs2.3.6.4/include/linux/vserver/network.h 2013-05-31 14:47:11.000000000 +0000 +++ linux-3.9.4-vs2.3.6.4/include/linux/vserver/network.h 2013-05-31 14:47:11.000000000 +0000 @@ -29,7 +29,7 @@ struct nx_info { struct hlist_node nx_hlist; /* linked list of nxinfos */ - nid_t nx_id; /* vnet id */ + vnid_t nx_id; /* vnet id */ atomic_t nx_usecnt; /* usage count */ atomic_t nx_tasks; /* tasks count */ int nx_state; /* context state */ @@ -57,7 +57,7 @@ extern struct nx_info *lookup_nx_info(int); extern int get_nid_list(int, unsigned int *, int); -extern int nid_is_hashed(nid_t); +extern int nid_is_hashed(vnid_t); extern int nx_migrate_task(struct task_struct *, struct nx_info *); diff -u linux-3.9.4-vs2.3.6.4/include/linux/vserver/tag.h linux-3.9.4-vs2.3.6.4/include/linux/vserver/tag.h --- linux-3.9.4-vs2.3.6.4/include/linux/vserver/tag.h 2013-06-03 20:23:02.000000000 +0000 +++ linux-3.9.4-vs2.3.6.4/include/linux/vserver/tag.h 2013-06-03 20:23:02.000000000 +0000 @@ -144,7 +144,7 @@ #define dx_notagcheck(sb) ((sb) && ((sb)->s_flags & MS_NOTAGCHECK)) -int dx_parse_tag(char *string, tag_t *tag, int remove, int *mnt_flags, +int dx_parse_tag(char *string, vtag_t *tag, int remove, int *mnt_flags, unsigned long *flags); #ifdef CONFIG_PROPAGATE diff -u linux-3.9.4-vs2.3.6.4/include/net/sock.h linux-3.9.4-vs2.3.6.4/include/net/sock.h --- linux-3.9.4-vs2.3.6.4/include/net/sock.h 2013-05-31 17:17:53.000000000 +0000 +++ linux-3.9.4-vs2.3.6.4/include/net/sock.h 2013-05-31 17:17:53.000000000 +0000 @@ -191,9 +191,9 @@ #ifdef CONFIG_NET_NS struct net *skc_net; #endif - xid_t skc_xid; + vxid_t skc_xid; struct vx_info *skc_vx_info; - nid_t skc_nid; + vnid_t skc_nid; struct nx_info *skc_nx_info; /* * fields between dontcopy_begin/dontcopy_end diff -u linux-3.9.4-vs2.3.6.4/kernel/vserver/context.c linux-3.9.4-vs2.3.6.4/kernel/vserver/context.c --- linux-3.9.4-vs2.3.6.4/kernel/vserver/context.c 2013-05-31 19:34:32.000000000 +0000 +++ linux-3.9.4-vs2.3.6.4/kernel/vserver/context.c 2013-05-31 19:34:32.000000000 +0000 @@ -70,7 +70,7 @@ * allocate an initialized vx_info struct * doesn't make it visible (hash) */ -static struct vx_info *__alloc_vx_info(xid_t xid) +static struct vx_info *__alloc_vx_info(vxid_t xid) { struct vx_info *new = NULL; int cpu, index; @@ -269,7 +269,7 @@ static DEFINE_SPINLOCK(vx_info_hash_lock); -static inline unsigned int __hashval(xid_t xid) +static inline unsigned int __hashval(vxid_t xid) { return (xid % VX_HASH_SIZE); } @@ -333,7 +333,7 @@ * requires the hash_lock to be held * doesn't increment the vx_refcnt */ -static inline struct vx_info *__lookup_vx_info(xid_t xid) +static inline struct vx_info *__lookup_vx_info(vxid_t xid) { struct hlist_head *head = &vx_info_hash[__hashval(xid)]; struct hlist_node *pos; @@ -435,7 +435,7 @@ * verify that xid is still hashed */ -int xid_is_hashed(xid_t xid) +int xid_is_hashed(vxid_t xid) { int hashed; @@ -790,7 +790,7 @@ int vc_task_xid(uint32_t id) { - xid_t xid; + vxid_t xid; if (id) { struct task_struct *tsk; diff -u linux-3.9.4-vs2.3.6.4/kernel/vserver/device.c linux-3.9.4-vs2.3.6.4/kernel/vserver/device.c --- linux-3.9.4-vs2.3.6.4/kernel/vserver/device.c 2013-05-31 14:47:11.000000000 +0000 +++ linux-3.9.4-vs2.3.6.4/kernel/vserver/device.c 2013-05-31 14:47:11.000000000 +0000 @@ -36,7 +36,7 @@ } u; #define dm_hlist u.hlist #define dm_list u.list - xid_t xid; + vxid_t xid; dev_t device; struct vx_dmap_target target; }; @@ -148,7 +148,7 @@ * * caller must hold hash_lock */ -static inline int __find_mapping(xid_t xid, dev_t device, umode_t mode, +static inline int __find_mapping(vxid_t xid, dev_t device, umode_t mode, struct vs_mapping **local, struct vs_mapping **global) { struct hlist_head *hash = dmap_main_hash; @@ -190,7 +190,7 @@ struct vs_mapping *vdm, *global; struct vx_dmap_target *vdmt; int ret = 0; - xid_t xid = vxi->vx_id; + vxid_t xid = vxi->vx_id; int index; spin_lock(hash_lock); diff -u linux-3.9.4-vs2.3.6.4/kernel/vserver/dlimit.c linux-3.9.4-vs2.3.6.4/kernel/vserver/dlimit.c --- linux-3.9.4-vs2.3.6.4/kernel/vserver/dlimit.c 2013-05-31 19:37:39.000000000 +0000 +++ linux-3.9.4-vs2.3.6.4/kernel/vserver/dlimit.c 2013-05-31 19:37:39.000000000 +0000 @@ -27,7 +27,7 @@ * allocate an initialized dl_info struct * doesn't make it visible (hash) */ -static struct dl_info *__alloc_dl_info(struct super_block *sb, tag_t tag) +static struct dl_info *__alloc_dl_info(struct super_block *sb, vtag_t tag) { struct dl_info *new = NULL; @@ -84,7 +84,7 @@ static DEFINE_SPINLOCK(dl_info_hash_lock); -static inline unsigned int __hashval(struct super_block *sb, tag_t tag) +static inline unsigned int __hashval(struct super_block *sb, vtag_t tag) { return ((tag ^ (unsigned long)sb) % DL_HASH_SIZE); } @@ -126,7 +126,7 @@ * requires the rcu_read_lock() * doesn't increment the dl_refcnt */ -static inline struct dl_info *__lookup_dl_info(struct super_block *sb, tag_t tag) +static inline struct dl_info *__lookup_dl_info(struct super_block *sb, vtag_t tag) { struct hlist_head *head = &dl_info_hash[__hashval(sb, tag)]; struct dl_info *dli; @@ -139,7 +139,7 @@ } -struct dl_info *locate_dl_info(struct super_block *sb, tag_t tag) +struct dl_info *locate_dl_info(struct super_block *sb, vtag_t tag) { struct dl_info *dli; diff -u linux-3.9.4-vs2.3.6.4/kernel/vserver/inode.c linux-3.9.4-vs2.3.6.4/kernel/vserver/inode.c --- linux-3.9.4-vs2.3.6.4/kernel/vserver/inode.c 2013-06-01 08:26:06.000000000 +0000 +++ linux-3.9.4-vs2.3.6.4/kernel/vserver/inode.c 2013-06-01 08:26:06.000000000 +0000 @@ -339,7 +339,7 @@ } } -int dx_parse_tag(char *string, tag_t *tag, int remove, int *mnt_flags, +int dx_parse_tag(char *string, vtag_t *tag, int remove, int *mnt_flags, unsigned long *flags) { int set = 0; @@ -406,7 +406,7 @@ void __dx_propagate_tag(struct nameidata *nd, struct inode *inode) { - tag_t new_tag = 0; + vtag_t new_tag = 0; struct vfsmount *mnt; int propagate; diff -u linux-3.9.4-vs2.3.6.4/kernel/vserver/network.c linux-3.9.4-vs2.3.6.4/kernel/vserver/network.c --- linux-3.9.4-vs2.3.6.4/kernel/vserver/network.c 2013-05-31 14:47:11.000000000 +0000 +++ linux-3.9.4-vs2.3.6.4/kernel/vserver/network.c 2013-05-31 14:47:11.000000000 +0000 @@ -116,7 +116,7 @@ * allocate an initialized nx_info struct * doesn't make it visible (hash) */ -static struct nx_info *__alloc_nx_info(nid_t nid) +static struct nx_info *__alloc_nx_info(vnid_t nid) { struct nx_info *new = NULL; @@ -217,7 +217,7 @@ static DEFINE_SPINLOCK(nx_info_hash_lock); -static inline unsigned int __hashval(nid_t nid) +static inline unsigned int __hashval(vnid_t nid) { return (nid % NX_HASH_SIZE); } @@ -274,7 +274,7 @@ * requires the hash_lock to be held * doesn't increment the nx_refcnt */ -static inline struct nx_info *__lookup_nx_info(nid_t nid) +static inline struct nx_info *__lookup_nx_info(vnid_t nid) { struct hlist_head *head = &nx_info_hash[__hashval(nid)]; struct hlist_node *pos; @@ -374,7 +374,7 @@ * verify that nid is still hashed */ -int nid_is_hashed(nid_t nid) +int nid_is_hashed(vnid_t nid) { int hashed; @@ -518,7 +518,7 @@ int vc_task_nid(uint32_t id) { - nid_t nid; + vnid_t nid; if (id) { struct task_struct *tsk; diff -u linux-3.9.4-vs2.3.6.4/kernel/vserver/proc.c linux-3.9.4-vs2.3.6.4/kernel/vserver/proc.c --- linux-3.9.4-vs2.3.6.4/kernel/vserver/proc.c 2013-06-01 08:30:38.000000000 +0000 +++ linux-3.9.4-vs2.3.6.4/kernel/vserver/proc.c 2013-06-01 08:30:38.000000000 +0000 @@ -383,7 +383,7 @@ static int proc_xid_revalidate(struct dentry *dentry, unsigned int flags) { struct inode *inode = dentry->d_inode; - xid_t xid = PROC_I(inode)->fd; + vxid_t xid = PROC_I(inode)->fd; if (flags & LOOKUP_RCU) /* FIXME: can be dropped? */ return -ECHILD; @@ -400,7 +400,7 @@ static int proc_nid_revalidate(struct dentry *dentry, unsigned int flags) { struct inode *inode = dentry->d_inode; - nid_t nid = PROC_I(inode)->fd; + vnid_t nid = PROC_I(inode)->fd; if (flags & LOOKUP_RCU) /* FIXME: can be dropped? */ return -ECHILD; @@ -447,7 +447,7 @@ { struct inode *inode = file->f_dentry->d_inode; struct vx_info *vxi = NULL; - xid_t xid = PROC_I(inode)->fd; + vxid_t xid = PROC_I(inode)->fd; unsigned long page; ssize_t length = 0; @@ -483,7 +483,7 @@ { struct inode *inode = file->f_dentry->d_inode; struct nx_info *nxi = NULL; - nid_t nid = PROC_I(inode)->fd; + vnid_t nid = PROC_I(inode)->fd; unsigned long page; ssize_t length = 0; diff -u linux-3.9.4-vs2.3.6.4/kernel/vserver/tag.c linux-3.9.4-vs2.3.6.4/kernel/vserver/tag.c --- linux-3.9.4-vs2.3.6.4/kernel/vserver/tag.c 2013-05-31 14:47:11.000000000 +0000 +++ linux-3.9.4-vs2.3.6.4/kernel/vserver/tag.c 2013-05-31 14:47:11.000000000 +0000 @@ -17,7 +17,7 @@ #include -int dx_migrate_task(struct task_struct *p, tag_t tag) +int dx_migrate_task(struct task_struct *p, vtag_t tag) { if (!p) BUG(); @@ -41,7 +41,7 @@ int vc_task_tag(uint32_t id) { - tag_t tag; + vtag_t tag; if (id) { struct task_struct *tsk;