lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <86jz7sl25r.wl-maz@kernel.org>
Date: Thu, 10 Apr 2025 11:52:00 +0100
From: Marc Zyngier <maz@...nel.org>
To: Ganapatrao Kulkarni <gankulkarni@...amperecomputing.com>
Cc: linux-arm-kernel@...ts.infradead.org,
	kvmarm@...ts.linux.dev,
	linux-kernel@...r.kernel.org,
	oliver.upton@...ux.dev,
	joey.gouly@....com,
	suzuki.poulose@....com,
	yuzenghui@...wei.com,
	darren@...amperecomputing.com
Subject: Re: [PATCH] KVM: arm64: nv: Forward hvc traps if originated from nested VM

On Thu, 10 Apr 2025 11:20:24 +0100,
Ganapatrao Kulkarni <gankulkarni@...amperecomputing.com> wrote:
> 
> 
> 
> On 10-04-2025 12:49 pm, Marc Zyngier wrote:
> > On Thu, 10 Apr 2025 08:07:43 +0100,
> > Ganapatrao Kulkarni <gankulkarni@...amperecomputing.com> wrote:
> >> 
> >> It was discovered while trying selftest(smccc_filter) that the
> >> hvc trap is getting forwarded to guest hypervisor even if it is
> >> originated from itself.
> >> 
> >> HVC traps from guest hypervisor should be handled by the host
> >> hypervisor and traps originating from nested VM should be
> >> forwarded. Adding check to forward only if the hvc is trapped
> >> from the nested VM.
> > 
> > I disagree. HVC from EL2 must be routed to the same EL2. HVC from EL1
> > must be routed to the EL2 controlling EL1.
> 
> Thanks, Understood, In NV case, hvc has to be forwarded to L1
> irrespective of it origin (L1 or L2). Need to add hvc handler in the
> smccc_filter.c for the vm (when run as L1), so that it is handled and
> returns with required args set.

Why? This test checks under which conditions an HVC/SMC gets routed to
userspace. What does it even mean to test HVC if it doesn't make it
outside of the guest itself?

	M.

-- 
Without deviation from the norm, progress is not possible.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ