Received: by 10.213.65.68 with SMTP id h4csp179014imn; Fri, 23 Mar 2018 02:07:28 -0700 (PDT) X-Google-Smtp-Source: AG47ELvOMQpP8IWuF3d7BEpNplQo8wBG2qiUNM+1qefyp0ShDMwVwe5TwgzLepHj3wN88gJhxz1/ X-Received: by 10.98.182.4 with SMTP id j4mr324405pff.207.1521796048889; Fri, 23 Mar 2018 02:07:28 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1521796048; cv=none; d=google.com; s=arc-20160816; b=T8fVIViRhVj7vW9Ec1lLmaAtnEObgJ5Q4RgHWPJWItlm08A3JOjRM5NKn8H0n01nA0 KhelxPRwKgycmpMfkrLK1DdkOwkw7OeGw1tOZ+ZjqTaKX7sW7QnA8+eZLo4PaqKPlFfA /Hnf/v/LSKaYTOlNBJGEzO2c0lnWIpMzNdxR2Se3h4yH2fAcniDYNlZcQ1vxpxQd8tPu BxOadGpTHxhB32j42ISz9edKYtLN2wHdGMSnr8SoSN8p9qgRVYWUqzOQN0bfxZ8Jj0pa GNoz3VozIc5ADGggiWz1Aug9V9W38FF6iIPQeguQm3T4hSC0/D6JGSbJxaXwms8PLn95 U6Fg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:arc-authentication-results; bh=HTA0ShQeRJE6WWc9njAT+4gq34CEJ2HlAmEi/VSHTwU=; b=0CuJRvfjbcPc8x6kp9ICsAeU7COLyj9AdYrmOb93vyXAkh4M1iI3HAkQDcektJ1zRI lxBzFRqUs1SLMnmu+WgrNqVi9f7KjwIkD5zenCXFFSVybEQvyjawvYBrAnU7GmKlSJX3 EKIfv/HT9dSvSn/ExVNONg46wkNAy6NqM0n9gvHoJPwy6TgJvfGdN6pBqT03tySTdP9T mw31IijUzPClM/5PftFPfIrQE0WljWneL6EI2iU7fBjSSG7U6NE8IYRElFhMB8iWlrNt ATjuZK/ojsuXzUxAHppfnyVTz6wzGhBOF4KjeY8Z35WSqRKQpFq3GTD62mfiPy8zsAXM jviQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id e91-v6si3522988plb.73.2018.03.23.02.07.13; Fri, 23 Mar 2018 02:07:28 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751840AbeCWJGS (ORCPT + 99 others); Fri, 23 Mar 2018 05:06:18 -0400 Received: from mga17.intel.com ([192.55.52.151]:49153 "EHLO mga17.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751668AbeCWJGR (ORCPT ); Fri, 23 Mar 2018 05:06:17 -0400 X-Amp-Result: UNKNOWN X-Amp-Original-Verdict: FILE UNKNOWN X-Amp-File-Uploaded: False Received: from fmsmga005.fm.intel.com ([10.253.24.32]) by fmsmga107.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 23 Mar 2018 02:06:17 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.48,349,1517904000"; d="scan'208";a="214185274" Received: from bee.sh.intel.com (HELO bee) ([10.239.97.14]) by fmsmga005.fm.intel.com with ESMTP; 23 Mar 2018 02:06:12 -0700 Received: from kbuild by bee with local (Exim 4.84_2) (envelope-from ) id 1ezIeK-000Of3-3L; Fri, 23 Mar 2018 17:06:12 +0800 Date: Fri, 23 Mar 2018 17:06:07 +0800 From: kbuild test robot To: Kirill Tkhai Cc: kbuild-all@01.org, viro@zeniv.linux.org.uk, hannes@cmpxchg.org, mhocko@kernel.org, vdavydov.dev@gmail.com, ktkhai@virtuozzo.com, akpm@linux-foundation.org, tglx@linutronix.de, pombredanne@nexb.com, stummala@codeaurora.org, gregkh@linuxfoundation.org, sfr@canb.auug.org.au, guro@fb.com, mka@chromium.org, penguin-kernel@I-love.SAKURA.ne.jp, chris@chris-wilson.co.uk, longman@redhat.com, minchan@kernel.org, hillf.zj@alibaba-inc.com, ying.huang@intel.com, mgorman@techsingularity.net, shakeelb@google.com, jbacik@fb.com, linux@roeck-us.net, linux-kernel@vger.kernel.org, linux-mm@kvack.org, willy@infradead.org Subject: Re: [PATCH 03/10] mm: Assign memcg-aware shrinkers bitmap to memcg Message-ID: <201803231640.37BGHC6o%fengguang.wu@intel.com> References: <152163850081.21546.6969747084834474733.stgit@localhost.localdomain> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <152163850081.21546.6969747084834474733.stgit@localhost.localdomain> User-Agent: Mutt/1.5.23 (2014-03-12) X-SA-Exim-Connect-IP: X-SA-Exim-Mail-From: fengguang.wu@intel.com X-SA-Exim-Scanned: No (on bee); SAEximRunCond expanded to false Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Kirill, Thank you for the patch! Perhaps something to improve: [auto build test WARNING on mmotm/master] [also build test WARNING on v4.16-rc6 next-20180322] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system] url: https://github.com/0day-ci/linux/commits/Kirill-Tkhai/Improve-shrink_slab-scalability-old-complexity-was-O-n-2-new-is-O-n/20180323-052754 base: git://git.cmpxchg.org/linux-mmotm.git master reproduce: # apt-get install sparse make ARCH=x86_64 allmodconfig make C=1 CF=-D__CHECK_ENDIAN__ sparse warnings: (new ones prefixed by >>) include/trace/events/vmscan.h:79:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:79:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:79:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:79:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:79:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:79:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:79:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:79:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:79:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:79:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:79:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:79:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:79:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:79:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:79:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:79:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:79:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:79:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:79:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:79:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:79:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:79:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:79:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:79:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:79:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:79:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:79:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:79:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:79:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:79:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:79:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:79:1: sparse: incorrect type in argument 3 (different base types) @@ expected unsigned long [unsigned] flags @@ got resunsigned long [unsigned] flags @@ include/trace/events/vmscan.h:79:1: expected unsigned long [unsigned] flags include/trace/events/vmscan.h:79:1: got restricted gfp_t [usertype] gfp_flags include/trace/events/vmscan.h:106:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:106:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:106:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:106:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:106:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:106:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:106:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:106:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:106:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:106:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:106:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:106:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:106:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:106:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:106:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:106:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:106:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:106:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:106:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:106:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:106:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:106:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:106:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:106:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:106:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:106:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:106:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:106:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:106:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:106:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:106:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:106:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:106:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:106:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:106:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:106:1: sparse: incorrect type in argument 3 (different base types) @@ expected unsigned long [unsigned] flags @@ got resunsigned long [unsigned] flags @@ include/trace/events/vmscan.h:106:1: expected unsigned long [unsigned] flags include/trace/events/vmscan.h:106:1: got restricted gfp_t [usertype] gfp_flags include/trace/events/vmscan.h:196:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:196:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:196:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:196:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:196:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:196:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:196:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:196:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:196:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:196:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:196:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:196:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:196:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:196:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:196:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:196:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:196:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:196:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:196:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:196:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:196:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:196:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:196:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:196:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:196:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:196:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:196:1: sparse: cast from restricted gfp_t include/trace/events/vmscan.h:196:1: sparse: too many warnings >> mm/vmscan.c:231:15: sparse: incompatible types in conditional expression (different address spaces) >> mm/vmscan.c:231:15: sparse: cast from unknown type >> mm/vmscan.c:231:15: sparse: incompatible types in conditional expression (different address spaces) >> mm/vmscan.c:231:15: sparse: incompatible types in conditional expression (different address spaces) >> mm/vmscan.c:231:15: sparse: cast from unknown type vim +231 mm/vmscan.c 205 206 static int memcg_expand_maps(struct mem_cgroup *memcg, int size, int old_size) 207 { 208 struct shrinkers_map *new, *old; 209 int i; 210 211 new = kvmalloc(sizeof(*new) + nr_node_ids * sizeof(new->map[0]), 212 GFP_KERNEL); 213 if (!new) 214 return -ENOMEM; 215 216 for (i = 0; i < nr_node_ids; i++) { 217 new->map[i] = kvmalloc_node(size, GFP_KERNEL, i); 218 if (!new->map[i]) { 219 while (--i >= 0) 220 kvfree(new->map[i]); 221 kvfree(new); 222 return -ENOMEM; 223 } 224 225 /* Set all old bits, clear all new bits */ 226 memset(new->map[i], (int)0xff, old_size); 227 memset((void *)new->map[i] + old_size, 0, size - old_size); 228 } 229 230 lockdep_assert_held(&bitmap_rwsem); > 231 old = rcu_dereference_protected(SHRINKERS_MAP(memcg), true); 232 233 /* 234 * We don't want to use rcu_read_lock() in shrink_slab(). 235 * Since expansion happens rare, we may just take the lock 236 * here. 237 */ 238 if (old) 239 down_write(&shrinker_rwsem); 240 241 if (memcg) 242 rcu_assign_pointer(memcg->shrinkers_map, new); 243 else 244 rcu_assign_pointer(root_shrinkers_map, new); 245 246 if (old) { 247 up_write(&shrinker_rwsem); 248 call_rcu(&old->rcu, kvfree_map_rcu); 249 } 250 251 return 0; 252 } 253 --- 0-DAY kernel test infrastructure Open Source Technology Center https://lists.01.org/pipermail/kbuild-all Intel Corporation