1 #ifndef __ASM_ARM_STRING_H
2 #define __ASM_ARM_STRING_H
7 * We don't do inline string functions, since the
8 * optimised inline asm versions are not small.
11 #undef __HAVE_ARCH_STRRCHR
12 extern char * strrchr(const char * s, int c);
14 #undef __HAVE_ARCH_STRCHR
15 extern char * strchr(const char * s, int c);
17 #ifdef CONFIG_USE_ARCH_MEMCPY
18 #define __HAVE_ARCH_MEMCPY
20 extern void * memcpy(void *, const void *, __kernel_size_t);
22 #undef __HAVE_ARCH_MEMMOVE
23 extern void * memmove(void *, const void *, __kernel_size_t);
25 #undef __HAVE_ARCH_MEMCHR
26 extern void * memchr(const void *, int, __kernel_size_t);
28 #undef __HAVE_ARCH_MEMZERO
29 #ifdef CONFIG_USE_ARCH_MEMSET
30 #define __HAVE_ARCH_MEMSET
32 extern void * memset(void *, int, __kernel_size_t);
35 extern void __memzero(void *ptr, __kernel_size_t n);
37 #define memset(p,v,n) \
40 if (__builtin_constant_p((v)) && (v) == 0) \
43 memset((p),(v),(n)); \
48 #define memzero(p,n) ({ if ((n) != 0) __memzero((p),(n)); (p); })
50 extern void memzero(void *ptr, __kernel_size_t n);