From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=209.85.222.176 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1796131967; b=A1yCLXA8IWZtpklHif58gLERIvFvxhJ+QSiCiuKx2LA07uvM1+yHH84UYH+mOm55jRAE fO2IQuYyLvTSaL1NSl/LzV/KY3aXfWo1Eu2666lqrYy5zXpKsM+zBIXlzilyO4K/aIzhu 1PSMJpvYBCy1EQECxOXwvQORQQ1hwCfgnRkAUBZm85W3t7f7knTFiHBsLE6t+PFeJa8Ob 7tGrg2bNIl+P3e0zKxL6Z/ZqDWAMZsXyPydZcSjgQzooiqoP0e32lp3utRHgS/xv4of1U NaLXVDDeqai35gf4W68COuTzCg1OOoCyJv1Mr02cnX01oxmL2Sq57hOPWgMF0O8UkFg== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796131967; h=DMARC-Filter:Received:DKIM-Signature:X-Google-DKIM-Signature: X-Forwarded-Encrypted:X-Gm-Message-State:X-Gm-Gg:X-Received:Received: Received:Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; bh=T3wdSUtvh3b5noX4vPr7Kanz2WiFkhEv7ivn6i/6sMA=; b=CoT/TMDcBj2X8JNUO3qSsxh7mGakalAuw4iRSLwW+761x7RviTyjpnP6eELba8BnNYEa ljRWXtyM0wPZmF/UUhjHiNop4iukN23SjU+JY/SBP6X9+QZp+Nv+bp3ceYYpT0iTSn3k4 WPCBXtDOfvi2RUtuozT9GmcVZ/X2jMNO8JyNWQoJNp5QpA1F/ObMHBhWM1/dL25you0NW ChLXAnM1Ssb4sIgLe6MNp8phZ4mkJSskdCAYGbMVBqAadCC0aiaurv2hOIVj2FsYay38s 3Ly8cZbxYk5is45TfNaLFZGur5oCX7AMgjC34zCAc3Qs7mRjtLEg1RcNu0Prn82efMg== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=none header.from=ziepe.ca; spf=pass smtp.mailfrom=ziepe.ca; dkim=pass header.d=ziepe.ca header.i=@ziepe.ca header.a=rsa-sha256 header.s=google header.b=M7iSu0ni; arc=none smtp.remote-ip=209.85.222.176 Received: from mail-qk1-f176.google.com (mail-qk1-f176.google.com [209.85.222.176]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 63B6B606A327 for ; Tue, 1 Dec 2026 13:32:47 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org 63B6B606A327 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=ziepe.ca Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=ziepe.ca Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=ziepe.ca header.i=@ziepe.ca header.a=rsa-sha256 header.s=google header.b=M7iSu0ni Received: by mail-qk1-f176.google.com with SMTP id af79cd13be357-94962d80d34so663407785a.2 for ; Tue, 01 Dec 2026 05:32:47 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ziepe.ca; s=google; t=1796131966; x=1796736766; darn=vger.kernel.org; h=in-reply-to:content-disposition:content-type:mime-version :references:message-id:subject:cc:to:from:date:from:to:cc:subject :date:message-id:reply-to:content-type; bh=T3wdSUtvh3b5noX4vPr7Kanz2WiFkhEv7ivn6i/6sMA=; b=M7iSu0niydB51M/cnDfbDxWjc6P7BeK6N1TSiJKj/AZhV+JJatRBRGZ9mlZ48dpnu9 vwETVncMUyT9VExTcgYw2McsGas7twKMT9y7RErd729ahzDrKjqrx6om/W8ixnp8czMc ipHs6YWdweamxJ920R9FW0liFqeSREJoYoM2ECO1voP0AyGYa9XjCk4wVC9keYTETIIf lgY3DNO0iRgSDKp0iefPN5e37nh9tgwOwkWFhtaz9X8Om5cmU8q60/Uv/1K0uOJ/4adL gyco3s6z12xI0YPL52blSob26fO7CQhkZ38wg3tZu3tfjmvjjaRPtM1K93R5lZXxqUqK LLPQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20260707; t=1796131966; x=1796736766; h=in-reply-to:content-disposition:content-type: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 :content-type; bh=T3wdSUtvh3b5noX4vPr7Kanz2WiFkhEv7ivn6i/6sMA=; b=iB/DQPQPQnL35SJn1tLuAqLDGcccVLlWUS06U4VRxyqAn83FAjBcNOn3bj18uQ5o8V uErVY7fm/vw6sI9zTRRSq9SKYE9TDrK+lmpT20QGq3xqv44uTqxPVEPVAx2L2N77r/h1 NqW7unjwH40JzLMYCKY54jphyNhvHGsqgZVWY12SPL5jDhlFx8iNDJYZWpP01Ebax9+G si2kchB4cgV0JA1wm6Rz/WkyLW50DuG8hsmS4Awtp24aOXJbhZo9vyzmzWZFiQssFZWO j0D79r36ITiEEsuTX7cjnViZiRYQbLcAxXII+O1P2jGOEFr7uwDDHA6e2mX3sgEe/o8L /3rQ== X-Forwarded-Encrypted: i=1; AL+hErEibbvmEqrvP5B77R7ThrCsYcVA8GURbSAPkzNkRmtXmKOtA2qdoBUYnWUS7TYWI4icsKM=@vger.kernel.org X-Gm-Message-State: APuU4Z/t9Q7TG54yxouHqW9j3QvRJGgdYbM18q6k5da4sfBJcmBh7ssT 0mAN91lX0ipr5iILq56ekbEFp429BSvKKHHpE0iX+EZb0cRzSarfGVLMIWsbbJLsqB4= X-Gm-Gg: AZFdTZdzFrsFmuei8LwxaG6akIymhkWUIENPYkMIa36/dEfnjuy5bF/aIrZmbmGhps8 iP7MW+5Acx5OnAVCYBcYb1MaVuHOSFGYnQnyiypkKdVgtj8D0rMuEiy0a0OmZqKfW7NkkAfH/Qc NVx8X1ZCRSe5SA0CsVbh7bsYSlU8U0d/It39Ms9J64+6WPCmYP3DbD7CHe7jApVBPYv/Rycj4VV rQp730i+0DwNi8jbhLpLT/REELs0u193wRXq3ZHaKicjMRxCcB37UUWganJriQwuXfcxAanuaby rGb+aSN7KMEfVh93E5Eniw59djdlvsYoGX/0NEnK0fCfTrB4l/Gwd7T5VzojvlzIdy6GNW2Oyho 1j2ztvDbzPXDeBVYobhD4+CPYezb81Fy2+1ZRaDAsQSNxgYny3mW3nUIINODHxIufuWcEjSH7H7 Hge6fVM2wcK/rynfb81E+dVGRfZxk6J7f2Z0JSu/PXFYP9JsrCtOFuIeRuP7eAf5ER2uoSUYsCM 7hgiUB/og0r+srbKmu09s17t1p/y9u4P69ud1pAtq1SUUU8J0N86QY9z4ssHEA6C6E2NnPLJpms 5L4A X-Received: by 2002:a05:620a:2401:10b0:949:c503:ce40 with SMTP id af79cd13be357-949c503d18cmr4657980685a.56.1796131966198; Tue, 01 Dec 2026 05:32:46 -0800 (PST) Received: from ziepe.ca ([142.177.118.84]) by smtp.gmail.com with ESMTPSA id af79cd13be357-94a0175c67fsm1808666185a.31.2026.12.01.05.32.45 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 01 Dec 2026 05:32:45 -0800 (PST) Received: from jgg by wakko with local (Exim 4.97) (envelope-from ) id 1xYNyP-00000000obo-0T2P; Tue, 01 Dec 2026 09:32:45 -0400 Date: Tue, 1 Dec 2026 09:32:45 -0400 From: Jason Gunthorpe To: "Reshetova, Elena" Cc: "Aneesh Kumar K.V" , "linux-coco@lists.linux.dev" , Dan Williams , Leon Romanovsky , Bjorn Helgaas , Jonathan Cameron , Xu Yilun , Alexey Kardashevskiy , Greg Kroah-Hartman , "Rafael J . Wysocki" , Steven Price , Suzuki K Poulose , Lukas Wunner , Ashish Kalra , Tom Lendacky , Herbert Xu , "driver-core@lists.linux.dev" , "linux-pci@vger.kernel.org" , "kvm@vger.kernel.org" , "patches@lists.linux.dev" Subject: Re: [PATCH v1 08/10] PCI/TSM: Add sysfs lock and unlock for guest-assigned devices Message-ID: <20261201133245.GE1856591@ziepe.ca> References: <20261123083337.2731019-1-aneesh.kumar@kernel.org> <20261123083337.2731019-9-aneesh.kumar@kernel.org> <20261123152738.GF179082@ziepe.ca> X-Mailing-List: kvm@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: On Mon, Nov 30, 2026 at 04:18:28PM +0000, Reshetova, Elena wrote: > I have a question on this: > "Independent host audit must not change guest-visible > data; current CCA has no separate host-audit measurement operation." > > TDX is the same, i.e. there is a single command on the host to collect > measurements from the device with a supplied nonce > (RMI_VDEV_GET_MEASUREMENTS in your case, TDH.SPDM.MNG > (GET_MEASUREMENTS) in our case). TDX is not quite the same, RMI_VDEV_GET_MEASUREMENTS requires a realm to exist before you can even call it, so it is impossible for the host to get measurements at all. This is obviously broken and ARM will fix it. TDX at least doesn't seem to have that limitation, but it does have the issue that the TDH.SPDM.MNG always changes guest visible information. So the TSM driver must block the host from calling TDH.SPDM.MNG once an iommufd vdevice exists, to prevent guest corruption. Intel should correct this so they can have full host audit as well. I imagine this will just be some simple ERRNO return. AMD seems to be similar to Intel. Jason