linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] mm, slab: remove memcg_from_slab_obj()
@ 2024-03-01 16:08 Vlastimil Babka
  2024-03-02  5:07 ` Chengming Zhou
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Vlastimil Babka @ 2024-03-01 16:08 UTC (permalink / raw)
  To: Christoph Lameter, Pekka Enberg, David Rientjes, Joonsoo Kim
  Cc: Andrew Morton, Roman Gushchin, Hyeonggon Yoo, Chengming Zhou,
	linux-mm, Vlastimil Babka

This empty wrapped exists only for !CONFIG_MEMCG_KMEM and seems it was
never used. Probably a leftover from development of a series.

Signed-off-by: Vlastimil Babka <vbabka@suse.cz>
---
 mm/slub.c | 5 -----
 1 file changed, 5 deletions(-)

diff --git a/mm/slub.c b/mm/slub.c
index 12066e69688d..186a8ec28228 100644
--- a/mm/slub.c
+++ b/mm/slub.c
@@ -2028,11 +2028,6 @@ void memcg_slab_alloc_error_hook(struct kmem_cache *s, int objects,
 		obj_cgroup_uncharge(objcg, objects * obj_full_size(s));
 }
 #else /* CONFIG_MEMCG_KMEM */
-static inline struct mem_cgroup *memcg_from_slab_obj(void *ptr)
-{
-	return NULL;
-}
-
 static inline void memcg_free_slab_cgroups(struct slab *slab)
 {
 }
-- 
2.44.0



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

* Re: [PATCH] mm, slab: remove memcg_from_slab_obj()
  2024-03-01 16:08 [PATCH] mm, slab: remove memcg_from_slab_obj() Vlastimil Babka
@ 2024-03-02  5:07 ` Chengming Zhou
  2024-03-02 15:57 ` Roman Gushchin
  2024-03-03 22:10 ` David Rientjes
  2 siblings, 0 replies; 4+ messages in thread
From: Chengming Zhou @ 2024-03-02  5:07 UTC (permalink / raw)
  To: Vlastimil Babka, Christoph Lameter, Pekka Enberg, David Rientjes,
	Joonsoo Kim
  Cc: Andrew Morton, Roman Gushchin, Hyeonggon Yoo, linux-mm

On 2024/3/2 00:08, Vlastimil Babka wrote:
> This empty wrapped exists only for !CONFIG_MEMCG_KMEM and seems it was
> never used. Probably a leftover from development of a series.
> 
> Signed-off-by: Vlastimil Babka <vbabka@suse.cz>

LGTM, thanks!

Reviewed-by: Chengming Zhou <chengming.zhou@linux.dev>

> ---
>  mm/slub.c | 5 -----
>  1 file changed, 5 deletions(-)
> 
> diff --git a/mm/slub.c b/mm/slub.c
> index 12066e69688d..186a8ec28228 100644
> --- a/mm/slub.c
> +++ b/mm/slub.c
> @@ -2028,11 +2028,6 @@ void memcg_slab_alloc_error_hook(struct kmem_cache *s, int objects,
>  		obj_cgroup_uncharge(objcg, objects * obj_full_size(s));
>  }
>  #else /* CONFIG_MEMCG_KMEM */
> -static inline struct mem_cgroup *memcg_from_slab_obj(void *ptr)
> -{
> -	return NULL;
> -}
> -
>  static inline void memcg_free_slab_cgroups(struct slab *slab)
>  {
>  }


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

* Re: [PATCH] mm, slab: remove memcg_from_slab_obj()
  2024-03-01 16:08 [PATCH] mm, slab: remove memcg_from_slab_obj() Vlastimil Babka
  2024-03-02  5:07 ` Chengming Zhou
@ 2024-03-02 15:57 ` Roman Gushchin
  2024-03-03 22:10 ` David Rientjes
  2 siblings, 0 replies; 4+ messages in thread
From: Roman Gushchin @ 2024-03-02 15:57 UTC (permalink / raw)
  To: Vlastimil Babka
  Cc: Christoph Lameter, Pekka Enberg, David Rientjes, Joonsoo Kim,
	Andrew Morton, Hyeonggon Yoo, Chengming Zhou, linux-mm

On Fri, Mar 01, 2024 at 05:08:09PM +0100, Vlastimil Babka wrote:
> This empty wrapped exists only for !CONFIG_MEMCG_KMEM and seems it was
> never used. Probably a leftover from development of a series.
> 
> Signed-off-by: Vlastimil Babka <vbabka@suse.cz>

Reviewed-by: Roman Gushchin <roman.gushchin@linux.dev>

Thanks!


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

* Re: [PATCH] mm, slab: remove memcg_from_slab_obj()
  2024-03-01 16:08 [PATCH] mm, slab: remove memcg_from_slab_obj() Vlastimil Babka
  2024-03-02  5:07 ` Chengming Zhou
  2024-03-02 15:57 ` Roman Gushchin
@ 2024-03-03 22:10 ` David Rientjes
  2 siblings, 0 replies; 4+ messages in thread
From: David Rientjes @ 2024-03-03 22:10 UTC (permalink / raw)
  To: Vlastimil Babka
  Cc: Christoph Lameter, Pekka Enberg, Joonsoo Kim, Andrew Morton,
	Roman Gushchin, Hyeonggon Yoo, Chengming Zhou, linux-mm

On Fri, 1 Mar 2024, Vlastimil Babka wrote:

> This empty wrapped exists only for !CONFIG_MEMCG_KMEM and seems it was
> never used. Probably a leftover from development of a series.
> 
> Signed-off-by: Vlastimil Babka <vbabka@suse.cz>

Acked-by: David Rientjes <rientjes@google.com>


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

end of thread, other threads:[~2024-03-03 22:10 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-03-01 16:08 [PATCH] mm, slab: remove memcg_from_slab_obj() Vlastimil Babka
2024-03-02  5:07 ` Chengming Zhou
2024-03-02 15:57 ` Roman Gushchin
2024-03-03 22:10 ` David Rientjes

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