Received: by 2002:ab2:6c55:0:b0:1fd:c486:4f03 with SMTP id v21csp409506lqp; Wed, 12 Jun 2024 05:36:52 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCVcN1zaqjDEkPbk2epQsPLgZM9gl/26G0vr0SqzVixgMWP0IVWkYG61lFEn1XiPoNu5aYFIWl1H+Wl2LDoToFxuM67sWKB2+yCTLBgp3Q== X-Google-Smtp-Source: AGHT+IGeWcYcLQsbFlNg31++Z7dWbogcIXKf9wP8m4sfHTivpVbqGOkxpQWiH5S7TPGfUsSlWTxw X-Received: by 2002:a17:902:e5ce:b0:1f7:1f4d:6ede with SMTP id d9443c01a7336-1f83b6c0f24mr17516405ad.39.1718195812554; Wed, 12 Jun 2024 05:36:52 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1718195812; cv=pass; d=google.com; s=arc-20160816; b=wMUPAgQsAfu2XNeNgriN7bksbwqRSblnRd7TQ0duVdT0yGfUCN074/p21+BtayH34N k3fogWcjWxXbLUuaJnn1w0WM0b/qA5iWVM1yuZYyVrM2n4rhXmPyjMwu1RdyepFfNSLT Q8SgmC3pycHL8B1+MdIaYiEmatmKyFmJZXDmolQrIMl2BaBIiEYzv1PBM/bY3mfotErp r0P/B7wMv4KSaO4+PtDfscuwtdcJoKO6h7TdCqf1o9cqIguEPafRcUakJfiLiQV3tkgt 6Qtan4sNiewzL1eT4a071WI7Kh/TmdFDJ81r8kic31/GIOCD5mBc0FyeGChT4LbZpN54 /OdA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-disposition:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:message-id:subject:cc :to:from:date:dkim-signature; bh=QrMyjmD2JSCqaNbD/3Zbq25zH0wkB1yh4QXxandYTCo=; fh=c3jR+vAG9EnRwX/W10lvjyDWAkQ5R6xRKzsFLYKlx9Q=; b=gEQ20LYJGlceDBq48DaL7KuZIaGD9BCN+m3M7AA2tk1bBJmQn2TyyQuEGnJHn6cghm rTkkj+/ole0fc6+gljiiD/+pO6iUfDgz7mfdlaNvxm6YKQugTyfaDY4LkdmK3mH3g2Gu Y2HppeW6UArR/TKgxNgDVk5hutszgCRsp4mBrdc6HrcKM7rFKpEwpbHriVqxKh7mCeBI ushmgm2zvyqxuvMtCiEblitZ7hFXfgvWJE2/u0E8s5PsKFKH/gAan30/ZPQMLnCub5WD 64vtejxNeuL6tV1oXpImGzi5ZRpUS0t25d3S98QCxc0hxcFSDiQfPx4deczMk4zNrEiD c+xw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=F24CDxpc; arc=pass (i=1 dkim=pass dkdomain=intel.com dmarc=pass fromdomain=linux.intel.com); spf=pass (google.com: domain of linux-kernel+bounces-211292-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-211292-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id d9443c01a7336-1f727f92cacsi36137335ad.526.2024.06.12.05.36.52 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 12 Jun 2024 05:36:52 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-211292-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) client-ip=2604:1380:45e3:2400::1; Authentication-Results: mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=F24CDxpc; arc=pass (i=1 dkim=pass dkdomain=intel.com dmarc=pass fromdomain=linux.intel.com); spf=pass (google.com: domain of linux-kernel+bounces-211292-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-211292-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id 9B7C5283DF8 for ; Wed, 12 Jun 2024 09:47:10 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id BA32C16DECC; Wed, 12 Jun 2024 09:46:44 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=intel.com header.i=@intel.com header.b="F24CDxpc" Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.13]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 85B6615BB for ; Wed, 12 Jun 2024 09:46:42 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=192.198.163.13 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1718185603; cv=none; b=Nd2YHXKGEuZzzP5py4TlfdbMXteh1dFB+nRc6ft1jPz0+JkE2PxI/PXTdDm7SrL1j/13shMfRb29JOKIgYM5B7kQGme6cHlx6NAZTa2OhSVpN0anty8z9AUMPIy8/CAAYVy9TwsVY4DtpSpHMq22+I7rLCE0CcajNFNms1WP5Qk= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1718185603; c=relaxed/simple; bh=a7lwZ0mHtGz7Gcc9Okj6FYzGI4uiz2b1f7BH+B8VXes=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=r71a5EeQt8mSA0MmZTZCQdaEJ2hHGkrcxYC2HprZNDRU+QmemTWs92KXOc+1dP8Z/Rmh0dW27hmtp//C/0BYVLAPxwnI7rY+ATasQ0EfO65Rj2SEOeqATmwz920Z8FqfPllW3P5g3N0xZJ04cFPkbFTenQC/Vl0plF3tnzbdTdA= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.intel.com; spf=none smtp.mailfrom=linux.intel.com; dkim=pass (2048-bit key) header.d=intel.com header.i=@intel.com header.b=F24CDxpc; arc=none smtp.client-ip=192.198.163.13 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.intel.com Authentication-Results: smtp.subspace.kernel.org; spf=none smtp.mailfrom=linux.intel.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1718185603; x=1749721603; h=date:from:to:cc:subject:message-id:references: mime-version:in-reply-to; bh=a7lwZ0mHtGz7Gcc9Okj6FYzGI4uiz2b1f7BH+B8VXes=; b=F24CDxpc2eeiBbtDgy3bX5uvdXfwWG5b+xxMgM5jjdY2py6gC1xmKQ/3 kWH9ycIKlusMaWJSqxfNgGwkp5wvKQ6jKxQwh9VWNuUAHYyylpg/6sDOs 3yXLxhXYIuwvmw76/Equzi1qV8kTw0zxX3pheUkGfzpTeHr1OYA/GohdQ cMBkQGTaJC0b6pk+aRRsgjtwk/VEowEmBsvdgxmidKhh+ZdiURT/91Ipx a7XtsYM7XlNXMMJ5dOys5ObncP06GvfjJ+zr9IZ2cdmOAsXjlrGaoyY6f rjJBA+CiUcfgqt7pNuocn+zaDzXZF6YQPcIluOEMwSpvKMFKcmNO4iv0O Q==; X-CSE-ConnectionGUID: YLdxmD0qTN+2LTVupKaHzQ== X-CSE-MsgGUID: ATAjoUuHTAOWI6KwQRYNaQ== X-IronPort-AV: E=McAfee;i="6600,9927,11100"; a="17863439" X-IronPort-AV: E=Sophos;i="6.08,232,1712646000"; d="scan'208";a="17863439" Received: from orviesa006.jf.intel.com ([10.64.159.146]) by fmvoesa107.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 12 Jun 2024 02:46:42 -0700 X-CSE-ConnectionGUID: v+BjPlcWSS25zn6ybtEtbQ== X-CSE-MsgGUID: QJvE9afARvSRiV7EDcgmRw== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.08,232,1712646000"; d="scan'208";a="40204411" Received: from black.fi.intel.com ([10.237.72.28]) by orviesa006.jf.intel.com with ESMTP; 12 Jun 2024 02:46:39 -0700 Received: by black.fi.intel.com (Postfix, from userid 1000) id B1C44193; Wed, 12 Jun 2024 12:46:37 +0300 (EEST) Date: Wed, 12 Jun 2024 12:46:37 +0300 From: "Kirill A. Shutemov" To: Jeremi Piotrowski Cc: Chris Oo , Dave Hansen , Dave Hansen , Thomas Gleixner , Ingo Molnar , Borislav Petkov , "x86@kernel.org" , "H. Peter Anvin" , "linux-coco@lists.linux.dev" , "linux-kernel@vger.kernel.org" , Dexuan Cui , John Starks Subject: Re: [EXTERNAL] Re: [PATCH] x86/tdx: Generate SIGBUS on userspace MMIO Message-ID: References: <20240528100919.520881-1-kirill.shutemov@linux.intel.com> <4df2ebee-40c0-4ea3-8909-13b90f049ff1@intel.com> <31ead5ce-fb38-4c0d-9bf9-606b59d6da09@linux.microsoft.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: <31ead5ce-fb38-4c0d-9bf9-606b59d6da09@linux.microsoft.com> On Tue, Jun 11, 2024 at 07:25:27PM +0200, Jeremi Piotrowski wrote: > Is there a reason we can't fix the handler to do the #VE->mmio emulation > for userspace too, so that this scenario works just like outside of a > CVM? We are looking into it. It requires some groundwork to properly understand risks of wider attack surface. I think we will get there, but it will take time. -- Kiryl Shutsemau / Kirill A. Shutemov