On Sat, Aug 9, 2008 at 5:45 PM, Carl-Daniel Hailfinger
+struct global_vars { +#ifdef CONFIG_CONSOLE_BUFFER
struct printk_buffer *printk_buffer;
+#endif +};
I think you should always leave the struct the same size and let it have struct members that are in some cases unused.
Why not have, e.g, a page sized global area and allocate out of it? Hmm. we just recreated malloc.
hmm. Why not when we allocate stack have a constant that defines a 'base of stack' area that is some fixed size, which matches struct global_vars in size? just random thoughts.
This is close but Peter's comment is important.
ron