From mboxrd@z Thu Jan 1 00:00:00 1970 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 4597DC433F5 for ; Fri, 22 Apr 2022 09:17:22 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1379055AbiDVJUM (ORCPT ); Fri, 22 Apr 2022 05:20:12 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35390 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S244072AbiDVJTx (ORCPT ); Fri, 22 Apr 2022 05:19:53 -0400 Received: from sin.source.kernel.org (sin.source.kernel.org [145.40.73.55]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0977254BFE; Fri, 22 Apr 2022 02:15:39 -0700 (PDT) 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 sin.source.kernel.org (Postfix) with ESMTPS id 57E5FCE27DC; Fri, 22 Apr 2022 09:15:37 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 007E2C385A0; Fri, 22 Apr 2022 09:15:34 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1650618935; bh=wphSIBvr7Ma1//woXk0Uh+SjFy5kCgM83/jgyso856g=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=IadMM0AGGhNeQrUn/BzUo032y3FpRxAXbWOAnYyGSZ4U/UaIalbYvgke7dE/w9SS9 8Edg1emCkaYqz1ZxEnnQqH+Ij38F9deMsfJSLZzSveltvIZPY6W0/JlyrL8pfBMxuC cC7aMkIi9MNJby/Y30//y1eP2/ZBWfzlRVDiEKcSUDFbQVpXn1SW9ufiQ/CL4Jml0x AkD5KAbWPUa/l0RSqIf1wYF5HUi3p2rir4fCNREQ4dcmikbru5PhBmsWJra1MvHUIA BjayHV3xMzl46U41OFqHXjpP5Nq1X2f915A/abqMbofunwKpHp3RfBeeSIZ4NDdqZh 7QlBwycZpGD8g== Date: Fri, 22 Apr 2022 12:14:20 +0300 From: Jarkko Sakkinen To: "Dhanraj, Vijay" Cc: "Chatre, Reinette" , "dave.hansen@linux.intel.com" , "tglx@linutronix.de" , "bp@alien8.de" , "Lutomirski, Andy" , "mingo@redhat.com" , "linux-sgx@vger.kernel.org" , "x86@kernel.org" , "shuah@kernel.org" , "linux-kselftest@vger.kernel.org" , "Shanahan, Mark" , "Christopherson,, Sean" , "Huang, Kai" , "Zhang, Cathy" , "Xing, Cedric" , "Huang, Haitao" , "hpa@zytor.com" , "linux-kernel@vger.kernel.org" Subject: Re: [PATCH V4 00/31] x86/sgx and selftests/sgx: Support SGX2 Message-ID: References: <2f4338f37943c2b067db16ae65c9af665d3b51d9.camel@kernel.org> <9fbf26c8-5808-20c5-8653-d4f36bf398a4@intel.com> <42a52a6018e8dadb4c3eebefaae4dab31c0d5721.camel@kernel.org> <54f053d8bb6b72725b2351fc2016d20b65cebbf1.camel@kernel.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Apr 21, 2022 at 11:46:57PM +0000, Dhanraj, Vijay wrote: > Hi All, > > I evaluated V4 patch changes with Gramine and ran into an issue when > trying to set EPC page permission to PROT_NONE. It looks like with V3 > patch series a change was introduced which requires kernel to have at > least R permission when calling RESTRICT IOCTL. This change was done > under the assumption that EPCM requires at least R permission for > EMODPE/EACCEPT to succeed. But when testing with V2 version, EACCEPT > worked fine with page permission set to PROT_NONE. > > Thanks to @Shanahan, Mark for confirming that EPCM does not need to have > R value to allow EACCEPT or EMODPE. Given this, can we please revert this > change? > > Thanks, > -Vijay Let's try to avoid top-posting and split the lines appropriately. BR, Jarkko