[PATCH 18/20] powerpc/xmon: Use kallsyms_lookup_size_offset() in get_function_bounds()
Michael Ellerman
michael at ellerman.id.au
Wed Oct 10 01:20:45 EST 2012
We throw away the name so we should use kallsyms_lookup_size_offset(),
which does what we need and nothing more.
Signed-off-by: Michael Ellerman <michael at ellerman.id.au>
---
arch/powerpc/xmon/xmon.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/arch/powerpc/xmon/xmon.c b/arch/powerpc/xmon/xmon.c
index c6cd027..9eb1d34 100644
--- a/arch/powerpc/xmon/xmon.c
+++ b/arch/powerpc/xmon/xmon.c
@@ -1313,15 +1313,13 @@ static void get_function_bounds(unsigned long pc, unsigned long *startp,
unsigned long *endp)
{
unsigned long size, offset;
- const char *name;
*startp = *endp = 0;
if (pc == 0)
return;
if (start_bus_error_jump() == 0) {
- name = kallsyms_lookup(pc, &size, &offset, NULL, tmpstr);
- if (name != NULL) {
+ if (kallsyms_lookup_size_offset(pc, &size, &offset)) {
*startp = pc - offset;
*endp = pc - offset + size;
}
--
1.7.9.5
More information about the Linuxppc-dev
mailing list