linux-riscv.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* [PATCH V2 0/4] Remove WARN_ON in save_processor_state
@ 2023-06-09  7:50 Song Shuai
  2023-06-09  7:50 ` [PATCH V2 1/4] ARM: hibernate: remove " Song Shuai
                   ` (6 more replies)
  0 siblings, 7 replies; 11+ messages in thread
From: Song Shuai @ 2023-06-09  7:50 UTC (permalink / raw)
  To: catalin.marinas, will, paul.walmsley, palmer, aou, chris,
	jcmvbkbc, songshuaishuai, steven.price, vincenzo.frascino,
	leyfoon.tan, mason.huo, jeeheng.sia, conor.dooley, ajones
  Cc: linux, linux-arm-kernel, linux-kernel, linux-riscv

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.

So remove the unnecessary checking in save_processor_state
for ARM,arm64,riscv,xtensa architechtures.

Changes since V1:
https://lore.kernel.org/linux-riscv/20230525025555.24104-1-songshuaishuai@tinylab.org/
- supplement the case of CONFIG_PM_SLEEP_SMP=n in commit message as Will suggests

Song Shuai (4):
  ARM: hibernate: remove WARN_ON in save_processor_state
  arm64: hibernate: remove WARN_ON in save_processor_state
  riscv: hibernate: remove WARN_ON in save_processor_state
  xtensa: hibernate: remove WARN_ON in save_processor_state

 arch/arm/kernel/hibernate.c    | 1 -
 arch/arm64/kernel/hibernate.c  | 1 -
 arch/riscv/kernel/hibernate.c  | 1 -
 arch/xtensa/kernel/hibernate.c | 1 -
 4 files changed, 4 deletions(-)

-- 
2.20.1


_______________________________________________
linux-riscv mailing list
linux-riscv@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-riscv

^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2023-06-25 23:20 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-06-09  7:50 [PATCH V2 0/4] Remove WARN_ON in save_processor_state Song Shuai
2023-06-09  7:50 ` [PATCH V2 1/4] ARM: hibernate: remove " Song Shuai
2023-06-09  7:50 ` [PATCH V2 2/4] arm64: " Song Shuai
2023-06-09 10:23   ` Will Deacon
2023-06-09  7:50 ` [PATCH V2 3/4] riscv: " Song Shuai
2023-06-10 15:39   ` Conor Dooley
2023-06-09  7:50 ` [PATCH V2 4/4] xtensa: " Song Shuai
2023-06-21 15:51 ` (subset) [PATCH V2 0/4] Remove " Catalin Marinas
2023-06-22 18:28   ` Palmer Dabbelt
2023-06-25 23:17 ` Palmer Dabbelt
2023-06-25 23:20 ` patchwork-bot+linux-riscv

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).