Received: by 2002:a05:7412:a9a2:b0:e2:908c:2ebd with SMTP id o34csp1452514rdh; Fri, 27 Oct 2023 15:06:18 -0700 (PDT) X-Google-Smtp-Source: AGHT+IHNe/NpD7ODIX6hIQ07Tzi2uGgnS/UKKZFZ1xQz/YqhDzVoD88Kz/j61got9n3+2J69XJFh X-Received: by 2002:a25:cf51:0:b0:d9a:f7dc:d8c3 with SMTP id f78-20020a25cf51000000b00d9af7dcd8c3mr3777060ybg.15.1698444378337; Fri, 27 Oct 2023 15:06:18 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1698444378; cv=none; d=google.com; s=arc-20160816; b=JAxCe1ddkho5ezCCnDEzqvOz2raIdKFq/VdoRfQbnXQDWQGBbqxfyGJHBsCOxpvR3M H4H7WlpI2zJRdnmiz76FTIk4tyke/LDbRMgcIPq+X03T4+B5xnbShD4a1Um5dvytAgwP jnfYfr2meVh6KbFqxbGlGSpMr/g8gnrhrAkCgpVE8q0qUU2yPTmzZg8yBPPUEvG+MVg/ TVchUjIorEXxWXA8PjXpIkeR90fVHB7vITnmDeSiD+d8wsjPu4NMIIxxLaq10GY0EWtN rM798zVzRF9iEZxi7/zEAUagUAuxt9DeAjRJrwUdJJXjDz+S8zBMcrTA5lV1SjKIGh7l Bmww== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=EYCAyHviKNKDeA9zecSwLrqFG76gAM2TWOZ+GOqwprM=; fh=Xn5nprqnnoF3CPXjAJVpIQ5iuNfypbmRsvbbs83BurE=; b=z5DPFPKa0i2rO3peFGlM7JmP703sNhavqd43/3FGrdCs52Bm81WGxShsbRVYaWw58L AyITScgIOj59b/qQRkId/a6XxlP8lAZYzFdK7Siyv8/AAo8eGI17rngT+0vF20wcg3cv AwygwAL+G9sjo1tpHusLmGvNkrGKobMXCrfzteBLUOpoNHsrAuwi4fhZe8x+tK8CUx4Z NMoYWuuI8OTWxca5ntXr8Au2tIgi6B8+zIVjcpEnDe3BP4nY/tdwnWYWpthryEy88rLN 6HfRPbtR42hEugOPeNkKCAi+FacwDC6yKXnGuFM06NaToTovEouoTDeRjW69VATEf+h1 UIKA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@infradead.org header.s=bombadil.20210309 header.b=ftQp63Qn; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:8 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from fry.vger.email (fry.vger.email. [2620:137:e000::3:8]) by mx.google.com with ESMTPS id e15-20020a5b004f000000b00d8680fc836fsi3591531ybp.320.2023.10.27.15.06.17 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 27 Oct 2023 15:06:18 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:8 as permitted sender) client-ip=2620:137:e000::3:8; Authentication-Results: mx.google.com; dkim=pass header.i=@infradead.org header.s=bombadil.20210309 header.b=ftQp63Qn; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:8 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by fry.vger.email (Postfix) with ESMTP id 87CE780C7751; Fri, 27 Oct 2023 15:05:24 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at fry.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1346583AbjJ0WFG (ORCPT + 99 others); Fri, 27 Oct 2023 18:05:06 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57366 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229712AbjJ0WFE (ORCPT ); Fri, 27 Oct 2023 18:05:04 -0400 Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:3::133]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 8378B1A6; Fri, 27 Oct 2023 15:05:01 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=Sender:In-Reply-To:Content-Type: MIME-Version:References:Message-ID:Subject:Cc:To:From:Date:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=EYCAyHviKNKDeA9zecSwLrqFG76gAM2TWOZ+GOqwprM=; b=ftQp63QnPUjq81aj92WyGldhDG +uZzJoJx8Y+FfGFKEnMpjYdKdF471lvIGABRVDIMB9dotIAxQq6cTyOkg1VhKN91dr4KOIJir5NB3 ACKnKI6wxCpOmi54sFBBaOj2u+1ANRXFqgs2Qp+tXJiTKZocKOxsFZLdbSYLwrTwo548kzARdw9fB pkywDDPt2dINpKJODre8NYRHD/agz0gFfAJcGGVyIgnbZPrB1cNn1FK2noDSmB1E/yHDlof8/nY0f F0yL32qof++hnmTAtaJtnPmDO3Q9lQN+4c6x1Fv5LWANlMTLzb9P4uxfhtytmNlppiZHy9IpSFVTS 5UHYYYZg==; Received: from mcgrof by bombadil.infradead.org with local (Exim 4.96 #2 (Red Hat Linux)) id 1qwUwq-00HGYH-0E; Fri, 27 Oct 2023 22:04:56 +0000 Date: Fri, 27 Oct 2023 15:04:56 -0700 From: Luis Chamberlain To: Krister Johansen Cc: Kees Cook , Iurii Zaikin , linux-kernel@vger.kernel.org, linux-fsdevel@vger.kernel.org, Douglas Anderson , Vlastimil Babka , Arnd Bergmann , Lecopzer Chen , Nick Desaulniers , Thomas Gleixner , David Hildenbrand , Masami Hiramatsu , Pingfan Liu , Michael Kelley , Petr Mladek , Andrew Morton , Josh Poimboeuf , "Guilherme G. Piccoli" , Mike Rapoport , Peter Zijlstra Subject: Re: [PATCH 0/2] Triggering a softlockup panic during SMP boot Message-ID: References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Sender: Luis Chamberlain X-Spam-Status: No, score=-1.0 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on fry.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (fry.vger.email [0.0.0.0]); Fri, 27 Oct 2023 15:05:24 -0700 (PDT) On Fri, Oct 27, 2023 at 02:46:26PM -0700, Krister Johansen wrote: > Hi, > This pair of patches was the result of an unsuccessful attempt to set > softlockup_panic before SMP boot. The rationale for wanting to set this > parameter is that some of the VMs that my team runs will occasionally > get stuck while onlining the non-boot processors as part of SMP boot. > > In the cases where this happens, we find out about it after the instance > successfully boots; however, the machines can get stuck for tens of > minutes at a time before finally completing onlining processors. Since > we pay per minute for many of these VMs there were two goals for setting > this value on boot: first, fail fast and hope that a subsequent boot > attempt will be successful. Second, a panic is a little easier to keep > track of, especially if we're scraping serial logs after the fact. In > essence, the goal is to trigger the failure earlier and hopefully get > more useful information for further debugging the problem as well. > > While testing to make sure that this value was getting correctly set on > boot, I ran into a pair of surprises. First, when the softlockup_panic > parameter was migrated to a sysctl alias, it had the side effect of > setting the parameter value after SMP boot has occurred, when it used to > be set before this. Second, testing revealed that even though the > aliases were being correctly processed, the kernel was reporting the > commandline arguments as unrecognized. This generated a message in the > logs about an unrecognized parameter (even though it was) and the > parameter was passed as an environment variable to init. > > The first patch ensures that aliased sysctl arguments are not reported > as unrecognized boot arguments. > > The second patch moves the setting of softlockup_panic earlier in boot, > where it can take effect before SMP boot beings. Sounds all great but I only got the cover letter, so may be resend? Luis