[vfs:work.autofs 5/10] fs/autofs4/root.c:450:30: warning: passing argument 1 of 'autofs4_mount_wait' discards 'const' qualifier from pointer target type

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



tree:   https://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs.git work.autofs
head:   b46d9614d65cd18d38922b60540aeec725bf2514
commit: d31d633e717a1458d5f76e713cc1c6b10a5b249f [5/10] autofs: change autofs4_wait() to take struct path
config: mips-jz4740 (attached as .config)
compiler: mips-linux-gnu-gcc (Debian 6.1.1-9) 6.1.1 20160705
reproduce:
        wget https://git.kernel.org/cgit/linux/kernel/git/wfg/lkp-tests.git/plain/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        git checkout d31d633e717a1458d5f76e713cc1c6b10a5b249f
        # save the attached .config to linux build tree
        make.cross ARCH=mips 

All warnings (new ones prefixed by >>):

   fs/autofs4/root.c: In function 'autofs4_d_manage':
>> fs/autofs4/root.c:450:30: warning: passing argument 1 of 'autofs4_mount_wait' discards 'const' qualifier from pointer target type [-Wdiscarded-qualifiers]
     status = autofs4_mount_wait(path, rcu_walk);
                                 ^~~~
   fs/autofs4/root.c:272:12: note: expected 'struct path *' but argument is of type 'const struct path *'
    static int autofs4_mount_wait(struct path *path, bool rcu_walk)
               ^~~~~~~~~~~~~~~~~~

vim +450 fs/autofs4/root.c

   434	
   435		/* The daemon never waits. */
   436		if (autofs4_oz_mode(sbi)) {
   437			if (!d_mountpoint(dentry))
   438				return -EISDIR;
   439			return 0;
   440		}
   441	
   442		/* Wait for pending expires */
   443		if (do_expire_wait(path, rcu_walk) == -ECHILD)
   444			return -ECHILD;
   445	
   446		/*
   447		 * This dentry may be under construction so wait on mount
   448		 * completion.
   449		 */
 > 450		status = autofs4_mount_wait(path, rcu_walk);
   451		if (status)
   452			return status;
   453	
   454		if (rcu_walk) {
   455			/* We don't need fs_lock in rcu_walk mode,
   456			 * just testing 'AUTOFS_INFO_NO_RCU' is enough.
   457			 * simple_empty() takes a spinlock, so leave it
   458			 * to last.

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

Attachment: .config.gz
Description: application/gzip


[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [Samba]     [Device Mapper]     [CEPH Development]
  Powered by Linux