Displaying 20 results from an estimated 142 matches for "vm_fault_t".
2018 Apr 23
3
[PATCH] gpu: drm: qxl: Adding new typedef vm_fault_t
On Tue, Apr 17, 2018 at 07:08:44PM +0530, Souptick Joarder wrote:
> Use new return type vm_fault_t for fault handler. For
> now, this is just documenting that the function returns
> a VM_FAULT value rather than an errno. Once all instances
> are converted, vm_fault_t will become a distinct type.
>
> Reference id -> 1c8f422059ae ("mm: change return type to
> vm_fault_t&...
2018 Apr 23
3
[PATCH] gpu: drm: qxl: Adding new typedef vm_fault_t
On Tue, Apr 17, 2018 at 07:08:44PM +0530, Souptick Joarder wrote:
> Use new return type vm_fault_t for fault handler. For
> now, this is just documenting that the function returns
> a VM_FAULT value rather than an errno. Once all instances
> are converted, vm_fault_t will become a distinct type.
>
> Reference id -> 1c8f422059ae ("mm: change return type to
> vm_fault_t&...
2024 Jan 22
2
[PATCH] mm: Remove double faults once write a device pfn
...+++++++++---
> 10 files changed, 30 insertions(+), 16 deletions(-)
>
> diff --git a/arch/x86/entry/vdso/vma.c b/arch/x86/entry/vdso/vma.c
> index 7645730dc228..dd2431c2975f 100644
> --- a/arch/x86/entry/vdso/vma.c
> +++ b/arch/x86/entry/vdso/vma.c
> @@ -185,7 +185,8 @@ static vm_fault_t vvar_fault(const struct vm_special_mapping *sm,
> if (pvti && vclock_was_used(VDSO_CLOCKMODE_PVCLOCK)) {
> return vmf_insert_pfn_prot(vma, vmf->address,
> __pa(pvti) >> PAGE_SHIFT,
> - pgprot_decrypted(vma->vm_page_prot));
> + pgprot_decryp...
2024 Jan 24
1
[PATCH] mm: Remove double faults once write a device pfn
...x86/entry/vdso/vma.c b/arch/x86/entry/vdso/vma.c
>> >>>>> index 7645730dc228..dd2431c2975f 100644
>> >>>>> --- a/arch/x86/entry/vdso/vma.c
>> >>>>> +++ b/arch/x86/entry/vdso/vma.c
>> >>>>> @@ -185,7 +185,8 @@ static vm_fault_t vvar_fault(const struct
>> >>>> vm_special_mapping *sm,
>> >>>>> if (pvti && vclock_was_used(VDSO_CLOCKMODE_PVCLOCK))
>> >>>> {
>> >>>>> return vmf_insert_pfn_prot(vma, vmf->...
2024 Jan 23
2
[PATCH] mm: Remove double faults once write a device pfn
...ons(+), 16 deletions(-)
>>>
>>> diff --git a/arch/x86/entry/vdso/vma.c b/arch/x86/entry/vdso/vma.c
>>> index 7645730dc228..dd2431c2975f 100644
>>> --- a/arch/x86/entry/vdso/vma.c
>>> +++ b/arch/x86/entry/vdso/vma.c
>>> @@ -185,7 +185,8 @@ static vm_fault_t vvar_fault(const struct
>> vm_special_mapping *sm,
>>> if (pvti && vclock_was_used(VDSO_CLOCKMODE_PVCLOCK))
>> {
>>> return vmf_insert_pfn_prot(vma, vmf->address,
>>> __pa(pvti)...
2024 Jan 24
2
[PATCH] mm: Remove double faults once write a device pfn
...;>>>> diff --git a/arch/x86/entry/vdso/vma.c b/arch/x86/entry/vdso/vma.c
>>>>> index 7645730dc228..dd2431c2975f 100644
>>>>> --- a/arch/x86/entry/vdso/vma.c
>>>>> +++ b/arch/x86/entry/vdso/vma.c
>>>>> @@ -185,7 +185,8 @@ static vm_fault_t vvar_fault(const struct
>>>> vm_special_mapping *sm,
>>>>> if (pvti && vclock_was_used(VDSO_CLOCKMODE_PVCLOCK))
>>>> {
>>>>> return vmf_insert_pfn_prot(vma, vmf->address,
>>>>>...
2018 Apr 24
0
[PATCH] gpu: drm: qxl: Adding new typedef vm_fault_t
On Mon, Apr 23, 2018 at 12:49:24PM +0200, Gerd Hoffmann wrote:
> On Tue, Apr 17, 2018 at 07:08:44PM +0530, Souptick Joarder wrote:
> > Use new return type vm_fault_t for fault handler. For
> > now, this is just documenting that the function returns
> > a VM_FAULT value rather than an errno. Once all instances
> > are converted, vm_fault_t will become a distinct type.
> >
> > Reference id -> 1c8f422059ae ("mm: change return...
2019 Jun 13
0
[PATCH 10/22] memremap: add a migrate callback to struct dev_pagemap_ops
.../include/linux/hmm.h b/include/linux/hmm.h
index 5761a39221a6..3c9a59dbfdb8 100644
--- a/include/linux/hmm.h
+++ b/include/linux/hmm.h
@@ -658,11 +658,6 @@ struct hmm_devmem_ops {
* chunk, as an optimization. It must, however, prioritize the faulting address
* over all the others.
*/
-typedef vm_fault_t (*dev_page_fault_t)(struct vm_area_struct *vma,
- unsigned long addr,
- const struct page *page,
- unsigned int flags,
- pmd_t *pmdp);
struct hmm_devmem {
struct completion completion;
@@ -673,7 +668,6 @@ struct hmm_devmem {
struct dev_pagemap pagemap;
const struct hmm_devmem...
2019 Jun 26
0
[PATCH 12/25] memremap: add a migrate_to_ram method to struct dev_pagemap_ops
.../include/linux/hmm.h b/include/linux/hmm.h
index 44a5ac738bb5..ba19c19e24ed 100644
--- a/include/linux/hmm.h
+++ b/include/linux/hmm.h
@@ -692,11 +692,6 @@ struct hmm_devmem_ops {
* chunk, as an optimization. It must, however, prioritize the faulting address
* over all the others.
*/
-typedef vm_fault_t (*dev_page_fault_t)(struct vm_area_struct *vma,
- unsigned long addr,
- const struct page *page,
- unsigned int flags,
- pmd_t *pmdp);
struct hmm_devmem {
struct completion completion;
@@ -707,7 +702,6 @@ struct hmm_devmem {
struct dev_pagemap pagemap;
const struct hmm_devmem...
2019 Jun 13
1
[PATCH 10/22] memremap: add a migrate callback to struct dev_pagemap_ops
...> index 5761a39221a6..3c9a59dbfdb8 100644
> --- a/include/linux/hmm.h
> +++ b/include/linux/hmm.h
> @@ -658,11 +658,6 @@ struct hmm_devmem_ops {
> * chunk, as an optimization. It must, however, prioritize the faulting address
> * over all the others.
> */
> -typedef vm_fault_t (*dev_page_fault_t)(struct vm_area_struct *vma,
> - unsigned long addr,
> - const struct page *page,
> - unsigned int flags,
> - pmd_t *pmdp);
>
> struct hmm_devmem {
> struct completion completion;
> @@ -673,7 +668,6 @@ struct hmm_devmem {
> struc...
2018 May 14
0
[PATCH] gpu: drm: qxl: Adding new typedef vm_fault_t
Hi,
> > So my expectation that a backmerge happens anyway after -rc1/2 is in
> > line with reality, it is just to be delayed this time. I'll stay
> > tuned ;)
>
> Is this patch already merged in drm-misc-next tree ?
Pushed now.
cheers,
Gerd
2020 Jul 23
0
[PATCH v4 5/6] mm/hmm/test: use the new migration invalidation
...st_pfns;
args.start = addr;
args.end = next;
- args.pgmap_owner = NULL;
+ args.pgmap_owner = dmirror->mdevice;
args.flags = MIGRATE_VMA_SELECT_SYSTEM;
ret = migrate_vma_setup(&args);
if (ret)
@@ -983,7 +991,7 @@ static void dmirror_devmem_free(struct page *page)
}
static vm_fault_t dmirror_devmem_fault_alloc_and_copy(struct migrate_vma *args,
- struct dmirror_device *mdevice)
+ struct dmirror *dmirror)
{
const unsigned long *src = args->src;
unsigned long *dst = args->dst;
@@ -1005,6 +1013,7 @@ static vm_fault_t dmirror_devmem_fault_alloc_and_copy(s...
2020 Sep 23
1
[PATCH v3 03/22] drm/etnaviv: Introduce GEM object functions
...9236e5f..914f0867ff71 100644
--- a/drivers/gpu/drm/etnaviv/etnaviv_drv.h
+++ b/drivers/gpu/drm/etnaviv/etnaviv_drv.h
@@ -49,7 +49,6 @@ int etnaviv_ioctl_gem_submit(struct drm_device *dev, void *data,
struct drm_file *file);
int etnaviv_gem_mmap(struct file *filp, struct vm_area_struct *vma);
-vm_fault_t etnaviv_gem_fault(struct vm_fault *vmf);
int etnaviv_gem_mmap_offset(struct drm_gem_object *obj, u64 *offset);
struct sg_table *etnaviv_gem_prime_get_sg_table(struct drm_gem_object *obj);
void *etnaviv_gem_prime_vmap(struct drm_gem_object *obj);
diff --git a/drivers/gpu/drm/etnaviv/etnaviv_gem.c...
2020 Sep 09
1
[bug report] drm/nouveau: move io_reserve_lru handling into the driver v5
...eau: move io_reserve_lru handling
into the driver v5" from Aug 21, 2020, leads to the following static
checker warning:
drivers/gpu/drm/nouveau/nouveau_ttm.c:148 nouveau_ttm_fault()
warn: inconsistent returns '*bo->base.resv'.
drivers/gpu/drm/nouveau/nouveau_ttm.c
126 static vm_fault_t nouveau_ttm_fault(struct vm_fault *vmf)
127 {
128 struct vm_area_struct *vma = vmf->vma;
129 struct ttm_buffer_object *bo = vma->vm_private_data;
130 pgprot_t prot;
131 vm_fault_t ret;
132
133 ret = ttm_bo_vm_reserve(bo, vmf...
2019 Aug 08
0
[PATCH 6/9] nouveau: simplify nouveau_dmem_migrate_to_ram
..._fence_done(struct nouveau_fence **fence)
}
}
-static void
-nouveau_dmem_fault_alloc_and_copy(struct vm_area_struct *vma,
- const unsigned long *src_pfns,
- unsigned long *dst_pfns,
- unsigned long start,
- unsigned long end,
- struct nouveau_dmem_fault *fault)
+static vm_fault_t nouveau_dmem_fault_copy_one(struct nouveau_drm *drm,
+ struct vm_fault *vmf, struct migrate_vma *args,
+ dma_addr_t *dma_addr)
{
- struct nouveau_drm *drm = fault->drm;
struct device *dev = drm->dev->dev;
- unsigned long addr, i, npages = 0;
- nouveau_migrate_copy_t copy;
- int ret;
-...
2020 Aug 13
0
[PATCH 10/20] drm/omapdrm: Introduce GEM object functions
....dumb_map_offset = omap_gem_dumb_map_offset,
.ioctls = ioctls,
diff --git a/drivers/gpu/drm/omapdrm/omap_gem.c b/drivers/gpu/drm/omapdrm/omap_gem.c
index d0d12d5dd76c..d68dc63dea0a 100644
--- a/drivers/gpu/drm/omapdrm/omap_gem.c
+++ b/drivers/gpu/drm/omapdrm/omap_gem.c
@@ -487,7 +487,7 @@ static vm_fault_t omap_gem_fault_2d(struct drm_gem_object *obj,
* vma->vm_private_data points to the GEM object that is backing this
* mapping.
*/
-vm_fault_t omap_gem_fault(struct vm_fault *vmf)
+static vm_fault_t omap_gem_fault(struct vm_fault *vmf)
{
struct vm_area_struct *vma = vmf->vma;
struct...
2019 Aug 08
1
[PATCH 6/9] nouveau: simplify nouveau_dmem_migrate_to_ram
...}
>
> -static void
> -nouveau_dmem_fault_alloc_and_copy(struct vm_area_struct *vma,
> - const unsigned long *src_pfns,
> - unsigned long *dst_pfns,
> - unsigned long start,
> - unsigned long end,
> - struct nouveau_dmem_fault *fault)
> +static vm_fault_t nouveau_dmem_fault_copy_one(struct nouveau_drm *drm,
> + struct vm_fault *vmf, struct migrate_vma *args,
> + dma_addr_t *dma_addr)
> {
> - struct nouveau_drm *drm = fault->drm;
> struct device *dev = drm->dev->dev;
> - unsigned long addr, i, npages = 0;
> - nouv...
2019 Oct 10
1
[PATCH 1/2] drm/nouveau: move io_reserve_lru handling into the driver
Am 09.10.19 um 17:39 schrieb Daniel Vetter:
> On Mon, Sep 30, 2019 at 03:12:53PM +0200, Christian König wrote:
> [SNIP]
>> +static vm_fault_t nouveau_ttm_fault(struct vm_fault *vmf)
>> +{
>> + struct vm_area_struct *vma = vmf->vma;
>> + struct ttm_buffer_object *bo = vma->vm_private_data;
>> + pgprot_t prot;
>> + vm_fault_t ret;
>> +
>> + ret = ttm_bo_vm_reserve(bo, vmf);
>> + if (ret...
2019 Sep 30
3
[PATCH 1/2] drm/nouveau: move io_reserve_lru handling into the driver
...c b/drivers/gpu/drm/nouveau/nouveau_ttm.c
index f0daf958e03a..7f8495066e8b 100644
--- a/drivers/gpu/drm/nouveau/nouveau_ttm.c
+++ b/drivers/gpu/drm/nouveau/nouveau_ttm.c
@@ -162,13 +162,51 @@ const struct ttm_mem_type_manager_func nv04_gart_manager = {
.debug = nouveau_manager_debug
};
+static vm_fault_t nouveau_ttm_fault(struct vm_fault *vmf)
+{
+ struct vm_area_struct *vma = vmf->vma;
+ struct ttm_buffer_object *bo = vma->vm_private_data;
+ pgprot_t prot;
+ vm_fault_t ret;
+
+ ret = ttm_bo_vm_reserve(bo, vmf);
+ if (ret)
+ return ret;
+
+ nouveau_bo_del_io_reserve_lru(bo);
+
+ prot = vm_ge...
2020 Sep 15
0
[PATCH v2 05/21] drm/gma500: Introduce GEM object functions
...diff --git a/drivers/gpu/drm/gma500/gem.c b/drivers/gpu/drm/gma500/gem.c
index f9c4b1d76f56..8f07de83b6fb 100644
--- a/drivers/gpu/drm/gma500/gem.c
+++ b/drivers/gpu/drm/gma500/gem.c
@@ -18,7 +18,9 @@
#include "psb_drv.h"
-void psb_gem_free_object(struct drm_gem_object *obj)
+static vm_fault_t psb_gem_fault(struct vm_fault *vmf);
+
+static void psb_gem_free_object(struct drm_gem_object *obj)
{
struct gtt_range *gtt = container_of(obj, struct gtt_range, gem);
@@ -36,6 +38,17 @@ int psb_gem_get_aperture(struct drm_device *dev, void *data,
return -EINVAL;
}
+static const struct vm...