Re: [ PATCH 1/2] xen: enable APIC-Register Virtualization

Jan Beulich
2012-08-31T12:14:39Z

>>> On 31.08.12 at 11:29, "Li, Jiongxi"
<jiongxi.li@intel.com> wrote:
> --- a/xen/arch/x86/hvm/vlapic.c      Fri Aug 24 12:38:18 2012 +0100
> +++ b/xen/arch/x86/hvm/vlapic.c   Thu Aug 30 22:38:26 2012 +0800
> @@ -823,6 +823,16 @@ static int vlapic_write(struct vcpu *v,
>      return rc;
> }
>
> +int vlapic_apicv_write(struct vcpu *v, unsigned int offset)
> +{
> +    uint32_t val = vlapic_get_reg(vcpu_vlapic(v), offset);
> +
> +    ASSERT(cpu_has_vmx_apic_reg_virt);

Given the function and the assertion are in a common file, both
should be named without using VMX specific terms (or moved
elsewhere).

Jan

> +
> +    vlapic_reg_write(v, offset, val);
> +    return 0;
> +}
> +