diff options
author | Bibo Mao <maobibo@loongson.cn> | 2024-07-09 16:25:51 +0800 |
---|---|---|
committer | Huacai Chen <chenhuacai@loongson.cn> | 2024-07-09 16:25:51 +0800 |
commit | ebf00272da5c32ecd9f28e56b71bdfd5f11227e6 (patch) | |
tree | 44e60a48fe9a0fbcb10bcc70c75d12dbd32a9e8d /scripts | |
parent | 8c347042527058976e8a1cb10c0ae31e55145f76 (diff) |
LoongArch: KVM: Mark page accessed and dirty with page ref added
Function kvm_map_page_fast() is fast path of secondary mmu page fault
flow, pfn is parsed from secondary mmu page table walker. However the
corresponding page reference is not added, it is dangerious to access
page out of mmu_lock.
Here page ref is added inside mmu_lock, function kvm_set_pfn_accessed()
and kvm_set_pfn_dirty() is called with page ref added, so that the page
will not be freed by others.
Also kvm_set_pfn_accessed() is removed here since it is called in the
following function kvm_release_pfn_clean().
Signed-off-by: Bibo Mao <maobibo@loongson.cn>
Signed-off-by: Huacai Chen <chenhuacai@loongson.cn>
Diffstat (limited to 'scripts')
0 files changed, 0 insertions, 0 deletions