[PATCH 1/2] linux/bitfield.h: import FIELD_PREP_CONST macro from Linux Kernel

Quentin Schulz quentin.schulz at cherry.de
Tue Jun 3 17:08:13 CEST 2025


Hi Christian,

On 6/3/25 10:51 AM, Christian Marangi wrote:
> Import FIELD_PREP_CONST macro from Linux Kernel to permit usage of
> FIELD_PREP with scenario where a constant value is needed.
> 
> Refer to commit e2192de59e45 ("bitfield: add FIELD_PREP_CONST()") in
> Linux kernel for extensive explaination of why this is useful.
> 
> This is also to better align with the Linux Kernel for easier porting of
> driver.
> 

Do you know it it'd be possible to simply copy Linux kernel's bitfield.h 
instead of "cherry-picking" individual commit(s)?

Cheers,
Quentin


More information about the U-Boot mailing list