diff options
author | Guoqing Jiang <gqjiang@suse.com> | 2015-12-17 01:54:25 +0800 |
---|---|---|
committer | NeilBrown <neilb@suse.com> | 2015-12-17 09:51:46 +1100 |
commit | 1b78e47021170527e9f173b05e3adac41f8bccf9 (patch) | |
tree | 1fe5c841f04569a77fa4e9e928f8422ddcab2617 | |
parent | 53e76b1def4d3d6c884e45f1ac723b5f3a1b7376 (diff) | |
download | mdadm-1b78e47021170527e9f173b05e3adac41f8bccf9.tar.gz |
mdadm: do not try to hold dlm lock in free_super1
Since free_super1 actually doesn't change the sb, it
just free the addr space of sb. Also free_super1 is
called in lots of place within mdadm, so remove dlm
lock code since the func doesn't need the protection
and also reduce latency.
Signed-off-by: Guoqing Jiang <gqjiang@suse.com>
Signed-off-by: NeilBrown <neilb@suse.com>
-rw-r--r-- | super1.c | 11 |
1 files changed, 0 insertions, 11 deletions
@@ -2422,15 +2422,6 @@ static int write_bitmap1(struct supertype *st, int fd, enum bitmap_update update static void free_super1(struct supertype *st) { - int rv, lockid; - if (is_clustered(st)) { - rv = cluster_get_dlmlock(st, &lockid); - if (rv) { - pr_err("Cannot get dlmlock in %s return %d\n", __func__, rv); - cluster_release_dlmlock(st, lockid); - return; - } - } if (st->sb) free(st->sb); @@ -2442,8 +2433,6 @@ static void free_super1(struct supertype *st) free(di); } st->sb = NULL; - if (is_clustered(st)) - cluster_release_dlmlock(st, lockid); } #ifndef MDASSEMBLE |