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 X-Spam-Level: X-Spam-Status: No, score=-6.3 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, NICE_REPLY_A,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_SANE_1 autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 400B0C433DF for ; Wed, 29 Jul 2020 17:57:30 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 06DEF2075D for ; Wed, 29 Jul 2020 17:57:30 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="dNpT8K/H"; dkim=fail reason="signature verification failed" (1024-bit key) header.d=linux.microsoft.com header.i=@linux.microsoft.com header.b="ET55hxg/" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 06DEF2075D Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=linux.microsoft.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.20170209; h=Sender:Content-Transfer-Encoding: Content-Type:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:Date:Message-ID:From: References:To:Subject:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=oiJcAFZBPDLubVU0i8tRukEKC4gITs29uHjuUxBBmpA=; b=dNpT8K/HW+lG1GCIq0qN13Cuo reVgmAYXZxvSGE8UflHBL+n4V6tMh/1ywdgmWqFJynsBBDag9XgtPQrdGTK3Iqr8tUMfcYteTifC6 CXhdTktVKb37wPBeBcok9TxLZmSHHEwtSCriemmbSzi7s+kWVxwTyw0ee1HIoz19Hj8+CpzCfF3ks farWYI39CQ+aSXiibYx8rJX9Vuu8FB6bgw1BLMgEAzLBf1oPc7Mh4dQ8CT2bzY2367W1ccx1nW1dH MycbdMlIa0L/gha+FcUAbKLzFKS5HHsyznHzv5cVDfaUDHjhKp+Tu+JYZndRDwxR8lom8fzIJ81Pt TEepLnINA==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1k0qJ2-0005Iv-TE; Wed, 29 Jul 2020 17:55:56 +0000 Received: from linux.microsoft.com ([13.77.154.182]) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1k0qJ1-0005Hx-3B for linux-arm-kernel@lists.infradead.org; Wed, 29 Jul 2020 17:55:55 +0000 Received: from [192.168.254.32] (unknown [47.187.206.220]) by linux.microsoft.com (Postfix) with ESMTPSA id F0E4120B4908; Wed, 29 Jul 2020 10:55:51 -0700 (PDT) DKIM-Filter: OpenDKIM Filter v2.11.0 linux.microsoft.com F0E4120B4908 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.microsoft.com; s=default; t=1596045352; bh=Nh1awxv8sYMWjyBdKzptNt/99nJiurbGvK4nLo6gXvU=; h=Subject:To:Cc:References:From:Date:In-Reply-To:From; b=ET55hxg/DBtDrPqMLvEgwflc/o1gjQ4X7Oa3dCnjuCAMmZs7sULLK5HNN8WxJb0i5 0ANYiCsQDqTi6GijyuIZbLq/tNbFUvpAB5eayNWW4/qmE/6W3Ct1DOBfa73pb1uSap kv37tbx4EFhfNrjIQ8YdBDHjoOhsdUZVP47hnYG0= Subject: Re: [PATCH v1 0/4] [RFC] Implement Trampoline File Descriptor To: David Laight , Andy Lutomirski References: <20200728131050.24443-1-madvenka@linux.microsoft.com> <59246260-e535-a9f1-d89e-4e953288b977@linux.microsoft.com> From: "Madhavan T. Venkataraman" Message-ID: <98aa9d5e-6eb4-de29-2fc2-06f6dc52086f@linux.microsoft.com> Date: Wed, 29 Jul 2020 12:55:51 -0500 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0 MIME-Version: 1.0 In-Reply-To: Content-Language: en-US X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20200729_135555_217388_5A220D3E X-CRM114-Status: GOOD ( 16.81 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: "kernel-hardening@lists.openwall.com" , "linux-api@vger.kernel.org" , "x86@kernel.org" , "linux-kernel@vger.kernel.org" , "oleg@redhat.com" , "linux-security-module@vger.kernel.org" , "linux-fsdevel@vger.kernel.org" , "linux-integrity@vger.kernel.org" , "linux-arm-kernel@lists.infradead.org" Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On 7/29/20 3:36 AM, David Laight wrote: > From: Madhavan T. Venkataraman >> Sent: 28 July 2020 19:52 > ... >> trampfd faults are instruction faults that go through a different code path than >> the one that calls handle_mm_fault(). Perhaps, it is the handle_mm_fault() that >> is time consuming. Could you clarify? > Given that the expectation is a few instructions in userspace > (eg to pick up the original arguments for a nested call) > the (probable) thousands of clocks taken by entering the > kernel (especially with page table separation) is a massive > delta. > > If entering the kernel were cheap no one would have added > the DSO functions for getting the time of day. I hear you. BTW, I did not say that the overhead was trivial. I only said that in most cases, applications may not mind that extra overhead. However, since multiple people have raised that as an issue, I will address it. I mentioned before that the kernel can actually supply the code page that sets the context and jumps to a PC and map it so the performance issue can be addressed. I was planning to do that as a future enhancement. If there is a consensus that I must address it immediately, I could do that. I will continue this discussion in my reply to Andy's email. Let us pick it up from there. Thanks. Madhavan > > David > > - > Registered Address Lakeside, Bramley Road, Mount Farm, Milton Keynes, MK1 1PT, UK > Registration No: 1397386 (Wales) _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel