public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] per-cpu patch 1/3
@ 2002-07-18  3:46 Rusty Russell
  2002-07-22  3:00 ` Andrew Morton
  0 siblings, 1 reply; 3+ messages in thread
From: Rusty Russell @ 2002-07-18  3:46 UTC (permalink / raw)
  To: torvalds; +Cc: linux-kernel


Name: Export __per_cpu_offset so modules can use per-cpu data.
Author: Rusty Russell
Status: Trivial

D: As per Andrew Morton's request.

diff -urN -I \$.*\$ --exclude TAGS -X /home/rusty/devel/kernel/kernel-patches/current-dontdiff --minimal linux-2.5.25/kernel/ksyms.c working-2.5.25-percpu/kernel/ksyms.c
--- linux-2.5.25/kernel/ksyms.c	Sun Jul  7 02:12:24 2002
+++ working-2.5.25-percpu/kernel/ksyms.c	Fri Jul 12 16:03:47 2002
@@ -50,6 +50,7 @@
 #include <linux/namei.h>
 #include <linux/buffer_head.h>
 #include <linux/root_dev.h>
+#include <linux/percpu.h>
 #include <asm/checksum.h>
 
 #if defined(CONFIG_PROC_FS)
@@ -597,3 +598,6 @@
 
 EXPORT_SYMBOL(tasklist_lock);
 EXPORT_SYMBOL(pidhash);
+#if defined(CONFIG_SMP) && defined(__GENERIC_PER_CPU)
+EXPORT_SYMBOL(__per_cpu_offset);
+#endif

--
  Anyone who quotes me in their sig is an idiot. -- Rusty Russell.

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

* Re: [PATCH] per-cpu patch 1/3
  2002-07-18  3:46 [PATCH] per-cpu patch 1/3 Rusty Russell
@ 2002-07-22  3:00 ` Andrew Morton
  2002-07-22  5:14   ` Rusty Russell
  0 siblings, 1 reply; 3+ messages in thread
From: Andrew Morton @ 2002-07-22  3:00 UTC (permalink / raw)
  To: Rusty Russell; +Cc: torvalds, linux-kernel

Rusty Russell wrote:
> 
> Name: Export __per_cpu_offset so modules can use per-cpu data.

ie: so modules can access per-cpu data which is defined in
vmlinux.  afaik, modules cannot define percpu.h-style per-cpu
storage of their own, yes?

That's rather a trap.  It would be nice to ensure that any
attempt to define per-cpu data in a module fails reliably
at compile-time, please.

-

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

* Re: [PATCH] per-cpu patch 1/3
  2002-07-22  3:00 ` Andrew Morton
@ 2002-07-22  5:14   ` Rusty Russell
  0 siblings, 0 replies; 3+ messages in thread
From: Rusty Russell @ 2002-07-22  5:14 UTC (permalink / raw)
  To: Andrew Morton; +Cc: torvalds, linux-kernel

In message <3D3B7532.96B78172@zip.com.au> you write:
> Rusty Russell wrote:
> > 
> > Name: Export __per_cpu_offset so modules can use per-cpu data.
> 
> ie: so modules can access per-cpu data which is defined in
> vmlinux.  afaik, modules cannot define percpu.h-style per-cpu
> storage of their own, yes?
> 
> That's rather a trap.  It would be nice to ensure that any
> attempt to define per-cpu data in a module fails reliably
> at compile-time, please.

See patch 3/3.

Cheers!
Rusty.
--
  Anyone who quotes me in their sig is an idiot. -- Rusty Russell.

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

end of thread, other threads:[~2002-07-22  5:26 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2002-07-18  3:46 [PATCH] per-cpu patch 1/3 Rusty Russell
2002-07-22  3:00 ` Andrew Morton
2002-07-22  5:14   ` Rusty Russell

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox