From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=100.103.45.18 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1796468149; b=JYFVz4xST3wkzC7C4Pp57XPfjowSGqnaceU/TnZAIuCD52qmJnlGWY93exIOM0YmNL6Z TqngZKptXrEJKSc2LxBOUhsLdcyQcHaKyoTRDv+unTJNBspUZq2wQX7vtdL2kqC9xZl8R my7QEeKdzx1lDgC49D3GxaJ8fzhPLJ77L+7VYq0COP8S8zFXNCKBPZsmBRh01tXfE1xJf Q62KEl7eWuKX2iVCP6uXh1Vs6M2yLA4dtaMsYd9Vs+w+oBit5ogF4bHmtqY5ya9CXxxq4 iaVRqciNeD98+uC6ZwDHOOGucoWgvQQVPrh9VMNsMfJu3EOJT76PNnpgmY0jWWIDeQg== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796468149; h=Received:DKIM-Signature:Message-ID:From:Subject:Reply-To:To:Cc: In-Reply-To:References:Content-Type:Content-Transfer-Encoding:Date; bh=WjxyhxZTm0kTqoVK4HX+p3+45xG0ZB5ktSawP9VpJC8=; b=Xo571YhQx0WyB62grC+Ta1Hf4b9AqXk8yPgLm4iVBgHNmR48jJCtdOaJkV91dp2atKXT B8m7GtNJZndqMikulEPLpKV4rn/XTpiKvH/wXJAgxRlCMI0rAdojD0HGZ8IScps7UExcj jBnB9ALfGPYdC5geoWs0OEEVzIEHDK95glswSnBJe+Pt9dfJhcOyZ50tRPczgaBMxe9gu 1Q62U9luo7qQ1+dkWZ4K/h9QohDYGQgdHfo55mcTstGuCv+Me3ggQGvesTTL1neM3/5sn WNrWC7wS4WO5P2jX395CjXGTb4TjQb6/XO2C8f0a3oHxuhDLY4/NLDlUbA6ch/NmPnA== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=XjeiZaGW; arc=none smtp.remote-ip=100.103.45.18 Received: from smtp.kernel.org (quasi.space.kernel.org [100.103.45.18]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 2D392606A322; Sat, 5 Dec 2026 10:55:49 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=XjeiZaGW Received: by smtp.kernel.org (Postfix) with ESMTPSA id D79DD1F0092B; Sat, 5 Dec 2026 10:55:48 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel.org; s=k20260515; t=1796468149; bh=WjxyhxZTm0kTqoVK4HX+p3+45xG0ZB5ktSawP9VpJC8=; h=From:Subject:Reply-To:To:Cc:In-Reply-To:References:Date; b=XjeiZaGWa9vKt/81qZ9CRKZ1AvG8pHiHnGOomoSKKAu4SPX9vD+yE01W+StcLqQuR eleVnjObc3ey2S0zUG9GpTn+jj9s8Yq08+hvnwaZUsUb9VVfFt0pnLQ/DPwzjfaYdB cKF15h+gfAmselZOJ7pf7FHISJywHV+vmruXMC/B+U/LqqTVsEy1OtPQlP4661LSJm DsxcckUxNZYGSby4kkgJV2yNnmr2WxJsaR6MpzJfSBtaaBzusJl1Em9scPpcF0TK49 cDOvzUV6/GhkHgeyx7IR0i8DWPcoUGMBnKAG6XozFnogPRGC4aVZsPg/KuUW/ZwN6L JORrzKuq1p/gQ== Message-ID: From: sashiko-bot@kernel.org Subject: Re: [PATCH 6.1.y 5/5] KVM: arm64: vgic: Linearise AP list pruning process Reply-To: sashiko-reviews@lists.linux.dev To: "Marc Zyngier" , kvmarm@lists.linux.dev, kvm@vger.kernel.org Cc: "Oliver Upton" In-Reply-To: <20261205104145.1432112-6-maz@kernel.org> References: <20261205104145.1432112-1-maz@kernel.org> <20261205104145.1432112-6-maz@kernel.org> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Date: Sat, 05 Dec 2026 10:55:48 +0000 X-Mailing-List: kvm@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list Thank you for your contribution! Sashiko AI review found 1 potential issue to consider: - [Low] KVM: arm64: stale comments and dead ERR_PTR checks in vgic_predict_target() -- commit 1c3fcb3fde3a113a8df4be62afe265b892945484 Author: Marc Zyngier KVM: arm64: vgic: Linearise AP list pruning process This patch replaces the quadratic AP list pruning loop in vgic_prune_ap_list() with a linear pass that moves migrating IRQs onto a local list before dispatching them to their target vCPUs. > diff --git a/arch/arm64/kvm/vgic/vgic.c b/arch/arm64/kvm/vgic/vgic.c > index 7c49b113b1f60..a5c63b7f59353 100644 > --- a/arch/arm64/kvm/vgic/vgic.c > +++ b/arch/arm64/kvm/vgic/vgic.c > @@ -610,6 +610,26 @@ int kvm_vgic_set_owner(struct kvm_vcpu *vcpu, unsign= ed int intid, void *owner) > return ret; > } > =20 > +/* > + * This helper checks the target *and* does the laundry, nuking the irq = off > + * the ap_list when necessary, and doing the refcount drop on LPIs. -ENO= ENT > + * is returned when LPI release is warranted. > + */ > +static struct kvm_vcpu *vgic_predict_target(struct kvm *kvm, struct vgic= _irq *irq) > +{ > + struct kvm_vcpu *target; > + > + lockdep_assert_held(&irq->irq_lock); > + > + target =3D vgic_target_oracle(irq); > + if (!target) { > + list_del(&irq->ap_list); > + irq->vcpu =3D NULL; > + } > + > + return target; > +} [Severity: Low] Can the stale comments, unused parameter, and dead error-pointer checks around vgic_predict_target() be cleaned up in this backport? Because vgic_put_irq() was moved out of vgic_predict_target() to its callers, the comment above vgic_predict_target() no longer matches the code (it neither drops the LPI refcount nor returns -ENOENT), and the kvm parameter is unused. Similarly, the comment and both IS_ERR_OR_NULL(irq_target) checks in vgic_prune_ap_list() assume vgic_predict_target() can return an error pointer, leaving dead error-pointer handling (and inconsistent vgic_put_irq() guards across the two call sites). --=20 Sashiko AI review =C2=B7 https://sashiko.dev/#/patchset/20261205104145.1432= 112-1-maz@kernel.org?part=3D5