blob: 96348d617fca34c4abfbf00759a84b8178d8aae9 [file] [log] [blame]
wdenk60b1bd02001-10-17 20:21:50 +00001#ifndef _LINUX_STRING_H_
2#define _LINUX_STRING_H_
3
4#include <linux/types.h> /* for size_t */
5#include <linux/stddef.h> /* for NULL */
6
7#ifdef __cplusplus
8extern "C" {
9#endif
10
11extern char * ___strtok;
12extern char * strpbrk(const char *,const char *);
13extern char * strtok(char *,const char *);
14extern char * strsep(char **,const char *);
15extern __kernel_size_t strspn(const char *,const char *);
16
17
18/*
19 * Include machine specific inline routines
20 */
21#include <asm/string.h>
22
Jeroen Hofstee5afe73f2014-10-08 22:57:49 +020023#ifndef __HAVE_ARCH_BCOPY
24char *bcopy(const char *src, char *dest, int count);
25#endif
26
wdenk60b1bd02001-10-17 20:21:50 +000027#ifndef __HAVE_ARCH_STRCPY
28extern char * strcpy(char *,const char *);
29#endif
30#ifndef __HAVE_ARCH_STRNCPY
31extern char * strncpy(char *,const char *, __kernel_size_t);
32#endif
33#ifndef __HAVE_ARCH_STRCAT
34extern char * strcat(char *, const char *);
35#endif
36#ifndef __HAVE_ARCH_STRNCAT
37extern char * strncat(char *, const char *, __kernel_size_t);
38#endif
39#ifndef __HAVE_ARCH_STRCMP
40extern int strcmp(const char *,const char *);
41#endif
42#ifndef __HAVE_ARCH_STRNCMP
43extern int strncmp(const char *,const char *,__kernel_size_t);
44#endif
Simon Glassb1f17bf2012-12-05 14:46:35 +000045#ifndef __HAVE_ARCH_STRCASECMP
46int strcasecmp(const char *s1, const char *s2);
47#endif
48#ifndef __HAVE_ARCH_STRNCASECMP
49extern int strncasecmp(const char *s1, const char *s2, __kernel_size_t len);
wdenk60b1bd02001-10-17 20:21:50 +000050#endif
51#ifndef __HAVE_ARCH_STRCHR
52extern char * strchr(const char *,int);
53#endif
54#ifndef __HAVE_ARCH_STRRCHR
55extern char * strrchr(const char *,int);
56#endif
Joe Hershbergere772cb32012-12-11 22:16:18 -060057#include <linux/linux_string.h>
wdenk60b1bd02001-10-17 20:21:50 +000058#ifndef __HAVE_ARCH_STRSTR
59extern char * strstr(const char *,const char *);
60#endif
61#ifndef __HAVE_ARCH_STRLEN
62extern __kernel_size_t strlen(const char *);
63#endif
64#ifndef __HAVE_ARCH_STRNLEN
65extern __kernel_size_t strnlen(const char *,__kernel_size_t);
66#endif
67#ifndef __HAVE_ARCH_STRDUP
68extern char * strdup(const char *);
69#endif
wdenk27aa8182004-03-23 22:37:33 +000070#ifndef __HAVE_ARCH_STRSWAB
wdenkc3f9d492004-03-14 00:59:59 +000071extern char * strswab(const char *);
72#endif
wdenk60b1bd02001-10-17 20:21:50 +000073
74#ifndef __HAVE_ARCH_MEMSET
75extern void * memset(void *,int,__kernel_size_t);
76#endif
77#ifndef __HAVE_ARCH_MEMCPY
78extern void * memcpy(void *,const void *,__kernel_size_t);
79#endif
80#ifndef __HAVE_ARCH_MEMMOVE
81extern void * memmove(void *,const void *,__kernel_size_t);
82#endif
83#ifndef __HAVE_ARCH_MEMSCAN
84extern void * memscan(void *,int,__kernel_size_t);
85#endif
86#ifndef __HAVE_ARCH_MEMCMP
87extern int memcmp(const void *,const void *,__kernel_size_t);
88#endif
89#ifndef __HAVE_ARCH_MEMCHR
90extern void * memchr(const void *,int,__kernel_size_t);
91#endif
Sergey Lapindfe64e22013-01-14 03:46:50 +000092#ifndef __HAVE_ARCH_MEMCHR_INV
93void *memchr_inv(const void *, int, size_t);
94#endif
wdenk60b1bd02001-10-17 20:21:50 +000095
Jeroen Hofstee5afe73f2014-10-08 22:57:49 +020096unsigned long ustrtoul(const char *cp, char **endp, unsigned int base);
97unsigned long long ustrtoull(const char *cp, char **endp, unsigned int base);
98
wdenk60b1bd02001-10-17 20:21:50 +000099#ifdef __cplusplus
100}
101#endif
102
103#endif /* _LINUX_STRING_H_ */