/* Shift the value and apply the specified mask.  */
uint32_t field_prep(uint32_t mask, uint32_t val)
/* Shift the value and apply the specified mask.  */
uint32_t field_prep(uint32_t mask, uint32_t val)
{
	return (val << find_first_set_bit(mask)) & mask;
}