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

Re: [Xen-devel] [PATCH] x86/PV: properly populate descriptor tables



>>> On 26.10.15 at 16:41, <david.vrabel@xxxxxxxxxx> wrote:
> Apply this partial revert fixes the problem for me.

This would need some cleaning up, but I could do that. May I put your
S-o-b underneath it (with or without the extra cleanup)?

Jan

> --- a/xen/arch/x86/mm.c
> +++ b/xen/arch/x86/mm.c
> @@ -502,8 +502,8 @@ void update_cr3(struct vcpu *v)
>  static void invalidate_shadow_ldt(struct vcpu *v, int flush)
>  {
>      l1_pgentry_t *pl1e;
> -    unsigned int i;
> -    unsigned long pfn, zero_pfn = PFN_DOWN(__pa(zero_page));
> +    int i;
> +    unsigned long pfn;
>      struct page_info *page;
>  
>      BUG_ON(unlikely(in_irq()));
> @@ -524,9 +523,8 @@ static void invalidate_shadow_ldt(struct vcpu *v, int 
> flush)
>      for ( i = 16; i < 32; i++ )
>      {
>          pfn = l1e_get_pfn(pl1e[i]);
> -        if ( !(l1e_get_flags(pl1e[i]) & _PAGE_PRESENT) || pfn == zero_pfn )
> -            continue;
> -        l1e_write(&pl1e[i], l1e_from_pfn(zero_pfn, __PAGE_HYPERVISOR_RO));
> +        if ( pfn == 0 ) continue;
> +        l1e_write(&pl1e[i], l1e_empty());
>          page = mfn_to_page(pfn);
>          ASSERT_PAGE_IS_TYPE(page, PGT_seg_desc_page);
>          ASSERT_PAGE_IS_DOMAIN(page, v->domain);




_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel


 


Rackspace

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