string.h 1.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950
  1. /* string.h: FRV string handling
  2. *
  3. * Copyright (C) 2004 Red Hat, Inc. All Rights Reserved.
  4. * Written by David Howells (dhowells@redhat.com)
  5. *
  6. * This program is free software; you can redistribute it and/or
  7. * modify it under the terms of the GNU General Public License
  8. * as published by the Free Software Foundation; either version
  9. * 2 of the License, or (at your option) any later version.
  10. */
  11. #ifndef _ASM_STRING_H_
  12. #define _ASM_STRING_H_
  13. #ifdef __KERNEL__ /* only set these up for kernel code */
  14. #define __HAVE_ARCH_MEMSET 1
  15. #define __HAVE_ARCH_MEMCPY 1
  16. extern void *memset(void *, int, __kernel_size_t);
  17. extern void *memcpy(void *, const void *, __kernel_size_t);
  18. #else /* KERNEL */
  19. /*
  20. * let user libraries deal with these,
  21. * IMHO the kernel has no place defining these functions for user apps
  22. */
  23. #define __HAVE_ARCH_STRCPY 1
  24. #define __HAVE_ARCH_STRNCPY 1
  25. #define __HAVE_ARCH_STRCAT 1
  26. #define __HAVE_ARCH_STRNCAT 1
  27. #define __HAVE_ARCH_STRCMP 1
  28. #define __HAVE_ARCH_STRNCMP 1
  29. #define __HAVE_ARCH_STRCHR 1
  30. #define __HAVE_ARCH_STRRCHR 1
  31. #define __HAVE_ARCH_STRSTR 1
  32. #define __HAVE_ARCH_STRLEN 1
  33. #define __HAVE_ARCH_STRNLEN 1
  34. #define __HAVE_ARCH_MEMSET 1
  35. #define __HAVE_ARCH_MEMCPY 1
  36. #define __HAVE_ARCH_MEMMOVE 1
  37. #define __HAVE_ARCH_MEMSCAN 1
  38. #define __HAVE_ARCH_MEMCMP 1
  39. #define __HAVE_ARCH_MEMCHR 1
  40. #define __HAVE_ARCH_STRTOK 1
  41. #endif /* KERNEL */
  42. #endif /* _ASM_STRING_H_ */