Re: [PATCH] allocate struct ext4_allocation_context from a kmem cache to save stack space

2008-02-08 Thread Dave Kleikamp
On Fri, 2008-02-08 at 10:25 -0800, Mingming Cao wrote: > On Fri, 2008-02-08 at 10:55 -0600, Eric Sandeen wrote: > > Mingming Cao wrote: > > > > > printk could be removed...so as long as it builds fine. I had looked at > > > the history yesterday and find this fix > > > http://lists.openwall.net/l

Re: [PATCH] allocate struct ext4_allocation_context from a kmem cache to save stack space

2008-02-08 Thread Mingming Cao
On Fri, 2008-02-08 at 10:55 -0600, Eric Sandeen wrote: > Mingming Cao wrote: > > > printk could be removed...so as long as it builds fine. I had looked at > > the history yesterday and find this fix > > http://lists.openwall.net/linux-ext4/2007/10/10/2 > > so I was under impression that the ifdefs

Re: [PATCH] allocate struct ext4_allocation_context from a kmem cache to save stack space

2008-02-08 Thread Dave Kleikamp
On Fri, 2008-02-08 at 08:39 -0800, Mingming Cao wrote: > On Fri, 2008-02-08 at 09:45 -0600, Dave Kleikamp wrote: > > On Thu, 2008-02-07 at 20:35 -0600, Eric Sandeen wrote: > > > it'll build: > > > > > > static inline struct proc_dir_entry *proc_mkdir(const char *name, > > > struct proc_d

Re: [PATCH] allocate struct ext4_allocation_context from a kmem cache to save stack space

2008-02-08 Thread Eric Sandeen
Mingming Cao wrote: > printk could be removed...so as long as it builds fine. I had looked at > the history yesterday and find this fix > http://lists.openwall.net/linux-ext4/2007/10/10/2 > so I was under impression that the ifdefs was added to fix compile > issue. I did not look more closely. May

Re: [PATCH] allocate struct ext4_allocation_context from a kmem cache to save stack space

2008-02-08 Thread Mingming Cao
On Fri, 2008-02-08 at 09:45 -0600, Dave Kleikamp wrote: > On Thu, 2008-02-07 at 20:35 -0600, Eric Sandeen wrote: > > Mingming Cao wrote: > > > On Thu, 2008-02-07 at 19:06 -0600, Eric Sandeen wrote: > > >> Mingming Cao wrote: > > >> > > >>> Do you intend to remove the #ifdef CONFIG_PROC_FS, or it's

Re: [PATCH] allocate struct ext4_allocation_context from a kmem cache to save stack space

2008-02-08 Thread Dave Kleikamp
On Thu, 2008-02-07 at 20:35 -0600, Eric Sandeen wrote: > Mingming Cao wrote: > > On Thu, 2008-02-07 at 19:06 -0600, Eric Sandeen wrote: > >> Mingming Cao wrote: > >> > >>> Do you intend to remove the #ifdef CONFIG_PROC_FS, or it's a accident? I > >>> think we need keep that to allow ext4 build wit

Re: [PATCH] allocate struct ext4_allocation_context from a kmem cache to save stack space

2008-02-07 Thread Eric Sandeen
Mingming Cao wrote: > On Thu, 2008-02-07 at 19:06 -0600, Eric Sandeen wrote: >> Mingming Cao wrote: >> >>> Do you intend to remove the #ifdef CONFIG_PROC_FS, or it's a accident? I >>> think we need keep that to allow ext4 build without procfs configured. >>> >>> Other than this, the patch looks fin

Re: [PATCH] allocate struct ext4_allocation_context from a kmem cache to save stack space

2008-02-07 Thread Mingming Cao
On Thu, 2008-02-07 at 19:06 -0600, Eric Sandeen wrote: > Mingming Cao wrote: > > > Do you intend to remove the #ifdef CONFIG_PROC_FS, or it's a accident? I > > think we need keep that to allow ext4 build without procfs configured. > > > > Other than this, the patch looks fine to me.:) > > oh, it

Re: [PATCH] allocate struct ext4_allocation_context from a kmem cache to save stack space

2008-02-07 Thread Eric Sandeen
Mingming Cao wrote: > Do you intend to remove the #ifdef CONFIG_PROC_FS, or it's a accident? I > think we need keep that to allow ext4 build without procfs configured. > > Other than this, the patch looks fine to me.:) oh, it kind of snuck in. It actually should still build, as remove_proc_entr

Re: [PATCH] allocate struct ext4_allocation_context from a kmem cache to save stack space

2008-02-07 Thread Mingming Cao
On Wed, 2008-02-06 at 11:05 -0600, Eric Sandeen wrote: > struct ext4_allocation_context is rather large, and this bloats > the stack of many functions which use it. Allocating it from > a named slab cache will alleviate this. > > For example, with this change (on top of the noinline patch sent ea

[PATCH] allocate struct ext4_allocation_context from a kmem cache to save stack space

2008-02-06 Thread Eric Sandeen
struct ext4_allocation_context is rather large, and this bloats the stack of many functions which use it. Allocating it from a named slab cache will alleviate this. For example, with this change (on top of the noinline patch sent earlier): -ext4_mb_new_blocks 200 +ext4_mb_new_blocks