Re: Back to the future.

From: Rafael J. Wysocki
Date: Fri Apr 27 2007 - 18:37:40 EST

On Saturday, 28 April 2007 00:08, Linus Torvalds wrote:
> On Sat, 28 Apr 2007, Rafael J. Wysocki wrote:
> >
> > We're freezing many of them just fine. ;-)
> And can you name a _single_ advantage of doing so?

Yes. We have a lot less interdependencies to worry about during the whole

> It so happens, that most people wouldn't notice or care that kmirrord got
> frozen (kernel thread picked at random - it might be one of the threads
> that has gotten special-cased to not do that), but I have yet to hear a
> single coherent explanation for why it's actually a good idea in the first
> place.

Well, I don't know if that's a 'coherent' explanation from your point of view
(probably not), but I'll try nevertheless:
1) if the kernel threads are frozen, we know that they don't hold any locks
that could interfere with the freezing of device drivers,
2) if they are frozen, we know, for example, that they won't call user mode
helpers or do similar things,
3) if they are frozen, we know that they won't submit I/O to disks and
potentially damage filesystems (suspend2 has much more problems with that
than swsusp, but still. And yes, there have been bug reports related to it,
so it's not just my fantasy).

Probably some other people can say more about it.

> And it has added totally idiotic code to every single kernel thread main
> loop. For _no_ reason, except that the concept was broken, and needed more
> breakage to just make it work.

It is actually useful for some things other than the hibernation/suspend, the
code is not idiotic (it's one line of code in the majority of cases) and you
should take that "I hate everything even remotely related to hibernation" hat
off, really.

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