diff options
Diffstat (limited to 'kernel')
-rw-r--r-- | kernel/kallsyms.c | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/kernel/kallsyms.c b/kernel/kallsyms.c index 1627f8d6e0cd..13bcec151b57 100644 --- a/kernel/kallsyms.c +++ b/kernel/kallsyms.c | |||
@@ -46,6 +46,14 @@ static inline int is_kernel_inittext(unsigned long addr) | |||
46 | return 0; | 46 | return 0; |
47 | } | 47 | } |
48 | 48 | ||
49 | static inline int is_kernel_extratext(unsigned long addr) | ||
50 | { | ||
51 | if (addr >= (unsigned long)_sextratext | ||
52 | && addr <= (unsigned long)_eextratext) | ||
53 | return 1; | ||
54 | return 0; | ||
55 | } | ||
56 | |||
49 | static inline int is_kernel_text(unsigned long addr) | 57 | static inline int is_kernel_text(unsigned long addr) |
50 | { | 58 | { |
51 | if (addr >= (unsigned long)_stext && addr <= (unsigned long)_etext) | 59 | if (addr >= (unsigned long)_stext && addr <= (unsigned long)_etext) |
@@ -169,8 +177,9 @@ const char *kallsyms_lookup(unsigned long addr, | |||
169 | namebuf[0] = 0; | 177 | namebuf[0] = 0; |
170 | 178 | ||
171 | if ((all_var && is_kernel(addr)) || | 179 | if ((all_var && is_kernel(addr)) || |
172 | (!all_var && (is_kernel_text(addr) || is_kernel_inittext(addr)))) { | 180 | (!all_var && (is_kernel_text(addr) || is_kernel_inittext(addr) || |
173 | unsigned long symbol_end=0; | 181 | is_kernel_extratext(addr)))) { |
182 | unsigned long symbol_end = 0; | ||
174 | 183 | ||
175 | /* do a binary search on the sorted kallsyms_addresses array */ | 184 | /* do a binary search on the sorted kallsyms_addresses array */ |
176 | low = 0; | 185 | low = 0; |