common/dmerror: always try to resume device
authorDarrick J. Wong <darrick.wong@oracle.com>
Wed, 11 Dec 2019 05:38:31 +0000 (21:38 -0800)
committerEryu Guan <guaneryu@gmail.com>
Mon, 6 Jan 2020 06:36:04 +0000 (14:36 +0800)
commit29e2be05501ffb62d4d4fed6d3712869cce55152
tree457028a163a9440ee13ffac83029684083e000f6
parent0335928b8c934fef14008941ab5aa6336f1e423d
common/dmerror: always try to resume device

When we're reloading the error-target dm table, always resume the device
even if the reload fails because (a) we shouldn't leave dm state for the
callers to clean up and (b) the caller don't clean up the state which
just leads to the scratch filesystem hanging on the suspended dm error
device.

Resume the dm device when we're cleaning up so that cleaning up the
scratch filesystem won't hang.

Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
Reviewed-by: Eryu Guan <guaneryu@gmail.com>
Signed-off-by: Eryu Guan <guaneryu@gmail.com>
common/dmerror