projects
/
powerpc.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge master.kernel.org:/home/rmk/linux-2.6-mmc
[powerpc.git]
/
fs
/
exec.c
diff --git
a/fs/exec.c
b/fs/exec.c
index
14dd039
..
d2208f7
100644
(file)
--- a/
fs/exec.c
+++ b/
fs/exec.c
@@
-126,8
+126,7
@@
asmlinkage long sys_uselib(const char __user * library)
struct nameidata nd;
int error;
struct nameidata nd;
int error;
- nd.intent.open.flags = FMODE_READ;
- error = __user_walk(library, LOOKUP_FOLLOW|LOOKUP_OPEN, &nd);
+ error = __user_path_lookup_open(library, LOOKUP_FOLLOW, &nd, FMODE_READ);
if (error)
goto out;
if (error)
goto out;
@@
-139,7
+138,7
@@
asmlinkage long sys_uselib(const char __user * library)
if (error)
goto exit;
if (error)
goto exit;
- file =
dentry_open(nd.dentry, nd.mnt
, O_RDONLY);
+ file =
nameidata_to_filp(&nd
, O_RDONLY);
error = PTR_ERR(file);
if (IS_ERR(file))
goto out;
error = PTR_ERR(file);
if (IS_ERR(file))
goto out;
@@
-167,6
+166,7
@@
asmlinkage long sys_uselib(const char __user * library)
out:
return error;
exit:
out:
return error;
exit:
+ release_open_intent(&nd);
path_release(&nd);
goto out;
}
path_release(&nd);
goto out;
}
@@
-421,11
+421,6
@@
int setup_arg_pages(struct linux_binprm *bprm,
if (!mpnt)
return -ENOMEM;
if (!mpnt)
return -ENOMEM;
- if (security_vm_enough_memory(arg_size >> PAGE_SHIFT)) {
- kmem_cache_free(vm_area_cachep, mpnt);
- return -ENOMEM;
- }
-
memset(mpnt, 0, sizeof(*mpnt));
down_write(&mm->mmap_sem);
memset(mpnt, 0, sizeof(*mpnt));
down_write(&mm->mmap_sem);
@@
-495,8
+490,7
@@
struct file *open_exec(const char *name)
int err;
struct file *file;
int err;
struct file *file;
- nd.intent.open.flags = FMODE_READ;
- err = path_lookup(name, LOOKUP_FOLLOW|LOOKUP_OPEN, &nd);
+ err = path_lookup_open(name, LOOKUP_FOLLOW, &nd, FMODE_READ);
file = ERR_PTR(err);
if (!err) {
file = ERR_PTR(err);
if (!err) {
@@
-509,7
+503,7
@@
struct file *open_exec(const char *name)
err = -EACCES;
file = ERR_PTR(err);
if (!err) {
err = -EACCES;
file = ERR_PTR(err);
if (!err) {
- file =
dentry_open(nd.dentry, nd.mnt
, O_RDONLY);
+ file =
nameidata_to_filp(&nd
, O_RDONLY);
if (!IS_ERR(file)) {
err = deny_write_access(file);
if (err) {
if (!IS_ERR(file)) {
err = deny_write_access(file);
if (err) {
@@
-521,6
+515,7
@@
out:
return file;
}
}
return file;
}
}
+ release_open_intent(&nd);
path_release(&nd);
}
goto out;
path_release(&nd);
}
goto out;
@@
-745,8
+740,8
@@
static inline int de_thread(struct task_struct *tsk)
}
/*
}
/*
- *
Now there are really no other threads at all
,
- *
so it's safe to stop telling them
to kill themselves.
+ *
There may be one thread left which is just exiting
,
+ *
but it's safe to stop telling the group
to kill themselves.
*/
sig->flags = 0;
*/
sig->flags = 0;
@@
-785,7
+780,6
@@
no_thread_group:
kmem_cache_free(sighand_cachep, oldsighand);
}
kmem_cache_free(sighand_cachep, oldsighand);
}
- BUG_ON(!thread_group_empty(current));
BUG_ON(!thread_group_leader(current));
return 0;
}
BUG_ON(!thread_group_leader(current));
return 0;
}