Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp2410796rwd; Fri, 26 May 2023 06:19:22 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ56oqsfKgmk/C2P1Eh6JFUikT0JqMqK92prI5DCt9DBjzGk0fTeTXsSjDKOEDyELdZKQJs7 X-Received: by 2002:a05:6a20:8f09:b0:10b:27d0:70cc with SMTP id b9-20020a056a208f0900b0010b27d070ccmr2772145pzk.20.1685107162477; Fri, 26 May 2023 06:19:22 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1685107162; cv=none; d=google.com; s=arc-20160816; b=lLhlwXziseK3VX0kkbntCc3SrahSrT/Fs28r0YCkIKrrvFJcEfB9lZRo8A+/5VS+cp L271ik5XooDfgbxlRV6biav/D4gd7Y64g313xvzTQKhmOB2WWsfnSYAbig6OyjykXAVX YbQy7idxOjvjW8/M+wHZcb8Id9+O+VKQD0lNRfrBJeQmMzwXL4wpjeMVeUDp/AyLc1vv 73ge79bFItMBSWd7u+xYis14uI9raMDEAHtGfNLDEsh63Fc2mh/1K3UbtiJjPscDXqXi sGEWXYgCF5jqYziyr6ph71xlw6THx4G1s7mV0zdKJidy0TjRchMniK0HQ8fVz5N17QbS yzRw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:cc:to:subject :message-id:date:from:in-reply-to:references:mime-version :dkim-signature; bh=hkVaao4LtBpB5P1B3tLZxzGuMjJCrzkDcbHFtv+t/BA=; b=edP4tY9N3P/7fOliDBwOV1eOZ2ogp0p1fBhwXP+KskNYRX6Hq1KUW6NNmlhnvDRWFF tKtaz+homwXgRetXgjB6Kfn2/CLSbFtchYElGg9t0f2FSRLrH3aJpQ98pkV/cif9I/Yr LegrWvxP0VVZSy/7PF/hbKfun01gFvdv5JHh2M41CpQjk4VcF76UJ4WLPwQg52G0h0GN 15KeYHgNAcLdKg+a7oc1namWZdGhHXpva7isN8lvqxvmbJSJvlIgvAxpBARpxZl5qIem jpDosj6pXnY6fxwaRMQH1xTtgfvU7bpggUMpC8HEg24ZktP5QDAEKTaSBTH3PWaTRenK DNJg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@rivosinc-com.20221208.gappssmtp.com header.s=20221208 header.b=CQa5Toso; 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 t136-20020a63788e000000b00528a60cc065si3745183pgc.380.2023.05.26.06.19.08; Fri, 26 May 2023 06:19:22 -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=@rivosinc-com.20221208.gappssmtp.com header.s=20221208 header.b=CQa5Toso; 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 S243629AbjEZNOu (ORCPT + 99 others); Fri, 26 May 2023 09:14:50 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54038 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S243622AbjEZNOs (ORCPT ); Fri, 26 May 2023 09:14:48 -0400 Received: from mail-wr1-x434.google.com (mail-wr1-x434.google.com [IPv6:2a00:1450:4864:20::434]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C3CBF1A8 for ; Fri, 26 May 2023 06:14:45 -0700 (PDT) Received: by mail-wr1-x434.google.com with SMTP id ffacd0b85a97d-30aa1eb95a0so654884f8f.1 for ; Fri, 26 May 2023 06:14:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rivosinc-com.20221208.gappssmtp.com; s=20221208; t=1685106884; x=1687698884; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=hkVaao4LtBpB5P1B3tLZxzGuMjJCrzkDcbHFtv+t/BA=; b=CQa5TosoK4BroftU06tqqI4ZdsZA7t32w5o96Hdfl1FoC4INZY5MA/7zJY6nYZPPTI G8RE9Pf67umWPGDtgcOkTHjoP4M1IhEOZQ+ddOG401n52y3MuxTjYzE/HYSpzCSs4nT7 bu5V3EmE68JCrwpU53oNgRRM9RfdJ0TWmcJvMfSJpxqNlHWzmFo+K6pKvCPQdRWhxNWF 7fZYWRY9NIuS5epHVwkW5KHkWZR0LrP0qxrmfYTmeaLpO7+qGcnN/DMTc6c11dSNHyQy aWmQmvmWs9HO91fiE4GxsjEI9xUuC90mhUpFGXYBq13LHdJqEuQCK0saZqvnj/RnsP0t VcPw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1685106884; x=1687698884; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=hkVaao4LtBpB5P1B3tLZxzGuMjJCrzkDcbHFtv+t/BA=; b=SIjeJIYVpBc2evq7vh/b+UHLA9qZsf+PIvVa+H8HFJsj8xNe61SkfSp0FD3bR1gNj9 rB9o5C3nQcrJbP+o4uO3BQ4JUWW6wNkFuw4nNYwVX08KBvmKQKFpJW9X2/Y7un9YDPMj ZCftl1y4Y7ZbXJSEhHyOPBifM/oFYkbCupvUM7UROselEdoV5WEN8eNB+kLq9s/MKCZM EgLMpmxLeWMsECQ9ftUwKyJB81SlZ2GRGjBBl9Dbhe/GqQgjr/60pmRnLDHEJisFiXpi 92TBvJ8Wc3mZtXq+JDu+LgU3jNtwJWj4g3eaSOQFQVhUrUwEAkgKpzQ2pPyJ+7AgS0IB /W/g== X-Gm-Message-State: AC+VfDxZVAgOG8PpM4H/vbiWVb8iSV7fK4F80DTtX3o8EExLeIvEHHNY ghxzX91BqhVQgBddiFpfaDADgROxzbUd59Q43Ox5aA== X-Received: by 2002:a5d:5750:0:b0:307:8800:bbdb with SMTP id q16-20020a5d5750000000b003078800bbdbmr1211243wrw.58.1685106884257; Fri, 26 May 2023 06:14:44 -0700 (PDT) MIME-Version: 1.0 References: <20230525-postnasal-monopoly-98adb96ffaa1@wendy> <20230525-shrapnel-precut-26500fca4a48@wendy> <20230525-citric-waged-a2f78d27eb0c@wendy> <20230525-flaring-trading-f2bf0713ae26@spud> <20230525-desecrate-imposing-d97ab34e06ad@spud> <20230525-batting-botch-7e03393a2d97@spud> In-Reply-To: <20230525-batting-botch-7e03393a2d97@spud> From: Alexandre Ghiti Date: Fri, 26 May 2023 15:14:33 +0200 Message-ID: Subject: Re: Bug report: kernel paniced when system hibernates To: Conor Dooley , =?UTF-8?B?QmrDtnJuIFTDtnBlbA==?= Cc: Atish Patra , Conor Dooley , Anup Patel , Anup Patel , Alexandre Ghiti , robh@kernel.org, jeeheng.sia@starfivetech.com, linux-kernel@vger.kernel.org, palmer@rivosinc.com, leyfoon.tan@starfivetech.com, mason.huo@starfivetech.com, Guo Ren , Paul Walmsley , Song Shuai , linux-riscv@lists.infradead.org, Andrew Jones Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE,URIBL_BLOCKED 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 everyone, On Thu, May 25, 2023 at 11:24=E2=80=AFPM Conor Dooley wr= ote: > > On Thu, May 25, 2023 at 01:06:04PM -0700, Atish Patra wrote: > > On Thu, May 25, 2023 at 11:39=E2=80=AFAM Conor Dooley wrote: > > > > > > On Thu, May 25, 2023 at 11:37:40AM -0700, Atish Patra wrote: > > > > > > > Any testing of hibernation still needs to revert the patch until we > > > > have the proper fix. > > > > > > "the patch" is what exactly? I assume you don't mean depending on > > > NONPORTABLE, since that is a Kconfig option. > > > > Nope. Sorry I meant the commit > > > > 3335068 ("riscv: Use PUD/P4D/PGD pages for the linear mapping") > > Ah, if your SBI implementation is one of the affected ones, yeah. > If not, you can just set NONPORTABLE :) @Bj=C3=B6rn T=C3=B6pel emitted the idea of excluding from the hibernation a= ll the memory nodes in the "/reserved-memory" node (https://elixir.bootlin.com/linux/v6.4-rc1/source/Documentation/devicetree/= bindings/reserved-memory/reserved-memory.yaml): I have to admit that I don't see why it is not done by default by the kernel. Unless there is stuff in this node that needs to be "hibernated", I think that would be a very good solution since we would not rely on the name of the "internal" nodes of "/reserved-memory" (i.e. "mmode_resv"). I'm digging into why it is not done by default, just wanted to have your feedback before the week-end :)