Re: [PATCH 00/05] robust per_cpu allocation for modules

From: Steven Rostedt
Date: Mon Apr 17 2006 - 07:34:26 EST


On Mon, 2006-04-17 at 16:47 +1000, Rusty Russell wrote:

>
> The arch would allocate a virtual memory hole for each CPU, and map
> pages as required (this is the simplest of several potential schemes).
> This gives the "same space between CPUs" property which is required for
> the ptr + per-cpu-offset scheme. An arch would supply functions like:
>
> /* Returns address of new memory chunk(s)
> * (add __per_cpu_offset to get virtual addresses). */
> unsigned long alloc_percpu_memory(unsigned long *size);
>
> /* Set by ia64 to reserve the first chunk for percpu vars
> * in modules only.
> #define __MODULE_RESERVE_FIRST_CHUNK
>
> And an allocator would work on top of these.
>
> I'm glad someone is looking at this again!

Hi Rusty, thanks for the input.

Arnd Bergmann also suggested doing the same thing. I've slept on this
thought last night and I'm starting to like it more and more. At least
it seems to be a better solution than some of the things that I've come
up with.

I'll start playing around a little and see what I can do with it. I
also need to start doing some other work too, so this might take a month
or two to get some results. So hopefully, I'll have another patch set
in June or July that will be more acceptable.

I'd like to thank all those that responded with ideas and criticisms.
It's been very helpful.

-- Steve


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/