From: Bryan Wu <bryan.wu@analog.com>
To: linux-kernel@vger.kernel.org
Cc: Robin Getz <robin.getz@analog.com>, Bryan Wu <bryan.wu@analog.com>
Subject: [PATCH 1/1] [Kallsyms] Blackfin: Allow kernel symbols in L1 to be found
Date: Wed, 30 Jan 2008 18:20:53 +0800 [thread overview]
Message-ID: <1201688453-1763-1-git-send-email-bryan.wu@analog.com> (raw)
From: Robin Getz <robin.getz@analog.com>
Signed-off-by: Robin Getz <robin.getz@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
---
kernel/kallsyms.c | 6 +++++-
scripts/kallsyms.c | 10 +++++++++-
2 files changed, 14 insertions(+), 2 deletions(-)
diff --git a/kernel/kallsyms.c b/kernel/kallsyms.c
index 7dadc71..714bd5b 100644
--- a/kernel/kallsyms.c
+++ b/kernel/kallsyms.c
@@ -63,7 +63,11 @@ static inline int is_kernel_extratext(unsigned long addr)
static inline int is_kernel_text(unsigned long addr)
{
- if (addr >= (unsigned long)_stext && addr <= (unsigned long)_etext)
+ if ((addr >= (unsigned long)_stext && addr <= (unsigned long)_etext)
+#if defined(CONFIG_BLACKFIN)
+ || (addr >= (unsigned long)_stext_l1 && addr <= (unsigned long)_etext_l1)
+#endif
+ )
return 1;
return in_gate_area_no_task(addr);
}
diff --git a/scripts/kallsyms.c b/scripts/kallsyms.c
index 1f11d84..8775981 100644
--- a/scripts/kallsyms.c
+++ b/scripts/kallsyms.c
@@ -12,6 +12,8 @@
* (25/Aug/2004) Paulo Marques <pmarques@grupopie.com>
* Changed the compression method from stem compression to "table lookup"
* compression
+ * (10/Jul/2006) Robin Getz <rgetz@blackfin.uclinux.org>
+ * Add _stext_l1, _etext_l1 for the L1 memory section in Blackfin.
*
* Table compression uses all the unused char codes on the symbols and
* maps these to the most used substrings (tokens). For instance, it might
@@ -42,6 +44,7 @@ struct sym_entry {
static struct sym_entry *table;
static unsigned int table_size, table_cnt;
static unsigned long long _text, _stext, _etext, _sinittext, _einittext, _sextratext, _eextratext;
+static unsigned long long _stext_l1, _etext_l1;
static int all_symbols = 0;
static char symbol_prefix_char = '\0';
@@ -103,6 +106,10 @@ static int read_symbol(FILE *in, struct sym_entry *s)
_sextratext = s->addr;
else if (strcmp(sym, "_eextratext") == 0)
_eextratext = s->addr;
+ else if (strcmp(sym, "_stext_l1" ) == 0)
+ _stext_l1 = s->addr;
+ else if (strcmp(sym, "_etext_l1" ) == 0)
+ _etext_l1 = s->addr;
else if (toupper(stype) == 'A')
{
/* Keep these useful absolute symbols */
@@ -166,7 +173,8 @@ static int symbol_valid(struct sym_entry *s)
if (!all_symbols) {
if ((s->addr < _stext || s->addr > _etext)
&& (s->addr < _sinittext || s->addr > _einittext)
- && (s->addr < _sextratext || s->addr > _eextratext))
+ && (s->addr < _sextratext || s->addr > _eextratext)
+ && (s->addr < _stext_l1 || s->addr > _etext_l1))
return 0;
/* Corner case. Discard any symbols with the same value as
* _etext _einittext or _eextratext; they can move between pass
--
1.5.3.4
next reply other threads:[~2008-01-30 10:23 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-01-30 10:20 Bryan Wu [this message]
2008-01-30 11:17 ` Paulo Marques
2008-01-30 17:27 ` Bryan Wu
2008-01-30 17:48 ` [PATCH 1/1 try #2] " Bryan Wu
2008-01-30 17:49 ` [PATCH] [Scripts] kallsyms: Nuke all ChangeLog, this should be logged by git Bryan Wu
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1201688453-1763-1-git-send-email-bryan.wu@analog.com \
--to=bryan.wu@analog.com \
--cc=linux-kernel@vger.kernel.org \
--cc=robin.getz@analog.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Powered by JetHome