Received: by 10.213.65.68 with SMTP id h4csp1138774imn; Wed, 14 Mar 2018 10:42:34 -0700 (PDT) X-Google-Smtp-Source: AG47ELsflWti4Sihg2BmVuP67IpWlkqX6RVlUUnqf21U0CDafyo2cXCEIrLkm3wkXtKDsDYNapjd X-Received: by 10.98.82.144 with SMTP id g138mr4989243pfb.239.1521049354223; Wed, 14 Mar 2018 10:42:34 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1521049354; cv=none; d=google.com; s=arc-20160816; b=lcoYTccc5eu41iBW++454aNB/zbIOk/6cFrt94UBppjMyn8KbbuexIJlOdvqALI5Jw xGyUnILvp/TeQ7lUrW/UXcqzLDy4yqTyOZGMXSXkr0zyMbuf3McfII9OllcFNAOHXbf1 qYLX+m9LF8cR435anEzoE6Lb2R8SYtSM5O4pdu+B25ZhHGdNTNFRGnkzstqr8XDShEDy n70EM7HTORvahVkUOW4pe+ED3djCYWxnwe4FwM1OR1abgiLvFLzlB7cSz/ntwGb9MBo6 E9AsJYSpBxvVz0orF6kchLZvGcG5WTYbM/wnASoIfARw9iR9i+UCZCVaZ4xK7cD2MyMp l/wQ== 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 :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:arc-authentication-results; bh=G3PqjieP7U8fVvTe+KfA5JPRBqrlD/w0RG/T45YExqE=; b=xSFVgIt+5kHhVIrCCd50D2e0amDpCm2pRF+4g6vizx+14F93ixAkJ9Qlo+YfH/2c4b 6jfyvGs/eVGXupk/wlb3OwgtsYqC4yvFkz7p2idNWqbr72mNp644YYEKb/FGWs+vt7Dg u63Ifte6786aTIyoOYWpmsaRKaa4iy2/yAAGpXckMXkuSKxnQWmtPrddNJFKhqCgyBrS D/1e4EA8DB1T/9OQjRXjqezTAvlZ5qsKON+Z2RZfq6MAyqR9M/uXqFsID7cj4Z6zV9mA w/6ObO70ARJfUexj1q5X7RYpb0fPTvzc94tSZHnsR64nKUC3zl/Udt57ELgTnzvikr9+ nR3g== 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id b72si2463758pfk.10.2018.03.14.10.42.20; Wed, 14 Mar 2018 10:42:34 -0700 (PDT) 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752131AbeCNRlK (ORCPT + 99 others); Wed, 14 Mar 2018 13:41:10 -0400 Received: from mail.skyhub.de ([5.9.137.197]:36152 "EHLO mail.skyhub.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752071AbeCNRlG (ORCPT ); Wed, 14 Mar 2018 13:41:06 -0400 X-Virus-Scanned: Nedap ESD1 at mail.skyhub.de Received: from mail.skyhub.de ([127.0.0.1]) by localhost (blast.alien8.de [127.0.0.1]) (amavisd-new, port 10026) with ESMTP id GcROQCRMqiXU; Wed, 14 Mar 2018 18:40:49 +0100 (CET) Received: from pd.tnic (p200300EC2BC98E000DB0D181F40EDD09.dip0.t-ipconnect.de [IPv6:2003:ec:2bc9:8e00:db0:d181:f40e:dd09]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.skyhub.de (SuperMail on ZX Spectrum 128k) with ESMTPSA id 3ACEC1EC05E2; Wed, 14 Mar 2018 18:40:49 +0100 (CET) Date: Wed, 14 Mar 2018 18:40:27 +0100 From: Borislav Petkov To: "Prakhya, Sai Praneeth" Cc: "linux-efi@vger.kernel.org" , "linux-kernel@vger.kernel.org" , Chun-Yi Lee , "Luck, Tony" , Will Deacon , "Hansen, Dave" , Mark Rutland , Bhupesh Sharma , "Neri, Ricardo" , "Shankar, Ravi V" , Matt Fleming , "Zijlstra, Peter" , Ard Biesheuvel , "Williams, Dan J" Subject: Re: [PATCH V2 2/3] efi: Introduce efi_rts_workqueue and some infrastructure to invoke all efi_runtime_services() Message-ID: <20180314174027.GF16605@pd.tnic> References: <1520292190-5027-1-git-send-email-sai.praneeth.prakhya@intel.com> <1520292190-5027-3-git-send-email-sai.praneeth.prakhya@intel.com> <20180307121047.GG23662@pd.tnic> <20180308140830.GE21166@pd.tnic> <20180309111157.GC10753@pd.tnic> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.9.3 (2018-01-21) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sat, Mar 10, 2018 at 12:33:35AM +0000, Prakhya, Sai Praneeth wrote: > Although the discussions were off my understanding, the present issue > I see is, (and also the motivation for me to do the patch is) when a > thread tries to execute any efi_runtime_service() we switch to efi_pgd > (which doesn't have user space mappings) and all other subsystems in > kernel aren't aware of this switch. This looks like a perfect case for > kthread. That's all fine and good but you need to be prepared and handle properly an NMI while EFI is running. I have no clue whether the platform delays delivery of NMIs during EFI runtime services or whatever happens but you need to have all those cases covered so that no monkey business happens. Thx. -- Regards/Gruss, Boris. Good mailing practices for 400: avoid top-posting and trim the reply.