projects
/
deliverable
/
linux.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
ARM: dts: omap3: Add clocks to McBSP nodes
[deliverable/linux.git]
/
ipc
/
shm.c
diff --git
a/ipc/shm.c
b/ipc/shm.c
index 331fc1b0b3c7952110f0223d741fc4fa19881d70..13282510bc0da71aa9789ff72ba015bede5c96e7 100644
(file)
--- a/
ipc/shm.c
+++ b/
ipc/shm.c
@@
-1200,7
+1200,11
@@
long do_shmat(int shmid, char __user *shmaddr, int shmflg, ulong *raddr,
if (err)
goto out_fput;
if (err)
goto out_fput;
- down_write(¤t->mm->mmap_sem);
+ if (down_write_killable(¤t->mm->mmap_sem)) {
+ err = -EINTR;
+ goto out_fput;
+ }
+
if (addr && !(shmflg & SHM_REMAP)) {
err = -EINVAL;
if (addr + size < addr)
if (addr && !(shmflg & SHM_REMAP)) {
err = -EINVAL;
if (addr + size < addr)
@@
-1271,7
+1275,8
@@
SYSCALL_DEFINE1(shmdt, char __user *, shmaddr)
if (addr & ~PAGE_MASK)
return retval;
if (addr & ~PAGE_MASK)
return retval;
- down_write(&mm->mmap_sem);
+ if (down_write_killable(&mm->mmap_sem))
+ return -EINTR;
/*
* This function tries to be smart and unmap shm segments that
/*
* This function tries to be smart and unmap shm segments that
This page took
0.024122 seconds
and
5
git commands to generate.