From: kernel test robot <lkp@intel.com>
To: Yunhui Cui <cuiyunhui@bytedance.com>,
yury.norov@gmail.com, linux@rasmusvillemoes.dk,
paul.walmsley@sifive.com, palmer@dabbelt.com,
aou@eecs.berkeley.edu, alex@ghiti.fr,
linux-riscv@lists.infradead.org, linux-kernel@vger.kernel.org,
dennis@kernel.org, tj@kernel.org, cl@gentwo.org,
linux-mm@kvack.org
Cc: llvm@lists.linux.dev, oe-kbuild-all@lists.linux.dev,
Yunhui Cui <cuiyunhui@bytedance.com>
Subject: Re: [PATCH 2/2] riscv: introduce percpu.h into include/asm
Date: Wed, 20 Aug 2025 14:44:54 +0800 [thread overview]
Message-ID: <202508201452.ciEgfhNO-lkp@intel.com> (raw)
In-Reply-To: <20250819135007.85646-3-cuiyunhui@bytedance.com>
Hi Yunhui,
kernel test robot noticed the following build warnings:
[auto build test WARNING on linus/master]
[also build test WARNING on dennis-percpu/for-next v6.17-rc2 next-20250819]
[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/Yunhui-Cui/riscv-remove-irqflags-h-inclusion-in-asm-bitops-h/20250819-215256
base: linus/master
patch link: https://lore.kernel.org/r/20250819135007.85646-3-cuiyunhui%40bytedance.com
patch subject: [PATCH 2/2] riscv: introduce percpu.h into include/asm
config: riscv-randconfig-002-20250820 (https://download.01.org/0day-ci/archive/20250820/202508201452.ciEgfhNO-lkp@intel.com/config)
compiler: clang version 22.0.0git (https://github.com/llvm/llvm-project 93d24b6b7b148c47a2fa228a4ef31524fa1d9f3f)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250820/202508201452.ciEgfhNO-lkp@intel.com/reproduce)
If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202508201452.ciEgfhNO-lkp@intel.com/
All warnings (new ones prefixed by >>):
In file included from arch/riscv/kernel/asm-offsets.c:8:
In file included from include/linux/mm.h:7:
In file included from include/linux/gfp.h:7:
In file included from include/linux/mmzone.h:22:
In file included from include/linux/mm_types.h:19:
In file included from include/linux/workqueue.h:9:
>> include/linux/alloc_tag.h:219:2: warning: implicit conversion from 'typeof (tag->counters->calls)' (aka 'unsigned long long') to 'unsigned long' changes value from 18446744073709551615 to 4294967295 [-Wconstant-conversion]
219 | this_cpu_dec(tag->counters->calls);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/linux/percpu-defs.h:512:28: note: expanded from macro 'this_cpu_dec'
512 | #define this_cpu_dec(pcp) this_cpu_sub(pcp, 1)
| ^~~~~~~~~~~~~~~~~~~~
include/linux/percpu-defs.h:510:51: note: expanded from macro 'this_cpu_sub'
510 | #define this_cpu_sub(pcp, val) this_cpu_add(pcp, -(typeof(pcp))(val))
| ~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~
include/linux/percpu-defs.h:501:70: note: expanded from macro 'this_cpu_add'
501 | #define this_cpu_add(pcp, val) __pcpu_size_call(this_cpu_add_, pcp, val)
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~
include/linux/percpu-defs.h:372:29: note: expanded from macro '__pcpu_size_call'
372 | case 8: stem##8(variable, __VA_ARGS__);break; \
| ~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~
arch/riscv/include/asm/percpu.h:96:78: note: expanded from macro 'this_cpu_add_8'
96 | #define this_cpu_add_8(pcp, val) _pcp_protect(__percpu_add_amo_case_64, pcp, val)
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~
arch/riscv/include/asm/percpu.h:72:26: note: expanded from macro '_pcp_protect'
72 | op(raw_cpu_ptr(&(pcp)), __VA_ARGS__); \
| ~~ ^~~~~~~~~~~
1 warning generated.
--
In file included from arch/riscv/errata/sifive/errata.c:7:
In file included from include/linux/memory.h:19:
In file included from include/linux/node.h:18:
In file included from include/linux/device.h:16:
In file included from include/linux/energy_model.h:7:
In file included from include/linux/kobject.h:20:
In file included from include/linux/sysfs.h:16:
In file included from include/linux/kernfs.h:12:
In file included from include/linux/idr.h:15:
In file included from include/linux/radix-tree.h:16:
In file included from include/linux/percpu.h:5:
>> include/linux/alloc_tag.h:219:2: warning: implicit conversion from 'typeof (tag->counters->calls)' (aka 'unsigned long long') to 'unsigned long' changes value from 18446744073709551615 to 4294967295 [-Wconstant-conversion]
219 | this_cpu_dec(tag->counters->calls);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/linux/percpu-defs.h:512:28: note: expanded from macro 'this_cpu_dec'
512 | #define this_cpu_dec(pcp) this_cpu_sub(pcp, 1)
| ^~~~~~~~~~~~~~~~~~~~
include/linux/percpu-defs.h:510:51: note: expanded from macro 'this_cpu_sub'
510 | #define this_cpu_sub(pcp, val) this_cpu_add(pcp, -(typeof(pcp))(val))
| ~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~
include/linux/percpu-defs.h:501:70: note: expanded from macro 'this_cpu_add'
501 | #define this_cpu_add(pcp, val) __pcpu_size_call(this_cpu_add_, pcp, val)
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~
include/linux/percpu-defs.h:372:29: note: expanded from macro '__pcpu_size_call'
372 | case 8: stem##8(variable, __VA_ARGS__);break; \
| ~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~
arch/riscv/include/asm/percpu.h:96:78: note: expanded from macro 'this_cpu_add_8'
96 | #define this_cpu_add_8(pcp, val) _pcp_protect(__percpu_add_amo_case_64, pcp, val)
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~
arch/riscv/include/asm/percpu.h:72:26: note: expanded from macro '_pcp_protect'
72 | op(raw_cpu_ptr(&(pcp)), __VA_ARGS__); \
| ~~ ^~~~~~~~~~~
arch/riscv/errata/sifive/errata.c:29:14: warning: result of comparison of constant 9223372036854775815 with expression of type 'unsigned long' is always true [-Wtautological-constant-out-of-range-compare]
29 | if (arch_id != 0x8000000000000007 ||
| ~~~~~~~ ^ ~~~~~~~~~~~~~~~~~~
arch/riscv/errata/sifive/errata.c:42:14: warning: result of comparison of constant 9223372036854775815 with expression of type 'unsigned long' is always true [-Wtautological-constant-out-of-range-compare]
42 | if (arch_id != 0x8000000000000007 && arch_id != 0x1)
| ~~~~~~~ ^ ~~~~~~~~~~~~~~~~~~
3 warnings generated.
--
In file included from arch/riscv/kernel/asm-offsets.c:8:
In file included from include/linux/mm.h:7:
In file included from include/linux/gfp.h:7:
In file included from include/linux/mmzone.h:22:
In file included from include/linux/mm_types.h:19:
In file included from include/linux/workqueue.h:9:
>> include/linux/alloc_tag.h:219:2: warning: implicit conversion from 'typeof (tag->counters->calls)' (aka 'unsigned long long') to 'unsigned long' changes value from 18446744073709551615 to 4294967295 [-Wconstant-conversion]
219 | this_cpu_dec(tag->counters->calls);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/linux/percpu-defs.h:512:28: note: expanded from macro 'this_cpu_dec'
512 | #define this_cpu_dec(pcp) this_cpu_sub(pcp, 1)
| ^~~~~~~~~~~~~~~~~~~~
include/linux/percpu-defs.h:510:51: note: expanded from macro 'this_cpu_sub'
510 | #define this_cpu_sub(pcp, val) this_cpu_add(pcp, -(typeof(pcp))(val))
| ~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~
include/linux/percpu-defs.h:501:70: note: expanded from macro 'this_cpu_add'
501 | #define this_cpu_add(pcp, val) __pcpu_size_call(this_cpu_add_, pcp, val)
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~
include/linux/percpu-defs.h:372:29: note: expanded from macro '__pcpu_size_call'
372 | case 8: stem##8(variable, __VA_ARGS__);break; \
| ~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~
arch/riscv/include/asm/percpu.h:96:78: note: expanded from macro 'this_cpu_add_8'
96 | #define this_cpu_add_8(pcp, val) _pcp_protect(__percpu_add_amo_case_64, pcp, val)
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~
arch/riscv/include/asm/percpu.h:72:26: note: expanded from macro '_pcp_protect'
72 | op(raw_cpu_ptr(&(pcp)), __VA_ARGS__); \
| ~~ ^~~~~~~~~~~
1 warning generated.
vim +219 include/linux/alloc_tag.h
22d407b164ff79 Suren Baghdasaryan 2024-03-21 202
22d407b164ff79 Suren Baghdasaryan 2024-03-21 203 static inline void alloc_tag_sub(union codetag_ref *ref, size_t bytes)
22d407b164ff79 Suren Baghdasaryan 2024-03-21 204 {
22d407b164ff79 Suren Baghdasaryan 2024-03-21 205 struct alloc_tag *tag;
22d407b164ff79 Suren Baghdasaryan 2024-03-21 206
22d407b164ff79 Suren Baghdasaryan 2024-03-21 207 alloc_tag_sub_check(ref);
22d407b164ff79 Suren Baghdasaryan 2024-03-21 208 if (!ref || !ref->ct)
22d407b164ff79 Suren Baghdasaryan 2024-03-21 209 return;
22d407b164ff79 Suren Baghdasaryan 2024-03-21 210
239d6c96d86f8a Suren Baghdasaryan 2024-03-21 211 if (is_codetag_empty(ref)) {
239d6c96d86f8a Suren Baghdasaryan 2024-03-21 212 ref->ct = NULL;
239d6c96d86f8a Suren Baghdasaryan 2024-03-21 213 return;
239d6c96d86f8a Suren Baghdasaryan 2024-03-21 214 }
239d6c96d86f8a Suren Baghdasaryan 2024-03-21 215
22d407b164ff79 Suren Baghdasaryan 2024-03-21 216 tag = ct_to_alloc_tag(ref->ct);
22d407b164ff79 Suren Baghdasaryan 2024-03-21 217
22d407b164ff79 Suren Baghdasaryan 2024-03-21 218 this_cpu_sub(tag->counters->bytes, bytes);
22d407b164ff79 Suren Baghdasaryan 2024-03-21 @219 this_cpu_dec(tag->counters->calls);
22d407b164ff79 Suren Baghdasaryan 2024-03-21 220
22d407b164ff79 Suren Baghdasaryan 2024-03-21 221 ref->ct = NULL;
22d407b164ff79 Suren Baghdasaryan 2024-03-21 222 }
22d407b164ff79 Suren Baghdasaryan 2024-03-21 223
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
next prev parent reply other threads:[~2025-08-20 6:45 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-08-19 13:50 [PATCH 0/2] riscv: introduce percpu.h Yunhui Cui
2025-08-19 13:50 ` [PATCH 1/2] riscv: remove irqflags.h inclusion in asm/bitops.h Yunhui Cui
2025-08-19 13:50 ` [PATCH 2/2] riscv: introduce percpu.h into include/asm Yunhui Cui
2025-08-20 6:44 ` kernel test robot [this message]
2025-08-20 17:18 ` kernel test robot
2025-08-20 23:26 ` Christoph Lameter (Ampere)
2025-08-21 8:01 ` [External] " yunhui cui
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=202508201452.ciEgfhNO-lkp@intel.com \
--to=lkp@intel.com \
--cc=alex@ghiti.fr \
--cc=aou@eecs.berkeley.edu \
--cc=cl@gentwo.org \
--cc=cuiyunhui@bytedance.com \
--cc=dennis@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=linux-riscv@lists.infradead.org \
--cc=linux@rasmusvillemoes.dk \
--cc=llvm@lists.linux.dev \
--cc=oe-kbuild-all@lists.linux.dev \
--cc=palmer@dabbelt.com \
--cc=paul.walmsley@sifive.com \
--cc=tj@kernel.org \
--cc=yury.norov@gmail.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: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox