Re: [PATCH v2] memcg: workingset: remove folio_memcg_rcu usage

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sat, 26 Oct 2024 23:55:14 -0700 Shakeel Butt <shakeel.butt@xxxxxxxxx> wrote:

[...]
 It seems like folio_memcg_charged() is not defined for CONFIG_MEMCG=n
> config option. The following stub should fix the build for such config.
> 
> 
> diff --git a/include/linux/memcontrol.h b/include/linux/memcontrol.h
> index 89a1e9f10e1b..5502aa8e138e 100644
> --- a/include/linux/memcontrol.h
> +++ b/include/linux/memcontrol.h
> @@ -1055,6 +1055,11 @@ static inline struct mem_cgroup *folio_memcg(struct folio *folio)
>  	return NULL;
>  }
>  
> +static inline bool folio_memcg_charged(struct folio *folio)
> +{
> +	return false;
> +}
> +
>  static inline struct mem_cgroup *folio_memcg_check(struct folio *folio)
>  {
>  	return NULL;

Tested-by: SeongJae Park <sj@xxxxxxxxxx>


Thanks,
SJ




[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux OMAP]     [Linux MIPS]     [eCos]     [Asterisk Internet PBX]     [Linux API]     [Monitors]

  Powered by Linux