Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp15376894rwd; Sun, 25 Jun 2023 16:26:09 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ7ooNE08nycB3vJlB2gA2ZKZhATBulq2SJISXvwyeJx5a2aT736n6YiOhO3YLHkwGIRlpce X-Received: by 2002:a05:6a00:15c9:b0:675:3ce:506e with SMTP id o9-20020a056a0015c900b0067503ce506emr3477406pfu.21.1687735569567; Sun, 25 Jun 2023 16:26:09 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1687735569; cv=none; d=google.com; s=arc-20160816; b=e3hVOiQcjHlMmyQjMhLiE/h9RTJmzH4s8haJeOFc7y+nbIgQi+GmvT02tegQ8xpv1a nm1vLG2erUsl7zHOX1k/+QH6dmtKdjB6hzjsINNC3NzouU/u9YKUBzqumwA3bC++lgJx b7sC5ueUAbX6YBrhWkPXnt0lEl3KN8y477nY0oIK3v1qL2JDwbHLCG4bjXNNoqXctJn+ gr8/fYJtM5jtYkfnU7TJ1hMW1uKzX0WJIm1NxTGkzHDnNNzdIS3MNIhbHvx1J4zSq4Jn oXlzJXu5IydRliuP/HC6lAom7bdz1IA2aEQZy7fo8BDIH1crFI+Y1pJvtphhLUM07xB6 subA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:to:from:cc:content-transfer-encoding :mime-version:date:message-id:subject:references:in-reply-to :dkim-signature; bh=ggy/7h1OPvstNA0LMyWIdKuG/UdvrrY9huBZRZ1dffc=; fh=WH19oi0e8Fg5Ehz1Z8f2nHqUL3A9S6Ag1D1w06FdpPw=; b=Mh9EXpGu+Bq8vGANM3AiilmnQ/iKf9D7pQvUGFfvvsXim53xZifmpyLBDfiHiIj/Mb YfWbQPnEzWOAU+znJOq3qgivUdQSER72XJaUgLxGj95BnQYH/rDmQZkJ8w4vX2wMl3I9 yNyK6Ko52hYHyG6t+EB3mL/aWcWYu0afXy0PWvK3HHI1EMDi0GTVKODmS4s0y7DX2BNs 1ayzjH1irb0XB28/8BdbKvdHn19dgET35gP413ibK+8popcuPLHO/x332txyJmyYaFb6 tdrEUKjQD2d4T1gibFz5w1jYQGFCdnGUJ1Z97YW0UVqT9Qv1VLBJBn0cQfvD70JRz0uZ Fysw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@rivosinc-com.20221208.gappssmtp.com header.s=20221208 header.b=FPJt8W4I; 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 m64-20020a632643000000b005533ded45c5si4305528pgm.17.2023.06.25.16.25.57; Sun, 25 Jun 2023 16:26:09 -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=FPJt8W4I; 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 S229835AbjFYXTB (ORCPT + 99 others); Sun, 25 Jun 2023 19:19:01 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34486 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229619AbjFYXSu (ORCPT ); Sun, 25 Jun 2023 19:18:50 -0400 Received: from mail-pf1-x429.google.com (mail-pf1-x429.google.com [IPv6:2607:f8b0:4864:20::429]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 3002AE43 for ; Sun, 25 Jun 2023 16:18:50 -0700 (PDT) Received: by mail-pf1-x429.google.com with SMTP id d2e1a72fcca58-66c729f5618so1390415b3a.1 for ; Sun, 25 Jun 2023 16:18:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rivosinc-com.20221208.gappssmtp.com; s=20221208; t=1687735129; x=1690327129; h=to:from:cc:content-transfer-encoding:mime-version:date:message-id :subject:references:in-reply-to:from:to:cc:subject:date:message-id :reply-to; bh=ggy/7h1OPvstNA0LMyWIdKuG/UdvrrY9huBZRZ1dffc=; b=FPJt8W4ID6XMXNwf1/VDKjHKddiZA2HyalGr4b7xUSwxScRpb8jmJ10eanIKIZv6dP Yt4Aia8ROJ2su6ZpuuAupfSD8XRUvCxQBYSb/hIjFjEnwshNVvsn3RPlweXpUTKKqccl kNq84gbcwQSW6bWF5cBkMdTLfcE7R4Y6PU8q7pk5046SnwEfhl+wqnzEDBsaiqAaIC+5 rRNOUEwQDWq1GUQMEiRLSQJwFJHNLwi4A1Bk48kf7khPsYQmDjfmzU8FyRRdEUkEKey+ mtF6v1L0ApdP+yH7YcND616lDMDQ9oFg5m3/2SWCMulebzoATcU4uXNcwEg/y3Jk5Cbs vDAw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1687735129; x=1690327129; h=to:from:cc:content-transfer-encoding:mime-version:date:message-id :subject:references:in-reply-to:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=ggy/7h1OPvstNA0LMyWIdKuG/UdvrrY9huBZRZ1dffc=; b=AIwkrVSxe+C41voW4zYTBrPomcPFgQlkfXcEMl2qFms4hPvnB8Qezy6OZ85SFadRdg h84wkwmmJmgO19T7W1trUGxJiuG2RB5rNAC0Y50UxxVWwIY3JLw1e/goQgqtTXJ9l14I H6eEBrNahahRYMUAIvVREjrdxfQhcrj0yZBtbLa3ftF/w90XjuHTvTEF8k7Iw022sjx5 24pw3M/tP0uGd9J7mZ1KaMVnWmcyTZraRYPHO6vo0E20nyGqDSdIRwD39lODrou0WnyM YL1I+rBWh32affjXpSZGK1hmpBpfdzCa82LTQUMNR6Y1ZIEX8Fom/vOAWq08XWbUxbxl GxdQ== X-Gm-Message-State: AC+VfDx92ejCFOmaRVZnOb+d9sE6CzwBIp9LqVVLafDaQ10UrZYESZ6l DHNQqiGpKUxKR6dU6P7NjpqNWjRusrEGZLV8u+o= X-Received: by 2002:a05:6a00:1804:b0:667:e17e:85bc with SMTP id y4-20020a056a00180400b00667e17e85bcmr33742884pfa.0.1687735129579; Sun, 25 Jun 2023 16:18:49 -0700 (PDT) Received: from localhost ([50.221.140.188]) by smtp.gmail.com with ESMTPSA id m18-20020aa79012000000b0064fc715b380sm2693121pfo.176.2023.06.25.16.18.49 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 25 Jun 2023 16:18:49 -0700 (PDT) In-Reply-To: <20230609075049.2651723-1-songshuaishuai@tinylab.org> References: <20230609075049.2651723-1-songshuaishuai@tinylab.org> Subject: Re: (subset) [PATCH V2 0/4] Remove WARN_ON in save_processor_state Message-Id: <168773507361.1389.9680109116196931036.b4-ty@rivosinc.com> Date: Sun, 25 Jun 2023 16:17:53 -0700 MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit X-Mailer: b4 0.13-dev-901c5 Cc: linux@armlinux.org.uk, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, linux-riscv@lists.infradead.org From: Palmer Dabbelt To: Catalin Marinas , Will Deacon , Paul Walmsley , Palmer Dabbelt , aou@eecs.berkeley.edu, chris@zankel.net, jcmvbkbc@gmail.com, steven.price@arm.com, vincenzo.frascino@arm.com, leyfoon.tan@starfivetech.com, mason.huo@starfivetech.com, jeeheng.sia@starfivetech.com, Conor Dooley , ajones@ventanamicro.com, Song Shuai 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 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 Fri, 09 Jun 2023 15:50:45 +0800, Song Shuai wrote: > During hibernation or restoration, freeze_secondary_cpus > checks num_online_cpus via BUG_ON, and the subsequent > save_processor_state also does the checking with WARN_ON. > > In the case of CONFIG_PM_SLEEP_SMP=n, freeze_secondary_cpus > is not defined, but the sole possible condition to disable > CONFIG_PM_SLEEP_SMP is !SMP where num_online_cpus is always 1. > We also don't have to check it in save_processor_state. > > [...] Applied, thanks! [3/4] riscv: hibernate: remove WARN_ON in save_processor_state https://git.kernel.org/palmer/c/91afbaafd6b1 Best regards, -- Palmer Dabbelt