Lines Matching refs:n_bits
33 size_t n_bits; member
39 size_t n_bits);
43 size_t n_bits) in tlpm_add() argument
48 n = (n_bits + 7) / 8; in tlpm_add()
51 node = tlpm_match(list, key, n_bits); in tlpm_add()
52 if (node && node->n_bits == n_bits) { in tlpm_add()
63 node->n_bits = n_bits; in tlpm_add()
83 size_t n_bits) in tlpm_match() argument
95 for (i = 0; i < n_bits && i < list->n_bits; ++i) { in tlpm_match()
101 if (i >= list->n_bits) { in tlpm_match()
102 if (!best || i > best->n_bits) in tlpm_match()
112 size_t n_bits) in tlpm_delete() argument
114 struct tlpm_node *best = tlpm_match(list, key, n_bits); in tlpm_delete()
117 if (!best || best->n_bits != n_bits) in tlpm_delete()
188 l2 = tlpm_add(l2, t1->key, t1->n_bits); in test_lpm_order()
198 assert(t1->n_bits == t2->n_bits); in test_lpm_order()
199 for (j = 0; j < t1->n_bits; ++j) in test_lpm_order()
270 assert(t->n_bits == value[keysize]); in test_lpm_map()
271 for (j = 0; j < t->n_bits; ++j) in test_lpm_map()
286 key->prefixlen = list->n_bits; in test_lpm_map()
290 list = tlpm_delete(list, list->key, list->n_bits); in test_lpm_map()
307 assert(t->n_bits == value[keysize]); in test_lpm_map()
308 for (j = 0; j < t->n_bits; ++j) in test_lpm_map()