Skip to contentSkip to conversation

fs: thaw_bdev() should return EINVAL if bd_fsfreeze_count is 0

PATCH RESEND New Masayoshi MIZUMA 1 participant 1 message Jul 27, 2010 VFS

lore
Share & tools
lore
#0 lore raw

PATCH RESEND 1/1 fs: thaw_bdev() should return EINVAL if bd_fsfreeze_count is 0

Hi,

thaw_bdev() should return EINVAL if bd_fsfreeze_count is 0 at entering thaw_bdev() because it is expected that bd_fsfreeze_count is incremented by freeze_bdev().

---
 fs/block_dev.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
fs/block_dev.c +1 -1
index 99d6af8..51500f6 100644
@@ -291,7 +291,7 @@ int thaw_bdev(struct block_device *bdev, struct super_block *sb)
 	}
 out:
 	mutex_unlock(&bdev->bd_fsfreeze_mutex);
-	return 0;
+	return error;
 }
 EXPORT_SYMBOL(thaw_bdev);
 
Signature · 4 lines
1.6.2.5

Thanks,
Masayoshi