From: "Linux regression tracking #adding (Thorsten Leemhuis)" <regressions@leemhuis.info>
To: Vlastimil Babka <vbabka@suse.cz>, Christoph Hellwig <hch@lst.de>,
Jens Axboe <axboe@kernel.dk>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
"Rafael J. Wysocki" <rafael@kernel.org>,
Mike Snitzer <snitzer@kernel.org>,
Joern Engel <joern@lazybastard.org>,
Miquel Raynal <miquel.raynal@bootlin.com>,
Richard Weinberger <richard@nod.at>,
Vignesh Raghavendra <vigneshr@ti.com>,
Pavel Machek <pavel@ucw.cz>,
Loic Poulain <loic.poulain@linaro.org>,
dm-devel@redhat.com, linux-kernel@vger.kernel.org,
linux-block@vger.kernel.org, linux-mtd@lists.infradead.org,
linux-pm@vger.kernel.org,
Linux regressions mailing list <regressions@lists.linux.dev>
Subject: Re: [PATCH 04/24] PM: hibernate: move finding the resume device out of software_resume
Date: Sat, 5 Aug 2023 15:07:18 +0200 [thread overview]
Message-ID: <84f6ea98-0d72-e17a-4b7c-d025f2d34e95@leemhuis.info> (raw)
In-Reply-To: <2cfa5f55-1d68-8a4f-d049-13f42e0d1484@suse.cz>
[TLDR: I'm adding this report to the list of tracked Linux kernel
regressions; the text you find below is based on a few templates
paragraphs you might have encountered already in similar form.
See link in footer if these mails annoy you.]
On 03.08.23 10:27, Vlastimil Babka wrote:
> On 5/31/23 14:55, Christoph Hellwig wrote:
>> software_resume can be called either from an init call in the boot code,
>> or from sysfs once the system has finished booting, and the two
>> invocation methods this can't race with each other.
>>
>> For the latter case we did just parse the suspend device manually, while
>> the former might not have one. Split software_resume so that the search
>> only happens for the boot case, which also means the special lockdep
>> nesting annotation can go away as the system transition mutex can be
>> taken a little later and doesn't have the sysfs locking nest inside it.
>>
>> Signed-off-by: Christoph Hellwig <hch@lst.de>
>> Acked-by: Rafael J. Wysocki <rafael@kernel.org>
>
> This caused a regression for me in 6.5-rc1+, fix below.
>
> ----8<----
>>From 95a310ae6cfae9b3cab61e54a1bce488c3ab93a1 Mon Sep 17 00:00:00 2001
> From: Vlastimil Babka <vbabka@suse.cz>
> Date: Wed, 2 Aug 2023 15:46:18 +0200
> Subject: [PATCH] PM: hibernate: fix resume_store() return value when
> hibernation not available
>
> On a laptop with hibernation set up but not actively used, and with
> secure boot and lockdown enabled kernel, 6.5-rc1 gets stuck on boot with
> the following repeated messages:
>
> A start job is running for Resume from hibernation using device /dev/system/swap (24s / no limit)
> lockdown_is_locked_down: 25311154 callbacks suppressed
> Lockdown: systemd-hiberna: hibernation is restricted; see man kernel_lockdown.7
> ...
>
> Checking the resume code leads to commit cc89c63e2fe3 ("PM: hibernate:
> move finding the resume device out of software_resume") which
> inadvertently changed the return value from resume_store() to 0 when
> !hibernation_available(). This apparently translates to userspace
> write() returning 0 as in number of bytes written, and userspace looping
> indefinitely in the attempt to write the intended value.
>
> Fix this by returning the full number of bytes that were to be written,
> as that's what was done before the commit.
>
> Fixes: cc89c63e2fe3 ("PM: hibernate: move finding the resume device out of software_resume")
> [...]
Thanks for the report. To be sure the issue doesn't fall through the
cracks unnoticed, I'm adding it to regzbot, the Linux kernel regression
tracking bot:
#regzbot ^introduced cc89c63e2fe3
#regzbot title pm: boot problems when hibernate is configured and kernel
locked down
#regzbot fix: PM: hibernate: fix resume_store() return value when
hibernation not available
#regzbot ignore-activity
This isn't a regression? This issue or a fix for it are already
discussed somewhere else? It was fixed already? You want to clarify when
the regression started to happen? Or point out I got the title or
something else totally wrong? Then just reply and tell me -- ideally
while also telling regzbot about it, as explained by the page listed in
the footer of this mail.
Developers: When fixing the issue, remember to add 'Link:' tags pointing
to the report (the parent of this mail). See page linked in footer for
details.
Ciao, Thorsten (wearing his 'the Linux kernel's regression tracker' hat)
--
Everything you wanna know about Linux kernel regression tracking:
https://linux-regtracking.leemhuis.info/about/#tldr
That page also explains what to do if mails like this annoy you.
next prev parent reply other threads:[~2023-08-05 13:07 UTC|newest]
Thread overview: 36+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-05-31 12:55 fix the name_to_dev_t mess v2 Christoph Hellwig
2023-05-31 12:55 ` [PATCH 01/24] driver core: return bool from driver_probe_done Christoph Hellwig
2023-06-05 17:22 ` Jens Axboe
2023-05-31 12:55 ` [PATCH 02/24] PM: hibernate: factor out a helper to find the resume device Christoph Hellwig
2023-05-31 12:55 ` [PATCH 03/24] PM: hibernate: remove the global snapshot_test variable Christoph Hellwig
2023-05-31 12:55 ` [PATCH 04/24] PM: hibernate: move finding the resume device out of software_resume Christoph Hellwig
2023-08-03 8:27 ` Vlastimil Babka
2023-08-04 10:31 ` Christoph Hellwig
2023-08-04 13:30 ` Greg Kroah-Hartman
2023-08-05 13:07 ` Linux regression tracking #adding (Thorsten Leemhuis) [this message]
2023-05-31 12:55 ` [PATCH 05/24] init: remove pointless Root_* values Christoph Hellwig
2023-05-31 12:55 ` [PATCH 06/24] init: rename mount_block_root to mount_root_generic Christoph Hellwig
2023-05-31 12:55 ` [PATCH 07/24] init: refactor mount_root Christoph Hellwig
2023-05-31 12:55 ` [PATCH 08/24] init: pass root_device_name explicitly Christoph Hellwig
2023-06-24 0:08 ` Guenter Roeck
2023-06-26 7:53 ` Christoph Hellwig
2023-06-26 14:50 ` Guenter Roeck
2023-06-27 10:38 ` Max Filippov
2023-05-31 12:55 ` [PATCH 09/24] init: don't remove the /dev/ prefix from error messages Christoph Hellwig
2023-05-31 12:55 ` [PATCH 10/24] init: handle ubi/mtd root mounting like all other root types Christoph Hellwig
2023-05-31 12:55 ` [PATCH 11/24] init: factor the root_wait logic in prepare_namespace into a helper Christoph Hellwig
2023-05-31 12:55 ` [PATCH 12/24] init: move the nfs/cifs/ram special cases out of name_to_dev_t Christoph Hellwig
2023-05-31 12:55 ` [PATCH 13/24] init: improve the name_to_dev_t interface Christoph Hellwig
2023-05-31 12:55 ` [PATCH 14/24] init: clear root_wait on all invalid root= strings Christoph Hellwig
2023-05-31 12:55 ` [PATCH 15/24] block: move the code to do early boot lookup of block devices to block/ Christoph Hellwig
2023-05-31 12:55 ` [PATCH 16/24] block: move more code to early-lookup.c Christoph Hellwig
2023-05-31 12:55 ` [PATCH 17/24] dm-snap: simplify the origin_dev == cow_dev check in snapshot_ctr Christoph Hellwig
2023-05-31 12:55 ` [PATCH 18/24] dm: open code dm_get_dev_t in dm_init_init Christoph Hellwig
2023-05-31 12:55 ` [PATCH 19/24] dm: remove dm_get_dev_t Christoph Hellwig
2023-05-31 12:55 ` [PATCH 20/24] dm: only call early_lookup_bdev from early boot context Christoph Hellwig
2023-05-31 12:55 ` [PATCH 21/24] PM: hibernate: don't use early_lookup_bdev in resume_store Christoph Hellwig
2023-05-31 12:55 ` [PATCH 22/24] mtd: block2mtd: factor the early block device open logic into a helper Christoph Hellwig
2023-05-31 12:55 ` [PATCH 23/24] mtd: block2mtd: don't call early_lookup_bdev after the system is running Christoph Hellwig
2023-05-31 12:55 ` [PATCH 24/24] block: mark early_lookup_bdev as __init Christoph Hellwig
-- strict thread matches above, loose matches on Subject: below --
2023-05-23 7:45 fix the name_to_dev_t mess Christoph Hellwig
2023-05-23 7:45 ` [PATCH 04/24] PM: hibernate: move finding the resume device out of software_resume Christoph Hellwig
2023-05-23 18:33 ` Rafael J. Wysocki
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=84f6ea98-0d72-e17a-4b7c-d025f2d34e95@leemhuis.info \
--to=regressions@leemhuis.info \
--cc=axboe@kernel.dk \
--cc=dm-devel@redhat.com \
--cc=gregkh@linuxfoundation.org \
--cc=hch@lst.de \
--cc=joern@lazybastard.org \
--cc=linux-block@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mtd@lists.infradead.org \
--cc=linux-pm@vger.kernel.org \
--cc=loic.poulain@linaro.org \
--cc=miquel.raynal@bootlin.com \
--cc=pavel@ucw.cz \
--cc=rafael@kernel.org \
--cc=regressions@lists.linux.dev \
--cc=richard@nod.at \
--cc=snitzer@kernel.org \
--cc=vbabka@suse.cz \
--cc=vigneshr@ti.com \
/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