On Wed, 1 Jul 2026 at 14:03, Magnus Kulke
<[email protected]> wrote:
>
> Processor features are stored in a union containing two "banks":
>
> union hv_partition_processor_features {
>     uint64_t as_uint[2];
>     struct {
>         uint64_t sse3_support:1;
>         ...
>     }
> }
>
> get_proc_features() to retrieve the 2nd bank was passing a pointer that
> steps over the whole union (+16B) instead of picking the 2nd bank _in_
> the union. This manifests in mismatching feature bits for the 2nd bank
> and possibly other side-effects caused by writing beyond the union.
>
> We need to step over the first bank (+8B) by using as_uint64[0/1] to
> correct this behaviour.
>
> Fixes: 2f6da91e8a ("accel/mshv: store partition proc features")
> Signed-off-by: Magnus Kulke <[email protected]>

Reviewed-by: Peter Maydell <[email protected]>

thanks
-- PMM

Reply via email to