aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/kallsyms.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/linux/kallsyms.h')
-rw-r--r--include/linux/kallsyms.h26
1 files changed, 8 insertions, 18 deletions
diff --git a/include/linux/kallsyms.h b/include/linux/kallsyms.h
index 00c1801099fa..f3fe34391d8e 100644
--- a/include/linux/kallsyms.h
+++ b/include/linux/kallsyms.h
@@ -6,6 +6,7 @@
6#define _LINUX_KALLSYMS_H 6#define _LINUX_KALLSYMS_H
7 7
8#include <linux/errno.h> 8#include <linux/errno.h>
9#include <linux/kernel.h>
9#include <linux/stddef.h> 10#include <linux/stddef.h>
10 11
11#define KSYM_NAME_LEN 128 12#define KSYM_NAME_LEN 128
@@ -92,12 +93,10 @@ static inline void print_symbol(const char *fmt, unsigned long addr)
92} 93}
93 94
94/* 95/*
95 * Pretty-print a function pointer. 96 * Pretty-print a function pointer. This function is deprecated.
96 * 97 * Please use the "%pF" vsprintf format instead.
97 * ia64 and ppc64 function pointers are really function descriptors,
98 * which contain a pointer the real address.
99 */ 98 */
100static inline void print_fn_descriptor_symbol(const char *fmt, void *addr) 99static inline void __deprecated print_fn_descriptor_symbol(const char *fmt, void *addr)
101{ 100{
102#if defined(CONFIG_IA64) || defined(CONFIG_PPC64) 101#if defined(CONFIG_IA64) || defined(CONFIG_PPC64)
103 addr = *(void **)addr; 102 addr = *(void **)addr;
@@ -105,18 +104,9 @@ static inline void print_fn_descriptor_symbol(const char *fmt, void *addr)
105 print_symbol(fmt, (unsigned long)addr); 104 print_symbol(fmt, (unsigned long)addr);
106} 105}
107 106
108#ifndef CONFIG_64BIT 107static inline void print_ip_sym(unsigned long ip)
109#define print_ip_sym(ip) \ 108{
110do { \ 109 printk("[<%p>] %pS\n", (void *) ip, (void *) ip);
111 printk("[<%08lx>]", ip); \ 110}
112 print_symbol(" %s\n", ip); \
113} while(0)
114#else
115#define print_ip_sym(ip) \
116do { \
117 printk("[<%016lx>]", ip); \
118 print_symbol(" %s\n", ip); \
119} while(0)
120#endif
121 111
122#endif /*_LINUX_KALLSYMS_H*/ 112#endif /*_LINUX_KALLSYMS_H*/