* [PATCH] slqb: add declaration for kmem_cache_init_late()
@ 2009-08-06 2:27 Wu Fengguang
2009-08-06 4:17 ` Andrew Morton
0 siblings, 1 reply; 4+ messages in thread
From: Wu Fengguang @ 2009-08-06 2:27 UTC (permalink / raw)
To: Andrew Morton; +Cc: Nick Piggin, linux-mm
Signed-off-by: Wu Fengguang <fengguang.wu@intel.com>
---
include/linux/slqb_def.h | 2 ++
1 file changed, 2 insertions(+)
--- linux-mm.orig/include/linux/slqb_def.h 2009-07-20 20:10:20.000000000 +0800
+++ linux-mm/include/linux/slqb_def.h 2009-08-06 10:17:05.000000000 +0800
@@ -298,4 +298,6 @@ static __always_inline void *kmalloc_nod
}
#endif
+void __init kmem_cache_init_late(void);
+
#endif /* _LINUX_SLQB_DEF_H */
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] slqb: add declaration for kmem_cache_init_late()
2009-08-06 2:27 [PATCH] slqb: add declaration for kmem_cache_init_late() Wu Fengguang
@ 2009-08-06 4:17 ` Andrew Morton
2009-08-06 5:31 ` [PATCH] slab: remove duplicate kmem_cache_init_late() declarations Wu Fengguang
0 siblings, 1 reply; 4+ messages in thread
From: Andrew Morton @ 2009-08-06 4:17 UTC (permalink / raw)
To: Wu Fengguang; +Cc: Nick Piggin, linux-mm, Pekka Enberg
On Thu, 6 Aug 2009 10:27:04 +0800 Wu Fengguang <fengguang.wu@intel.com> wrote:
> Signed-off-by: Wu Fengguang <fengguang.wu@intel.com>
> ---
> include/linux/slqb_def.h | 2 ++
> 1 file changed, 2 insertions(+)
>
> --- linux-mm.orig/include/linux/slqb_def.h 2009-07-20 20:10:20.000000000 +0800
> +++ linux-mm/include/linux/slqb_def.h 2009-08-06 10:17:05.000000000 +0800
> @@ -298,4 +298,6 @@ static __always_inline void *kmalloc_nod
> }
> #endif
>
> +void __init kmem_cache_init_late(void);
> +
> #endif /* _LINUX_SLQB_DEF_H */
spose so.
As all sl[a-zA-Z_]b.c must implement this, why not put the declaration
into slab.h?
That would require uninlining the slob one, but it's tiny and __init.
That's one for Pekka to worry about ;)
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
^ permalink raw reply [flat|nested] 4+ messages in thread
* [PATCH] slab: remove duplicate kmem_cache_init_late() declarations
2009-08-06 4:17 ` Andrew Morton
@ 2009-08-06 5:31 ` Wu Fengguang
2009-08-06 9:02 ` Pekka Enberg
0 siblings, 1 reply; 4+ messages in thread
From: Wu Fengguang @ 2009-08-06 5:31 UTC (permalink / raw)
To: Andrew Morton
Cc: Nick Piggin, linux-mm, Pekka Enberg, Matt Mackall, Christoph Lameter
On Thu, Aug 06, 2009 at 12:17:27PM +0800, Andrew Morton wrote:
> On Thu, 6 Aug 2009 10:27:04 +0800 Wu Fengguang <fengguang.wu@intel.com> wrote:
>
> > Signed-off-by: Wu Fengguang <fengguang.wu@intel.com>
> > ---
> > include/linux/slqb_def.h | 2 ++
> > 1 file changed, 2 insertions(+)
> >
> > --- linux-mm.orig/include/linux/slqb_def.h 2009-07-20 20:10:20.000000000 +0800
> > +++ linux-mm/include/linux/slqb_def.h 2009-08-06 10:17:05.000000000 +0800
> > @@ -298,4 +298,6 @@ static __always_inline void *kmalloc_nod
> > }
> > #endif
> >
> > +void __init kmem_cache_init_late(void);
> > +
> > #endif /* _LINUX_SLQB_DEF_H */
>
> spose so.
>
> As all sl[a-zA-Z_]b.c must implement this, why not put the declaration
> into slab.h?
>
> That would require uninlining the slob one, but it's tiny and __init.
Right. It seems someone recently moved the declaration from slab_def.h
to slab.h, so the replacement patch is a bit smaller:
---
slab: remove duplicate kmem_cache_init_late() declarations
kmem_cache_init_late() has been declared in slab.h
CC: Nick Piggin <npiggin@suse.de>
CC: Matt Mackall <mpm@selenic.com>
CC: Pekka Enberg <penberg@cs.helsinki.fi>
CC: Christoph Lameter <cl@linux-foundation.org>
Signed-off-by: Wu Fengguang <fengguang.wu@intel.com>
---
include/linux/slob_def.h | 5 -----
include/linux/slub_def.h | 2 --
mm/slob.c | 5 +++++
3 files changed, 5 insertions(+), 7 deletions(-)
--- linux-mm.orig/include/linux/slub_def.h 2009-08-06 13:15:24.000000000 +0800
+++ linux-mm/include/linux/slub_def.h 2009-08-06 13:15:52.000000000 +0800
@@ -304,6 +304,4 @@ static __always_inline void *kmalloc_nod
}
#endif
-void __init kmem_cache_init_late(void);
-
#endif /* _LINUX_SLUB_DEF_H */
--- linux-mm.orig/include/linux/slob_def.h 2009-08-06 13:15:24.000000000 +0800
+++ linux-mm/include/linux/slob_def.h 2009-08-06 13:15:52.000000000 +0800
@@ -34,9 +34,4 @@ static __always_inline void *__kmalloc(s
return kmalloc(size, flags);
}
-static inline void kmem_cache_init_late(void)
-{
- /* Nothing to do */
-}
-
#endif /* __LINUX_SLOB_DEF_H */
--- linux-mm.orig/mm/slob.c 2009-08-06 13:15:24.000000000 +0800
+++ linux-mm/mm/slob.c 2009-08-06 13:23:50.000000000 +0800
@@ -692,3 +692,8 @@ void __init kmem_cache_init(void)
{
slob_ready = 1;
}
+
+void __init kmem_cache_init_late(void)
+{
+ /* Nothing to do */
+}
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] slab: remove duplicate kmem_cache_init_late() declarations
2009-08-06 5:31 ` [PATCH] slab: remove duplicate kmem_cache_init_late() declarations Wu Fengguang
@ 2009-08-06 9:02 ` Pekka Enberg
0 siblings, 0 replies; 4+ messages in thread
From: Pekka Enberg @ 2009-08-06 9:02 UTC (permalink / raw)
To: Wu Fengguang
Cc: Andrew Morton, Nick Piggin, linux-mm, Matt Mackall, Christoph Lameter
Wu Fengguang wrote:
> Right. It seems someone recently moved the declaration from slab_def.h
> to slab.h, so the replacement patch is a bit smaller:
>
> ---
> slab: remove duplicate kmem_cache_init_late() declarations
>
> kmem_cache_init_late() has been declared in slab.h
>
> CC: Nick Piggin <npiggin@suse.de>
> CC: Matt Mackall <mpm@selenic.com>
> CC: Pekka Enberg <penberg@cs.helsinki.fi>
> CC: Christoph Lameter <cl@linux-foundation.org>
> Signed-off-by: Wu Fengguang <fengguang.wu@intel.com>
Applied, thanks!
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2009-08-06 9:02 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-08-06 2:27 [PATCH] slqb: add declaration for kmem_cache_init_late() Wu Fengguang
2009-08-06 4:17 ` Andrew Morton
2009-08-06 5:31 ` [PATCH] slab: remove duplicate kmem_cache_init_late() declarations Wu Fengguang
2009-08-06 9:02 ` Pekka Enberg
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox