X-Git-Url: http://git.cascardo.eti.br/?a=blobdiff_plain;f=lib%2Ftest_rhashtable.c;h=2bc403d8f9ee80a19a1e31d206a1cd5e5e632311;hb=970282d0e1404b23f9d7ec6a676fa76ff15b3376;hp=f6ce291b68e79f9af9b6ecdf506300f499987059;hpb=ee92259849b1616e4c23121f78eb1342d2b1ce1e;p=cascardo%2Flinux.git diff --git a/lib/test_rhashtable.c b/lib/test_rhashtable.c index f6ce291b68e7..2bc403d8f9ee 100644 --- a/lib/test_rhashtable.c +++ b/lib/test_rhashtable.c @@ -80,7 +80,7 @@ static void test_bucket_stats(struct rhashtable *ht, bool quiet) rcu_cnt = cnt = 0; if (!quiet) - pr_info(" [%#4x/%zu]", i, tbl->size); + pr_info(" [%#4x/%u]", i, tbl->size); rht_for_each_entry_rcu(obj, pos, tbl, i, node) { cnt++; @@ -201,9 +201,8 @@ static int __init test_rht_init(void) .key_offset = offsetof(struct test_obj, value), .key_len = sizeof(int), .hashfn = jhash, + .max_size = 2, /* we expand/shrink manually here */ .nulls_base = (3U << RHT_BASE_SHIFT), - .grow_decision = rht_grow_above_75, - .shrink_decision = rht_shrink_below_30, }; int err; @@ -223,6 +222,11 @@ static int __init test_rht_init(void) return err; } +static void __exit test_rht_exit(void) +{ +} + module_init(test_rht_init); +module_exit(test_rht_exit); MODULE_LICENSE("GPL v2");