From nobody Mon Feb 9 17:46:25 2026 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id C4ED9C7EE23 for ; Mon, 22 May 2023 02:52:18 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231464AbjEVCwR (ORCPT ); Sun, 21 May 2023 22:52:17 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36808 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231486AbjEVCwL (ORCPT ); Sun, 21 May 2023 22:52:11 -0400 X-Greylist: delayed 85 seconds by postgrey-1.37 at lindbergh.monkeyblade.net; Sun, 21 May 2023 19:52:03 PDT Received: from bg4.exmail.qq.com (bg4.exmail.qq.com [43.155.67.158]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 37651188 for ; Sun, 21 May 2023 19:52:02 -0700 (PDT) X-QQ-mid: bizesmtp66t1684723824tixnfbhg Received: from localhost.localdomain ( [221.226.144.218]) by bizesmtp.qq.com (ESMTP) with id ; Mon, 22 May 2023 10:50:23 +0800 (CST) X-QQ-SSF: 01200000000000204000000A0000000 X-QQ-FEAT: fp7GbACbaw5+/Q/MDriKgD9K7a4eKyWoz7734QLbFWStCUU/K7or6Lv1s5wOQ z89TIgb0hFWuT+B13h0yWpejC28/IEq+yFu5lnWDBG//Hf0Vw5LHFNvPNgOi6Bu6SS1MM5A mZi57ZiIsGAlPBD7i0UGXyb7AhQf/J2SDcp2KZM8wDWqlBaBjt/Nf2EsPHPCYK4Fpb7Bz0r V5SYhnifPJ6awCgeF8okbGEiD4YWUK+R1WCgYPBhYmAINustflXk79e14nHnpLSL6IKbtjH 7Aw5Ccd02qII2Iv5a6ovTcZtirCSalh//tzOo9q75WEawLfmRA/6/E3YrV+63bo9spXftFG brd6ajRUBnvXlVsH0Xvsmt9srrsIY1F6RxRF5aaJgJDz41/PxU= X-QQ-GoodBg: 0 X-BIZMAIL-ID: 14716206032302420397 From: Song Shuai To: paul.walmsley@sifive.com, palmer@dabbelt.com, aou@eecs.berkeley.edu, suagrfillet@gmail.com, mason.huo@starfivetech.com, leyfoon.tan@starfivetech.com, ajones@ventanamicro.com, jeeheng.sia@starfivetech.com Cc: linux-riscv@lists.infradead.org, linux-kernel@vger.kernel.org, Song Shuai , Conor Dooley Subject: [PATCH V2] riscv: hibernation: Remove duplicate call of suspend_restore_csrs Date: Mon, 22 May 2023 10:50:20 +0800 Message-Id: <20230522025020.285042-1-songshuaishuai@tinylab.org> X-Mailer: git-send-email 2.20.1 MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-QQ-SENDSIZE: 520 Feedback-ID: bizesmtp:tinylab.org:qybglogicsvrgz:qybglogicsvrgz5a-3 Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" The suspend_restore_csrs is called in both __hibernate_cpu_resume and the `else` of subsequent swsusp_arch_suspend. Removing the first call makes both suspend_{save,restore}_csrs left in swsusp_arch_suspend for clean code. Fixes: c0317210012e ("RISC-V: Add arch functions to support hibernation/sus= pend-to-disk") Reviewed-by: Conor Dooley Reviewed-by: JeeHeng Sia Signed-off-by: Song Shuai --- Changes since V1: https://lore.kernel.org/linux-riscv/20230519102908.253458-1-suagrfillet@gma= il.com/ - fix incorrect email in the Author and SoB field - add Fixes tag --- arch/riscv/kernel/hibernate-asm.S | 1 - 1 file changed, 1 deletion(-) diff --git a/arch/riscv/kernel/hibernate-asm.S b/arch/riscv/kernel/hibernat= e-asm.S index 5c76671c7e15..d698dd7df637 100644 --- a/arch/riscv/kernel/hibernate-asm.S +++ b/arch/riscv/kernel/hibernate-asm.S @@ -28,7 +28,6 @@ ENTRY(__hibernate_cpu_resume) =20 REG_L a0, hibernate_cpu_context =20 - suspend_restore_csrs suspend_restore_regs =20 /* Return zero value. */ --=20 2.20.1