diff options
Diffstat (limited to 'kernel/kallsyms.c')
-rw-r--r-- | kernel/kallsyms.c | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/kernel/kallsyms.c b/kernel/kallsyms.c index fed54418626c..0d662475dd9f 100644 --- a/kernel/kallsyms.c +++ b/kernel/kallsyms.c | |||
@@ -317,13 +317,12 @@ int sprint_symbol(char *buffer, unsigned long address) | |||
317 | name = kallsyms_lookup(address, &size, &offset, &modname, namebuf); | 317 | name = kallsyms_lookup(address, &size, &offset, &modname, namebuf); |
318 | if (!name) | 318 | if (!name) |
319 | return sprintf(buffer, "0x%lx", address); | 319 | return sprintf(buffer, "0x%lx", address); |
320 | else { | 320 | |
321 | if (modname) | 321 | if (modname) |
322 | return sprintf(buffer, "%s+%#lx/%#lx [%s]", name, offset, | 322 | return sprintf(buffer, "%s+%#lx/%#lx [%s]", name, offset, |
323 | size, modname); | 323 | size, modname); |
324 | else | 324 | else |
325 | return sprintf(buffer, "%s+%#lx/%#lx", name, offset, size); | 325 | return sprintf(buffer, "%s+%#lx/%#lx", name, offset, size); |
326 | } | ||
327 | } | 326 | } |
328 | 327 | ||
329 | /* Look up a kernel symbol and print it to the kernel messages. */ | 328 | /* Look up a kernel symbol and print it to the kernel messages. */ |