Received: by 2002:a05:6a10:2726:0:0:0:0 with SMTP id ib38csp1431811pxb; Fri, 1 Apr 2022 13:20:37 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwDKBi7xk9wOTtdv18H0mvRiBXtUy9CdS/Xzn2lqvDE8m5JRG1zxfhCzS1TKAtSLLAdh2nx X-Received: by 2002:aa7:81ca:0:b0:4f6:d297:4213 with SMTP id c10-20020aa781ca000000b004f6d2974213mr46228640pfn.59.1648844436880; Fri, 01 Apr 2022 13:20:36 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1648844436; cv=none; d=google.com; s=arc-20160816; b=hLgLjwXlS9Q7TScVHP1F6cmq8mOQ8bZfe1yydB1rG2m7GxSV/mbPOuu9oUM3VnENzO 8UnFuXoaxPxqDQKE/JfRQLjvL4RsHwQ0i5fUnpsJaqDNbbNeiUDHdeyScgSHVJQuHF1f M1GQ25yrYbPKBys6U3BFttaAeJBsmWKn2O+A9emtXHNbmlk6d9/nH4UN8gGr/jQH4fVH W+mwcIVqjn7xUMRbTjIscTPo9eOjm4D8VRJ5rRLqzUE/hTU5TcQ9OVtfBRSQOMpwVbZO kFjUgWaTFMGONTsLOKpwG6Q0dVSbBx7XrO/OjUwn1w66V4Jc5A2deABmGfzao1l2nGtI SJ9A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:cc:to:content-language:subject:user-agent:mime-version :date:message-id:dkim-signature; bh=oJBsoW1uyBTrmZS6VG/0HyJLaUmX1rPmn4glzAwDgC0=; b=0pN1jwz1jroAzwfgOJZWlcRKfF9OfGDcCvSqNK0Bh2eZeo4BNrU6QkSywOniBD9BFx FIyOhhhaxJKQQq1rMNeYlqVeHd2+dDTDxdpyqk3weRPXD19PBzBe5a9WgPuiUD16jtLV cIsDLtwiFQWwphwqG4011ibhBSu2kMyWSHd9Zq7y+ubC+qtTIpw0phcqaYqlLxjMFIcl PMEmfrYgV/Hdr+q95Tb274ZvBep7tFX9TncMIQsei5wSPT+BMg1QrR+xFmlF+BRsjcOW b0XflwuF0S+886SP7DobZr+g7CVP5wHDRZPI2ero2ocIbAbubspp/dN0mow48OK4fXzX SFlQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b="CUEA/rpt"; 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=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id y29-20020a634b1d000000b003821d32f04csi3372912pga.116.2022.04.01.13.20.22; Fri, 01 Apr 2022 13:20:36 -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=@redhat.com header.s=mimecast20190719 header.b="CUEA/rpt"; 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=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S243971AbiDAIex (ORCPT + 99 others); Fri, 1 Apr 2022 04:34:53 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60000 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S243139AbiDAIev (ORCPT ); Fri, 1 Apr 2022 04:34:51 -0400 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 99F7C673E0 for ; Fri, 1 Apr 2022 01:33:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1648801981; 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=oJBsoW1uyBTrmZS6VG/0HyJLaUmX1rPmn4glzAwDgC0=; b=CUEA/rpt1nziY6kVw+lAoipdezCJ/uiFDKmR6GjK9TA85GOWgp5BKbwspQ9lrGbg+dBBrr odZjgT6VyT9yKiNkmDWCg+ZlgbsV7MTVqWmM0Lqzzh84rG9MAxsAczrvPUyCqLSgsh5ovF RpeiT9r8u8qvv49QF5sp10To8sgqfEo= Received: from mail-wm1-f70.google.com (mail-wm1-f70.google.com [209.85.128.70]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-98-UQXCITluOKKfl0U_2fKL7A-1; Fri, 01 Apr 2022 04:33:00 -0400 X-MC-Unique: UQXCITluOKKfl0U_2fKL7A-1 Received: by mail-wm1-f70.google.com with SMTP id 9-20020a05600c240900b0038c99b98f6fso904576wmp.0 for ; Fri, 01 Apr 2022 01:33:00 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:message-id:date:mime-version:user-agent:subject :content-language:to:cc:references:from:in-reply-to :content-transfer-encoding; bh=oJBsoW1uyBTrmZS6VG/0HyJLaUmX1rPmn4glzAwDgC0=; b=aZsln/cE3WoLzUIY+tjjhfMw3BG7nO2X2FnMBpkOlmR3N2cHIUo/0kJxFhVGOqHhHC xx4vkCSN7JNz37q4QhSoQ37X41EzeWYjVNNfFRhexm+Qg/LRU9o0GEE06EUxUNhXB1O3 OYwFGasmi5PLrHMjffEbZfl/Iq3gH7/PCS0+20l/KwIaAB4Y0594S3omnk5OfEliLobe SuYq9XepHm7Nh7H/KLBt56eijeIgfq8z72rD4oUqo3F6diIyYiPtyJK3iS7lwqGys9z3 gj8S/dGJNtXB/60sbCHr2F1VrFTVArsGzfLUiUh7O8RR6mattL7KN3MFYuGGwRt8TEt8 DKVw== X-Gm-Message-State: AOAM531zfmvaHeqwF8o5eb+lm8OaujO692Dl/2qdEDAf6fRM0cLjE0yO lX4z4t5WXwCD/uDvjmTpicEgxmM3EY+WMrBJOQ0SiKrLDLKab54vNLaOLZ585Zs85UEjdkqd1Gt 9t0mDALGYIn4EFMthPFT2h1iE X-Received: by 2002:a5d:64aa:0:b0:204:1c8a:51e9 with SMTP id m10-20020a5d64aa000000b002041c8a51e9mr6944109wrp.314.1648801979058; Fri, 01 Apr 2022 01:32:59 -0700 (PDT) X-Received: by 2002:a5d:64aa:0:b0:204:1c8a:51e9 with SMTP id m10-20020a5d64aa000000b002041c8a51e9mr6944091wrp.314.1648801978840; Fri, 01 Apr 2022 01:32:58 -0700 (PDT) Received: from [192.168.1.102] ([92.176.231.205]) by smtp.gmail.com with ESMTPSA id b3-20020adfd1c3000000b00205820686dasm1788397wrd.5.2022.04.01.01.32.57 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Fri, 01 Apr 2022 01:32:58 -0700 (PDT) Message-ID: <78a0360d-1a27-5280-10bf-d27d1d306fa5@redhat.com> Date: Fri, 1 Apr 2022 10:32:56 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.7.0 Subject: Re: [PATCH v2] efi: Allow to enable EFI runtime services by default on RT Content-Language: en-US To: Sebastian Andrzej Siewior Cc: "Ahmed S. Darwish" , Ard Biesheuvel , Linux Kernel Mailing List , linux-efi , Brian Masney , Al Stone , Peter Robinson , Robbie Harwood , Peter Jones , Alexander Larsson , Andrew Halaney , linux-rt-users@vger.kernel.org, Thomas Gleixner References: <20220331151654.184433-1-javierm@redhat.com> From: Javier Martinez Canillas In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-2.8 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A, RCVD_IN_DNSWL_LOW,RCVD_IN_MSPIKE_H5,RCVD_IN_MSPIKE_WL,SPF_HELO_NONE, SPF_NONE,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 Hello Sebastian, On 4/1/22 09:42, Sebastian Andrzej Siewior wrote: > On 2022-04-01 00:19:57 [+0200], Javier Martinez Canillas wrote: >>> 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 >> >> I considered that as well but was not sure about what that message should be. > > This makes sense and we had this in the past but dropped it for some > reason. > Ok, something like the following maybe? If you agree, I'll squash in v3: diff --git a/drivers/firmware/efi/efi.c b/drivers/firmware/efi/efi.c index ff57db8f8d05..08d329a5179b 100644 --- a/drivers/firmware/efi/efi.c +++ b/drivers/firmware/efi/efi.c @@ -362,6 +362,8 @@ static int __init efisubsys_init(void) if (!efi_enabled(EFI_RUNTIME_SERVICES)) efi.runtime_supported_mask = 0; + else if (IS_ENABLED(CONFIG_PREEMPT_RT)) + pr_warn("EFI runtime services can lead to high latencies on Real-Time kernels\n"); if (!efi_enabled(EFI_BOOT)) return 0; >> Since it will be printed even on systems whose EFI firmwares do not >> have such long call times as the ones described in the commit that >> disabled the runtime services for RT. >> >> And in that case the warning may be misleading and make users believe >> that a problem exists, which might not be accurate. > > Does this matter? The efi-rtc driver is known to cause latencies but it > does not happen if the driver is not used. The same is probably true for > efi-vars: It won't cause high latencies on _read_ but then a certain > number of bit flips during read _may_ lead to write+erase which will > cause higher latencies. > Having a warning at boot (similar to trace_printk's warning) with the > options listed that are known to case high latencies might be a help. > There are some options that nobody will argue about like LOCKDEP. Then > there are other like WATCHDOG or this one, where a debate might start ;) > Yes, you are correct. >> Best regards, >> Javier > > Sebastian > -- Best regards, Javier Martinez Canillas Linux Engineering Red Hat