search for: pgd

Displaying 20 results from an estimated 670 matches for "pgd".

Did you mean: gd
2007 Dec 27
2
VT-d and the GPU
...xm create to the assert. BTW: I have noted the missing bios call when posting the the new vgabios and if any one knows the details surrounding int15h AX=5F21, I would also appreciate that as well, I know it has something to do with the GPU clock rate. (XEN) intel-iommu.c:1965:d0 iommu_set_pgd: hd->pgd = ff25f000 (XEN) intel-iommu.c:1843: assign_device: bus = 0 dev = 2 func = 0 (XEN) intel-iommu.c:1371:d0 reassign_device-0:2:0- source = 0 target = 1 (XEN) dmar.c:110:d0 acpi_find_matched_drhd_unit: drhd->address = feb01000 (XEN) intel-iommu.c:1312:d0 domain_context_un...
2007 Apr 18
1
[PATCH 1/5] Add pagetable allocation notifiers
...; } Index: linux-2.6.13/arch/i386/mm/pgtable.c =================================================================== --- linux-2.6.13.orig/arch/i386/mm/pgtable.c 2005-08-24 09:31:05.000000000 -0700 +++ linux-2.6.13/arch/i386/mm/pgtable.c 2005-08-24 09:40:22.000000000 -0700 @@ -209,6 +209,7 @@ void pgd_ctor(void *pgd, kmem_cache_t *c if (PTRS_PER_PMD == 1) { memset(pgd, 0, USER_PTRS_PER_PGD*sizeof(pgd_t)); + SetPagePDE(virt_to_page(pgd)); spin_lock_irqsave(&pgd_lock, flags); } @@ -227,6 +228,7 @@ void pgd_dtor(void *pgd, kmem_cache_t *c { unsigned long flags; /* can be calle...
2007 Apr 18
1
[PATCH 1/5] Add pagetable allocation notifiers
...; } Index: linux-2.6.13/arch/i386/mm/pgtable.c =================================================================== --- linux-2.6.13.orig/arch/i386/mm/pgtable.c 2005-08-24 09:31:05.000000000 -0700 +++ linux-2.6.13/arch/i386/mm/pgtable.c 2005-08-24 09:40:22.000000000 -0700 @@ -209,6 +209,7 @@ void pgd_ctor(void *pgd, kmem_cache_t *c if (PTRS_PER_PMD == 1) { memset(pgd, 0, USER_PTRS_PER_PGD*sizeof(pgd_t)); + SetPagePDE(virt_to_page(pgd)); spin_lock_irqsave(&pgd_lock, flags); } @@ -227,6 +228,7 @@ void pgd_dtor(void *pgd, kmem_cache_t *c { unsigned long flags; /* can be calle...
2014 Feb 04
1
[RFC 07/16] drm/nouveau/bar/nvc0: support chips without BAR3
...> + &priv->bar[nr].mem); > + mem = priv->bar[nr].mem; > if (ret) > return ret; > > ret = nouveau_gpuobj_new(nv_object(priv), NULL, 0x8000, 0, 0, > - &priv->bar[0].pgd); > + &priv->bar[nr].pgd); > if (ret) > return ret; > > - ret = nouveau_vm_new(device, 0, nv_device_resource_len(device, 3), 0, &vm); > + bar_len = nv_device_resource_len(device, bar); > + > +...
2007 Apr 18
2
pgd_alloc and [cd]tors
Is there any real use in having a ctor/dtor for the pgd cache? Given that all pgd allocation happens via pgd_alloc/pgd_free, why not just fold the [cd]tor in? I'm asking because Xen wants pgd[3] to be unshared in the PAE case, and it looks to me like the easiest way to handle that is by making pgd_alloc/free pv-ops and doing the appropriate thing...
2007 Apr 18
2
pgd_alloc and [cd]tors
Is there any real use in having a ctor/dtor for the pgd cache? Given that all pgd allocation happens via pgd_alloc/pgd_free, why not just fold the [cd]tor in? I'm asking because Xen wants pgd[3] to be unshared in the PAE case, and it looks to me like the easiest way to handle that is by making pgd_alloc/free pv-ops and doing the appropriate thing...
2007 Apr 18
0
[PATCH 1/5] Paravirt page alloc.patch
The VMI backend uses explicit page type notification to track shadow page tables. The allocation of page table roots is especially tricky. We want to clone the root for non-PAE mode while it is protected under the pgd lock. Signed-off-by: Zachary Amsden <zach@vmware.com> =================================================================== --- a/arch/i386/kernel/paravirt.c +++ b/arch/i386/kernel/paravirt.c @@ -545,6 +545,12 @@ struct paravirt_ops paravirt_ops = { .flush_tlb_kernel = native_flush_tlb_glob...
2007 Apr 18
0
[PATCH 1/5] Paravirt page alloc.patch
The VMI backend uses explicit page type notification to track shadow page tables. The allocation of page table roots is especially tricky. We want to clone the root for non-PAE mode while it is protected under the pgd lock. Signed-off-by: Zachary Amsden <zach@vmware.com> =================================================================== --- a/arch/i386/kernel/paravirt.c +++ b/arch/i386/kernel/paravirt.c @@ -545,6 +545,12 @@ struct paravirt_ops paravirt_ops = { .flush_tlb_kernel = native_flush_tlb_glob...
2007 Apr 18
0
[PATCH 1/6] Page allocation hooks for VMI backend
The VMI backend uses explicit page type notification to track shadow page tables. The allocation of page table roots is especially tricky. We need to clone the root for non-PAE mode while it is protected under the pgd lock to correctly copy the shadow. We don't need to allocate pgds in PAE mode, (PDPs in Intel terminology) as they only have 4 entries, and are cached entirely by the processor, which makes shadowing them rather simple. For base page table level allocation, pmd_populate provides the exact hoo...
2007 Apr 18
0
[PATCH 1/6] Page allocation hooks for VMI backend
The VMI backend uses explicit page type notification to track shadow page tables. The allocation of page table roots is especially tricky. We need to clone the root for non-PAE mode while it is protected under the pgd lock to correctly copy the shadow. We don't need to allocate pgds in PAE mode, (PDPs in Intel terminology) as they only have 4 entries, and are cached entirely by the processor, which makes shadowing them rather simple. For base page table level allocation, pmd_populate provides the exact hoo...
2007 Apr 18
1
[PATCH 4/10] I386 pgd clone under lock fix.patch
Copying of the pgd range must happen under the pgd_lock. This got broken by the paravirt changes in the -mm tree. Badness can result if you copy the pgd before being added to the list when splitting or rejoining large pages. Signed-off-by: Zachary Amsden <zach@vmware.com> diff -r 2247ff2c3fdb arch/i386/mm/p...
2007 Apr 18
1
[PATCH 4/10] I386 pgd clone under lock fix.patch
Copying of the pgd range must happen under the pgd_lock. This got broken by the paravirt changes in the -mm tree. Badness can result if you copy the pgd before being added to the list when splitting or rejoining large pages. Signed-off-by: Zachary Amsden <zach@vmware.com> diff -r 2247ff2c3fdb arch/i386/mm/p...
2007 Apr 18
0
[PATCH 2/2] Use page present for pae pdpes
...notifiers Index: linux-2.6.13/arch/i386/mm/pgtable.c =================================================================== --- linux-2.6.13.orig/arch/i386/mm/pgtable.c 2005-08-31 14:48:17.000000000 -0700 +++ linux-2.6.13/arch/i386/mm/pgtable.c 2005-08-31 14:48:53.000000000 -0700 @@ -247,14 +247,14 @@ pgd_t *pgd_alloc(struct mm_struct *mm) if (!pmd) goto out_oom; SetPagePDE(virt_to_page(pmd)); - set_pgd(&pgd[i], __pgd(1 + __pa(pmd))); + set_pgd(&pgd[i], __pgd(_PAGE_PRESENT | __pa(pmd))); } return pgd; out_oom: for (i--; i >= 0; i--) { ClearPagePDE(pfn_to_page(pgd_v...
2007 Apr 18
0
[PATCH 2/2] Use page present for pae pdpes
...notifiers Index: linux-2.6.13/arch/i386/mm/pgtable.c =================================================================== --- linux-2.6.13.orig/arch/i386/mm/pgtable.c 2005-08-31 14:48:17.000000000 -0700 +++ linux-2.6.13/arch/i386/mm/pgtable.c 2005-08-31 14:48:53.000000000 -0700 @@ -247,14 +247,14 @@ pgd_t *pgd_alloc(struct mm_struct *mm) if (!pmd) goto out_oom; SetPagePDE(virt_to_page(pmd)); - set_pgd(&pgd[i], __pgd(1 + __pa(pmd))); + set_pgd(&pgd[i], __pgd(_PAGE_PRESENT | __pa(pmd))); } return pgd; out_oom: for (i--; i >= 0; i--) { ClearPagePDE(pfn_to_page(pgd_v...
2014 Feb 01
0
[RFC 07/16] drm/nouveau/bar/nvc0: support chips without BAR3
...= nouveau_gpuobj_new(nv_object(priv), NULL, 0x1000, 0, 0, - &priv->bar[0].mem); - mem = priv->bar[0].mem; + &priv->bar[nr].mem); + mem = priv->bar[nr].mem; if (ret) return ret; ret = nouveau_gpuobj_new(nv_object(priv), NULL, 0x8000, 0, 0, - &priv->bar[0].pgd); + &priv->bar[nr].pgd); if (ret) return ret; - ret = nouveau_vm_new(device, 0, nv_device_resource_len(device, 3), 0, &vm); + bar_len = nv_device_resource_len(device, bar); + + ret = nouveau_vm_new(device, 0, bar_len, 0, &vm); if (ret) return ret; atomic_inc(&v...
2007 Apr 18
0
[RFC/PATCH PV_OPS X86_64 08/17] paravirt_ops - memory managment
...fault.c =================================================================== --- clean-start.orig/arch/x86_64/mm/fault.c +++ clean-start/arch/x86_64/mm/fault.c @@ -180,7 +180,7 @@ void dump_pagetable(unsigned long addres pmd_t *pmd; pte_t *pte; - asm("movq %%cr3,%0" : "=r" (pgd)); + pgd = (pgd_t *)read_cr3(); pgd = __va((unsigned long)pgd & PHYSICAL_PAGE_MASK); pgd += pgd_index(address); @@ -347,7 +347,7 @@ asmlinkage void __kprobes do_page_fault( prefetchw(&mm->mmap_sem); /* get the address */ - __asm__("movq %%cr2,%0":"=r" (ad...
2007 Apr 18
0
[RFC/PATCH PV_OPS X86_64 08/17] paravirt_ops - memory managment
...fault.c =================================================================== --- clean-start.orig/arch/x86_64/mm/fault.c +++ clean-start/arch/x86_64/mm/fault.c @@ -180,7 +180,7 @@ void dump_pagetable(unsigned long addres pmd_t *pmd; pte_t *pte; - asm("movq %%cr3,%0" : "=r" (pgd)); + pgd = (pgd_t *)read_cr3(); pgd = __va((unsigned long)pgd & PHYSICAL_PAGE_MASK); pgd += pgd_index(address); @@ -347,7 +347,7 @@ asmlinkage void __kprobes do_page_fault( prefetchw(&mm->mmap_sem); /* get the address */ - __asm__("movq %%cr2,%0":"=r" (ad...
2009 Sep 24
0
[Lguest] [PATCH 3/5] lguest: use PGDIR_SHIFT for PAE code to allow different PAGE_OFFSET
...hanged, 2 insertions(+), 4 deletions(-) > > diff --git a/drivers/lguest/page_tables.c b/drivers/lguest/page_tables.c > --- a/drivers/lguest/page_tables.c > +++ b/drivers/lguest/page_tables.c > @@ -996,11 +996,9 @@ static unsigned long setup_pagetables(st > if (copy_to_user(&pgdir[0], &pgd, sizeof(pgd)) != 0) > return -EFAULT; > /* > - * And the third PGD entry (ie. addresses 3G-4G). > - * > - * FIXME: This assumes that PAGE_OFFSET for the Guest is 0xC0000000. > + * And the other PGD entry to make the linear mapping at PAGE_OFFSET > */...
2009 Sep 24
0
[Lguest] [PATCH 3/5] lguest: use PGDIR_SHIFT for PAE code to allow different PAGE_OFFSET
...hanged, 2 insertions(+), 4 deletions(-) > > diff --git a/drivers/lguest/page_tables.c b/drivers/lguest/page_tables.c > --- a/drivers/lguest/page_tables.c > +++ b/drivers/lguest/page_tables.c > @@ -996,11 +996,9 @@ static unsigned long setup_pagetables(st > if (copy_to_user(&pgdir[0], &pgd, sizeof(pgd)) != 0) > return -EFAULT; > /* > - * And the third PGD entry (ie. addresses 3G-4G). > - * > - * FIXME: This assumes that PAGE_OFFSET for the Guest is 0xC0000000. > + * And the other PGD entry to make the linear mapping at PAGE_OFFSET > */...
2014 Mar 24
0
[PATCH 04/12] drm/nouveau/bar/nvc0: support chips without BAR3
...= nouveau_gpuobj_new(nv_object(priv), NULL, 0x1000, 0, 0, - &priv->bar[0].mem); - mem = priv->bar[0].mem; + &priv->bar[nr].mem); + mem = priv->bar[nr].mem; if (ret) return ret; ret = nouveau_gpuobj_new(nv_object(priv), NULL, 0x8000, 0, 0, - &priv->bar[0].pgd); + &priv->bar[nr].pgd); if (ret) return ret; - ret = nouveau_vm_new(device, 0, nv_device_resource_len(device, 3), 0, &vm); + bar_len = nv_device_resource_len(device, bar); + + ret = nouveau_vm_new(device, 0, bar_len, 0, &vm); if (ret) return ret; atomic_inc(&v...