Re: Alternative to TIF_FREEZE -> a notifier in the task_struct?

From: Pavel Machek
Date: Thu Jul 28 2005 - 02:42:29 EST


> This could be used to have a process execute any other piece that is
> required to run in the context of the thread. Maybe such a feature could
> help with PTRACE or/and get_user_pages that currently do ugly things to a
> process. It may also allow changing values that so far cannot be
> changed from the outside in the task struct by running a function
> in the context of the process.

Well, we really need slightly more from "running in process context":
we also need "no locks held" for swsusp. (But other uses probably do,

> Here is a patch against Linus current tree that does this. Note that this
> patch is incomplete at this point and only a basis for further discussion.
> Not all software suspend checkpoints are useful for a notifier chain. We
> would need to inspect several cases where drivers/kernel threads have
> special functionality for software suspend.

I guess I'd prefer if you left "refrigerator()" and "try_to_freeze()"
functions in; there are about 1000 drivers that know/use them, and
some patches are probably in the queue....

teflon -- maybe it is a trademark, but it should not be.
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at
Please read the FAQ at