mirror of
https://github.com/Fishwaldo/linux-bl808.git
synced 2025-06-17 20:25:19 +00:00
rhashtable: Introduce max_size/min_size
This patch adds the parameters max_size and min_size which are meant to replace max_shift and min_shift. Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
6aebd94084
commit
c2e213cff7
2 changed files with 12 additions and 4 deletions
|
@ -85,6 +85,8 @@ struct rhashtable;
|
|||
* @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,6 +99,8 @@ struct rhashtable_params {
|
|||
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;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue