aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/string.h
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@ppc970.osdl.org>2005-04-16 18:20:36 -0400
committerLinus Torvalds <torvalds@ppc970.osdl.org>2005-04-16 18:20:36 -0400
commit1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 (patch)
tree0bba044c4ce775e45a88a51686b5d9f90697ea9d /include/linux/string.h
Linux-2.6.12-rc2v2.6.12-rc2
Initial git repository build. I'm not bothering with the full history, even though we have it. We can create a separate "historical" git archive of that later if we want to, and in the meantime it's about 3.2GB when imported into git - space that would just make the early git days unnecessarily complicated, when we don't have a lot of good infrastructure for it. Let it rip!
Diffstat (limited to 'include/linux/string.h')
-rw-r--r--include/linux/string.h96
1 files changed, 96 insertions, 0 deletions
diff --git a/include/linux/string.h b/include/linux/string.h
new file mode 100644
index 000000000000..b9fc59469956
--- /dev/null
+++ b/include/linux/string.h
@@ -0,0 +1,96 @@
1#ifndef _LINUX_STRING_H_
2#define _LINUX_STRING_H_
3
4/* We don't want strings.h stuff being user by user stuff by accident */
5
6#ifdef __KERNEL__
7
8#include <linux/compiler.h> /* for inline */
9#include <linux/types.h> /* for size_t */
10#include <linux/stddef.h> /* for NULL */
11
12#ifdef __cplusplus
13extern "C" {
14#endif
15
16extern char * strpbrk(const char *,const char *);
17extern char * strsep(char **,const char *);
18extern __kernel_size_t strspn(const char *,const char *);
19extern __kernel_size_t strcspn(const char *,const char *);
20
21/*
22 * Include machine specific inline routines
23 */
24#include <asm/string.h>
25
26#ifndef __HAVE_ARCH_STRCPY
27extern char * strcpy(char *,const char *);
28#endif
29#ifndef __HAVE_ARCH_STRNCPY
30extern char * strncpy(char *,const char *, __kernel_size_t);
31#endif
32#ifndef __HAVE_ARCH_STRLCPY
33size_t strlcpy(char *, const char *, size_t);
34#endif
35#ifndef __HAVE_ARCH_STRCAT
36extern char * strcat(char *, const char *);
37#endif
38#ifndef __HAVE_ARCH_STRNCAT
39extern char * strncat(char *, const char *, __kernel_size_t);
40#endif
41#ifndef __HAVE_ARCH_STRLCAT
42extern size_t strlcat(char *, const char *, __kernel_size_t);
43#endif
44#ifndef __HAVE_ARCH_STRCMP
45extern int strcmp(const char *,const char *);
46#endif
47#ifndef __HAVE_ARCH_STRNCMP
48extern int strncmp(const char *,const char *,__kernel_size_t);
49#endif
50#ifndef __HAVE_ARCH_STRNICMP
51extern int strnicmp(const char *, const char *, __kernel_size_t);
52#endif
53#ifndef __HAVE_ARCH_STRCHR
54extern char * strchr(const char *,int);
55#endif
56#ifndef __HAVE_ARCH_STRNCHR
57extern char * strnchr(const char *, size_t, int);
58#endif
59#ifndef __HAVE_ARCH_STRRCHR
60extern char * strrchr(const char *,int);
61#endif
62#ifndef __HAVE_ARCH_STRSTR
63extern char * strstr(const char *,const char *);
64#endif
65#ifndef __HAVE_ARCH_STRLEN
66extern __kernel_size_t strlen(const char *);
67#endif
68#ifndef __HAVE_ARCH_STRNLEN
69extern __kernel_size_t strnlen(const char *,__kernel_size_t);
70#endif
71
72#ifndef __HAVE_ARCH_MEMSET
73extern void * memset(void *,int,__kernel_size_t);
74#endif
75#ifndef __HAVE_ARCH_MEMCPY
76extern void * memcpy(void *,const void *,__kernel_size_t);
77#endif
78#ifndef __HAVE_ARCH_MEMMOVE
79extern void * memmove(void *,const void *,__kernel_size_t);
80#endif
81#ifndef __HAVE_ARCH_MEMSCAN
82extern void * memscan(void *,int,__kernel_size_t);
83#endif
84#ifndef __HAVE_ARCH_MEMCMP
85extern int memcmp(const void *,const void *,__kernel_size_t);
86#endif
87#ifndef __HAVE_ARCH_MEMCHR
88extern void * memchr(const void *,int,__kernel_size_t);
89#endif
90
91#ifdef __cplusplus
92}
93#endif
94
95#endif
96#endif /* _LINUX_STRING_H_ */