Received: by 2002:a25:23cc:0:0:0:0:0 with SMTP id j195csp1782320ybj; Wed, 6 May 2020 05:20:40 -0700 (PDT) X-Google-Smtp-Source: APiQypIHhoiroj/bpR1sam+R9UKwg0EZ/I4KiP0tJizbShAg136fEQ3RqH0FrzYDBxIl1ANnmHGs X-Received: by 2002:a05:6402:95e:: with SMTP id h30mr6540126edz.117.1588767640461; Wed, 06 May 2020 05:20:40 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1588767640; cv=none; d=google.com; s=arc-20160816; b=LHZgfsbQS/OuQfbSfygZghkSShX28Mm6apseDSTi8D27qIAVqycZSLKbnSxC07qNfC FXtyIvMGyz03DT0HXhdVW1nV1jp2T7HoD4z52/JMcg6uciUfKcReM7YIdEb0gdzzUp1x G4bay6NcF0LxmSIohdj+hfxeWuabp+wt34VKCKKN95XqXfWivl3zksCDovv86mfO+EaM 4Tn3GtCNXiOTZQsCF+lqgpUO+Y1Uz/tSYheKS2qjexmTlVC3cLYGzLoBu0GnoSSYQYLq zMxuhFx4pLJpEuwS2+QZOC1JhPP1WCxfHuB/w++7hwBDuyzE4VdkLmsJOjLzVpOTJMwA 4vdw== 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-disposition:mime-version:references:message-id:subject:cc :to:from:date:ironport-sdr:ironport-sdr; bh=JnRFDYohN7UXov5evq0+f1JVurz66ZJC3HvSlOTLhNc=; b=qSRJhmNjIHAY6cWt8PfOtXhgO/AE5qTUX0qlU1WLtRnlxJPVoTTxeQoJpgxn4NzPLr sMr99Tb6xrsiIvt5jZjJQj4MKbgFaKCCgI1kPSx0erQoVRZhVxO7wXgmJXabnxTituNf 2wBM+/R9FC+6Ci8Ex+xGR5IuosDVI828WC+AIZyyjsMiZ5gORmnNs8XByl3goyYMTVUI iAlofOjI0Hl4GGZ+qEsLrTIVvB5uBPv7c/zSLtX2ScaElYJr6ufr1UUSRI55qXwjPgY6 2KTwOkP6EWbVaai5A2xbrfT7myNab2oi5rh9cCDfF/CD9HtM0CXygsSmtSyBfhfSbXcy 8aqA== 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 a7si974931edb.221.2020.05.06.05.20.15; Wed, 06 May 2020 05:20:40 -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 S1728057AbgEFMQ3 (ORCPT + 99 others); Wed, 6 May 2020 08:16:29 -0400 Received: from mga05.intel.com ([192.55.52.43]:54465 "EHLO mga05.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727792AbgEFMQ3 (ORCPT ); Wed, 6 May 2020 08:16:29 -0400 IronPort-SDR: 8Uv4s9Fdj0SGFaphJ1CbFtoEo54rTShdLOuFtgQZ72a7TjkYsAWBMB0WWhcUnsmy4tB4jl1AP8 HAbOA43TbygQ== X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga004.fm.intel.com ([10.253.24.48]) by fmsmga105.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 06 May 2020 05:16:28 -0700 IronPort-SDR: JPc1qDvxWTtCQTa5kLHajZfavO2LC2sdMB2KoRj3adSpRVz9HEdoV9Pqvrhqm9O01NFfFPhQaw bgM8i1rw/9sw== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.73,358,1583222400"; d="scan'208";a="284606158" Received: from ngorb-mobl1.ccr.corp.intel.com (HELO localhost) ([10.252.52.39]) by fmsmga004.fm.intel.com with ESMTP; 06 May 2020 05:16:21 -0700 Date: Wed, 6 May 2020 15:16:18 +0300 From: Jarkko Sakkinen To: Jethro Beekman Cc: linux-kernel@vger.kernel.org, x86@kernel.org, linux-sgx@vger.kernel.org, akpm@linux-foundation.org, dave.hansen@intel.com, sean.j.christopherson@intel.com, nhorman@redhat.com, npmccallum@redhat.com, haitao.huang@intel.com, andriy.shevchenko@linux.intel.com, tglx@linutronix.de, kai.svahn@intel.com, bp@alien8.de, josh@joshtriplett.org, luto@kernel.org, kai.huang@intel.com, rientjes@google.com, cedric.xing@intel.com, puiterwijk@redhat.com Subject: Re: [PATCH v29 00/20] Intel SGX foundations Message-ID: <20200506121618.GA170146@linux.intel.com> References: <20200421215316.56503-1-jarkko.sakkinen@linux.intel.com> <07c1a36c-cebc-3a65-6f92-4a5498fcc369@fortanix.com> <20200430034651.GB31820@linux.intel.com> <20200430082328.GA6387@linux.intel.com> <1dd3ba07-f782-3a82-ac25-83d524a2c062@fortanix.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1dd3ba07-f782-3a82-ac25-83d524a2c062@fortanix.com> 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 Thu, Apr 30, 2020 at 04:12:07PM +0200, Jethro Beekman wrote: > On 2020-04-30 10:23, Jarkko Sakkinen wrote: > > On Thu, Apr 30, 2020 at 09:19:48AM +0200, Jethro Beekman wrote: > >> On 2020-04-30 05:46, Jarkko Sakkinen wrote: > >>> On Wed, Apr 29, 2020 at 05:27:48PM +0200, Jethro Beekman wrote: > >>>> On 2020-04-21 23:52, Jarkko Sakkinen wrote: > >>>>> Intel(R) SGX is a set of CPU instructions that can be used by applications > >>>>> to set aside private regions of code and data. The code outside the enclave > >>>>> is disallowed to access the memory inside the enclave by the CPU access > >>>>> control. > >>>>> > >>>>> There is a new hardware unit in the processor called Memory Encryption > >>>>> Engine (MEE) starting from the Skylake microacrhitecture. BIOS can define > >>>>> one or many MEE regions that can hold enclave data by configuring them with > >>>>> PRMRR registers. > >>>>> > >>>>> The MEE automatically encrypts the data leaving the processor package to > >>>>> the MEE regions. The data is encrypted using a random key whose life-time > >>>>> is exactly one power cycle. > >>>>> > >>>>> The current implementation requires that the firmware sets > >>>>> IA32_SGXLEPUBKEYHASH* MSRs as writable so that ultimately the kernel can > >>>>> decide what enclaves it wants run. The implementation does not create > >>>>> any bottlenecks to support read-only MSRs later on. > >>>>> > >>>>> You can tell if your CPU supports SGX by looking into /proc/cpuinfo: > >>>>> > >>>>> cat /proc/cpuinfo | grep sgx > >>>> > >>>> Let's merge this. > >>> > >>> So can I tag reviewed-by's? > >>> > >> > >> No, but you already have my tested-by's. > >> > >> If it helps I can try to review some patches, but 1) I know nothing > >> about kernel coding guidelines and best practices and 2) I know little > >> about most kernel internals, so I won't be able to review every patch. > > > > Ackd-by *acknowledges* that the patches work for you. I think that would > > be then the correct choice for the driver patch and patches before that. > > > > Lets go with that if that is cool for you of course. > > > > Did you run the selftest only or possibly also some internal Fortanix > > tests? > > > > v29 patches 2 through 18: > > Acked-by: Jethro Beekman > > I only ran production SGX software. I didn't run the self test. That's great to hear thank you. Updated my tree accordingly. /Jarkko