]> pilppa.com Git - linux-2.6-omap-h63xx.git/commitdiff
Merge branch 'master' into next
authorJames Morris <jmorris@namei.org>
Thu, 4 Dec 2008 06:16:36 +0000 (17:16 +1100)
committerJames Morris <jmorris@namei.org>
Thu, 4 Dec 2008 06:16:36 +0000 (17:16 +1100)
Conflicts:
fs/nfsd/nfs4recover.c

Manually fixed above to use new creds API functions, e.g.
nfs4_save_creds().

Signed-off-by: James Morris <jmorris@namei.org>
18 files changed:
1  2 
Documentation/kernel-parameters.txt
fs/cifs/misc.c
fs/namei.c
fs/nfsd/nfs4recover.c
fs/ocfs2/dlm/dlmfs.c
fs/ubifs/dir.c
include/linux/sched.h
include/linux/security.h
ipc/util.c
kernel/cgroup.c
kernel/ptrace.c
kernel/sched.c
kernel/sysctl.c
kernel/trace/trace.c
mm/migrate.c
net/rose/af_rose.c
net/socket.c
net/unix/af_unix.c

Simple merge
diff --cc fs/cifs/misc.c
Simple merge
diff --cc fs/namei.c
Simple merge
index 9371ea12d7fa459e6ff9b6f6babd148eaccfd1fb,b79ec930d9f1af003ddfb1fd9d130b12f6755f8b..0f9d6efaa62bb553bb95b3063516bcb793f52929
@@@ -230,12 -224,10 +230,13 @@@ nfsd4_list_rec_dir(struct dentry *dir, 
        if (!rec_dir_init)
                return 0;
  
 -      nfs4_save_user(&uid, &gid);
 +      status = nfs4_save_creds(&original_cred);
 +      if (status < 0)
 +              return status;
+       INIT_LIST_HEAD(dentries);
  
 -      filp = dentry_open(dget(dir), mntget(rec_dir.mnt), O_RDONLY);
 +      filp = dentry_open(dget(dir), mntget(rec_dir.mnt), O_RDONLY,
 +                         current_cred());
        status = PTR_ERR(filp);
        if (IS_ERR(filp))
                goto out;
Simple merge
diff --cc fs/ubifs/dir.c
Simple merge
Simple merge
index 59a11e19b617d2b2e55151a8214d5163cccefd4c,e3d4ecda267381d85da5697b2ad681c1da749fe3..6423abf1ac0faee1385d460bcd9951b1bd85a955
@@@ -1800,32 -1822,45 +1801,35 @@@ static inline int security_vm_enough_me
        return cap_vm_enough_memory(current->mm, pages);
  }
  
- static inline int security_vm_enough_memory_kern(long pages)
+ static inline int security_vm_enough_memory_mm(struct mm_struct *mm, long pages)
  {
-       return cap_vm_enough_memory(current->mm, pages);
+       WARN_ON(mm == NULL);
+       return cap_vm_enough_memory(mm, pages);
  }
  
- static inline int security_vm_enough_memory_mm(struct mm_struct *mm, long pages)
+ static inline int security_vm_enough_memory_kern(long pages)
  {
-       return cap_vm_enough_memory(mm, pages);
+       /* If current->mm is a kernel thread then we will pass NULL,
+          for this specific case that is fine */
+       return cap_vm_enough_memory(current->mm, pages);
  }
  
 -static inline int security_bprm_alloc(struct linux_binprm *bprm)
 -{
 -      return 0;
 -}
 -
 -static inline void security_bprm_free(struct linux_binprm *bprm)
 -{ }
 -
 -static inline void security_bprm_apply_creds(struct linux_binprm *bprm, int unsafe)
 +static inline int security_bprm_set_creds(struct linux_binprm *bprm)
  {
 -      cap_bprm_apply_creds(bprm, unsafe);
 +      return cap_bprm_set_creds(bprm);
  }
  
 -static inline void security_bprm_post_apply_creds(struct linux_binprm *bprm)
 +static inline int security_bprm_check(struct linux_binprm *bprm)
  {
 -      return;
 +      return 0;
  }
  
 -static inline int security_bprm_set(struct linux_binprm *bprm)
 +static inline void security_bprm_committing_creds(struct linux_binprm *bprm)
  {
 -      return cap_bprm_set_security(bprm);
  }
  
 -static inline int security_bprm_check(struct linux_binprm *bprm)
 +static inline void security_bprm_committed_creds(struct linux_binprm *bprm)
  {
 -      return 0;
  }
  
  static inline int security_bprm_secureexec(struct linux_binprm *bprm)
diff --cc ipc/util.c
Simple merge
diff --cc kernel/cgroup.c
Simple merge
diff --cc kernel/ptrace.c
Simple merge
diff --cc kernel/sched.c
Simple merge
diff --cc kernel/sysctl.c
Simple merge
Simple merge
diff --cc mm/migrate.c
Simple merge
Simple merge
diff --cc net/socket.c
Simple merge
Simple merge