[PATCH v4 0/2] RISC-V: KVM: Fix hugepage mapping handling during dirty logging

wang.yechao255@zte.com.cn posted 2 patches 2 days, 22 hours ago
arch/riscv/include/asm/kvm_gstage.h |   4 +
arch/riscv/kvm/gstage.c             | 133 +++++++++++++++++++++++++++-
2 files changed, 133 insertions(+), 4 deletions(-)
[PATCH v4 0/2] RISC-V: KVM: Fix hugepage mapping handling during dirty logging
Posted by wang.yechao255@zte.com.cn 2 days, 22 hours ago
From: Wang Yechao <wang.yechao255@zte.com.cn>

This series fixes an issue where dirty logging fails to work correctly
with huge pages.

v3 -> v4:
  - Squash PATCH2 into PATCH3, and adjust according to Anup's comments.
  - Link to v3:
  https://lore.kernel.org/linux-riscv/20260316141234007qSAOsesu2cSQsj-LA-qq3@zte.com.cn/T/#t

v2 -> v3:
  - patch01: Add reference to the specific commit being fixed
  - patch02: Fill the page table entry before replacing the ptep value
  - patch03: Add handling for dirty logging disable to avoid memory leak in gstage page tables
  - Link to v2:
  https://lore.kernel.org/linux-riscv/20260304172139131ChDubMSpGDUB03lY4UCbK@zte.com.cn/T/#t

v1 -> v2:
  - fix the lost write protection on huge pages
  - split huge pages before handling the write protection fault.

  - Link to v1:
  https://lore.kernel.org/linux-riscv/20260226172245358qVZavIykLL2QC0KoqTO-I@zte.com.cn/T/#u

Wang Yechao (2):
  RISC-V: KVM: Fix lost write protection on huge pages during dirty logging
  RISC-V: KVM: Split huge pages during fault handling for dirty logging

 arch/riscv/include/asm/kvm_gstage.h |   4 +
 arch/riscv/kvm/gstage.c             | 133 +++++++++++++++++++++++++++-
 2 files changed, 133 insertions(+), 4 deletions(-)

-- 
2.47.3
Re: [PATCH v4 0/2] RISC-V: KVM: Fix hugepage mapping handling during dirty logging
Posted by Anup Patel 2 days, 21 hours ago
On Mon, Mar 30, 2026 at 1:38 PM <wang.yechao255@zte.com.cn> wrote:
>
> From: Wang Yechao <wang.yechao255@zte.com.cn>
>
> This series fixes an issue where dirty logging fails to work correctly
> with huge pages.
>
> v3 -> v4:
>   - Squash PATCH2 into PATCH3, and adjust according to Anup's comments.
>   - Link to v3:
>   https://lore.kernel.org/linux-riscv/20260316141234007qSAOsesu2cSQsj-LA-qq3@zte.com.cn/T/#t
>
> v2 -> v3:
>   - patch01: Add reference to the specific commit being fixed
>   - patch02: Fill the page table entry before replacing the ptep value
>   - patch03: Add handling for dirty logging disable to avoid memory leak in gstage page tables
>   - Link to v2:
>   https://lore.kernel.org/linux-riscv/20260304172139131ChDubMSpGDUB03lY4UCbK@zte.com.cn/T/#t
>
> v1 -> v2:
>   - fix the lost write protection on huge pages
>   - split huge pages before handling the write protection fault.
>
>   - Link to v1:
>   https://lore.kernel.org/linux-riscv/20260226172245358qVZavIykLL2QC0KoqTO-I@zte.com.cn/T/#u
>
> Wang Yechao (2):
>   RISC-V: KVM: Fix lost write protection on huge pages during dirty logging
>   RISC-V: KVM: Split huge pages during fault handling for dirty logging
>
>  arch/riscv/include/asm/kvm_gstage.h |   4 +
>  arch/riscv/kvm/gstage.c             | 133 +++++++++++++++++++++++++++-
>  2 files changed, 133 insertions(+), 4 deletions(-)
>
> --
> 2.47.3
>
> --
> kvm-riscv mailing list
> kvm-riscv@lists.infradead.org
> http://lists.infradead.org/mailman/listinfo/kvm-riscv

Queued this series for Linux-7.1

Thanks,
Anup