From: kbuild test robot <lkp@intel.com> Cc: kbuild-all@lists.01.org, songliubraving@fb.com, linux-raid@vger.kernel.org, guoqing.jiang@cloud.ionos.com, Coly Li <colyli@suse.de>, Kent Overstreet <kent.overstreet@gmail.com>, Michal Hocko <mhocko@suse.com> Subject: Re: [PATCH] raid5: use memalloc_noio_save()/restore in resize_chunks() Date: Fri, 3 Apr 2020 21:17:58 +0800 [thread overview] Message-ID: <202004032106.S7qEbIkH%lkp@intel.com> (raw) In-Reply-To: <20200402081312.32709-1-colyli@suse.de> [-- Attachment #1: Type: text/plain, Size: 3509 bytes --] Hi Coly, I love your patch! Yet something to improve: [auto build test ERROR on linus/master] [also build test ERROR on v5.6 next-20200403] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system. BTW, we also suggest to use '--base' option to specify the base tree in git format-patch, please see https://stackoverflow.com/a/37406982] url: https://github.com/0day-ci/linux/commits/Coly-Li/raid5-use-memalloc_noio_save-restore-in-resize_chunks/20200402-215014 base: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git 919dce24701f7b34681a6a1d3ef95c9f6c4fb1cc config: x86_64-rhel (attached as .config) compiler: gcc-7 (Ubuntu 7.5.0-6ubuntu2) 7.5.0 reproduce: # save the attached .config to linux build tree make ARCH=x86_64 If you fix the issue, kindly add following tag Reported-by: kbuild test robot <lkp@intel.com> All errors (new ones prefixed by >>): drivers/md/raid5.c: In function 'scribble_alloc': drivers/md/raid5.c:2237:15: warning: unused variable 'noio_flag' [-Wunused-variable] unsigned int noio_flag; ^~~~~~~~~ drivers/md/raid5.c: In function 'resize_chunks': >> drivers/md/raid5.c:2275:14: error: implicit declaration of function 'memalloc_noio_save'; did you mean 'vmalloc_to_page'? [-Werror=implicit-function-declaration] noio_flag = memalloc_noio_save(); ^~~~~~~~~~~~~~~~~~ vmalloc_to_page >> drivers/md/raid5.c:2285:2: error: implicit declaration of function 'memalloc_noio_restore'; did you mean '__vmalloc_node_range'? [-Werror=implicit-function-declaration] memalloc_noio_restore(noio_flag); ^~~~~~~~~~~~~~~~~~~~~ __vmalloc_node_range cc1: some warnings being treated as errors vim +2275 drivers/md/raid5.c 2249 2250 static int resize_chunks(struct r5conf *conf, int new_disks, int new_sectors) 2251 { 2252 unsigned long cpu; 2253 int err = 0; 2254 unsigned int noio_flag; 2255 2256 /* 2257 * Never shrink. And mddev_suspend() could deadlock if this is called 2258 * from raid5d. In that case, scribble_disks and scribble_sectors 2259 * should equal to new_disks and new_sectors 2260 */ 2261 if (conf->scribble_disks >= new_disks && 2262 conf->scribble_sectors >= new_sectors) 2263 return 0; 2264 mddev_suspend(conf->mddev); 2265 get_online_cpus(); 2266 2267 /* 2268 * scribble_alloc() allocates memory by kvmalloc_array(), if 2269 * the memory allocation triggers memory reclaim I/Os onto 2270 * this raid array, there might be potential deadlock if this 2271 * raid array happens to be suspended during memory allocation. 2272 * Here the scope APIs are used to disable such recursive memory 2273 * reclaim I/Os. 2274 */ > 2275 noio_flag = memalloc_noio_save(); 2276 for_each_present_cpu(cpu) { 2277 struct raid5_percpu *percpu; 2278 2279 percpu = per_cpu_ptr(conf->percpu, cpu); 2280 err = scribble_alloc(percpu, new_disks, 2281 new_sectors / STRIPE_SECTORS); 2282 if (err) 2283 break; 2284 } > 2285 memalloc_noio_restore(noio_flag); 2286 2287 put_online_cpus(); 2288 mddev_resume(conf->mddev); 2289 if (!err) { 2290 conf->scribble_disks = new_disks; 2291 conf->scribble_sectors = new_sectors; 2292 } 2293 return err; 2294 } 2295 --- 0-DAY CI Kernel Test Service, Intel Corporation https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org [-- Attachment #2: .config.gz --] [-- Type: application/gzip, Size: 44475 bytes --]
WARNING: multiple messages have this Message-ID (diff)
From: kbuild test robot <lkp@intel.com> To: kbuild-all@lists.01.org Subject: Re: [PATCH] raid5: use memalloc_noio_save()/restore in resize_chunks() Date: Fri, 03 Apr 2020 21:17:58 +0800 [thread overview] Message-ID: <202004032106.S7qEbIkH%lkp@intel.com> (raw) In-Reply-To: <20200402081312.32709-1-colyli@suse.de> [-- Attachment #1: Type: text/plain, Size: 3602 bytes --] Hi Coly, I love your patch! Yet something to improve: [auto build test ERROR on linus/master] [also build test ERROR on v5.6 next-20200403] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system. BTW, we also suggest to use '--base' option to specify the base tree in git format-patch, please see https://stackoverflow.com/a/37406982] url: https://github.com/0day-ci/linux/commits/Coly-Li/raid5-use-memalloc_noio_save-restore-in-resize_chunks/20200402-215014 base: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git 919dce24701f7b34681a6a1d3ef95c9f6c4fb1cc config: x86_64-rhel (attached as .config) compiler: gcc-7 (Ubuntu 7.5.0-6ubuntu2) 7.5.0 reproduce: # save the attached .config to linux build tree make ARCH=x86_64 If you fix the issue, kindly add following tag Reported-by: kbuild test robot <lkp@intel.com> All errors (new ones prefixed by >>): drivers/md/raid5.c: In function 'scribble_alloc': drivers/md/raid5.c:2237:15: warning: unused variable 'noio_flag' [-Wunused-variable] unsigned int noio_flag; ^~~~~~~~~ drivers/md/raid5.c: In function 'resize_chunks': >> drivers/md/raid5.c:2275:14: error: implicit declaration of function 'memalloc_noio_save'; did you mean 'vmalloc_to_page'? [-Werror=implicit-function-declaration] noio_flag = memalloc_noio_save(); ^~~~~~~~~~~~~~~~~~ vmalloc_to_page >> drivers/md/raid5.c:2285:2: error: implicit declaration of function 'memalloc_noio_restore'; did you mean '__vmalloc_node_range'? [-Werror=implicit-function-declaration] memalloc_noio_restore(noio_flag); ^~~~~~~~~~~~~~~~~~~~~ __vmalloc_node_range cc1: some warnings being treated as errors vim +2275 drivers/md/raid5.c 2249 2250 static int resize_chunks(struct r5conf *conf, int new_disks, int new_sectors) 2251 { 2252 unsigned long cpu; 2253 int err = 0; 2254 unsigned int noio_flag; 2255 2256 /* 2257 * Never shrink. And mddev_suspend() could deadlock if this is called 2258 * from raid5d. In that case, scribble_disks and scribble_sectors 2259 * should equal to new_disks and new_sectors 2260 */ 2261 if (conf->scribble_disks >= new_disks && 2262 conf->scribble_sectors >= new_sectors) 2263 return 0; 2264 mddev_suspend(conf->mddev); 2265 get_online_cpus(); 2266 2267 /* 2268 * scribble_alloc() allocates memory by kvmalloc_array(), if 2269 * the memory allocation triggers memory reclaim I/Os onto 2270 * this raid array, there might be potential deadlock if this 2271 * raid array happens to be suspended during memory allocation. 2272 * Here the scope APIs are used to disable such recursive memory 2273 * reclaim I/Os. 2274 */ > 2275 noio_flag = memalloc_noio_save(); 2276 for_each_present_cpu(cpu) { 2277 struct raid5_percpu *percpu; 2278 2279 percpu = per_cpu_ptr(conf->percpu, cpu); 2280 err = scribble_alloc(percpu, new_disks, 2281 new_sectors / STRIPE_SECTORS); 2282 if (err) 2283 break; 2284 } > 2285 memalloc_noio_restore(noio_flag); 2286 2287 put_online_cpus(); 2288 mddev_resume(conf->mddev); 2289 if (!err) { 2290 conf->scribble_disks = new_disks; 2291 conf->scribble_sectors = new_sectors; 2292 } 2293 return err; 2294 } 2295 --- 0-DAY CI Kernel Test Service, Intel Corporation https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org [-- Attachment #2: config.gz --] [-- Type: application/gzip, Size: 44475 bytes --]
next prev parent reply other threads:[~2020-04-03 13:17 UTC|newest] Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top 2020-04-02 8:13 [PATCH] raid5: use memalloc_noio_save()/restore in resize_chunks() Coly Li 2020-04-03 13:17 ` kbuild test robot [this message] 2020-04-03 13:17 ` kbuild test robot 2020-04-05 15:53 ` Guoqing Jiang 2020-04-07 15:09 ` Coly Li 2020-04-09 21:38 ` Guoqing Jiang 2020-04-10 9:36 ` Coly Li 2020-04-15 11:48 ` Michal Hocko 2020-04-15 14:10 ` Guoqing Jiang 2020-04-15 14:23 ` Michal Hocko 2020-04-15 14:57 ` Guoqing Jiang 2020-04-30 6:36 ` Song Liu 2020-04-05 17:43 ` Song Liu 2020-04-07 14:42 ` Coly Li
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=202004032106.S7qEbIkH%lkp@intel.com \ --to=lkp@intel.com \ --cc=colyli@suse.de \ --cc=guoqing.jiang@cloud.ionos.com \ --cc=kbuild-all@lists.01.org \ --cc=kent.overstreet@gmail.com \ --cc=linux-raid@vger.kernel.org \ --cc=mhocko@suse.com \ --cc=songliubraving@fb.com \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.