linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] FRV: Fix the extern declaration of kallsyms_num_syms
@ 2007-11-06 21:48 David Howells
  2007-11-09 19:52 ` Andrew Morton
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: David Howells @ 2007-11-06 21:48 UTC (permalink / raw)
  To: torvalds, akpm, jdi; +Cc: linux-kernel, dhowells

From: David Howells <dhowells@redhat.com>

Fix the extern declaration of kallsyms_num_syms to indicate that the symbol
does not reside in the small-data storage space, and so may not be accessed
relative to the small data base register.

Signed-off-by: David Howells <dhowells@redhat.com>
---

 kernel/kallsyms.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/kernel/kallsyms.c b/kernel/kallsyms.c
index 474219a..fa84b83 100644
--- a/kernel/kallsyms.c
+++ b/kernel/kallsyms.c
@@ -32,7 +32,8 @@
 
 /* These will be re-linked against their real values during the second link stage */
 extern const unsigned long kallsyms_addresses[] __attribute__((weak));
-extern const unsigned long kallsyms_num_syms __attribute__((weak));
+extern const unsigned long kallsyms_num_syms
+__nongpreldata __attribute__((weak));
 extern const u8 kallsyms_names[] __attribute__((weak));
 
 extern const u8 kallsyms_token_table[] __attribute__((weak));


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH] FRV: Fix the extern declaration of kallsyms_num_syms
  2007-11-06 21:48 [PATCH] FRV: Fix the extern declaration of kallsyms_num_syms David Howells
@ 2007-11-09 19:52 ` Andrew Morton
  2007-11-13 15:44 ` David Howells
  2007-11-13 17:01 ` David Howells
  2 siblings, 0 replies; 4+ messages in thread
From: Andrew Morton @ 2007-11-09 19:52 UTC (permalink / raw)
  To: David Howells; +Cc: torvalds, jdi, linux-kernel, dhowells

On Tue, 06 Nov 2007 21:48:20 +0000
David Howells <dhowells@redhat.com> wrote:

> From: David Howells <dhowells@redhat.com>
> 
> Fix the extern declaration of kallsyms_num_syms to indicate that the symbol
> does not reside in the small-data storage space, and so may not be accessed
> relative to the small data base register.
> 
> Signed-off-by: David Howells <dhowells@redhat.com>
> ---
> 
>  kernel/kallsyms.c |    3 ++-
>  1 files changed, 2 insertions(+), 1 deletions(-)
> 
> diff --git a/kernel/kallsyms.c b/kernel/kallsyms.c
> index 474219a..fa84b83 100644
> --- a/kernel/kallsyms.c
> +++ b/kernel/kallsyms.c
> @@ -32,7 +32,8 @@
>  
>  /* These will be re-linked against their real values during the second link stage */
>  extern const unsigned long kallsyms_addresses[] __attribute__((weak));
> -extern const unsigned long kallsyms_num_syms __attribute__((weak));
> +extern const unsigned long kallsyms_num_syms
> +__nongpreldata __attribute__((weak));

umm, this makes Linux an frv-only operating system...

>  extern const u8 kallsyms_names[] __attribute__((weak));
>  
>  extern const u8 kallsyms_token_table[] __attribute__((weak));

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] FRV: Fix the extern declaration of kallsyms_num_syms
  2007-11-06 21:48 [PATCH] FRV: Fix the extern declaration of kallsyms_num_syms David Howells
  2007-11-09 19:52 ` Andrew Morton
@ 2007-11-13 15:44 ` David Howells
  2007-11-13 17:01 ` David Howells
  2 siblings, 0 replies; 4+ messages in thread
From: David Howells @ 2007-11-13 15:44 UTC (permalink / raw)
  To: Andrew Morton; +Cc: dhowells, torvalds, jdi, linux-kernel

Andrew Morton <akpm@linux-foundation.org> wrote:

> > +extern const unsigned long kallsyms_num_syms
> > +__nongpreldata __attribute__((weak));
> 
> umm, this makes Linux an frv-only operating system...

Oops.  Well... is there any other CPU?  Apart from MN10300, that is... :-)

I remember I had to fix a bunch of things like this before... I wonder how I
did it...

David


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] FRV: Fix the extern declaration of kallsyms_num_syms
  2007-11-06 21:48 [PATCH] FRV: Fix the extern declaration of kallsyms_num_syms David Howells
  2007-11-09 19:52 ` Andrew Morton
  2007-11-13 15:44 ` David Howells
@ 2007-11-13 17:01 ` David Howells
  2 siblings, 0 replies; 4+ messages in thread
From: David Howells @ 2007-11-13 17:01 UTC (permalink / raw)
  Cc: dhowells, Andrew Morton, torvalds, jdi, linux-kernel

David Howells <dhowells@redhat.com> wrote:

> > > +extern const unsigned long kallsyms_num_syms
> > > +__nongpreldata __attribute__((weak));

Rather than using __nongpreldata, I should be able to say that it's in
.rodata - which seems to be more correct anyway - and throw into a comment to
say why.

I can't quite work out, though, how the kernel build stuff gets the datum into
the kernel build.  I can see there's a script, but I never see the output of
the script crop up anywhere in the build tree:-/  GDB reports, though, that
kallsyms_num_syms gets the right value.

David

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2007-11-13 17:02 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-11-06 21:48 [PATCH] FRV: Fix the extern declaration of kallsyms_num_syms David Howells
2007-11-09 19:52 ` Andrew Morton
2007-11-13 15:44 ` David Howells
2007-11-13 17:01 ` David Howells

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).