Received: by 2002:a6b:fb09:0:0:0:0:0 with SMTP id h9csp5748157iog; Thu, 23 Jun 2022 04:43:04 -0700 (PDT) X-Google-Smtp-Source: AGRyM1vC7jlkWd8QFjGMCukXfzrTpsvwyRTP3Iw9idg6ZZ/vvqkn1eZRuT65U3x50ynYRnDDzW0c X-Received: by 2002:a05:6402:5299:b0:435:61da:9bb9 with SMTP id en25-20020a056402529900b0043561da9bb9mr10159306edb.21.1655984584077; Thu, 23 Jun 2022 04:43:04 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1655984584; cv=none; d=google.com; s=arc-20160816; b=jlKXmLobIpR1mYJ4/0K+k3IQqdNFdz++7vPyq1RdCQ9XbOxX33eMw4FBcZTpearQwB TZ8yFeDHbLcqmGmc3c73UMLd6lncSwEXI+fAi3SPJSDYxTAAfBwaPQgBa5ICi07SF6kV ztUmdd5ePsy22EyP+CC7MDNSw4rcu6h2Q2N+61mNzO9WBy7gUuSo9nOSfaA+kRtdFEtf ifnQ+Ayjxd6/THbk72ufSJpyrO7BnsVcTBrEHq79wyN0B2gcznGk3XUVwifzoO53SHuJ yLPPewfWo+M7q3Oid8d1hF+wN8Tf6T13LpXdfr53AZ7VlRblEsazkosP3oZu6j6RIJgM shiQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:references:in-reply-to:subject:cc:to:from :dkim-signature; bh=pXX1Tci8u6uSkWlCeJ6TegtPSfgMP3wYaXXEz0pOrgM=; b=Hj5o9L/aGCzbME33cl8IgOeZUFLYpFEbDfG3KatBfiVrf8R04GQ6iThcZYtTXF2wwr bu70V7w9hm1falEOHnvT7Jc9lzCelUGcWY9lrQUjPQy8VECutPwgihdsFm5J49zHIYDN LTlbeM59ssImBWp2CtAyvEngauCemD3qjLbZfeR4WK6EgYxh2AO/f9SMJKHMZBaRO1f1 MRiQD5yNmuQ068ZmZLH0H2NKbSeQugQB8K96lKQ02B10tOQ94cfYRxQeQlM8l+B9kstO j0y5GBqpAcTkoyHX/pE2QAufG/tk7c0QRzb1pY/Ld/zzllhuJkNzrAN8uYUhbP60CLwD oknA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=OaZVVip9; 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 s15-20020a056402520f00b0042fafec8901si12619275edd.130.2022.06.23.04.42.38; Thu, 23 Jun 2022 04:43:04 -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=OaZVVip9; 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 S230429AbiFWLkH (ORCPT + 99 others); Thu, 23 Jun 2022 07:40:07 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:55862 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230349AbiFWLkG (ORCPT ); Thu, 23 Jun 2022 07:40:06 -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 F36594BFD6 for ; Thu, 23 Jun 2022 04:40:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1655984404; 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=pXX1Tci8u6uSkWlCeJ6TegtPSfgMP3wYaXXEz0pOrgM=; b=OaZVVip9LN/4AoDZryX9HsRC1xmCNjwx1AvQoBJZKv+ztF/kGJ9W703UZl9bMq3i0F1iiA ty1prNpcnCWCURujDjSvGbxxaFWlNcILTo9RIrUW6ATHn71i2kXPVcBGrq1iYSB2hpkwsZ sqzsqpMRmUkiircDI9dI51cZUwIzAqY= Received: from mail-wm1-f69.google.com (mail-wm1-f69.google.com [209.85.128.69]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-298-upTb53_9P9SB-ChKbmpmgA-1; Thu, 23 Jun 2022 07:40:00 -0400 X-MC-Unique: upTb53_9P9SB-ChKbmpmgA-1 Received: by mail-wm1-f69.google.com with SMTP id p6-20020a05600c358600b0039c873184b9so1302533wmq.4 for ; Thu, 23 Jun 2022 04:40: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:from:to:cc:subject:in-reply-to:references:date :message-id:mime-version:content-transfer-encoding; bh=pXX1Tci8u6uSkWlCeJ6TegtPSfgMP3wYaXXEz0pOrgM=; b=DKS3p6qBOb5bzZ66kWfgJXQZXH8lmoxLhBBr1gUnIFmUv7ts3ApYDUdsYSl30o7M/b L8Gr4Z+1eYzHCoECr7bnJklNiu8GFsyg4yME8egsj2Ee7ogfHun9FWTKodUDoT+UhZBc S5vFlbzjIjGNh3rqafcMniYLxWloGaKLYPgciqYWxlJVVsztnhuyktMXU2R/HLq32uba J+LlfMEFQHy1jHkh5Fy2exxKZA3XXRIeaT82rF80HW+CzKgItQpfK/sxM/Y7xiqT8DIj 5CspbS5RnEb+3cwCIZAfxHEBZ9WaWQPR99z9psXk4MIfL35ounyU+Z8j3iv/lpeb3UL9 hyFw== X-Gm-Message-State: AJIora/UeTSEmADJEbPNT0Lw+jnYXOI7AuCJPs6e/1UTvTYrx/hiuWhG dIVwvzyvQ/ZGYn4YHs1UpCJ3/TXTdCUEqfSN21sd8lg/gMbkMwYtYg5VrKafvlynP7SgmFW2nLl 0wbOgjgSfoiDUZtHI55I3/joR X-Received: by 2002:adf:dece:0:b0:21b:a4b0:f7e3 with SMTP id i14-20020adfdece000000b0021ba4b0f7e3mr4817782wrn.197.1655984399533; Thu, 23 Jun 2022 04:39:59 -0700 (PDT) X-Received: by 2002:adf:dece:0:b0:21b:a4b0:f7e3 with SMTP id i14-20020adfdece000000b0021ba4b0f7e3mr4817761wrn.197.1655984399335; Thu, 23 Jun 2022 04:39:59 -0700 (PDT) Received: from vschneid.remote.csb ([185.11.37.247]) by smtp.gmail.com with ESMTPSA id h30-20020adfaa9e000000b0020c7ec0fdf4sm27013707wrc.117.2022.06.23.04.39.58 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 23 Jun 2022 04:39:58 -0700 (PDT) From: Valentin Schneider To: Sebastian Andrzej Siewior Cc: linux-kernel@vger.kernel.org, kexec@lists.infradead.org, linux-rt-users@vger.kernel.org, Eric Biederman , Arnd Bergmann , Petr Mladek , Thomas Gleixner , Juri Lelli , "Luis Claudio R. Goncalves" Subject: Re: [PATCH v2] panic, kexec: Make __crash_kexec() NMI safe In-Reply-To: References: <20220620111520.1039685-1-vschneid@redhat.com> Date: Thu, 23 Jun 2022 12:39:57 +0100 Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-3.4 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_LOW, SPF_HELO_NONE,SPF_NONE,T_SCC_BODY_TEXT_LINE autolearn=unavailable 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 23/06/22 11:31, Sebastian Andrzej Siewior wrote: > On 2022-06-20 12:15:20 [+0100], Valentin Schneider wrote: >> Attempting to get a crash dump out of a debug PREEMPT_RT kernel via an N= MI >> panic() doesn't work. The cause of that lies in the PREEMPT_RT definition >> of mutex_trylock(): >>=20 > =E2=80=A6 > >> Fixes: 6ce47fd961fa ("rtmutex: Warn if trylock is called from hard/softi= rq context") >> Signed-off-by: Valentin Schneider > > Reviewed-by: Sebastian Andrzej Siewior > >> --- >> v1 -> v2 >> ++++++++ >>=20 >> o Changed from Peterson-like synchronization to simpler atomic_cmpxchg >> (Petr) >> o Slightly reworded changelog >> o Added Fixes: tag. Technically should be up to since kexec can happen >> in an NMI, but that isn't such a clear target > > RT-wise it would be needed for each release. So git tells me the Fixes: commit dates from v4.2; from [1] and [2] I get that both current longterm stable and stable-rt trees go as far back as v4.9, so I'm guessing if that gets picked up for the stable trees then it should make its way into the stable -rt trees? [1]: https://wiki.linuxfoundation.org/realtime/preempt_rt_versions [2]: https://www.kernel.org/category/releases.html > There is also a mutex_unlock() in case an image is missing. This can go > via the scheduler if there is a waiter which does not look good with the > NMI in the picture. > > Sebastian