tree:
https://android.googlesource.com/kernel/common android13-5.15
head: 5c9cf613be14804250ff56fe5651760b3acf2c91
commit: 42db6c2e985bd4805fd6c74a6e8749cf72e084a7 [1/3] ANDROID: mm/memory_hotplug:
implement {add/remove}_memory_subsection
config: x86_64-randconfig-r021-20211210
(
https://download.01.org/0day-ci/archive/20211210/202112101536.eWkoI5S7-lk...)
compiler: clang version 14.0.0 (
https://github.com/llvm/llvm-project
097a1cb1d5ebb3a0ec4bcaed8ba3ff6a8e33c00a)
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
git remote add android-common
https://android.googlesource.com/kernel/common
git fetch --no-tags android-common android13-5.15
git checkout 42db6c2e985bd4805fd6c74a6e8749cf72e084a7
# save the config file to linux build tree
mkdir build_dir
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir
ARCH=x86_64 SHELL=/bin/bash
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All warnings (new ones prefixed by >>):
> mm/memory_hotplug.c:1505:17: warning: format specifies type
'unsigned long' but the argument has type 'u64' (aka 'unsigned long
long') [-Wformat]
__func__, start, size);
^~~~~
include/linux/printk.h:493:33: note: expanded from macro 'pr_err'
printk(KERN_ERR pr_fmt(fmt), ##__VA_ARGS__)
~~~ ^~~~~~~~~~~
include/linux/printk.h:450:60: note: expanded from macro 'printk'
#define printk(fmt, ...) printk_index_wrap(_printk, fmt, ##__VA_ARGS__)
~~~ ^~~~~~~~~~~
include/linux/printk.h:422:19: note: expanded from macro 'printk_index_wrap'
_p_func(_fmt, ##__VA_ARGS__); \
~~~~ ^~~~~~~~~~~
mm/memory_hotplug.c:1505:24: warning: format specifies type 'unsigned long' but
the argument has type 'u64' (aka 'unsigned long long') [-Wformat]
__func__, start, size);
^~~~
include/linux/printk.h:493:33: note: expanded from macro 'pr_err'
printk(KERN_ERR pr_fmt(fmt), ##__VA_ARGS__)
~~~ ^~~~~~~~~~~
include/linux/printk.h:450:60: note: expanded from macro 'printk'
#define printk(fmt, ...) printk_index_wrap(_printk, fmt, ##__VA_ARGS__)
~~~ ^~~~~~~~~~~
include/linux/printk.h:422:19: note: expanded from macro 'printk_index_wrap'
_p_func(_fmt, ##__VA_ARGS__); \
~~~~ ^~~~~~~~~~~
mm/memory_hotplug.c:1525:17: warning: format specifies type 'unsigned long' but
the argument has type 'u64' (aka 'unsigned long long') [-Wformat]
__func__, start, size);
^~~~~
include/linux/printk.h:493:33: note: expanded from macro 'pr_err'
printk(KERN_ERR pr_fmt(fmt), ##__VA_ARGS__)
~~~ ^~~~~~~~~~~
include/linux/printk.h:450:60: note: expanded from macro 'printk'
#define printk(fmt, ...) printk_index_wrap(_printk, fmt, ##__VA_ARGS__)
~~~ ^~~~~~~~~~~
include/linux/printk.h:422:19: note: expanded from macro 'printk_index_wrap'
_p_func(_fmt, ##__VA_ARGS__); \
~~~~ ^~~~~~~~~~~
mm/memory_hotplug.c:1525:24: warning: format specifies type 'unsigned long' but
the argument has type 'u64' (aka 'unsigned long long') [-Wformat]
__func__, start, size);
^~~~
include/linux/printk.h:493:33: note: expanded from macro 'pr_err'
printk(KERN_ERR pr_fmt(fmt), ##__VA_ARGS__)
~~~ ^~~~~~~~~~~
include/linux/printk.h:450:60: note: expanded from macro 'printk'
#define printk(fmt, ...) printk_index_wrap(_printk, fmt, ##__VA_ARGS__)
~~~ ^~~~~~~~~~~
include/linux/printk.h:422:19: note: expanded from macro 'printk_index_wrap'
_p_func(_fmt, ##__VA_ARGS__); \
~~~~ ^~~~~~~~~~~
mm/memory_hotplug.c:2304:17: warning: format specifies type 'unsigned long' but
the argument has type 'u64' (aka 'unsigned long long') [-Wformat]
__func__, start, size);
^~~~~
include/linux/printk.h:493:33: note: expanded from macro 'pr_err'
printk(KERN_ERR pr_fmt(fmt), ##__VA_ARGS__)
~~~ ^~~~~~~~~~~
include/linux/printk.h:450:60: note: expanded from macro 'printk'
#define printk(fmt, ...) printk_index_wrap(_printk, fmt, ##__VA_ARGS__)
~~~ ^~~~~~~~~~~
include/linux/printk.h:422:19: note: expanded from macro 'printk_index_wrap'
_p_func(_fmt, ##__VA_ARGS__); \
~~~~ ^~~~~~~~~~~
mm/memory_hotplug.c:2304:24: warning: format specifies type 'unsigned long' but
the argument has type 'u64' (aka 'unsigned long long') [-Wformat]
__func__, start, size);
^~~~
include/linux/printk.h:493:33: note: expanded from macro 'pr_err'
printk(KERN_ERR pr_fmt(fmt), ##__VA_ARGS__)
~~~ ^~~~~~~~~~~
include/linux/printk.h:450:60: note: expanded from macro 'printk'
#define printk(fmt, ...) printk_index_wrap(_printk, fmt, ##__VA_ARGS__)
~~~ ^~~~~~~~~~~
include/linux/printk.h:422:19: note: expanded from macro 'printk_index_wrap'
_p_func(_fmt, ##__VA_ARGS__); \
~~~~ ^~~~~~~~~~~
mm/memory_hotplug.c:2312:17: warning: format specifies type 'unsigned long' but
the argument has type 'u64' (aka 'unsigned long long') [-Wformat]
__func__, start, start + size);
^~~~~
include/linux/printk.h:493:33: note: expanded from macro 'pr_err'
printk(KERN_ERR pr_fmt(fmt), ##__VA_ARGS__)
~~~ ^~~~~~~~~~~
include/linux/printk.h:450:60: note: expanded from macro 'printk'
#define printk(fmt, ...) printk_index_wrap(_printk, fmt, ##__VA_ARGS__)
~~~ ^~~~~~~~~~~
include/linux/printk.h:422:19: note: expanded from macro 'printk_index_wrap'
_p_func(_fmt, ##__VA_ARGS__); \
~~~~ ^~~~~~~~~~~
mm/memory_hotplug.c:2312:24: warning: format specifies type 'unsigned long' but
the argument has type 'unsigned long long' [-Wformat]
__func__, start, start + size);
^~~~~~~~~~~~
include/linux/printk.h:493:33: note: expanded from macro 'pr_err'
printk(KERN_ERR pr_fmt(fmt), ##__VA_ARGS__)
~~~ ^~~~~~~~~~~
include/linux/printk.h:450:60: note: expanded from macro 'printk'
#define printk(fmt, ...) printk_index_wrap(_printk, fmt, ##__VA_ARGS__)
~~~ ^~~~~~~~~~~
include/linux/printk.h:422:19: note: expanded from macro 'printk_index_wrap'
_p_func(_fmt, ##__VA_ARGS__); \
~~~~ ^~~~~~~~~~~
8 warnings generated.
Kconfig warnings: (for reference only)
WARNING: unmet direct dependencies detected for ASYNC_TX_ENABLE_CHANNEL_SWITCH
Depends on DMADEVICES
Selected by
- GKI_HIDDEN_DMA_CONFIGS
vim +1505 mm/memory_hotplug.c
1492
1493 int add_memory_subsection(int nid, u64 start, u64 size)
1494 {
1495 struct mhp_params params = { .pgprot = PAGE_KERNEL };
1496 struct resource *res;
1497 int ret;
1498
1499 if (size == memory_block_size_bytes())
1500 return add_memory(nid, start, size, MHP_NONE);
1501
1502 if (!IS_ALIGNED(start, SUBSECTION_SIZE) ||
1503 !IS_ALIGNED(size, SUBSECTION_SIZE)) {
1504 pr_err("%s: start 0x%lx size 0x%lx not aligned to subsection size\n",
1505 __func__, start, size);
1506 return -EINVAL;
1507 }
1508
1509 res = register_memory_resource(start, size, "System RAM");
1510 if (IS_ERR(res))
1511 return PTR_ERR(res);
1512
1513 mem_hotplug_begin();
1514
1515 nid = memory_add_physaddr_to_nid(start);
1516
1517 if (IS_ENABLED(CONFIG_ARCH_KEEP_MEMBLOCK))
1518 memblock_add_node(start, size, nid);
1519
1520 ret = arch_add_memory(nid, start, size, ¶ms);
1521 if (ret) {
1522 if (IS_ENABLED(CONFIG_ARCH_KEEP_MEMBLOCK))
1523 memblock_remove(start, size);
1524 pr_err("%s failed to add subsection start 0x%lx size 0x%lx\n",
1525 __func__, start, size);
1526 }
1527 mem_hotplug_done();
1528
1529 return ret;
1530 }
1531 EXPORT_SYMBOL_GPL(add_memory_subsection);
1532
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org