Re: [PATCH v2 3/3] serial: sc16is7xx: convert bitmask definitions to use BIT macro

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, 12 Aug 2024, Andy Shevchenko wrote:

> On Mon, Aug 12, 2024 at 06:56:53PM +0200, Lech Perczak wrote:
> > Now that bit definition comments were cleaned up, convert bitmask
> > definitions to use BIT macro for clarity.
> 
> In the Subject and here: BIT()
> 
> ...
> 
> >  #define SC16IS7XX_IIR_ID_MASK		0x3e     /* Mask for the interrupt ID */
> 
> While at it, why not convert the MASK(s) to use GENMASK()?
> It's logically coupled change, no need to have a separate patch.
> 
> ...
> 
> >  #define SC16IS7XX_LSR_BRK_ERROR_MASK	0x1E     /* BI, FE, PE, OE bits */
> 
> Ditto.

No. This is not GENMASK() but combination of other bits. This mask define 
should be a combination those bit defines and the comment dropped because 
it adds no value after using the bit defines directly.

> (maybe more that are not visible in the context of this patch)


-- 
 i.





[Index of Archives]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Linux PPP]     [Linux FS]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Linmodem]     [Device Mapper]     [Linux Kernel for ARM]

  Powered by Linux