diff options
author | Takashi Iwai <tiwai@suse.de> | 2013-11-08 16:45:38 +0100 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2013-11-08 16:45:38 +0100 |
commit | a6bc732b5a96b5403c2637e85c350b95ec6591f3 (patch) | |
tree | 4b1c3967cd1de42a5e36e567cbdd18e1f4e8446f /scripts/kallsyms.c | |
parent | 9a22a8f558d09a83965d2bbe168294eb8ffb70e9 (diff) | |
parent | dd212bd5bb8b15889821ef79213cdb5bd47c6f85 (diff) |
Merge tag 'asoc-v3.13-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into for-linussound-3.13-rc1
ASoC: Updates for v3.13
Some additional fixes for v3.13, the majority of which are removals and
downgrades of BUG()s from Takashi.
Diffstat (limited to 'scripts/kallsyms.c')
-rw-r--r-- | scripts/kallsyms.c | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/scripts/kallsyms.c b/scripts/kallsyms.c index 487ac6f37ca2..9a11f9f799f4 100644 --- a/scripts/kallsyms.c +++ b/scripts/kallsyms.c @@ -55,6 +55,7 @@ static struct sym_entry *table; static unsigned int table_size, table_cnt; static int all_symbols = 0; static char symbol_prefix_char = '\0'; +static unsigned long long kernel_start_addr = 0; int token_profit[0x10000]; @@ -65,7 +66,10 @@ unsigned char best_table_len[256]; static void usage(void) { - fprintf(stderr, "Usage: kallsyms [--all-symbols] [--symbol-prefix=<prefix char>] < in.map > out.S\n"); + fprintf(stderr, "Usage: kallsyms [--all-symbols] " + "[--symbol-prefix=<prefix char>] " + "[--page-offset=<CONFIG_PAGE_OFFSET>] " + "< in.map > out.S\n"); exit(1); } @@ -194,6 +198,9 @@ static int symbol_valid(struct sym_entry *s) int i; int offset = 1; + if (s->addr < kernel_start_addr) + return 0; + /* skip prefix char */ if (symbol_prefix_char && *(s->sym + 1) == symbol_prefix_char) offset++; @@ -646,6 +653,9 @@ int main(int argc, char **argv) if ((*p == '"' && *(p+2) == '"') || (*p == '\'' && *(p+2) == '\'')) p++; symbol_prefix_char = *p; + } else if (strncmp(argv[i], "--page-offset=", 14) == 0) { + const char *p = &argv[i][14]; + kernel_start_addr = strtoull(p, NULL, 16); } else usage(); } |