diff options
-rw-r--r-- | drivers/block/loop.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/block/loop.c b/drivers/block/loop.c index 450c958b514f..1e5284ef65fa 100644 --- a/drivers/block/loop.c +++ b/drivers/block/loop.c | |||
@@ -1049,9 +1049,9 @@ static int loop_clr_fd(struct loop_device *lo, struct block_device *bdev) | |||
1049 | if (bdev) | 1049 | if (bdev) |
1050 | invalidate_bdev(bdev); | 1050 | invalidate_bdev(bdev); |
1051 | set_capacity(lo->lo_disk, 0); | 1051 | set_capacity(lo->lo_disk, 0); |
1052 | loop_sysfs_exit(lo); | ||
1052 | if (bdev) { | 1053 | if (bdev) { |
1053 | bd_set_size(bdev, 0); | 1054 | bd_set_size(bdev, 0); |
1054 | loop_sysfs_exit(lo); | ||
1055 | /* let user-space know about this change */ | 1055 | /* let user-space know about this change */ |
1056 | kobject_uevent(&disk_to_dev(bdev->bd_disk)->kobj, KOBJ_CHANGE); | 1056 | kobject_uevent(&disk_to_dev(bdev->bd_disk)->kobj, KOBJ_CHANGE); |
1057 | } | 1057 | } |