Searched refs:proto_tab (Results 1 - 6 of 6) sorted by relevance
/kernel/linux/linux-5.10/net/nfc/ |
H A D | af_nfc.c | 16 static const struct nfc_protocol *proto_tab[NFC_SOCKPROTO_MAX]; variable 30 if (proto_tab[proto] && try_module_get(proto_tab[proto]->owner)) { in nfc_sock_create() 31 rc = proto_tab[proto]->create(net, sock, proto_tab[proto], kern); in nfc_sock_create() 32 module_put(proto_tab[proto]->owner); in nfc_sock_create() 57 if (proto_tab[nfc_proto->id]) in nfc_proto_register() 60 proto_tab[nfc_proto->id] = nfc_proto; in nfc_proto_register() 73 proto_tab[nfc_proto->id] = NULL; in nfc_proto_unregister()
|
/kernel/linux/linux-6.6/net/nfc/ |
H A D | af_nfc.c | 16 static const struct nfc_protocol *proto_tab[NFC_SOCKPROTO_MAX]; variable 30 if (proto_tab[proto] && try_module_get(proto_tab[proto]->owner)) { in nfc_sock_create() 31 rc = proto_tab[proto]->create(net, sock, proto_tab[proto], kern); in nfc_sock_create() 32 module_put(proto_tab[proto]->owner); in nfc_sock_create() 57 if (proto_tab[nfc_proto->id]) in nfc_proto_register() 60 proto_tab[nfc_proto->id] = nfc_proto; in nfc_proto_register() 73 proto_tab[nfc_proto->id] = NULL; in nfc_proto_unregister()
|
/kernel/linux/linux-5.10/net/phonet/ |
H A D | af_phonet.c | 25 static const struct phonet_protocol *proto_tab[PHONET_NPROTO] __read_mostly; 35 pp = rcu_dereference(proto_tab[protocol]); in phonet_proto_get() 472 if (proto_tab[protocol]) in phonet_proto_register() 475 rcu_assign_pointer(proto_tab[protocol], pp); in phonet_proto_register() 486 BUG_ON(proto_tab[protocol] != pp); in phonet_proto_unregister() 487 RCU_INIT_POINTER(proto_tab[protocol], NULL); in phonet_proto_unregister()
|
/kernel/linux/linux-6.6/net/phonet/ |
H A D | af_phonet.c | 25 static const struct phonet_protocol *proto_tab[PHONET_NPROTO] __read_mostly; 35 pp = rcu_dereference(proto_tab[protocol]); in phonet_proto_get() 471 if (proto_tab[protocol]) in phonet_proto_register() 474 rcu_assign_pointer(proto_tab[protocol], pp); in phonet_proto_register() 485 BUG_ON(proto_tab[protocol] != pp); in phonet_proto_unregister() 486 RCU_INIT_POINTER(proto_tab[protocol], NULL); in phonet_proto_unregister()
|
/kernel/linux/linux-5.10/net/can/ |
H A D | af_can.c | 82 static const struct can_proto __rcu *proto_tab[CAN_NPROTO] __read_mostly; 101 cp = rcu_dereference(proto_tab[protocol]); in can_get_proto() 758 if (rcu_access_pointer(proto_tab[proto])) { in can_proto_register() 762 RCU_INIT_POINTER(proto_tab[proto], cp); in can_proto_register() 783 BUG_ON(rcu_access_pointer(proto_tab[proto]) != cp); in can_proto_unregister() 784 RCU_INIT_POINTER(proto_tab[proto], NULL); in can_proto_unregister()
|
/kernel/linux/linux-6.6/net/can/ |
H A D | af_can.c | 82 static const struct can_proto __rcu *proto_tab[CAN_NPROTO] __read_mostly; 101 cp = rcu_dereference(proto_tab[protocol]); in can_get_proto() 749 if (rcu_access_pointer(proto_tab[proto])) { in can_proto_register() 753 RCU_INIT_POINTER(proto_tab[proto], cp); in can_proto_register() 774 BUG_ON(rcu_access_pointer(proto_tab[proto]) != cp); in can_proto_unregister() 775 RCU_INIT_POINTER(proto_tab[proto], NULL); in can_proto_unregister()
|
Completed in 5 milliseconds