aboutsummaryrefslogtreecommitdiffstats
path: root/arch/powerpc/boot/flatdevtree_env.h
diff options
context:
space:
mode:
authorDavid Gibson <david@gibson.dropbear.id.au>2007-08-28 00:52:57 -0400
committerPaul Mackerras <paulus@samba.org>2007-09-13 11:33:19 -0400
commit0ae0b54565a8dcc2b98de694b998e765de15b713 (patch)
tree21bbfa5618d55460e2e90ef0e876b1c6c03b42f7 /arch/powerpc/boot/flatdevtree_env.h
parent768cc2d3b2768ca34f254e8190f1f9e297b09ad4 (diff)
[POWERPC] Move bootwrapper's strchr() and strncmp() from .h to string.S
Currently the bootwrapper has implementations of strchr() and strncmp(), but they're inlines in flatdevtree_env.h, rather than in string.S with all the rest of the string functions. This moves them to string.S. Signed-off-by: David Gibson <david@gibson.dropbear.id.au> Signed-off-by: Paul Mackerras <paulus@samba.org>
Diffstat (limited to 'arch/powerpc/boot/flatdevtree_env.h')
-rw-r--r--arch/powerpc/boot/flatdevtree_env.h20
1 files changed, 0 insertions, 20 deletions
diff --git a/arch/powerpc/boot/flatdevtree_env.h b/arch/powerpc/boot/flatdevtree_env.h
index 83bc1c718836..ad0420da8921 100644
--- a/arch/powerpc/boot/flatdevtree_env.h
+++ b/arch/powerpc/boot/flatdevtree_env.h
@@ -24,24 +24,4 @@
24#define be64_to_cpu(x) (x) 24#define be64_to_cpu(x) (x)
25#define cpu_to_be64(x) (x) 25#define cpu_to_be64(x) (x)
26 26
27static inline int strncmp(const char *cs, const char *ct, size_t count)
28{
29 signed char __res = 0;
30
31 while (count) {
32 if ((__res = *cs - *ct++) != 0 || !*cs++)
33 break;
34 count--;
35 }
36 return __res;
37}
38
39static inline char *strchr(const char *s, int c)
40{
41 for (; *s != (char)c; ++s)
42 if (*s == '\0')
43 return NULL;
44 return (char *)s;
45}
46
47#endif /* _PPC_BOOT_FLATDEVTREE_ENV_H_ */ 27#endif /* _PPC_BOOT_FLATDEVTREE_ENV_H_ */