projects
/
cascardo
/
linux.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
debugfs: fix race in u32_array_read and allocate array at open
[cascardo/linux.git]
/
fs
/
binfmt_elf.c
diff --git
a/fs/binfmt_elf.c
b/fs/binfmt_elf.c
index
e658dd1
..
1b52956
100644
(file)
--- a/
fs/binfmt_elf.c
+++ b/
fs/binfmt_elf.c
@@
-329,7
+329,6
@@
static unsigned long elf_map(struct file *filep, unsigned long addr,
if (!size)
return addr;
if (!size)
return addr;
- down_write(¤t->mm->mmap_sem);
/*
* total_size is the size of the ELF (interpreter) image.
* The _first_ mmap needs to know the full size, otherwise
/*
* total_size is the size of the ELF (interpreter) image.
* The _first_ mmap needs to know the full size, otherwise
@@
-340,13
+339,12
@@
static unsigned long elf_map(struct file *filep, unsigned long addr,
*/
if (total_size) {
total_size = ELF_PAGEALIGN(total_size);
*/
if (total_size) {
total_size = ELF_PAGEALIGN(total_size);
- map_addr =
do
_mmap(filep, addr, total_size, prot, type, off);
+ map_addr =
vm
_mmap(filep, addr, total_size, prot, type, off);
if (!BAD_ADDR(map_addr))
if (!BAD_ADDR(map_addr))
-
do_munmap(current->mm,
map_addr+size, total_size-size);
+
vm_munmap(
map_addr+size, total_size-size);
} else
} else
- map_addr =
do
_mmap(filep, addr, size, prot, type, off);
+ map_addr =
vm
_mmap(filep, addr, size, prot, type, off);
- up_write(¤t->mm->mmap_sem);
return(map_addr);
}
return(map_addr);
}