Displaying 17 results from an estimated 17 matches for "vmf_insert_pfn".
2024 Jan 22
2
[PATCH] mm: Remove double faults once write a device pfn
Am 22.01.24 um 04:32 schrieb Xianrong Zhou:
> The vmf_insert_pfn_prot could cause unnecessary double faults
> on a device pfn. Because currently the vmf_insert_pfn_prot does
> not make the pfn writable so the pte entry is normally read-only
> or dirty catching.
What? How do you got to this conclusion?
> The first fault only sets up the pte entry wh...
2024 Jan 24
1
[PATCH] mm: Remove double faults once write a device pfn
"Zhou, Xianrong" <Xianrong.Zhou at amd.com> writes:
> [AMD Official Use Only - General]
>
>> >>>>> The vmf_insert_pfn_prot could cause unnecessary double faults on a
>> >>>>> device pfn. Because currently the vmf_insert_pfn_prot does not
>> >>>>> make the pfn writable so the pte entry is normally read-only or
>> >>>>> dirty catching.
>> >>&...
2024 Jan 23
2
[PATCH] mm: Remove double faults once write a device pfn
Am 23.01.24 um 09:33 schrieb Zhou, Xianrong:
> [AMD Official Use Only - General]
>
>>> The vmf_insert_pfn_prot could cause unnecessary double faults on a
>>> device pfn. Because currently the vmf_insert_pfn_prot does not make
>>> the pfn writable so the pte entry is normally read-only or dirty
>>> catching.
>> What? How do you got to this conclusion?
> Sorry. I did n...
2024 Jan 24
2
[PATCH] mm: Remove double faults once write a device pfn
Am 24.01.24 um 03:43 schrieb Zhou, Xianrong:
> [AMD Official Use Only - General]
>
>>>>> The vmf_insert_pfn_prot could cause unnecessary double faults on a
>>>>> device pfn. Because currently the vmf_insert_pfn_prot does not make
>>>>> the pfn writable so the pte entry is normally read-only or dirty
>>>>> catching.
>>>> What? How do you got to this...
2019 Oct 02
2
DANGER WILL ROBINSON, DANGER
...gt;>> possible to call MMU notifier update callbacks around the call to insert_pfn.
>>
>> Can't do that.
>> First, insert_pfn() uses set_pte_at() which won't trigger the MMU notifier on
>> the target VMA. It's also static, so I'll have to access it thru vmf_insert_pfn()
>> or vmf_insert_mixed().
>
> Why would you need to target mmu notifier on target vma ?
If the mapping of the source VMA changes, mirroring can update the
target VMA via insert_pfn. But what ensures that KVM's MMU notifier
dismantles its own existing page tables (so that they c...
2019 Oct 02
2
DANGER WILL ROBINSON, DANGER
...gt;>> possible to call MMU notifier update callbacks around the call to insert_pfn.
>>
>> Can't do that.
>> First, insert_pfn() uses set_pte_at() which won't trigger the MMU notifier on
>> the target VMA. It's also static, so I'll have to access it thru vmf_insert_pfn()
>> or vmf_insert_mixed().
>
> Why would you need to target mmu notifier on target vma ?
If the mapping of the source VMA changes, mirroring can update the
target VMA via insert_pfn. But what ensures that KVM's MMU notifier
dismantles its own existing page tables (so that they c...
2020 Sep 15
0
[PATCH v2 02/21] drm/armada: Introduce GEM object functions
...,
diff --git a/drivers/gpu/drm/armada/armada_gem.c b/drivers/gpu/drm/armada/armada_gem.c
index ecf8a55e93d9..c343fbefe47c 100644
--- a/drivers/gpu/drm/armada/armada_gem.c
+++ b/drivers/gpu/drm/armada/armada_gem.c
@@ -25,7 +25,7 @@ static vm_fault_t armada_gem_vm_fault(struct vm_fault *vmf)
return vmf_insert_pfn(vmf->vma, vmf->address, pfn);
}
-const struct vm_operations_struct armada_gem_vm_ops = {
+static const struct vm_operations_struct armada_gem_vm_ops = {
.fault = armada_gem_vm_fault,
.open = drm_gem_vm_open,
.close = drm_gem_vm_close,
@@ -184,6 +184,12 @@ armada_gem_map_object(struct...
2019 Oct 02
0
DANGER WILL ROBINSON, DANGER
...to call MMU notifier update callbacks around the call to insert_pfn.
> >>
> >> Can't do that.
> >> First, insert_pfn() uses set_pte_at() which won't trigger the MMU notifier on
> >> the target VMA. It's also static, so I'll have to access it thru vmf_insert_pfn()
> >> or vmf_insert_mixed().
> >
> > Why would you need to target mmu notifier on target vma ?
>
> If the mapping of the source VMA changes, mirroring can update the
> target VMA via insert_pfn. But what ensures that KVM's MMU notifier
> dismantles its own e...
2020 Apr 22
0
[PATCH hmm 4/5] mm/hmm: remove HMM_PFN_SPECIAL
...m.h
@@ -44,10 +44,6 @@ enum hmm_pfn_flag_e {
* Flags:
* HMM_PFN_ERROR: corresponding CPU page table entry points to poisoned memory
* HMM_PFN_NONE: corresponding CPU page table entry is pte_none()
- * HMM_PFN_SPECIAL: corresponding CPU page table entry is special; i.e., the
- * result of vmf_insert_pfn() or vm_insert_page(). Therefore, it should not
- * be mirrored by a device, because the entry will never have HMM_PFN_VALID
- * set and the pfn value is undefined.
*
* Driver provides values for none entry, error entry, and special entry.
* Driver can alias (i.e., use same value) e...
2019 Oct 02
0
DANGER WILL ROBINSON, DANGER
...uess it would be
> > possible to call MMU notifier update callbacks around the call to insert_pfn.
>
> Can't do that.
> First, insert_pfn() uses set_pte_at() which won't trigger the MMU notifier on
> the target VMA. It's also static, so I'll have to access it thru vmf_insert_pfn()
> or vmf_insert_mixed().
Why would you need to target mmu notifier on target vma ? You do not need
that. The workflow is:
userspace:
ptr = mmap(/dev/kvm-mirroring-device, virtual_addresse_of_target)
Then when the mirroring process access ptr it triggers page fault that
endup in...
2020 May 01
0
[PATCH hmm v2 4/5] mm/hmm: remove HMM_PFN_SPECIAL
...m.h
@@ -44,10 +44,6 @@ enum hmm_pfn_flag_e {
* Flags:
* HMM_PFN_ERROR: corresponding CPU page table entry points to poisoned memory
* HMM_PFN_NONE: corresponding CPU page table entry is pte_none()
- * HMM_PFN_SPECIAL: corresponding CPU page table entry is special; i.e., the
- * result of vmf_insert_pfn() or vm_insert_page(). Therefore, it should not
- * be mirrored by a device, because the entry will never have HMM_PFN_VALID
- * set and the pfn value is undefined.
*
* Driver provides values for none entry, error entry, and special entry.
* Driver can alias (i.e., use same value) e...
2020 May 01
13
[PATCH hmm v2 0/5] Adjust hmm_range_fault() API
From: Jason Gunthorpe <jgg at mellanox.com>
The API is a bit complicated for the uses we actually have, and
disucssions for simplifying have come up a number of times.
This small series removes the customizable pfn format and simplifies the
return code of hmm_range_fault()
All the drivers are adjusted to process in the simplified format.
I would appreciated tested-by's for the two
2019 Aug 09
6
[RFC PATCH v6 71/92] mm: add support for remote mapping
From: Mircea C?rjaliu <mcirjaliu at bitdefender.com>
The following two new mm exports are introduced:
* mm_remote_map(struct mm_struct *req_mm,
unsigned long req_hva,
unsigned long map_hva)
* mm_remote_unmap(unsigned long map_hva)
* mm_remote_reset(void)
* rmap_walk_remote(struct page *page,
struct rmap_walk_control *rwc)
This patch
2020 Sep 15
40
[PATCH v2 00/21] Convert all remaining drivers to GEM object functions
The GEM and PRIME related callbacks in struct drm_driver are deprecated in
favor of GEM object functions in struct drm_gem_object_funcs. This patchset
converts the remaining drivers to object functions and removes most of the
obsolete interfaces.
Patches #1 to #16 and #18 to #19 convert DRM drivers to GEM object functions,
one by one. Each patch moves existing callbacks from struct drm_driver to
2020 Apr 22
11
[PATCH hmm 0/5] Adjust hmm_range_fault() API
From: Jason Gunthorpe <jgg at mellanox.com>
The API is a bit complicated for the uses we actually have, and
disucssions for simplifying have come up a number of times.
This small series removes the customizable pfn format and simplifies the
return code of hmm_range_fault()
All the drivers are adjusted to process in the simplified format.
I would appreciated tested-by's for the two
2020 Sep 23
25
[PATCH v3 00/22] Convert all remaining drivers to GEM object functions
The GEM and PRIME related callbacks in struct drm_driver are deprecated in
favor of GEM object functions in struct drm_gem_object_funcs. This patchset
converts the remaining drivers to object functions and removes most of the
obsolete interfaces.
Version 3 of this patchset mostly fixes drm_gem_prime_handle_to_fd and
updates i.MX's dcss driver. The driver was missing from earlier versions
and
2020 Aug 13
28
[PATCH 00/20] Convert all remaining drivers to GEM object functions
The GEM and PRIME related callbacks in struct drm_driver are deprecated in
favor of GEM object functions in struct drm_gem_object_funcs. This patchset
converts the remaining drivers to object functions and removes most of the
obsolete interfaces.
Patches #1 to #18 convert DRM drivers to GEM object functions, one by one.
Each patch moves existing callbacks from struct drm_driver to an instance
of