aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux
diff options
context:
space:
mode:
authorDavid S. Miller <davem@davemloft.net>2015-03-18 12:46:48 -0400
committerDavid S. Miller <davem@davemloft.net>2015-03-18 12:47:50 -0400
commitb65885d29d41c7245bbd98769e781f77e8d9ed5b (patch)
tree9509ed7547a4788e818c3038f7ce38a8856cf1ef /include/linux
parenta61bfa65facebd64403c94ebdab50323ce8942b2 (diff)
parente2e21c1c5808e5dfd88d3606cd6386cf85f6f5b1 (diff)
downloadkernel_replicant_linux-b65885d29d41c7245bbd98769e781f77e8d9ed5b.tar.gz
kernel_replicant_linux-b65885d29d41c7245bbd98769e781f77e8d9ed5b.tar.bz2
kernel_replicant_linux-b65885d29d41c7245bbd98769e781f77e8d9ed5b.zip
Merge branch 'rhashtable_remove_shift'
Herbert Xu says: ==================== rhashtable: Kill redundant shift parameter I was trying to squeeze bucket_table->rehash in by downsizing bucket_table->size, only to find that my spot had been taken over by bucket_table->shift. These patches kill shift and makes me feel better :) v2 corrects the typo in the test_rhashtable changelog and also notes the min_shift parameter in the tipc patch changelog. ==================== Acked-by: Thomas Graf <tgraf@suug.ch> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/rhashtable.h10
1 files changed, 4 insertions, 6 deletions
diff --git a/include/linux/rhashtable.h b/include/linux/rhashtable.h
index 1695378b3c5b..99425f2be708 100644
--- a/include/linux/rhashtable.h
+++ b/include/linux/rhashtable.h
@@ -51,7 +51,6 @@ struct rhash_head {
* @size: Number of hash buckets
* @rehash: Current bucket being rehashed
* @hash_rnd: Random seed to fold into hash
- * @shift: Current size (1 << shift)
* @locks_mask: Mask to apply before accessing locks[]
* @locks: Array of spinlocks protecting individual buckets
* @walkers: List of active walkers
@@ -63,7 +62,6 @@ struct bucket_table {
unsigned int size;
unsigned int rehash;
u32 hash_rnd;
- u32 shift;
unsigned int locks_mask;
spinlock_t *locks;
struct list_head walkers;
@@ -85,8 +83,8 @@ struct rhashtable;
* @key_len: Length of key
* @key_offset: Offset of key in struct to be hashed
* @head_offset: Offset of rhash_head in struct to be hashed
- * @max_shift: Maximum number of shifts while expanding
- * @min_shift: Minimum number of shifts while shrinking
+ * @max_size: Maximum size while expanding
+ * @min_size: Minimum size while shrinking
* @nulls_base: Base value to generate nulls marker
* @locks_mul: Number of bucket locks to allocate per cpu (default: 128)
* @hashfn: Function to hash key
@@ -97,8 +95,8 @@ struct rhashtable_params {
size_t key_len;
size_t key_offset;
size_t head_offset;
- size_t max_shift;
- size_t min_shift;
+ unsigned int max_size;
+ unsigned int min_size;
u32 nulls_base;
size_t locks_mul;
rht_hashfn_t hashfn;