[PATCH] riscv: ptrace: avoid BIT() in UAPI header

Andreas Schwab schwab at suse.de
Mon Mar 30 01:16:09 PDT 2026


On Mär 30 2026, Michael Neuling wrote:

> BIT() is not available in UAPI headers — the installed linux/bits.h
> (UAPI version) does not define it. Replace BIT() with open-coded
> (1UL << x) which is the standard practice for UAPI headers, and drop
> the linux/bits.h include that was added by commit 98545620b0 ("riscv:
> ptrace: Fix BIT() compilation issues").

There is also the _BITUL macro, which may be preferable.

-- 
Andreas Schwab, SUSE Labs, schwab at suse.de
GPG Key fingerprint = 0196 BAD8 1CE9 1970 F4BE  1748 E4D4 88E3 0EEA B9D7
"And now for something completely different."



More information about the linux-riscv mailing list