[PATCH] rust: bug: fix `dead_code` warning in `warn_on!`

FUJITA Tomonori tomo at flapping.org
Sat Aug 8 17:50:41 PDT 2026


On Sat, 8 Aug 2026 21:40:49 +0200
Miguel Ojeda <miguel.ojeda.sandonis at gmail.com> wrote:

>> I posted a `cfg(testlib)` split for it:
>>
>> https://lore.kernel.org/all/20260808022608.1125174-1-tomo@flapping.org/
> 
> Thanks! It seems good to me.

Thanks!

>> While at it, a question: what is `rusttest` meant to cover when
>> `ARCH=` is not the host's?
> 
> `rusttest` is meant to run tests on the host, regardless of the target.

Then `jump_label.rs` needs the same treatment?

`arch_static_branch!` embeds the generated arch asm too. It is not a
problem today only because, like `warn_on!` until now, it has no user
inside the `kernel` crate itself.




More information about the linux-arm-kernel mailing list