From: kernel test robot <lkp@intel.com>
To: Kent Overstreet <kent.overstreet@linux.dev>
Cc: llvm@lists.linux.dev, oe-kbuild-all@lists.linux.dev
Subject: [koverstreet-bcachefs:bcachefs-testing 563/1112] fs/bcachefs/debug/async_objs.c:64:14: error: invalid application of 'sizeof' to an incomplete type 'struct dump_iter'
Date: Thu, 11 Dec 2025 03:05:09 +0800 [thread overview]
Message-ID: <202512110258.0KOGju5g-lkp@intel.com> (raw)
tree: https://github.com/koverstreet/bcachefs bcachefs-testing
head: c584fbbbf2e8eb98b64af4c5ea5d02d549dd4e4d
commit: da7a6f67bdb81c87b94b7e549f55fb1b3298fc83 [563/1112] bcachefs: kill CONFIG_BCACHEFS_ASYNC_OBJECT_LISTS
config: arm-randconfig-003-20251211 (https://download.01.org/0day-ci/archive/20251211/202512110258.0KOGju5g-lkp@intel.com/config)
compiler: clang version 22.0.0git (https://github.com/llvm/llvm-project 6ec8c4351cfc1d0627d1633b02ea787bd29c77d8)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20251211/202512110258.0KOGju5g-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@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202512110258.0KOGju5g-lkp@intel.com/
All errors (new ones prefixed by >>):
>> fs/bcachefs/debug/async_objs.c:64:14: error: invalid application of 'sizeof' to an incomplete type 'struct dump_iter'
64 | i = kzalloc(sizeof(struct dump_iter), GFP_KERNEL);
| ^ ~~~~~~~~~~~~~~~~~~
include/linux/slab.h:1041:52: note: expanded from macro 'kzalloc'
1041 | #define kzalloc(...) alloc_hooks(kzalloc_noprof(__VA_ARGS__))
| ^~~~~~~~~~~
include/linux/alloc_tag.h:253:31: note: expanded from macro 'alloc_hooks'
253 | alloc_hooks_tag(&_alloc_tag, _do_alloc); \
| ^~~~~~~~~
include/linux/alloc_tag.h:239:9: note: expanded from macro 'alloc_hooks_tag'
239 | typeof(_do_alloc) _res; \
| ^~~~~~~~~
fs/bcachefs/debug/async_objs.c:62:9: note: forward declaration of 'struct dump_iter'
62 | struct dump_iter *i;
| ^
>> fs/bcachefs/debug/async_objs.c:64:14: error: invalid application of 'sizeof' to an incomplete type 'struct dump_iter'
64 | i = kzalloc(sizeof(struct dump_iter), GFP_KERNEL);
| ^ ~~~~~~~~~~~~~~~~~~
include/linux/slab.h:1041:52: note: expanded from macro 'kzalloc'
1041 | #define kzalloc(...) alloc_hooks(kzalloc_noprof(__VA_ARGS__))
| ^~~~~~~~~~~
include/linux/alloc_tag.h:253:31: note: expanded from macro 'alloc_hooks'
253 | alloc_hooks_tag(&_alloc_tag, _do_alloc); \
| ^~~~~~~~~
include/linux/alloc_tag.h:243:10: note: expanded from macro 'alloc_hooks_tag'
243 | _res = _do_alloc; \
| ^~~~~~~~~
fs/bcachefs/debug/async_objs.c:62:9: note: forward declaration of 'struct dump_iter'
62 | struct dump_iter *i;
| ^
>> fs/bcachefs/debug/async_objs.c:64:14: error: invalid application of 'sizeof' to an incomplete type 'struct dump_iter'
64 | i = kzalloc(sizeof(struct dump_iter), GFP_KERNEL);
| ^ ~~~~~~~~~~~~~~~~~~
include/linux/slab.h:1041:52: note: expanded from macro 'kzalloc'
1041 | #define kzalloc(...) alloc_hooks(kzalloc_noprof(__VA_ARGS__))
| ^~~~~~~~~~~
include/linux/alloc_tag.h:253:31: note: expanded from macro 'alloc_hooks'
253 | alloc_hooks_tag(&_alloc_tag, _do_alloc); \
| ^~~~~~~~~
include/linux/alloc_tag.h:246:10: note: expanded from macro 'alloc_hooks_tag'
246 | _res = _do_alloc; \
| ^~~~~~~~~
fs/bcachefs/debug/async_objs.c:62:9: note: forward declaration of 'struct dump_iter'
62 | struct dump_iter *i;
| ^
>> fs/bcachefs/debug/async_objs.c:69:3: error: incomplete definition of type 'struct dump_iter'
69 | i->from = POS_MIN;
| ~^
fs/bcachefs/debug/async_objs.c:62:9: note: forward declaration of 'struct dump_iter'
62 | struct dump_iter *i;
| ^
fs/bcachefs/debug/async_objs.c:70:3: error: incomplete definition of type 'struct dump_iter'
70 | i->iter = 0;
| ~^
fs/bcachefs/debug/async_objs.c:62:9: note: forward declaration of 'struct dump_iter'
62 | struct dump_iter *i;
| ^
fs/bcachefs/debug/async_objs.c:71:3: error: incomplete definition of type 'struct dump_iter'
71 | i->c = container_of(list, struct bch_fs, async_objs[list->idx]);
| ~^
fs/bcachefs/debug/async_objs.c:62:9: note: forward declaration of 'struct dump_iter'
62 | struct dump_iter *i;
| ^
fs/bcachefs/debug/async_objs.c:72:3: error: incomplete definition of type 'struct dump_iter'
72 | i->list = list;
| ~^
fs/bcachefs/debug/async_objs.c:62:9: note: forward declaration of 'struct dump_iter'
62 | struct dump_iter *i;
| ^
fs/bcachefs/debug/async_objs.c:73:3: error: incomplete definition of type 'struct dump_iter'
73 | i->buf = PRINTBUF;
| ~^
fs/bcachefs/debug/async_objs.c:62:9: note: forward declaration of 'struct dump_iter'
62 | struct dump_iter *i;
| ^
fs/bcachefs/debug/async_objs.c:81:33: error: incomplete definition of type 'struct dump_iter'
81 | struct async_obj_list *list = i->list;
| ~^
fs/bcachefs/debug/async_objs.c:80:9: note: forward declaration of 'struct dump_iter'
80 | struct dump_iter *i = file->private_data;
| ^
fs/bcachefs/debug/async_objs.c:84:3: error: incomplete definition of type 'struct dump_iter'
84 | i->ubuf = buf;
| ~^
fs/bcachefs/debug/async_objs.c:80:9: note: forward declaration of 'struct dump_iter'
80 | struct dump_iter *i = file->private_data;
| ^
fs/bcachefs/debug/async_objs.c:85:3: error: incomplete definition of type 'struct dump_iter'
85 | i->size = size;
| ~^
fs/bcachefs/debug/async_objs.c:80:9: note: forward declaration of 'struct dump_iter'
80 | struct dump_iter *i = file->private_data;
| ^
fs/bcachefs/debug/async_objs.c:86:3: error: incomplete definition of type 'struct dump_iter'
86 | i->ret = 0;
| ~^
fs/bcachefs/debug/async_objs.c:80:9: note: forward declaration of 'struct dump_iter'
80 | struct dump_iter *i = file->private_data;
| ^
fs/bcachefs/debug/async_objs.c:90:51: error: incomplete definition of type 'struct dump_iter'
90 | fast_list_for_each_from(&list->list, iter, obj, i->iter) {
| ~^
fs/bcachefs/debug/async_objs.c:80:9: note: forward declaration of 'struct dump_iter'
80 | struct dump_iter *i = file->private_data;
| ^
fs/bcachefs/debug/async_objs.c:90:51: error: incomplete definition of type 'struct dump_iter'
90 | fast_list_for_each_from(&list->list, iter, obj, i->iter) {
| ~^
fs/bcachefs/debug/async_objs.c:80:9: note: forward declaration of 'struct dump_iter'
80 | struct dump_iter *i = file->private_data;
| ^
>> fs/bcachefs/debug/async_objs.c:91:9: error: call to undeclared function 'bch2_debugfs_flush_buf'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
91 | ret = bch2_debugfs_flush_buf(i);
| ^
fs/bcachefs/debug/async_objs.c:95:9: error: incomplete definition of type 'struct dump_iter'
95 | if (!i->size)
| ~^
fs/bcachefs/debug/async_objs.c:80:9: note: forward declaration of 'struct dump_iter'
80 | struct dump_iter *i = file->private_data;
| ^
fs/bcachefs/debug/async_objs.c:98:23: error: incomplete definition of type 'struct dump_iter'
98 | list->obj_to_text(&i->buf, i->c, obj);
| ~^
fs/bcachefs/debug/async_objs.c:80:9: note: forward declaration of 'struct dump_iter'
80 | struct dump_iter *i = file->private_data;
| ^
fs/bcachefs/debug/async_objs.c:98:31: error: incomplete definition of type 'struct dump_iter'
98 | list->obj_to_text(&i->buf, i->c, obj);
| ~^
fs/bcachefs/debug/async_objs.c:80:9: note: forward declaration of 'struct dump_iter'
80 | struct dump_iter *i = file->private_data;
| ^
fs/bcachefs/debug/async_objs.c:99:4: error: incomplete definition of type 'struct dump_iter'
99 | i->iter = iter.pos;
| ~^
fs/bcachefs/debug/async_objs.c:80:9: note: forward declaration of 'struct dump_iter'
80 | struct dump_iter *i = file->private_data;
| ^
fatal error: too many errors emitted, stopping now [-ferror-limit=]
20 errors generated.
vim +64 fs/bcachefs/debug/async_objs.c
41e51769b8a649 fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 58
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 59 static int bch2_async_obj_list_open(struct inode *inode, struct file *file)
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 60 {
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 61 struct async_obj_list *list = inode->i_private;
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 @62 struct dump_iter *i;
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 63
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 @64 i = kzalloc(sizeof(struct dump_iter), GFP_KERNEL);
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 65 if (!i)
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 66 return -ENOMEM;
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 67
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 68 file->private_data = i;
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 @69 i->from = POS_MIN;
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 70 i->iter = 0;
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 71 i->c = container_of(list, struct bch_fs, async_objs[list->idx]);
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 72 i->list = list;
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 73 i->buf = PRINTBUF;
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 74 return 0;
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 75 }
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 76
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 77 static ssize_t bch2_async_obj_list_read(struct file *file, char __user *buf,
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 78 size_t size, loff_t *ppos)
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 79 {
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 @80 struct dump_iter *i = file->private_data;
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 81 struct async_obj_list *list = i->list;
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 82 ssize_t ret = 0;
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 83
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 84 i->ubuf = buf;
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 85 i->size = size;
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 86 i->ret = 0;
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 87
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 88 struct genradix_iter iter;
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 89 void *obj;
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 90 fast_list_for_each_from(&list->list, iter, obj, i->iter) {
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 @91 ret = bch2_debugfs_flush_buf(i);
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 92 if (ret)
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 93 return ret;
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 94
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 95 if (!i->size)
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 96 break;
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 97
43b6a46d5d95bf fs/bcachefs/async_objs.c Kent Overstreet 2025-07-10 98 list->obj_to_text(&i->buf, i->c, obj);
90221f7301320b fs/bcachefs/async_objs.c Kent Overstreet 2025-07-10 99 i->iter = iter.pos;
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 100 }
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 101
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 102 if (i->buf.allocation_failure)
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 103 ret = -ENOMEM;
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 104
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 105 if (!ret)
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 106 ret = bch2_debugfs_flush_buf(i);
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 107
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 108 return ret ?: i->ret;
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 109 }
0499a82b18b5dd fs/bcachefs/async_objs.c Kent Overstreet 2025-04-21 110
:::::: The code at line 64 was first introduced by commit
:::::: 0499a82b18b5ddee0d97d2cfcae0c0120f858c1f bcachefs: Async object debugging
:::::: TO: Kent Overstreet <kent.overstreet@linux.dev>
:::::: CC: Kent Overstreet <kent.overstreet@linux.dev>
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
reply other threads:[~2025-12-10 19:05 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=202512110258.0KOGju5g-lkp@intel.com \
--to=lkp@intel.com \
--cc=kent.overstreet@linux.dev \
--cc=llvm@lists.linux.dev \
--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