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 <mich...@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

_______________________________________________
Linuxppc-dev mailing list
Linuxppc-dev@lists.ozlabs.org
https://lists.ozlabs.org/listinfo/linuxppc-dev

Reply via email to