Skip to content
Commit 8761a3dc authored by Phillip Susi's avatar Phillip Susi Committed by Jens Axboe
Browse files

loop: cleanup partitions when detaching loop device



Any partitions added by user space to the loop device were being
left in place after detaching the loop device.  This was because
the detach path issued a BLKRRPART to clean up partitions if
LO_FLAGS_PARTSCAN was set, meaning that the partitions were auto
scanned on attach.  Replace this BLKRRPART with code that
unconditionally cleans up partitions on detach instead.

Signed-off-by: default avatarPhillip Susi <psusi@ubuntu.com>

Modified by Jens to export delete_partition().

Signed-off-by: default avatarJens Axboe <axboe@kernel.dk>
parent 183cfb57
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment