Message ID | 20230522025020.285042-1-songshuaishuai@tinylab.org |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:b0ea:0:b0:3b6:4342:cba0 with SMTP id b10csp1175756vqo; Sun, 21 May 2023 20:13:05 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ4qA/ypY2ypveSq89SjUOAO+A0hNBxJM2HJZ+MMEfilr0R4DlkQnt7+fD3mtMab+zfhgqxO X-Received: by 2002:a17:90a:51e6:b0:253:44e7:9454 with SMTP id u93-20020a17090a51e600b0025344e79454mr14621342pjh.17.1684725185406; Sun, 21 May 2023 20:13:05 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1684725185; cv=none; d=google.com; s=arc-20160816; b=psoWT7PkNJ9g5i6+oyvE0qJPFNy8JyuFR8n55XG/5Mtc/8QScuZNN0/uTk3kAGwvvX fxUtwWA4o0dZ0Pje+3b+IBUsrNGRlWQ0FvdMS4BfrSNx2BP+deF1ViyNb/NqBMtyw6+h BfRYaaC+zuwPjR7K1HB//zLTHUq0YGtyolsX5/uGbUV2zQtU7vQwSOesDzHoAxdCH1DA VvJaWT+a0gep/ORW2ul21SiuZJcuYfN2ryhnu/3Dj4JA2Popqz4OosCmG7ZIsuc970z3 hW42RY5qr2ilUV5jE5Kv26K9tRzDsmMShgCJuRCYoXly9hcOVSo9VQOqbs2ZFVZyiJIN rcxQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:feedback-id:content-transfer-encoding :mime-version:message-id:date:subject:cc:to:from; bh=FoVB3GVz1SHTrqR2zXoCaqLHghhZimgVEGGn4wkXk5Y=; b=KAfrPvmt0RL5HLC0gNOLtM1W3o8CWxwPxwvDizKdOoqZRTS2k4ubipQq9+OAxRCwOW s5Bpb7VNP1bCn6DDXsRRy4oqGV6VeZW/jmv5WdDy2Lwpe86h1aCENRX2QhQY9OgQkM4C 9iAs+0Wm037PZ+foOo/kjx8tWZ1IZK53mja0ItqATz0EJgS1LHUnz+nS/TBMxUJu+0pD zhfSy+3wEow9wZvaHyk42aLESMZxtC84E4tEQvEZkWV2H/ZRGh9pjJ30ukrg9Qk5d/IH LOx1irZSgES1vcC4WhhSFl4qkN0dMwfQYm9cjaL8+3lHWQVOFXbZofmuxA3poV+w30oD yTfw== ARC-Authentication-Results: i=1; mx.google.com; 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: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id ie9-20020a17090b400900b002470f78a168si5911759pjb.104.2023.05.21.20.12.53; Sun, 21 May 2023 20:13:05 -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; 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 S231504AbjEVCwR (ORCPT <rfc822;cscallsign@gmail.com> + 99 others); 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 <rfc822;linux-kernel@vger.kernel.org>); 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 <linux-kernel@vger.kernel.org>; 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 <songshuaishuai@tinylab.org> 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 <songshuaishuai@tinylab.org>, Conor Dooley <conor.dooley@microchip.com> 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: 8bit X-QQ-SENDSIZE: 520 Feedback-ID: bizesmtp:tinylab.org:qybglogicsvrgz:qybglogicsvrgz5a-3 X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2,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: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1766562395866599864?= X-GMAIL-MSGID: =?utf-8?q?1766562395866599864?= |
Series |
[V2] riscv: hibernation: Remove duplicate call of suspend_restore_csrs
|
|
Commit Message
Song Shuai
May 22, 2023, 2:50 a.m. UTC
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/suspend-to-disk") Reviewed-by: Conor Dooley <conor.dooley@microchip.com> Reviewed-by: JeeHeng Sia <jeeheng.sia@starfivetech.com> Signed-off-by: Song Shuai <songshuaishuai@tinylab.org> --- Changes since V1: https://lore.kernel.org/linux-riscv/20230519102908.253458-1-suagrfillet@gmail.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(-)
Comments
On Mon, 22 May 2023 10:50:20 +0800, Song Shuai wrote: > 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. > > > [...] Applied, thanks! [1/1] riscv: hibernation: Remove duplicate call of suspend_restore_csrs https://git.kernel.org/palmer/c/c6399b893043 Best regards,
Hello: This patch was applied to riscv/linux.git (for-next) by Palmer Dabbelt <palmer@rivosinc.com>: On Mon, 22 May 2023 10:50:20 +0800 you wrote: > 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/suspend-to-disk") > Reviewed-by: Conor Dooley <conor.dooley@microchip.com> > Reviewed-by: JeeHeng Sia <jeeheng.sia@starfivetech.com> > Signed-off-by: Song Shuai <songshuaishuai@tinylab.org> > > [...] Here is the summary with links: - [V2] riscv: hibernation: Remove duplicate call of suspend_restore_csrs https://git.kernel.org/riscv/c/c6399b893043 You are awesome, thank you!
diff --git a/arch/riscv/kernel/hibernate-asm.S b/arch/riscv/kernel/hibernate-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) REG_L a0, hibernate_cpu_context - suspend_restore_csrs suspend_restore_regs /* Return zero value. */