From 4e7afab231e22fc740e2d8a39fd7eaefd1fa9f2f Mon Sep 17 00:00:00 2001 From: Ravishankar N Date: Thu, 14 Mar 2019 18:41:11 +0530 Subject: gfapi: add function to set client-pid This api offers the ability to set the pid of a client to a particular value, identical to how gluster fuse clients provide the --client-pid option. This is an internal API to be used by gluster processes only. See https://lists.gluster.org/pipermail/gluster-devel/2019-March/055925.html for more details. Currently glfsheal is the only proposed consumer. updates: bz#1693155 Change-Id: I0620be2127d79d69cdd57cffb29bba44e6e5da1f Signed-off-by: Ravishankar N (cherry picked from commit 08d502c3b05c6f7831bb4cc764bd458b405a99b1) --- api/src/glfs-internal.h | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'api/src/glfs-internal.h') diff --git a/api/src/glfs-internal.h b/api/src/glfs-internal.h index 40bbb8a9834..55401b2910e 100644 --- a/api/src/glfs-internal.h +++ b/api/src/glfs-internal.h @@ -702,4 +702,10 @@ void glfs_iatt_from_statx(struct iatt *, const struct glfs_stat *) GFAPI_PRIVATE(glfs_iatt_from_statx, 6.0); +/* + * This API is a per thread setting, similar to glfs_setfs{u/g}id, because of + * the call to syncopctx_setfspid. + */ +int +glfs_setfspid(struct glfs *, pid_t) GFAPI_PRIVATE(glfs_setfspid, 6.1); #endif /* !_GLFS_INTERNAL_H */ -- cgit