Lines Matching refs:width
57 #define MAKE_MASK32(width) (width == 32 ? 0xffffffff : \ argument
58 (uint32_t)((1 << width) - 1))
60 static inline uint32_t e32_##t(uint32_t lsoffset, uint32_t width, t val) \
62 BUG_ON(width > (sizeof(t) * 8)); \
63 return ((uint32_t)val & MAKE_MASK32(width)) << lsoffset; \
65 static inline t d32_##t(uint32_t lsoffset, uint32_t width, uint32_t val) \
67 BUG_ON(width > (sizeof(t) * 8)); \
68 return (t)((val >> lsoffset) & MAKE_MASK32(width)); \
70 static inline uint32_t i32_##t(uint32_t lsoffset, uint32_t width, \
73 BUG_ON(width > (sizeof(t) * 8)); \
74 return e32_##t(lsoffset, width, d32_##t(lsoffset, width, val)); \
76 static inline uint32_t r32_##t(uint32_t lsoffset, uint32_t width, \
79 BUG_ON(width > (sizeof(t) * 8)); \
80 return ~(MAKE_MASK32(width) << lsoffset) & val; \