Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 5D08FC7EE30 for ; Mon, 27 Feb 2023 23:40:29 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229816AbjB0Xk1 (ORCPT ); Mon, 27 Feb 2023 18:40:27 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46084 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229470AbjB0XkY (ORCPT ); Mon, 27 Feb 2023 18:40:24 -0500 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 66D351EFCC; Mon, 27 Feb 2023 15:40:23 -0800 (PST) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 02ECD60F05; Mon, 27 Feb 2023 23:40:23 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 2CBBCC433D2; Mon, 27 Feb 2023 23:40:22 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1677541222; bh=9IxQJE3j4dmxMZbzznAmN8B1dh5sGXAOcy0FKIivJoM=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=mWgMzMsYow3d5/oPP6Yw+TiUfU1bb3O28f+nzzOTKWFw3Ck27DHlBEOZH/dL9H83N QdyJl0Awby3W7MNl4DwbqdhWlSZYCqCOVsVj5iDsKM4+4LqfcuwiQIpX83wabT4sYv MzLml0YnOXiK97590FuiEhkjhzZUZSi3Y+ZDQ5M5N00Bzn+YY3pDM8aV9OhBz/i5ew ZF0qIMbZ9SZvXAG/aDUvdbaSEzLDTk8ZJOef0NOxpUoTEUGLpyo/xLlCZgmOTR8nf8 2oxLYdgAxxPTT00j6mktHpu3IjxvcjAjgS0wk+oJNhNouzskRLAuV4ZNnxsw0tqhon BuBGRBIc2J3pg== Date: Mon, 27 Feb 2023 15:40:21 -0800 From: Jakub Kicinski To: Jeremi Piotrowski Cc: linux-kernel@vger.kernel.org, netdev@vger.kernel.org, Richard Cochran , Christoph Hellwig Subject: Re: [PATCH v2] ptp: kvm: Use decrypted memory in confidential guest on x86 Message-ID: <20230227154021.259cce7b@kernel.org> In-Reply-To: <20230227155819.1189863-1-jpiotrowski@linux.microsoft.com> References: <20230227155819.1189863-1-jpiotrowski@linux.microsoft.com> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, 27 Feb 2023 15:58:19 +0000 Jeremi Piotrowski wrote: > KVM_HC_CLOCK_PAIRING currently fails inside SEV-SNP guests because the > guest passes an address to static data to the host. In confidential > computing the host can't access arbitrary guest memory so handling the > hypercall runs into an "rmpfault". To make the hypercall work, the guest > needs to explicitly mark the memory as decrypted. Do that in > kvm_arch_ptp_init(), but retain the previous behavior for > non-confidential guests to save us from having to allocate memory. > > Add a new arch-specific function (kvm_arch_ptp_exit()) to free the > allocation and mark the memory as encrypted again. # Form letter - net-next is closed The merge window for v6.3 has begun and therefore net-next is closed for new drivers, features, code refactoring and optimizations. We are currently accepting bug fixes only. Please repost when net-next reopens after Mar 6th. RFC patches sent for review only are obviously welcome at any time.