aboutsummaryrefslogtreecommitdiffstats
path: root/tools/include
diff options
context:
space:
mode:
authorArnaldo Carvalho de Melo <acme@redhat.com>2017-04-26 15:49:21 -0300
committerArnaldo Carvalho de Melo <acme@redhat.com>2017-04-26 15:49:21 -0300
commit96395cbbc7e94cbbe4f76cf64cf122fabc19123d (patch)
treec0cf51cd06c2b98bf45ef786f88c9b662c6645e8 /tools/include
parentperf units: Move parse_tag_value() to units.[ch] (diff)
downloadlinux-dev-96395cbbc7e94cbbe4f76cf64cf122fabc19123d.tar.xz
linux-dev-96395cbbc7e94cbbe4f76cf64cf122fabc19123d.zip
tools lib string: Adopt prefixcmp() from perf and subcmd
Both had copies originating from git.git, move those to tools/lib/string.c, getting both tools/lib/subcmd/ and tools/perf/ to use it. Cc: Adrian Hunter <adrian.hunter@intel.com> Cc: David Ahern <dsahern@gmail.com> Cc: Jiri Olsa <jolsa@kernel.org> Cc: Josh Poimboeuf <jpoimboe@redhat.com> Cc: Namhyung Kim <namhyung@kernel.org> Cc: Wang Nan <wangnan0@huawei.com> Link: http://lkml.kernel.org/n/tip-uidwtticro1qhttzd2rkrkg1@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'tools/include')
-rw-r--r--tools/include/linux/string.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/tools/include/linux/string.h b/tools/include/linux/string.h
index f436d2420a18..d62b56cf8c12 100644
--- a/tools/include/linux/string.h
+++ b/tools/include/linux/string.h
@@ -18,4 +18,6 @@ extern size_t strlcpy(char *dest, const char *src, size_t size);
char *str_error_r(int errnum, char *buf, size_t buflen);
+int prefixcmp(const char *str, const char *prefix);
+
#endif /* _LINUX_STRING_H_ */