Received: by 2002:a25:8b91:0:0:0:0:0 with SMTP id j17csp78648ybl; Mon, 2 Dec 2019 07:50:22 -0800 (PST) X-Google-Smtp-Source: APXvYqyhTR9DvQnS+5/6OsqLNxSgERyODmw5DzBuOqATgMjDCxDKY7nsO2LutJkNSoojqzT30Z22 X-Received: by 2002:aa7:cb58:: with SMTP id w24mr27610802edt.11.1575301822153; Mon, 02 Dec 2019 07:50:22 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1575301822; cv=none; d=google.com; s=arc-20160816; b=0SccAkg40OycIBTTVhp/8EV7zrlf634hTB8HgC2mDsLuU6oRfVa+fUuT86O2jD0rsF /3HHCs0olgxgwbOnCBbtwDJL267tSzf4+AD9yUWrv2Pvwcq7Ax92NNH4moiB3U9/nWNE rAXUs+nYKBRyzNyQgnVyudSTZZYDgwHk/FuLTjt1n6vxttgXeXwsp9qMoFZ1AHK+yeGe LE5sZlrt+q2sZFyoYQ75/MeuOV4MzruqjSoXFwuVIX5nn2cYOUvc/+yxE9eRwbk0r9qS t7aBD6FvZnumfofJtzccNo5B565iVaR2vmh4FMm4JE8HXKHefUIvXFAwwsKsOVkHde1T gpwQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to:message-id :organization:from:content-transfer-encoding:mime-version:date :references:reply-to:subject:cc:to; bh=3teI+90g066nyRh9dBx1pAmXUUD7ctTdICBO6h0DAts=; b=Kaz6kaK26NFpBGt19Lkiv/wHu4HNhaIvMR5mOebXf3urxLB503vA9hdKHeD106Qfx+ sIxE30zxXAuV4B47cJoNWT58RUGUx8nYO5J6HLS2pEWejbwkhMlhszHqMDTABjtCVfEL KhVdGJKTgLYa1U7jK1+D3FsMggwcoNiotTrvceQ+OUyWkT6G8R6rlRCYkGrppLdCBvFZ Bm+gz9sac2sVsD/+q1jAo/B5ICHtVkoxvJuCGPZPKyJZzWZ75CQgVqOyXlFBmga57AC9 1WsMUyNzm5SAeiTY4rG+/HcKLcx27NRYJtccHlGSHfDfum8BYRfMk2+Ht3fxQRu7jD8g O94Q== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 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. [209.132.180.67]) by mx.google.com with ESMTP id jr4si20277239ejb.287.2019.12.02.07.49.58; Mon, 02 Dec 2019 07:50:22 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 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 S1727513AbfLBPsr (ORCPT + 99 others); Mon, 2 Dec 2019 10:48:47 -0500 Received: from mga05.intel.com ([192.55.52.43]:8957 "EHLO mga05.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727417AbfLBPsq (ORCPT ); Mon, 2 Dec 2019 10:48:46 -0500 X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga007.fm.intel.com ([10.253.24.52]) by fmsmga105.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 02 Dec 2019 07:48:46 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.69,268,1571727600"; d="scan'208";a="208167745" Received: from hhuan26-mobl.amr.corp.intel.com ([10.122.128.109]) by fmsmga007.fm.intel.com with ESMTP; 02 Dec 2019 07:48:44 -0800 Content-Type: text/plain; charset=iso-8859-15; format=flowed; delsp=yes To: linux-kernel@vger.kernel.org, x86@kernel.org, linux-sgx@vger.kernel.org, "Jarkko Sakkinen" Cc: akpm@linux-foundation.org, dave.hansen@intel.com, sean.j.christopherson@intel.com, nhorman@redhat.com, npmccallum@redhat.com, serge.ayoun@intel.com, shay.katz-zamir@intel.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, linux-security-module@vger.kernel.org, "Suresh Siddha" Subject: Re: [PATCH v24 12/24] x86/sgx: Linux Enclave Driver Reply-To: haitao.huang@linux.intel.com References: <20191129231326.18076-1-jarkko.sakkinen@linux.intel.com> <20191129231326.18076-13-jarkko.sakkinen@linux.intel.com> Date: Mon, 02 Dec 2019 09:48:43 -0600 MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: "Haitao Huang" Organization: Intel Message-ID: In-Reply-To: <20191129231326.18076-13-jarkko.sakkinen@linux.intel.com> User-Agent: Opera Mail/1.0 (Win32) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, 29 Nov 2019 17:13:14 -0600, Jarkko Sakkinen wrote: > + > + for (c = 0 ; c < addp.length; c += PAGE_SIZE) { > + if (signal_pending(current)) { > + ret = -ERESTARTSYS; > + break; > + } This IOC is not idempotent as pages EADDed at this point can not be re-EADDed again. So we can't return ERESTARTSYS Haitao