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

Christian Marangi ansuelsmth at gmail.com
Tue Jun 3 22:37:22 CEST 2025


On Tue, Jun 03, 2025 at 05:08:13PM +0200, Quentin Schulz wrote:
> 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)?
> 

Mhhh what do you mean? You mean syncing the full header with latest
version?

Isn't that more risky??

-- 
	Ansuel


More information about the U-Boot mailing list