summaryrefslogtreecommitdiffstats
path: root/rpc/xdr/src
diff options
context:
space:
mode:
Diffstat (limited to 'rpc/xdr/src')
-rw-r--r--rpc/xdr/src/glusterfs3.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/rpc/xdr/src/glusterfs3.h b/rpc/xdr/src/glusterfs3.h
index b3ee267b64d..c2fa15f9e79 100644
--- a/rpc/xdr/src/glusterfs3.h
+++ b/rpc/xdr/src/glusterfs3.h
@@ -279,4 +279,17 @@ gf_proto_upcall_from_upcall (gfs3_upcall_req *gf_up_req,
gf_up_req->flags = gf_up_data->flags;
gf_up_req->expire_time_attr = gf_up_data->expire_time_attr;
}
+
+static inline void
+gf_proto_upcall_to_upcall (gfs3_upcall_req *gf_up_req,
+ struct gf_upcall *gf_up_data)
+{
+ if (!gf_up_req || !gf_up_data)
+ return;
+
+ memcpy (gf_up_data->gfid, gf_up_req->gfid, 16);
+ gf_up_data->event_type = gf_up_req->event_type;
+ gf_up_data->flags = gf_up_req->flags;
+ gf_up_data->expire_time_attr = gf_up_req->expire_time_attr;
+}
#endif /* !_GLUSTERFS3_H */