X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=include%2Fasm-i386%2Fstring.h;h=fc66609bb76142e19c3adf129d26243640a84299;hb=9bf4aaab3e101692164d49b7ca357651eb691cb6;hp=a14f9f37d9c1ff7b4b8c0d18107d661e8d527fc7;hpb=db216c3d5e4c040e557a50f8f5d35d5c415e8c1c;p=linux-2.6.git diff --git a/include/asm-i386/string.h b/include/asm-i386/string.h index a14f9f37d..fc66609bb 100644 --- a/include/asm-i386/string.h +++ b/include/asm-i386/string.h @@ -27,6 +27,7 @@ */ #if !defined(IN_STRING_C) +#define __HAVE_ARCH_STRCPY static inline char * strcpy(char * dest,const char *src) { int d0, d1, d2; @@ -40,6 +41,7 @@ __asm__ __volatile__( return dest; } +#define __HAVE_ARCH_STRNCPY static inline char * strncpy(char * dest,const char *src,size_t count) { int d0, d1, d2, d3; @@ -58,6 +60,7 @@ __asm__ __volatile__( return dest; } +#define __HAVE_ARCH_STRCAT static inline char * strcat(char * dest,const char * src) { int d0, d1, d2, d3; @@ -74,6 +77,7 @@ __asm__ __volatile__( return dest; } +#define __HAVE_ARCH_STRNCAT static inline char * strncat(char * dest,const char * src,size_t count) { int d0, d1, d2, d3; @@ -96,6 +100,7 @@ __asm__ __volatile__( return dest; } +#define __HAVE_ARCH_STRCMP static inline int strcmp(const char * cs,const char * ct) { int d0, d1; @@ -116,6 +121,7 @@ __asm__ __volatile__( return __res; } +#define __HAVE_ARCH_STRNCMP static inline int strncmp(const char * cs,const char * ct,size_t count) { register int __res; @@ -138,6 +144,7 @@ __asm__ __volatile__( return __res; } +#define __HAVE_ARCH_STRCHR static inline char * strchr(const char * s, int c) { int d0; @@ -156,6 +163,7 @@ __asm__ __volatile__( return __res; } +#define __HAVE_ARCH_STRRCHR static inline char * strrchr(const char * s, int c) { int d0, d1; @@ -277,41 +285,8 @@ static __inline__ void *__memcpy3d(void *to, const void *from, size_t len) #endif -/* - * struct_cpy(x,y), copy structure *x into (matching structure) *y. - * - * We get link-time errors if the structure sizes do not match. - * There is no runtime overhead, it's all optimized away at - * compile time. - */ -extern void __struct_cpy_bug (void); - -#define struct_cpy(x,y) \ -({ \ - if (sizeof(*(x)) != sizeof(*(y))) \ - __struct_cpy_bug(); \ - memcpy(x, y, sizeof(*(x))); \ -}) - #define __HAVE_ARCH_MEMMOVE -static inline void * memmove(void * dest,const void * src, size_t n) -{ -int d0, d1, d2; -if (dest