From: kernel test robot <lkp@intel.com>
Cc: oe-kbuild-all@lists.linux.dev, llvm@lists.linux.dev
Subject: [leon-rdma:rxe-rust-v1 65/106] Unable to generate bindings: clang diagnosed error: rust/helpers/net/device.c:36:9: error: invalid application of 'sizeof' to bit-field
Date: Fri, 16 Oct 2026 09:21:43 +0800 [thread overview]
Message-ID: <202610160917.DsbpZfde-lkp@intel.com> (raw)
TO: Leon Romanovsky <leonro@nvidia.com>
Hi Leon,
First bad commit (maybe != root cause):
tree: https://git.kernel.org/pub/scm/linux/kernel/git/leon/linux-rdma.git rxe-rust-v1
head: bb839a6cc0506a07f63d8931ee7cf500e82f362a
commit: 5909e537a0a6265f69309aac377dd5ab2a3672c4 [65/106] rust: net: Add borrowed network devices and notifier registrations
config: um-allmodconfig (https://download.01.org/0day-ci/archive/20261016/202610160917.DsbpZfde-lkp@intel.com/config)
compiler: clang version 17.0.6 (https://github.com/llvm/llvm-project 6009708b4367171ccdbf4b5905cb6a803753fe18)
rustc: rustc 1.96.0 (ac68faa20 2026-05-25)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20261016/202610160917.DsbpZfde-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/202610160917.DsbpZfde-lkp@intel.com/
All errors (new ones prefixed by >>):
In file included from include/linux/hardirq.h:11:
In file included from arch/um/include/asm/hardirq.h:24:
In file included from include/linux/irq.h:20:
In file included from include/linux/io.h:12:
In file included from arch/um/include/asm/io.h:24:
include/asm-generic/io.h:1209:55: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
1209 | return (port > MMIO_UPPER_LIMIT) ? NULL : PCI_IOBASE + port;
| ~~~~~~~~~~ ^
1 warning generated.
In file included from rust/helpers/helpers.c:48:
In file included from rust/helpers/blk.c:3:
In file included from include/linux/blk-mq.h:5:
In file included from include/linux/blkdev.h:9:
In file included from include/linux/blk_types.h:10:
In file included from include/linux/bvec.h:10:
In file included from include/linux/highmem.h:12:
In file included from include/linux/hardirq.h:11:
In file included from arch/um/include/asm/hardirq.h:24:
In file included from include/linux/irq.h:20:
In file included from include/linux/io.h:12:
In file included from arch/um/include/asm/io.h:24:
include/asm-generic/io.h:1209:55: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
1209 | return (port > MMIO_UPPER_LIMIT) ? NULL : PCI_IOBASE + port;
| ~~~~~~~~~~ ^
In file included from rust/helpers/helpers.c:80:
rust/helpers/net/device.c:36:9: error: invalid application of 'sizeof' to bit-field
36 | return READ_ONCE(dev->priv_flags) & IFF_802_1Q_VLAN;
| ^
include/asm-generic/rwonce.h:49:2: note: expanded from macro 'READ_ONCE'
49 | compiletime_assert_rwonce_type(x); \
| ^
include/asm-generic/rwonce.h:36:21: note: expanded from macro 'compiletime_assert_rwonce_type'
36 | compiletime_assert(__native_word(t) || sizeof(t) == sizeof(long long), \
| ^
include/linux/compiler_types.h:663:9: note: expanded from macro '__native_word'
663 | (sizeof(t) == sizeof(char) || sizeof(t) == sizeof(short) || \
| ^
In file included from rust/helpers/helpers.c:80:
rust/helpers/net/device.c:36:9: error: invalid application of 'sizeof' to bit-field
include/asm-generic/rwonce.h:49:2: note: expanded from macro 'READ_ONCE'
49 | compiletime_assert_rwonce_type(x); \
| ^
include/asm-generic/rwonce.h:36:21: note: expanded from macro 'compiletime_assert_rwonce_type'
36 | compiletime_assert(__native_word(t) || sizeof(t) == sizeof(long long), \
| ^
include/linux/compiler_types.h:663:38: note: expanded from macro '__native_word'
663 | (sizeof(t) == sizeof(char) || sizeof(t) == sizeof(short) || \
| ^
In file included from rust/helpers/helpers.c:80:
rust/helpers/net/device.c:36:9: error: invalid application of 'sizeof' to bit-field
include/asm-generic/rwonce.h:49:2: note: expanded from macro 'READ_ONCE'
49 | compiletime_assert_rwonce_type(x); \
| ^
include/asm-generic/rwonce.h:36:21: note: expanded from macro 'compiletime_assert_rwonce_type'
36 | compiletime_assert(__native_word(t) || sizeof(t) == sizeof(long long), \
| ^
include/linux/compiler_types.h:664:9: note: expanded from macro '__native_word'
664 | sizeof(t) == sizeof(int) || sizeof(t) == sizeof(long))
| ^
In file included from rust/helpers/helpers.c:80:
rust/helpers/net/device.c:36:9: error: invalid application of 'sizeof' to bit-field
include/asm-generic/rwonce.h:49:2: note: expanded from macro 'READ_ONCE'
49 | compiletime_assert_rwonce_type(x); \
| ^
include/asm-generic/rwonce.h:36:21: note: expanded from macro 'compiletime_assert_rwonce_type'
36 | compiletime_assert(__native_word(t) || sizeof(t) == sizeof(long long), \
| ^
include/linux/compiler_types.h:664:37: note: expanded from macro '__native_word'
664 | sizeof(t) == sizeof(int) || sizeof(t) == sizeof(long))
| ^
In file included from rust/helpers/helpers.c:80:
rust/helpers/net/device.c:36:9: error: invalid application of 'sizeof' to bit-field
include/asm-generic/rwonce.h:49:2: note: expanded from macro 'READ_ONCE'
49 | compiletime_assert_rwonce_type(x); \
| ^
include/asm-generic/rwonce.h:36:47: note: expanded from macro 'compiletime_assert_rwonce_type'
36 | compiletime_assert(__native_word(t) || sizeof(t) == sizeof(long long), \
| ^
In file included from rust/helpers/helpers.c:80:
rust/helpers/net/device.c:36:9: error: address of bit-field requested
36 | return READ_ONCE(dev->priv_flags) & IFF_802_1Q_VLAN;
| ^ ~~~~~~~~~~~~~~~
include/asm-generic/rwonce.h:50:2: note: expanded from macro 'READ_ONCE'
50 | __READ_ONCE(x); \
| ^ ~
include/asm-generic/rwonce.h:44:70: note: expanded from macro '__READ_ONCE'
44 | #define __READ_ONCE(x) (*(const volatile __unqual_scalar_typeof(x) *)&(x))
| ^ ~
clang diag: include/asm-generic/io.h:1209:55: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
1 warning and 6 errors generated.
make[3]: *** [rust/Makefile:729: rust/helpers/helpers.o] Error 1
clang diag: include/asm-generic/io.h:1209:55: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
include/asm-generic/io.h:1209:55: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
rust/helpers/net/device.c:36:9: error: invalid application of 'sizeof' to bit-field
rust/helpers/net/device.c:36:9: error: invalid application of 'sizeof' to bit-field
rust/helpers/net/device.c:36:9: error: invalid application of 'sizeof' to bit-field
rust/helpers/net/device.c:36:9: error: invalid application of 'sizeof' to bit-field
rust/helpers/net/device.c:36:9: error: invalid application of 'sizeof' to bit-field
rust/helpers/net/device.c:36:9: error: address of bit-field requested
clang diag: include/asm-generic/io.h:1209:55: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
>> Unable to generate bindings: clang diagnosed error: rust/helpers/net/device.c:36:9: error: invalid application of 'sizeof' to bit-field
rust/helpers/net/device.c:36:9: error: invalid application of 'sizeof' to bit-field
rust/helpers/net/device.c:36:9: error: invalid application of 'sizeof' to bit-field
rust/helpers/net/device.c:36:9: error: invalid application of 'sizeof' to bit-field
rust/helpers/net/device.c:36:9: error: invalid application of 'sizeof' to bit-field
rust/helpers/net/device.c:36:9: error: address of bit-field requested
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
reply other threads:[~2026-10-16 1:22 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=202610160917.DsbpZfde-lkp@intel.com \
--to=lkp@intel.com \
--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