Skip to content
  • Mikulas Patocka's avatar
    dm: fix handling of multiple internal suspends · 96b26c8c
    Mikulas Patocka authored
    Commit ffcc3936
    
     ("dm: enhance internal suspend and resume interface")
    attempted to handle multiple internal suspends on the same device, but
    it did that incorrectly.  When these functions are called in this order
    on the same device the device is no longer suspended, but it should be:
    	dm_internal_suspend_noflush
    	dm_internal_suspend_noflush
    	dm_internal_resume
    
    Fix this bug by maintaining an 'internal_suspend_count' and resuming
    the device when this count drops to zero.
    
    Signed-off-by: default avatarMikulas Patocka <mpatocka@redhat.com>
    Signed-off-by: default avatarMike Snitzer <snitzer@redhat.com>
    96b26c8c