if (error)
goto Exit;
+ lock_device_hotplug();
/* Allocate memory management structures */
error = create_basic_memory_bitmaps();
if (error)
Free_bitmaps:
free_basic_memory_bitmaps();
Thaw:
+ unlock_device_hotplug();
thaw_processes();
/* Don't bother checking whether freezer_test_done is true */
pr_debug("PM: Loading hibernation image.\n");
+ lock_device_hotplug();
error = create_basic_memory_bitmaps();
if (error)
goto Thaw;
swsusp_free();
free_basic_memory_bitmaps();
Thaw:
+ unlock_device_hotplug();
thaw_processes();
Finish:
pm_notifier_call_chain(PM_POST_RESTORE);