From: Oleg Nesterov <oleg@redhat.com>
To: Zihuan Zhang <zhangzihuan@kylinos.cn>
Cc: "rafael J . wysocki" <rafael@kernel.org>,
Peter Zijlstra <peterz@infradead.org>,
len brown <len.brown@intel.com>, pavel machek <pavel@kernel.org>,
linux-pm@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v4] PM / Freezer: Skip zombie/dead processes to reduce freeze latency
Date: Thu, 17 Jul 2025 03:31:59 +0200 [thread overview]
Message-ID: <20250717013158.GF16401@redhat.com> (raw)
In-Reply-To: <c6c7e8b5-430b-4616-b9e8-46500621bb84@kylinos.cn>
Hi Zihuan,
On 07/17, Zihuan Zhang wrote:
>
> >>+ */
> >>+ if (p == current || p->exit_state || !freeze_task(p))
> >> continue;
> >I leave this to you and Rafael, but this change doesn't look safe to me.
> >What if the exiting task does some IO after exit_notify() ?
>
> Tasks that have passed exit_notify() and entered EXIT_ZOMBIE are no longer
> schedulable,
How so? please look at do_exit(). The exiting task is still running
until it does its last __schedule() in do_task_dead().
> so they cannot do I/O anymore. Skipping them during freezing
> should be safe
Oleg.
next prev parent reply other threads:[~2025-07-17 1:33 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-07-16 6:26 [PATCH v4 0/1] PM / Freezer: Skip zombie/dead processes to reduce Zihuan Zhang
2025-07-16 6:26 ` [PATCH v4] PM / Freezer: Skip zombie/dead processes to reduce freeze latency Zihuan Zhang
2025-07-16 16:38 ` Oleg Nesterov
2025-07-16 18:36 ` Peter Zijlstra
2025-07-17 1:30 ` Zihuan Zhang
2025-07-17 1:43 ` Oleg Nesterov
2025-07-17 1:16 ` Zihuan Zhang
2025-07-17 1:31 ` Oleg Nesterov [this message]
2025-07-17 8:45 ` Zihuan Zhang
2025-07-16 12:26 ` [PATCH v4 0/1] PM / Freezer: Skip zombie/dead processes to reduce Rafael J. Wysocki
2025-07-17 1:02 ` Zihuan Zhang
2025-07-17 9:50 ` Rafael J. Wysocki
2025-07-21 10:39 ` Zihuan Zhang
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=20250717013158.GF16401@redhat.com \
--to=oleg@redhat.com \
--cc=len.brown@intel.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pm@vger.kernel.org \
--cc=pavel@kernel.org \
--cc=peterz@infradead.org \
--cc=rafael@kernel.org \
--cc=zhangzihuan@kylinos.cn \
/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;
as well as URLs for NNTP newsgroup(s).