From: sashiko-bot@kernel.org
To: "Fuad Tabba" <tabba@google.com>
Cc: kvmarm@lists.linux.dev, "Oliver Upton" <oupton@kernel.org>,
"Marc Zyngier" <maz@kernel.org>
Subject: Re: [PATCH 4/8] KVM: arm64: Move PSCI helper functions to a shared header
Date: Fri, 19 Jun 2026 07:16:01 +0000 [thread overview]
Message-ID: <20260619071601.A5E641F000E9@smtp.kernel.org> (raw)
In-Reply-To: <20260619070508.802802-5-tabba@google.com>
Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
- [Low] The header `include/kvm/arm_psci.h` is not self-contained due to missing includes for dependencies used in the newly added inline functions.
--
commit 5533f45659b895d2266b9d4cfb6fd00ea1dc5f92
Author: Fuad Tabba <tabba@google.com>
KVM: arm64: Move PSCI helper functions to a shared header
This commit moves several PSCI helper functions out of psci.c and into the
shared include/kvm/arm_psci.h header. This includes kvm_psci_valid_affinity()
and kvm_psci_narrow_to_32bit(), along with renaming psci_affinity_mask().
[ ... ]
> diff --git a/include/kvm/arm_psci.h b/include/kvm/arm_psci.h
> index cbaec804eb839..f86a006d67136 100644
> --- a/include/kvm/arm_psci.h
> +++ b/include/kvm/arm_psci.h
> @@ -38,6 +38,33 @@ static inline int kvm_psci_version(struct kvm_vcpu *vcpu)
> return KVM_ARM_PSCI_0_1;
> }
>
> +/* Narrow the PSCI register arguments (r1 to r3) to 32 bits. */
> +static inline void kvm_psci_narrow_to_32bit(struct kvm_vcpu *vcpu)
> +{
> + int i;
> +
> + /*
> + * Zero the input registers' upper 32 bits. They will be fully
> + * zeroed on exit, so we're fine changing them in place.
> + */
> + for (i = 1; i < 4; i++)
> + vcpu_set_reg(vcpu, i, lower_32_bits(vcpu_get_reg(vcpu, i)));
[Severity: Low]
Does this change leave arm_psci.h relying on implicit includes?
The moved inline function kvm_psci_narrow_to_32bit() relies on vcpu_set_reg()
and vcpu_get_reg() which are defined in asm/kvm_emulate.h, as well as
lower_32_bits() which comes from linux/wordpart.h.
Should this header explicitly include those files to ensure it remains
self-contained, so that future users don't encounter build errors if they
include this file first?
--
Sashiko AI review · https://sashiko.dev/#/patchset/20260619070508.802802-1-tabba@google.com?part=4
next prev parent reply other threads:[~2026-06-19 7:16 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-06-19 7:05 [PATCH 0/8] KVM: arm64: Rework pKVM vCPU state synchronisation Fuad Tabba
2026-06-19 7:05 ` [PATCH 1/8] KVM: arm64: Extract MPIDR computation into a shared header Fuad Tabba
2026-06-19 7:05 ` [PATCH 2/8] KVM: arm64: Make vcpu_{read,write}_sys_reg available to HYP code Fuad Tabba
2026-06-19 7:05 ` [PATCH 3/8] KVM: arm64: Factor out reusable vCPU reset helpers Fuad Tabba
2026-06-19 7:05 ` [PATCH 4/8] KVM: arm64: Move PSCI helper functions to a shared header Fuad Tabba
2026-06-19 7:16 ` sashiko-bot [this message]
2026-06-19 7:24 ` Fuad Tabba
2026-06-19 7:05 ` [PATCH 5/8] KVM: arm64: Add host and hypervisor vCPU lookup primitives Fuad Tabba
2026-06-19 7:05 ` [PATCH 6/8] KVM: arm64: Minimise EL2's exposure of host VGIC state during world switch Fuad Tabba
2026-06-19 7:22 ` sashiko-bot
2026-06-19 7:29 ` Fuad Tabba
2026-06-19 7:05 ` [PATCH 7/8] KVM: arm64: Add primitives to flush/sync the VGIC state at EL2 Fuad Tabba
2026-06-19 7:05 ` [PATCH 8/8] KVM: arm64: Implement lazy vCPU state sync for non-protected guests Fuad Tabba
2026-06-19 7:24 ` sashiko-bot
2026-06-19 7:55 ` Fuad Tabba
2026-06-19 7:06 ` [PATCH 0/8] KVM: arm64: Rework pKVM vCPU state synchronisation Fuad Tabba
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=20260619071601.A5E641F000E9@smtp.kernel.org \
--to=sashiko-bot@kernel.org \
--cc=kvmarm@lists.linux.dev \
--cc=maz@kernel.org \
--cc=oupton@kernel.org \
--cc=sashiko-reviews@lists.linux.dev \
--cc=tabba@google.com \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.