summaryrefslogtreecommitdiffstats
path: root/kernel/pid.c
diff options
context:
space:
mode:
authorSteven Rostedt (VMware) <rostedt@goodmis.org>2018-12-20 04:38:21 +0100
committerSteven Rostedt (VMware) <rostedt@goodmis.org>2018-12-23 04:51:01 +0100
commit754481e6954cbef53f8bc4412ad48dde611e21d3 (patch)
tree311427797eae5dfd56859c4d80edabe0afe8800e /kernel/pid.c
parentstring.h: Add str_has_prefix() helper function (diff)
downloadlinux-754481e6954cbef53f8bc4412ad48dde611e21d3.tar.xz
linux-754481e6954cbef53f8bc4412ad48dde611e21d3.zip
tracing: Use str_has_prefix() helper for histogram code
The tracing histogram code contains a lot of instances of the construct: strncmp(str, "const", sizeof("const") - 1) This can be prone to bugs due to typos or bad cut and paste. Use the str_has_prefix() helper macro instead that removes the need for having two copies of the constant string. Cc: Tom Zanussi <tom.zanussi@linux.intel.com> Acked-by: Namhyung Kim <namhyung@kernel.org> Signed-off-by: Steven Rostedt (VMware) <rostedt@goodmis.org>
Diffstat (limited to 'kernel/pid.c')
0 files changed, 0 insertions, 0 deletions