[kernel/f14/master] Fix missing dm_put().
Peter Jones
pjones at fedoraproject.org
Fri Oct 15 17:17:58 UTC 2010
commit 7810142e6c8d07c61423b2184dd20679e841f91b
Author: Peter Jones <pjones at redhat.com>
Date: Fri Oct 15 13:16:48 2010 -0400
Fix missing dm_put().
There's an error path that fails to call dm_put(), which means bad
things happen. This patch adds the dm_put() call.
...ing-of-uuid-via-rename-if-not-already-set.patch | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
---
diff --git a/dm-allow-setting-of-uuid-via-rename-if-not-already-set.patch b/dm-allow-setting-of-uuid-via-rename-if-not-already-set.patch
index ba5d453..fd0f1af 100644
--- a/dm-allow-setting-of-uuid-via-rename-if-not-already-set.patch
+++ b/dm-allow-setting-of-uuid-via-rename-if-not-already-set.patch
@@ -62,7 +62,7 @@ index bb6bdc8..d102269 100644
return -EBUSY;
}
-@@ -329,22 +334,45 @@ static int dm_hash_rename(uint32_t cookie, uint32_t *flags, const char *old,
+@@ -329,22 +334,46 @@ static int dm_hash_rename(uint32_t cookie, uint32_t *flags, const char *old,
*/
hc = __get_name_cell(old);
if (!hc) {
@@ -92,6 +92,7 @@ index bb6bdc8..d102269 100644
+ DMWARN("Unable to change uuid of device, %s because "
+ "uuid is already set to %s",
+ old, hc->uuid);
++ dm_put(hc->md);
+ up_write(&_hash_lock);
+ kfree(new_data);
+ return -EINVAL;
More information about the scm-commits
mailing list