* [PATCH RESEND] md:Check if call to thaw_bdev fails in unlock_fs
@ 2016-01-14 21:05 Nicholas Krause
0 siblings, 0 replies; only message in thread
From: Nicholas Krause @ 2016-01-14 21:05 UTC (permalink / raw)
To: agk; +Cc: linux-raid, dm-devel, neilb, snitzer, linux-kernel
This adds a check to the function unlock_fs to check if the call
to thaw_bdev failed by returning a return code and if so print
on the log level of KERN_CRIT that the thaw has failed on the
passed device structure pointer's name before returnin immediately
to this function's caller.
Signed-off-by: Nicholas Krause <xerofoify@gmail.com>
---
drivers/md/dm.c | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/drivers/md/dm.c b/drivers/md/dm.c
index ab37ae1..20ccc36 100644
--- a/drivers/md/dm.c
+++ b/drivers/md/dm.c
@@ -3152,7 +3152,11 @@ static void unlock_fs(struct mapped_device *md)
if (!test_bit(DMF_FROZEN, &md->flags))
return;
- thaw_bdev(md->bdev, md->frozen_sb);
+ if (!thaw_bdev(md->bdev, md->frozen_sb)) {
+ pr_crit("Thaw failed on the file device %s\n", md->name);
+ return;
+ }
+
md->frozen_sb = NULL;
clear_bit(DMF_FROZEN, &md->flags);
}
--
2.1.4
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2016-01-14 21:05 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-01-14 21:05 [PATCH RESEND] md:Check if call to thaw_bdev fails in unlock_fs Nicholas Krause
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox