aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/power/user.c
diff options
context:
space:
mode:
Diffstat (limited to 'kernel/power/user.c')
-rw-r--r--kernel/power/user.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/kernel/power/user.c b/kernel/power/user.c
index 6b1ab7a88522..e5a21a857302 100644
--- a/kernel/power/user.c
+++ b/kernel/power/user.c
@@ -274,6 +274,15 @@ static long snapshot_ioctl(struct file *filp, unsigned int cmd,
274 swsusp_free(); 274 swsusp_free();
275 memset(&data->handle, 0, sizeof(struct snapshot_handle)); 275 memset(&data->handle, 0, sizeof(struct snapshot_handle));
276 data->ready = 0; 276 data->ready = 0;
277 /*
278 * It is necessary to thaw kernel threads here, because
279 * SNAPSHOT_CREATE_IMAGE may be invoked directly after
280 * SNAPSHOT_FREE. In that case, if kernel threads were not
281 * thawed, the preallocation of memory carried out by
282 * hibernation_snapshot() might run into problems (i.e. it
283 * might fail or even deadlock).
284 */
285 thaw_kernel_threads();
277 break; 286 break;
278 287
279 case SNAPSHOT_PREF_IMAGE_SIZE: 288 case SNAPSHOT_PREF_IMAGE_SIZE: