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 AB59CC6FA82 for ; Sat, 10 Sep 2022 01:37:29 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id E66BA8D0001; Fri, 9 Sep 2022 21:37:28 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id E15776B0072; Fri, 9 Sep 2022 21:37:28 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id CB6768D0001; Fri, 9 Sep 2022 21:37:28 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0016.hostedemail.com [216.40.44.16]) by kanga.kvack.org (Postfix) with ESMTP id BCD0B6B0071 for ; Fri, 9 Sep 2022 21:37:28 -0400 (EDT) Received: from smtpin18.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay01.hostedemail.com (Postfix) with ESMTP id 486991C60B2 for ; Sat, 10 Sep 2022 01:37:28 +0000 (UTC) X-FDA: 79894463376.18.C809F9B Received: from mga01.intel.com (mga01.intel.com [192.55.52.88]) by imf16.hostedemail.com (Postfix) with ESMTP id 96A3218007D for ; Sat, 10 Sep 2022 01:37:26 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1662773846; x=1694309846; h=date:from:to:cc:subject:message-id:references: mime-version:in-reply-to; bh=HM4gATmp1s6shVM9+XdfzJPDKTDVkoUU2CxEiQTnkSE=; b=as1xbJIQARR0SzQQSF57VdtzN00g7EhCxq9TVLDVf26BapnzTXQ8ZUzM w7HCQ54aKYMeielhCF6kO6zfSSFScyolT9Wfivkr1e/+BI8V7I8y8gWzX HsP1VkpyZeQFFOi7PKm8p8MXWp7i5UIaLPvA0SOGaRvlTGW10sKweVOpL WQrnJY5wE7t2UPMgSgp6RPh0LOjAe+9WlnnT+gSm7xky89x+bsHe2JRxD jd6lh91nlw9g0CWTvCW+wHsre+qZFCbu4rUh0kPmcE1EhJA9/X24f5+ZS ENYwdv6eyCfg/qDl7DW3rHVFmJJeWh4oJdJG14aTHlxCsN0Zypw+iIss+ w==; X-IronPort-AV: E=McAfee;i="6500,9779,10465"; a="323820760" X-IronPort-AV: E=Sophos;i="5.93,304,1654585200"; d="scan'208";a="323820760" Received: from fmsmga006.fm.intel.com ([10.253.24.20]) by fmsmga101.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 09 Sep 2022 18:37:25 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.93,304,1654585200"; d="scan'208";a="860593642" Received: from lkp-server02.sh.intel.com (HELO b2938d2e5c5a) ([10.239.97.151]) by fmsmga006.fm.intel.com with ESMTP; 09 Sep 2022 18:37:21 -0700 Received: from kbuild by b2938d2e5c5a with local (Exim 4.96) (envelope-from ) id 1oWpQu-0001y3-2j; Sat, 10 Sep 2022 01:37:20 +0000 Date: Sat, 10 Sep 2022 09:37:13 +0800 From: kernel test robot To: Jiebin Sun , akpm@linux-foundation.org, vasily.averin@linux.dev, shakeelb@google.com, dennis@kernel.org, tj@kernel.org, cl@linux.com, ebiederm@xmission.com, legion@kernel.org, manfred@colorfullife.com, alexander.mikhalitsyn@virtuozzo.com, linux-mm@kvack.org, linux-kernel@vger.kernel.org Cc: kbuild-all@lists.01.org, tim.c.chen@intel.com, feng.tang@intel.com, ying.huang@intel.com, tianyou.li@intel.com, wangyang.guo@intel.com, jiebin.sun@intel.com Subject: Re: [PATCH v5 1/2] percpu: Add percpu_counter_add_local and percpu_counter_sub_local Message-ID: <202209100911.HBo9ZqIU-lkp@intel.com> References: <20220909203636.2652466-2-jiebin.sun@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20220909203636.2652466-2-jiebin.sun@intel.com> ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1662773847; 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=fD5VJZ0sw0LSaR53qkxZ1rmp21Yfaa0fnWQ0x7bmgI4=; b=Ht42UZsvVVBoi9aLjEur/bCNtGpHTxIsoGk7qAzpdTZnj09dTBNNxVsl2bEEJjLax9itAc CM96ZNjo2uAPoaXNcaJvpLGYx33DO/skhXB5gUoejS0xmSI++VxT1KAqckHTDzd+tchXFW pEGVfK4wg6n0tfDEXfbr1/hceFcDzyU= ARC-Authentication-Results: i=1; imf16.hostedemail.com; dkim=none ("invalid DKIM record") header.d=intel.com header.s=Intel header.b=as1xbJIQ; spf=pass (imf16.hostedemail.com: domain of lkp@intel.com designates 192.55.52.88 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=1662773847; a=rsa-sha256; cv=none; b=2zo/Cy4RPZvXZWHCk0oLDCVmQCVvrBAV9Fz/HftLRGhGwhu0wjHfVUeP8n3Qe30QGm/1fq 5+JR3VLscVVFe9Fx+Sd3XcExc/bFvpsNnqke8KGqZhFyOaYPOKjA8ZB49rUQA8zWjY7QYy bLmVVPhoTJhJhJoGKMJQdpe+BRcMOqk= X-Rspam-User: X-Stat-Signature: k3yy4k1iw4hmko4aqd7w19gqbazki9w1 X-Rspamd-Server: rspam05 X-Rspamd-Queue-Id: 96A3218007D Authentication-Results: imf16.hostedemail.com; dkim=none ("invalid DKIM record") header.d=intel.com header.s=Intel header.b=as1xbJIQ; spf=pass (imf16.hostedemail.com: domain of lkp@intel.com designates 192.55.52.88 as permitted sender) smtp.mailfrom=lkp@intel.com; dmarc=pass (policy=none) header.from=intel.com X-HE-Tag: 1662773846-314796 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: Hi Jiebin, Thank you for the patch! Yet something to improve: [auto build test ERROR on akpm-mm/mm-everything] [also build test ERROR on linus/master v6.0-rc4 next-20220909] [If your patch is applied to the wrong git tree, kindly drop us a note. And when submitting patch, we suggest to use '--base' as documented in https://git-scm.com/docs/git-format-patch#_base_tree_information] url: https://github.com/intel-lab-lkp/linux/commits/Jiebin-Sun/percpu-Add-percpu_counter_add_local-and-percpu_counter_sub_local/20220910-053730 base: https://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm.git mm-everything config: x86_64-randconfig-a013 (https://download.01.org/0day-ci/archive/20220910/202209100911.HBo9ZqIU-lkp@intel.com/config) compiler: gcc-11 (Debian 11.3.0-5) 11.3.0 reproduce (this is a W=1 build): # https://github.com/intel-lab-lkp/linux/commit/44e7288c01b9b125c7a5f97591ca26ffd90e3385 git remote add linux-review https://github.com/intel-lab-lkp/linux git fetch --no-tags linux-review Jiebin-Sun/percpu-Add-percpu_counter_add_local-and-percpu_counter_sub_local/20220910-053730 git checkout 44e7288c01b9b125c7a5f97591ca26ffd90e3385 # save the config file mkdir build_dir && cp config build_dir/.config make W=1 O=build_dir ARCH=x86_64 prepare If you fix the issue, kindly add following tag where applicable Reported-by: kernel test robot All error/warnings (new ones prefixed by >>): In file included from include/linux/sched/user.h:7, from include/linux/cred.h:17, from include/linux/sched/signal.h:10, from include/linux/rcuwait.h:6, from include/linux/percpu-rwsem.h:7, from include/linux/fs.h:33, from include/linux/cgroup.h:17, from include/linux/memcontrol.h:13, from include/linux/swap.h:9, from include/linux/suspend.h:5, from arch/x86/kernel/asm-offsets.c:13: include/linux/percpu_counter.h: In function 'percpu_counter_sub_local': >> include/linux/percpu_counter.h:176:9: error: implicit declaration of function 'percpu_counter_sub'; did you mean 'percpu_counter_set'? [-Werror=implicit-function-declaration] 176 | percpu_counter_sub(fbc, amount); | ^~~~~~~~~~~~~~~~~~ | percpu_counter_set include/linux/percpu_counter.h: At top level: >> include/linux/percpu_counter.h:229:20: warning: conflicting types for 'percpu_counter_sub'; have 'void(struct percpu_counter *, s64)' {aka 'void(struct percpu_counter *, long long int)'} 229 | static inline void percpu_counter_sub(struct percpu_counter *fbc, s64 amount) | ^~~~~~~~~~~~~~~~~~ >> include/linux/percpu_counter.h:229:20: error: static declaration of 'percpu_counter_sub' follows non-static declaration include/linux/percpu_counter.h:176:9: note: previous implicit declaration of 'percpu_counter_sub' with type 'void(struct percpu_counter *, s64)' {aka 'void(struct percpu_counter *, long long int)'} 176 | percpu_counter_sub(fbc, amount); | ^~~~~~~~~~~~~~~~~~ cc1: some warnings being treated as errors make[2]: *** [scripts/Makefile.build:117: arch/x86/kernel/asm-offsets.s] Error 1 make[2]: Target '__build' not remade because of errors. make[1]: *** [Makefile:1206: prepare0] Error 2 make[1]: Target 'prepare' not remade because of errors. make: *** [Makefile:222: __sub-make] Error 2 make: Target 'prepare' not remade because of errors. vim +176 include/linux/percpu_counter.h 171 172 /* no smp percpu_counter_sub_local is the same with percpu_counter_sub */ 173 static inline void 174 percpu_counter_sub_local(struct percpu_counter *fbc, s64 amount) 175 { > 176 percpu_counter_sub(fbc, amount); 177 } 178 179 static inline void 180 percpu_counter_add_batch(struct percpu_counter *fbc, s64 amount, s32 batch) 181 { 182 percpu_counter_add(fbc, amount); 183 } 184 185 static inline s64 percpu_counter_read(struct percpu_counter *fbc) 186 { 187 return fbc->count; 188 } 189 190 /* 191 * percpu_counter is intended to track positive numbers. In the UP case the 192 * number should never be negative. 193 */ 194 static inline s64 percpu_counter_read_positive(struct percpu_counter *fbc) 195 { 196 return fbc->count; 197 } 198 199 static inline s64 percpu_counter_sum_positive(struct percpu_counter *fbc) 200 { 201 return percpu_counter_read_positive(fbc); 202 } 203 204 static inline s64 percpu_counter_sum(struct percpu_counter *fbc) 205 { 206 return percpu_counter_read(fbc); 207 } 208 209 static inline bool percpu_counter_initialized(struct percpu_counter *fbc) 210 { 211 return true; 212 } 213 214 static inline void percpu_counter_sync(struct percpu_counter *fbc) 215 { 216 } 217 #endif /* CONFIG_SMP */ 218 219 static inline void percpu_counter_inc(struct percpu_counter *fbc) 220 { 221 percpu_counter_add(fbc, 1); 222 } 223 224 static inline void percpu_counter_dec(struct percpu_counter *fbc) 225 { 226 percpu_counter_add(fbc, -1); 227 } 228 > 229 static inline void percpu_counter_sub(struct percpu_counter *fbc, s64 amount) 230 { 231 percpu_counter_add(fbc, -amount); 232 } 233 -- 0-DAY CI Kernel Test Service https://01.org/lkp