diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2015-04-15 14:19:18 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2015-04-15 14:19:18 -0400 |
commit | b422b75875a3663f08a9ab5aeb265ed2383cbe2f (patch) | |
tree | 33e1ca04314539fd448f8f199839279798c1c163 /scripts | |
parent | d488d3a4ce08e96dad5cb3b6117517d57ccec98f (diff) | |
parent | 41b585b2ed793db6f02ec87d0026d73382e8180a (diff) |
Merge branch 'kbuild' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild
Pull kbuild updates from Michal Marek:
"Here is the first round of kbuild changes for v4.1-rc1:
- kallsyms fix for ARM and cleanup
- make dep(end) removed (developers have no sense of nostalgia these
days...)
- include Makefiles by relative path
- stop useless rebuilds of asm-offsets.h and bounds.h"
* 'kbuild' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild:
Kbuild: kallsyms: drop special handling of pre-3.0 GCC symbols
Kbuild: kallsyms: ignore veneers emitted by the ARM linker
kbuild: ia64: use $(src)/Makefile.gate rather than particular path
kbuild: include $(src)/Makefile rather than $(obj)/Makefile
kbuild: use relative path more to include Makefile
kbuild: use relative path to include Makefile
kbuild: do not add $(bounds-file) and $(offsets-file) to targets
kbuild: remove warning about "make depend"
kbuild: Don't reset timestamps in include/generated if not needed
Diffstat (limited to 'scripts')
-rw-r--r-- | scripts/Makefile.dtbinst | 2 | ||||
-rw-r--r-- | scripts/Makefile.fwinst | 2 | ||||
-rw-r--r-- | scripts/kallsyms.c | 29 |
3 files changed, 22 insertions, 11 deletions
diff --git a/scripts/Makefile.dtbinst b/scripts/Makefile.dtbinst index 909ed7a2ac61..1c15717e0d56 100644 --- a/scripts/Makefile.dtbinst +++ b/scripts/Makefile.dtbinst | |||
@@ -18,7 +18,7 @@ export dtbinst-root ?= $(obj) | |||
18 | 18 | ||
19 | include include/config/auto.conf | 19 | include include/config/auto.conf |
20 | include scripts/Kbuild.include | 20 | include scripts/Kbuild.include |
21 | include $(srctree)/$(obj)/Makefile | 21 | include $(src)/Makefile |
22 | 22 | ||
23 | PHONY += __dtbs_install_prep | 23 | PHONY += __dtbs_install_prep |
24 | __dtbs_install_prep: | 24 | __dtbs_install_prep: |
diff --git a/scripts/Makefile.fwinst b/scripts/Makefile.fwinst index 5b698add4f31..b27290035253 100644 --- a/scripts/Makefile.fwinst +++ b/scripts/Makefile.fwinst | |||
@@ -13,7 +13,7 @@ src := $(obj) | |||
13 | -include $(objtree)/.config | 13 | -include $(objtree)/.config |
14 | 14 | ||
15 | include scripts/Kbuild.include | 15 | include scripts/Kbuild.include |
16 | include $(srctree)/$(obj)/Makefile | 16 | include $(src)/Makefile |
17 | 17 | ||
18 | include scripts/Makefile.host | 18 | include scripts/Makefile.host |
19 | 19 | ||
diff --git a/scripts/kallsyms.c b/scripts/kallsyms.c index c6d33bd15b04..8fa81e84e295 100644 --- a/scripts/kallsyms.c +++ b/scripts/kallsyms.c | |||
@@ -212,15 +212,22 @@ static int symbol_valid(struct sym_entry *s) | |||
212 | "_SDA_BASE_", /* ppc */ | 212 | "_SDA_BASE_", /* ppc */ |
213 | "_SDA2_BASE_", /* ppc */ | 213 | "_SDA2_BASE_", /* ppc */ |
214 | NULL }; | 214 | NULL }; |
215 | |||
216 | static char *special_suffixes[] = { | ||
217 | "_veneer", /* arm */ | ||
218 | NULL }; | ||
219 | |||
215 | int i; | 220 | int i; |
216 | int offset = 1; | 221 | char *sym_name = (char *)s->sym + 1; |
222 | |||
217 | 223 | ||
218 | if (s->addr < kernel_start_addr) | 224 | if (s->addr < kernel_start_addr) |
219 | return 0; | 225 | return 0; |
220 | 226 | ||
221 | /* skip prefix char */ | 227 | /* skip prefix char */ |
222 | if (symbol_prefix_char && *(s->sym + 1) == symbol_prefix_char) | 228 | if (symbol_prefix_char && *sym_name == symbol_prefix_char) |
223 | offset++; | 229 | sym_name++; |
230 | |||
224 | 231 | ||
225 | /* if --all-symbols is not specified, then symbols outside the text | 232 | /* if --all-symbols is not specified, then symbols outside the text |
226 | * and inittext sections are discarded */ | 233 | * and inittext sections are discarded */ |
@@ -235,22 +242,26 @@ static int symbol_valid(struct sym_entry *s) | |||
235 | * rules. | 242 | * rules. |
236 | */ | 243 | */ |
237 | if ((s->addr == text_range_text->end && | 244 | if ((s->addr == text_range_text->end && |
238 | strcmp((char *)s->sym + offset, | 245 | strcmp(sym_name, |
239 | text_range_text->end_sym)) || | 246 | text_range_text->end_sym)) || |
240 | (s->addr == text_range_inittext->end && | 247 | (s->addr == text_range_inittext->end && |
241 | strcmp((char *)s->sym + offset, | 248 | strcmp(sym_name, |
242 | text_range_inittext->end_sym))) | 249 | text_range_inittext->end_sym))) |
243 | return 0; | 250 | return 0; |
244 | } | 251 | } |
245 | 252 | ||
246 | /* Exclude symbols which vary between passes. */ | 253 | /* Exclude symbols which vary between passes. */ |
247 | if (strstr((char *)s->sym + offset, "_compiled.")) | ||
248 | return 0; | ||
249 | |||
250 | for (i = 0; special_symbols[i]; i++) | 254 | for (i = 0; special_symbols[i]; i++) |
251 | if( strcmp((char *)s->sym + offset, special_symbols[i]) == 0 ) | 255 | if (strcmp(sym_name, special_symbols[i]) == 0) |
252 | return 0; | 256 | return 0; |
253 | 257 | ||
258 | for (i = 0; special_suffixes[i]; i++) { | ||
259 | int l = strlen(sym_name) - strlen(special_suffixes[i]); | ||
260 | |||
261 | if (l >= 0 && strcmp(sym_name + l, special_suffixes[i]) == 0) | ||
262 | return 0; | ||
263 | } | ||
264 | |||
254 | return 1; | 265 | return 1; |
255 | } | 266 | } |
256 | 267 | ||