public inbox for llvm@lists.linux.dev
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: Luis Chamberlain <mcgrof@kernel.org>
Cc: llvm@lists.linux.dev, oe-kbuild-all@lists.linux.dev
Subject: [mcgrof:20230322-deprecate-bdev_disk_changed 1/1] block/partitions/core.c:701:1: error: type specifier missing, defaults to 'int'; ISO C99 and later do not support implicit int
Date: Thu, 23 Mar 2023 12:00:01 +0800	[thread overview]
Message-ID: <202303231125.zhFczwGo-lkp@intel.com> (raw)

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/mcgrof/linux.git 20230322-deprecate-bdev_disk_changed
head:   64988d63873be8d60ab3ebb87c869cba3960116e
commit: 64988d63873be8d60ab3ebb87c869cba3960116e [1/1] block: annotate bdev_disk_changed() deprecation with a symbol namespace
config: arm-randconfig-r046-20230322 (https://download.01.org/0day-ci/archive/20230323/202303231125.zhFczwGo-lkp@intel.com/config)
compiler: clang version 17.0.0 (https://github.com/llvm/llvm-project 67409911353323ca5edf2049ef0df54132fa1ca7)
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
        # install arm cross compiling tool for clang build
        # apt-get install binutils-arm-linux-gnueabi
        # https://git.kernel.org/pub/scm/linux/kernel/git/mcgrof/linux.git/commit/?id=64988d63873be8d60ab3ebb87c869cba3960116e
        git remote add mcgrof https://git.kernel.org/pub/scm/linux/kernel/git/mcgrof/linux.git
        git fetch --no-tags mcgrof 20230322-deprecate-bdev_disk_changed
        git checkout 64988d63873be8d60ab3ebb87c869cba3960116e
        # save the config file
        mkdir build_dir && cp config build_dir/.config
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=arm olddefconfig
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=arm SHELL=/bin/bash block/

If you fix the issue, kindly add following tag where applicable
| Reported-by: kernel test robot <lkp@intel.com>
| Link: https://lore.kernel.org/oe-kbuild-all/202303231125.zhFczwGo-lkp@intel.com/

All errors (new ones prefixed by >>):

>> block/partitions/core.c:701:1: error: type specifier missing, defaults to 'int'; ISO C99 and later do not support implicit int [-Wimplicit-int]
   EXPORT_SYMBOL_GPL_NS(bdev_disk_changed, BLOCK_DEPRECATED);
   ^
   int
>> block/partitions/core.c:701:22: error: a parameter list without types is only allowed in a function definition
   EXPORT_SYMBOL_GPL_NS(bdev_disk_changed, BLOCK_DEPRECATED);
                        ^
   2 errors generated.


vim +/int +701 block/partitions/core.c

   654	
   655	int bdev_disk_changed(struct gendisk *disk, bool invalidate)
   656	{
   657		int ret = 0;
   658	
   659		lockdep_assert_held(&disk->open_mutex);
   660	
   661		if (!disk_live(disk))
   662			return -ENXIO;
   663	
   664	rescan:
   665		if (disk->open_partitions)
   666			return -EBUSY;
   667		sync_blockdev(disk->part0);
   668		invalidate_bdev(disk->part0);
   669		blk_drop_partitions(disk);
   670	
   671		clear_bit(GD_NEED_PART_SCAN, &disk->state);
   672	
   673		/*
   674		 * Historically we only set the capacity to zero for devices that
   675		 * support partitions (independ of actually having partitions created).
   676		 * Doing that is rather inconsistent, but changing it broke legacy
   677		 * udisks polling for legacy ide-cdrom devices.  Use the crude check
   678		 * below to get the sane behavior for most device while not breaking
   679		 * userspace for this particular setup.
   680		 */
   681		if (invalidate) {
   682			if (!(disk->flags & GENHD_FL_NO_PART) ||
   683			    !(disk->flags & GENHD_FL_REMOVABLE))
   684				set_capacity(disk, 0);
   685		}
   686	
   687		if (get_capacity(disk)) {
   688			ret = blk_add_partitions(disk);
   689			if (ret == -EAGAIN)
   690				goto rescan;
   691		} else if (invalidate) {
   692			/*
   693			 * Tell userspace that the media / partition table may have
   694			 * changed.
   695			 */
   696			kobject_uevent(&disk_to_dev(disk)->kobj, KOBJ_CHANGE);
   697		}
   698	
   699		return ret;
   700	}
 > 701	EXPORT_SYMBOL_GPL_NS(bdev_disk_changed, BLOCK_DEPRECATED);
   702	

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

                 reply	other threads:[~2023-03-23  4:00 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=202303231125.zhFczwGo-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=llvm@lists.linux.dev \
    --cc=mcgrof@kernel.org \
    --cc=oe-kbuild-all@lists.linux.dev \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox