diff options
author | Mike Frysinger <vapier.adi@gmail.com> | 2009-01-07 10:14:38 -0500 |
---|---|---|
committer | Bryan Wu <cooloney@kernel.org> | 2009-01-07 10:14:38 -0500 |
commit | 75aca61b1fc76f46da79d1a4ec393faa19005927 (patch) | |
tree | afef4a782e50f24c7d147bbfcc5c7cd32eb3cbc5 /arch/blackfin/include | |
parent | d41e8009994f429ef7198a750c37fd9660366fab (diff) |
Blackfin arch: add __must_check markings to our user functions like other arches
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
Diffstat (limited to 'arch/blackfin/include')
-rw-r--r-- | arch/blackfin/include/asm/uaccess.h | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/arch/blackfin/include/asm/uaccess.h b/arch/blackfin/include/asm/uaccess.h index daf2dc8e98cf..3248033531e6 100644 --- a/arch/blackfin/include/asm/uaccess.h +++ b/arch/blackfin/include/asm/uaccess.h | |||
@@ -197,8 +197,8 @@ static inline int bad_user_access_length(void) | |||
197 | #define copy_from_user_ret(to,from,n,retval) ({ if (copy_from_user(to,from,n))\ | 197 | #define copy_from_user_ret(to,from,n,retval) ({ if (copy_from_user(to,from,n))\ |
198 | return retval; }) | 198 | return retval; }) |
199 | 199 | ||
200 | static inline long copy_from_user(void *to, | 200 | static inline unsigned long __must_check |
201 | const void __user * from, unsigned long n) | 201 | copy_from_user(void *to, const void __user *from, unsigned long n) |
202 | { | 202 | { |
203 | if (access_ok(VERIFY_READ, from, n)) | 203 | if (access_ok(VERIFY_READ, from, n)) |
204 | memcpy(to, from, n); | 204 | memcpy(to, from, n); |
@@ -207,8 +207,8 @@ static inline long copy_from_user(void *to, | |||
207 | return 0; | 207 | return 0; |
208 | } | 208 | } |
209 | 209 | ||
210 | static inline long copy_to_user(void *to, | 210 | static inline unsigned long __must_check |
211 | const void __user * from, unsigned long n) | 211 | copy_to_user(void *to, const void __user *from, unsigned long n) |
212 | { | 212 | { |
213 | if (access_ok(VERIFY_WRITE, to, n)) | 213 | if (access_ok(VERIFY_WRITE, to, n)) |
214 | memcpy(to, from, n); | 214 | memcpy(to, from, n); |
@@ -221,8 +221,8 @@ static inline long copy_to_user(void *to, | |||
221 | * Copy a null terminated string from userspace. | 221 | * Copy a null terminated string from userspace. |
222 | */ | 222 | */ |
223 | 223 | ||
224 | static inline long strncpy_from_user(char *dst, | 224 | static inline long __must_check |
225 | const char *src, long count) | 225 | strncpy_from_user(char *dst, const char *src, long count) |
226 | { | 226 | { |
227 | char *tmp; | 227 | char *tmp; |
228 | if (!access_ok(VERIFY_READ, src, 1)) | 228 | if (!access_ok(VERIFY_READ, src, 1)) |
@@ -248,7 +248,8 @@ static inline long strnlen_user(const char *src, long n) | |||
248 | * Zero Userspace | 248 | * Zero Userspace |
249 | */ | 249 | */ |
250 | 250 | ||
251 | static inline unsigned long __clear_user(void *to, unsigned long n) | 251 | static inline unsigned long __must_check |
252 | __clear_user(void *to, unsigned long n) | ||
252 | { | 253 | { |
253 | memset(to, 0, n); | 254 | memset(to, 0, n); |
254 | return 0; | 255 | return 0; |