summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--include/linux/string.h4
-rw-r--r--lib/string.c28
2 files changed, 0 insertions, 32 deletions
diff --git a/include/linux/string.h b/include/linux/string.h
index 488a459ed99..5bcbf72a89b 100644
--- a/include/linux/string.h
+++ b/include/linux/string.h
@@ -107,10 +107,6 @@ extern char * strndup(const char *, size_t);
extern const char *strdup_const(const char *s);
extern void kfree_const(const void *x);
-#ifndef __HAVE_ARCH_STRSWAB
-extern char * strswab(const char *);
-#endif
-
#ifndef __HAVE_ARCH_MEMSET
extern void * memset(void *,int,__kernel_size_t);
#endif
diff --git a/lib/string.c b/lib/string.c
index 45f0f5f8d09..82d0b6a9caa 100644
--- a/lib/string.c
+++ b/lib/string.c
@@ -503,34 +503,6 @@ char * strsep(char **s, const char *ct)
}
#endif
-#ifndef __HAVE_ARCH_STRSWAB
-/**
- * strswab - swap adjacent even and odd bytes in %NUL-terminated string
- * s: address of the string
- *
- * returns the address of the swapped string or NULL on error. If
- * string length is odd, last byte is untouched.
- */
-char *strswab(const char *s)
-{
- char *p, *q;
-
- if ((NULL == s) || ('\0' == *s)) {
- return (NULL);
- }
-
- for (p=(char *)s, q=p+1; (*p != '\0') && (*q != '\0'); p+=2, q+=2) {
- char tmp;
-
- tmp = *p;
- *p = *q;
- *q = tmp;
- }
-
- return (char *) s;
-}
-#endif
-
#ifndef __HAVE_ARCH_MEMSET
/**
* memset - Fill a region of memory with the given value