summaryrefslogtreecommitdiffstats
path: root/xlators/features
diff options
context:
space:
mode:
authorJeff Darcy <jdarcy@redhat.com>2015-07-28 12:11:12 -0400
committerJeff Darcy <jdarcy@redhat.com>2015-09-01 04:55:15 -0700
commit0773ca67fdb60a142207759fa6c07a69882ce59c (patch)
tree027101fce644fe17e58c78321b1632f38aaed166 /xlators/features
parent038dfe57cf0c5944b0392332dbf5a00bb1208150 (diff)
all: reduce "inline" usage
There are three kinds of inline functions: plain inline, extern inline, and static inline. All three have been removed from .c files, except those in "contrib" which aren't our problem. Inlines in .h files, which are overwhelmingly "static inline" already, have generally been left alone. Over time we should be able to "lower" these into .c files, but that has to be done in a case-by-case fashion requiring more manual effort. This part was easy to do automatically without (as far as I can tell) any ill effect. In the process, several pieces of dead code were flagged by the compiler, and were removed. Change-Id: I56a5e614735c9e0a6ee420dab949eac22e25c155 BUG: 1245331 Signed-off-by: Jeff Darcy <jdarcy@redhat.com> Reviewed-on: http://review.gluster.org/11769 Tested-by: NetBSD Build System <jenkins@build.gluster.org> Reviewed-by: Dan Lambright <dlambrig@redhat.com> Reviewed-by: Kaleb KEITHLEY <kkeithle@redhat.com> Reviewed-by: Niels de Vos <ndevos@redhat.com> Reviewed-by: Raghavendra Bhat <raghavendra@redhat.com> Reviewed-by: Venky Shankar <vshankar@redhat.com>
Diffstat (limited to 'xlators/features')
-rw-r--r--xlators/features/bit-rot/src/bitd/bit-rot-scrub.c26
-rw-r--r--xlators/features/bit-rot/src/bitd/bit-rot-tbf.c4
-rw-r--r--xlators/features/bit-rot/src/bitd/bit-rot.c36
-rw-r--r--xlators/features/bit-rot/src/stub/bit-rot-stub.c32
-rw-r--r--xlators/features/changelog/lib/src/gf-changelog-reborp.c53
-rw-r--r--xlators/features/changelog/src/changelog-encoders.c2
-rw-r--r--xlators/features/changelog/src/changelog-ev-handle.c6
-rw-r--r--xlators/features/changelog/src/changelog-helpers.c26
-rw-r--r--xlators/features/changelog/src/changelog-rpc.c2
-rw-r--r--xlators/features/changelog/src/changelog.c2
-rw-r--r--xlators/features/changetimerecorder/src/changetimerecorder.c4
-rw-r--r--xlators/features/changetimerecorder/src/ctr-xlator-ctx.c6
-rw-r--r--xlators/features/index/src/index.c4
-rw-r--r--xlators/features/locks/src/entrylk.c4
-rw-r--r--xlators/features/locks/src/inodelk.c12
-rw-r--r--xlators/features/locks/src/reservelk.c2
-rw-r--r--xlators/features/marker/src/marker.c2
-rw-r--r--xlators/features/quota/src/quota.c18
18 files changed, 90 insertions, 151 deletions
diff --git a/xlators/features/bit-rot/src/bitd/bit-rot-scrub.c b/xlators/features/bit-rot/src/bitd/bit-rot-scrub.c
index c5f44b5b52f..4a74bbf7eef 100644
--- a/xlators/features/bit-rot/src/bitd/bit-rot-scrub.c
+++ b/xlators/features/bit-rot/src/bitd/bit-rot-scrub.c
@@ -43,7 +43,7 @@ struct br_fsscan_entry {
* NOTE: On success @xattr is not unref'd as @sign points
* to the dictionary value.
*/
-static inline int32_t
+static int32_t
bitd_fetch_signature (xlator_t *this, br_child_t *child,
fd_t *fd, dict_t **xattr, br_isignature_out_t **sign)
{
@@ -131,7 +131,7 @@ bitd_scrub_post_compute_check (xlator_t *this,
}
-static inline int32_t
+static int32_t
bitd_signature_staleness (xlator_t *this,
br_child_t *child, fd_t *fd,
int *stale, unsigned long *version)
@@ -191,7 +191,7 @@ bitd_scrub_pre_compute_check (xlator_t *this, br_child_t *child,
return ret;
}
-/* static inline int */
+/* static int */
int
bitd_compare_ckum (xlator_t *this,
br_isignature_out_t *sign,
@@ -429,13 +429,13 @@ wait_for_scrubbing (xlator_t *this, struct br_scanfs *fsscan)
pthread_cleanup_pop (0);
}
-static inline void
+static void
_br_fsscan_inc_entry_count (struct br_scanfs *fsscan)
{
fsscan->entries++;
}
-static inline void
+static void
_br_fsscan_dec_entry_count (struct br_scanfs *fsscan)
{
if (--fsscan->entries == 0) {
@@ -554,7 +554,7 @@ br_fsscan_deactivate (xlator_t *this, br_child_t *child)
return 0;
}
-static inline void
+static void
br_fsscanner_log_time (xlator_t *this, br_child_t *child, const char *sfx)
{
struct timeval tv = {0,};
@@ -589,7 +589,7 @@ br_fsscanner_wait_until_kicked (struct br_scanfs *fsscan)
pthread_cleanup_pop (0);
}
-static inline void
+static void
br_fsscanner_entry_control (xlator_t *this, br_child_t *child)
{
struct br_scanfs *fsscan = &child->fsscan;
@@ -603,7 +603,7 @@ br_fsscanner_entry_control (xlator_t *this, br_child_t *child)
UNLOCK (&child->lock);
}
-static inline void
+static void
br_fsscanner_exit_control (xlator_t *this, br_child_t *child)
{
struct br_scanfs *fsscan = &child->fsscan;
@@ -690,7 +690,7 @@ br_kickstart_scanner (struct gf_tw_timer_list *timer,
}
-static inline uint32_t
+static uint32_t
br_fsscan_calculate_delta (uint32_t times)
{
return times;
@@ -905,7 +905,7 @@ br_scrubber_calc_scale (xlator_t *this,
}
-static inline br_child_t *
+static br_child_t *
_br_scrubber_get_next_child (struct br_scrubber *fsscrub)
{
br_child_t *child = NULL;
@@ -916,7 +916,7 @@ _br_scrubber_get_next_child (struct br_scrubber *fsscrub)
return child;
}
-static inline void
+static void
_br_scrubber_get_entry (br_child_t *child, struct br_fsscan_entry **fsentry)
{
struct br_scanfs *fsscan = &child->fsscan;
@@ -928,7 +928,7 @@ _br_scrubber_get_entry (br_child_t *child, struct br_fsscan_entry **fsentry)
list_del_init (&(*fsentry)->list);
}
-static inline void
+static void
_br_scrubber_find_scrubbable_entry (struct br_scrubber *fsscrub,
struct br_fsscan_entry **fsentry)
{
@@ -1159,7 +1159,7 @@ br_scrubber_configure (xlator_t *this, br_private_t *priv,
return ret;
}
-static inline int32_t
+static int32_t
br_scrubber_fetch_option (xlator_t *this,
char *opt, dict_t *options, char **value)
{
diff --git a/xlators/features/bit-rot/src/bitd/bit-rot-tbf.c b/xlators/features/bit-rot/src/bitd/bit-rot-tbf.c
index d9543416540..f8b9b75d575 100644
--- a/xlators/features/bit-rot/src/bitd/bit-rot-tbf.c
+++ b/xlators/features/bit-rot/src/bitd/bit-rot-tbf.c
@@ -55,7 +55,7 @@ typedef struct br_tbf_throttle {
*/
#define BR_TBF_TOKENGEN_INTERVAL_USEC 600000
-static inline br_tbf_throttle_t *
+static br_tbf_throttle_t *
br_tbf_init_throttle (unsigned long tokens_required)
{
br_tbf_throttle_t *throttle = NULL;
@@ -137,7 +137,7 @@ void *br_tbf_tokengenerator (void *arg)
* under br_tbf_mod() context) and br_tbf_throttle(). *bucket is
* updated _after_ all the required variables are initialized.
*/
-static inline int32_t
+static int32_t
br_tbf_init_bucket (br_tbf_t *tbf, br_tbf_opspec_t *spec)
{
int ret = 0;
diff --git a/xlators/features/bit-rot/src/bitd/bit-rot.c b/xlators/features/bit-rot/src/bitd/bit-rot.c
index d9874660781..d6ae5e2fdd2 100644
--- a/xlators/features/bit-rot/src/bitd/bit-rot.c
+++ b/xlators/features/bit-rot/src/bitd/bit-rot.c
@@ -118,7 +118,7 @@ br_brick_fini (void *xl, char *brick, void *data)
* FIX: Send the string length as part of the signature struct and
* change stub to handle this change.
*/
-static inline br_isignature_t *
+static br_isignature_t *
br_prepare_signature (const unsigned char *sign,
unsigned long hashlen,
int8_t hashtype, br_object_t *object)
@@ -181,7 +181,7 @@ out:
/**
* Do a lookup on the gfid present within the object.
*/
-static inline int32_t
+static int32_t
br_object_lookup (xlator_t *this, br_object_t *object,
struct iatt *iatt, inode_t **linked_inode)
{
@@ -229,7 +229,7 @@ out:
* know that open is being done by bitd because syncop framework does not allow
* passing xdata -- may be use frame->root->pid itself.
*/
-static inline int32_t
+static int32_t
br_object_open (xlator_t *this,
br_object_t *object, inode_t *inode, fd_t **openfd)
{
@@ -372,14 +372,14 @@ br_calculate_obj_checksum (unsigned char *md,
return ret;
}
-static inline int32_t
+static int32_t
br_object_checksum (unsigned char *md,
br_object_t *object, fd_t *fd, struct iatt *iatt)
{
return br_calculate_obj_checksum (md, object->child, fd, iatt);
}
-static inline int32_t
+static int32_t
br_object_read_sign (inode_t *linked_inode, fd_t *fd, br_object_t *object,
struct iatt *iatt)
{
@@ -452,7 +452,7 @@ br_object_read_sign (inode_t *linked_inode, fd_t *fd, br_object_t *object,
return ret;
}
-static inline int br_object_sign_softerror (int32_t op_errno)
+static int br_object_sign_softerror (int32_t op_errno)
{
return ((op_errno == ENOENT) || (op_errno == ESTALE)
|| (op_errno == ENODATA));
@@ -562,7 +562,7 @@ br_object_resign (xlator_t *this,
* some form of priority scheduling and/or read burstness to avoid starving
* (or kicking) client I/O's.
*/
-static inline int32_t br_sign_object (br_object_t *object)
+static int32_t br_sign_object (br_object_t *object)
{
int32_t ret = -1;
inode_t *linked_inode = NULL;
@@ -631,7 +631,7 @@ static inline int32_t br_sign_object (br_object_t *object)
return ret;
}
-static inline br_object_t *__br_pick_object (br_private_t *priv)
+static br_object_t *__br_pick_object (br_private_t *priv)
{
br_object_t *object = NULL;
@@ -719,7 +719,7 @@ br_add_object_to_queue (struct gf_tw_timer_list *timer,
return;
}
-static inline br_object_t *
+static br_object_t *
br_initialize_object (xlator_t *this, br_child_t *child, changelog_event_t *ev)
{
br_object_t *object = NULL;
@@ -741,7 +741,7 @@ out:
return object;
}
-static inline struct gf_tw_timer_list *
+static struct gf_tw_timer_list *
br_initialize_timer (xlator_t *this, br_object_t *object, br_child_t *child,
changelog_event_t *ev)
{
@@ -872,17 +872,7 @@ br_fill_brick_spec (struct gf_brick_spec *brick, char *path)
brick->disconnected = NULL;
}
-static inline gf_boolean_t
-br_time_equal (br_child_t *child, struct timeval *tv)
-{
- if ((child->tv.tv_sec == tv->tv_sec) &&
- (child->tv.tv_usec == tv->tv_usec))
- return _gf_true;
-
- return _gf_false;
-}
-
-static inline gf_boolean_t
+static gf_boolean_t
br_check_object_need_sign (xlator_t *this, dict_t *xattr, br_child_t *child)
{
int32_t ret = -1;
@@ -1641,7 +1631,7 @@ notify (xlator_t *this, int32_t event, void *data, ...)
* Initialize signer specific structures, spawn worker threads.
*/
-static inline void
+static void
br_fini_signer (xlator_t *this, br_private_t *priv)
{
int i = 0;
@@ -1653,7 +1643,7 @@ br_fini_signer (xlator_t *this, br_private_t *priv)
pthread_cond_destroy (&priv->object_cond);
}
-static inline int32_t
+static int32_t
br_init_signer (xlator_t *this, br_private_t *priv)
{
int i = 0;
diff --git a/xlators/features/bit-rot/src/stub/bit-rot-stub.c b/xlators/features/bit-rot/src/stub/bit-rot-stub.c
index 9439f0cdfe7..85fad6925c1 100644
--- a/xlators/features/bit-rot/src/stub/bit-rot-stub.c
+++ b/xlators/features/bit-rot/src/stub/bit-rot-stub.c
@@ -148,7 +148,7 @@ fini (xlator_t *this)
return;
}
-static inline int
+static int
br_stub_alloc_versions (br_version_t **obuf,
br_signature_t **sbuf, size_t signaturelen)
{
@@ -178,13 +178,13 @@ br_stub_alloc_versions (br_version_t **obuf,
return -1;
}
-static inline void
+static void
br_stub_dealloc_versions (void *mem)
{
GF_FREE (mem);
}
-static inline br_stub_local_t *
+static br_stub_local_t *
br_stub_alloc_local (xlator_t *this)
{
br_stub_private_t *priv = this->private;
@@ -192,13 +192,13 @@ br_stub_alloc_local (xlator_t *this)
return mem_get0 (priv->local_pool);
}
-static inline void
+static void
br_stub_dealloc_local (br_stub_local_t *ptr)
{
mem_put (ptr);
}
-static inline int
+static int
br_stub_prepare_version_request (xlator_t *this, dict_t *dict,
br_version_t *obuf, unsigned long oversion)
{
@@ -211,7 +211,7 @@ br_stub_prepare_version_request (xlator_t *this, dict_t *dict,
(void *)obuf, sizeof (br_version_t));
}
-static inline int
+static int
br_stub_prepare_signing_request (dict_t *dict,
br_signature_t *sbuf,
br_isignature_t *sign, size_t signaturelen)
@@ -230,7 +230,7 @@ br_stub_prepare_signing_request (dict_t *dict,
* context, hence the inode is marked dirty. this routine also
* initializes the transient inode version.
*/
-static inline int
+static int
br_stub_init_inode_versions (xlator_t *this, fd_t *fd, inode_t *inode,
unsigned long version, gf_boolean_t markdirty,
gf_boolean_t bad_object)
@@ -271,7 +271,7 @@ free_ctx:
/**
* modify the ongoing version of an inode.
*/
-static inline int
+static int
br_stub_mod_inode_versions (xlator_t *this,
fd_t *fd, inode_t *inode, unsigned long version)
{
@@ -296,7 +296,7 @@ unblock:
return ret;
}
-static inline void
+static void
br_stub_fill_local (br_stub_local_t *local,
call_stub_t *stub, fd_t *fd, inode_t *inode, uuid_t gfid,
int versioningtype, unsigned long memversion)
@@ -311,7 +311,7 @@ br_stub_fill_local (br_stub_local_t *local,
gf_uuid_copy (local->u.context.gfid, gfid);
}
-static inline void
+static void
br_stub_cleanup_local (br_stub_local_t *local)
{
local->fopstub = NULL;
@@ -597,7 +597,7 @@ br_stub_fd_versioning (xlator_t *this, call_frame_t *frame,
return ret;
}
-static inline int
+static int
br_stub_perform_incversioning (xlator_t *this,
call_frame_t *frame, call_stub_t *stub,
fd_t *fd, br_stub_inode_ctx_t *ctx)
@@ -703,7 +703,7 @@ orderq (struct list_head *elem1, struct list_head *elem2)
return (s1->v > s2->v);
}
-static inline int
+static int
br_stub_compare_sign_version (xlator_t *this,
inode_t *inode,
br_signature_t *sbuf,
@@ -753,7 +753,7 @@ br_stub_compare_sign_version (xlator_t *this,
return ret;
}
-static inline int
+static int
br_stub_prepare_signature (xlator_t *this,
dict_t *dict, inode_t *inode,
br_isignature_t *sign, int *fakesuccess)
@@ -1447,7 +1447,7 @@ br_stub_getxattr_cbk (call_frame_t *frame, void *cookie, xlator_t *this,
return 0;
}
-static inline void
+static void
br_stub_send_stub_init_time (call_frame_t *frame, xlator_t *this)
{
int op_ret = 0;
@@ -2268,7 +2268,7 @@ unwind:
* successfully allocate the dict? Posix does not treat call back xdata
* creattion failure as the lookup failure.
*/
-static inline int32_t
+static int32_t
br_stub_lookup_version (xlator_t *this,
uuid_t gfid, inode_t *inode, dict_t *xattr)
{
@@ -2571,7 +2571,7 @@ br_stub_noop (call_frame_t *frame, void *cookie, xlator_t *this,
return 0;
}
-static inline void
+static void
br_stub_send_ipc_fop (xlator_t *this, fd_t *fd, unsigned long releaseversion,
int sign_info)
{
diff --git a/xlators/features/changelog/lib/src/gf-changelog-reborp.c b/xlators/features/changelog/lib/src/gf-changelog-reborp.c
index e6bb19e3696..665a6d0a5da 100644
--- a/xlators/features/changelog/lib/src/gf-changelog-reborp.c
+++ b/xlators/features/changelog/lib/src/gf-changelog-reborp.c
@@ -93,55 +93,6 @@ gf_changelog_connection_janitor (void *arg)
return NULL;
}
-static inline void
-__gf_changelog_set_conn_state (gf_changelog_t *entry,
- gf_changelog_conn_state_t state)
-{
- entry->connstate = state;
-}
-
-/**
- * state check login to gaurd access object after free
- */
-static inline void
-gf_changelog_check_event (gf_private_t *priv,
- gf_changelog_t *entry, rpcsvc_event_t event)
-{
- gf_boolean_t needfree = _gf_false;
- gf_changelog_conn_state_t laststate;
- /**
- * need to handle couple of connection states to gaurd correct
- * freeing of object.
- */
- LOCK (&entry->statelock);
- {
- laststate = entry->connstate;
- if (event == RPCSVC_EVENT_ACCEPT) {
- __gf_changelog_set_conn_state
- (entry, GF_CHANGELOG_CONN_STATE_ACCEPTED);
-
- if (laststate == GF_CHANGELOG_CONN_STATE_DISCONNECTED)
- needfree = _gf_true;
- }
-
- if (event == RPCSVC_EVENT_DISCONNECT) {
- __gf_changelog_set_conn_state
- (entry, GF_CHANGELOG_CONN_STATE_DISCONNECTED);
-
- if (laststate == GF_CHANGELOG_CONN_STATE_ACCEPTED)
- needfree = _gf_true;
- }
- }
- UNLOCK (&entry->statelock);
-
- /**
- * TODO:
- * Handle the race between ACCEPT and DISCONNECT in the
- * reconnect code. So purging of entry is deliberately
- * avoided here. It will be handled in the reconnect code.
- */
-}
-
int
gf_changelog_reborp_rpcsvc_notify (rpcsvc_t *rpc, void *mydata,
rpcsvc_event_t event, void *data)
@@ -181,8 +132,6 @@ gf_changelog_reborp_rpcsvc_notify (rpcsvc_t *rpc, void *mydata,
break;
}
- /* gf_changelog_check_event (priv, entry, event); */
-
return 0;
}
@@ -238,7 +187,7 @@ gf_changelog_invoke_callback (gf_changelog_t *entry,
* dynamically allocated and ordered.
*/
-inline int
+int
__is_expected_sequence (struct gf_event_list *ev, struct gf_event *event)
{
return (ev->next_seq == event->seq);
diff --git a/xlators/features/changelog/src/changelog-encoders.c b/xlators/features/changelog/src/changelog-encoders.c
index 2808b654119..95030236636 100644
--- a/xlators/features/changelog/src/changelog-encoders.c
+++ b/xlators/features/changelog/src/changelog-encoders.c
@@ -128,7 +128,7 @@ del_entry_free_fn (void *data)
* try to write all data in one shot
*/
-static inline void
+static void
changelog_encode_write_xtra (changelog_log_data_t *cld,
char *buffer, size_t *off, gf_boolean_t encode)
{
diff --git a/xlators/features/changelog/src/changelog-ev-handle.c b/xlators/features/changelog/src/changelog-ev-handle.c
index 5167b56ed88..79652a969bd 100644
--- a/xlators/features/changelog/src/changelog-ev-handle.c
+++ b/xlators/features/changelog/src/changelog-ev-handle.c
@@ -42,7 +42,7 @@ changelog_event_dispatch_cbk (struct rpc_req *req,
}
/* dispatcher RPC */
-inline int
+int
changelog_dispatch_vec (call_frame_t *frame, xlator_t *this,
struct rpc_clnt *rpc, struct ev_rpc_vec *vec)
{
@@ -243,7 +243,7 @@ changelog_ev_cleanup_connections (xlator_t *this, changelog_clnt_t *c_clnt)
* a performance bottleneck.
*/
-static inline changelog_rpc_clnt_t *
+static changelog_rpc_clnt_t *
get_client (changelog_clnt_t *c_clnt, struct list_head **next)
{
changelog_rpc_clnt_t *crpc = NULL;
@@ -262,7 +262,7 @@ get_client (changelog_clnt_t *c_clnt, struct list_head **next)
return crpc;
}
-static inline void
+static void
put_client (changelog_clnt_t *c_clnt, changelog_rpc_clnt_t *crpc)
{
LOCK (&c_clnt->active_lock);
diff --git a/xlators/features/changelog/src/changelog-helpers.c b/xlators/features/changelog/src/changelog-helpers.c
index d67be6f9838..6ca77e990cc 100644
--- a/xlators/features/changelog/src/changelog-helpers.c
+++ b/xlators/features/changelog/src/changelog-helpers.c
@@ -58,7 +58,7 @@ changelog_thread_cleanup (xlator_t *this, pthread_t thr_id)
return ret;
}
-inline void *
+void *
changelog_get_usable_buffer (changelog_local_t *local)
{
changelog_log_data_t *cld = NULL;
@@ -73,7 +73,7 @@ changelog_get_usable_buffer (changelog_local_t *local)
return cld->cld_iobuf->ptr;
}
-static inline int
+static int
changelog_selector_index (unsigned int selector)
{
return (ffs (selector) - 1);
@@ -183,7 +183,7 @@ changelog_cleanup_event_selection (xlator_t *this,
return LOCK_DESTROY (&selection->reflock);
}
-static inline void
+static void
changelog_perform_dispatch (xlator_t *this,
changelog_priv_t *priv, void *mem, size_t size)
{
@@ -215,7 +215,7 @@ changelog_dispatch_event (xlator_t *this,
}
}
-inline void
+void
changelog_set_usable_record_and_length (changelog_local_t *local,
size_t len, int xr)
{
@@ -255,7 +255,7 @@ changelog_local_cleanup (xlator_t *xl, changelog_local_t *local)
mem_put (local);
}
-inline int
+int
changelog_write (int fd, char *buffer, size_t len)
{
ssize_t size = 0;
@@ -965,7 +965,7 @@ changelog_start_next_change (xlator_t *this,
/**
* return the length of entry
*/
-inline size_t
+size_t
changelog_entry_length ()
{
return sizeof (changelog_log_data_t);
@@ -1054,7 +1054,7 @@ out:
return ret;
}
-inline int
+int
changelog_handle_change (xlator_t *this,
changelog_priv_t *priv, changelog_log_data_t *cld)
{
@@ -1615,7 +1615,7 @@ changelog_inode_ctx_get (xlator_t *this,
* then there is no need to record an update (as the equality of the two version
* signifies an update was recorded in the current time slice).
*/
-inline void
+void
changelog_update (xlator_t *this, changelog_priv_t *priv,
changelog_local_t *local, changelog_log_type type)
{
@@ -1683,7 +1683,7 @@ changelog_update (xlator_t *this, changelog_priv_t *priv,
* not incremented fop count but color is assigned black.
*/
-inline void
+void
changelog_color_fop_and_inc_cnt (xlator_t *this, changelog_priv_t *priv,
changelog_local_t *local)
{
@@ -1699,7 +1699,7 @@ changelog_color_fop_and_inc_cnt (xlator_t *this, changelog_priv_t *priv,
}
/* Increments the respective fop counter based on the fop color */
-inline void
+void
changelog_inc_fop_cnt (xlator_t *this, changelog_priv_t *priv,
changelog_local_t *local)
{
@@ -1729,7 +1729,7 @@ changelog_inc_fop_cnt (xlator_t *this, changelog_priv_t *priv,
}
/* Decrements the respective fop counter based on the fop color */
-inline void
+void
changelog_dec_fop_cnt (xlator_t *this, changelog_priv_t *priv,
changelog_local_t *local)
{
@@ -1781,7 +1781,7 @@ changelog_dec_fop_cnt (xlator_t *this, changelog_priv_t *priv,
/* Write to a pipe setup between changelog main thread and changelog
* rollover thread to initiate explicit rollover of changelog journal.
*/
-inline int
+int
changelog_barrier_notify (changelog_priv_t *priv, char *buf)
{
int ret = 0;
@@ -1793,7 +1793,7 @@ changelog_barrier_notify (changelog_priv_t *priv, char *buf)
}
/* Clean up flags set on barrier notification */
-inline void
+void
changelog_barrier_cleanup (xlator_t *this, changelog_priv_t *priv,
struct list_head *queue)
{
diff --git a/xlators/features/changelog/src/changelog-rpc.c b/xlators/features/changelog/src/changelog-rpc.c
index 76052a27a9c..b07030ec28e 100644
--- a/xlators/features/changelog/src/changelog-rpc.c
+++ b/xlators/features/changelog/src/changelog-rpc.c
@@ -187,7 +187,7 @@ changelog_rpc_clnt_cleanup (changelog_rpc_clnt_t *crpc)
GF_FREE (crpc);
}
-static inline changelog_rpc_clnt_t *
+static changelog_rpc_clnt_t *
changelog_rpc_clnt_init (xlator_t *this,
changelog_probe_req *rpc_req, changelog_clnt_t *c_clnt)
{
diff --git a/xlators/features/changelog/src/changelog.c b/xlators/features/changelog/src/changelog.c
index acd0d42323a..29e37a7ad56 100644
--- a/xlators/features/changelog/src/changelog.c
+++ b/xlators/features/changelog/src/changelog.c
@@ -2351,7 +2351,7 @@ changelog_barrier_pthread_init (xlator_t *this, changelog_priv_t *priv)
}
/* Destroy barrier related condition variables and locks */
-static inline void
+static void
changelog_barrier_pthread_destroy (changelog_priv_t *priv)
{
pthread_mutex_destroy (&priv->bn.bnotify_mutex);
diff --git a/xlators/features/changetimerecorder/src/changetimerecorder.c b/xlators/features/changetimerecorder/src/changetimerecorder.c
index 7fd62584752..5df9cb9097b 100644
--- a/xlators/features/changetimerecorder/src/changetimerecorder.c
+++ b/xlators/features/changetimerecorder/src/changetimerecorder.c
@@ -79,7 +79,7 @@ What is pending:
/* This function doesnot write anything to the db,
* just created the local variable
* for the frame and sets values for the ctr_db_record */
-static inline int
+static int
ctr_lookup_wind(call_frame_t *frame,
xlator_t *this,
gf_ctr_inode_context_t *ctr_inode_cx)
@@ -154,7 +154,7 @@ out:
/* This function inserts the ctr_db_record populated by ctr_lookup_wind
* in to the db. It also destroys the frame->local created by ctr_lookup_wind */
-static inline int
+static int
ctr_lookup_unwind (call_frame_t *frame,
xlator_t *this)
{
diff --git a/xlators/features/changetimerecorder/src/ctr-xlator-ctx.c b/xlators/features/changetimerecorder/src/ctr-xlator-ctx.c
index b5a54c0b5e4..c5900eac929 100644
--- a/xlators/features/changetimerecorder/src/ctr-xlator-ctx.c
+++ b/xlators/features/changetimerecorder/src/ctr-xlator-ctx.c
@@ -17,7 +17,7 @@
(ctr_hard_link->list.next == ctr_hard_link->list.prev)
-static inline void
+static void
fini_ctr_hard_link (ctr_hard_link_t **ctr_hard_link) {
GF_ASSERT (ctr_hard_link);
@@ -246,7 +246,7 @@ out:
/* Delete all hardlinks */
-static inline int
+static int
ctr_delete_all_hard_link (xlator_t *this,
ctr_xlator_ctx_t *ctr_xlator_ctx)
{
@@ -277,7 +277,7 @@ ctr_delete_all_hard_link (xlator_t *this,
/* Please lock the inode before using this function */
-static inline ctr_xlator_ctx_t *
+static ctr_xlator_ctx_t *
__get_ctr_xlator_ctx (xlator_t *this,
inode_t *inode)
{
diff --git a/xlators/features/index/src/index.c b/xlators/features/index/src/index.c
index 03e1075b133..2bba6630bde 100644
--- a/xlators/features/index/src/index.c
+++ b/xlators/features/index/src/index.c
@@ -27,7 +27,7 @@ __index_dequeue (struct list_head *callstubs)
return stub;
}
-inline static void
+static void
__index_enqueue (struct list_head *callstubs, call_stub_t *stub)
{
list_add_tail (&stub->list, callstubs);
@@ -539,7 +539,7 @@ xattrop_index_action (xlator_t *this, inode_t *inode, dict_t *xattr,
return;
}
-static inline gf_boolean_t
+static gf_boolean_t
index_xattrop_track (xlator_t *this, gf_xattrop_flags_t flags, dict_t *dict)
{
index_priv_t *priv = this->private;
diff --git a/xlators/features/locks/src/entrylk.c b/xlators/features/locks/src/entrylk.c
index 701121b90b9..31553c12be2 100644
--- a/xlators/features/locks/src/entrylk.c
+++ b/xlators/features/locks/src/entrylk.c
@@ -93,7 +93,7 @@ names_conflict (const char *n1, const char *n2)
}
-static inline int
+static int
__same_entrylk_owner (pl_entry_lock_t *l1, pl_entry_lock_t *l2)
{
return (is_same_lkowner (&l1->owner, &l2->owner) &&
@@ -101,7 +101,7 @@ __same_entrylk_owner (pl_entry_lock_t *l1, pl_entry_lock_t *l2)
}
/* Just as in inodelk, allow conflicting name locks from same (lk_owner, conn)*/
-static inline int
+static int
__conflicting_entrylks (pl_entry_lock_t *l1, pl_entry_lock_t *l2)
{
if (names_conflict (l1->basename, l2->basename)
diff --git a/xlators/features/locks/src/inodelk.c b/xlators/features/locks/src/inodelk.c
index df882f508f8..1564f26b8fb 100644
--- a/xlators/features/locks/src/inodelk.c
+++ b/xlators/features/locks/src/inodelk.c
@@ -18,19 +18,19 @@
#include "locks.h"
#include "common.h"
-inline void
+void
__delete_inode_lock (pl_inode_lock_t *lock)
{
list_del_init (&lock->list);
}
-static inline void
+static void
__pl_inodelk_ref (pl_inode_lock_t *lock)
{
lock->ref++;
}
-inline void
+void
__pl_inodelk_unref (pl_inode_lock_t *lock)
{
lock->ref--;
@@ -41,7 +41,7 @@ __pl_inodelk_unref (pl_inode_lock_t *lock)
}
/* Check if 2 inodelks are conflicting on type. Only 2 shared locks don't conflict */
-static inline int
+static int
inodelk_type_conflict (pl_inode_lock_t *l1, pl_inode_lock_t *l2)
{
if (l2->fl_type == F_WRLCK || l1->fl_type == F_WRLCK)
@@ -115,7 +115,7 @@ inodelk_overlap (pl_inode_lock_t *l1, pl_inode_lock_t *l2)
}
/* Returns true if the 2 inodelks have the same owner */
-static inline int
+static int
same_inodelk_owner (pl_inode_lock_t *l1, pl_inode_lock_t *l2)
{
return (is_same_lkowner (&l1->owner, &l2->owner) &&
@@ -826,7 +826,7 @@ pl_finodelk (call_frame_t *frame, xlator_t *this,
}
-static inline int32_t
+static int32_t
__get_inodelk_dom_count (pl_dom_list_t *dom)
{
pl_inode_lock_t *lock = NULL;
diff --git a/xlators/features/locks/src/reservelk.c b/xlators/features/locks/src/reservelk.c
index b0a858f3d80..8eb08d0ef79 100644
--- a/xlators/features/locks/src/reservelk.c
+++ b/xlators/features/locks/src/reservelk.c
@@ -66,7 +66,7 @@ out:
return ret_lock;
}
-static inline int
+static int
__same_owner_reservelk (posix_lock_t *l1, posix_lock_t *l2)
{
return (is_same_lkowner (&l1->owner, &l2->owner));
diff --git a/xlators/features/marker/src/marker.c b/xlators/features/marker/src/marker.c
index 2ebbde2d75b..401feb9a4d0 100644
--- a/xlators/features/marker/src/marker.c
+++ b/xlators/features/marker/src/marker.c
@@ -2259,7 +2259,7 @@ out:
return ret;
}
-static inline gf_boolean_t
+static gf_boolean_t
marker_xattr_cleanup_cmd (dict_t *dict)
{
return (dict_get (dict, VIRTUAL_QUOTA_XATTR_CLEANUP_KEY) != NULL);
diff --git a/xlators/features/quota/src/quota.c b/xlators/features/quota/src/quota.c
index 30445c4feaa..1a8aa87a2f6 100644
--- a/xlators/features/quota/src/quota.c
+++ b/xlators/features/quota/src/quota.c
@@ -185,7 +185,7 @@ out:
}
-static inline quota_local_t *
+static quota_local_t *
quota_local_new ()
{
quota_local_t *local = NULL;
@@ -268,7 +268,7 @@ quota_dentry_del (quota_inode_ctx_t *ctx, const char *name, uuid_t par)
UNLOCK (&ctx->lock);
}
-static inline inode_t*
+static inode_t*
__quota_inode_parent (inode_t *inode, uuid_t pargfid, const char *name)
{
inode_t *parent = NULL;
@@ -278,7 +278,7 @@ __quota_inode_parent (inode_t *inode, uuid_t pargfid, const char *name)
return parent;
}
-static inline inode_t*
+static inode_t*
quota_inode_parent (inode_t *inode, uuid_t pargfid, const char *name)
{
inode_t *parent = NULL;
@@ -509,7 +509,7 @@ out:
inode_unref (cur_inode);
}
-static inline void
+static void
quota_link_count_decrement (call_frame_t *frame)
{
call_frame_t *tmpframe = NULL;
@@ -553,7 +553,7 @@ out:
return;
}
-static inline void
+static void
quota_handle_validate_error (call_frame_t *frame, int32_t op_ret,
int32_t op_errno)
{
@@ -649,7 +649,7 @@ unwind:
}
-static inline uint64_t
+static uint64_t
quota_time_elapsed (struct timeval *now, struct timeval *then)
{
return (now->tv_sec - then->tv_sec);
@@ -674,7 +674,7 @@ quota_timeout (struct timeval *tv, int32_t timeout)
/* Return: 1 if new entry added
* 0 no entry added
*/
-static inline int32_t
+static int32_t
quota_add_parent (struct list_head *list, char *name, uuid_t pgfid)
{
quota_dentry_t *entry = NULL;
@@ -706,7 +706,7 @@ out:
* context and add unique parent to the list
* Returns number of dentry added to the list
*/
-static inline int32_t
+static int32_t
quota_add_parents_from_ctx (quota_inode_ctx_t *ctx, struct list_head *list)
{
int ret = 0;
@@ -1407,7 +1407,7 @@ out:
return parent;
}
-static inline int
+static int
quota_get_limits (xlator_t *this, dict_t *dict, int64_t *hard_lim,
int64_t *soft_lim, int64_t *object_hard_limit,
int64_t *object_soft_limit)