All of lore.kernel.org
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: kbuild-all@lists.01.org
Subject: [axboe-block:block-5.16 5/5] block/blk-ia-ranges.c:119: warning: expecting prototype for disk_register_independent_access__ranges(). Prototype was for disk_register_independent_access_ranges() instead
Date: Thu, 11 Nov 2021 12:43:48 +0800	[thread overview]
Message-ID: <202111111242.0HGPr3sW-lkp@intel.com> (raw)

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

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/axboe/linux-block.git block-5.16
head:   68636e242d45453d48a7d30a18a49f80d4ae08c0
commit: 68636e242d45453d48a7d30a18a49f80d4ae08c0 [5/5] block: fix kerneldoc for disk_register_independent_access__ranges()
config: ia64-defconfig (attached as .config)
compiler: ia64-linux-gcc (GCC) 11.2.0
reproduce (this is a W=1 build):
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # https://git.kernel.org/pub/scm/linux/kernel/git/axboe/linux-block.git/commit/?id=68636e242d45453d48a7d30a18a49f80d4ae08c0
        git remote add axboe-block https://git.kernel.org/pub/scm/linux/kernel/git/axboe/linux-block.git
        git fetch --no-tags axboe-block block-5.16
        git checkout 68636e242d45453d48a7d30a18a49f80d4ae08c0
        # save the attached .config to linux build tree
        mkdir build_dir
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross O=build_dir ARCH=ia64 SHELL=/bin/bash

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

All warnings (new ones prefixed by >>):

>> block/blk-ia-ranges.c:119: warning: expecting prototype for disk_register_independent_access__ranges(). Prototype was for disk_register_independent_access_ranges() instead


vim +119 block/blk-ia-ranges.c

a2247f19ee1c5a Damien Le Moal 2021-10-27  105  
a2247f19ee1c5a Damien Le Moal 2021-10-27  106  /**
68636e242d4545 Jens Axboe     2021-11-10  107   * disk_register_independent_access__ranges - register with sysfs a set of
68636e242d4545 Jens Axboe     2021-11-10  108   *		independent access ranges
a2247f19ee1c5a Damien Le Moal 2021-10-27  109   * @disk:	Target disk
a2247f19ee1c5a Damien Le Moal 2021-10-27  110   * @new_iars:	New set of independent access ranges
a2247f19ee1c5a Damien Le Moal 2021-10-27  111   *
a2247f19ee1c5a Damien Le Moal 2021-10-27  112   * Register with sysfs a set of independent access ranges for @disk.
a2247f19ee1c5a Damien Le Moal 2021-10-27  113   * If @new_iars is not NULL, this set of ranges is registered and the old set
a2247f19ee1c5a Damien Le Moal 2021-10-27  114   * specified by q->ia_ranges is unregistered. Otherwise, q->ia_ranges is
a2247f19ee1c5a Damien Le Moal 2021-10-27  115   * registered if it is not already.
a2247f19ee1c5a Damien Le Moal 2021-10-27  116   */
a2247f19ee1c5a Damien Le Moal 2021-10-27  117  int disk_register_independent_access_ranges(struct gendisk *disk,
a2247f19ee1c5a Damien Le Moal 2021-10-27  118  				struct blk_independent_access_ranges *new_iars)
a2247f19ee1c5a Damien Le Moal 2021-10-27 @119  {
a2247f19ee1c5a Damien Le Moal 2021-10-27  120  	struct request_queue *q = disk->queue;
a2247f19ee1c5a Damien Le Moal 2021-10-27  121  	struct blk_independent_access_ranges *iars;
a2247f19ee1c5a Damien Le Moal 2021-10-27  122  	int i, ret;
a2247f19ee1c5a Damien Le Moal 2021-10-27  123  
a2247f19ee1c5a Damien Le Moal 2021-10-27  124  	lockdep_assert_held(&q->sysfs_dir_lock);
a2247f19ee1c5a Damien Le Moal 2021-10-27  125  	lockdep_assert_held(&q->sysfs_lock);
a2247f19ee1c5a Damien Le Moal 2021-10-27  126  
a2247f19ee1c5a Damien Le Moal 2021-10-27  127  	/* If a new range set is specified, unregister the old one */
a2247f19ee1c5a Damien Le Moal 2021-10-27  128  	if (new_iars) {
a2247f19ee1c5a Damien Le Moal 2021-10-27  129  		if (q->ia_ranges)
a2247f19ee1c5a Damien Le Moal 2021-10-27  130  			disk_unregister_independent_access_ranges(disk);
a2247f19ee1c5a Damien Le Moal 2021-10-27  131  		q->ia_ranges = new_iars;
a2247f19ee1c5a Damien Le Moal 2021-10-27  132  	}
a2247f19ee1c5a Damien Le Moal 2021-10-27  133  
a2247f19ee1c5a Damien Le Moal 2021-10-27  134  	iars = q->ia_ranges;
a2247f19ee1c5a Damien Le Moal 2021-10-27  135  	if (!iars)
a2247f19ee1c5a Damien Le Moal 2021-10-27  136  		return 0;
a2247f19ee1c5a Damien Le Moal 2021-10-27  137  
a2247f19ee1c5a Damien Le Moal 2021-10-27  138  	/*
a2247f19ee1c5a Damien Le Moal 2021-10-27  139  	 * At this point, iars is the new set of sector access ranges that needs
a2247f19ee1c5a Damien Le Moal 2021-10-27  140  	 * to be registered with sysfs.
a2247f19ee1c5a Damien Le Moal 2021-10-27  141  	 */
a2247f19ee1c5a Damien Le Moal 2021-10-27  142  	WARN_ON(iars->sysfs_registered);
a2247f19ee1c5a Damien Le Moal 2021-10-27  143  	ret = kobject_init_and_add(&iars->kobj, &blk_ia_ranges_ktype,
a2247f19ee1c5a Damien Le Moal 2021-10-27  144  				   &q->kobj, "%s", "independent_access_ranges");
a2247f19ee1c5a Damien Le Moal 2021-10-27  145  	if (ret) {
a2247f19ee1c5a Damien Le Moal 2021-10-27  146  		q->ia_ranges = NULL;
a2247f19ee1c5a Damien Le Moal 2021-10-27  147  		kfree(iars);
a2247f19ee1c5a Damien Le Moal 2021-10-27  148  		return ret;
a2247f19ee1c5a Damien Le Moal 2021-10-27  149  	}
a2247f19ee1c5a Damien Le Moal 2021-10-27  150  
a2247f19ee1c5a Damien Le Moal 2021-10-27  151  	for (i = 0; i < iars->nr_ia_ranges; i++) {
a2247f19ee1c5a Damien Le Moal 2021-10-27  152  		iars->ia_range[i].queue = q;
a2247f19ee1c5a Damien Le Moal 2021-10-27  153  		ret = kobject_init_and_add(&iars->ia_range[i].kobj,
a2247f19ee1c5a Damien Le Moal 2021-10-27  154  					   &blk_ia_range_ktype, &iars->kobj,
a2247f19ee1c5a Damien Le Moal 2021-10-27  155  					   "%d", i);
a2247f19ee1c5a Damien Le Moal 2021-10-27  156  		if (ret) {
a2247f19ee1c5a Damien Le Moal 2021-10-27  157  			while (--i >= 0)
a2247f19ee1c5a Damien Le Moal 2021-10-27  158  				kobject_del(&iars->ia_range[i].kobj);
a2247f19ee1c5a Damien Le Moal 2021-10-27  159  			kobject_del(&iars->kobj);
a2247f19ee1c5a Damien Le Moal 2021-10-27  160  			kobject_put(&iars->kobj);
a2247f19ee1c5a Damien Le Moal 2021-10-27  161  			return ret;
a2247f19ee1c5a Damien Le Moal 2021-10-27  162  		}
a2247f19ee1c5a Damien Le Moal 2021-10-27  163  	}
a2247f19ee1c5a Damien Le Moal 2021-10-27  164  
a2247f19ee1c5a Damien Le Moal 2021-10-27  165  	iars->sysfs_registered = true;
a2247f19ee1c5a Damien Le Moal 2021-10-27  166  
a2247f19ee1c5a Damien Le Moal 2021-10-27  167  	return 0;
a2247f19ee1c5a Damien Le Moal 2021-10-27  168  }
a2247f19ee1c5a Damien Le Moal 2021-10-27  169  

:::::: The code at line 119 was first introduced by commit
:::::: a2247f19ee1c5ad75ef095cdfb909a3244b88aa8 block: Add independent access ranges support

:::::: TO: Damien Le Moal <damien.lemoal@wdc.com>
:::::: CC: Jens Axboe <axboe@kernel.dk>

---
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: 20007 bytes --]

WARNING: multiple messages have this Message-ID (diff)
From: kernel test robot <lkp@intel.com>
To: Jens Axboe <axboe@kernel.dk>
Cc: kbuild-all@lists.01.org, linux-kernel@vger.kernel.org
Subject: [axboe-block:block-5.16 5/5] block/blk-ia-ranges.c:119: warning: expecting prototype for disk_register_independent_access__ranges(). Prototype was for disk_register_independent_access_ranges() instead
Date: Thu, 11 Nov 2021 12:43:48 +0800	[thread overview]
Message-ID: <202111111242.0HGPr3sW-lkp@intel.com> (raw)

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

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/axboe/linux-block.git block-5.16
head:   68636e242d45453d48a7d30a18a49f80d4ae08c0
commit: 68636e242d45453d48a7d30a18a49f80d4ae08c0 [5/5] block: fix kerneldoc for disk_register_independent_access__ranges()
config: ia64-defconfig (attached as .config)
compiler: ia64-linux-gcc (GCC) 11.2.0
reproduce (this is a W=1 build):
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # https://git.kernel.org/pub/scm/linux/kernel/git/axboe/linux-block.git/commit/?id=68636e242d45453d48a7d30a18a49f80d4ae08c0
        git remote add axboe-block https://git.kernel.org/pub/scm/linux/kernel/git/axboe/linux-block.git
        git fetch --no-tags axboe-block block-5.16
        git checkout 68636e242d45453d48a7d30a18a49f80d4ae08c0
        # save the attached .config to linux build tree
        mkdir build_dir
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross O=build_dir ARCH=ia64 SHELL=/bin/bash

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

All warnings (new ones prefixed by >>):

>> block/blk-ia-ranges.c:119: warning: expecting prototype for disk_register_independent_access__ranges(). Prototype was for disk_register_independent_access_ranges() instead


vim +119 block/blk-ia-ranges.c

a2247f19ee1c5a Damien Le Moal 2021-10-27  105  
a2247f19ee1c5a Damien Le Moal 2021-10-27  106  /**
68636e242d4545 Jens Axboe     2021-11-10  107   * disk_register_independent_access__ranges - register with sysfs a set of
68636e242d4545 Jens Axboe     2021-11-10  108   *		independent access ranges
a2247f19ee1c5a Damien Le Moal 2021-10-27  109   * @disk:	Target disk
a2247f19ee1c5a Damien Le Moal 2021-10-27  110   * @new_iars:	New set of independent access ranges
a2247f19ee1c5a Damien Le Moal 2021-10-27  111   *
a2247f19ee1c5a Damien Le Moal 2021-10-27  112   * Register with sysfs a set of independent access ranges for @disk.
a2247f19ee1c5a Damien Le Moal 2021-10-27  113   * If @new_iars is not NULL, this set of ranges is registered and the old set
a2247f19ee1c5a Damien Le Moal 2021-10-27  114   * specified by q->ia_ranges is unregistered. Otherwise, q->ia_ranges is
a2247f19ee1c5a Damien Le Moal 2021-10-27  115   * registered if it is not already.
a2247f19ee1c5a Damien Le Moal 2021-10-27  116   */
a2247f19ee1c5a Damien Le Moal 2021-10-27  117  int disk_register_independent_access_ranges(struct gendisk *disk,
a2247f19ee1c5a Damien Le Moal 2021-10-27  118  				struct blk_independent_access_ranges *new_iars)
a2247f19ee1c5a Damien Le Moal 2021-10-27 @119  {
a2247f19ee1c5a Damien Le Moal 2021-10-27  120  	struct request_queue *q = disk->queue;
a2247f19ee1c5a Damien Le Moal 2021-10-27  121  	struct blk_independent_access_ranges *iars;
a2247f19ee1c5a Damien Le Moal 2021-10-27  122  	int i, ret;
a2247f19ee1c5a Damien Le Moal 2021-10-27  123  
a2247f19ee1c5a Damien Le Moal 2021-10-27  124  	lockdep_assert_held(&q->sysfs_dir_lock);
a2247f19ee1c5a Damien Le Moal 2021-10-27  125  	lockdep_assert_held(&q->sysfs_lock);
a2247f19ee1c5a Damien Le Moal 2021-10-27  126  
a2247f19ee1c5a Damien Le Moal 2021-10-27  127  	/* If a new range set is specified, unregister the old one */
a2247f19ee1c5a Damien Le Moal 2021-10-27  128  	if (new_iars) {
a2247f19ee1c5a Damien Le Moal 2021-10-27  129  		if (q->ia_ranges)
a2247f19ee1c5a Damien Le Moal 2021-10-27  130  			disk_unregister_independent_access_ranges(disk);
a2247f19ee1c5a Damien Le Moal 2021-10-27  131  		q->ia_ranges = new_iars;
a2247f19ee1c5a Damien Le Moal 2021-10-27  132  	}
a2247f19ee1c5a Damien Le Moal 2021-10-27  133  
a2247f19ee1c5a Damien Le Moal 2021-10-27  134  	iars = q->ia_ranges;
a2247f19ee1c5a Damien Le Moal 2021-10-27  135  	if (!iars)
a2247f19ee1c5a Damien Le Moal 2021-10-27  136  		return 0;
a2247f19ee1c5a Damien Le Moal 2021-10-27  137  
a2247f19ee1c5a Damien Le Moal 2021-10-27  138  	/*
a2247f19ee1c5a Damien Le Moal 2021-10-27  139  	 * At this point, iars is the new set of sector access ranges that needs
a2247f19ee1c5a Damien Le Moal 2021-10-27  140  	 * to be registered with sysfs.
a2247f19ee1c5a Damien Le Moal 2021-10-27  141  	 */
a2247f19ee1c5a Damien Le Moal 2021-10-27  142  	WARN_ON(iars->sysfs_registered);
a2247f19ee1c5a Damien Le Moal 2021-10-27  143  	ret = kobject_init_and_add(&iars->kobj, &blk_ia_ranges_ktype,
a2247f19ee1c5a Damien Le Moal 2021-10-27  144  				   &q->kobj, "%s", "independent_access_ranges");
a2247f19ee1c5a Damien Le Moal 2021-10-27  145  	if (ret) {
a2247f19ee1c5a Damien Le Moal 2021-10-27  146  		q->ia_ranges = NULL;
a2247f19ee1c5a Damien Le Moal 2021-10-27  147  		kfree(iars);
a2247f19ee1c5a Damien Le Moal 2021-10-27  148  		return ret;
a2247f19ee1c5a Damien Le Moal 2021-10-27  149  	}
a2247f19ee1c5a Damien Le Moal 2021-10-27  150  
a2247f19ee1c5a Damien Le Moal 2021-10-27  151  	for (i = 0; i < iars->nr_ia_ranges; i++) {
a2247f19ee1c5a Damien Le Moal 2021-10-27  152  		iars->ia_range[i].queue = q;
a2247f19ee1c5a Damien Le Moal 2021-10-27  153  		ret = kobject_init_and_add(&iars->ia_range[i].kobj,
a2247f19ee1c5a Damien Le Moal 2021-10-27  154  					   &blk_ia_range_ktype, &iars->kobj,
a2247f19ee1c5a Damien Le Moal 2021-10-27  155  					   "%d", i);
a2247f19ee1c5a Damien Le Moal 2021-10-27  156  		if (ret) {
a2247f19ee1c5a Damien Le Moal 2021-10-27  157  			while (--i >= 0)
a2247f19ee1c5a Damien Le Moal 2021-10-27  158  				kobject_del(&iars->ia_range[i].kobj);
a2247f19ee1c5a Damien Le Moal 2021-10-27  159  			kobject_del(&iars->kobj);
a2247f19ee1c5a Damien Le Moal 2021-10-27  160  			kobject_put(&iars->kobj);
a2247f19ee1c5a Damien Le Moal 2021-10-27  161  			return ret;
a2247f19ee1c5a Damien Le Moal 2021-10-27  162  		}
a2247f19ee1c5a Damien Le Moal 2021-10-27  163  	}
a2247f19ee1c5a Damien Le Moal 2021-10-27  164  
a2247f19ee1c5a Damien Le Moal 2021-10-27  165  	iars->sysfs_registered = true;
a2247f19ee1c5a Damien Le Moal 2021-10-27  166  
a2247f19ee1c5a Damien Le Moal 2021-10-27  167  	return 0;
a2247f19ee1c5a Damien Le Moal 2021-10-27  168  }
a2247f19ee1c5a Damien Le Moal 2021-10-27  169  

:::::: The code at line 119 was first introduced by commit
:::::: a2247f19ee1c5ad75ef095cdfb909a3244b88aa8 block: Add independent access ranges support

:::::: TO: Damien Le Moal <damien.lemoal@wdc.com>
:::::: CC: Jens Axboe <axboe@kernel.dk>

---
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: 20007 bytes --]

             reply	other threads:[~2021-11-11  4:43 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-11-11  4:43 kernel test robot [this message]
2021-11-11  4:43 ` [axboe-block:block-5.16 5/5] block/blk-ia-ranges.c:119: warning: expecting prototype for disk_register_independent_access__ranges(). Prototype was for disk_register_independent_access_ranges() instead kernel test robot

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=202111111242.0HGPr3sW-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=kbuild-all@lists.01.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.