linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
* [linux-next:master 2205/2463] include/trace/events/io_uring.h:509:1: sparse: sparse: incorrect type in assignment (different base types)
@ 2021-09-16 17:06 kernel test robot
  0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2021-09-16 17:06 UTC (permalink / raw)
  To: Jens Axboe; +Cc: kbuild-all, Linux Memory Management List

[-- Attachment #1: Type: text/plain, Size: 9812 bytes --]

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master
head:   368847b165bbfbdcf0bd4c96b167893dcdb13aba
commit: ca8c0786e01b744c990fa8cd8e9d53a861a44daa [2205/2463] io_uring: dump sqe contents if issue fails
config: i386-randconfig-s002-20210916 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-22) 9.3.0
reproduce:
        # apt-get install sparse
        # sparse version: v0.6.4-dirty
        # https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git/commit/?id=ca8c0786e01b744c990fa8cd8e9d53a861a44daa
        git remote add linux-next https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git
        git fetch --no-tags linux-next master
        git checkout ca8c0786e01b744c990fa8cd8e9d53a861a44daa
        # save the attached .config to linux build tree
        make W=1 C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' ARCH=i386 

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>


sparse warnings: (new ones prefixed by >>)
   fs/io_uring.c: note: in included file (through include/trace/trace_events.h, include/trace/define_trace.h, include/trace/events/io_uring.h):
>> include/trace/events/io_uring.h:509:1: sparse: sparse: incorrect type in assignment (different base types) @@     expected unsigned int [usertype] op_flags @@     got restricted __kernel_rwf_t const [usertype] rw_flags @@
   include/trace/events/io_uring.h:509:1: sparse:     expected unsigned int [usertype] op_flags
   include/trace/events/io_uring.h:509:1: sparse:     got restricted __kernel_rwf_t const [usertype] rw_flags
   fs/io_uring.c: note: in included file (through include/trace/perf.h, include/trace/define_trace.h, include/trace/events/io_uring.h):
>> include/trace/events/io_uring.h:509:1: sparse: sparse: incorrect type in assignment (different base types) @@     expected unsigned int [usertype] op_flags @@     got restricted __kernel_rwf_t const [usertype] rw_flags @@
   include/trace/events/io_uring.h:509:1: sparse:     expected unsigned int [usertype] op_flags
   include/trace/events/io_uring.h:509:1: sparse:     got restricted __kernel_rwf_t const [usertype] rw_flags
   fs/io_uring.c:3101:24: sparse: sparse: incorrect type in return expression (different address spaces) @@     expected void [noderef] __user * @@     got struct io_buffer *[assigned] kbuf @@
   fs/io_uring.c:3101:24: sparse:     expected void [noderef] __user *
   fs/io_uring.c:3101:24: sparse:     got struct io_buffer *[assigned] kbuf
   fs/io_uring.c:4620:14: sparse: sparse: incorrect type in assignment (different address spaces) @@     expected struct file *file @@     got struct file [noderef] __rcu * @@
   fs/io_uring.c:4620:14: sparse:     expected struct file *file
   fs/io_uring.c:4620:14: sparse:     got struct file [noderef] __rcu *
   fs/io_uring.c:5250:72: sparse: sparse: incorrect type in argument 4 (different base types) @@     expected int mask @@     got restricted __poll_t [usertype] mask @@
   fs/io_uring.c:5250:72: sparse:     expected int mask
   fs/io_uring.c:5250:72: sparse:     got restricted __poll_t [usertype] mask
   fs/io_uring.c:5254:21: sparse: sparse: incorrect type in assignment (different base types) @@     expected unsigned int [usertype] result @@     got restricted __poll_t [usertype] mask @@
   fs/io_uring.c:5254:21: sparse:     expected unsigned int [usertype] result
   fs/io_uring.c:5254:21: sparse:     got restricted __poll_t [usertype] mask
   fs/io_uring.c:5279:29: sparse: sparse: incorrect type in assignment (different base types) @@     expected unsigned int [usertype] result @@     got restricted __poll_t @@
   fs/io_uring.c:5279:29: sparse:     expected unsigned int [usertype] result
   fs/io_uring.c:5279:29: sparse:     got restricted __poll_t
   fs/io_uring.c:5370:51: sparse: sparse: incorrect type in argument 2 (different base types) @@     expected restricted __poll_t [usertype] mask @@     got unsigned int [usertype] result @@
   fs/io_uring.c:5370:51: sparse:     expected restricted __poll_t [usertype] mask
   fs/io_uring.c:5370:51: sparse:     got unsigned int [usertype] result
   fs/io_uring.c:5526:41: sparse: sparse: incorrect type in argument 4 (different base types) @@     expected int mask @@     got restricted __poll_t [usertype] @@
   fs/io_uring.c:5526:41: sparse:     expected int mask
   fs/io_uring.c:5526:41: sparse:     got restricted __poll_t [usertype]
   fs/io_uring.c:5598:30: sparse: sparse: restricted __poll_t degrades to integer
   fs/io_uring.c:5598:53: sparse: sparse: incorrect type in initializer (different base types) @@     expected restricted __poll_t [usertype] mask @@     got unsigned int @@
   fs/io_uring.c:5598:53: sparse:     expected restricted __poll_t [usertype] mask
   fs/io_uring.c:5598:53: sparse:     got unsigned int
   fs/io_uring.c:5610:22: sparse: sparse: invalid assignment: |=
   fs/io_uring.c:5610:22: sparse:    left side has type restricted __poll_t
   fs/io_uring.c:5610:22: sparse:    right side has type int
   fs/io_uring.c:5615:30: sparse: sparse: invalid assignment: &=
   fs/io_uring.c:5615:30: sparse:    left side has type restricted __poll_t
   fs/io_uring.c:5615:30: sparse:    right side has type int
   fs/io_uring.c:5618:22: sparse: sparse: invalid assignment: |=
   fs/io_uring.c:5618:22: sparse:    left side has type restricted __poll_t
   fs/io_uring.c:5618:22: sparse:    right side has type int
   fs/io_uring.c:5641:33: sparse: sparse: incorrect type in argument 5 (different base types) @@     expected int mask @@     got restricted __poll_t [usertype] mask @@
   fs/io_uring.c:5641:33: sparse:     expected int mask
   fs/io_uring.c:5641:33: sparse:     got restricted __poll_t [usertype] mask
   fs/io_uring.c:5641:50: sparse: sparse: incorrect type in argument 6 (different base types) @@     expected int events @@     got restricted __poll_t [usertype] events @@
   fs/io_uring.c:5641:50: sparse:     expected int events
   fs/io_uring.c:5641:50: sparse:     got restricted __poll_t [usertype] events
   fs/io_uring.c:5753:24: sparse: sparse: invalid assignment: |=
   fs/io_uring.c:5753:24: sparse:    left side has type unsigned int
   fs/io_uring.c:5753:24: sparse:    right side has type restricted __poll_t
   fs/io_uring.c:5754:65: sparse: sparse: restricted __poll_t degrades to integer
   fs/io_uring.c:5754:29: sparse: sparse: restricted __poll_t degrades to integer
   fs/io_uring.c:5754:38: sparse: sparse: incorrect type in return expression (different base types) @@     expected restricted __poll_t @@     got unsigned int @@
   fs/io_uring.c:5754:38: sparse:     expected restricted __poll_t
   fs/io_uring.c:5754:38: sparse:     got unsigned int
   fs/io_uring.c:5892:35: sparse: sparse: invalid assignment: &=
   fs/io_uring.c:5892:35: sparse:    left side has type restricted __poll_t
   fs/io_uring.c:5892:35: sparse:    right side has type int
   fs/io_uring.c:5893:54: sparse: sparse: restricted __poll_t degrades to integer
   fs/io_uring.c:5893:35: sparse: sparse: invalid assignment: |=
   fs/io_uring.c:5893:35: sparse:    left side has type restricted __poll_t
   fs/io_uring.c:5893:35: sparse:    right side has type unsigned int
   fs/io_uring.c:7887:9: sparse: sparse: context imbalance in 'io_sq_thread_unpark' - wrong count at exit
   fs/io_uring.c:7898:9: sparse: sparse: context imbalance in 'io_sq_thread_park' - wrong count at exit

vim +509 include/trace/events/io_uring.h

   500	
   501	/*
   502	 * io_uring_req_failed - called when an sqe is errored dring submission
   503	 *
   504	 * @sqe:		pointer to the io_uring_sqe that failed
   505	 * @error:		error it failed with
   506	 *
   507	 * Allows easier diagnosing of malformed requests in production systems.
   508	 */
 > 509	TRACE_EVENT(io_uring_req_failed,
   510	
   511		TP_PROTO(const struct io_uring_sqe *sqe, int error),
   512	
   513		TP_ARGS(sqe, error),
   514	
   515		TP_STRUCT__entry (
   516			__field(  u8,	opcode )
   517			__field(  u8,	flags )
   518			__field(  u8,	ioprio )
   519			__field( u64,	off )
   520			__field( u64,	addr )
   521			__field( u32,	len )
   522			__field( u32,	op_flags )
   523			__field( u64,	user_data )
   524			__field( u16,	buf_index )
   525			__field( u16,	personality )
   526			__field( u32,	file_index )
   527			__field( u64,	pad1 )
   528			__field( u64,	pad2 )
   529			__field( int,	error )
   530		),
   531	
   532		TP_fast_assign(
   533			__entry->opcode		= sqe->opcode;
   534			__entry->flags		= sqe->flags;
   535			__entry->ioprio		= sqe->ioprio;
   536			__entry->off		= sqe->off;
   537			__entry->addr		= sqe->addr;
   538			__entry->len		= sqe->len;
   539			__entry->op_flags	= sqe->rw_flags;
   540			__entry->user_data	= sqe->user_data;
   541			__entry->buf_index	= sqe->buf_index;
   542			__entry->personality	= sqe->personality;
   543			__entry->file_index	= sqe->file_index;
   544			__entry->pad1		= sqe->__pad2[0];
   545			__entry->pad2		= sqe->__pad2[1];
   546			__entry->error		= error;
   547		),
   548	
   549		TP_printk("op %d, flags=0x%x, prio=%d, off=%llu, addr=%llu, "
   550			  "len=%u, rw_flags=0x%x, user_data=0x%llx, buf_index=%d, "
   551			  "personality=%d, file_index=%d, pad=0x%llx/%llx, error=%d",
   552			  __entry->opcode, __entry->flags, __entry->ioprio,
   553			  (unsigned long long)__entry->off,
   554			  (unsigned long long) __entry->addr, __entry->len,
   555			  __entry->op_flags, (unsigned long long) __entry->user_data,
   556			  __entry->buf_index, __entry->personality, __entry->file_index,
   557			  (unsigned long long) __entry->pad1,
   558			  (unsigned long long) __entry->pad2, __entry->error)
   559	);
   560	

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org

[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 37810 bytes --]

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2021-09-16 17:06 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-09-16 17:06 [linux-next:master 2205/2463] include/trace/events/io_uring.h:509:1: sparse: sparse: incorrect type in assignment (different base types) kernel test robot

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).