[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] [PATCH v3 4/5] x86/sysctl: Implement XEN_SYSCTL_get_cpu_policy



>>> On 05.11.18 at 12:16, <andrew.cooper3@xxxxxxxxxx> wrote:
> --- a/xen/include/public/sysctl.h
> +++ b/xen/include/public/sysctl.h
> @@ -1075,12 +1075,25 @@ struct xen_sysctl_set_parameter {
>   *  - Default_*: Default set of features a PV or HVM guest can use.  This is
>   *               the security supported set.
>   */
> +struct xen_sysctl_cpu_policy {
>  #define XEN_SYSCTL_cpu_policy_raw          0
>  #define XEN_SYSCTL_cpu_policy_host         1
>  #define XEN_SYSCTL_cpu_policy_pv_max       2
>  #define XEN_SYSCTL_cpu_policy_hvm_max      3
>  #define XEN_SYSCTL_cpu_policy_pv_default   4
>  #define XEN_SYSCTL_cpu_policy_hvm_default  5
> +    uint32_t index;       /* IN: Which policy to query? */
> +    uint32_t nr_leaves;   /* IN/OUT: Number of leaves in/written to
> +                           * 'cpuid_policy', or the maximum number of leaves
> +                           * if the guest handle is NULL. */
> +    uint32_t nr_msrs;     /* IN/OUT: Number of MSRs in/written to
> +                           * 'msr_policy', or the maximum number of MSRs if
> +                           * the guest handle is NULL. */
> +    XEN_GUEST_HANDLE_64(xen_cpuid_leaf_t) cpuid_policy; /* OUT */

I'm sorry for being picky, but I (continue to) think there should be
explicit padding added above here, checked to be zero on input.
With this hypervisor parts
Reviewed-by: Jan Beulich <jbeulich@xxxxxxxx>

Jan



_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/mailman/listinfo/xen-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.