Quoting Jani Nikula (2018-11-15 14:01:26)
> Clean up fixed point temp variable initialization, use the more
> conventional tmp name for temp variables, add empty lines before
> return. No functional changes.
> 
> Signed-off-by: Jani Nikula <jani.nik...@intel.com>

<SNIP>

>  static inline uint_fixed_16_16_t clamp_u64_to_fixed16(u64 val)
>  {
> -       uint_fixed_16_16_t fp;
> +       uint_fixed_16_16_t fp = { .val = (u32)val };

Also a possibility:

        .val = lower_32_bits(val)
        WARN_ON(upper_32_bits(val))

But your style might be more uniform across other funcs.

> +
>         WARN_ON(val > U32_MAX);
> -       fp.val = (u32)val;

Reviewed-by: Joonas Lahtinen <joonas.lahti...@linux.intel.com>

Regards, Joonas
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

Reply via email to