linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: Christoph Hellwig <hch@lst.de>
Cc: kbuild-all@lists.01.org, linux-kernel@vger.kernel.org
Subject: [hch-misc:dax-support-cleanups 6/7] include/linux/dax.h:125:36: warning: passing argument 2 of '__bdev_dax_supported' makes pointer from integer without a cast
Date: Fri, 30 Jul 2021 20:32:04 +0800	[thread overview]
Message-ID: <202107302055.2msbkb0w-lkp@intel.com> (raw)

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

tree:   git://git.infradead.org/users/hch/misc.git dax-support-cleanups
head:   109fe091fac0e3958ba459e292f22f6b60eb39f0
commit: 6ee1cc412315e2a92aa1b6b57e349f84ec4b1168 [6/7] dax: pass the dax_device to bdev_dax_supported
config: i386-buildonly-randconfig-r002-20210730 (attached as .config)
compiler: gcc-10 (Ubuntu 10.3.0-1ubuntu1~20.04) 10.3.0
reproduce (this is a W=1 build):
        git remote add hch-misc git://git.infradead.org/users/hch/misc.git
        git fetch --no-tags hch-misc dax-support-cleanups
        git checkout 6ee1cc412315e2a92aa1b6b57e349f84ec4b1168
        # save the attached .config to linux build tree
        make W=1 ARCH=i386 

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 >>):

   In file included from include/linux/mempolicy.h:11,
                    from include/linux/migrate.h:6,
                    from kernel/sched/sched.h:54,
                    from kernel/sched/core.c:13:
   include/linux/dax.h: In function 'bdev_dax_supported':
   include/linux/dax.h:125:30: error: passing argument 1 of '__bdev_dax_supported' from incompatible pointer type [-Werror=incompatible-pointer-types]
     125 |  return __bdev_dax_supported(bdev, blocksize);
         |                              ^~~~
         |                              |
         |                              struct block_device *
   include/linux/dax.h:120:46: note: expected 'struct dax_device *' but argument is of type 'struct block_device *'
     120 | bool __bdev_dax_supported(struct dax_device *dax_dev, struct block_device *bdev,
         |                           ~~~~~~~~~~~~~~~~~~~^~~~~~~
>> include/linux/dax.h:125:36: warning: passing argument 2 of '__bdev_dax_supported' makes pointer from integer without a cast [-Wint-conversion]
     125 |  return __bdev_dax_supported(bdev, blocksize);
         |                                    ^~~~~~~~~
         |                                    |
         |                                    int
   include/linux/dax.h:120:76: note: expected 'struct block_device *' but argument is of type 'int'
     120 | bool __bdev_dax_supported(struct dax_device *dax_dev, struct block_device *bdev,
         |                                                       ~~~~~~~~~~~~~~~~~~~~~^~~~
   include/linux/dax.h:125:9: error: too few arguments to function '__bdev_dax_supported'
     125 |  return __bdev_dax_supported(bdev, blocksize);
         |         ^~~~~~~~~~~~~~~~~~~~
   include/linux/dax.h:120:6: note: declared here
     120 | bool __bdev_dax_supported(struct dax_device *dax_dev, struct block_device *bdev,
         |      ^~~~~~~~~~~~~~~~~~~~
   kernel/sched/core.c: In function 'ttwu_stat':
   kernel/sched/core.c:3270:13: warning: variable 'rq' set but not used [-Wunused-but-set-variable]
    3270 |  struct rq *rq;
         |             ^~
   cc1: some warnings being treated as errors
--
   In file included from include/linux/mempolicy.h:11,
                    from include/linux/migrate.h:6,
                    from kernel/sched/sched.h:54,
                    from kernel/sched/loadavg.c:9:
   include/linux/dax.h: In function 'bdev_dax_supported':
   include/linux/dax.h:125:30: error: passing argument 1 of '__bdev_dax_supported' from incompatible pointer type [-Werror=incompatible-pointer-types]
     125 |  return __bdev_dax_supported(bdev, blocksize);
         |                              ^~~~
         |                              |
         |                              struct block_device *
   include/linux/dax.h:120:46: note: expected 'struct dax_device *' but argument is of type 'struct block_device *'
     120 | bool __bdev_dax_supported(struct dax_device *dax_dev, struct block_device *bdev,
         |                           ~~~~~~~~~~~~~~~~~~~^~~~~~~
>> include/linux/dax.h:125:36: warning: passing argument 2 of '__bdev_dax_supported' makes pointer from integer without a cast [-Wint-conversion]
     125 |  return __bdev_dax_supported(bdev, blocksize);
         |                                    ^~~~~~~~~
         |                                    |
         |                                    int
   include/linux/dax.h:120:76: note: expected 'struct block_device *' but argument is of type 'int'
     120 | bool __bdev_dax_supported(struct dax_device *dax_dev, struct block_device *bdev,
         |                                                       ~~~~~~~~~~~~~~~~~~~~~^~~~
   include/linux/dax.h:125:9: error: too few arguments to function '__bdev_dax_supported'
     125 |  return __bdev_dax_supported(bdev, blocksize);
         |         ^~~~~~~~~~~~~~~~~~~~
   include/linux/dax.h:120:6: note: declared here
     120 | bool __bdev_dax_supported(struct dax_device *dax_dev, struct block_device *bdev,
         |      ^~~~~~~~~~~~~~~~~~~~
   cc1: some warnings being treated as errors
--
   In file included from include/linux/mempolicy.h:11,
                    from include/linux/migrate.h:6,
                    from kernel/sched/sched.h:54,
                    from kernel/sched/fair.c:23:
   include/linux/dax.h: In function 'bdev_dax_supported':
   include/linux/dax.h:125:30: error: passing argument 1 of '__bdev_dax_supported' from incompatible pointer type [-Werror=incompatible-pointer-types]
     125 |  return __bdev_dax_supported(bdev, blocksize);
         |                              ^~~~
         |                              |
         |                              struct block_device *
   include/linux/dax.h:120:46: note: expected 'struct dax_device *' but argument is of type 'struct block_device *'
     120 | bool __bdev_dax_supported(struct dax_device *dax_dev, struct block_device *bdev,
         |                           ~~~~~~~~~~~~~~~~~~~^~~~~~~
>> include/linux/dax.h:125:36: warning: passing argument 2 of '__bdev_dax_supported' makes pointer from integer without a cast [-Wint-conversion]
     125 |  return __bdev_dax_supported(bdev, blocksize);
         |                                    ^~~~~~~~~
         |                                    |
         |                                    int
   include/linux/dax.h:120:76: note: expected 'struct block_device *' but argument is of type 'int'
     120 | bool __bdev_dax_supported(struct dax_device *dax_dev, struct block_device *bdev,
         |                                                       ~~~~~~~~~~~~~~~~~~~~~^~~~
   include/linux/dax.h:125:9: error: too few arguments to function '__bdev_dax_supported'
     125 |  return __bdev_dax_supported(bdev, blocksize);
         |         ^~~~~~~~~~~~~~~~~~~~
   include/linux/dax.h:120:6: note: declared here
     120 | bool __bdev_dax_supported(struct dax_device *dax_dev, struct block_device *bdev,
         |      ^~~~~~~~~~~~~~~~~~~~
   kernel/sched/fair.c: At top level:
   kernel/sched/fair.c:5438:6: warning: no previous prototype for 'init_cfs_bandwidth' [-Wmissing-prototypes]
    5438 | void init_cfs_bandwidth(struct cfs_bandwidth *cfs_b) {}
         |      ^~~~~~~~~~~~~~~~~~
   kernel/sched/fair.c:11457:6: warning: no previous prototype for 'free_fair_sched_group' [-Wmissing-prototypes]
   11457 | void free_fair_sched_group(struct task_group *tg) { }
         |      ^~~~~~~~~~~~~~~~~~~~~
   kernel/sched/fair.c:11459:5: warning: no previous prototype for 'alloc_fair_sched_group' [-Wmissing-prototypes]
   11459 | int alloc_fair_sched_group(struct task_group *tg, struct task_group *parent)
         |     ^~~~~~~~~~~~~~~~~~~~~~
   kernel/sched/fair.c:11464:6: warning: no previous prototype for 'online_fair_sched_group' [-Wmissing-prototypes]
   11464 | void online_fair_sched_group(struct task_group *tg) { }
         |      ^~~~~~~~~~~~~~~~~~~~~~~
   kernel/sched/fair.c:11466:6: warning: no previous prototype for 'unregister_fair_sched_group' [-Wmissing-prototypes]
   11466 | void unregister_fair_sched_group(struct task_group *tg) { }
         |      ^~~~~~~~~~~~~~~~~~~~~~~~~~~
   cc1: some warnings being treated as errors
--
   In file included from include/linux/mempolicy.h:11,
                    from include/linux/migrate.h:6,
                    from kernel/sched/sched.h:54,
                    from kernel/sched/rt.c:6:
   include/linux/dax.h: In function 'bdev_dax_supported':
   include/linux/dax.h:125:30: error: passing argument 1 of '__bdev_dax_supported' from incompatible pointer type [-Werror=incompatible-pointer-types]
     125 |  return __bdev_dax_supported(bdev, blocksize);
         |                              ^~~~
         |                              |
         |                              struct block_device *
   include/linux/dax.h:120:46: note: expected 'struct dax_device *' but argument is of type 'struct block_device *'
     120 | bool __bdev_dax_supported(struct dax_device *dax_dev, struct block_device *bdev,
         |                           ~~~~~~~~~~~~~~~~~~~^~~~~~~
>> include/linux/dax.h:125:36: warning: passing argument 2 of '__bdev_dax_supported' makes pointer from integer without a cast [-Wint-conversion]
     125 |  return __bdev_dax_supported(bdev, blocksize);
         |                                    ^~~~~~~~~
         |                                    |
         |                                    int
   include/linux/dax.h:120:76: note: expected 'struct block_device *' but argument is of type 'int'
     120 | bool __bdev_dax_supported(struct dax_device *dax_dev, struct block_device *bdev,
         |                                                       ~~~~~~~~~~~~~~~~~~~~~^~~~
   include/linux/dax.h:125:9: error: too few arguments to function '__bdev_dax_supported'
     125 |  return __bdev_dax_supported(bdev, blocksize);
         |         ^~~~~~~~~~~~~~~~~~~~
   include/linux/dax.h:120:6: note: declared here
     120 | bool __bdev_dax_supported(struct dax_device *dax_dev, struct block_device *bdev,
         |      ^~~~~~~~~~~~~~~~~~~~
   kernel/sched/rt.c: At top level:
   kernel/sched/rt.c:253:6: warning: no previous prototype for 'free_rt_sched_group' [-Wmissing-prototypes]
     253 | void free_rt_sched_group(struct task_group *tg) { }
         |      ^~~~~~~~~~~~~~~~~~~
   kernel/sched/rt.c:255:5: warning: no previous prototype for 'alloc_rt_sched_group' [-Wmissing-prototypes]
     255 | int alloc_rt_sched_group(struct task_group *tg, struct task_group *parent)
         |     ^~~~~~~~~~~~~~~~~~~~
   kernel/sched/rt.c:669:6: warning: no previous prototype for 'sched_rt_bandwidth_account' [-Wmissing-prototypes]
     669 | bool sched_rt_bandwidth_account(struct rt_rq *rt_rq)
         |      ^~~~~~~~~~~~~~~~~~~~~~~~~~
   cc1: some warnings being treated as errors
--
   In file included from include/linux/mempolicy.h:11,
                    from include/linux/migrate.h:6,
                    from kernel/sched/sched.h:54,
                    from kernel/sched/psi.c:146:
   include/linux/dax.h: In function 'bdev_dax_supported':
   include/linux/dax.h:125:30: error: passing argument 1 of '__bdev_dax_supported' from incompatible pointer type [-Werror=incompatible-pointer-types]
     125 |  return __bdev_dax_supported(bdev, blocksize);
         |                              ^~~~
         |                              |
         |                              struct block_device *
   include/linux/dax.h:120:46: note: expected 'struct dax_device *' but argument is of type 'struct block_device *'
     120 | bool __bdev_dax_supported(struct dax_device *dax_dev, struct block_device *bdev,
         |                           ~~~~~~~~~~~~~~~~~~~^~~~~~~
>> include/linux/dax.h:125:36: warning: passing argument 2 of '__bdev_dax_supported' makes pointer from integer without a cast [-Wint-conversion]
     125 |  return __bdev_dax_supported(bdev, blocksize);
         |                                    ^~~~~~~~~
         |                                    |
         |                                    int
   include/linux/dax.h:120:76: note: expected 'struct block_device *' but argument is of type 'int'
     120 | bool __bdev_dax_supported(struct dax_device *dax_dev, struct block_device *bdev,
         |                                                       ~~~~~~~~~~~~~~~~~~~~~^~~~
   include/linux/dax.h:125:9: error: too few arguments to function '__bdev_dax_supported'
     125 |  return __bdev_dax_supported(bdev, blocksize);
         |         ^~~~~~~~~~~~~~~~~~~~
   include/linux/dax.h:120:6: note: declared here
     120 | bool __bdev_dax_supported(struct dax_device *dax_dev, struct block_device *bdev,
         |      ^~~~~~~~~~~~~~~~~~~~
   kernel/sched/psi.c: At top level:
   kernel/sched/psi.c:1112:21: warning: no previous prototype for 'psi_trigger_create' [-Wmissing-prototypes]
    1112 | struct psi_trigger *psi_trigger_create(struct psi_group *group,
         |                     ^~~~~~~~~~~~~~~~~~
   kernel/sched/psi.c:1246:6: warning: no previous prototype for 'psi_trigger_replace' [-Wmissing-prototypes]
    1246 | void psi_trigger_replace(void **trigger_ptr, struct psi_trigger *new)
         |      ^~~~~~~~~~~~~~~~~~~
   kernel/sched/psi.c:1258:10: warning: no previous prototype for 'psi_trigger_poll' [-Wmissing-prototypes]
    1258 | __poll_t psi_trigger_poll(void **trigger_ptr,
         |          ^~~~~~~~~~~~~~~~
   cc1: some warnings being treated as errors


vim +/__bdev_dax_supported +125 include/linux/dax.h

f5705aa8cfed14 Dan Williams      2017-05-13  116  
f44c77630d26ca Dan Williams      2018-03-07  117  struct writeback_control;
ef51042472f55b Dan Williams      2017-05-08  118  int bdev_dax_pgoff(struct block_device *, sector_t, size_t, pgoff_t *pgoff);
ef51042472f55b Dan Williams      2017-05-08  119  #if IS_ENABLED(CONFIG_FS_DAX)
6ee1cc412315e2 Christoph Hellwig 2021-07-30  120  bool __bdev_dax_supported(struct dax_device *dax_dev, struct block_device *bdev,
6ee1cc412315e2 Christoph Hellwig 2021-07-30  121  		int blocksize);
6ee1cc412315e2 Christoph Hellwig 2021-07-30  122  static inline bool bdev_dax_supported(struct dax_device *dax_dev,
6ee1cc412315e2 Christoph Hellwig 2021-07-30  123  		struct block_device *bdev, int blocksize)
ef51042472f55b Dan Williams      2017-05-08  124  {
ba23cba9b3bdc9 Darrick J. Wong   2018-05-30 @125  	return __bdev_dax_supported(bdev, blocksize);
ef51042472f55b Dan Williams      2017-05-08  126  }
f5705aa8cfed14 Dan Williams      2017-05-13  127  

:::::: The code at line 125 was first introduced by commit
:::::: ba23cba9b3bdc967aabdc6ff1e3e9b11ce05bb4f fs: allow per-device dax status checking for filesystems

:::::: 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@lists.01.org

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

                 reply	other threads:[~2021-07-30 12:32 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=202107302055.2msbkb0w-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=hch@lst.de \
    --cc=kbuild-all@lists.01.org \
    --cc=linux-kernel@vger.kernel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).