Thread (17 messages) 17 messages, 7 authors, 2022-05-23

Re: [RFC 2/6] PM: Hibernate: Add option to disable disk offset randomization

From: Andrew Lunn <andrew@lunn.ch>
Date: 2022-05-18 12:19:51
Also in: linux-block, linux-doc, linux-mm, linux-pm, lkml

On Wed, May 18, 2022 at 01:18:37PM +0530, Vivek Kumar wrote:
quoted hunk ↗ jump to hunk
Add a kernel parameter to disable the disk offset randomization
for SSD devices in which such feature is available at the
firmware level. This is helpful in improving hibernation
resume time.

Signed-off-by: Vivek Kumar <redacted>
Signed-off-by: Prasanna Kumar <redacted>
---
 Documentation/admin-guide/kernel-parameters.txt | 11 +++++++++++
 kernel/power/swap.c                             |  9 +++++++++
 2 files changed, 20 insertions(+)
diff --git a/Documentation/admin-guide/kernel-parameters.txt b/Documentation/admin-guide/kernel-parameters.txt
index 666ade9..06b4f10 100644
--- a/Documentation/admin-guide/kernel-parameters.txt
+++ b/Documentation/admin-guide/kernel-parameters.txt
@@ -5192,6 +5192,17 @@
 			Useful for devices that are detected asynchronously
 			(e.g. USB and MMC devices).
 
+	noswap_randomize
+			Kernel uses random disk offsets to help with wear-levelling
+			of SSD devices, while saving the hibernation snapshot image to
+			disk. Use this parameter to disable this feature for SSD
+			devices in scenarios when, such randomization is addressed at
+			the firmware level and hibenration image is not re-generated
+			frequently.
+			(Useful for improving hibernation resume time as snapshot pages
+			are available in disk serially and can be read in bigger chunks
+			without seeking)
Seeking is a NOP for SSD, so it seems odd you mentioned that. Is the
real problem here that the bootloader driver is very simple, it does
not queue multiple reads to the hardware, but does it one block at a
time?

Do you have performance numbers for both the bootloader and Linux?
Does Linux performance reading the snapshot increase as much as for
the bootloader?

	Andrew

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help