Received: by 2002:a05:6902:102b:0:0:0:0 with SMTP id x11csp1045565ybt; Wed, 24 Jun 2020 18:27:48 -0700 (PDT) X-Google-Smtp-Source: ABdhPJx9BZaijM7rIEBrcL+w5AroZrgt3e8yLt5NijoFufGdvyfRo+2cjpwugN3+GsLqQZINZZ4T X-Received: by 2002:aa7:d0c5:: with SMTP id u5mr28992719edo.51.1593048468513; Wed, 24 Jun 2020 18:27:48 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593048468; cv=none; d=google.com; s=arc-20160816; b=VKb6igcyZipWvU+ntvt78lJTqpV3sNuTUkqgTj3b1lYwkpO+HR7bQv78boqQVEGHZb gKXRl/8WOm/bgi1orAJpKFJnkPi47zdEMBHe4bflfu/A5jhvO4J8QWwqx7IAObfmyy8z jlpLN5Hn37A3dSn+vrXD7KnML1mgc8yelQoCjVimcoQm3ooWLa+5HRvqFZJGLnAMlg2+ FjOF6/VWtm7xov8Gay602VSOwuCpMt6JC/6Dd3xTNVxj02lHQnIal29GGQDLVEm+r5Rc GHwSsDSyHv8Q16IcG+sxd4ELzh9QC9rz/wMbIBtUfGj6pG5Jl6s36rbd3snHLCy3LQNo TYWA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:organization:in-reply-to :content-transfer-encoding:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:ironport-sdr :ironport-sdr; bh=J+PY2VGkYRs4y3CP28w+/TfK3hM1LJL5zumj1pGjBQU=; b=fEdgFemUsrmsE87GMRtFX9zyDPW1sw4fADgbnF/rItBq8eVev5hKxWvJy74r/MEfOx qYPdT7cRmo1qtuKNJt5td7uqSJCAIHZ9d3ixv+WUleIN7vNIZ5S4U3D6W7EiSoupVzUF 4fF37+3epXm8EikQW0de8uxbzaINiy9LFwjdKdnQfec/2CQU5OQKrbE3CFZWdscsrdo6 06EJ6tIXrWlaxZ3uABd7Y/WVP93UFWvUUxBhnw1hgA5nUOAJmrmmPval34X5GGrmGzqF MZVh+7vGOqquf7QKF4a3UkEEAhLflsFRmL+Jo96CMDyXopSN4HtkPbjI3GOskfu8QQwm pYdA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id b10si3735171ejv.385.2020.06.24.18.27.25; Wed, 24 Jun 2020 18:27:48 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2389119AbgFYBZS (ORCPT + 99 others); Wed, 24 Jun 2020 21:25:18 -0400 Received: from mga18.intel.com ([134.134.136.126]:52359 "EHLO mga18.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2388928AbgFYBZR (ORCPT ); Wed, 24 Jun 2020 21:25:17 -0400 IronPort-SDR: BVnQ631daeQ3xZ7uZU0MOw6VuaoKCfxKBXblbGodSYpvH7gy4hBuHaEBwndBBqNfntTg1W47n+ yCYA92RsY4vw== X-IronPort-AV: E=McAfee;i="6000,8403,9662"; a="132143138" X-IronPort-AV: E=Sophos;i="5.75,277,1589266800"; d="scan'208";a="132143138" X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga006.fm.intel.com ([10.253.24.20]) by orsmga106.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 24 Jun 2020 18:25:16 -0700 IronPort-SDR: lHG9pRk5VM34/0o+zgZoBgZgr+FGKS/ovMZTi3xdPANRvKhwRkhGBYsanWNzUR682mClBXbuhL h7UqOmyreLVA== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.75,277,1589266800"; d="scan'208";a="479314625" Received: from hluxenbu-mobl.ger.corp.intel.com (HELO localhost) ([10.252.36.218]) by fmsmga006.fm.intel.com with ESMTP; 24 Jun 2020 18:25:05 -0700 Date: Thu, 25 Jun 2020 04:25:03 +0300 From: Jarkko Sakkinen To: Borislav Petkov Cc: x86@kernel.org, linux-sgx@vger.kernel.org, linux-kernel@vger.kernel.org, Sean Christopherson , Jethro Beekman , akpm@linux-foundation.org, andriy.shevchenko@linux.intel.com, asapek@google.com, cedric.xing@intel.com, chenalexchen@google.com, conradparker@google.com, cyhanish@google.com, dave.hansen@intel.com, haitao.huang@intel.com, josh@joshtriplett.org, kai.huang@intel.com, kai.svahn@intel.com, kmoy@google.com, ludloff@google.com, luto@kernel.org, nhorman@redhat.com, npmccallum@redhat.com, puiterwijk@redhat.com, rientjes@google.com, tglx@linutronix.de, yaozhangx@google.com Subject: Re: [PATCH v33 01/21] x86/cpufeatures: x86/msr: Add Intel SGX hardware bits Message-ID: <20200625012503.GD21758@linux.intel.com> References: <20200617220844.57423-1-jarkko.sakkinen@linux.intel.com> <20200617220844.57423-2-jarkko.sakkinen@linux.intel.com> <20200622173711.GJ32200@zn.tnic> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20200622173711.GJ32200@zn.tnic> Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Jun 22, 2020 at 07:37:11PM +0200, Borislav Petkov wrote: > On Thu, Jun 18, 2020 at 01:08:23AM +0300, Jarkko Sakkinen wrote: > > From: Sean Christopherson > > > > Add X86_FEATURE_SGX from CPUID.(EAX=7, ECX=1), which informs whether the > > CPU has SGX. > > > > Add X86_FEATURE_SGX1 and X86_FEATURE_SGX2 from CPUID.(EAX=12H, ECX=0), > > which describe the level of SGX support available [1]. > > > > Add IA32_FEATURE_CONTROL_SGX_ENABLE. BIOS can use this bit to opt-in SGX > > I'm guessing that wants to be > > IA32_FEATURE_CONTROL.SGX_ENABLE > > judging by the diff and the SDM chapter. Underscore must be just a typo. > > > before locking the feature control MSR [2]. > > > > [1] Intel SDM: 36.7.2 Intel? SGX Resource Enumeration Leaves > > [2] Intel SDM: 36.7.1 Intel? SGX Opt-In Configuration > > > > Cc: Borislav Petkov > > Acked-by: Jethro Beekman > > Signed-off-by: Sean Christopherson > > Co-developed-by: Jarkko Sakkinen > > Signed-off-by: Jarkko Sakkinen > > --- > > arch/x86/include/asm/cpufeature.h | 5 +++-- > > arch/x86/include/asm/cpufeatures.h | 7 ++++++- > > arch/x86/include/asm/disabled-features.h | 18 +++++++++++++++--- > > arch/x86/include/asm/msr-index.h | 1 + > > arch/x86/include/asm/required-features.h | 2 +- > > arch/x86/kernel/cpu/common.c | 4 ++++ > > tools/arch/x86/include/asm/cpufeatures.h | 7 ++++++- > > Also, please drop this change to tools/, see > > https://lkml.kernel.org/r/20200622141737.GA30611@kernel.org > > from today. OK I reverted it [*]. > With those addressed: > > Reviewed-by: Borislav Petkov Thank you, I'll update this to the commit. > > Thx. > > -- > Regards/Gruss, > Boris. > > https://people.kernel.org/tglx/notes-about-netiquette [*] By "git diff -R HEAD~1 -- tools/arch/x86/include/asm/cpufeatures.h | patch -p1". /Jarkko