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 A4722ECAAD2 for ; Thu, 1 Sep 2022 23:58:44 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232670AbiIAX6o (ORCPT ); Thu, 1 Sep 2022 19:58:44 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45624 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230151AbiIAX6m (ORCPT ); Thu, 1 Sep 2022 19:58:42 -0400 Received: from ams.source.kernel.org (ams.source.kernel.org [145.40.68.75]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7AD2B6C763; Thu, 1 Sep 2022 16:58:41 -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 ams.source.kernel.org (Postfix) with ESMTPS id 0D7A9B82897; Thu, 1 Sep 2022 23:58:40 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 555F3C433C1; Thu, 1 Sep 2022 23:58:38 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1662076718; bh=8N8RRa/GUsmMMJuIufQYY+tMakpxVYzcByXjf3hVKfg=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=eEOR2R0Oh4Tx7xDq6t+t/oUttp3mkFtlyOG6WTlSWJuUwQF+yfwRKHq/bVhcj9TsG R/nFV1uNANlEKiCHrm13ruZVkVKM99L78SFqU2m1SrtPCTcdVKSTBbIQURb61zFKCf aQTkiPDKWuxoTwTe3TTFBFgJGCUr1JwPQ8z38ttL8aR9cLvj0yAEkJTLNWVLW/6TQi aZywYFHvj75Fk061U4RX+ELa9RkserETF8eZyijJSt8As2sAGP06+EnmDNydVJsMRW lPeLJ5UpSFLbQ/62IoOlQGXh2rZvO+hfvzP+ctk+NGjsl7WTX6mTe0u31Ka0kodHAR biRN3Six6o7Zw== Date: Fri, 2 Sep 2022 02:58:34 +0300 From: "jarkko@kernel.org" To: "Huang, Kai" Cc: "pmenzel@molgen.mpg.de" , "Hansen, Dave" , "linux-sgx@vger.kernel.org" , "x86@kernel.org" , "dave.hansen@linux.intel.com" , "Dhanraj, Vijay" , "Chatre, Reinette" , "mingo@redhat.com" , "tglx@linutronix.de" , "bp@alien8.de" , "haitao.huang@linux.intel.com" , "hpa@zytor.com" , "linux-kernel@vger.kernel.org" Subject: Re: [PATCH 1/6] x86/sgx: Do not consider unsanitized pages an error Message-ID: References: <94993d90b0b3c59fae61427cf0cc78dd10c381bb.camel@intel.com> 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-sgx@vger.kernel.org On Thu, Sep 01, 2022 at 10:41:54PM +0000, Huang, Kai wrote: > On Fri, 2022-09-02 at 01:27 +0300, jarkko@kernel.org wrote: > > On Wed, Aug 31, 2022 at 08:42:59PM +0000, Huang, Kai wrote: > > > On Wed, 2022-08-31 at 11:35 -0700, Dave Hansen wrote: > > > > Jarkko, Kai and Haitao, > > > > > > > > Can you three please start trimming your replies? You don't need to and > > > > should not quote the entirety of your messages every time you reply. > > > > > > > > On 8/31/22 11:28, jarkko@kernel.org wrote: > > > > > > Will it cause racing if we expose dev nodes to user space before > > > > > > ksgxd is started and sensitization done? > > > > > I'll to explain this. > > > > > > > > > > So the point is to fix the issue at hand, and fix it locally. > > > > > > > > > > Changing initialization order is simply out of context. It's > > > > > not really an argument for or against changing it > > > > > > > > > > We are fixing sanitization here, and only that with zero > > > > > side-effects to any other semantics. > > > > > > > > > > It's dictated by the development process [*] but more > > > > > importantly it's also just plain common sense. > > > > > > > > Kai, I think your suggestion is reasonable. You make a good point about > > > > not needing ksgxd for vepc. > > > > > > > > *But*, I think it's a bit too much for a bugfix that's headed to > > > > -stable. I'm concerned that it will have unintended side effects, > > > > *especially* when there's a working, tested alternative. > > > > > > Agreed. Thanks Dave/Jarkko. > > > > Please do a patch. It's a very reasonable suggestion when > > considered out of context of this bug. > > > > If you go really rigid with this, the compilation process > > should not compile in sanitization process in the case when > > only vepc is enabled. It's useless functionality in that > > case. > > > > BR, Jarkko > > Yeah I am planning to work out one to see how it goes. Looking forward to try it out :-) BR, Jarkko