All of lore.kernel.org
 help / color / mirror / Atom feed
* [djwong-xfs:repair-metadata-atomically 127/227] fs/xfs/scrub/parent.c:71:1: warning: no previous prototype for function 'xchk_parent_count_parent_dentries'
@ 2020-05-20 23:23 kbuild test robot
  0 siblings, 0 replies; only message in thread
From: kbuild test robot @ 2020-05-20 23:23 UTC (permalink / raw)
  To: kbuild-all

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

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/djwong/xfs-linux.git repair-metadata-atomically
head:   03560ddd3fbb967b10047a3d7a31266990f797cf
commit: ad2ea322f076aef144f3b3e9f4d7e3898f34e317 [127/227] xfs: teach online directory repair to scan for the parent
config: x86_64-allyesconfig (attached as .config)
compiler: clang version 11.0.0 (https://github.com/llvm/llvm-project e6658079aca6d971b4e9d7137a3a2ecbc9c34aec)
reproduce:
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # install x86_64 cross compiling tool for clang build
        # apt-get install binutils-x86-64-linux-gnu
        git checkout ad2ea322f076aef144f3b3e9f4d7e3898f34e317
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=x86_64 

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

All warnings (new ones prefixed by >>, old ones prefixed by <<):

>> fs/xfs/scrub/parent.c:71:1: warning: no previous prototype for function 'xchk_parent_count_parent_dentries' [-Wmissing-prototypes]
xchk_parent_count_parent_dentries(
^
fs/xfs/scrub/parent.c:70:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
int
^
static
1 warning generated.

vim +/xchk_parent_count_parent_dentries +71 fs/xfs/scrub/parent.c

0f28b25731f76f Darrick J. Wong   2017-10-17   68  
0f28b25731f76f Darrick J. Wong   2017-10-17   69  /* Count the number of dentries in the parent dir that point to this inode. */
ad2ea322f076ae Darrick J. Wong   2020-03-19   70  int
c517b3aa02cff1 Darrick J. Wong   2018-07-19  @71  xchk_parent_count_parent_dentries(
1d8a748a8aa94a Darrick J. Wong   2018-07-19   72  	struct xfs_scrub	*sc,
0f28b25731f76f Darrick J. Wong   2017-10-17   73  	struct xfs_inode	*parent,
0f28b25731f76f Darrick J. Wong   2017-10-17   74  	xfs_nlink_t		*nlink)
0f28b25731f76f Darrick J. Wong   2017-10-17   75  {
c517b3aa02cff1 Darrick J. Wong   2018-07-19   76  	struct xchk_parent_ctx	spc = {
c517b3aa02cff1 Darrick J. Wong   2018-07-19   77  		.dc.actor	= xchk_parent_actor,
0f28b25731f76f Darrick J. Wong   2017-10-17   78  		.ino		= sc->ip->i_ino,
8feb4732ff9f27 Darrick J. Wong   2019-11-25   79  		.sc		= sc,
0f28b25731f76f Darrick J. Wong   2017-10-17   80  	};
0f28b25731f76f Darrick J. Wong   2017-10-17   81  	size_t			bufsize;
0f28b25731f76f Darrick J. Wong   2017-10-17   82  	loff_t			oldpos;
0f28b25731f76f Darrick J. Wong   2017-10-17   83  	uint			lock_mode;
0f28b25731f76f Darrick J. Wong   2017-10-17   84  	int			error = 0;
0f28b25731f76f Darrick J. Wong   2017-10-17   85  
0f28b25731f76f Darrick J. Wong   2017-10-17   86  	/*
0f28b25731f76f Darrick J. Wong   2017-10-17   87  	 * If there are any blocks, read-ahead block 0 as we're almost
0f28b25731f76f Darrick J. Wong   2017-10-17   88  	 * certain to have the next operation be a read there.  This is
0f28b25731f76f Darrick J. Wong   2017-10-17   89  	 * how we guarantee that the parent's extent map has been loaded,
0f28b25731f76f Darrick J. Wong   2017-10-17   90  	 * if there is one.
0f28b25731f76f Darrick J. Wong   2017-10-17   91  	 */
0f28b25731f76f Darrick J. Wong   2017-10-17   92  	lock_mode = xfs_ilock_data_map_shared(parent);
0f28b25731f76f Darrick J. Wong   2017-10-17   93  	if (parent->i_d.di_nextents > 0)
06566fda428e64 Christoph Hellwig 2019-11-20   94  		error = xfs_dir3_data_readahead(parent, 0, 0);
0f28b25731f76f Darrick J. Wong   2017-10-17   95  	xfs_iunlock(parent, lock_mode);
0f28b25731f76f Darrick J. Wong   2017-10-17   96  	if (error)
0f28b25731f76f Darrick J. Wong   2017-10-17   97  		return error;
0f28b25731f76f Darrick J. Wong   2017-10-17   98  
0f28b25731f76f Darrick J. Wong   2017-10-17   99  	/*
0f28b25731f76f Darrick J. Wong   2017-10-17  100  	 * Iterate the parent dir to confirm that there is
0f28b25731f76f Darrick J. Wong   2017-10-17  101  	 * exactly one entry pointing back to the inode being
0f28b25731f76f Darrick J. Wong   2017-10-17  102  	 * scanned.
0f28b25731f76f Darrick J. Wong   2017-10-17  103  	 */
0f28b25731f76f Darrick J. Wong   2017-10-17  104  	bufsize = (size_t)min_t(loff_t, XFS_READDIR_BUFSIZE,
0f28b25731f76f Darrick J. Wong   2017-10-17  105  			parent->i_d.di_size);
0f28b25731f76f Darrick J. Wong   2017-10-17  106  	oldpos = 0;
0f28b25731f76f Darrick J. Wong   2017-10-17  107  	while (true) {
0f28b25731f76f Darrick J. Wong   2017-10-17  108  		error = xfs_readdir(sc->tp, parent, &spc.dc, bufsize);
0f28b25731f76f Darrick J. Wong   2017-10-17  109  		if (error)
0f28b25731f76f Darrick J. Wong   2017-10-17  110  			goto out;
8feb4732ff9f27 Darrick J. Wong   2019-11-25  111  		if (spc.cancelled) {
8feb4732ff9f27 Darrick J. Wong   2019-11-25  112  			error = -EAGAIN;
8feb4732ff9f27 Darrick J. Wong   2019-11-25  113  			goto out;
8feb4732ff9f27 Darrick J. Wong   2019-11-25  114  		}
0f28b25731f76f Darrick J. Wong   2017-10-17  115  		if (oldpos == spc.dc.pos)
0f28b25731f76f Darrick J. Wong   2017-10-17  116  			break;
0f28b25731f76f Darrick J. Wong   2017-10-17  117  		oldpos = spc.dc.pos;
0f28b25731f76f Darrick J. Wong   2017-10-17  118  	}
0f28b25731f76f Darrick J. Wong   2017-10-17  119  	*nlink = spc.nlink;
0f28b25731f76f Darrick J. Wong   2017-10-17  120  out:
0f28b25731f76f Darrick J. Wong   2017-10-17  121  	return error;
0f28b25731f76f Darrick J. Wong   2017-10-17  122  }
0f28b25731f76f Darrick J. Wong   2017-10-17  123  

:::::: The code at line 71 was first introduced by commit
:::::: c517b3aa02cff1dd688aa783b748e06c8aee1285 xfs: shorten xfs_scrub_ prefix

:::::: TO: Darrick J. Wong <darrick.wong@oracle.com>
:::::: CC: Darrick J. Wong <darrick.wong@oracle.com>

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

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

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

only message in thread, other threads:[~2020-05-20 23:23 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-05-20 23:23 [djwong-xfs:repair-metadata-atomically 127/227] fs/xfs/scrub/parent.c:71:1: warning: no previous prototype for function 'xchk_parent_count_parent_dentries' kbuild test robot

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.