From: sashiko-bot@kernel.org
To: "Paolo Bonzini" <pbonzini@redhat.com>
Cc: kvm@vger.kernel.org
Subject: Re: [PATCH 5.15.y v2 5/8] KVM: x86/mmu: pull call to drop_large_spte() into __link_shadow_page()
Date: Fri, 26 Jun 2026 17:59:19 +0000 [thread overview]
Message-ID: <20260626175920.6F0C61F000E9@smtp.kernel.org> (raw)
In-Reply-To: <20260626174620.1819772-6-pbonzini@redhat.com>
Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
- [Low] The `cache` parameter added to `__link_shadow_page` is unused.
--
commit ed55c138ec7737d6fb972fc8e93a6a6549ebcdf9
Author: Paolo Bonzini <pbonzini@redhat.com>
KVM: x86/mmu: pull call to drop_large_spte() into __link_shadow_page()
This commit moves the drop_large_spte() call out of individual callers
and directly into __link_shadow_page() before the shadow page is installed.
It also updates kvm_mmu_get_child_sp() to return an error pointer when a
shadow page already exists.
> diff --git a/arch/x86/kvm/mmu/mmu.c b/arch/x86/kvm/mmu/mmu.c
> index dbc18d4cc572c..d58be2e698f79 100644
> --- a/arch/x86/kvm/mmu/mmu.c
> +++ b/arch/x86/kvm/mmu/mmu.c
[ ... ]
> @@ -2264,13 +2257,21 @@ static void shadow_walk_next(struct kvm_shadow_walk_iterator *iterator)
> __shadow_walk_next(iterator, *iterator->sptep);
> }
>
> -static void link_shadow_page(struct kvm_vcpu *vcpu, u64 *sptep,
> - struct kvm_mmu_page *sp)
> +static void __link_shadow_page(struct kvm_vcpu *vcpu,
> + struct kvm_mmu_memory_cache *cache, u64 *sptep,
[Severity: Low]
This isn't a bug, but is the cache parameter used anywhere inside
__link_shadow_page()?
Looking at the full function body, it seems to rely on
mmu_page_add_parent_pte(vcpu, sp, sptep), which implicitly uses
vcpu->arch.mmu_pte_list_desc_cache rather than this new parameter.
> + struct kvm_mmu_page *sp)
> {
> u64 spte;
>
> BUILD_BUG_ON(VMX_EPT_WRITABLE_MASK != PT_WRITABLE_MASK);
--
Sashiko AI review · https://sashiko.dev/#/patchset/20260626174620.1819772-1-pbonzini@redhat.com?part=5
next prev parent reply other threads:[~2026-06-26 17:59 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-06-26 17:46 [PATCH 5.15.y v2 0/8] KVM: fixes for CVE-2026-46113 and related issues Paolo Bonzini
2026-06-26 17:46 ` [PATCH 5.15.y v2 1/8] KVM: x86/mmu: Use a bool for direct Paolo Bonzini
2026-06-26 17:46 ` [PATCH 5.15.y v2 2/8] KVM: x86/mmu: Stop passing "direct" to mmu_alloc_root() Paolo Bonzini
2026-06-26 17:46 ` [PATCH 5.15.y v2 3/8] KVM: x86/mmu: Derive shadow MMU page role from parent Paolo Bonzini
2026-06-26 18:07 ` sashiko-bot
2026-06-26 17:46 ` [PATCH 5.15.y v2 4/8] KVM: x86/mmu: Always pass 0 for @quadrant when gptes are 8 bytes Paolo Bonzini
2026-06-26 17:58 ` sashiko-bot
2026-06-26 17:46 ` [PATCH 5.15.y v2 5/8] KVM: x86/mmu: pull call to drop_large_spte() into __link_shadow_page() Paolo Bonzini
2026-06-26 17:59 ` sashiko-bot [this message]
2026-06-26 17:46 ` [PATCH 5.15.y v2 6/8] KVM: x86: Fix shadow paging use-after-free due to unexpected GFN Paolo Bonzini
2026-06-26 17:46 ` [PATCH 5.15.y v2 7/8] KVM: x86: Fix shadow paging use-after-free due to unexpected role Paolo Bonzini
2026-06-26 17:46 ` [PATCH 5.15.y v2 8/8] KVM: x86/mmu: Ensure hugepage is in by slot before checking max mapping level Paolo Bonzini
2026-06-27 16:35 ` [PATCH 5.15.y v2 0/8] KVM: fixes for CVE-2026-46113 and related issues Sasha Levin
2026-07-10 5:52 ` Kenta Akagi
2026-07-10 21:24 ` Sasha Levin
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20260626175920.6F0C61F000E9@smtp.kernel.org \
--to=sashiko-bot@kernel.org \
--cc=kvm@vger.kernel.org \
--cc=pbonzini@redhat.com \
--cc=sashiko-reviews@lists.linux.dev \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox