lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Message-ID: <202310172247.ihJFHycv-lkp@intel.com>
Date:   Tue, 17 Oct 2023 22:47:05 +0800
From:   kernel test robot <lkp@...el.com>
To:     "Darrick J. Wong" <djwong@...nel.org>
Cc:     oe-kbuild-all@...ts.linux.dev, linux-kernel@...r.kernel.org,
        Christoph Hellwig <hch@....de>,
        Dave Chinner <dchinner@...hat.com>, Jan Kara <jack@...e.cz>
Subject: fs/gfs2/super.c:767: warning: Function parameter or member 'who' not
 described in 'gfs2_freeze_super'

Hi Darrick,

FYI, the error/warning still remains.

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head:   213f891525c222e8ed145ce1ce7ae1f47921cb9c
commit: 880b9577855edddda1e732748e849c63199d489b fs: distinguish between user initiated freeze and kernel initiated freeze
date:   3 months ago
config: x86_64-buildonly-randconfig-001-20231012 (https://download.01.org/0day-ci/archive/20231017/202310172247.ihJFHycv-lkp@intel.com/config)
compiler: gcc-12 (Debian 12.2.0-14) 12.2.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20231017/202310172247.ihJFHycv-lkp@intel.com/reproduce)

If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@...el.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202310172247.ihJFHycv-lkp@intel.com/

All warnings (new ones prefixed by >>):

>> fs/gfs2/super.c:767: warning: Function parameter or member 'who' not described in 'gfs2_freeze_super'
>> fs/gfs2/super.c:822: warning: Function parameter or member 'who' not described in 'gfs2_thaw_super'


vim +767 fs/gfs2/super.c

2e60d7683c8d2e Benjamin Marzinski  2014-11-13  759  
9e6e0a128bca0a Steven Whitehouse   2009-05-22  760  /**
097cca525adf10 Andreas Gruenbacher 2022-11-14  761   * gfs2_freeze_super - prevent further writes to the filesystem
9e6e0a128bca0a Steven Whitehouse   2009-05-22  762   * @sb: the VFS structure for the filesystem
9e6e0a128bca0a Steven Whitehouse   2009-05-22  763   *
9e6e0a128bca0a Steven Whitehouse   2009-05-22  764   */
9e6e0a128bca0a Steven Whitehouse   2009-05-22  765  
880b9577855edd Darrick J. Wong     2023-07-17  766  static int gfs2_freeze_super(struct super_block *sb, enum freeze_holder who)
9e6e0a128bca0a Steven Whitehouse   2009-05-22 @767  {
9e6e0a128bca0a Steven Whitehouse   2009-05-22  768  	struct gfs2_sbd *sdp = sb->s_fs_info;
ff132c5f93c06b Bob Peterson        2021-03-25  769  	int error;
9e6e0a128bca0a Steven Whitehouse   2009-05-22  770  
b77b4a4815a965 Andreas Gruenbacher 2022-11-14  771  	if (!mutex_trylock(&sdp->sd_freeze_mutex))
b77b4a4815a965 Andreas Gruenbacher 2022-11-14  772  		return -EBUSY;
ff132c5f93c06b Bob Peterson        2021-03-25  773  	error = -EBUSY;
5432af15f8772d Andreas Gruenbacher 2022-08-18  774  	if (test_bit(SDF_FROZEN, &sdp->sd_flags))
2e60d7683c8d2e Benjamin Marzinski  2014-11-13  775  		goto out;
2e60d7683c8d2e Benjamin Marzinski  2014-11-13  776  
60528afa78667b Bob Peterson        2019-11-14  777  	for (;;) {
b77b4a4815a965 Andreas Gruenbacher 2022-11-14  778  		error = gfs2_freeze_locally(sdp);
b77b4a4815a965 Andreas Gruenbacher 2022-11-14  779  		if (error) {
b77b4a4815a965 Andreas Gruenbacher 2022-11-14  780  			fs_info(sdp, "GFS2: couldn't freeze filesystem: %d\n",
b77b4a4815a965 Andreas Gruenbacher 2022-11-14  781  				error);
2e60d7683c8d2e Benjamin Marzinski  2014-11-13  782  			goto out;
2e60d7683c8d2e Benjamin Marzinski  2014-11-13  783  		}
9e6e0a128bca0a Steven Whitehouse   2009-05-22  784  
52b1cdcb7a84a4 Bob Peterson        2019-11-15  785  		error = gfs2_lock_fs_check_clean(sdp);
9e6e0a128bca0a Steven Whitehouse   2009-05-22  786  		if (!error)
b77b4a4815a965 Andreas Gruenbacher 2022-11-14  787  			break;  /* success */
b77b4a4815a965 Andreas Gruenbacher 2022-11-14  788  
b77b4a4815a965 Andreas Gruenbacher 2022-11-14  789  		error = gfs2_do_thaw(sdp);
b77b4a4815a965 Andreas Gruenbacher 2022-11-14  790  		if (error)
b77b4a4815a965 Andreas Gruenbacher 2022-11-14  791  			goto out;
9e6e0a128bca0a Steven Whitehouse   2009-05-22  792  
55317f5b00f0dc Bob Peterson        2019-04-29  793  		if (error == -EBUSY)
9e6e0a128bca0a Steven Whitehouse   2009-05-22  794  			fs_err(sdp, "waiting for recovery before freeze\n");
52b1cdcb7a84a4 Bob Peterson        2019-11-15  795  		else if (error == -EIO) {
52b1cdcb7a84a4 Bob Peterson        2019-11-15  796  			fs_err(sdp, "Fatal IO error: cannot freeze gfs2 due "
52b1cdcb7a84a4 Bob Peterson        2019-11-15  797  			       "to recovery error.\n");
52b1cdcb7a84a4 Bob Peterson        2019-11-15  798  			goto out;
52b1cdcb7a84a4 Bob Peterson        2019-11-15  799  		} else {
9e6e0a128bca0a Steven Whitehouse   2009-05-22  800  			fs_err(sdp, "error freezing FS: %d\n", error);
52b1cdcb7a84a4 Bob Peterson        2019-11-15  801  		}
9e6e0a128bca0a Steven Whitehouse   2009-05-22  802  		fs_err(sdp, "retrying...\n");
9e6e0a128bca0a Steven Whitehouse   2009-05-22  803  		msleep(1000);
9e6e0a128bca0a Steven Whitehouse   2009-05-22  804  	}
b77b4a4815a965 Andreas Gruenbacher 2022-11-14  805  
2e60d7683c8d2e Benjamin Marzinski  2014-11-13  806  out:
b77b4a4815a965 Andreas Gruenbacher 2022-11-14  807  	if (!error) {
b77b4a4815a965 Andreas Gruenbacher 2022-11-14  808  		set_bit(SDF_FREEZE_INITIATOR, &sdp->sd_flags);
5432af15f8772d Andreas Gruenbacher 2022-08-18  809  		set_bit(SDF_FROZEN, &sdp->sd_flags);
b77b4a4815a965 Andreas Gruenbacher 2022-11-14  810  	}
2e60d7683c8d2e Benjamin Marzinski  2014-11-13  811  	mutex_unlock(&sdp->sd_freeze_mutex);
2e60d7683c8d2e Benjamin Marzinski  2014-11-13  812  	return error;
9e6e0a128bca0a Steven Whitehouse   2009-05-22  813  }
9e6e0a128bca0a Steven Whitehouse   2009-05-22  814  
9e6e0a128bca0a Steven Whitehouse   2009-05-22  815  /**
097cca525adf10 Andreas Gruenbacher 2022-11-14  816   * gfs2_thaw_super - reallow writes to the filesystem
9e6e0a128bca0a Steven Whitehouse   2009-05-22  817   * @sb: the VFS structure for the filesystem
9e6e0a128bca0a Steven Whitehouse   2009-05-22  818   *
9e6e0a128bca0a Steven Whitehouse   2009-05-22  819   */
9e6e0a128bca0a Steven Whitehouse   2009-05-22  820  
880b9577855edd Darrick J. Wong     2023-07-17  821  static int gfs2_thaw_super(struct super_block *sb, enum freeze_holder who)
9e6e0a128bca0a Steven Whitehouse   2009-05-22 @822  {
d564053f074634 Steven Whitehouse   2013-01-11  823  	struct gfs2_sbd *sdp = sb->s_fs_info;
b77b4a4815a965 Andreas Gruenbacher 2022-11-14  824  	int error;
d564053f074634 Steven Whitehouse   2013-01-11  825  
b77b4a4815a965 Andreas Gruenbacher 2022-11-14  826  	if (!mutex_trylock(&sdp->sd_freeze_mutex))
b77b4a4815a965 Andreas Gruenbacher 2022-11-14  827  		return -EBUSY;
b77b4a4815a965 Andreas Gruenbacher 2022-11-14  828  	error = -EINVAL;
b77b4a4815a965 Andreas Gruenbacher 2022-11-14  829  	if (!test_bit(SDF_FREEZE_INITIATOR, &sdp->sd_flags))
b77b4a4815a965 Andreas Gruenbacher 2022-11-14  830  		goto out;
b77b4a4815a965 Andreas Gruenbacher 2022-11-14  831  
b77b4a4815a965 Andreas Gruenbacher 2022-11-14  832  	gfs2_freeze_unlock(&sdp->sd_freeze_gh);
b77b4a4815a965 Andreas Gruenbacher 2022-11-14  833  
b77b4a4815a965 Andreas Gruenbacher 2022-11-14  834  	error = gfs2_do_thaw(sdp);
b77b4a4815a965 Andreas Gruenbacher 2022-11-14  835  
b77b4a4815a965 Andreas Gruenbacher 2022-11-14  836  	if (!error) {
b77b4a4815a965 Andreas Gruenbacher 2022-11-14  837  		clear_bit(SDF_FREEZE_INITIATOR, &sdp->sd_flags);
5432af15f8772d Andreas Gruenbacher 2022-08-18  838  		clear_bit(SDF_FROZEN, &sdp->sd_flags);
b77b4a4815a965 Andreas Gruenbacher 2022-11-14  839  	}
b77b4a4815a965 Andreas Gruenbacher 2022-11-14  840  out:
2e60d7683c8d2e Benjamin Marzinski  2014-11-13  841  	mutex_unlock(&sdp->sd_freeze_mutex);
b77b4a4815a965 Andreas Gruenbacher 2022-11-14  842  	return error;
2e60d7683c8d2e Benjamin Marzinski  2014-11-13  843  }
2e60d7683c8d2e Benjamin Marzinski  2014-11-13  844  

:::::: The code at line 767 was first introduced by commit
:::::: 9e6e0a128bca0a151d8d3fbd9459b22fc21cfebb GFS2: Merge mount.c and ops_super.c into super.c

:::::: TO: Steven Whitehouse <swhiteho@...hat.com>
:::::: CC: Steven Whitehouse <swhiteho@...hat.com>

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ