On 11.11.2025 21:10, Grygorii Strashko wrote:
> From: Grygorii Strashko <[email protected]>
> 
> Functions:
>  hvm_shadow_handle_cd()
>  hvm_set_uc_mode()
>  domain_exit_uc_mode()
> are used only by Intel VMX code, so move them to VMX code.
> 
> While here:
> - minor format change in domain_exit_uc_mode()
> - s/(0/1)/(false/true) for bool types
> - use "struct domain *" as parameter in hvm_set_uc_mode()
> - use "struct domain *d" as local var in hvm_shadow_handle_cd()

One more please:

> @@ -1451,6 +1452,66 @@ static int cf_check vmx_get_guest_pat(struct vcpu *v, 
> u64 *gpat)
>      return 1;
>  }
>  
> +/* Exit UC mode only if all VCPUs agree on MTRR/PAT and are not in no_fill. 
> */
> +static bool domain_exit_uc_mode(struct vcpu *v)
> +{
> +    struct domain *d = v->domain;
> +    struct vcpu *vs;

const on all three pointer target types. Then, together with the function
prefix adjustment discussed on the other sub-thread,
Acked-by: Jan Beulich <[email protected]>

Jan

Reply via email to