From: kernel test robot <lkp@intel.com>
To: Himanshu Chauhan <hchauhan@ventanamicro.com>
Cc: oe-kbuild-all@lists.linux.dev
Subject: Re: [PATCH v1 2/2] riscv: Introduce support for hardware break/watchpoints
Date: Fri, 11 Jul 2025 14:19:26 +0800 [thread overview]
Message-ID: <202507111419.Snh8ePO7-lkp@intel.com> (raw)
In-Reply-To: <20250710125231.653967-3-hchauhan@ventanamicro.com>
Hi Himanshu,
kernel test robot noticed the following build warnings:
[auto build test WARNING on linus/master]
[also build test WARNING on v6.16-rc5 next-20250710]
[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/Himanshu-Chauhan/riscv-Add-SBI-debug-trigger-extension-and-function-ids/20250710-205738
base: linus/master
patch link: https://lore.kernel.org/r/20250710125231.653967-3-hchauhan%40ventanamicro.com
patch subject: [PATCH v1 2/2] riscv: Introduce support for hardware break/watchpoints
config: riscv-randconfig-r071-20250711 (https://download.01.org/0day-ci/archive/20250711/202507111419.Snh8ePO7-lkp@intel.com/config)
compiler: riscv64-linux-gcc (GCC) 10.5.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250711/202507111419.Snh8ePO7-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/202507111419.Snh8ePO7-lkp@intel.com/
All warnings (new ones prefixed by >>):
from ./arch/riscv/include/generated/asm/local64.h:1,
from include/linux/perf_event.h:26,
from include/linux/hw_breakpoint.h:5,
from arch/riscv/kernel/hw_breakpoint.c:6:
arch/riscv/kernel/hw_breakpoint.c: In function 'arch_update_hw_breakpoint':
include/linux/percpu-defs.h:220:52: error: invalid use of undefined type 'union sbi_dbtr_shmem_entry'
220 | const void __percpu *__vpp_verify = (typeof((ptr) + 0))NULL; \
| ^
include/linux/percpu-defs.h:263:2: note: in expansion of macro '__verify_pcpu_ptr'
263 | __verify_pcpu_ptr(ptr); \
| ^~~~~~~~~~~~~~~~~
include/linux/percpu-defs.h:267:26: note: in expansion of macro 'per_cpu_ptr'
267 | #define raw_cpu_ptr(ptr) per_cpu_ptr(ptr, 0)
| ^~~~~~~~~~~
include/linux/percpu-defs.h:268:27: note: in expansion of macro 'raw_cpu_ptr'
268 | #define this_cpu_ptr(ptr) raw_cpu_ptr(ptr)
| ^~~~~~~~~~~
arch/riscv/kernel/hw_breakpoint.c:536:38: note: in expansion of macro 'this_cpu_ptr'
536 | union sbi_dbtr_shmem_entry *shmem = this_cpu_ptr(sbi_dbtr_shmem);
| ^~~~~~~~~~~~
arch/riscv/kernel/hw_breakpoint.c:539:16: error: storage size of 'ret' isn't known
539 | struct sbiret ret;
| ^~~
arch/riscv/kernel/hw_breakpoint.c:557:15: error: invalid use of undefined type 'union sbi_dbtr_shmem_entry'
557 | xmit = &shmem->data;
| ^~
arch/riscv/kernel/hw_breakpoint.c:558:6: error: invalid use of undefined type 'struct sbi_dbtr_data_msg'
558 | xmit->tdata1 = cpu_to_le(bp->tdata1);
| ^~
arch/riscv/kernel/hw_breakpoint.c:559:6: error: invalid use of undefined type 'struct sbi_dbtr_data_msg'
559 | xmit->tdata2 = cpu_to_le(bp->tdata2);
| ^~
arch/riscv/kernel/hw_breakpoint.c:560:6: error: invalid use of undefined type 'struct sbi_dbtr_data_msg'
560 | xmit->tdata3 = cpu_to_le(bp->tdata3);
| ^~
arch/riscv/kernel/hw_breakpoint.c:562:18: error: 'SBI_EXT_DBTR' undeclared (first use in this function)
562 | ret = sbi_ecall(SBI_EXT_DBTR, SBI_EXT_DBTR_TRIG_UPDATE,
| ^~~~~~~~~~~~
arch/riscv/kernel/hw_breakpoint.c:562:32: error: 'SBI_EXT_DBTR_TRIG_UPDATE' undeclared (first use in this function)
562 | ret = sbi_ecall(SBI_EXT_DBTR, SBI_EXT_DBTR_TRIG_UPDATE,
| ^~~~~~~~~~~~~~~~~~~~~~~~
arch/riscv/kernel/hw_breakpoint.c:539:16: warning: unused variable 'ret' [-Wunused-variable]
539 | struct sbiret ret;
| ^~~
arch/riscv/kernel/hw_breakpoint.c: In function 'arch_disable_hw_breakpoint':
arch/riscv/kernel/hw_breakpoint.c:574:16: error: storage size of 'ret' isn't known
574 | struct sbiret ret;
| ^~~
arch/riscv/kernel/hw_breakpoint.c:589:18: error: 'SBI_EXT_DBTR' undeclared (first use in this function)
589 | ret = sbi_ecall(SBI_EXT_DBTR, SBI_EXT_DBTR_TRIG_DISABLE,
| ^~~~~~~~~~~~
arch/riscv/kernel/hw_breakpoint.c:589:32: error: 'SBI_EXT_DBTR_TRIG_DISABLE' undeclared (first use in this function)
589 | ret = sbi_ecall(SBI_EXT_DBTR, SBI_EXT_DBTR_TRIG_DISABLE,
| ^~~~~~~~~~~~~~~~~~~~~~~~~
arch/riscv/kernel/hw_breakpoint.c:574:16: warning: unused variable 'ret' [-Wunused-variable]
574 | struct sbiret ret;
| ^~~
In file included from include/linux/percpu.h:5,
from include/asm-generic/local64.h:5,
from ./arch/riscv/include/generated/asm/local64.h:1,
from include/linux/perf_event.h:26,
from include/linux/hw_breakpoint.h:5,
from arch/riscv/kernel/hw_breakpoint.c:6:
arch/riscv/kernel/hw_breakpoint.c: In function 'arch_hw_breakpoint_init':
arch/riscv/kernel/hw_breakpoint.c:634:40: error: invalid application of 'sizeof' to incomplete type 'union sbi_dbtr_shmem_entry'
634 | sbi_dbtr_shmem = __alloc_percpu(sizeof(*sbi_dbtr_shmem) * dbtr_total_num,
| ^
include/linux/alloc_tag.h:239:9: note: in definition of macro 'alloc_hooks_tag'
239 | typeof(_do_alloc) _res; \
| ^~~~~~~~~
include/linux/percpu.h:142:2: note: in expansion of macro 'alloc_hooks'
142 | alloc_hooks(pcpu_alloc_noprof(_size, _align, false, GFP_KERNEL))
| ^~~~~~~~~~~
arch/riscv/kernel/hw_breakpoint.c:634:19: note: in expansion of macro '__alloc_percpu'
634 | sbi_dbtr_shmem = __alloc_percpu(sizeof(*sbi_dbtr_shmem) * dbtr_total_num,
| ^~~~~~~~~~~~~~
arch/riscv/kernel/hw_breakpoint.c:634:40: error: invalid application of 'sizeof' to incomplete type 'union sbi_dbtr_shmem_entry'
634 | sbi_dbtr_shmem = __alloc_percpu(sizeof(*sbi_dbtr_shmem) * dbtr_total_num,
| ^
include/linux/alloc_tag.h:243:10: note: in definition of macro 'alloc_hooks_tag'
243 | _res = _do_alloc; \
| ^~~~~~~~~
include/linux/percpu.h:142:2: note: in expansion of macro 'alloc_hooks'
142 | alloc_hooks(pcpu_alloc_noprof(_size, _align, false, GFP_KERNEL))
| ^~~~~~~~~~~
arch/riscv/kernel/hw_breakpoint.c:634:19: note: in expansion of macro '__alloc_percpu'
634 | sbi_dbtr_shmem = __alloc_percpu(sizeof(*sbi_dbtr_shmem) * dbtr_total_num,
| ^~~~~~~~~~~~~~
arch/riscv/kernel/hw_breakpoint.c:634:40: error: invalid application of 'sizeof' to incomplete type 'union sbi_dbtr_shmem_entry'
634 | sbi_dbtr_shmem = __alloc_percpu(sizeof(*sbi_dbtr_shmem) * dbtr_total_num,
| ^
include/linux/alloc_tag.h:246:10: note: in definition of macro 'alloc_hooks_tag'
246 | _res = _do_alloc; \
| ^~~~~~~~~
include/linux/percpu.h:142:2: note: in expansion of macro 'alloc_hooks'
142 | alloc_hooks(pcpu_alloc_noprof(_size, _align, false, GFP_KERNEL))
| ^~~~~~~~~~~
arch/riscv/kernel/hw_breakpoint.c:634:19: note: in expansion of macro '__alloc_percpu'
634 | sbi_dbtr_shmem = __alloc_percpu(sizeof(*sbi_dbtr_shmem) * dbtr_total_num,
| ^~~~~~~~~~~~~~
>> arch/riscv/kernel/hw_breakpoint.c:634:17: warning: assignment to 'union sbi_dbtr_shmem_entry *' from 'int' makes pointer from integer without a cast [-Wint-conversion]
634 | sbi_dbtr_shmem = __alloc_percpu(sizeof(*sbi_dbtr_shmem) * dbtr_total_num,
| ^
cc1: some warnings being treated as errors
vim +634 arch/riscv/kernel/hw_breakpoint.c
613
614 static int __init arch_hw_breakpoint_init(void)
615 {
616 unsigned int cpu;
617 int rc = 0;
618
619 for_each_possible_cpu(cpu)
620 raw_spin_lock_init(&per_cpu(ecall_lock, cpu));
621
622 if (!dbtr_init)
623 init_sbi_dbtr();
624
625 if (dbtr_total_num) {
626 pr_info("%s: total number of type %d triggers: %u\n",
627 __func__, dbtr_type, dbtr_total_num);
628 } else {
629 pr_info("%s: No hardware triggers available\n", __func__);
630 goto out;
631 }
632
633 /* Allocate per-cpu shared memory */
> 634 sbi_dbtr_shmem = __alloc_percpu(sizeof(*sbi_dbtr_shmem) * dbtr_total_num,
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
next prev parent reply other threads:[~2025-07-11 6:19 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-07-10 12:52 [PATCH v1 0/2] riscv: Introduce support for hardware break/watchpoints Himanshu Chauhan
2025-07-10 12:52 ` Himanshu Chauhan
2025-07-10 12:52 ` [PATCH v1 1/2] riscv: Add SBI debug trigger extension and function ids Himanshu Chauhan
2025-07-10 12:52 ` Himanshu Chauhan
2025-11-27 0:47 ` Paul Walmsley
2025-11-27 0:47 ` Paul Walmsley
2025-07-10 12:52 ` [PATCH v1 2/2] riscv: Introduce support for hardware break/watchpoints Himanshu Chauhan
2025-07-10 12:52 ` Himanshu Chauhan
2025-07-11 6:19 ` kernel test robot [this message]
2025-07-11 9:39 ` kernel test robot
2025-11-27 0:49 ` Paul Walmsley
2025-11-27 0:49 ` Paul Walmsley
2025-11-27 10:17 ` Himanshu Chauhan
2025-11-27 10:17 ` Himanshu Chauhan
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=202507111419.Snh8ePO7-lkp@intel.com \
--to=lkp@intel.com \
--cc=hchauhan@ventanamicro.com \
--cc=oe-kbuild-all@lists.linux.dev \
/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 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.