summaryrefslogtreecommitdiffstats
path: root/xlators/mgmt/glusterd/src/glusterd-op-sm.h
diff options
context:
space:
mode:
authorKaushal M <kaushal@redhat.com>2015-01-06 18:23:41 +0530
committerKrishnan Parthasarathi <kparthas@redhat.com>2015-03-03 23:50:22 -0800
commit673ba2659cebe22ee30c43f9fb080f330150f55e (patch)
treef91e83be5cfae7a08febfda420b33e05ed0b964f /xlators/mgmt/glusterd/src/glusterd-op-sm.h
parentef061b67f1b80c147c1959b896f7c9bdff01af96 (diff)
glusterd: Replace libglusterfs lists with liburcu lists
This patch replaces usage of the libglusterfs lists data structures and API in glusterd with the lists data structures and API from liburcu. The liburcu data structes and APIs are a drop-in replacement for libglusterfs lists. All usages have been changed to keep the code consistent, and free from confusion. NOTE: glusterd_conf_t->xprt_list still uses the libglusterfs data structures and API, as it holds rpc_transport_t objects, which is not a part of glusterd and is not being changed in this patch. This change was developed on the git branch at [1]. This commit is a combination of the following commits on the development branch. 6dac576 Replace libglusterfs lists with liburcu lists a51b5ab Fix compilation issues d98a06f Fix merge issues a5d918e Remove merge remnant 1cca113 More style cleanup 1917be3 Address review comments on 9624/1 8d10f13 Use cds_lists for glusterd_svc_t 524ad5d Add rculist header in glusterd-conn-helper.c 646f294 glusterd: add list_add_order API honouring rcu [1]: https://github.com/kshlm/glusterfs/tree/urcu Change-Id: Ic613c5b6e496a677b9d3de15fc042a0492109fb0 BUG: 1191030 Signed-off-by: Kaushal M <kaushal@redhat.com> Signed-off-by: Krishnan Parthasarathi <kparthas@redhat.com> Reviewed-on: http://review.gluster.org/9624 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Atin Mukherjee <amukherj@redhat.com> Reviewed-by: Gaurav Kumar Garg <ggarg@redhat.com> Reviewed-by: Anand Nekkunti <anekkunt@redhat.com>
Diffstat (limited to 'xlators/mgmt/glusterd/src/glusterd-op-sm.h')
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-op-sm.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/xlators/mgmt/glusterd/src/glusterd-op-sm.h b/xlators/mgmt/glusterd/src/glusterd-op-sm.h
index e306ccc6bde..0ca1b5bb1dc 100644
--- a/xlators/mgmt/glusterd/src/glusterd-op-sm.h
+++ b/xlators/mgmt/glusterd/src/glusterd-op-sm.h
@@ -70,7 +70,7 @@ typedef enum glusterd_op_sm_event_type_ {
struct glusterd_op_sm_event_ {
- struct list_head list;
+ struct cds_list_head list;
void *ctx;
glusterd_op_sm_event_type_t event;
uuid_t txn_id;
@@ -96,13 +96,13 @@ struct glusterd_op_info_ {
int32_t brick_pending_count;
int32_t op_count;
glusterd_op_t op;
- struct list_head op_peers;
+ struct cds_list_head op_peers;
void *op_ctx;
rpcsvc_request_t *req;
int32_t op_ret;
int32_t op_errno;
char *op_errstr;
- struct list_head pending_bricks;
+ struct cds_list_head pending_bricks;
};
typedef struct glusterd_op_info_ glusterd_op_info_t;
@@ -239,7 +239,7 @@ char*
glusterd_op_sm_event_name_get (int event);
int32_t
glusterd_op_bricks_select (glusterd_op_t op, dict_t *dict, char **op_errstr,
- struct list_head *selected, dict_t *rsp_dict);
+ struct cds_list_head *selected, dict_t *rsp_dict);
int
glusterd_brick_op_build_payload (glusterd_op_t op, glusterd_brickinfo_t *brickinfo,
gd1_mgmt_brick_op_req **req, dict_t *dict);