freezer: add new freezable helpers using freezer_do_not_count()
authorColin Cross <ccross@android.com>
Mon, 6 May 2013 23:50:14 +0000 (23:50 +0000)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Sun, 12 May 2013 12:16:22 +0000 (14:16 +0200)
commitdd5ec0f4e72bed3d0e589e21fdf46eedafc106b7
tree5c6d29cb3b1b6db27fab0470e3892e12fd2a9f78
parent8ee492d6595573a0d4be168ebda1c7ceb4ec509d
freezer: add new freezable helpers using freezer_do_not_count()

Freezing tasks will wake up almost every userspace task from
where it is blocking and force it to run until it hits a
call to try_to_sleep(), generally on the exit path from the syscall
it is blocking in.  On resume each task will run again, usually
restarting the syscall and running until it hits the same
blocking call as it was originally blocked in.

To allow tasks to avoid running on every suspend/resume cycle,
this patch adds additional freezable wrappers around blocking calls
that call freezer_do_not_count().  Combined with the previous patch,
these tasks will not run during suspend or resume unless they wake
up for another reason, in which case they will run until they hit
the try_to_freeze() in freezer_count(), and then continue processing
the wakeup after tasks are thawed.

Additional patches will convert the most common locations that
userspace blocks in to use freezable helpers.

Acked-by: Tejun Heo <tj@kernel.org>
Signed-off-by: Colin Cross <ccross@android.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
include/linux/freezer.h
This page took 0.0285879999999999 seconds and 5 git commands to generate.