Commit ccfb80c1 authored by James Simmons's avatar James Simmons Committed by Greg Kroah-Hartman

staging: lustre: libcfs: remove atomic cpt allocations

libcfs contains functions to perform atomic memory
operations. These functions have never been used
so remove them.
Signed-off-by: default avatarfrank zago <fzago@cray.com>
Signed-off-by: default avatarJames Simmons <uja.ornl@yahoo.com>
Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-6245
Reviewed-on: http://review.whamcloud.com/15913Reviewed-by: default avatarJohn L. Hammond <john.hammond@intel.com>
Reviewed-by: default avatarOleg Drokin <oleg.drokin@intel.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 9af4826a
...@@ -351,12 +351,6 @@ void cfs_percpt_lock_free(struct cfs_percpt_lock *pcl); ...@@ -351,12 +351,6 @@ void cfs_percpt_lock_free(struct cfs_percpt_lock *pcl);
void cfs_percpt_lock(struct cfs_percpt_lock *pcl, int index); void cfs_percpt_lock(struct cfs_percpt_lock *pcl, int index);
/* unlock private lock \a index of \a pcl */ /* unlock private lock \a index of \a pcl */
void cfs_percpt_unlock(struct cfs_percpt_lock *pcl, int index); void cfs_percpt_unlock(struct cfs_percpt_lock *pcl, int index);
/* create percpt (atomic) refcount based on @cptab */
atomic_t **cfs_percpt_atomic_alloc(struct cfs_cpt_table *cptab, int val);
/* destroy percpt refcount */
void cfs_percpt_atomic_free(atomic_t **refs);
/* return sum of all percpu refs */
int cfs_percpt_atomic_summary(atomic_t **refs);
/** Compile-time assertion. /** Compile-time assertion.
......
...@@ -142,44 +142,3 @@ cfs_percpt_unlock(struct cfs_percpt_lock *pcl, int index) ...@@ -142,44 +142,3 @@ cfs_percpt_unlock(struct cfs_percpt_lock *pcl, int index)
} }
} }
EXPORT_SYMBOL(cfs_percpt_unlock); EXPORT_SYMBOL(cfs_percpt_unlock);
/** free cpu-partition refcount */
void
cfs_percpt_atomic_free(atomic_t **refs)
{
cfs_percpt_free(refs);
}
EXPORT_SYMBOL(cfs_percpt_atomic_free);
/** allocate cpu-partition refcount with initial value @init_val */
atomic_t **
cfs_percpt_atomic_alloc(struct cfs_cpt_table *cptab, int init_val)
{
atomic_t **refs;
atomic_t *ref;
int i;
refs = cfs_percpt_alloc(cptab, sizeof(*ref));
if (!refs)
return NULL;
cfs_percpt_for_each(ref, i, refs)
atomic_set(ref, init_val);
return refs;
}
EXPORT_SYMBOL(cfs_percpt_atomic_alloc);
/** return sum of cpu-partition refs */
int
cfs_percpt_atomic_summary(atomic_t **refs)
{
atomic_t *ref;
int i;
int val = 0;
cfs_percpt_for_each(ref, i, refs)
val += atomic_read(ref);
return val;
}
EXPORT_SYMBOL(cfs_percpt_atomic_summary);
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment