aboutsummaryrefslogtreecommitdiffstats
path: root/tools/fops_probe
diff options
context:
space:
mode:
authorDmitry Vyukov <dvyukov@google.com>2020-06-11 22:10:07 +0200
committerDmitry Vyukov <dvyukov@google.com>2020-06-11 23:19:34 +0200
commit588020678f34b89925fcfbcaf8f635c5850e8e7a (patch)
tree0d0467180954d05e261681124088a1025f90cc58 /tools/fops_probe
parent829fd56fbf6fc9243f8ac969c7c58172e5adcb45 (diff)
all: use more respective language
Some terms are normalised on the technical level but may be oppressive on a societal level. Replace them with more technically neutral terms. See the following doc for a longer version: https://tools.ietf.org/id/draft-knodel-terminology-00.html
Diffstat (limited to 'tools/fops_probe')
-rw-r--r--tools/fops_probe/fops_probe.cc12
1 files changed, 6 insertions, 6 deletions
diff --git a/tools/fops_probe/fops_probe.cc b/tools/fops_probe/fops_probe.cc
index c3c3332a6..1cbe886c1 100644
--- a/tools/fops_probe/fops_probe.cc
+++ b/tools/fops_probe/fops_probe.cc
@@ -55,7 +55,7 @@ typedef std::map<long long, std::string> kallsyms_map_t;
static __attribute__((noreturn)) __attribute__((format(printf, 1, 2))) void failf(const char* msg, ...);
static kallsyms_map_t read_kallsyms();
-static bool is_blacklisted(const std::string& sym);
+static bool should_skip(const std::string& sym);
static void probe_callback(uint64_t* cover, const kallsyms_map_t& kallsyms,
const std::string& start_sym, std::function<void(void)> fn);
@@ -102,16 +102,16 @@ void probe_callback(uint64_t* cover, const kallsyms_map_t& kallsyms,
if (!started && sym != start_sym)
continue;
started = true;
- if (!seen.insert(sym).second || is_blacklisted(sym))
+ if (!seen.insert(sym).second || should_skip(sym))
continue;
printf("%0llx %s\n", pc, sym.c_str());
}
printf("\n");
}
-bool is_blacklisted(const std::string& sym)
+bool should_skip(const std::string& sym)
{
- static const char* blacklist[] = {
+ static const char* skip[] = {
"security",
"tomoyo",
"selinux",
@@ -125,8 +125,8 @@ bool is_blacklisted(const std::string& sym)
"snprintf",
"vsnprintf",
};
- for (size_t i = 0; i < sizeof(blacklist) / sizeof(blacklist[0]); i++) {
- if (!strncmp(sym.c_str(), blacklist[i], strlen(blacklist[i])))
+ for (size_t i = 0; i < sizeof(skip) / sizeof(skip[0]); i++) {
+ if (!strncmp(sym.c_str(), skip[i], strlen(skip[i])))
return true;
}
return false;