asm-generic: remove extra strn{cpy_from,len}_user declarations

As these are now in asm-generic, it's no longer necessary to
declare them in the architecture.

Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
This commit is contained in:
Arnd Bergmann 2020-01-17 17:26:54 +01:00
parent 98b861a304
commit 166ec4633b
3 changed files with 1 additions and 15 deletions

View File

@ -667,11 +667,6 @@ extern unsigned long arc_clear_user_noinline(void __user *to,
#define __clear_user(d, n) arc_clear_user_noinline(d, n)
#endif
extern long strncpy_from_user(char *dst, const char __user *src, long count);
#define strncpy_from_user(d, s, n) strncpy_from_user(d, s, n)
extern long strnlen_user(const char __user *src, long n);
#define strnlen_user(s, n) strnlen_user(s, n)
#include <asm/segment.h>
#include <asm-generic/uaccess.h>

View File

@ -57,12 +57,6 @@ unsigned long raw_copy_to_user(void __user *to, const void *from,
__kernel_size_t __clear_user_hexagon(void __user *dest, unsigned long count);
#define __clear_user(a, s) __clear_user_hexagon((a), (s))
extern long strnlen_user(const char __user *src, long n);
#define strnlen_user strnlen_user
extern long strncpy_from_user(char *dst, const char __user *src, long n)
#define strncpy_from_user strncpy_from_user
#include <asm-generic/uaccess.h>

View File

@ -23,16 +23,13 @@
extern unsigned long raw_copy_from_user(void *to, const void __user *from, unsigned long n);
extern unsigned long raw_copy_to_user(void __user *to, const void *from, unsigned long n);
extern long strncpy_from_user(char *dst, const char __user *src, long count);
extern long strnlen_user(const void __user *str, long len);
extern unsigned long __clear_user(void __user *mem, unsigned long len);
static inline int __access_ok(unsigned long addr, unsigned long size);
/* Teach asm-generic/uaccess.h that we have C functions for these. */
#define __access_ok __access_ok
#define __clear_user __clear_user
#define strnlen_user strnlen_user
#define strncpy_from_user strncpy_from_user
#define INLINE_COPY_FROM_USER
#define INLINE_COPY_TO_USER