From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 4FDBEE6C608 for ; Tue, 3 Dec 2024 05:43:50 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id BD9316B007B; Tue, 3 Dec 2024 00:43:49 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id B88EF6B0083; Tue, 3 Dec 2024 00:43:49 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id A50886B0085; Tue, 3 Dec 2024 00:43:49 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0011.hostedemail.com [216.40.44.11]) by kanga.kvack.org (Postfix) with ESMTP id 87E4C6B007B for ; Tue, 3 Dec 2024 00:43:49 -0500 (EST) Received: from smtpin11.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay08.hostedemail.com (Postfix) with ESMTP id 2296A14060C for ; Tue, 3 Dec 2024 05:43:49 +0000 (UTC) X-FDA: 82852555926.11.A7C13DC Received: from mgamail.intel.com (mgamail.intel.com [198.175.65.12]) by imf12.hostedemail.com (Postfix) with ESMTP id ED39B4000C for ; Tue, 3 Dec 2024 05:43:40 +0000 (UTC) Authentication-Results: imf12.hostedemail.com; dkim=pass header.d=intel.com header.s=Intel header.b=aquViQDD; spf=pass (imf12.hostedemail.com: domain of lkp@intel.com designates 198.175.65.12 as permitted sender) smtp.mailfrom=lkp@intel.com; dmarc=pass (policy=none) header.from=intel.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1733204621; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=NiFhzkw26mroRHmkHI0xFH1zyUONW7fNwjj+aKoFgKw=; b=2y+p3jcH1HY0/o/p+3Dd0RPTuiUXO+AfXcBDNhXE73UGHeeKysXDnOc6Kh/93ZGHzL4BUz JgbCiO9uB8H/PvaKBKo0MfNOHU0b0eYExv7yjXXuWGso5xsM3FvWCd6L54RgNBbC4ZWZK8 GIv9nIjos4FBBYfzkMTcvuVykEVxGdg= ARC-Authentication-Results: i=1; imf12.hostedemail.com; dkim=pass header.d=intel.com header.s=Intel header.b=aquViQDD; spf=pass (imf12.hostedemail.com: domain of lkp@intel.com designates 198.175.65.12 as permitted sender) smtp.mailfrom=lkp@intel.com; dmarc=pass (policy=none) header.from=intel.com ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1733204621; a=rsa-sha256; cv=none; b=deOg6yctZNhy1pIIvSUUmV09BY/fEx0NkU65oMIqDZjahzNWsXpJGjtMZIetr1FndGcLLo 5lT8OSBM6lJVAbJxvMcNPWvOYNKIxsTgvpgDTq+1qKOQwTZpKyKYv/AiRPS3XKUX1BnN7K Rk95S7fpyeBQLaE0Je2bOQ7kK13SqDE= DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1733204627; x=1764740627; h=date:from:to:cc:subject:message-id:references: mime-version:in-reply-to; bh=TBaw6U370tnIdeZ/reivCRWw+2bV9ozrdLvqRIr9cjg=; b=aquViQDDtM9LkD2MPAjra0Hk8h2Dp60e1fpEWKyjixOvbG6SY4GyQEt/ n2hTsf79XmYLgIIRI037gv/rmq5TtHQO8ODT3iKjKm1P4FTGGw7+fhZqf yhJ/PTIM15lWtKHW+pG88bL7UME6ClKsbeMAuu+sL9Ce4tvnmK+OOwvH6 02wSfNEK4obp265vwdhKa/hzYYAyhPs8PUxRQ10vo7zKBF+Uhryz/SE5p XWqaohJrgXR7zfzO1386xDF4pJtO0qJnhW/9yYjwfT94FGBgw7TV7IP+y nfHNOAz6s1JbAxg5T4NowOFgIwUBNM2Bcp199La1nWV2qm7Io7o9dPIm0 Q==; X-CSE-ConnectionGUID: CZPTdD03Q1CtewZQIARo6w== X-CSE-MsgGUID: jyqVMGAcQaaAumskdVovHw== X-IronPort-AV: E=McAfee;i="6700,10204,11274"; a="44784702" X-IronPort-AV: E=Sophos;i="6.12,204,1728975600"; d="scan'208";a="44784702" Received: from fmviesa009.fm.intel.com ([10.60.135.149]) by orvoesa104.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 02 Dec 2024 21:43:45 -0800 X-CSE-ConnectionGUID: HD/+TMo9Q0CBPjRWw7SDRg== X-CSE-MsgGUID: yr15CWHsQU27wGKvnmVdgA== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.12,204,1728975600"; d="scan'208";a="93789906" Received: from lkp-server01.sh.intel.com (HELO 388c121a226b) ([10.239.97.150]) by fmviesa009.fm.intel.com with ESMTP; 02 Dec 2024 21:43:41 -0800 Received: from kbuild by 388c121a226b with local (Exim 4.96) (envelope-from ) id 1tILhD-0000At-0S; Tue, 03 Dec 2024 05:43:39 +0000 Date: Tue, 3 Dec 2024 13:42:39 +0800 From: kernel test robot To: Kairui Song , linux-mm@kvack.org Cc: llvm@lists.linux.dev, oe-kbuild-all@lists.linux.dev, Andrew Morton , Linux Memory Management List , Chris Li , Hugh Dickins , "Huang, Ying" , Yosry Ahmed , Roman Gushchin , Shakeel Butt , Johannes Weiner , Barry Song , Michal Hocko , linux-kernel@vger.kernel.org, Kairui Song Subject: Re: [PATCH 1/4] mm, memcontrol: avoid duplicated memcg enable check Message-ID: <202412031318.6qeKIH6u-lkp@intel.com> References: <20241202184154.19321-2-ryncsn@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20241202184154.19321-2-ryncsn@gmail.com> X-Rspamd-Queue-Id: ED39B4000C X-Stat-Signature: zddrdakpnannpf9wfoigbk7nht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a9S4dTfeA4Cu16m/OpTAMBpgjNmm5XHregHksXv6qKVTmq0714vmCgci1pnjFatJR8gzzzNVyp8Ah+1K+xEXv7m+0zNuLM7IkgUOu5GPH0m4kkIt/MkwWhI0a2UmrbloXrXP16RluzXUL7UnPk7rg16KKeYknoed69p628saWrV9V0xpzLePVEpxogCaWeqWacjK5HRxYwXFLKpz/yw8dcg+JJbyfnG6F92Gvo0zKZGdI3XqUUdm5Nf0QIus2c2bwe29TZnl+ep/INjf/3U04CUQsdT67CqnBZVugq1vWTpBjeLs1ZAIU5S2XNB8VLCTcaG4y03REl9iKJ7Y7 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: List-Subscribe: List-Unsubscribe: Hi Kairui, kernel test robot noticed the following build errors: [auto build test ERROR on akpm-mm/mm-everything] url: https://github.com/intel-lab-lkp/linux/commits/Kairui-Song/mm-memcontrol-avoid-duplicated-memcg-enable-check/20241203-024957 base: https://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm.git mm-everything patch link: https://lore.kernel.org/r/20241202184154.19321-2-ryncsn%40gmail.com patch subject: [PATCH 1/4] mm, memcontrol: avoid duplicated memcg enable check config: i386-buildonly-randconfig-003-20241203 (https://download.01.org/0day-ci/archive/20241203/202412031318.6qeKIH6u-lkp@intel.com/config) compiler: clang version 19.1.3 (https://github.com/llvm/llvm-project ab51eccf88f5321e7c60591c5546b254b6afab99) reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20241203/202412031318.6qeKIH6u-lkp@intel.com/reproduce) If you fix the issue in a separate patch/commit (i.e. not just a new version of the same patch/commit), kindly add following tags | Reported-by: kernel test robot | Closes: https://lore.kernel.org/oe-kbuild-all/202412031318.6qeKIH6u-lkp@intel.com/ All errors (new ones prefixed by >>): In file included from mm/memcontrol.c:30: In file included from include/linux/memcontrol.h:21: In file included from include/linux/mm.h:2223: include/linux/vmstat.h:518:36: warning: arithmetic between different enumeration types ('enum node_stat_item' and 'enum lru_list') [-Wenum-enum-conversion] 518 | return node_stat_name(NR_LRU_BASE + lru) + 3; // skip "nr_" | ~~~~~~~~~~~ ^ ~~~ In file included from mm/memcontrol.c:56: include/linux/mm_inline.h:47:41: warning: arithmetic between different enumeration types ('enum node_stat_item' and 'enum lru_list') [-Wenum-enum-conversion] 47 | __mod_lruvec_state(lruvec, NR_LRU_BASE + lru, nr_pages); | ~~~~~~~~~~~ ^ ~~~ include/linux/mm_inline.h:49:22: warning: arithmetic between different enumeration types ('enum zone_stat_item' and 'enum lru_list') [-Wenum-enum-conversion] 49 | NR_ZONE_LRU_BASE + lru, nr_pages); | ~~~~~~~~~~~~~~~~ ^ ~~~ >> mm/memcontrol.c:4618:3: error: call to undeclared function '__mem_cgroup_uncharge_swap'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration] 4618 | __mem_cgroup_uncharge_swap(entry, nr_pages); | ^ mm/memcontrol.c:4618:3: note: did you mean 'mem_cgroup_uncharge_swap'? include/linux/swap.h:687:20: note: 'mem_cgroup_uncharge_swap' declared here 687 | static inline void mem_cgroup_uncharge_swap(swp_entry_t entry, | ^ 3 warnings and 1 error generated. vim +/__mem_cgroup_uncharge_swap +4618 mm/memcontrol.c 4587 4588 /* 4589 * mem_cgroup_swapin_uncharge_swap - uncharge swap slot 4590 * @entry: the first swap entry for which the pages are charged 4591 * @nr_pages: number of pages which will be uncharged 4592 * 4593 * Call this function after successfully adding the charged page to swapcache. 4594 * 4595 * Note: This function assumes the page for which swap slot is being uncharged 4596 * is order 0 page. 4597 */ 4598 void mem_cgroup_swapin_uncharge_swap(swp_entry_t entry, unsigned int nr_pages) 4599 { 4600 /* 4601 * Cgroup1's unified memory+swap counter has been charged with the 4602 * new swapcache page, finish the transfer by uncharging the swap 4603 * slot. The swap slot would also get uncharged when it dies, but 4604 * it can stick around indefinitely and we'd count the page twice 4605 * the entire time. 4606 * 4607 * Cgroup2 has separate resource counters for memory and swap, 4608 * so this is a non-issue here. Memory and swap charge lifetimes 4609 * correspond 1:1 to page and swap slot lifetimes: we charge the 4610 * page to memory here, and uncharge swap when the slot is freed. 4611 */ 4612 if (!mem_cgroup_disabled() && do_memsw_account()) { 4613 /* 4614 * The swap entry might not get freed for a long time, 4615 * let's not wait for it. The page already received a 4616 * memory+swap charge, drop the swap entry duplicate. 4617 */ > 4618 __mem_cgroup_uncharge_swap(entry, nr_pages); 4619 } 4620 } 4621 -- 0-DAY CI Kernel Test Service https://github.com/intel/lkp-tests/wiki