Skip to content

[PW_SID:1146017] KVM: riscv: Avoid overwriting existing G-stage tables with huge leaves - #2473

Closed
linux-riscv-bot wants to merge 2 commits into
workflow__riscv__fixesfrom
pw1146017
Closed

[PW_SID:1146017] KVM: riscv: Avoid overwriting existing G-stage tables with huge leaves#2473
linux-riscv-bot wants to merge 2 commits into
workflow__riscv__fixesfrom
pw1146017

Conversation

@linux-riscv-bot

Copy link
Copy Markdown

PR for series 1146017 applied to workflow__riscv__fixes

Name: KVM: riscv: Avoid overwriting existing G-stage tables with huge leaves
URL: https://patchwork.kernel.org/project/linux-riscv/list/?series=1146017
Version: 1

Linux RISC-V bot and others added 2 commits August 8, 2026 18:30
RISC-V KVM can overwrite an existing G-stage table entry when installing
a huge leaf mapping. If the target huge range already has a lower-level
page table, kvm_riscv_gstage_set_pte() can replace the non-leaf entry
with a leaf PTE. This disconnects the lower-level page table and can
change guest-visible mappings or leak the page-table page.

Reject replacing a valid non-leaf PTE with a leaf PTE. If huge-page
installation hits such a conflict, fall back to a 4K mapping for the
faulting GPA and leave the existing page-table structure intact.

Suggested-by: Sashiko <sashiko-bot@kernel.org>
Fixes: 9d05c1f ("RISC-V: KVM: Implement stage2 page table programming")
Signed-off-by: Jinyu Tang <jinyu.tang@linux.dev>
Signed-off-by: Linux RISC-V bot <linux.riscv.bot@gmail.com>
@linux-riscv-bot
linux-riscv-bot force-pushed the workflow__riscv__fixes branch 2 times, most recently from 3c76238 to 492cc66 Compare August 14, 2026 21:24
@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 1: "KVM: riscv: Avoid overwriting existing G-stage tables with huge leaves"
build-rv32-defconfig
Desc: Builds riscv32 defconfig
Duration: 143.50 seconds
Result: PASS

@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 1: "KVM: riscv: Avoid overwriting existing G-stage tables with huge leaves"
build-rv64-clang-allmodconfig
Desc: Builds riscv64 allmodconfig with Clang, and checks for errors and added warnings
Duration: 1130.94 seconds
Result: PASS

@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 1: "KVM: riscv: Avoid overwriting existing G-stage tables with huge leaves"
build-rv64-gcc-allmodconfig
Desc: Builds riscv64 allmodconfig with GCC, and checks for errors and added warnings
Duration: 1461.18 seconds
Result: PASS

@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 1: "KVM: riscv: Avoid overwriting existing G-stage tables with huge leaves"
build-rv64-nommu-k210-defconfig
Desc: Builds riscv64 defconfig with NOMMU for K210
Duration: 26.82 seconds
Result: PASS

@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 1: "KVM: riscv: Avoid overwriting existing G-stage tables with huge leaves"
build-rv64-nommu-k210-virt
Desc: Builds riscv64 defconfig with NOMMU for the virt platform
Duration: 27.83 seconds
Result: PASS

@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 1: "KVM: riscv: Avoid overwriting existing G-stage tables with huge leaves"
checkpatch
Desc: Runs checkpatch.pl on the patch
Duration: 0.82 seconds
Result: PASS

@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 1: "KVM: riscv: Avoid overwriting existing G-stage tables with huge leaves"
dtb-warn-rv64
Desc: Checks for Device Tree warnings/errors
Duration: 88.38 seconds
Result: PASS

@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 1: "KVM: riscv: Avoid overwriting existing G-stage tables with huge leaves"
header-inline
Desc: Detects static functions without inline keyword in header files
Duration: 0.23 seconds
Result: PASS

@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 1: "KVM: riscv: Avoid overwriting existing G-stage tables with huge leaves"
kdoc
Desc: Detects for kdoc errors
Duration: 0.89 seconds
Result: PASS

@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 1: "KVM: riscv: Avoid overwriting existing G-stage tables with huge leaves"
module-param
Desc: Detect module_param changes
Duration: 0.25 seconds
Result: PASS

@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 1: "KVM: riscv: Avoid overwriting existing G-stage tables with huge leaves"
verify-fixes
Desc: Verifies that the Fixes: tags exist
Duration: 0.28 seconds
Result: PASS

@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 1: "KVM: riscv: Avoid overwriting existing G-stage tables with huge leaves"
verify-signedoff
Desc: Verifies that Signed-off-by: tags are correct
Duration: 0.30 seconds
Result: PASS

@linux-riscv-bot
linux-riscv-bot force-pushed the workflow__riscv__fixes branch 2 times, most recently from bb1a926 to 6f6f7c0 Compare August 21, 2026 03:35
@linux-riscv-bot
linux-riscv-bot deleted the pw1146017 branch August 22, 2026 02:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant