mirror of
https://github.com/torvalds/linux.git
synced 2025-12-07 20:06:24 +00:00
staging: lustre: Convert seq_ hash functions to return void
These functions don't need to return anything. No caller uses the return value. Miscellanea: Integrate the individual strings to reduce object size ~100 bytes. Signed-off-by: Joe Perches <joe@perches.com> Cc: Oleg Drokin <oleg.drokin@intel.com> Cc: Andreas Dilger <andreas.dilger@intel.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
8faeebdf15
commit
c0e134afc3
@@ -785,8 +785,8 @@ static inline void __cfs_hash_set_theta(struct cfs_hash *hs, int min, int max)
|
||||
|
||||
/* Generic debug formatting routines mainly for proc handler */
|
||||
struct seq_file;
|
||||
int cfs_hash_debug_header(struct seq_file *m);
|
||||
int cfs_hash_debug_str(struct cfs_hash *hs, struct seq_file *m);
|
||||
void cfs_hash_debug_header(struct seq_file *m);
|
||||
void cfs_hash_debug_str(struct cfs_hash *hs, struct seq_file *m);
|
||||
|
||||
/*
|
||||
* Generic djb2 hash algorithm for character arrays.
|
||||
|
||||
@@ -2008,14 +2008,10 @@ void cfs_hash_rehash_key(struct cfs_hash *hs, const void *old_key,
|
||||
}
|
||||
EXPORT_SYMBOL(cfs_hash_rehash_key);
|
||||
|
||||
int cfs_hash_debug_header(struct seq_file *m)
|
||||
void cfs_hash_debug_header(struct seq_file *m)
|
||||
{
|
||||
seq_printf(m, "%-*s%6s%6s%6s%6s%6s%6s%6s%7s%8s%8s%8s%s\n",
|
||||
CFS_HASH_BIGNAME_LEN,
|
||||
"name", "cur", "min", "max", "theta", "t-min", "t-max",
|
||||
"flags", "rehash", "count", "maxdep", "maxdepb",
|
||||
" distribution");
|
||||
return 0;
|
||||
seq_printf(m, "%-*s cur min max theta t-min t-max flags rehash count maxdep maxdepb distribution\n",
|
||||
CFS_HASH_BIGNAME_LEN, "name");
|
||||
}
|
||||
EXPORT_SYMBOL(cfs_hash_debug_header);
|
||||
|
||||
@@ -2043,7 +2039,7 @@ cfs_hash_full_nbkt(struct cfs_hash *hs)
|
||||
CFS_HASH_RH_NBKT(hs) : CFS_HASH_NBKT(hs);
|
||||
}
|
||||
|
||||
int cfs_hash_debug_str(struct cfs_hash *hs, struct seq_file *m)
|
||||
void cfs_hash_debug_str(struct cfs_hash *hs, struct seq_file *m)
|
||||
{
|
||||
int dist[8] = { 0, };
|
||||
int maxdep = -1;
|
||||
@@ -2098,7 +2094,5 @@ int cfs_hash_debug_str(struct cfs_hash *hs, struct seq_file *m)
|
||||
seq_printf(m, "%d%c", dist[i], (i == 7) ? '\n' : '/');
|
||||
|
||||
cfs_hash_unlock(hs, 0);
|
||||
|
||||
return 0;
|
||||
}
|
||||
EXPORT_SYMBOL(cfs_hash_debug_str);
|
||||
|
||||
Reference in New Issue
Block a user