diff options
author | Alexey Dobriyan <adobriyan@sw.ru> | 2007-05-08 03:28:41 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-05-08 14:15:08 -0400 |
commit | ffb45122766db220d0bf3d01848d575fbbcb6430 (patch) | |
tree | a8fedf0518407ad12578a7c03aa2c3344f11ff3c /arch/sh64 | |
parent | ea07890a680273b25127129fb555aac0d9324bea (diff) |
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>
Diffstat (limited to 'arch/sh64')
-rw-r--r-- | arch/sh64/kernel/unwind.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/arch/sh64/kernel/unwind.c b/arch/sh64/kernel/unwind.c index f934f97f9f9c..1214c78e3584 100644 --- a/arch/sh64/kernel/unwind.c +++ b/arch/sh64/kernel/unwind.c | |||
@@ -46,15 +46,15 @@ static int lookup_prev_stack_frame(unsigned long fp, unsigned long pc, | |||
46 | struct pt_regs *regs) | 46 | struct pt_regs *regs) |
47 | { | 47 | { |
48 | const char *sym; | 48 | const char *sym; |
49 | char *modname, namebuf[128]; | 49 | char namebuf[128]; |
50 | unsigned long offset, size; | 50 | unsigned long offset; |
51 | unsigned long prologue = 0; | 51 | unsigned long prologue = 0; |
52 | unsigned long fp_displacement = 0; | 52 | unsigned long fp_displacement = 0; |
53 | unsigned long fp_prev = 0; | 53 | unsigned long fp_prev = 0; |
54 | unsigned long offset_r14 = 0, offset_r18 = 0; | 54 | unsigned long offset_r14 = 0, offset_r18 = 0; |
55 | int i, found_prologue_end = 0; | 55 | int i, found_prologue_end = 0; |
56 | 56 | ||
57 | sym = kallsyms_lookup(pc, &size, &offset, &modname, namebuf); | 57 | sym = kallsyms_lookup(pc, NULL, &offset, NULL, namebuf); |
58 | if (!sym) | 58 | if (!sym) |
59 | return -EINVAL; | 59 | return -EINVAL; |
60 | 60 | ||