Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

cgroup: propagate mode_t

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>

Al Viro a5e7ed32 f9ec8006

+8 -8
+1 -1
include/linux/cgroup.h
··· 319 319 * If not 0, file mode is set to this value, otherwise it will 320 320 * be figured out automatically 321 321 */ 322 - mode_t mode; 322 + umode_t mode; 323 323 324 324 /* 325 325 * If non-zero, defines the maximum length of string that can
+7 -7
kernel/cgroup.c
··· 775 775 static int alloc_css_id(struct cgroup_subsys *ss, 776 776 struct cgroup *parent, struct cgroup *child); 777 777 778 - static struct inode *cgroup_new_inode(mode_t mode, struct super_block *sb) 778 + static struct inode *cgroup_new_inode(umode_t mode, struct super_block *sb) 779 779 { 780 780 struct inode *inode = new_inode(sb); 781 781 ··· 2585 2585 return __d_cft(file->f_dentry); 2586 2586 } 2587 2587 2588 - static int cgroup_create_file(struct dentry *dentry, mode_t mode, 2588 + static int cgroup_create_file(struct dentry *dentry, umode_t mode, 2589 2589 struct super_block *sb) 2590 2590 { 2591 2591 struct inode *inode; ··· 2626 2626 * @mode: mode to set on new directory. 2627 2627 */ 2628 2628 static int cgroup_create_dir(struct cgroup *cgrp, struct dentry *dentry, 2629 - mode_t mode) 2629 + umode_t mode) 2630 2630 { 2631 2631 struct dentry *parent; 2632 2632 int error = 0; ··· 2653 2653 * returns S_IRUGO if it has only a read handler 2654 2654 * returns S_IWUSR if it has only a write hander 2655 2655 */ 2656 - static mode_t cgroup_file_mode(const struct cftype *cft) 2656 + static umode_t cgroup_file_mode(const struct cftype *cft) 2657 2657 { 2658 - mode_t mode = 0; 2658 + umode_t mode = 0; 2659 2659 2660 2660 if (cft->mode) 2661 2661 return cft->mode; ··· 2678 2678 struct dentry *dir = cgrp->dentry; 2679 2679 struct dentry *dentry; 2680 2680 int error; 2681 - mode_t mode; 2681 + umode_t mode; 2682 2682 2683 2683 char name[MAX_CGROUP_TYPE_NAMELEN + MAX_CFTYPE_NAME + 2] = { 0 }; 2684 2684 if (subsys && !test_bit(ROOT_NOPREFIX, &cgrp->root->flags)) { ··· 3752 3752 * Must be called with the mutex on the parent inode held 3753 3753 */ 3754 3754 static long cgroup_create(struct cgroup *parent, struct dentry *dentry, 3755 - mode_t mode) 3755 + umode_t mode) 3756 3756 { 3757 3757 struct cgroup *cgrp; 3758 3758 struct cgroupfs_root *root = parent->root;