diff options
Diffstat (limited to 'drivers/block/loop.c')
-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 1e6edd568214..bf1c61cab8eb 100644 --- a/drivers/block/loop.c +++ b/drivers/block/loop.c | |||
@@ -656,7 +656,7 @@ static int loop_validate_file(struct file *file, struct block_device *bdev) | |||
656 | return -EBADF; | 656 | return -EBADF; |
657 | 657 | ||
658 | l = f->f_mapping->host->i_bdev->bd_disk->private_data; | 658 | l = f->f_mapping->host->i_bdev->bd_disk->private_data; |
659 | if (l->lo_state == Lo_unbound) { | 659 | if (l->lo_state != Lo_bound) { |
660 | return -EINVAL; | 660 | return -EINVAL; |
661 | } | 661 | } |
662 | f = l->lo_backing_file; | 662 | f = l->lo_backing_file; |