mirror of
https://github.com/Fishwaldo/Star64_linux.git
synced 2025-07-02 20:29:20 +00:00
Simplify kallsyms_lookup()
Several kallsyms_lookup() pass dummy arguments but only need, say, module's name. Make kallsyms_lookup() accept NULLs where possible. Also, makes picture clearer about what interfaces are needed for all symbol resolving business. Signed-off-by: Alexey Dobriyan <adobriyan@sw.ru> Cc: Rusty Russell <rusty@rustcorp.com.au> Acked-by: Ingo Molnar <mingo@elte.hu> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
This commit is contained in:
parent
ea07890a68
commit
ffb4512276
10 changed files with 20 additions and 28 deletions
|
@ -868,13 +868,13 @@ static int __kprobes show_kprobe_addr(struct seq_file *pi, void *v)
|
|||
struct kprobe *p, *kp;
|
||||
const char *sym = NULL;
|
||||
unsigned int i = *(loff_t *) v;
|
||||
unsigned long size, offset = 0;
|
||||
unsigned long offset = 0;
|
||||
char *modname, namebuf[128];
|
||||
|
||||
head = &kprobe_table[i];
|
||||
preempt_disable();
|
||||
hlist_for_each_entry_rcu(p, node, head, hlist) {
|
||||
sym = kallsyms_lookup((unsigned long)p->addr, &size,
|
||||
sym = kallsyms_lookup((unsigned long)p->addr, NULL,
|
||||
&offset, &modname, namebuf);
|
||||
if (p->pre_handler == aggr_pre_handler) {
|
||||
list_for_each_entry_rcu(kp, &p->list, list)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue