[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <202103091750.bPnySE1c-lkp@intel.com>
Date: Tue, 9 Mar 2021 17:43:39 +0800
From: kernel test robot <lkp@...el.com>
To: Minchan Kim <minchan@...nel.org>,
Andrew Morton <akpm@...ux-foundation.org>
Cc: kbuild-all@...org,
Linux Memory Management List <linux-mm@...ck.org>,
LKML <linux-kernel@...r.kernel.org>, joaodias@...gle.com,
surenb@...gle.com, cgoldswo@...eaurora.org, willy@...radead.org,
mhocko@...e.com, david@...hat.com, vbabka@...e.cz
Subject: Re: [PATCH v2 1/2] mm: disable LRU pagevec during the migration
temporarily
Hi Minchan,
I love your patch! Yet something to improve:
[auto build test ERROR on linux/master]
[also build test ERROR on linus/master v5.12-rc2 next-20210309]
[cannot apply to hnaz-linux-mm/master]
[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]
url: https://github.com/0day-ci/linux/commits/Minchan-Kim/mm-disable-LRU-pagevec-during-the-migration-temporarily/20210309-131826
base: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git 144c79ef33536b4ecb4951e07dbc1f2b7fa99d32
config: powerpc-skiroot_defconfig (attached as .config)
compiler: powerpc64le-linux-gcc (GCC) 9.3.0
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://github.com/0day-ci/linux/commit/e746db1a2ab13441890fa2cad8604bbec190b401
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Minchan-Kim/mm-disable-LRU-pagevec-during-the-migration-temporarily/20210309-131826
git checkout e746db1a2ab13441890fa2cad8604bbec190b401
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=powerpc
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@...el.com>
All errors (new ones prefixed by >>):
In file included from mm/mempolicy.c:92:
include/linux/migrate.h: In function 'migrate_prep':
include/linux/migrate.h:70:48: error: 'return' with a value, in function returning void [-Werror=return-type]
70 | static inline void migrate_prep(void) { return -ENOSYS; }
| ^
include/linux/migrate.h:70:20: note: declared here
70 | static inline void migrate_prep(void) { return -ENOSYS; }
| ^~~~~~~~~~~~
include/linux/migrate.h: In function 'migrate_prep_local':
include/linux/migrate.h:71:54: error: 'return' with a value, in function returning void [-Werror=return-type]
71 | static inline void migrate_prep_local(void) { return -ENOSYS; }
| ^
include/linux/migrate.h:71:20: note: declared here
71 | static inline void migrate_prep_local(void) { return -ENOSYS; }
| ^~~~~~~~~~~~~~~~~~
mm/mempolicy.c: In function 'do_mbind':
>> mm/mempolicy.c:1378:3: error: implicit declaration of function 'migrate_finish'; did you mean 'migrate_done'? [-Werror=implicit-function-declaration]
1378 | migrate_finish();
| ^~~~~~~~~~~~~~
| migrate_done
cc1: some warnings being treated as errors
vim +1378 mm/mempolicy.c
1277
1278 static long do_mbind(unsigned long start, unsigned long len,
1279 unsigned short mode, unsigned short mode_flags,
1280 nodemask_t *nmask, unsigned long flags)
1281 {
1282 struct mm_struct *mm = current->mm;
1283 struct mempolicy *new;
1284 unsigned long end;
1285 int err;
1286 int ret;
1287 LIST_HEAD(pagelist);
1288
1289 if (flags & ~(unsigned long)MPOL_MF_VALID)
1290 return -EINVAL;
1291 if ((flags & MPOL_MF_MOVE_ALL) && !capable(CAP_SYS_NICE))
1292 return -EPERM;
1293
1294 if (start & ~PAGE_MASK)
1295 return -EINVAL;
1296
1297 if (mode == MPOL_DEFAULT)
1298 flags &= ~MPOL_MF_STRICT;
1299
1300 len = (len + PAGE_SIZE - 1) & PAGE_MASK;
1301 end = start + len;
1302
1303 if (end < start)
1304 return -EINVAL;
1305 if (end == start)
1306 return 0;
1307
1308 new = mpol_new(mode, mode_flags, nmask);
1309 if (IS_ERR(new))
1310 return PTR_ERR(new);
1311
1312 if (flags & MPOL_MF_LAZY)
1313 new->flags |= MPOL_F_MOF;
1314
1315 /*
1316 * If we are using the default policy then operation
1317 * on discontinuous address spaces is okay after all
1318 */
1319 if (!new)
1320 flags |= MPOL_MF_DISCONTIG_OK;
1321
1322 pr_debug("mbind %lx-%lx mode:%d flags:%d nodes:%lx\n",
1323 start, start + len, mode, mode_flags,
1324 nmask ? nodes_addr(*nmask)[0] : NUMA_NO_NODE);
1325
1326 if (flags & (MPOL_MF_MOVE | MPOL_MF_MOVE_ALL)) {
1327
1328 migrate_prep();
1329 }
1330 {
1331 NODEMASK_SCRATCH(scratch);
1332 if (scratch) {
1333 mmap_write_lock(mm);
1334 err = mpol_set_nodemask(new, nmask, scratch);
1335 if (err)
1336 mmap_write_unlock(mm);
1337 } else
1338 err = -ENOMEM;
1339 NODEMASK_SCRATCH_FREE(scratch);
1340 }
1341 if (err)
1342 goto mpol_out;
1343
1344 ret = queue_pages_range(mm, start, end, nmask,
1345 flags | MPOL_MF_INVERT, &pagelist);
1346
1347 if (ret < 0) {
1348 err = ret;
1349 goto up_out;
1350 }
1351
1352 err = mbind_range(mm, start, end, new);
1353
1354 if (!err) {
1355 int nr_failed = 0;
1356
1357 if (!list_empty(&pagelist)) {
1358 WARN_ON_ONCE(flags & MPOL_MF_LAZY);
1359 nr_failed = migrate_pages(&pagelist, new_page, NULL,
1360 start, MIGRATE_SYNC, MR_MEMPOLICY_MBIND);
1361 if (nr_failed)
1362 putback_movable_pages(&pagelist);
1363 }
1364
1365 if ((ret > 0) || (nr_failed && (flags & MPOL_MF_STRICT)))
1366 err = -EIO;
1367 } else {
1368 up_out:
1369 if (!list_empty(&pagelist))
1370 putback_movable_pages(&pagelist);
1371 }
1372
1373 mmap_write_unlock(mm);
1374 mpol_out:
1375 mpol_put(new);
1376
1377 if (flags & (MPOL_MF_MOVE | MPOL_MF_MOVE_ALL))
> 1378 migrate_finish();
1379
1380 return err;
1381 }
1382
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
Download attachment ".config.gz" of type "application/gzip" (21555 bytes)
Powered by blists - more mailing lists