summaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/amd/amdgpu/amdgpu_debugfs.c
diff options
context:
space:
mode:
authorBibo Mao <maobibo@loongson.cn>2025-09-18 14:44:22 +0300
committerHuacai Chen <chenhuacai@loongson.cn>2025-09-18 14:44:22 +0300
commitf58c9aa1065f73d243904b267c71f6a9d1e9f90e (patch)
tree287638a1d1576b5e122b5badf9ef645173b8dfab /drivers/gpu/drm/amd/amdgpu/amdgpu_debugfs.c
parent091b29d53fe645781c5c1f405bc9fcd50ce5792b (diff)
downloadlinux-f58c9aa1065f73d243904b267c71f6a9d1e9f90e.tar.xz
LoongArch: KVM: Fix VM migration failure with PTW enabled
With PTW disabled system, bit _PAGE_DIRTY is a HW bit for page writing. However with PTW enabled system, bit _PAGE_WRITE is also a "HW bit" for page writing, because hardware synchronizes _PAGE_WRITE to _PAGE_DIRTY automatically. Previously, _PAGE_WRITE is treated as a SW bit to record the page writeable attribute for the fast page fault handling in the secondary MMU, however with PTW enabled machine, this bit is used by HW already (so setting it will silence the TLB modify exception). Here define KVM_PAGE_WRITEABLE with the SW bit _PAGE_MODIFIED, so that it can work on both PTW disabled and enabled machines. And for HW write bits, both _PAGE_DIRTY and _PAGE_WRITE are set or clear together. Cc: stable@vger.kernel.org Signed-off-by: Bibo Mao <maobibo@loongson.cn> Signed-off-by: Huacai Chen <chenhuacai@loongson.cn>
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/amdgpu_debugfs.c')
0 files changed, 0 insertions, 0 deletions