Received: by 2002:a05:6358:1087:b0:cb:c9d3:cd90 with SMTP id j7csp1091125rwi; Mon, 10 Oct 2022 11:03:13 -0700 (PDT) X-Google-Smtp-Source: AMsMyM6gAvDG3hdU28772dyBArsJNgogBP4YY5gwDx0jjuqvKJHb/3Z2UTTq/85tkgZxXl8ScuNG X-Received: by 2002:a17:906:6791:b0:78d:4051:fcf0 with SMTP id q17-20020a170906679100b0078d4051fcf0mr15365189ejp.591.1665424992777; Mon, 10 Oct 2022 11:03:12 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1665424992; cv=none; d=google.com; s=arc-20160816; b=YIQRnfQqqLBWh3wpivyl3KII7Oor9JeerJvDd7/5SLH0g1DLii03ntUTg89TqgKXr6 HHQ2BUO5mUUaE4xZIz6SJi0IcP8EcxRg7sCVR1+IMCXGAqE1VRYoKd1x1Mnd8ZB/eyms v2LBOau6pUtvFwieCo6velMp8Ab0aAlVcxc3P/YYAwmlsFabwi6gwjYQreeE473nU2F2 FGIrbm+53CXOqGzxkGp2ybonR624sQz4JL4wFGmmba3/NZPCW/pnsGSNn0H/kzkjEMNi S0uWft9zpYSN5Vp/yQpen46YqXM9YHv7ZWpbDGkSIwrFCLp5VpGqDXTk/wYJwDv0m9RD dTEw== 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-disposition:mime-version :references:message-id:subject:cc:to:from:date; bh=BNhFyR4UlnCbYP4aqg2o1eZKkrdxpq6VPlHdw3XWBtk=; b=aneezY0ILqWctDQ6araAxDB0hXiaahKrxcaMMEqqfH6iAMKe9E1MIMk6XFqdrYUJXG 3lsZYX+EhESrVOp+nrTl6g9drTjBQlol9BqsZP1Mo/9NlnD5n3ek8xp2mo90T778mYEv BO9Ul07fXuWOKaso6kZLaGXvvGYTY9gHGZdtpqCWcVbrJQ3qGfweUK3Blv2u6QnWNGiD ZEboK/ba5BDSxfz67sY5LeR+AivG3TKUZ8lvv4sHTZPEmomSbKA75y/afN4BD5VUGTKS Iu42Zrp5VbNZSMOItet1vZmDVUswBGN6vwsahxP/9N0/Qf4S9C72LPiBPenOwXsDWFG8 yq3w== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id ds17-20020a170907725100b00782a1b59663si11472213ejc.891.2022.10.10.11.02.45; Mon, 10 Oct 2022 11:03:12 -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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229835AbiJJRuX (ORCPT + 99 others); Mon, 10 Oct 2022 13:50:23 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35420 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229927AbiJJRuH (ORCPT ); Mon, 10 Oct 2022 13:50:07 -0400 Received: from outbound-smtp60.blacknight.com (outbound-smtp60.blacknight.com [46.22.136.244]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D2A1325EB4 for ; Mon, 10 Oct 2022 10:50:01 -0700 (PDT) Received: from mail.blacknight.com (pemlinmail03.blacknight.ie [81.17.254.16]) by outbound-smtp60.blacknight.com (Postfix) with ESMTPS id D1010FADF0 for ; Mon, 10 Oct 2022 18:49:59 +0100 (IST) Received: (qmail 9487 invoked from network); 10 Oct 2022 17:49:59 -0000 Received: from unknown (HELO techsingularity.net) (mgorman@techsingularity.net@[84.203.198.246]) by 81.17.254.9 with ESMTPSA (AES256-SHA encrypted, authenticated); 10 Oct 2022 17:49:59 -0000 Date: Mon, 10 Oct 2022 18:45:26 +0100 From: Mel Gorman To: "Rafael J. Wysocki" Cc: "Rafael J. Wysocki" , linux-rtc@vger.kernel.org, linux-acpi@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: Intermittent boot failure after 6492fed7d8c9 (v6.0-rc1) Message-ID: <20221010174526.3yi7nziokwwpr63s@techsingularity.net> References: <20221010141630.zfzi7mk7zvnmclzy@techsingularity.net> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-15 Content-Disposition: inline In-Reply-To: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,SPF_HELO_NONE, SPF_PASS 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 On Mon, Oct 10, 2022 at 04:47:50PM +0200, Rafael J. Wysocki wrote: > Hi Mel, > > Thanks for the report! > > On Mon, Oct 10, 2022 at 4:25 PM Mel Gorman wrote: > > > > Hi Rafael, > > > > I'm seeing intermittent boot failures after 6492fed7d8c9 ("rtc: rtc-cmos: > > Do not check ACPI_FADT_LOW_POWER_S0") due to a NULL pointer exception > > early in boot. It fails to boot 5 times after 10 boot attempts and I've > > only observed it on one machine so far. Either a revert or the patch below > > fixes it but it's unlikely it is the correct fix. > > > > --- drivers/rtc/rtc-cmos.c.orig 2022-10-10 15:11:50.335756567 +0200 > > +++ drivers/rtc/rtc-cmos.c 2022-10-10 15:11:53.211756691 +0200 > > @@ -1209,7 +1209,7 @@ > > * Or else, ACPI SCI is enabled during suspend/resume only, > > * update rtc irq in that case. > > */ > > - if (cmos_use_acpi_alarm()) > > + if (cmos_use_acpi_alarm() && cmos) > > cmos_interrupt(0, (void *)cmos->rtc); > > else { > > /* Fix me: can we use cmos_interrupt() here as well? */ > > It looks like I've exposed a race condition there. > > Generally speaking, it is misguided to install an event handler that > is not ready to handle the event at that time before making sure that > the event is disabled. > > Does the attached patch help? > It failed 3/10 times. That's less than the previous 5/10 failures but I cannot be certain it helped without running a lot more boot tests. The failure happens in the same function as before. -- Mel Gorman SUSE Labs