]> asedeno.scripts.mit.edu Git - linux.git/blobdiff - arch/x86/boot/string.c
Merge branches 'pm-core', 'pm-qos', 'pm-domains' and 'pm-opp'
[linux.git] / arch / x86 / boot / string.c
index 9e240fcba784b085bd55e77dc79c08d21d1a23e2..5457b02fc05077b69ada23565bb54026aca09c0a 100644 (file)
@@ -156,3 +156,16 @@ char *strstr(const char *s1, const char *s2)
        }
        return NULL;
 }
+
+/**
+ * strchr - Find the first occurrence of the character c in the string s.
+ * @s: the string to be searched
+ * @c: the character to search for
+ */
+char *strchr(const char *s, int c)
+{
+       while (*s != (char)c)
+               if (*s++ == '\0')
+                       return NULL;
+       return (char *)s;
+}