Received: by 2002:a6b:500f:0:0:0:0:0 with SMTP id e15csp6204045iob; Tue, 10 May 2022 12:46:20 -0700 (PDT) X-Google-Smtp-Source: ABdhPJw1WnXlSRAtPQOo5uhhVfipq0Hhh1AwUEGuVpgU4CygqNSOn6gd1lYeDto7ZGNP/kUt1cBc X-Received: by 2002:a17:90b:3850:b0:1dc:2948:bd38 with SMTP id nl16-20020a17090b385000b001dc2948bd38mr1460399pjb.29.1652211980335; Tue, 10 May 2022 12:46:20 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1652211980; cv=none; d=google.com; s=arc-20160816; b=AzVurhxMiDymq2ygbiUEB7WPbu4teTbu+sGeaB4F4fnmX8b/ckEShb6DKX926E3r3B +1nb65ReH60fZc6POPYdhbZLI4KBkYB4IyAxfKgjbMJQO1qty2q8jrSsjRshQTuQRCsS /uWUCObdD342N8UmBXLGWPIpWNkDf6DjtEfuh0/ZmlQenavCGSuawyHgMI6+NTCejakD Wk6pfDpX/DW4+CNTAKDcQY1sFzhhMBvNzIQe6Tmp8mqh2xGcrERMbYvHb7VeEdDQgHbS cviKXOpM1PF//gfU6vLGi9Z6MpJgUbn/jqKHaWqCtnY5ebFNji0q805LU9WAjZ5Tqa+/ depg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=D22aDHnJ1m79Gspc+stki2xxpGA84mw9KFYTLRBWAQs=; b=S3KrNuewXNgML/KW9jQXijIxd1BBbKyKvS47eZF0j+t9roJ46hYLuVD60cHTmTm+5H TxJbIeJKg4TbWPSHxjqmCJhzwtNodmnwTS/oEBABuxQeVr3QTsbezSGpDCOH/NnsGHdN MzThF1sTv2+TmtRqaKb/Cp4IpEiRnBaz95AmskgqIrTnp444pWnnRr9JwT+rg5kZrIAh pViS7e8jCGWcjoopSQH1AcG9XpUE9U26EmcEIbXwf+c0M7x39VkWzGEr/zOi2VJMWJnn HDGgSdIZdtaussMmRPsSjlQoTg0caIZh/vRz/+GPoboa6dgU7n2cYZ0pLalXfoKwlU9a N2ZQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=cROMnquZ; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id q18-20020a170902f79200b0015ed293b2d3si294pln.125.2022.05.10.12.46.04; Tue, 10 May 2022 12:46:20 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=cROMnquZ; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S243692AbiEJRWm (ORCPT + 99 others); Tue, 10 May 2022 13:22:42 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35280 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1347876AbiEJRWl (ORCPT ); Tue, 10 May 2022 13:22:41 -0400 Received: from mga18.intel.com (mga18.intel.com [134.134.136.126]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E374322386D for ; Tue, 10 May 2022 10:18:43 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1652203123; x=1683739123; h=date:from:to:cc:subject:message-id:references: mime-version:in-reply-to; bh=Ljmq8HUFYZ6GA+tSSAa18YvTdl9NI5PPjwKlwvCCJrY=; b=cROMnquZU6qdzaFh/b9Qf/6Mg0fNO41txQV36MUMPJzqtg6U+/0N0cWZ SPlRpE8+laOVODAPYHTuBgE3QJTmNkZPsYYZErXfFBPQIgoKwx8kdlf49 MJ2N054BJEfbMw2kB+wFhZahR1iM66cv0nkHTtCTZjR+eQ/V9fcMxDK8K 9Gr+mOSYPX0Jj9zKvW2uNkZ1FPGZ/ti3YFqhM6WUuPupnqLMHHO1pVYJL R09L/kSGZESQshN2z0ETYgf6FVj50GfrqnXW6fUKpdP9RFfjcgfz929Ob rxTqx0lSUmbaAkleInQJOoPySYh9O6sYh6elGOlQrMQryUKCwmf7xO3nz g==; X-IronPort-AV: E=McAfee;i="6400,9594,10343"; a="251494862" X-IronPort-AV: E=Sophos;i="5.91,214,1647327600"; d="scan'208";a="251494862" Received: from orsmga004.jf.intel.com ([10.7.209.38]) by orsmga106.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 10 May 2022 10:18:26 -0700 X-IronPort-AV: E=Sophos;i="5.91,214,1647327600"; d="scan'208";a="697188538" Received: from ticela-or-037.amr.corp.intel.com (HELO localhost) ([10.209.191.163]) by orsmga004-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 10 May 2022 10:18:25 -0700 Date: Tue, 10 May 2022 10:18:24 -0700 From: Ira Weiny To: Kees Cook Cc: Dave Hansen , "H. Peter Anvin" , Dan Williams , Fenghua Yu , Rick Edgecombe , "Shankar, Ravi V" , linux-kernel@vger.kernel.org Subject: Re: [PATCH V10 08/44] Documentation/pkeys: Add initial PKS documentation Message-ID: References: <20220419170649.1022246-1-ira.weiny@intel.com> <20220419170649.1022246-9-ira.weiny@intel.com> <202205091501.132944B2C7@keescook> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <202205091501.132944B2C7@keescook> X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE, SPF_NONE,T_SCC_BODY_TEXT_LINE,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, May 09, 2022 at 03:03:48PM -0700, Kees Cook wrote: > On Tue, Apr 19, 2022 at 10:06:13AM -0700, ira.weiny@intel.com wrote: > > From: Ira Weiny > > > > Add initial overview and configuration information about PKS. > > > > Cc: "Moger, Babu" > > Signed-off-by: Ira Weiny > > > > --- > > Changes for V9 > > Feedback from Dave Hansen > > Remove overview and move relevant text to the main pkey > > overview which covers both user ans kernel keys. > > Add an example of using Kconfig > > Move MSR details to later patches > > --- > > Documentation/core-api/protection-keys.rst | 43 ++++++++++++++++++++-- > > 1 file changed, 39 insertions(+), 4 deletions(-) > > > > diff --git a/Documentation/core-api/protection-keys.rst b/Documentation/core-api/protection-keys.rst > > index bf28ac0401f3..13eedb0119e1 100644 > > --- a/Documentation/core-api/protection-keys.rst > > +++ b/Documentation/core-api/protection-keys.rst > > @@ -13,6 +13,11 @@ Pkeys Userspace (PKU) is a feature which can be found on: > > * Intel client CPUs, Tiger Lake (11th Gen Core) and later > > * Future AMD CPUs > > > > +Protection Keys Supervisor (PKS) is a feature which can be found on: > > + * Sapphire Rapids (and later) "Scalable Processor" Server CPUs > > + * Future non-server Intel parts. > > + * qemu: https://www.qemu.org/2021/04/30/qemu-6-0-0/ > > It looks like QEMU has pass-through support, but not emulation? I'm not an expert on qemu but I believe the support is emulated with TCG. "TCG can emulate the PKS feature (protection keys for supervisor pages)." -- https://wiki.qemu.org/ChangeLog/6.0 > It'd be > really nice to have this feature emulated so it would be possible to > test the code. (Or I need to find a machine that supports this...) Both Rick and I have been able to run with the following options to qemu: qemu-system-x86_64 ... -machine accel=tcg -cpu qemu64,+pks ... Ira