public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* Re: [sj:damon/next 27/34] mm/damon/sysfs-schemes.c:1409:19: error: incomplete definition of type 'struct mem_cgroup'
       [not found] <202211281158.AsAWEmu1-lkp@intel.com>
@ 2022-11-28 17:54 ` SeongJae Park
  0 siblings, 0 replies; only message in thread
From: SeongJae Park @ 2022-11-28 17:54 UTC (permalink / raw)
  To: kernel test robot
  Cc: SeongJae Park, damon, linux-mm, linux-kernel, llvm, oe-kbuild-all

Hello Robot,

On Mon, 28 Nov 2022 12:00:58 +0800 kernel test robot <lkp@intel.com> wrote:

> [-- Attachment #1: Type: text/plain, Size: 1995 bytes --]
> 
> tree:   https://git.kernel.org/pub/scm/linux/kernel/git/sj/linux.git damon/next
> head:   c68bc40dc2022ce015ee828d0fccb34f864934f8
> commit: 80bd927ee54ff864d9a6ceb1c6ce4803b22e7220 [27/34] mm/damon/sysfs-schemes: implement scheme filters
> config: x86_64-randconfig-r015-20221128
> compiler: clang version 14.0.6 (https://github.com/llvm/llvm-project f28c006a5895fc0e329fe15fead81e37457cb1d1)
> reproduce (this is a W=1 build):
>         wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
>         chmod +x ~/bin/make.cross
>         # https://git.kernel.org/pub/scm/linux/kernel/git/sj/linux.git/commit/?id=80bd927ee54ff864d9a6ceb1c6ce4803b22e7220
>         git remote add sj https://git.kernel.org/pub/scm/linux/kernel/git/sj/linux.git
>         git fetch --no-tags sj damon/next
>         git checkout 80bd927ee54ff864d9a6ceb1c6ce4803b22e7220
>         # save the config file
>         mkdir build_dir && cp config build_dir/.config
>         COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=x86_64 SHELL=/bin/bash
> 
> If you fix the issue, kindly add following tag where applicable
> | Reported-by: kernel test robot <lkp@intel.com>
> 
> All errors (new ones prefixed by >>):
> 
> >> mm/damon/sysfs-schemes.c:1409:19: error: incomplete definition of type 'struct mem_cgroup'
>            cgroup_path(memcg->css.cgroup, memcg_path_buf, PATH_MAX);
>                        ~~~~~^
>    include/linux/mm_types.h:33:8: note: forward declaration of 'struct mem_cgroup'
>    struct mem_cgroup;
>           ^
>    1 error generated.
> 
> 
> vim +1409 mm/damon/sysfs-schemes.c
> 
>   1404	
>   1405	static bool damon_sysfs_memcg_path_eq(struct mem_cgroup *memcg,
>   1406			char *memcg_path_buf, char *path)
>   1407	{
>   1408	#ifdef CONFIG_CGROUPS
> > 1409		cgroup_path(memcg->css.cgroup, memcg_path_buf, PATH_MAX);
>   1410		if (sysfs_streq(memcg_path_buf, path))
>   1411			return true;
>   1412	#endif

'struct mem_cgroup' is defined under '#ifdef CONFIG_MEMCG', so this should be
guarded with it.  Fixed it[1].  Thank you again!

[1] https://git.kernel.org/pub/scm/linux/kernel/git/sj/linux.git/commit/?h=damon/next&id=dc31f4ababd073e1686de0e51f45c5bbd42e66ac


Thanks,
SJ

>   1413		return false;
>   1414	}
>   1415	

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2022-11-28 18:12 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <202211281158.AsAWEmu1-lkp@intel.com>
2022-11-28 17:54 ` [sj:damon/next 27/34] mm/damon/sysfs-schemes.c:1409:19: error: incomplete definition of type 'struct mem_cgroup' SeongJae Park

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