xref: /rk3399_ARM-atf/include/lib/libc/string.h (revision 7c0ff9c40ceeacf239ec9a3465be0477594cf898)
127989a8eSAntonio Nino Diaz /*
227989a8eSAntonio Nino Diaz  * Copyright (c) 2012-2017 Roberto E. Vargas Caballero
327989a8eSAntonio Nino Diaz  *
427989a8eSAntonio Nino Diaz  * SPDX-License-Identifier: BSD-3-Clause
527989a8eSAntonio Nino Diaz  */
6*7c0ff9c4SAntonio Nino Diaz /*
7*7c0ff9c4SAntonio Nino Diaz  * Portions copyright (c) 2018, ARM Limited and Contributors.
8*7c0ff9c4SAntonio Nino Diaz  * All rights reserved.
9*7c0ff9c4SAntonio Nino Diaz  */
1027989a8eSAntonio Nino Diaz 
1127989a8eSAntonio Nino Diaz #ifndef _STRING_H
1227989a8eSAntonio Nino Diaz #define _STRING_H
1327989a8eSAntonio Nino Diaz 
14*7c0ff9c4SAntonio Nino Diaz #include <string_.h>
1527989a8eSAntonio Nino Diaz 
1627989a8eSAntonio Nino Diaz #ifndef NULL
1727989a8eSAntonio Nino Diaz #define NULL ((void *) 0)
1827989a8eSAntonio Nino Diaz #endif
1927989a8eSAntonio Nino Diaz 
2027989a8eSAntonio Nino Diaz extern void *memcpy(void * restrict s1, const void * restrict s2, size_t n);
2127989a8eSAntonio Nino Diaz extern void *memmove(void *s1, const void *s2, size_t n);
2227989a8eSAntonio Nino Diaz extern char *strcpy(char * restrict s1, const char * restrict s2);
2327989a8eSAntonio Nino Diaz extern char *strncpy(char * restrict s1, const char * restrict s2, size_t n);
2427989a8eSAntonio Nino Diaz extern char *strcat(char * restrict s1, const char * restrict s2);
2527989a8eSAntonio Nino Diaz extern char *strncat(char * restrict s1, const char * restrict s2, size_t n);
2627989a8eSAntonio Nino Diaz extern int memcmp(const void *s1, const void *s2, size_t n);
2727989a8eSAntonio Nino Diaz extern int strcmp(const char *s1, const char *s2);
2827989a8eSAntonio Nino Diaz extern int strcoll(const char *s1, const char *s2);
2927989a8eSAntonio Nino Diaz extern int strncmp(const char *s1, const char *s2, size_t n);
3027989a8eSAntonio Nino Diaz extern size_t strxfrm(char * restrict s1, const char * restrict s2, size_t n);
3127989a8eSAntonio Nino Diaz extern void *memchr(const void *s, int c, size_t n);
3227989a8eSAntonio Nino Diaz extern char *strchr(const char *s, int c);
3327989a8eSAntonio Nino Diaz extern size_t strcspn(const char *s1, const char *s2);
3427989a8eSAntonio Nino Diaz extern char *strpbrk(const char *s1, const char *s2);
3527989a8eSAntonio Nino Diaz extern char *strrchr(const char *s, int c);
3627989a8eSAntonio Nino Diaz extern size_t strspn(const char *s1, const char *s2);
3727989a8eSAntonio Nino Diaz extern char *strstr(const char *s1, const char *s2);
3827989a8eSAntonio Nino Diaz extern char *strtok(char * restrict s1, const char * restrict s2);
3927989a8eSAntonio Nino Diaz extern void *memset(void *s, int c, size_t n);
4027989a8eSAntonio Nino Diaz extern char *strerror(int errnum);
4127989a8eSAntonio Nino Diaz extern size_t strlen(const char *s);
4227989a8eSAntonio Nino Diaz 
4327989a8eSAntonio Nino Diaz #endif
44