summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--dwflpp.cxx16
-rw-r--r--dwflpp.h5
-rw-r--r--tapsets.cxx6
3 files changed, 6 insertions, 21 deletions
diff --git a/dwflpp.cxx b/dwflpp.cxx
index d55852ee..650acb70 100644
--- a/dwflpp.cxx
+++ b/dwflpp.cxx
@@ -2302,13 +2302,13 @@ dwflpp::blacklisted_p(const string& funcname,
const string& filename,
int,
const string& module,
- const string& section,
Dwarf_Addr addr,
bool has_return)
{
if (!blacklist_enabled)
return false; // no blacklist for userspace
+ string section = get_blacklist_section(addr);
if (section.substr(0, 6) == string(".init.") ||
section.substr(0, 6) == string(".exit.") ||
section.substr(0, 9) == string(".devinit.") ||
@@ -2533,9 +2533,7 @@ dwflpp::get_blacklist_section(Dwarf_Addr addr)
Dwarf_Addr
-dwflpp::relocate_address(Dwarf_Addr dw_addr,
- string& reloc_section,
- string& blacklist_section)
+dwflpp::relocate_address(Dwarf_Addr dw_addr, string& reloc_section)
{
// PR10273
// libdw address, so adjust for bias gotten from dwfl_module_getdwarf
@@ -2544,7 +2542,6 @@ dwflpp::relocate_address(Dwarf_Addr dw_addr,
{
assert(module_name == TOK_KERNEL);
reloc_section = "";
- blacklist_section = "";
}
else if (dwfl_module_relocations (module) > 0)
{
@@ -2554,19 +2551,12 @@ dwflpp::relocate_address(Dwarf_Addr dw_addr,
const char* r_s = dwfl_module_relocation_info (module, idx, NULL);
if (r_s)
reloc_section = r_s;
- blacklist_section = reloc_section;
if (reloc_section == "" && dwfl_module_relocations (module) == 1)
- {
- blacklist_section = get_blacklist_section(dw_addr);
reloc_section = ".dynamic";
- }
}
else
- {
- blacklist_section = get_blacklist_section(dw_addr);
- reloc_section = ".absolute";
- }
+ reloc_section = ".absolute";
return reloc_addr;
}
diff --git a/dwflpp.h b/dwflpp.h
index 34531071..ea14bb87 100644
--- a/dwflpp.h
+++ b/dwflpp.h
@@ -268,13 +268,10 @@ struct dwflpp
const std::string& filename,
int line,
const std::string& module,
- const std::string& section,
Dwarf_Addr addr,
bool has_return);
- Dwarf_Addr relocate_address(Dwarf_Addr addr,
- std::string& reloc_section,
- std::string& blacklist_section);
+ Dwarf_Addr relocate_address(Dwarf_Addr addr, std::string& reloc_section);
Dwarf_Addr literal_addr_to_sym_addr(Dwarf_Addr lit_addr);
diff --git a/tapsets.cxx b/tapsets.cxx
index 15491d55..e0768868 100644
--- a/tapsets.cxx
+++ b/tapsets.cxx
@@ -965,12 +965,11 @@ dwarf_query::add_probe_point(const string& funcname,
{
string reloc_section; // base section for relocation purposes
Dwarf_Addr reloc_addr; // relocated
- string blacklist_section; // linking section for blacklist purposes
const string& module = dw.module_name; // "kernel" or other
assert (! has_absolute); // already handled in dwarf_builder::build()
- reloc_addr = dw.relocate_address(addr, reloc_section, blacklist_section);
+ reloc_addr = dw.relocate_address(addr, reloc_section);
if (sess.verbose > 1)
{
@@ -982,12 +981,11 @@ dwarf_query::add_probe_point(const string& funcname,
else if (has_process)
clog << " process=" << module;
if (reloc_section != "") clog << " reloc=" << reloc_section;
- if (blacklist_section != "") clog << " section=" << blacklist_section;
clog << " pc=0x" << hex << addr << dec;
}
bool bad = dw.blacklisted_p (funcname, filename, line, module,
- blacklist_section, addr, has_return);
+ addr, has_return);
if (sess.verbose > 1)
clog << endl;