Linux-NFS Archive on lore.kernel.org
 help / color / Atom feed
* [nfs:testing 12/12] fs/nfs/./nfs4trace.h:2216:4: warning: format '%d' expects argument of type 'int', but argument 3 has type 'long unsigned int'
@ 2019-12-31 14:25 kbuild test robot
  0 siblings, 0 replies; only message in thread
From: kbuild test robot @ 2019-12-31 14:25 UTC (permalink / raw)
  To: Trond Myklebust; +Cc: kbuild-all, linux-nfs

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

tree:   git://git.linux-nfs.org/projects/trondmy/linux-nfs.git testing
head:   b96931ff504fa3c488f557c067ad8184aca4329b
commit: b96931ff504fa3c488f557c067ad8184aca4329b [12/12] pNFS/flexfiles: Add tracing for layout errors
config: sh-allmodconfig (attached as .config)
compiler: sh4-linux-gcc (GCC) 7.5.0
reproduce:
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        git checkout b96931ff504fa3c488f557c067ad8184aca4329b
        # save the attached .config to linux build tree
        GCC_VERSION=7.5.0 make.cross ARCH=sh 

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

All warnings (new ones prefixed by >>):

   In file included from include/trace/define_trace.h:102:0,
                    from fs/nfs/nfs4trace.h:2237,
                    from fs/nfs/nfs4trace.c:13:
   fs/nfs/./nfs4trace.h: In function 'trace_raw_output_ff_layout_commit_error':
>> fs/nfs/./nfs4trace.h:2216:4: warning: format '%d' expects argument of type 'int', but argument 3 has type 'long unsigned int' [-Wformat=]
       "error=%d (%s) fileid=%02x:%02x:%llu fhandle=0x%08x "
       ^
   fs/nfs/./nfs4trace.h:2218:4:
       -__entry->error,
       ~~~~~~~~~~~
   include/trace/trace_events.h:366:22: note: in definition of macro 'DECLARE_EVENT_CLASS'
     trace_seq_printf(s, print);     \
                         ^~~~~
   include/trace/trace_events.h:79:9: note: in expansion of macro 'PARAMS'
            PARAMS(print));         \
            ^~~~~~
   fs/nfs/./nfs4trace.h:2182:1: note: in expansion of macro 'TRACE_EVENT'
    TRACE_EVENT(ff_layout_commit_error,
    ^~~~~~~~~~~
   fs/nfs/./nfs4trace.h:2215:3: note: in expansion of macro 'TP_printk'
      TP_printk(
      ^~~~~~~~~
   In file included from include/trace/trace_events.h:400:0,
                    from include/trace/define_trace.h:102,
                    from fs/nfs/nfs4trace.h:2237,
                    from fs/nfs/nfs4trace.c:13:
   fs/nfs/./nfs4trace.h:2216:12: note: format string is defined here
       "error=%d (%s) fileid=%02x:%02x:%llu fhandle=0x%08x "
              ~^
              %ld

vim +2216 fs/nfs/./nfs4trace.h

  2181	
  2182	TRACE_EVENT(ff_layout_commit_error,
  2183			TP_PROTO(
  2184				const struct nfs_commit_data *data
  2185			),
  2186	
  2187			TP_ARGS(data),
  2188	
  2189			TP_STRUCT__entry(
  2190				__field(unsigned long, error)
  2191				__field(dev_t, dev)
  2192				__field(u32, fhandle)
  2193				__field(u64, fileid)
  2194				__field(loff_t, offset)
  2195				__field(u32, count)
  2196				__string(dstaddr, data->ds_clp ?
  2197					rpc_peeraddr2str(data->ds_clp->cl_rpcclient,
  2198						RPC_DISPLAY_ADDR) : "unknown")
  2199			),
  2200	
  2201			TP_fast_assign(
  2202				const struct inode *inode = data->inode;
  2203	
  2204				__entry->error = data->res.op_status;
  2205				__entry->fhandle = nfs_fhandle_hash(data->args.fh);
  2206				__entry->fileid = NFS_FILEID(inode);
  2207				__entry->dev = inode->i_sb->s_dev;
  2208				__entry->offset = data->args.offset;
  2209				__entry->count = data->args.count;
  2210				__assign_str(dstaddr, data->ds_clp ?
  2211					rpc_peeraddr2str(data->ds_clp->cl_rpcclient,
  2212						RPC_DISPLAY_ADDR) : "unknown");
  2213			),
  2214	
  2215			TP_printk(
> 2216				"error=%d (%s) fileid=%02x:%02x:%llu fhandle=0x%08x "
  2217				"offset=%llu count=%u dstaddr=%s",
  2218				-__entry->error,
  2219				show_nfsv4_errors(__entry->error),
  2220				MAJOR(__entry->dev), MINOR(__entry->dev),
  2221				(unsigned long long)__entry->fileid,
  2222				__entry->fhandle,
  2223				__entry->offset, __entry->count,
  2224				__get_str(dstaddr)
  2225			)
  2226	);
  2227	
  2228	

---
0-DAY kernel test infrastructure                 Open Source Technology Center
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org Intel Corporation

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

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

only message in thread, back to index

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-12-31 14:25 [nfs:testing 12/12] fs/nfs/./nfs4trace.h:2216:4: warning: format '%d' expects argument of type 'int', but argument 3 has type 'long unsigned int' kbuild test robot

Linux-NFS Archive on lore.kernel.org

Archives are clonable:
	git clone --mirror https://lore.kernel.org/linux-nfs/0 linux-nfs/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 linux-nfs linux-nfs/ https://lore.kernel.org/linux-nfs \
		linux-nfs@vger.kernel.org
	public-inbox-index linux-nfs

Example config snippet for mirrors

Newsgroup available over NNTP:
	nntp://nntp.lore.kernel.org/org.kernel.vger.linux-nfs


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git