[<prev] [next>] [day] [month] [year] [list]
Message-ID: <202212070259.b4RrFt1c-lkp@intel.com>
Date: Wed, 7 Dec 2022 02:27:58 +0800
From: kernel test robot <lkp@...el.com>
To: Qing Zhang <zhangqing@...ngson.cn>
Cc: oe-kbuild-all@...ts.linux.dev, linux-kernel@...r.kernel.org,
Huacai Chen <chenhuacai@...nel.org>
Subject: kernel/trace/trace.h:1338:13: sparse: sparse: incorrect type in
argument 1 (different address spaces)
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: bce9332220bd677d83b19d21502776ad555a0e73
commit: 93a4fa622eb061f75f87f0cf9609ab4e69c67d01 LoongArch: Add STACKTRACE support
date: 4 months ago
config: loongarch-randconfig-s031-20221206
compiler: loongarch64-linux-gcc (GCC) 12.1.0
reproduce:
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# apt-get install sparse
# sparse version: v0.6.4-39-gce1a6720-dirty
# https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=93a4fa622eb061f75f87f0cf9609ab4e69c67d01
git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
git fetch --no-tags linus master
git checkout 93a4fa622eb061f75f87f0cf9609ab4e69c67d01
# save the config file
mkdir build_dir && cp config build_dir/.config
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.1.0 make.cross C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' O=build_dir ARCH=loongarch SHELL=/bin/bash kernel/trace/ sound/soc/
If you fix the issue, kindly add following tag where applicable
| Reported-by: kernel test robot <lkp@...el.com>
sparse warnings: (new ones prefixed by >>)
kernel/trace/trace_events_user.c:280:37: sparse: sparse: Using plain integer as NULL pointer
kernel/trace/trace_events_user.c:461:38: sparse: sparse: Using plain integer as NULL pointer
kernel/trace/trace_events_user.c:482:40: sparse: sparse: Using plain integer as NULL pointer
kernel/trace/trace_events_user.c:1181:16: sparse: sparse: incompatible types in comparison expression (different address spaces):
kernel/trace/trace_events_user.c:1181:16: sparse: void [noderef] __rcu *
kernel/trace/trace_events_user.c:1181:16: sparse: void *
kernel/trace/trace_events_user.c:1248:13: sparse: sparse: cast removes address space '__user' of expression
kernel/trace/trace_events_user.c:1248:13: sparse: sparse: incorrect type in argument 2 (different address spaces) @@ expected void [noderef] __user *buf @@ got char * @@
kernel/trace/trace_events_user.c:1248:13: sparse: expected void [noderef] __user *buf
kernel/trace/trace_events_user.c:1248:13: sparse: got char *
kernel/trace/trace_events_user.c:1264:16: sparse: sparse: incompatible types in comparison expression (different address spaces):
kernel/trace/trace_events_user.c:1264:16: sparse: void [noderef] __rcu *
kernel/trace/trace_events_user.c:1264:16: sparse: void *
kernel/trace/trace_events_user.c:1291:9: sparse: sparse: incompatible types in comparison expression (different address spaces):
kernel/trace/trace_events_user.c:1291:9: sparse: void [noderef] __rcu *
kernel/trace/trace_events_user.c:1291:9: sparse: void *
kernel/trace/trace_events_user.c: note: in included file:
>> kernel/trace/trace.h:1338:13: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void *ptr @@ got struct ring_buffer_event *[noderef] __percpu * @@
kernel/trace/trace.h:1338:13: sparse: expected void *ptr
kernel/trace/trace.h:1338:13: sparse: got struct ring_buffer_event *[noderef] __percpu *
>> kernel/trace/trace.h:1338:13: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void *ptr @@ got struct ring_buffer_event *[noderef] __percpu * @@
kernel/trace/trace.h:1338:13: sparse: expected void *ptr
kernel/trace/trace.h:1338:13: sparse: got struct ring_buffer_event *[noderef] __percpu *
>> kernel/trace/trace.h:1338:13: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void *ptr @@ got struct ring_buffer_event *[noderef] __percpu * @@
kernel/trace/trace.h:1338:13: sparse: expected void *ptr
kernel/trace/trace.h:1338:13: sparse: got struct ring_buffer_event *[noderef] __percpu *
>> kernel/trace/trace.h:1338:13: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void *ptr @@ got struct ring_buffer_event *[noderef] __percpu * @@
kernel/trace/trace.h:1338:13: sparse: expected void *ptr
kernel/trace/trace.h:1338:13: sparse: got struct ring_buffer_event *[noderef] __percpu *
vim +1338 kernel/trace/trace.h
0fc1b09ff1ff40 Steven Rostedt (Red Hat 2016-05-03 1333)
0fc1b09ff1ff40 Steven Rostedt (Red Hat 2016-05-03 1334) static inline void
13292494379f92 Steven Rostedt (VMware 2019-12-13 1335) __trace_event_discard_commit(struct trace_buffer *buffer,
0fc1b09ff1ff40 Steven Rostedt (Red Hat 2016-05-03 1336) struct ring_buffer_event *event)
0fc1b09ff1ff40 Steven Rostedt (Red Hat 2016-05-03 1337) {
0fc1b09ff1ff40 Steven Rostedt (Red Hat 2016-05-03 @1338) if (this_cpu_read(trace_buffered_event) == event) {
6c536d76cfe63b Steven Rostedt (VMware 2021-11-29 1339) /* Simply release the temp buffer and enable preemption */
0fc1b09ff1ff40 Steven Rostedt (Red Hat 2016-05-03 1340) this_cpu_dec(trace_buffered_event_cnt);
6c536d76cfe63b Steven Rostedt (VMware 2021-11-29 1341) preempt_enable_notrace();
0fc1b09ff1ff40 Steven Rostedt (Red Hat 2016-05-03 1342) return;
0fc1b09ff1ff40 Steven Rostedt (Red Hat 2016-05-03 1343) }
6c536d76cfe63b Steven Rostedt (VMware 2021-11-29 1344) /* ring_buffer_discard_commit() enables preemption */
0fc1b09ff1ff40 Steven Rostedt (Red Hat 2016-05-03 1345) ring_buffer_discard_commit(buffer, event);
0fc1b09ff1ff40 Steven Rostedt (Red Hat 2016-05-03 1346) }
0fc1b09ff1ff40 Steven Rostedt (Red Hat 2016-05-03 1347)
:::::: The code at line 1338 was first introduced by commit
:::::: 0fc1b09ff1ff404ddf753f5ffa5cd0adc8fdcdc9 tracing: Use temp buffer when filtering events
:::::: TO: Steven Rostedt (Red Hat) <rostedt@...dmis.org>
:::::: CC: Steven Rostedt <rostedt@...dmis.org>
--
0-DAY CI Kernel Test Service
https://01.org/lkp
View attachment "config" of type "text/plain" (176245 bytes)
Powered by blists - more mailing lists