All of lore.kernel.org
 help / color / mirror / Atom feed
* [jlayton:ceph-fscache-iter 3/3] arch/riscv/include/asm/cmpxchg.h:144:1: error: incompatible types when initializing type 'struct fscache_cookie *' using type 'struct fscache_cookie'
@ 2020-05-12  1:06 kbuild test robot
  0 siblings, 0 replies; only message in thread
From: kbuild test robot @ 2020-05-12  1:06 UTC (permalink / raw)
  To: kbuild-all

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

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/jlayton/linux.git ceph-fscache-iter
head:   33c7b534b8d4e908533e47b67cd25cc31db149d9
commit: 33c7b534b8d4e908533e47b67cd25cc31db149d9 [3/3] SQUASH: more conversion
config: riscv-allyesconfig (attached as .config)
compiler: riscv64-linux-gcc (GCC) 9.3.0
reproduce:
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        git checkout 33c7b534b8d4e908533e47b67cd25cc31db149d9
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day GCC_VERSION=9.3.0 make.cross ARCH=riscv 

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

All errors (new ones prefixed by >>):

   fs/ceph/cache.h:50:9: warning: 'return' with a value, in function returning void [-Wreturn-type]
      50 |  return fscache_uncache_page(ci->fscache, page);
         |         ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   fs/ceph/cache.h:46:20: note: declared here
      46 | static inline void ceph_fscache_uncache_page(struct inode *inode,
         |                    ^~~~~~~~~~~~~~~~~~~~~~~~~
   fs/ceph/cache.h: In function 'ceph_release_fscache_page':
   fs/ceph/cache.h:57:9: error: implicit declaration of function 'fscache_maybe_release_page' [-Werror=implicit-function-declaration]
      57 |  return fscache_maybe_release_page(ci->fscache, page, gfp);
         |         ^~~~~~~~~~~~~~~~~~~~~~~~~~
   fs/ceph/cache.h: In function 'ceph_fscache_readpage_cancel':
   fs/ceph/cache.h:65:3: error: implicit declaration of function '__fscache_uncache_page'; did you mean 'ceph_fscache_uncache_page'? [-Werror=implicit-function-declaration]
      65 |   __fscache_uncache_page(ci->fscache, page);
         |   ^~~~~~~~~~~~~~~~~~~~~~
         |   ceph_fscache_uncache_page
   fs/ceph/cache.h: In function 'ceph_fscache_readpages_cancel':
   fs/ceph/cache.h:72:9: error: implicit declaration of function 'fscache_readpages_cancel'; did you mean 'ceph_fscache_readpages_cancel'? [-Werror=implicit-function-declaration]
      72 |  return fscache_readpages_cancel(ci->fscache, pages);
         |         ^~~~~~~~~~~~~~~~~~~~~~~~
         |         ceph_fscache_readpages_cancel
   fs/ceph/cache.h:72:9: warning: 'return' with a value, in function returning void [-Wreturn-type]
      72 |  return fscache_readpages_cancel(ci->fscache, pages);
         |         ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   fs/ceph/cache.h:68:20: note: declared here
      68 | static inline void ceph_fscache_readpages_cancel(struct inode *inode,
         |                    ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   fs/ceph/cache.c: In function 'ceph_fscache_register_fs':
   fs/ceph/cache.c:83:17: error: too few arguments to function 'fscache_acquire_cookie'
      83 |  fsc->fscache = fscache_acquire_cookie(ceph_cache_netfs.primary_index,
         |                 ^~~~~~~~~~~~~~~~~~~~~~
   In file included from fs/ceph/super.h:24,
                    from fs/ceph/cache.c:12:
   include/linux/fscache.h:307:24: note: declared here
     307 | struct fscache_cookie *fscache_acquire_cookie(
         |                        ^~~~~~~~~~~~~~~~~~~~~~
   fs/ceph/cache.c: At top level:
   fs/ceph/cache.c:102:30: error: return type is an incomplete type
     102 | static enum fscache_checkaux ceph_fscache_inode_check_aux(
         |                              ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
   fs/ceph/cache.c: In function 'ceph_fscache_inode_check_aux':
   fs/ceph/cache.c:112:10: error: 'FSCACHE_CHECKAUX_OBSOLETE' undeclared (first use in this function)
     112 |   return FSCACHE_CHECKAUX_OBSOLETE;
         |          ^~~~~~~~~~~~~~~~~~~~~~~~~
   fs/ceph/cache.c:112:10: note: each undeclared identifier is reported only once for each function it appears in
   fs/ceph/cache.c:112:10: warning: 'return' with a value, in function returning void [-Wreturn-type]
   fs/ceph/cache.c:102:30: note: declared here
     102 | static enum fscache_checkaux ceph_fscache_inode_check_aux(
         |                              ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
   fs/ceph/cache.c:120:10: warning: 'return' with a value, in function returning void [-Wreturn-type]
     120 |   return FSCACHE_CHECKAUX_OBSOLETE;
         |          ^~~~~~~~~~~~~~~~~~~~~~~~~
   fs/ceph/cache.c:102:30: note: declared here
     102 | static enum fscache_checkaux ceph_fscache_inode_check_aux(
         |                              ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
   fs/ceph/cache.c:123:9: error: 'FSCACHE_CHECKAUX_OKAY' undeclared (first use in this function)
     123 |  return FSCACHE_CHECKAUX_OKAY;
         |         ^~~~~~~~~~~~~~~~~~~~~
   fs/ceph/cache.c:123:9: warning: 'return' with a value, in function returning void [-Wreturn-type]
   fs/ceph/cache.c:102:30: note: declared here
     102 | static enum fscache_checkaux ceph_fscache_inode_check_aux(
         |                              ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
   fs/ceph/cache.c: At top level:
   fs/ceph/cache.c:126:21: error: variable 'ceph_fscache_inode_object_def' has initializer but incomplete type
     126 | static const struct fscache_cookie_def ceph_fscache_inode_object_def = {
         |                     ^~~~~~~~~~~~~~~~~~
   fs/ceph/cache.c:127:3: error: 'const struct fscache_cookie_def' has no member named 'name'
     127 |  .name  = "CEPH.inode",
         |   ^~~~
   fs/ceph/cache.c:127:11: warning: excess elements in struct initializer
     127 |  .name  = "CEPH.inode",
         |           ^~~~~~~~~~~~
   fs/ceph/cache.c:127:11: note: (near initialization for 'ceph_fscache_inode_object_def')
   fs/ceph/cache.c:128:3: error: 'const struct fscache_cookie_def' has no member named 'type'
     128 |  .type  = FSCACHE_COOKIE_TYPE_DATAFILE,
         |   ^~~~
   fs/ceph/cache.c:128:11: warning: excess elements in struct initializer
     128 |  .type  = FSCACHE_COOKIE_TYPE_DATAFILE,
         |           ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
   fs/ceph/cache.c:128:11: note: (near initialization for 'ceph_fscache_inode_object_def')
   fs/ceph/cache.c:129:3: error: 'const struct fscache_cookie_def' has no member named 'check_aux'
     129 |  .check_aux = ceph_fscache_inode_check_aux,
         |   ^~~~~~~~~
   fs/ceph/cache.c:129:15: warning: excess elements in struct initializer
     129 |  .check_aux = ceph_fscache_inode_check_aux,
         |               ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
   fs/ceph/cache.c:129:15: note: (near initialization for 'ceph_fscache_inode_object_def')
   fs/ceph/cache.c: In function 'ceph_fscache_register_inode_cookie':
   fs/ceph/cache.c:143:2: error: expected expression before 'if'
     143 |  if (!fsc->fscache)
         |  ^~
   fs/ceph/cache.c:143:2: warning: 'return' with a value, in function returning void [-Wreturn-type]
   fs/ceph/cache.c:132:6: note: declared here
     132 | void ceph_fscache_register_inode_cookie(struct inode *inode)
         |      ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   In file included from arch/riscv/include/asm/atomic.h:19,
                    from include/linux/atomic.h:7,
                    from include/linux/refcount.h:95,
                    from include/linux/fs_context.h:12,
                    from fs/ceph/cache.c:11:
   fs/ceph/cache.c: In function 'ceph_fscache_unregister_inode_cookie':
>> arch/riscv/include/asm/cmpxchg.h:145:27: error: invalid initializer
     145 |  __typeof__(*(ptr)) _x_ = (x);     \
         |                           ^
   fs/ceph/cache.c:163:34: note: in expansion of macro 'xchg'
     163 |  struct fscache_cookie* cookie = xchg(ci->fscache, NULL);
         |                                  ^~~~
   arch/riscv/include/asm/cmpxchg.h:145:27: note: (near initialization for 'cookie')
     145 |  __typeof__(*(ptr)) _x_ = (x);     \
         |                           ^
   fs/ceph/cache.c:163:34: note: in expansion of macro 'xchg'
     163 |  struct fscache_cookie* cookie = xchg(ci->fscache, NULL);
         |                                  ^~~~
>> arch/riscv/include/asm/cmpxchg.h:144:1: error: incompatible types when initializing type 'struct fscache_cookie *' using type 'struct fscache_cookie'
     144 | ({         \
         | ^
   fs/ceph/cache.c:163:34: note: in expansion of macro 'xchg'
     163 |  struct fscache_cookie* cookie = xchg(ci->fscache, NULL);
         |                                  ^~~~
   fs/ceph/cache.c:166:3: error: too many arguments to function 'fscache_relinquish_cookie'
     166 |   fscache_relinquish_cookie(cookie, &ci->i_vino, false);
         |   ^~~~~~~~~~~~~~~~~~~~~~~~~
   In file included from fs/ceph/super.h:24,
                    from fs/ceph/cache.c:12:
   include/linux/fscache.h:377:6: note: declared here
     377 | void fscache_relinquish_cookie(struct fscache_cookie *cookie, bool retire)
         |      ^~~~~~~~~~~~~~~~~~~~~~~~~
   fs/ceph/cache.c: In function 'ceph_readpage_from_fscache':
   fs/ceph/cache.c:203:8: error: implicit declaration of function 'fscache_read_or_alloc_page' [-Werror=implicit-function-declaration]
     203 |  ret = fscache_read_or_alloc_page(ci->fscache, page,
         |        ^~~~~~~~~~~~~~~~~~~~~~~~~~
   fs/ceph/cache.c: In function 'ceph_readpages_from_fscache':
   fs/ceph/cache.c:232:8: error: implicit declaration of function 'fscache_read_or_alloc_pages' [-Werror=implicit-function-declaration]
     232 |  ret = fscache_read_or_alloc_pages(ci->fscache, mapping, pages, nr_pages,
         |        ^~~~~~~~~~~~~~~~~~~~~~~~~~~
   fs/ceph/cache.c: In function 'ceph_readpage_to_fscache':
   fs/ceph/cache.c:261:8: error: implicit declaration of function 'fscache_write_page'; did you mean 'fscache_write'? [-Werror=implicit-function-declaration]
     261 |  ret = fscache_write_page(ci->fscache, page, i_size_read(inode),
         |        ^~~~~~~~~~~~~~~~~~
         |        fscache_write
   fs/ceph/cache.c: In function 'ceph_invalidate_fscache_page':
   fs/ceph/cache.c:274:2: error: implicit declaration of function 'fscache_wait_on_page_write' [-Werror=implicit-function-declaration]
     274 |  fscache_wait_on_page_write(ci->fscache, page);
         |  ^~~~~~~~~~~~~~~~~~~~~~~~~~
   fs/ceph/cache.c: In function 'ceph_fscache_unregister_fs':
   fs/ceph/cache.c:296:3: error: too many arguments to function '__fscache_relinquish_cookie'
     296 |   __fscache_relinquish_cookie(fsc->fscache, NULL, false);
         |   ^~~~~~~~~~~~~~~~~~~~~~~~~~~
   In file included from fs/ceph/super.h:24,
                    from fs/ceph/cache.c:12:
   include/linux/fscache.h:200:13: note: declared here
     200 | extern void __fscache_relinquish_cookie(struct fscache_cookie *, bool);
         |             ^~~~~~~~~~~~~~~~~~~~~~~~~~~
   fs/ceph/cache.c: In function 'ceph_fscache_revalidate_cookie':
   fs/ceph/cache.c:313:7: error: implicit declaration of function 'fscache_check_consistency' [-Werror=implicit-function-declaration]
     313 |   if (fscache_check_consistency(ci->fscache, &ci->i_vino))
         |       ^~~~~~~~~~~~~~~~~~~~~~~~~
   fs/ceph/cache.c:314:4: error: too few arguments to function 'fscache_invalidate'
     314 |    fscache_invalidate(ci->fscache);
         |    ^~~~~~~~~~~~~~~~~~
   In file included from fs/ceph/super.h:24,
                    from fs/ceph/cache.c:12:
   include/linux/fscache.h:468:6: note: declared here
     468 | void fscache_invalidate(struct fscache_cookie *cookie,
         |      ^~~~~~~~~~~~~~~~~~
   fs/ceph/cache.c: At top level:
   fs/ceph/cache.c:126:40: error: storage size of 'ceph_fscache_inode_object_def' isn't known
     126 | static const struct fscache_cookie_def ceph_fscache_inode_object_def = {
         |                                        ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   cc1: some warnings being treated as errors

vim +144 arch/riscv/include/asm/cmpxchg.h

5ce6c1f3535fa8 Andrea Parri   2018-03-09  142  
5ce6c1f3535fa8 Andrea Parri   2018-03-09  143  #define xchg(ptr, x)							\
5ce6c1f3535fa8 Andrea Parri   2018-03-09 @144  ({									\
5ce6c1f3535fa8 Andrea Parri   2018-03-09 @145  	__typeof__(*(ptr)) _x_ = (x);					\
5ce6c1f3535fa8 Andrea Parri   2018-03-09  146  	(__typeof__(*(ptr))) __xchg((ptr), _x_, sizeof(*(ptr)));	\
5ce6c1f3535fa8 Andrea Parri   2018-03-09  147  })
fab957c11efe2f Palmer Dabbelt 2017-07-10  148  

:::::: The code at line 144 was first introduced by commit
:::::: 5ce6c1f3535fa8d2134468547377b7b737042834 riscv/atomic: Strengthen implementations with fences

:::::: TO: Andrea Parri <parri.andrea@gmail.com>
:::::: CC: Palmer Dabbelt <palmer@sifive.com>

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

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2020-05-12  1:06 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-05-12  1:06 [jlayton:ceph-fscache-iter 3/3] arch/riscv/include/asm/cmpxchg.h:144:1: error: incompatible types when initializing type 'struct fscache_cookie *' using type 'struct fscache_cookie' kbuild test robot

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.