Received: by 2002:a05:6a10:2726:0:0:0:0 with SMTP id ib38csp2267290pxb; Sat, 2 Apr 2022 23:44:33 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxRd5ShmtMpXBtMTeVjxWvPE4MhlVwDuN2vdJv3PxzFpMvSljTuFx9zxvE0jkOFEQKjqDYa X-Received: by 2002:a50:9358:0:b0:41c:bcf0:3a95 with SMTP id n24-20020a509358000000b0041cbcf03a95mr2951072eda.20.1648968273180; Sat, 02 Apr 2022 23:44:33 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1648968273; cv=none; d=google.com; s=arc-20160816; b=Oe2xbI5CWvK67541zVoVaeKDmnOZcTg9kiddaE0sicINhcXNuy6Cv+o8CYUOMlxSWF s8lDe0joZQ//PXWAfJy3gErtvgeswy27b4SyrVizgLXdawQFWB1LjJIi3cQYQfXqk8r6 GXV4i87BZW59GHBqJrFqOz9Fwtwy172MMBe6Iz0jpQjW9VxB4C7jjnphEpePH+uEcAXA 709aauL25Pd9LgQ+k0sJhv6FjUX3fH3leaDHRPjP9yLvQoDuvnhO6J900ROK1fZSOCkg Ys/TuuOZ0iebAIxa1Tv7mn3hKVso1ToJbEbv/v+6zCLDZrO2PEItB202jUOA2hw+wV4O JBNw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-transfer-encoding :content-disposition:mime-version:references:message-id:subject:cc :to:from:dkim-signature:dkim-signature:date; bh=SyRunJIttOSoKPtRPHVIrqd1pxkb0TjVve+voxhbD10=; b=Wh8zBg6QzULa0O/XTKgp7ZfbF6EU0kulDYnojamoKAaYvE3apfQil0KNmShQN7aisK jvI83qGWVf/L7CVBaem6rEPaQlFdXg7LTl72JLFWZwMxEjSLneL3HFQiW0G4ZMArvV5h M0EWtOYjHv8RnuCDrPJzKIiLDuRhQ8vS8wKO9oQx33O8Nb+vfbxlzycDvmR2NzKZPCoZ gj2BpS9HEm1KAZSZ4P35UUmTJVNz2ZRr7WX3AIihFV2clw2S4xbT0162hoGGwMkmk8bX 0p9RboqWkhSi9a79w7FiQ3zcBCXAZRhOV+qzgEJNnOGsXNW9Fi/QZtNOUFtOI+PMtumR mWdQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=Kb6NtKDn; dkim=neutral (no key) header.i=@linutronix.de header.b=uWFmRx5t; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id c10-20020a50cf0a000000b00418c2b5bd35si4677862edk.23.2022.04.02.23.43.45; Sat, 02 Apr 2022 23:44:33 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=Kb6NtKDn; dkim=neutral (no key) header.i=@linutronix.de header.b=uWFmRx5t; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S240716AbiCaTaz (ORCPT + 99 others); Thu, 31 Mar 2022 15:30:55 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38944 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S240705AbiCaTax (ORCPT ); Thu, 31 Mar 2022 15:30:53 -0400 Received: from galois.linutronix.de (Galois.linutronix.de [193.142.43.55]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9975F21244; Thu, 31 Mar 2022 12:29:04 -0700 (PDT) Date: Thu, 31 Mar 2022 21:29:01 +0200 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1648754942; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=SyRunJIttOSoKPtRPHVIrqd1pxkb0TjVve+voxhbD10=; b=Kb6NtKDnhx71zz0GNRf097nKYq6nD1t7B3ApI8gUlJpzEqWyM/bVV04hZFHUhd66cgwkkB s5QzvQIF4+pXqVYxkIopLCiEhvVpiw/vLG+43VyDaLWf0CQInoDz8VJFu9YkNwEkfJrbFX rrwCCl7DxjIcb9N/o6dHp0vGghmY6cd6YkZGtHAqGWKUHvYa6ZfDLNy48EBbJZk9VB4sbz 6S6OPPGD6o9tRtxWQRMDTv4ENqC9Bbh7ggeByeklACXiFLxlasYMtZfrKCqaxJIK4W+V6l euVywUCvpP/kzuk9vAlsY/uvtevd5a0llcjqeOysKcu1Gk32esIxCo6Zae0H8A== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1648754942; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=SyRunJIttOSoKPtRPHVIrqd1pxkb0TjVve+voxhbD10=; b=uWFmRx5ti2WzkyyQpub6TqK7NwdfLKb6opOH0V23cijzXiMLlrEA+HR0IUlKfLppY7UdjY Hqhkzoo4hWHiWNCQ== From: "Ahmed S. Darwish" To: Ard Biesheuvel Cc: Javier Martinez Canillas , Linux Kernel Mailing List , linux-efi , Brian Masney , Sebastian Andrzej Siewior , Al Stone , Peter Robinson , Robbie Harwood , Peter Jones , Alexander Larsson , Andrew Halaney , linux-rt-users@vger.kernel.org, Thomas Gleixner Subject: Re: [PATCH v2] efi: Allow to enable EFI runtime services by default on RT Message-ID: References: <20220331151654.184433-1-javierm@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED,SPF_HELO_NONE, SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Ard, Javier, Am Do, Mar 31, 2022, schrieb Ard Biesheuvel: > On Thu, 31 Mar 2022 at 17:17, Javier Martinez Canillas > wrote: > > > > Commit d9f283ae71af ("efi: Disable runtime services on RT") disabled EFI > > runtime services by default when the CONFIG_PREEMPT_RT option is enabled. > > > > The rationale for that commit is that some EFI calls could take too much > > time, leading to large latencies which is an issue for Real-Time kernels. > > > > But a side effect of that change was that now is not possible anymore to > > enable the EFI runtime services by default when CONFIG_PREEMPT_RT is set, > > without passing an efi=runtime command line parameter to the kernel. > > > > Instead, let's add a new EFI_DISABLE_RUNTIME boolean Kconfig option, that > > would be set to n by default but to y if CONFIG_PREEMPT_RT is enabled. > > > > That way, the current behaviour is preserved but gives users a mechanism > > to enable the EFI runtimes services in their kernels if that is required. > > For example, if the firmware could guarantee bounded time for EFI calls. > > > > Also, having a separate boolean config could allow users to disable the > > EFI runtime services by default even when CONFIG_PREEMPT_RT is not set. > > > > Reported-by: Alexander Larsson > > Fixes: d9f283ae71af ("efi: Disable runtime services on RT") > > Signed-off-by: Javier Martinez Canillas > > --- > > > > Changes in v2: > > - Improve commit description to make clear the motivation for the change > > (Sebastian Andrzej Siewior). > > > > This looks ok to me. I'll queue this up once the merge window closes. > In case of (CONFIG_PREEMPT_RT=y && CONFIG_EFI_DISABLE_RUNTIME=n), shouldn't we add a small message in the kernel log warning that EFI runtime services are enabled for the RT kernel? In almost all HW, except custom ones with "verified" firmware, such a warning would be useful... This is especially true since in the embedded domain, manually-configured RT kernels are almost always the norm. Thanks, -- Ahmed S. Darwish Linutronix GmbH | Bahnhofstrasse 3 | D-88690 Uhldingen-M?hlhofen Phone: +49 7556 25 999 31; Fax.: +49 7556 25 999 99 Hinweise zum Datenschutz finden Sie hier (Informations on data privacy can be found here): https://linutronix.de/kontakt/Datenschutz.php Linutronix GmbH | Firmensitz (Registered Office): Uhldingen-M?hlhofen | Registergericht (Registration Court): Amtsgericht Freiburg i.Br., HRB700 806 | Gesch?ftsf?hrer (Managing Directors): Heinz Egger, Thomas Gleixner