search for: virt_to_pag

Displaying 20 results from an estimated 202 matches for "virt_to_pag".

Did you mean: virt_to_page
2007 Apr 18
1
[PATCH 1/5] Add pagetable allocation notifiers
...g/arch/i386/mm/init.c 2005-08-24 09:31:05.000000000 -0700 +++ linux-2.6.13/arch/i386/mm/init.c 2005-08-24 09:31:31.000000000 -0700 @@ -79,6 +79,7 @@ static pte_t * __init one_page_table_ini { if (pmd_none(*pmd)) { pte_t *page_table = (pte_t *) alloc_bootmem_low_pages(PAGE_SIZE); + SetPagePTE(virt_to_page(page_table)); set_pmd(pmd, __pmd(__pa(page_table) | _PAGE_TABLE)); if (page_table != pte_offset_kernel(pmd, 0)) BUG(); Index: linux-2.6.13/arch/i386/mm/pageattr.c =================================================================== --- linux-2.6.13.orig/arch/i386/mm/pageattr.c 2005-08-24...
2007 Apr 18
1
[PATCH 1/5] Add pagetable allocation notifiers
...g/arch/i386/mm/init.c 2005-08-24 09:31:05.000000000 -0700 +++ linux-2.6.13/arch/i386/mm/init.c 2005-08-24 09:31:31.000000000 -0700 @@ -79,6 +79,7 @@ static pte_t * __init one_page_table_ini { if (pmd_none(*pmd)) { pte_t *page_table = (pte_t *) alloc_bootmem_low_pages(PAGE_SIZE); + SetPagePTE(virt_to_page(page_table)); set_pmd(pmd, __pmd(__pa(page_table) | _PAGE_TABLE)); if (page_table != pte_offset_kernel(pmd, 0)) BUG(); Index: linux-2.6.13/arch/i386/mm/pageattr.c =================================================================== --- linux-2.6.13.orig/arch/i386/mm/pageattr.c 2005-08-24...
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 in the Xen code. Would need to sort out the
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 in the Xen code. Would need to sort out the
2012 Oct 19
5
[PATCH v2 1/3] mm: highmem: export kmap_to_page for modules
...Will Deacon <will.deacon at arm.com> --- mm/highmem.c | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/mm/highmem.c b/mm/highmem.c index d517cd1..2a07f97 100644 --- a/mm/highmem.c +++ b/mm/highmem.c @@ -105,6 +105,7 @@ struct page *kmap_to_page(void *vaddr) return virt_to_page(addr); } +EXPORT_SYMBOL(kmap_to_page); static void flush_all_zero_pkmaps(void) { -- 1.7.4.1
2012 Oct 19
5
[PATCH v2 1/3] mm: highmem: export kmap_to_page for modules
...Will Deacon <will.deacon at arm.com> --- mm/highmem.c | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/mm/highmem.c b/mm/highmem.c index d517cd1..2a07f97 100644 --- a/mm/highmem.c +++ b/mm/highmem.c @@ -105,6 +105,7 @@ struct page *kmap_to_page(void *vaddr) return virt_to_page(addr); } +EXPORT_SYMBOL(kmap_to_page); static void flush_all_zero_pkmaps(void) { -- 1.7.4.1
2020 Sep 25
1
[PATCH 08/18] dma-mapping: add a new dma_alloc_noncoherent API
On 2020-09-15 16:51, Christoph Hellwig wrote: [...] > +These APIs allow to allocate pages in the kernel direct mapping that are > +guaranteed to be DMA addressable. This means that unlike dma_alloc_coherent, > +virt_to_page can be called on the resulting address, and the resulting Nit: if we explicitly describe this as if it's a guarantee that can be relied upon... > +struct page can be used for everything a struct page is suitable for. [...] > +This routine allocates a region of <size> bytes of c...
2010 Sep 14
2
[PATCH 1/4] x86: remove cast from void*
...changed, 1 insertions(+), 1 deletions(-) diff --git a/arch/x86/xen/mmu.c b/arch/x86/xen/mmu.c index 42086ac..7436283 100644 --- a/arch/x86/xen/mmu.c +++ b/arch/x86/xen/mmu.c @@ -737,7 +737,7 @@ pgd_t *xen_get_user_pgd(pgd_t *pgd) if (offset < pgd_index(USER_LIMIT)) { struct page *page = virt_to_page(pgd_page); - user_ptr = (pgd_t *)page->private; + user_ptr = page->private; if (user_ptr) user_ptr += offset; } -- 1.7.2.1
2010 Sep 14
2
[PATCH 1/4] x86: remove cast from void*
...changed, 1 insertions(+), 1 deletions(-) diff --git a/arch/x86/xen/mmu.c b/arch/x86/xen/mmu.c index 42086ac..7436283 100644 --- a/arch/x86/xen/mmu.c +++ b/arch/x86/xen/mmu.c @@ -737,7 +737,7 @@ pgd_t *xen_get_user_pgd(pgd_t *pgd) if (offset < pgd_index(USER_LIMIT)) { struct page *page = virt_to_page(pgd_page); - user_ptr = (pgd_t *)page->private; + user_ptr = page->private; if (user_ptr) user_ptr += offset; } -- 1.7.2.1
2010 Sep 14
2
[PATCH 1/4] x86: remove cast from void*
...changed, 1 insertions(+), 1 deletions(-) diff --git a/arch/x86/xen/mmu.c b/arch/x86/xen/mmu.c index 42086ac..7436283 100644 --- a/arch/x86/xen/mmu.c +++ b/arch/x86/xen/mmu.c @@ -737,7 +737,7 @@ pgd_t *xen_get_user_pgd(pgd_t *pgd) if (offset < pgd_index(USER_LIMIT)) { struct page *page = virt_to_page(pgd_page); - user_ptr = (pgd_t *)page->private; + user_ptr = page->private; if (user_ptr) user_ptr += offset; } -- 1.7.2.1
2007 Jun 11
5
[PATCH][Linux] gnttab: make dma address conversion logic of gnttab dma arch specific.
...B_DMA_H + +int gnttab_dma_local_pfn(struct page *page); + +static inline maddr_t gnttab_dma_map_page(struct page *page) +{ + __gnttab_dma_map_page(page, &gnttab_dma_local_pfn); + return page_to_bus(page); +} + +static inline void gnttab_dma_unmap_page(maddr_t maddr) +{ + __gnttab_dma_unmap_page(virt_to_page(bus_to_virt(maddr))); +} + +#endif /* _ASM_I386_GNTTAB_DMA_H */ diff -r d5e0eb7dd069 -r 69e2dd4e06c4 include/asm-ia64/gnttab_dma.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/include/asm-ia64/gnttab_dma.h Mon Jun 11 16:13:06 2007 +0900 @@ -0,0 +1,46 @@ +/* + * Copyright (c) 2007 Herbert Xu...
2012 Mar 15
3
[PATCH] arm: allocate top level p2m page for all non-idle VCPUs
.../domain.c b/xen/arch/arm/domain.c index 5702399..4b38790 100644 --- a/xen/arch/arm/domain.c +++ b/xen/arch/arm/domain.c @@ -201,6 +201,9 @@ int arch_domain_create(struct domain *d, unsigned int domcr_flags) clear_page(d->shared_info); share_xen_page_with_guest( virt_to_page(d->shared_info), d, XENSHARE_writable); + + if ( (rc = p2m_alloc_table(d)) != 0 ) + goto fail; } d->max_vcpus = 8; diff --git a/xen/arch/arm/domain_build.c b/xen/arch/arm/domain_build.c index 15632f7..6687e50 100644 --- a/xen/arch/arm/domain_build.c +++ b/xen/ar...
2007 Oct 12
10
[PATCH 00/10] REVIEW: Xen patches for 2.6.24
This is my current set of updates to Xen for 2.6.24. This is largely a bugfix set, and a couple of them are also relevent to 2.6.23. These are in the pre-x86 merge form; I'll update them once the merge goes into git. Quick overview: - remove some dead code in arch/i386/mm/init.c - clean up some duplicate includes - when sending an IPI, yield the vcpu if the destination doesn't have
2007 Oct 12
10
[PATCH 00/10] REVIEW: Xen patches for 2.6.24
This is my current set of updates to Xen for 2.6.24. This is largely a bugfix set, and a couple of them are also relevent to 2.6.23. These are in the pre-x86 merge form; I'll update them once the merge goes into git. Quick overview: - remove some dead code in arch/i386/mm/init.c - clean up some duplicate includes - when sending an IPI, yield the vcpu if the destination doesn't have
2007 Oct 12
10
[PATCH 00/10] REVIEW: Xen patches for 2.6.24
This is my current set of updates to Xen for 2.6.24. This is largely a bugfix set, and a couple of them are also relevent to 2.6.23. These are in the pre-x86 merge form; I'll update them once the merge goes into git. Quick overview: - remove some dead code in arch/i386/mm/init.c - clean up some duplicate includes - when sending an IPI, yield the vcpu if the destination doesn't have
2007 Jun 07
4
[PATCH RFC 0/3] Virtio draft II
Hi again all, It turns out that networking really wants ordered requests, which the previous patches didn't allow. This patch changes it to a callback mechanism; kudos to Avi. The downside is that locking is more complicated, and after a few dead ends I implemented the simplest solution: the struct virtio_device contains the spinlock to use, and it's held when your callbacks get
2007 Jun 07
4
[PATCH RFC 0/3] Virtio draft II
Hi again all, It turns out that networking really wants ordered requests, which the previous patches didn't allow. This patch changes it to a callback mechanism; kudos to Avi. The downside is that locking is more complicated, and after a few dead ends I implemented the simplest solution: the struct virtio_device contains the spinlock to use, and it's held when your callbacks get
2007 Jun 07
4
[PATCH RFC 0/3] Virtio draft II
Hi again all, It turns out that networking really wants ordered requests, which the previous patches didn't allow. This patch changes it to a callback mechanism; kudos to Avi. The downside is that locking is more complicated, and after a few dead ends I implemented the simplest solution: the struct virtio_device contains the spinlock to use, and it's held when your callbacks get
2009 Sep 21
0
[PATCH 4/5] lguest: cleanup for map_switcher()
From: Xiao Guangrong <xiaoguangrong at cn.fujitsu.com> We can use alloc_page() instead of get_zeroed_page() and virt_to_page() Signed-off-by: Xiao Guangrong <xiaoguangrong at cn.fujitsu.com> Signed-off-by: Rusty Russell <rusty at rustcorp.com.au> --- drivers/lguest/core.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/drivers/lguest/core.c b/drivers/lguest/core.c index 1e2cb84....
2009 Sep 21
0
[PATCH 4/5] lguest: cleanup for map_switcher()
From: Xiao Guangrong <xiaoguangrong at cn.fujitsu.com> We can use alloc_page() instead of get_zeroed_page() and virt_to_page() Signed-off-by: Xiao Guangrong <xiaoguangrong at cn.fujitsu.com> Signed-off-by: Rusty Russell <rusty at rustcorp.com.au> --- drivers/lguest/core.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/drivers/lguest/core.c b/drivers/lguest/core.c index 1e2cb84....