On Wed, Apr 18, 2018 at 04:38:22PM +0000, Meenakshi Aggarwal wrote: > > > + > > > +/* > > > + * Returns the bit mask for a bit index from 0 to 31 > > > + */ > > > +#define BIT(_BitIndex) (0x1u << (_BitIndex)) > > > > I don't see these being used for anything other than setting up BIT1 > > BIT2 BIT3 and so on. We already have those in Base.h. > > > In Base.h, we have BIT1, BIT2 defined, here the requirement is to > get set bit on basis of bit number, bit is not known in advance.
Ah, I missed the uses in SerDes.c and saw only the ones in UsbHcd.h (which could use the Base.h defines). But does it really simplify anything in SerDes.c? *SerDesPrtclMap |= BIT (LanePrtcl); is no clearer to me than *SerDesPrtclMap |= (1u << LanePrtcl); Best Regards, Leif _______________________________________________ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel