diff options
author | Yaniv Kaul <ykaul@redhat.com> | 2019-07-30 10:15:42 +0300 |
---|---|---|
committer | Atin Mukherjee <amukherj@redhat.com> | 2019-08-05 03:08:13 +0000 |
commit | 2aeb9fb17087434d87497a85077073ea3bf94869 (patch) | |
tree | 3625e683a27b8719ee97d89702815c89b6c5d2e4 /xlators/mgmt/glusterd/src/glusterd-snapshot.c | |
parent | 2dd43d3e5b5305db3a5ecafabdd9cf8e7775ec75 (diff) |
multiple files: reduce minor work under RCU_READ_LOCK
1. Try to unlock faster - in error paths.
2. Remove memory allocations - do them before the lock.
Change-Id: I1e9ddd80b99de45ad0f557d62a5f28951dfd54c8
updates: bz#1193929
Signed-off-by: Yaniv Kaul <ykaul@redhat.com>
Diffstat (limited to 'xlators/mgmt/glusterd/src/glusterd-snapshot.c')
-rw-r--r-- | xlators/mgmt/glusterd/src/glusterd-snapshot.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/xlators/mgmt/glusterd/src/glusterd-snapshot.c b/xlators/mgmt/glusterd/src/glusterd-snapshot.c index 3cd9a505a9e..97bd9ec511d 100644 --- a/xlators/mgmt/glusterd/src/glusterd-snapshot.c +++ b/xlators/mgmt/glusterd/src/glusterd-snapshot.c @@ -217,13 +217,13 @@ glusterd_find_missed_snap(dict_t *rsp_dict, glusterd_volinfo_t *vol, ret = glusterd_add_missed_snaps_to_dict( rsp_dict, vol, brickinfo, brick_count + 1, op); if (ret) { + RCU_READ_UNLOCK; gf_msg(this->name, GF_LOG_ERROR, 0, GD_MSG_MISSED_SNAP_CREATE_FAIL, "Failed to add missed snapshot " "info for %s:%s in the " "rsp_dict", brickinfo->hostname, brickinfo->path); - RCU_READ_UNLOCK; goto out; } } |