lkml.org 
[lkml]   [2007]   [Jan]   [9]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] flush_cpu_workqueue: don't flush an empty ->worklist

* Andrew Morton <akpm@osdl.org> wrote:

> > I would be happy to be corrected if the above impression of
> > freeze_processes() is corrected ..
>
> It could be that the freezer needs a bit of work for this application.
> Obviously we're not interested in the handling of disk I/O, so we'd
> really like to do a simple
> try_to_freeze_tasks(FREEZER_USER_SPACE|FREEZER_KERNEL_THREADS), but
> the code isn't set up to do that (it should be). The other non-swsusp
> callers probably want this change as well. But that's all a minor
> matter.

yes. The freezer does the fundamentally right thing: it stops all tasks
in user-space or waits for them to return back to user-space to stop
them there, or if it's a pure kernel-space task it waits until that
kernel-space task voluntarily stop.

Once the system is in such a state, and all processing has been stopped,
all of the kernel's data structures are completely 'unused', and we can:

- patch the kernel freely (kprobes)

- save+stop the kernel (sw-suspend)

- remove a CPU (CPU hotplug and suspend)

- (We could also use this mechanism to live-migrate the kernel to
another system btw., possibly useful for containers)

- (We could also use this mechanism to create a live snapshot of a
running kernel, together with an LVM snapshot of filesystem state,
for possible restore point later on.)

It is a very powerful mechanism that has really nice properties - we
should work on this one shared infrastructure instead of adding zillions
of per-subsystem CPU hotplug locks.

Ingo
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2007-01-09 08:53    [W:0.239 / U:0.380 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site