From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-ej1-f50.google.com (mail-ej1-f50.google.com [209.85.218.50]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 9F3F840680F for ; Wed, 10 Jun 2026 12:15:50 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.218.50 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1781093752; cv=none; b=jVrBpD7Fjd9udvzPTCqW+DFxeE5Eshn3euXkCHD6IDe7dswNdt/NRZtBc6tImRsI0lI5zZnDrUbUgGf6kWcRsRNugEctMMASoDAq7L4KFL2wn6f3dsRvC2bsGXYRFKIjHHCvAMdotD8XGj0c9tLRBD1N4TiIK14dgc/79El1I6w= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1781093752; c=relaxed/simple; bh=EQ4ylpXWi+YuFiR5Looby0OijETsTIL2XaXtihxgnN4=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=sg5EI4uWqM2zuN86fSTm/k9NfuU/HMQePis3UfPRoa+xz3nggXrSgiwIwxjZjZgU0B++ppQgameGUyd9Uv8SoUTa0VGuNHcxRZzErqVhQBN0v9KYPssmn70derFk06AL5eE6pnprIw+pO/6l5aeorj39JOJHNhskoqoauOXhi1A= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=google.com; spf=pass smtp.mailfrom=google.com; dkim=pass (2048-bit key) header.d=google.com header.i=@google.com header.b=HA1IJgmS; arc=none smtp.client-ip=209.85.218.50 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=google.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=google.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=google.com header.i=@google.com header.b="HA1IJgmS" Received: by mail-ej1-f50.google.com with SMTP id a640c23a62f3a-bebac79fff8so713510566b.0 for ; Wed, 10 Jun 2026 05:15:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20251104; t=1781093749; x=1781698549; darn=vger.kernel.org; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:from:to:cc:subject:date:message-id:reply-to; bh=bzJL0f8wCrWQURXF71Dj93R+/8RnEeuOYo8zI8bSgbE=; b=HA1IJgmSf6lbxP/Pd0X/amAKB2Y6Zpcd43Bw732bgMyR04o1IJT6NnG4jhWC47+12I 2/ANyBTVRaP1cTmeOGs8bGo40mK3ck6BdzB6pOuxmgXYq5dL8kl6aWJT7FlcFQnIVhOF TbeyXUlUIdatBV/0lPQNv7xT15cMReDEsxum9rwj4zzjQXATstmJwqvXC+yR+nkCdGAM 9Ku0/keffndz9x2xXD9WxQDgh6acWyOlya/1BzRA0NncBTuvdGqrmSvsyi4mbLCx/fNG eFVQvKYEXyHAxUjR3iAiR56iLZztcdbyGR3Q1WPeBE/CBEtw6OZjCXiwLl3K5n/hWQDS 4GTg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1781093749; x=1781698549; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-gg:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=bzJL0f8wCrWQURXF71Dj93R+/8RnEeuOYo8zI8bSgbE=; b=s2BM4MMvyPq5BZHwG++7Lfcwk0OdNVY38ri5lV6p75SHbG8UQ8JNSQo/w/29+ib3OI wLk8wsvySe2K1iTpUZp4dE3VNwax6MpEyhvtOtYM/81ybGwQEO8Ag93xJwFKIFS0C1k0 Ek7qQkkYFH3gSOWpMpO8ES0/ZCoxWhdG7GdmIEGrnzNmYRsWohZNF53l034+r5Ur/+/t JzvLkjbnYZI/bPjIOYebSRBCbjXK2nG3W/0NrsXnmpLlugPg7a/Xzd5VoEsFSj1k0r4r ovekGV4wQ52kRjIDFtoqSK6depi6QL7ZYmzA23BJRR/a0rIVAA9BIyA1TCGFX3uPPags corQ== X-Forwarded-Encrypted: i=1; AFNElJ+a5H+k9nsSXlA2LY+2PPHLAwmdvWznNS4ggkNWuazL3hra5lLyiE3WpttvIhGERdpMuofs1JxsUzQqwms=@vger.kernel.org X-Gm-Message-State: AOJu0YxFLI5o4I1tGU8iwm+FIvLEKvr+88ViWe+5qix7etc3DJQJ5DwH kM27ezfR4qofGR5ms/m88Pag+fe0jSXa8ngtRG4oq6o67yDneD3PdF/9i9kM01SW9w== X-Gm-Gg: Acq92OEJGtqDLsjZXmD8wYlKir+KCIHOosw0a2Be3SqCYOcpCJ4tqbAmdzpt4BAtRdC POsSNhurUDV+dAy7GTpjdWaE2he+9ee0KHMQ7feK+nSKGNoPwELqnZyDhlMfNGJm8u73/U/kzsv S14hFAvqTa0SMga6i75ig76LfgLOgYr01z8XX1B8FtC+FvYHhM2PBRqIFsiedYELXqegdd9pK3T gmRM2PTSWTTTs/3uRtKv5nVoXtjJ1vRX5gIfSYhlT6yJflIEy4HJt5mr0pIxDMJTmGxkdwCVTF6 YbmgHw7kRhPv7ymaaPKM/+KDSZzsX0I+XoFhEgeSLegwlQbO7nqtuvcJVB2YiAevaNiTDCQ0s4M Ie/Qwht2poAWge07ON5ApzPI6OciZeFiJlgJPqsCjobWRoU47z59xmzoSYhe3LT0q4bjMRpWTEe a5Qi00IC17hxmx3OI1KuBUgocldGtvNXGa9rnD6bgkwc6P5blpjHjxi7+Aleb8rp+sM8OKVjF/U J+RSg== X-Received: by 2002:a17:907:267b:b0:bec:bd4f:e495 with SMTP id a640c23a62f3a-bf37155192bmr921560466b.12.1781093748467; Wed, 10 Jun 2026 05:15:48 -0700 (PDT) Received: from google.com (135.91.155.104.bc.googleusercontent.com. [104.155.91.135]) by smtp.gmail.com with ESMTPSA id a640c23a62f3a-bf0559f1464sm1197120266b.55.2026.06.10.05.15.47 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 10 Jun 2026 05:15:47 -0700 (PDT) Date: Wed, 10 Jun 2026 13:15:44 +0100 From: Vincent Donnefort To: Will Deacon Cc: Sebastian Ene , catalin.marinas@arm.com, maz@kernel.org, oupton@kernel.org, joey.gouly@arm.com, korneld@google.com, kvmarm@lists.linux.dev, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, android-kvm@google.com, mrigendra.chaubey@gmail.com, perlarsen@google.com, suzuki.poulose@arm.com, yuzenghui@huawei.com Subject: Re: [PATCH v2 0/7] KVM: arm64: Forward FFA_NOTIFICATION* calls to TrustZone Message-ID: References: <20260608165549.1479409-1-sebastianene@google.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: On Wed, Jun 10, 2026 at 11:15:14AM +0100, Will Deacon wrote: > On Wed, Jun 10, 2026 at 10:26:59AM +0100, Vincent Donnefort wrote: > > On Mon, Jun 08, 2026 at 04:55:42PM +0000, Sebastian Ene wrote: > > > Remove the FFA_NOTIFICATION* calls from the blocklist used by the pKVM > > > FF-A proxy. This restriction was preventing the use of asynchronous > > > signaling mechanisms defined by the Arm FF-A specification to > > > communicate with the secure services. > > > While these calls are markes as optional, there is no reason why the > > > hypervisor proxy would block them because: > > > > > > 1. Host is the Sole Non-Secure Endpoint: The Host operates as the > > > only Non-Secure VM ID (VM ID 0) recognized by the Secure World. > > > Because all forwarded notifications are inherently attributed to > > > the Host by the SPMC, there is no risk of VM ID spoofing > > > originating from the Normal World. > > > > > > 2. No Memory Pointers or Addresses: The FFA_NOTIFICATION_* ABIs > > > operate strictly via register-based parameters, passing only > > > VM IDs, VCPU IDs, flags, and bitmaps. Because these calls do > > > not contain memory addresses, offsets, or pointers, forwarding > > > them doesn't pose a risk of memory-based confused deputy attack > > > (e.g., tricking the SPMC into overwriting protected memory). > > > > > > While the pKVM proxy behaves as a relayer, it doesn't currently have its > > > own FF-A ID(only the host has the ID 0). The behavior of the setup > > > flow is covered by the spec in the: '10.9 Notification support without > > > a Hypervisor'. > > > > As it is only a relayer. Is it really important to check SBZ arguments and > > fields on behalf of Trustzone? It doesn't feel it brings any security. If the > > host passes broken arguments, I don't believe this puts pKVM at risk. Does it? > > I think the problem would be if an update to FF-A allocated some of the > currently SBZ bits to implement some functionality that we would want > to filter at EL2. I suppose that would bump the FF-A version and the proxy would reject it? If we really want to check for those arguments to be 0: * Shouldn't we extend this check to other FF-A invocations? * Do we really want to also look into the !SBZ arguments to verify what we can? (I'm thinking about the checks on flags) > > Will