/net/tipc/ |
D | core.c | 54 struct tipc_net *tn = net_generic(net, tipc_net_id); in tipc_init_net() local 57 tn->net_id = 4711; in tipc_init_net() 58 tn->node_addr = 0; in tipc_init_net() 59 tn->trial_addr = 0; in tipc_init_net() 60 tn->addr_trial_end = 0; in tipc_init_net() 61 tn->capabilities = TIPC_NODE_CAPABILITIES; in tipc_init_net() 62 INIT_WORK(&tn->final_work.work, tipc_net_finalize_work); in tipc_init_net() 63 memset(tn->node_id, 0, sizeof(tn->node_id)); in tipc_init_net() 64 memset(tn->node_id_string, 0, sizeof(tn->node_id_string)); in tipc_init_net() 65 tn->mon_threshold = TIPC_DEF_MON_THRESHOLD; in tipc_init_net() [all …]
|
D | discover.c | 83 struct tipc_net *tn = tipc_net(net); in tipc_disc_init_msg() local 88 tipc_msg_init(tn->trial_addr, hdr, LINK_CONFIG, mtyp, in tipc_disc_init_msg() 92 msg_set_node_sig(hdr, tn->random); in tipc_disc_init_msg() 95 msg_set_bc_netid(hdr, tn->net_id); in tipc_disc_init_msg() 97 msg_set_peer_net_hash(hdr, tipc_net_hash_mixes(net, tn->random)); in tipc_disc_init_msg() 149 struct tipc_net *tn = tipc_net(net); in tipc_disc_addr_trial_msg() local 151 bool trial = time_before(jiffies, tn->addr_trial_end) && !self; in tipc_disc_addr_trial_msg() 158 if (dst != tn->trial_addr) in tipc_disc_addr_trial_msg() 162 tn->trial_addr = sugg_addr; in tipc_disc_addr_trial_msg() 164 tn->addr_trial_end = jiffies + msecs_to_jiffies(1000); in tipc_disc_addr_trial_msg() [all …]
|
D | net.c | 127 struct tipc_net *tn = tipc_net(net); in tipc_net_finalize() local 129 if (cmpxchg(&tn->node_addr, 0, addr)) in tipc_net_finalize() 149 struct tipc_net *tn = tipc_net(net); in tipc_sched_net_finalize() local 151 tn->final_work.net = net; in tipc_sched_net_finalize() 152 tn->final_work.addr = addr; in tipc_sched_net_finalize() 153 schedule_work(&tn->final_work.work); in tipc_sched_net_finalize() 171 struct tipc_net *tn = net_generic(net, tipc_net_id); in __tipc_nl_add_net() local 172 u64 *w0 = (u64 *)&tn->node_id[0]; in __tipc_nl_add_net() 173 u64 *w1 = (u64 *)&tn->node_id[8]; in __tipc_nl_add_net() 186 if (nla_put_u32(msg->skb, TIPC_NLA_NET_ID, tn->net_id)) in __tipc_nl_add_net() [all …]
|
D | addr.c | 57 struct tipc_net *tn = tipc_net(net); in tipc_set_node_id() local 60 memcpy(tn->node_id, id, NODE_ID_LEN); in tipc_set_node_id() 61 tipc_nodeid2string(tn->node_id_string, id); in tipc_set_node_id() 62 tn->trial_addr = tmp[0] ^ tmp[1] ^ tmp[2] ^ tmp[3]; in tipc_set_node_id() 64 tipc_own_id_string(net), tn->net_id); in tipc_set_node_id() 69 struct tipc_net *tn = tipc_net(net); in tipc_set_node_addr() local 72 tn->node_addr = addr; in tipc_set_node_addr() 77 tn->trial_addr = addr; in tipc_set_node_addr() 78 tn->addr_trial_end = jiffies; in tipc_set_node_addr()
|
D | name_distr.c | 209 struct tipc_net *tn = tipc_net(net); in tipc_publ_purge() local 212 spin_lock_bh(&tn->nametbl_lock); in tipc_publ_purge() 217 spin_unlock_bh(&tn->nametbl_lock); in tipc_publ_purge() 235 struct tipc_net *tn = net_generic(net, tipc_net_id); in tipc_dist_queue_purge() local 238 spin_lock_bh(&tn->nametbl_lock); in tipc_dist_queue_purge() 239 list_for_each_entry_safe(e, tmp, &tn->dist_queue, next) { in tipc_dist_queue_purge() 245 spin_unlock_bh(&tn->nametbl_lock); in tipc_dist_queue_purge() 303 struct tipc_net *tn = net_generic(net, tipc_net_id); in tipc_named_rcv() local 311 spin_lock_bh(&tn->nametbl_lock); in tipc_named_rcv() 325 spin_unlock_bh(&tn->nametbl_lock); in tipc_named_rcv() [all …]
|
D | bearer.c | 63 struct tipc_net *tn = tipc_net(net); in bearer_get() local 65 return rcu_dereference(tn->bearer_list[bearer_id]); in bearer_get() 174 struct tipc_net *tn = net_generic(net, tipc_net_id); in tipc_bearer_find() local 179 b = rtnl_dereference(tn->bearer_list[i]); in tipc_bearer_find() 193 struct tipc_net *tn = tipc_net(net); in tipc_bearer_get_name() local 199 b = rtnl_dereference(tn->bearer_list[bearer_id]); in tipc_bearer_get_name() 209 struct tipc_net *tn = net_generic(net, tipc_net_id); in tipc_bearer_add_dest() local 213 b = rcu_dereference(tn->bearer_list[bearer_id]); in tipc_bearer_add_dest() 221 struct tipc_net *tn = net_generic(net, tipc_net_id); in tipc_bearer_remove_dest() local 225 b = rcu_dereference(tn->bearer_list[bearer_id]); in tipc_bearer_remove_dest() [all …]
|
D | node.c | 271 struct tipc_net *tn = tipc_net(net); in tipc_node_find() local 276 hlist_for_each_entry_rcu(node, &tn->node_htable[thash], hash) { in tipc_node_find() 293 struct tipc_net *tn = tipc_net(net); in tipc_node_find_by_id() local 298 list_for_each_entry_rcu(n, &tn->node_list, list) { in tipc_node_find_by_id() 405 struct tipc_net *tn = net_generic(net, tipc_net_id); in tipc_node_create() local 411 spin_lock_bh(&tn->node_list_lock); in tipc_node_create() 429 tn->capabilities = TIPC_NODE_CAPABILITIES; in tipc_node_create() 430 list_for_each_entry_rcu(temp_node, &tn->node_list, list) { in tipc_node_create() 431 tn->capabilities &= temp_node->capabilities; in tipc_node_create() 482 hlist_add_head_rcu(&n->hash, &tn->node_htable[tipc_hashfn(addr)]); in tipc_node_create() [all …]
|
D | name_table.c | 425 struct tipc_net *tn = tipc_net(net); in tipc_nametbl_translate() local 426 bool legacy = tn->legacy_addr_format; in tipc_nametbl_translate() 615 struct tipc_net *tn = tipc_net(net); in tipc_nametbl_publish() local 619 spin_lock_bh(&tn->nametbl_lock); in tipc_nametbl_publish() 633 spin_unlock_bh(&tn->nametbl_lock); in tipc_nametbl_publish() 647 struct tipc_net *tn = tipc_net(net); in tipc_nametbl_withdraw() local 652 spin_lock_bh(&tn->nametbl_lock); in tipc_nametbl_withdraw() 664 spin_unlock_bh(&tn->nametbl_lock); in tipc_nametbl_withdraw() 679 struct tipc_net *tn = tipc_net(sub->net); in tipc_nametbl_subscribe() local 685 spin_lock_bh(&tn->nametbl_lock); in tipc_nametbl_subscribe() [all …]
|
/net/ipv4/ |
D | fib_trie.c | 173 static struct key_vector *resize(struct trie *t, struct key_vector *tn); 194 #define node_parent(tn) rtnl_dereference(tn_info(tn)->parent) argument 195 #define get_child(tn, i) rtnl_dereference((tn)->tnode[i]) argument 198 #define node_parent_rcu(tn) rcu_dereference_rtnl(tn_info(tn)->parent) argument 199 #define get_child_rcu(tn, i) rcu_dereference_rtnl((tn)->tnode[i]) argument 213 static inline unsigned long child_length(const struct key_vector *tn) in child_length() argument 215 return (1ul << tn->bits) & ~(1ul); in child_length() 381 struct key_vector *tn; in tnode_new() local 399 tn = tnode->kv; in tnode_new() 400 tn->key = (shift < KEYLENGTH) ? (key >> shift) << shift : 0; in tnode_new() [all …]
|
/net/netfilter/ |
D | xt_TEE.c | 65 struct tee_net *tn = net_generic(net, tee_net_id); in tee_netdev_event() local 68 mutex_lock(&tn->lock); in tee_netdev_event() 69 list_for_each_entry(priv, &tn->priv_list, list) { in tee_netdev_event() 87 mutex_unlock(&tn->lock); in tee_netdev_event() 94 struct tee_net *tn = net_generic(par->net, tee_net_id); in tee_tg_check() local 122 mutex_lock(&tn->lock); in tee_tg_check() 123 list_add(&priv->list, &tn->priv_list); in tee_tg_check() 124 mutex_unlock(&tn->lock); in tee_tg_check() 134 struct tee_net *tn = net_generic(par->net, tee_net_id); in tee_tg_destroy() local 138 mutex_lock(&tn->lock); in tee_tg_destroy() [all …]
|
/net/sched/ |
D | act_ipt.c | 100 struct tc_action_net *tn = net_generic(net, id); in __tcf_ipt_init() local 121 err = tcf_idr_check_alloc(tn, &index, a, bind); in __tcf_ipt_init() 132 tcf_idr_cleanup(tn, index); in __tcf_ipt_init() 141 tcf_idr_cleanup(tn, index); in __tcf_ipt_init() 146 ret = tcf_idr_create(tn, index, est, a, ops, bind, in __tcf_ipt_init() 149 tcf_idr_cleanup(tn, index); in __tcf_ipt_init() 323 struct tc_action_net *tn = net_generic(net, ipt_net_id); in tcf_ipt_walker() local 325 return tcf_generic_walker(tn, skb, cb, type, ops, extack); in tcf_ipt_walker() 330 struct tc_action_net *tn = net_generic(net, ipt_net_id); in tcf_ipt_search() local 332 return tcf_idr_search(tn, a, index); in tcf_ipt_search() [all …]
|
D | act_vlan.c | 107 struct tc_action_net *tn = net_generic(net, vlan_net_id); in tcf_vlan_init() local 134 err = tcf_idr_check_alloc(tn, &index, a, bind); in tcf_vlan_init() 150 tcf_idr_cleanup(tn, index); in tcf_vlan_init() 158 tcf_idr_cleanup(tn, index); in tcf_vlan_init() 172 tcf_idr_cleanup(tn, index); in tcf_vlan_init() 187 tcf_idr_cleanup(tn, index); in tcf_vlan_init() 193 ret = tcf_idr_create(tn, index, est, a, in tcf_vlan_init() 196 tcf_idr_cleanup(tn, index); in tcf_vlan_init() 300 struct tc_action_net *tn = net_generic(net, vlan_net_id); in tcf_vlan_walker() local 302 return tcf_generic_walker(tn, skb, cb, type, ops, extack); in tcf_vlan_walker() [all …]
|
D | act_simple.c | 91 struct tc_action_net *tn = net_generic(net, simp_net_id); in tcf_simp_init() local 113 err = tcf_idr_check_alloc(tn, &index, a, bind); in tcf_simp_init() 124 tcf_idr_cleanup(tn, index); in tcf_simp_init() 129 ret = tcf_idr_create(tn, index, est, a, in tcf_simp_init() 132 tcf_idr_cleanup(tn, index); in tcf_simp_init() 204 struct tc_action_net *tn = net_generic(net, simp_net_id); in tcf_simp_walker() local 206 return tcf_generic_walker(tn, skb, cb, type, ops, extack); in tcf_simp_walker() 211 struct tc_action_net *tn = net_generic(net, simp_net_id); in tcf_simp_search() local 213 return tcf_idr_search(tn, a, index); in tcf_simp_search() 231 struct tc_action_net *tn = net_generic(net, simp_net_id); in simp_init_net() local [all …]
|
D | act_connmark.c | 103 struct tc_action_net *tn = net_generic(net, connmark_net_id); in tcf_connmark_init() local 124 ret = tcf_idr_check_alloc(tn, &index, a, bind); in tcf_connmark_init() 126 ret = tcf_idr_create(tn, index, est, a, in tcf_connmark_init() 129 tcf_idr_cleanup(tn, index); in tcf_connmark_init() 208 struct tc_action_net *tn = net_generic(net, connmark_net_id); in tcf_connmark_walker() local 210 return tcf_generic_walker(tn, skb, cb, type, ops, extack); in tcf_connmark_walker() 215 struct tc_action_net *tn = net_generic(net, connmark_net_id); in tcf_connmark_search() local 217 return tcf_idr_search(tn, a, index); in tcf_connmark_search() 234 struct tc_action_net *tn = net_generic(net, connmark_net_id); in connmark_init_net() local 236 return tc_action_net_init(net, tn, &act_connmark_ops); in connmark_init_net()
|
D | act_skbmod.c | 89 struct tc_action_net *tn = net_generic(net, skbmod_net_id); in tcf_skbmod_init() local 133 err = tcf_idr_check_alloc(tn, &index, a, bind); in tcf_skbmod_init() 144 tcf_idr_cleanup(tn, index); in tcf_skbmod_init() 149 ret = tcf_idr_create(tn, index, est, a, in tcf_skbmod_init() 152 tcf_idr_cleanup(tn, index); in tcf_skbmod_init() 263 struct tc_action_net *tn = net_generic(net, skbmod_net_id); in tcf_skbmod_walker() local 265 return tcf_generic_walker(tn, skb, cb, type, ops, extack); in tcf_skbmod_walker() 270 struct tc_action_net *tn = net_generic(net, skbmod_net_id); in tcf_skbmod_search() local 272 return tcf_idr_search(tn, a, index); in tcf_skbmod_search() 290 struct tc_action_net *tn = net_generic(net, skbmod_net_id); in skbmod_init_net() local [all …]
|
D | act_gact.c | 58 struct tc_action_net *tn = net_generic(net, gact_net_id); in tcf_gact_init() local 99 err = tcf_idr_check_alloc(tn, &index, a, bind); in tcf_gact_init() 101 ret = tcf_idr_create(tn, index, est, a, in tcf_gact_init() 104 tcf_idr_cleanup(tn, index); in tcf_gact_init() 236 struct tc_action_net *tn = net_generic(net, gact_net_id); in tcf_gact_walker() local 238 return tcf_generic_walker(tn, skb, cb, type, ops, extack); in tcf_gact_walker() 243 struct tc_action_net *tn = net_generic(net, gact_net_id); in tcf_gact_search() local 245 return tcf_idr_search(tn, a, index); in tcf_gact_search() 277 struct tc_action_net *tn = net_generic(net, gact_net_id); in gact_init_net() local 279 return tc_action_net_init(net, tn, &act_gact_ops); in gact_init_net()
|
D | act_sample.c | 41 struct tc_action_net *tn = net_generic(net, sample_net_id); in tcf_sample_init() local 63 err = tcf_idr_check_alloc(tn, &index, a, bind); in tcf_sample_init() 71 ret = tcf_idr_create(tn, index, est, a, in tcf_sample_init() 74 tcf_idr_cleanup(tn, index); in tcf_sample_init() 249 struct tc_action_net *tn = net_generic(net, sample_net_id); in tcf_sample_walker() local 251 return tcf_generic_walker(tn, skb, cb, type, ops, extack); in tcf_sample_walker() 256 struct tc_action_net *tn = net_generic(net, sample_net_id); in tcf_sample_search() local 258 return tcf_idr_search(tn, a, index); in tcf_sample_search() 301 struct tc_action_net *tn = net_generic(net, sample_net_id); in sample_init_net() local 303 return tc_action_net_init(net, tn, &act_sample_ops); in sample_init_net()
|
D | act_mirred.c | 99 struct tc_action_net *tn = net_generic(net, mirred_net_id); in tcf_mirred_init() local 124 err = tcf_idr_check_alloc(tn, &index, a, bind); in tcf_mirred_init() 141 tcf_idr_cleanup(tn, index); in tcf_mirred_init() 148 tcf_idr_cleanup(tn, index); in tcf_mirred_init() 152 ret = tcf_idr_create(tn, index, est, a, in tcf_mirred_init() 155 tcf_idr_cleanup(tn, index); in tcf_mirred_init() 375 struct tc_action_net *tn = net_generic(net, mirred_net_id); in tcf_mirred_walker() local 377 return tcf_generic_walker(tn, skb, cb, type, ops, extack); in tcf_mirred_walker() 382 struct tc_action_net *tn = net_generic(net, mirred_net_id); in tcf_mirred_search() local 384 return tcf_idr_search(tn, a, index); in tcf_mirred_search() [all …]
|
D | act_skbedit.c | 92 struct tc_action_net *tn = net_generic(net, skbedit_net_id); in tcf_skbedit_init() local 151 err = tcf_idr_check_alloc(tn, &index, a, bind); in tcf_skbedit_init() 162 tcf_idr_cleanup(tn, index); in tcf_skbedit_init() 167 ret = tcf_idr_create(tn, index, est, a, in tcf_skbedit_init() 170 tcf_idr_cleanup(tn, index); in tcf_skbedit_init() 296 struct tc_action_net *tn = net_generic(net, skbedit_net_id); in tcf_skbedit_walker() local 298 return tcf_generic_walker(tn, skb, cb, type, ops, extack); in tcf_skbedit_walker() 303 struct tc_action_net *tn = net_generic(net, skbedit_net_id); in tcf_skbedit_search() local 305 return tcf_idr_search(tn, a, index); in tcf_skbedit_search() 335 struct tc_action_net *tn = net_generic(net, skbedit_net_id); in skbedit_init_net() local [all …]
|
D | act_nat.c | 41 struct tc_action_net *tn = net_generic(net, nat_net_id); in tcf_nat_init() local 61 err = tcf_idr_check_alloc(tn, &index, a, bind); in tcf_nat_init() 63 ret = tcf_idr_create(tn, index, est, a, in tcf_nat_init() 66 tcf_idr_cleanup(tn, index); in tcf_nat_init() 299 struct tc_action_net *tn = net_generic(net, nat_net_id); in tcf_nat_walker() local 301 return tcf_generic_walker(tn, skb, cb, type, ops, extack); in tcf_nat_walker() 306 struct tc_action_net *tn = net_generic(net, nat_net_id); in tcf_nat_search() local 308 return tcf_idr_search(tn, a, index); in tcf_nat_search() 325 struct tc_action_net *tn = net_generic(net, nat_net_id); in nat_init_net() local 327 return tc_action_net_init(net, tn, &act_nat_ops); in nat_init_net()
|
D | act_ctinfo.c | 162 struct tc_action_net *tn = net_generic(net, ctinfo_net_id); in tcf_ctinfo_init() local 213 err = tcf_idr_check_alloc(tn, &index, a, bind); in tcf_ctinfo_init() 215 ret = tcf_idr_create(tn, index, est, a, in tcf_ctinfo_init() 218 tcf_idr_cleanup(tn, index); in tcf_ctinfo_init() 351 struct tc_action_net *tn = net_generic(net, ctinfo_net_id); in tcf_ctinfo_walker() local 353 return tcf_generic_walker(tn, skb, cb, type, ops, extack); in tcf_ctinfo_walker() 358 struct tc_action_net *tn = net_generic(net, ctinfo_net_id); in tcf_ctinfo_search() local 360 return tcf_idr_search(tn, a, index); in tcf_ctinfo_search() 388 struct tc_action_net *tn = net_generic(net, ctinfo_net_id); in ctinfo_init_net() local 390 return tc_action_net_init(net, tn, &act_ctinfo_ops); in ctinfo_init_net()
|
D | act_bpf.c | 280 struct tc_action_net *tn = net_generic(net, bpf_net_id); in tcf_bpf_init() local 303 ret = tcf_idr_check_alloc(tn, &index, act, bind); in tcf_bpf_init() 305 ret = tcf_idr_create(tn, index, est, act, in tcf_bpf_init() 308 tcf_idr_cleanup(tn, index); in tcf_bpf_init() 394 struct tc_action_net *tn = net_generic(net, bpf_net_id); in tcf_bpf_walker() local 396 return tcf_generic_walker(tn, skb, cb, type, ops, extack); in tcf_bpf_walker() 401 struct tc_action_net *tn = net_generic(net, bpf_net_id); in tcf_bpf_search() local 403 return tcf_idr_search(tn, a, index); in tcf_bpf_search() 421 struct tc_action_net *tn = net_generic(net, bpf_net_id); in bpf_init_net() local 423 return tc_action_net_init(net, tn, &act_bpf_ops); in bpf_init_net()
|
D | act_ct.c | 38 struct tc_action_net tn; /* Must be first */ member 599 struct tc_ct_action_net *tn = net_generic(net, ct_net_id); in tcf_ct_fill_params() local 635 if (!tn->labels) { in tcf_ct_fill_params() 676 struct tc_action_net *tn = net_generic(net, ct_net_id); in tcf_ct_init() local 700 err = tcf_idr_check_alloc(tn, &index, a, bind); in tcf_ct_init() 705 err = tcf_idr_create(tn, index, est, a, in tcf_ct_init() 708 tcf_idr_cleanup(tn, index); in tcf_ct_init() 903 struct tc_action_net *tn = net_generic(net, ct_net_id); in tcf_ct_walker() local 905 return tcf_generic_walker(tn, skb, cb, type, ops, extack); in tcf_ct_walker() 910 struct tc_action_net *tn = net_generic(net, ct_net_id); in tcf_ct_search() local [all …]
|
D | act_mpls.c | 148 struct tc_action_net *tn = net_generic(net, mpls_net_id); in tcf_mpls_init() local 230 err = tcf_idr_check_alloc(tn, &index, a, bind); in tcf_mpls_init() 238 ret = tcf_idr_create(tn, index, est, a, in tcf_mpls_init() 241 tcf_idr_cleanup(tn, index); in tcf_mpls_init() 363 struct tc_action_net *tn = net_generic(net, mpls_net_id); in tcf_mpls_walker() local 365 return tcf_generic_walker(tn, skb, cb, type, ops, extack); in tcf_mpls_walker() 370 struct tc_action_net *tn = net_generic(net, mpls_net_id); in tcf_mpls_search() local 372 return tcf_idr_search(tn, a, index); in tcf_mpls_search() 390 struct tc_action_net *tn = net_generic(net, mpls_net_id); in mpls_init_net() local 392 return tc_action_net_init(net, tn, &act_mpls_ops); in mpls_init_net()
|
D | act_police.c | 33 struct tc_action_net *tn = net_generic(net, police_net_id); in tcf_police_walker() local 35 return tcf_generic_walker(tn, skb, cb, type, ops, extack); in tcf_police_walker() 59 struct tc_action_net *tn = net_generic(net, police_net_id); in tcf_police_init() local 81 err = tcf_idr_check_alloc(tn, &index, a, bind); in tcf_police_init() 89 ret = tcf_idr_create(tn, index, NULL, a, in tcf_police_init() 92 tcf_idr_cleanup(tn, index); in tcf_police_init() 378 struct tc_action_net *tn = net_generic(net, police_net_id); in tcf_police_search() local 380 return tcf_idr_search(tn, a, index); in tcf_police_search() 403 struct tc_action_net *tn = net_generic(net, police_net_id); in police_init_net() local 405 return tc_action_net_init(net, tn, &act_police_ops); in police_init_net()
|