From: Andrew Lunn <andrew@lunn.ch>
To: Vivek Kumar <quic_vivekuma@quicinc.com>
Cc: corbet@lwn.net, catalin.marinas@arm.com, will@kernel.org,
tglx@linutronix.de, maz@kernel.org, axboe@kernel.dk,
rafael@kernel.org, akpm@linux-foundation.org,
linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org,
linux-arm-kernel@lists.infradead.org,
linux-block@vger.kernel.org, linux-pm@vger.kernel.org,
linux-mm@kvack.org, len.brown@intel.com, pavel@ucw.cz,
paulmck@kernel.org, bp@suse.de, keescook@chromium.org,
songmuchun@bytedance.com, rdunlap@infradead.org,
damien.lemoal@opensource.wdc.com, pasha.tatashin@soleen.com,
tabba@google.com, ardb@kernel.org, tsoni@quicinc.com,
quic_psodagud@quicinc.com, quic_svaddagi@quicinc.com,
Prasanna Kumar <quic_kprasan@quicinc.com>
Subject: Re: [RFC 2/6] PM: Hibernate: Add option to disable disk offset randomization
Date: Wed, 18 May 2022 14:19:23 +0200 [thread overview]
Message-ID: <YoTkSx96vt1NTdZ/@lunn.ch> (raw)
In-Reply-To: <1652860121-24092-3-git-send-email-quic_vivekuma@quicinc.com>
On Wed, May 18, 2022 at 01:18:37PM +0530, Vivek Kumar wrote:
> 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 <quic_vivekuma@quicinc.com>
> Signed-off-by: Prasanna Kumar <quic_kprasan@quicinc.com>
> ---
> 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
next prev parent reply other threads:[~2022-05-18 12:19 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-05-18 7:48 [RFC 0/6] Bootloader based hibernation Vivek Kumar
2022-05-18 7:48 ` [RFC 1/6] arm64: hibernate: Introduce new entry point to kernel Vivek Kumar
2022-05-19 15:27 ` Marc Zyngier
2022-05-18 7:48 ` [RFC 2/6] PM: Hibernate: Add option to disable disk offset randomization Vivek Kumar
2022-05-18 12:19 ` Andrew Lunn [this message]
2022-05-18 13:00 ` Christoph Hellwig
2022-05-23 20:49 ` Randy Dunlap
2022-05-18 7:48 ` [RFC 3/6] block: gendisk: Add a new genhd capability flag Vivek Kumar
2022-05-18 8:08 ` Christoph Hellwig
2022-05-18 7:48 ` [RFC 4/6] mm: swap: Add randomization check for swapon/off calls Vivek Kumar
2022-05-18 12:27 ` Andrew Lunn
2022-05-18 7:48 ` [RFC 5/6] Hibernate: Add check for pte_valid in saveable page Vivek Kumar
2022-05-18 13:09 ` Christoph Hellwig
2022-05-18 7:48 ` [RFC 6/6] irqchip/gic-v3: Re-init GIC hardware upon hibernation restore Vivek Kumar
2022-05-19 7:59 ` Marc Zyngier
2022-05-18 16:55 ` [RFC 0/6] Bootloader based hibernation Pasha Tatashin
2022-05-20 16:43 ` Mark Rutland
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=YoTkSx96vt1NTdZ/@lunn.ch \
--to=andrew@lunn.ch \
--cc=akpm@linux-foundation.org \
--cc=ardb@kernel.org \
--cc=axboe@kernel.dk \
--cc=bp@suse.de \
--cc=catalin.marinas@arm.com \
--cc=corbet@lwn.net \
--cc=damien.lemoal@opensource.wdc.com \
--cc=keescook@chromium.org \
--cc=len.brown@intel.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-block@vger.kernel.org \
--cc=linux-doc@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=linux-pm@vger.kernel.org \
--cc=maz@kernel.org \
--cc=pasha.tatashin@soleen.com \
--cc=paulmck@kernel.org \
--cc=pavel@ucw.cz \
--cc=quic_kprasan@quicinc.com \
--cc=quic_psodagud@quicinc.com \
--cc=quic_svaddagi@quicinc.com \
--cc=quic_vivekuma@quicinc.com \
--cc=rafael@kernel.org \
--cc=rdunlap@infradead.org \
--cc=songmuchun@bytedance.com \
--cc=tabba@google.com \
--cc=tglx@linutronix.de \
--cc=tsoni@quicinc.com \
--cc=will@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox