Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 45355
b: refs/heads/master
c: d8ad075
h: refs/heads/master
i:
  45353: ce6012a
  45351: 95177be
v: v3
  • Loading branch information
Heiko Carstens authored and Martin Schwidefsky committed Jan 9, 2007
1 parent e9f4d85 commit 18608b7
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 5 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: de338a3795bbcb3c3d77591f65118cbec776cc39
refs/heads/master: d8ad075ef60ca33f1bd8e227eed2202108fd6cd8
3 changes: 3 additions & 0 deletions trunk/arch/s390/lib/uaccess_pt.c
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
*/

#include <linux/errno.h>
#include <linux/hardirq.h>
#include <linux/mm.h>
#include <asm/uaccess.h>
#include <asm/futex.h>
Expand All @@ -18,6 +19,8 @@ static inline int __handle_fault(struct mm_struct *mm, unsigned long address,
struct vm_area_struct *vma;
int ret = -EFAULT;

if (in_atomic())
return ret;
down_read(&mm->mmap_sem);
vma = find_vma(mm, address);
if (unlikely(!vma))
Expand Down
3 changes: 0 additions & 3 deletions trunk/arch/s390/lib/uaccess_std.c
Original file line number Diff line number Diff line change
Expand Up @@ -258,8 +258,6 @@ int futex_atomic_op(int op, int __user *uaddr, int oparg, int *old)
{
int oldval = 0, newval, ret;

pagefault_disable();

switch (op) {
case FUTEX_OP_SET:
__futex_atomic_op("lr %2,%5\n",
Expand All @@ -284,7 +282,6 @@ int futex_atomic_op(int op, int __user *uaddr, int oparg, int *old)
default:
ret = -ENOSYS;
}
pagefault_enable();
*old = oldval;
return ret;
}
Expand Down
4 changes: 3 additions & 1 deletion trunk/include/asm-s390/futex.h
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
#ifdef __KERNEL__

#include <linux/futex.h>
#include <linux/uaccess.h>
#include <asm/errno.h>
#include <asm/uaccess.h>

static inline int futex_atomic_op_inuser (int encoded_op, int __user *uaddr)
{
Expand All @@ -21,7 +21,9 @@ static inline int futex_atomic_op_inuser (int encoded_op, int __user *uaddr)
if (! access_ok (VERIFY_WRITE, uaddr, sizeof(int)))
return -EFAULT;

pagefault_disable();
ret = uaccess.futex_atomic_op(op, uaddr, oparg, &oldval);
pagefault_enable();

if (!ret) {
switch (cmp) {
Expand Down

0 comments on commit 18608b7

Please sign in to comment.