]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
Merge remote-tracking branch 'jfs/jfs-next'
authorStephen Rothwell <sfr@canb.auug.org.au>
Wed, 3 Oct 2012 01:24:40 +0000 (11:24 +1000)
committerStephen Rothwell <sfr@canb.auug.org.au>
Wed, 3 Oct 2012 01:24:40 +0000 (11:24 +1000)
1  2 
fs/jfs/jfs_incore.h
fs/jfs/super.c

index 680605d7bf15eed0928d762d874412804a5d75f1,4fa958ae198620cb1e66aad13eb6fccdc0c52081..cf47f09e8ac8ab692df3aa14f9420f79005d1725
@@@ -192,9 -192,10 +192,10 @@@ struct jfs_sb_info 
        uint            state;          /* mount/recovery state */
        unsigned long   flag;           /* mount time flags */
        uint            p_state;        /* state prior to going no integrity */
 -      uint            uid;            /* uid to override on-disk uid */
 -      uint            gid;            /* gid to override on-disk gid */
 +      kuid_t          uid;            /* uid to override on-disk uid */
 +      kgid_t          gid;            /* gid to override on-disk gid */
        uint            umask;          /* umask to override on-disk umask */
+       uint            minblks_trim;   /* minimum blocks, for online trim */
  };
  
  /* jfs_sb_info commit_state */
diff --cc fs/jfs/super.c
index 706692f240331e337631385cc6418f18e164e9d0,6f4ac1c070f0118d8dbda1a9405a2abd4f6ad426..53b896446e6cfdb702e55bc77abb07bbaf510c88
@@@ -321,21 -322,17 +322,23 @@@ static int parse_options(char *options
                case Opt_uid:
                {
                        char *uid = args[0].from;
 -                      sbi->uid = simple_strtoul(uid, &uid, 0);
 +                      uid_t val = simple_strtoul(uid, &uid, 0);
 +                      sbi->uid = make_kuid(current_user_ns(), val);
 +                      if (!uid_valid(sbi->uid))
 +                              goto cleanup;
                        break;
                }
                case Opt_gid:
                {
                        char *gid = args[0].from;
 -                      sbi->gid = simple_strtoul(gid, &gid, 0);
 +                      gid_t val = simple_strtoul(gid, &gid, 0);
 +                      sbi->gid = make_kgid(current_user_ns(), val);
 +                      if (!gid_valid(sbi->gid))
 +                              goto cleanup;
                        break;
                }
                case Opt_umask:
                {
                        char *umask = args[0].from;