Lines Matching refs:l_new
372 struct htab_elem *__percpu *pptr, *l_new; in alloc_extra_elems() local
386 l_new = container_of(l, struct htab_elem, fnode); in alloc_extra_elems()
387 *per_cpu_ptr(pptr, cpu) = l_new; in alloc_extra_elems()
982 struct htab_elem *l_new, **pl_new; in alloc_htab_elem() local
991 l_new = *pl_new; in alloc_htab_elem()
999 l_new = container_of(l, struct htab_elem, fnode); in alloc_htab_elem()
1012 l_new = bpf_mem_cache_alloc(&htab->ma); in alloc_htab_elem()
1013 if (!l_new) { in alloc_htab_elem()
1014 l_new = ERR_PTR(-ENOMEM); in alloc_htab_elem()
1019 memcpy(l_new->key, key, key_size); in alloc_htab_elem()
1022 pptr = htab_elem_get_ptr(l_new, key_size); in alloc_htab_elem()
1028 bpf_mem_cache_free(&htab->ma, l_new); in alloc_htab_elem()
1029 l_new = ERR_PTR(-ENOMEM); in alloc_htab_elem()
1032 l_new->ptr_to_pptr = ptr; in alloc_htab_elem()
1039 htab_elem_set_ptr(l_new, key_size, pptr); in alloc_htab_elem()
1042 memcpy(l_new->key + round_up(key_size, 8), value, size); in alloc_htab_elem()
1045 l_new->key + round_up(key_size, 8), in alloc_htab_elem()
1049 l_new->hash = hash; in alloc_htab_elem()
1050 return l_new; in alloc_htab_elem()
1053 return l_new; in alloc_htab_elem()
1075 struct htab_elem *l_new = NULL, *l_old; in htab_map_update_elem() local
1143 l_new = alloc_htab_elem(htab, key, value, key_size, hash, false, false, in htab_map_update_elem()
1145 if (IS_ERR(l_new)) { in htab_map_update_elem()
1147 ret = PTR_ERR(l_new); in htab_map_update_elem()
1154 hlist_nulls_add_head_rcu(&l_new->hash_node, head); in htab_map_update_elem()
1194 struct htab_elem *l_new, *l_old = NULL; in htab_lru_map_update_elem() local
1220 l_new = prealloc_lru_pop(htab, key, hash); in htab_lru_map_update_elem()
1221 if (!l_new) in htab_lru_map_update_elem()
1224 l_new->key + round_up(map->key_size, 8), value); in htab_lru_map_update_elem()
1239 hlist_nulls_add_head_rcu(&l_new->hash_node, head); in htab_lru_map_update_elem()
1241 bpf_lru_node_set_ref(&l_new->lru_node); in htab_lru_map_update_elem()
1251 htab_lru_push_free(htab, l_new); in htab_lru_map_update_elem()
1263 struct htab_elem *l_new = NULL, *l_old; in __htab_percpu_map_update_elem() local
1299 l_new = alloc_htab_elem(htab, key, value, key_size, in __htab_percpu_map_update_elem()
1301 if (IS_ERR(l_new)) { in __htab_percpu_map_update_elem()
1302 ret = PTR_ERR(l_new); in __htab_percpu_map_update_elem()
1305 hlist_nulls_add_head_rcu(&l_new->hash_node, head); in __htab_percpu_map_update_elem()
1318 struct htab_elem *l_new = NULL, *l_old; in __htab_lru_percpu_map_update_elem() local
1345 l_new = prealloc_lru_pop(htab, key, hash); in __htab_lru_percpu_map_update_elem()
1346 if (!l_new) in __htab_lru_percpu_map_update_elem()
1367 pcpu_init_value(htab, htab_elem_get_ptr(l_new, key_size), in __htab_lru_percpu_map_update_elem()
1369 hlist_nulls_add_head_rcu(&l_new->hash_node, head); in __htab_lru_percpu_map_update_elem()
1370 l_new = NULL; in __htab_lru_percpu_map_update_elem()
1376 if (l_new) { in __htab_lru_percpu_map_update_elem()
1378 bpf_lru_push_free(&htab->lru, &l_new->lru_node); in __htab_lru_percpu_map_update_elem()