Skip to content

Commit

Permalink
[S390] uaccess: turn __access_ok() into a define
Browse files Browse the repository at this point in the history
Turn __access_ok() into a define and add a __chk_user_ptr() call
instead.

Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
  • Loading branch information
Heiko Carstens committed May 26, 2011
1 parent d7b250e commit 7683f74
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions arch/s390/include/asm/uaccess.h
Original file line number Diff line number Diff line change
Expand Up @@ -49,12 +49,13 @@

#define segment_eq(a,b) ((a).ar4 == (b).ar4)

#define __access_ok(addr, size) \
({ \
__chk_user_ptr(addr); \
1; \
})

static inline int __access_ok(const void __user *addr, unsigned long size)
{
return 1;
}
#define access_ok(type,addr,size) __access_ok(addr,size)
#define access_ok(type, addr, size) __access_ok(addr, size)

/*
* The exception table consists of pairs of addresses: the first is the
Expand Down

0 comments on commit 7683f74

Please sign in to comment.