Lines Matching defs:nl_table

90 struct netlink_table *nl_table __read_mostly;
91 EXPORT_SYMBOL_GPL(nl_table);
135 /* nl_table locking explained:
532 struct netlink_table *table = &nl_table[protocol];
549 struct netlink_table *tbl = &nl_table[sk->sk_protocol];
572 struct netlink_table *table = &nl_table[sk->sk_protocol];
615 table = &nl_table[sk->sk_protocol];
692 if (!nl_table[protocol].registered) {
698 if (nl_table[protocol].registered &&
699 try_module_get(nl_table[protocol].module))
700 module = nl_table[protocol].module;
703 cb_mutex = nl_table[protocol].cb_mutex;
704 bind = nl_table[protocol].bind;
705 unbind = nl_table[protocol].unbind;
706 release = nl_table[protocol].release;
803 BUG_ON(nl_table[sk->sk_protocol].registered == 0);
804 if (--nl_table[sk->sk_protocol].registered == 0) {
807 old = nl_deref_protected(nl_table[sk->sk_protocol].listeners);
808 RCU_INIT_POINTER(nl_table[sk->sk_protocol].listeners, NULL);
810 nl_table[sk->sk_protocol].module = NULL;
811 nl_table[sk->sk_protocol].bind = NULL;
812 nl_table[sk->sk_protocol].unbind = NULL;
813 nl_table[sk->sk_protocol].flags = 0;
814 nl_table[sk->sk_protocol].registered = 0;
839 struct netlink_table *table = &nl_table[sk->sk_protocol];
941 return (nl_table[sock->sk->sk_protocol].flags & flag) ||
953 sk_add_bind_node(sk, &nl_table[sk->sk_protocol].mc_list);
966 groups = nl_table[sk->sk_protocol].groups;
967 if (!nl_table[sk->sk_protocol].registered) {
1395 listeners = rcu_dereference(nl_table[sk->sk_protocol].listeners);
1397 if (listeners && group - 1 < nl_table[sk->sk_protocol].groups)
1551 sk_for_each_bound(sk, &nl_table[ssk->sk_protocol].mc_list)
1639 sk_for_each_bound(sk, &nl_table[ssk->sk_protocol].mc_list)
2027 BUG_ON(!nl_table);
2060 if (!nl_table[unit].registered) {
2061 nl_table[unit].groups = groups;
2062 rcu_assign_pointer(nl_table[unit].listeners, listeners);
2063 nl_table[unit].cb_mutex = cb_mutex;
2064 nl_table[unit].module = module;
2066 nl_table[unit].bind = cfg->bind;
2067 nl_table[unit].unbind = cfg->unbind;
2068 nl_table[unit].release = cfg->release;
2069 nl_table[unit].flags = cfg->flags;
2071 nl_table[unit].registered = 1;
2074 nl_table[unit].registered++;
2103 struct netlink_table *tbl = &nl_table[sk->sk_protocol];
2149 struct netlink_table *tbl = &nl_table[ksk->sk_protocol];
2614 rhashtable_walk_enter(&nl_table[iter->link].hash, &iter->hti);
2851 nl_table[NETLINK_USERSOCK].groups = groups;
2852 rcu_assign_pointer(nl_table[NETLINK_USERSOCK].listeners, listeners);
2853 nl_table[NETLINK_USERSOCK].module = THIS_MODULE;
2854 nl_table[NETLINK_USERSOCK].registered = 1;
2855 nl_table[NETLINK_USERSOCK].flags = NL_CFG_F_NONROOT_SEND;
2926 nl_table = kcalloc(MAX_LINKS, sizeof(*nl_table), GFP_KERNEL);
2927 if (!nl_table)
2931 if (rhashtable_init(&nl_table[i].hash,
2934 rhashtable_destroy(&nl_table[i].hash);
2935 kfree(nl_table);
2950 panic("netlink_init: Cannot allocate nl_table\n");