Symbol: net
crypto/af_alg.c
503
static int alg_create(struct net *net, struct socket *sock, int protocol,
crypto/af_alg.c
515
sk = sk_alloc(net, PF_ALG, GFP_KERNEL, &alg_proto, kern);
crypto/crypto_user.c
168
struct net *net = sock_net(in_skb->sk);
crypto/crypto_user.c
202
return nlmsg_unicast(net->crypto_nlsk, skb, NETLINK_CB(in_skb).portid);
crypto/crypto_user.c
413
struct net *net = sock_net(skb->sk);
crypto/crypto_user.c
444
err = netlink_dump_start(net->crypto_nlsk, skb, nlh, &c);
crypto/crypto_user.c
468
static int __net_init crypto_netlink_init(struct net *net)
crypto/crypto_user.c
474
net->crypto_nlsk = netlink_kernel_create(net, NETLINK_CRYPTO, &cfg);
crypto/crypto_user.c
475
return net->crypto_nlsk == NULL ? -ENOMEM : 0;
crypto/crypto_user.c
478
static void __net_exit crypto_netlink_exit(struct net *net)
crypto/crypto_user.c
480
netlink_kernel_release(net->crypto_nlsk);
crypto/crypto_user.c
481
net->crypto_nlsk = NULL;
drivers/base/core.c
4979
struct net_device *net = to_net_dev(dev);
drivers/base/core.c
4982
"n%u", net->ifindex);
drivers/connector/connector.c
172
static int cn_bind(struct net *net, int group)
drivers/connector/connector.c
176
if (ns_capable(net->user_ns, CAP_NET_ADMIN))
drivers/firewire/net.c
1200
static int fwnet_open(struct net_device *net)
drivers/firewire/net.c
1202
struct fwnet_device *dev = netdev_priv(net);
drivers/firewire/net.c
1209
netif_start_queue(net);
drivers/firewire/net.c
1219
static int fwnet_stop(struct net_device *net)
drivers/firewire/net.c
1221
struct fwnet_device *dev = netdev_priv(net);
drivers/firewire/net.c
1223
netif_stop_queue(net);
drivers/firewire/net.c
1229
static netdev_tx_t fwnet_tx(struct sk_buff *skb, struct net_device *net)
drivers/firewire/net.c
1232
struct fwnet_device *dev = netdev_priv(net);
drivers/firewire/net.c
1354
net->stats.tx_dropped++;
drivers/firewire/net.c
1355
net->stats.tx_errors++;
drivers/firewire/net.c
1377
static void fwnet_init_dev(struct net_device *net)
drivers/firewire/net.c
1379
net->header_ops = &fwnet_header_ops;
drivers/firewire/net.c
1380
net->netdev_ops = &fwnet_netdev_ops;
drivers/firewire/net.c
1381
net->watchdog_timeo = 2 * HZ;
drivers/firewire/net.c
1382
net->flags = IFF_BROADCAST | IFF_MULTICAST;
drivers/firewire/net.c
1383
net->features = NETIF_F_HIGHDMA;
drivers/firewire/net.c
1384
net->addr_len = FWNET_ALEN;
drivers/firewire/net.c
1385
net->hard_header_len = FWNET_HLEN;
drivers/firewire/net.c
1386
net->type = ARPHRD_IEEE1394;
drivers/firewire/net.c
1387
net->tx_queue_len = FWNET_TX_QUEUE_LEN;
drivers/firewire/net.c
1388
net->ethtool_ops = &fwnet_ethtool_ops;
drivers/firewire/net.c
1440
struct net_device *net;
drivers/firewire/net.c
1450
net = dev->netdev;
drivers/firewire/net.c
1454
net = alloc_netdev(sizeof(*dev), "firewire%d", NET_NAME_UNKNOWN,
drivers/firewire/net.c
1456
if (net == NULL) {
drivers/firewire/net.c
1462
SET_NETDEV_DEV(net, card->device);
drivers/firewire/net.c
1463
dev = netdev_priv(net);
drivers/firewire/net.c
1474
dev->netdev = net;
drivers/firewire/net.c
1486
net->mtu = 1500U;
drivers/firewire/net.c
1487
net->min_mtu = ETH_MIN_MTU;
drivers/firewire/net.c
1488
net->max_mtu = 4096U;
drivers/firewire/net.c
1495
dev_addr_set(net, ha.u);
drivers/firewire/net.c
1497
memset(net->broadcast, -1, net->addr_len);
drivers/firewire/net.c
1499
ret = register_netdev(net);
drivers/firewire/net.c
1504
dev_notice(&net->dev, "IP over IEEE 1394 on card %s\n",
drivers/firewire/net.c
1509
unregister_netdev(net);
drivers/firewire/net.c
1513
free_netdev(net);
drivers/firewire/net.c
1559
struct net_device *net;
drivers/firewire/net.c
1564
net = dev->netdev;
drivers/firewire/net.c
1569
unregister_netdev(net);
drivers/firewire/net.c
1578
free_netdev(net);
drivers/firewire/net.c
207
static int fwnet_header_create(struct sk_buff *skb, struct net_device *net,
drivers/firewire/net.c
216
if (net->flags & (IFF_LOOPBACK | IFF_NOARP)) {
drivers/firewire/net.c
217
memset(h->h_dest, 0, net->addr_len);
drivers/firewire/net.c
219
return net->hard_header_len;
drivers/firewire/net.c
223
memcpy(h->h_dest, daddr, net->addr_len);
drivers/firewire/net.c
225
return net->hard_header_len;
drivers/firewire/net.c
228
return -net->hard_header_len;
drivers/firewire/net.c
234
struct net_device *net;
drivers/firewire/net.c
239
net = neigh->dev;
drivers/firewire/net.c
242
memcpy(h->h_dest, neigh->ha, net->addr_len);
drivers/firewire/net.c
254
const struct net_device *net, const unsigned char *haddr)
drivers/firewire/net.c
256
memcpy((u8 *)hh->hh_data + HH_DATA_OFF(FWNET_HLEN), haddr, net->addr_len);
drivers/firewire/net.c
355
static struct fwnet_partial_datagram *fwnet_pd_new(struct net_device *net,
drivers/firewire/net.c
373
new->skb = dev_alloc_skb(dg_size + LL_RESERVED_SPACE(net));
drivers/firewire/net.c
377
skb_reserve(new->skb, LL_RESERVED_SPACE(net));
drivers/firewire/net.c
481
static int fwnet_finish_incoming_packet(struct net_device *net,
drivers/firewire/net.c
499
skb->dev = net;
drivers/firewire/net.c
506
if (dev_hard_header(skb, net, ether_type,
drivers/firewire/net.c
507
is_broadcast ? net->broadcast : net->dev_addr,
drivers/firewire/net.c
517
if (memcmp(eth->h_dest, net->broadcast,
drivers/firewire/net.c
518
net->addr_len) == 0)
drivers/firewire/net.c
525
if (memcmp(eth->h_dest, net->dev_addr, net->addr_len))
drivers/firewire/net.c
543
net->stats.rx_errors++;
drivers/firewire/net.c
544
net->stats.rx_dropped++;
drivers/firewire/net.c
546
net->stats.rx_packets++;
drivers/firewire/net.c
547
net->stats.rx_bytes += len;
drivers/firewire/net.c
553
net->stats.rx_errors++;
drivers/firewire/net.c
554
net->stats.rx_dropped++;
drivers/firewire/net.c
566
struct net_device *net = dev->netdev;
drivers/firewire/net.c
593
skb = dev_alloc_skb(len + LL_RESERVED_SPACE(net));
drivers/firewire/net.c
595
net->stats.rx_dropped++;
drivers/firewire/net.c
599
skb_reserve(skb, LL_RESERVED_SPACE(net));
drivers/firewire/net.c
602
return fwnet_finish_incoming_packet(net, skb, source_node_id,
drivers/firewire/net.c
643
pd = fwnet_pd_new(net, peer, datagram_label,
drivers/firewire/net.c
658
pd = fwnet_pd_new(net, peer, datagram_label,
drivers/firewire/net.c
691
return fwnet_finish_incoming_packet(net, skb, source_node_id,
drivers/gpu/drm/nouveau/nvkm/engine/gr/ga102.c
276
const struct netlist_image *net;
drivers/gpu/drm/nouveau/nvkm/engine/gr/ga102.c
287
net = (const void *)fw->data;
drivers/gpu/drm/nouveau/nvkm/engine/gr/ga102.c
289
net->header.version, net->header.regions);
drivers/gpu/drm/nouveau/nvkm/engine/gr/ga102.c
291
for (i = 0; i < net->header.regions; i++) {
drivers/gpu/drm/nouveau/nvkm/engine/gr/ga102.c
292
const struct netlist_region *reg = &net->regions[i];
drivers/infiniband/core/addr.c
232
rdma_find_ndev_for_src_ip_rcu(struct net *net, const struct sockaddr *src_in)
drivers/infiniband/core/addr.c
239
dev = __ip_dev_find(net,
drivers/infiniband/core/addr.c
247
for_each_netdev_rcu(net, dev) {
drivers/infiniband/core/addr.c
248
if (ipv6_chk_addr(net,
drivers/infiniband/core/addr.c
267
dev = dev_get_by_index(dev_addr->net, dev_addr->bound_dev_if);
drivers/infiniband/core/addr.c
276
dev = rdma_find_ndev_for_src_ip_rcu(dev_addr->net, addr);
drivers/infiniband/core/addr.c
386
rt = ip_route_output_key(addr->net, &fl4);
drivers/infiniband/core/addr.c
416
dst = ip6_dst_lookup_flow(addr->net, NULL, &fl6, NULL);
drivers/infiniband/core/addr.c
520
addr->net = dev_net(ndev);
drivers/infiniband/core/addr.c
527
addr->net = &init_net;
drivers/infiniband/core/addr.c
542
if (!addr->net) {
drivers/infiniband/core/addr.c
724
dev_addr.net = &init_net;
drivers/infiniband/core/addr.c
808
dev_addr.net = &init_net;
drivers/infiniband/core/cma.c
1010
__rdma_create_id(struct net *net, rdma_cm_event_handler event_handler,
drivers/infiniband/core/cma.c
1040
id_priv->id.route.addr.dev_addr.net = get_net(net);
drivers/infiniband/core/cma.c
1052
__rdma_create_kernel_id(struct net *net, rdma_cm_event_handler event_handler,
drivers/infiniband/core/cma.c
1058
ret = __rdma_create_id(net, event_handler, context, ps, qp_type, NULL);
drivers/infiniband/core/cma.c
174
static struct cma_pernet *cma_pernet(struct net *net)
drivers/infiniband/core/cma.c
176
return net_generic(net, cma_pernet_id);
drivers/infiniband/core/cma.c
180
struct xarray *cma_pernet_xa(struct net *net, enum rdma_ucm_port_space ps)
drivers/infiniband/core/cma.c
1802
if (net_eq(dev_net(net_dev), addr->dev_addr.net) &&
drivers/infiniband/core/cma.c
182
struct cma_pernet *pernet = cma_pernet(net);
drivers/infiniband/core/cma.c
1993
struct net *net = id_priv->id.route.addr.dev_addr.net;
drivers/infiniband/core/cma.c
2001
cma_ps_remove(net, bind_list->ps, bind_list->port);
drivers/infiniband/core/cma.c
2022
ndev = dev_get_by_index(dev_addr->net,
drivers/infiniband/core/cma.c
2088
put_net(id_priv->id.route.addr.dev_addr.net);
drivers/infiniband/core/cma.c
219
static int cma_ps_alloc(struct net *net, enum rdma_ucm_port_space ps,
drivers/infiniband/core/cma.c
222
struct xarray *xa = cma_pernet_xa(net, ps);
drivers/infiniband/core/cma.c
227
static struct rdma_bind_list *cma_ps_find(struct net *net,
drivers/infiniband/core/cma.c
2287
id_priv = __rdma_create_id(listen_id->route.addr.dev_addr.net,
drivers/infiniband/core/cma.c
230
struct xarray *xa = cma_pernet_xa(net, ps);
drivers/infiniband/core/cma.c
2344
struct net *net = listen_id->route.addr.dev_addr.net;
drivers/infiniband/core/cma.c
2348
id_priv = __rdma_create_id(net, listen_id->event_handler,
drivers/infiniband/core/cma.c
235
static void cma_ps_remove(struct net *net, enum rdma_ucm_port_space ps,
drivers/infiniband/core/cma.c
238
struct xarray *xa = cma_pernet_xa(net, ps);
drivers/infiniband/core/cma.c
2608
conn_id = __rdma_create_id(listen_id->id.route.addr.dev_addr.net,
drivers/infiniband/core/cma.c
2724
struct net *net = id_priv->id.route.addr.dev_addr.net;
drivers/infiniband/core/cma.c
2737
__rdma_create_id(net, cma_listen_handler, id_priv,
drivers/infiniband/core/cma.c
3144
ndev = dev_get_by_index(addr->dev_addr.net,
drivers/infiniband/core/cma.c
3693
ret = cma_ps_alloc(id_priv->id.route.addr.dev_addr.net, ps, bind_list,
drivers/infiniband/core/cma.c
3754
struct net *net = id_priv->id.route.addr.dev_addr.net;
drivers/infiniband/core/cma.c
3758
inet_get_local_port_range(net, &low, &high);
drivers/infiniband/core/cma.c
3766
bind_list = cma_ps_find(net, ps, (unsigned short)rover);
drivers/infiniband/core/cma.c
3842
bind_list = cma_ps_find(id_priv->id.route.addr.dev_addr.net, ps, snum);
drivers/infiniband/core/cma.c
4044
struct net *net = id_priv->id.route.addr.dev_addr.net;
drivers/infiniband/core/cma.c
4046
id_priv->afonly = net->ipv6.sysctl.bindv6only;
drivers/infiniband/core/cma.c
4876
ndev = dev_get_by_index(dev_addr->net, dev_addr->bound_dev_if);
drivers/infiniband/core/cma.c
5049
ndev = dev_get_by_index(dev_addr->net, dev_addr->bound_dev_if);
drivers/infiniband/core/cma.c
5166
(net_eq(dev_net(ndev), dev_addr->net)) &&
drivers/infiniband/core/cma.c
5457
static int cma_init_net(struct net *net)
drivers/infiniband/core/cma.c
5459
struct cma_pernet *pernet = cma_pernet(net);
drivers/infiniband/core/cma.c
5469
static void cma_exit_net(struct net *net)
drivers/infiniband/core/cma.c
5471
struct cma_pernet *pernet = cma_pernet(net);
drivers/infiniband/core/cma.c
683
if (!rdma_dev_access_netns(device, id_priv->id.route.addr.dev_addr.net))
drivers/infiniband/core/cma.c
707
pdev = dev_get_by_index_rcu(dev_addr->net, bound_if_index);
drivers/infiniband/core/cma.c
721
if (!net_eq(dev_net(ndev), dev_addr->net) ||
drivers/infiniband/core/cma.c
738
ndev = dev_get_by_index(dev_addr->net, bound_if_index);
drivers/infiniband/core/cma.c
744
ndev = dev_get_by_index(dev_addr->net, bound_if_index);
drivers/infiniband/core/core_priv.h
316
struct ib_device *ib_device_get_by_index(const struct net *net, u32 index);
drivers/infiniband/core/core_priv.h
68
possible_net_t net;
drivers/infiniband/core/core_priv.h
76
static inline struct rdma_dev_net *rdma_net_to_dev_net(struct net *net)
drivers/infiniband/core/core_priv.h
78
return net_generic(net, rdma_dev_net_id);
drivers/infiniband/core/device.c
1126
static void rdma_dev_exit_net(struct net *net)
drivers/infiniband/core/device.c
1128
struct rdma_dev_net *rnet = rdma_net_to_dev_net(net);
drivers/infiniband/core/device.c
1155
rdma_dev_change_netns(dev, net, &init_net);
drivers/infiniband/core/device.c
1166
static __net_init int rdma_dev_init_net(struct net *net)
drivers/infiniband/core/device.c
1168
struct rdma_dev_net *rnet = rdma_net_to_dev_net(net);
drivers/infiniband/core/device.c
1173
write_pnet(&rnet->net, net);
drivers/infiniband/core/device.c
1180
if (net_eq(net, &init_net))
drivers/infiniband/core/device.c
1203
rdma_dev_exit_net(net);
drivers/infiniband/core/device.c
143
bool rdma_dev_access_netns(const struct ib_device *dev, const struct net *net)
drivers/infiniband/core/device.c
146
net_eq(read_pnet(&dev->coredev.rdma_net), net));
drivers/infiniband/core/device.c
162
const struct net *net;
drivers/infiniband/core/device.c
1678
static int rdma_dev_change_netns(struct ib_device *device, struct net *cur_net,
drivers/infiniband/core/device.c
1679
struct net *net)
drivers/infiniband/core/device.c
169
net = &init_net;
drivers/infiniband/core/device.c
1704
write_pnet(&device->coredev.rdma_net, net);
drivers/infiniband/core/device.c
171
net = read_pnet(&dev->coredev.rdma_net);
drivers/infiniband/core/device.c
173
return ns_capable(net->user_ns, CAP_NET_RAW);
drivers/infiniband/core/device.c
1745
struct net *net;
drivers/infiniband/core/device.c
1748
net = get_net_ns_by_fd(ns_fd);
drivers/infiniband/core/device.c
1749
if (IS_ERR(net)) {
drivers/infiniband/core/device.c
1750
ret = PTR_ERR(net);
drivers/infiniband/core/device.c
1754
if (!netlink_ns_capable(skb, net->user_ns, CAP_NET_ADMIN)) {
drivers/infiniband/core/device.c
1771
ret = rdma_dev_change_netns(dev, current->nsproxy->net_ns, net);
drivers/infiniband/core/device.c
1774
put_net(net);
drivers/infiniband/core/device.c
1778
put_net(net);
drivers/infiniband/core/device.c
270
static int rdma_dev_change_netns(struct ib_device *device, struct net *cur_net,
drivers/infiniband/core/device.c
271
struct net *net);
drivers/infiniband/core/device.c
320
struct ib_device *ib_device_get_by_index(const struct net *net, u32 index)
drivers/infiniband/core/device.c
327
if (!rdma_dev_access_netns(device, net)) {
drivers/infiniband/core/device.c
517
struct net *net = read_pnet(&coredev->rdma_net);
drivers/infiniband/core/device.c
519
return net ? to_ns_common(net) : NULL;
drivers/infiniband/core/device.c
531
struct ib_device *dev, struct net *net)
drivers/infiniband/core/device.c
556
write_pnet(&coredev->rdma_net, net);
drivers/infiniband/core/device.c
571
struct ib_device *_ib_alloc_device(size_t size, struct net *net)
drivers/infiniband/core/device.c
595
net = ib_devices_shared_netns ? &init_net : net;
drivers/infiniband/core/device.c
596
rdma_init_coredev(&device->coredev, device, net);
drivers/infiniband/core/device.c
944
if (net_eq(read_pnet(&rnet->net),
drivers/infiniband/core/device.c
970
rdma_init_coredev(cdev, device, read_pnet(&rnet->net));
drivers/infiniband/core/netlink.c
262
int rdma_nl_unicast(struct net *net, struct sk_buff *skb, u32 pid)
drivers/infiniband/core/netlink.c
264
struct rdma_dev_net *rnet = rdma_net_to_dev_net(net);
drivers/infiniband/core/netlink.c
272
int rdma_nl_unicast_wait(struct net *net, struct sk_buff *skb, __u32 pid)
drivers/infiniband/core/netlink.c
274
struct rdma_dev_net *rnet = rdma_net_to_dev_net(net);
drivers/infiniband/core/netlink.c
282
int rdma_nl_multicast(struct net *net, struct sk_buff *skb,
drivers/infiniband/core/netlink.c
285
struct rdma_dev_net *rnet = rdma_net_to_dev_net(net);
drivers/infiniband/core/netlink.c
311
struct net *net = read_pnet(&rnet->net);
drivers/infiniband/core/netlink.c
318
nls = netlink_kernel_create(net, NETLINK_RDMA, &cfg);
drivers/infiniband/core/nldev.c
3054
const struct net *net)
drivers/infiniband/core/nldev.c
3059
if (!netdev || !net_eq(dev_net(netdev), net))
drivers/infiniband/core/nldev.c
3073
const struct net *net)
drivers/infiniband/core/nldev.c
3078
if (netdev && !net_eq(dev_net(netdev), net))
drivers/infiniband/core/nldev.c
3157
struct net *net;
drivers/infiniband/core/nldev.c
3160
net = read_pnet(&device->coredev.rdma_net);
drivers/infiniband/core/nldev.c
3161
if (!net)
drivers/infiniband/core/nldev.c
3183
ret = fill_mon_netdev_association(skb, device, port_num, net);
drivers/infiniband/core/nldev.c
3188
ret = fill_mon_netdev_rename(skb, device, port_num, net);
drivers/infiniband/core/nldev.c
3201
ret = rdma_nl_multicast(net, skb, RDMA_NL_GROUP_NOTIFY, GFP_KERNEL);
drivers/infiniband/core/nldev.c
360
const struct net *net)
drivers/infiniband/core/nldev.c
401
if (netdev && net_eq(dev_net(netdev), net)) {
drivers/infiniband/core/roce_gid_mgmt.c
478
struct net *net;
drivers/infiniband/core/roce_gid_mgmt.c
486
for_each_net(net)
drivers/infiniband/core/roce_gid_mgmt.c
487
for_each_netdev(net, ndev) {
drivers/infiniband/hw/bng_re/bng_dev.c
36
rdev->netdev = aux_dev->net;
drivers/infiniband/hw/bnxt_re/main.c
1440
rdev->netdev = en_dev->net;
drivers/infiniband/hw/ionic/ionic_controlpath.c
510
enum rdma_network_type net;
drivers/infiniband/hw/ionic/ionic_controlpath.c
526
net = rdma_gid_attr_network_type(grh->sgid_attr);
drivers/infiniband/hw/ionic/ionic_controlpath.c
533
net == RDMA_NETWORK_IPV4 ? 4 : 6,
drivers/infiniband/hw/ionic/ionic_controlpath.c
543
if (net == RDMA_NETWORK_IPV4) {
drivers/infiniband/sw/rxe/rxe_net.c
107
struct net *net,
drivers/infiniband/sw/rxe/rxe_net.c
120
rt = ip_route_output_key(net, &fl);
drivers/infiniband/sw/rxe/rxe_net.c
131
struct net *net,
drivers/infiniband/sw/rxe/rxe_net.c
144
ndst = ip6_dst_lookup_flow(net, rxe_ns_pernet_sk6(net), &fl6, NULL);
drivers/infiniband/sw/rxe/rxe_net.c
164
struct net *net,
drivers/infiniband/sw/rxe/rxe_net.c
179
struct net *net;
drivers/infiniband/sw/rxe/rxe_net.c
188
net = dev_net(ndev);
drivers/infiniband/sw/rxe/rxe_net.c
196
dst = rxe_find_route4(qp, net, ndev, saddr, daddr);
drivers/infiniband/sw/rxe/rxe_net.c
203
dst = rxe_find_route6(qp, net, ndev, saddr6, daddr6);
drivers/infiniband/sw/rxe/rxe_net.c
259
static struct socket *rxe_setup_udp_tunnel(struct net *net, __be16 port,
drivers/infiniband/sw/rxe/rxe_net.c
277
err = udp_sock_create(net, &udp_cfg, &sock);
drivers/infiniband/sw/rxe/rxe_net.c
286
setup_udp_tunnel_sock(net, sock->sk, &tnl_cfg);
drivers/infiniband/sw/rxe/rxe_net.c
635
void (*set_sk)(struct net *, struct sock *),
drivers/infiniband/sw/rxe/rxe_net.c
636
struct net *net)
drivers/infiniband/sw/rxe/rxe_net.c
643
set_sk(net, sk);
drivers/infiniband/sw/rxe/rxe_net.c
651
struct net *net;
drivers/infiniband/sw/rxe/rxe_net.c
657
net = dev_net(ndev);
drivers/infiniband/sw/rxe/rxe_net.c
659
sk = rxe_ns_pernet_sk4(net);
drivers/infiniband/sw/rxe/rxe_net.c
661
rxe_sock_put(sk, rxe_ns_pernet_set_sk4, net);
drivers/infiniband/sw/rxe/rxe_net.c
663
sk = rxe_ns_pernet_sk6(net);
drivers/infiniband/sw/rxe/rxe_net.c
665
rxe_sock_put(sk, rxe_ns_pernet_set_sk6, net);
drivers/infiniband/sw/rxe/rxe_net.c
756
static int rxe_net_ipv4_init(struct net *net)
drivers/infiniband/sw/rxe/rxe_net.c
761
sk = rxe_ns_pernet_sk4(net);
drivers/infiniband/sw/rxe/rxe_net.c
767
sock = rxe_setup_udp_tunnel(net, htons(ROCE_V2_UDP_DPORT), false);
drivers/infiniband/sw/rxe/rxe_net.c
772
rxe_ns_pernet_set_sk4(net, sock->sk);
drivers/infiniband/sw/rxe/rxe_net.c
777
static int rxe_net_ipv6_init(struct net *net)
drivers/infiniband/sw/rxe/rxe_net.c
783
sk = rxe_ns_pernet_sk6(net);
drivers/infiniband/sw/rxe/rxe_net.c
789
sock = rxe_setup_udp_tunnel(net, htons(ROCE_V2_UDP_DPORT), true);
drivers/infiniband/sw/rxe/rxe_net.c
800
rxe_ns_pernet_set_sk6(net, sock->sk);
drivers/infiniband/sw/rxe/rxe_net.c
826
struct net *net;
drivers/infiniband/sw/rxe/rxe_net.c
830
net = dev_net(ndev);
drivers/infiniband/sw/rxe/rxe_net.c
832
err = rxe_net_ipv4_init(net);
drivers/infiniband/sw/rxe/rxe_net.c
836
err = rxe_net_ipv6_init(net);
drivers/infiniband/sw/rxe/rxe_net.c
844
sk = rxe_ns_pernet_sk4(net);
drivers/infiniband/sw/rxe/rxe_net.c
846
rxe_sock_put(sk, rxe_ns_pernet_set_sk4, net);
drivers/infiniband/sw/rxe/rxe_ns.c
107
void rxe_ns_pernet_set_sk6(struct net *net, struct sock *sk)
drivers/infiniband/sw/rxe/rxe_ns.c
109
struct rxe_ns_sock *ns_sk = net_generic(net, rxe_pernet_id);
drivers/infiniband/sw/rxe/rxe_ns.c
29
static int rxe_ns_init(struct net *net)
drivers/infiniband/sw/rxe/rxe_ns.c
38
static void rxe_ns_exit(struct net *net)
drivers/infiniband/sw/rxe/rxe_ns.c
42
struct rxe_ns_sock *ns_sk = net_generic(net, rxe_pernet_id);
drivers/infiniband/sw/rxe/rxe_ns.c
74
struct sock *rxe_ns_pernet_sk4(struct net *net)
drivers/infiniband/sw/rxe/rxe_ns.c
76
struct rxe_ns_sock *ns_sk = net_generic(net, rxe_pernet_id);
drivers/infiniband/sw/rxe/rxe_ns.c
86
void rxe_ns_pernet_set_sk4(struct net *net, struct sock *sk)
drivers/infiniband/sw/rxe/rxe_ns.c
88
struct rxe_ns_sock *ns_sk = net_generic(net, rxe_pernet_id);
drivers/infiniband/sw/rxe/rxe_ns.c
95
struct sock *rxe_ns_pernet_sk6(struct net *net)
drivers/infiniband/sw/rxe/rxe_ns.c
97
struct rxe_ns_sock *ns_sk = net_generic(net, rxe_pernet_id);
drivers/infiniband/sw/rxe/rxe_ns.h
10
void rxe_ns_pernet_set_sk6(struct net *net, struct sock *sk);
drivers/infiniband/sw/rxe/rxe_ns.h
11
struct sock *rxe_ns_pernet_sk6(struct net *net);
drivers/infiniband/sw/rxe/rxe_ns.h
13
static inline struct sock *rxe_ns_pernet_sk6(struct net *net)
drivers/infiniband/sw/rxe/rxe_ns.h
18
static inline void rxe_ns_pernet_set_sk6(struct net *net, struct sock *sk)
drivers/infiniband/sw/rxe/rxe_ns.h
6
struct sock *rxe_ns_pernet_sk4(struct net *net);
drivers/infiniband/sw/rxe/rxe_ns.h
7
void rxe_ns_pernet_set_sk4(struct net *net, struct sock *sk);
drivers/infiniband/ulp/ipoib/ipoib_main.c
323
struct net *net = dev_net(dev);
drivers/infiniband/ulp/ipoib/ipoib_main.c
335
ret_addr = inet_confirm_addr(net, in_dev, 0,
drivers/infiniband/ulp/ipoib/ipoib_main.c
345
ipv6_chk_addr(net, &addr_in6->sin6_addr, dev, 1))
drivers/infiniband/ulp/ipoib/ipoib_netlink.c
104
struct net *link_net = rtnl_newlink_link_net(params);
drivers/infiniband/ulp/srp/ib_srp.c
1052
kobj_ns_drop(KOBJ_NS_TYPE_NET, to_ns_common(target->net));
drivers/infiniband/ulp/srp/ib_srp.c
3311
static int srp_parse_in(struct net *net, struct sockaddr_storage *sa,
drivers/infiniband/ulp/srp/ib_srp.c
3327
ret = inet_pton_with_scope(net, AF_INET, addr, port_str, sa);
drivers/infiniband/ulp/srp/ib_srp.c
3332
ret = inet_pton_with_scope(net, AF_INET6, addr + 1,
drivers/infiniband/ulp/srp/ib_srp.c
3341
static int srp_parse_options(struct net *net, const char *buf,
drivers/infiniband/ulp/srp/ib_srp.c
337
new_cm_id = rdma_create_id(target->net, srp_rdma_cm_handler, ch,
drivers/infiniband/ulp/srp/ib_srp.c
3448
ret = srp_parse_in(net, &target->rdma_cm.src.ss, p,
drivers/infiniband/ulp/srp/ib_srp.c
3465
ret = srp_parse_in(net, &target->rdma_cm.dst.ss, p,
drivers/infiniband/ulp/srp/ib_srp.c
3735
target->net = to_net_ns(kobj_ns_grab_current(KOBJ_NS_TYPE_NET));
drivers/infiniband/ulp/srp/ib_srp.c
3757
ret = srp_parse_options(target->net, buf, target);
drivers/infiniband/ulp/srp/ib_srp.c
3927
kobj_ns_drop(KOBJ_NS_TYPE_NET, to_ns_common(target->net));
drivers/infiniband/ulp/srp/ib_srp.h
207
struct net *net;
drivers/media/common/videobuf2/videobuf2-dvb.c
166
result = dvb_net_init(adapter, &dvb->net, &dvb->demux.dmx);
drivers/media/common/videobuf2/videobuf2-dvb.c
324
if (fe->dvb.net.dvbdev) {
drivers/media/common/videobuf2/videobuf2-dvb.c
325
dvb_net_release(&fe->dvb.net);
drivers/media/dvb-core/dvb_net.c
1223
struct net_device *dev = priv->net;
drivers/media/dvb-core/dvb_net.c
1264
struct net_device *dev = priv->net;
drivers/media/dvb-core/dvb_net.c
1349
struct net_device *net;
drivers/media/dvb-core/dvb_net.c
1359
net = alloc_netdev(sizeof(struct dvb_net_priv), "dvb",
drivers/media/dvb-core/dvb_net.c
1361
if (!net)
drivers/media/dvb-core/dvb_net.c
1365
snprintf(net->name, IFNAMSIZ, "dvb%d%u%d",
drivers/media/dvb-core/dvb_net.c
1369
snprintf(net->name, IFNAMSIZ, "dvb%d_%d",
drivers/media/dvb-core/dvb_net.c
1372
net->addr_len = 6;
drivers/media/dvb-core/dvb_net.c
1373
eth_hw_addr_set(net, dvbnet->dvbdev->adapter->proposed_mac);
drivers/media/dvb-core/dvb_net.c
1375
dvbnet->device[if_num] = net;
drivers/media/dvb-core/dvb_net.c
1377
priv = netdev_priv(net);
drivers/media/dvb-core/dvb_net.c
1378
priv->net = net;
drivers/media/dvb-core/dvb_net.c
1391
net->base_addr = pid;
drivers/media/dvb-core/dvb_net.c
1393
if ((result = register_netdev(net)) < 0) {
drivers/media/dvb-core/dvb_net.c
1395
free_netdev(net);
drivers/media/dvb-core/dvb_net.c
1398
pr_info("created network interface %s\n", net->name);
drivers/media/dvb-core/dvb_net.c
1405
struct net_device *net = dvbnet->device[num];
drivers/media/dvb-core/dvb_net.c
1410
priv = netdev_priv(net);
drivers/media/dvb-core/dvb_net.c
1414
dvb_net_stop(net);
drivers/media/dvb-core/dvb_net.c
1417
pr_info("removed network interface %s\n", net->name);
drivers/media/dvb-core/dvb_net.c
1418
unregister_netdev(net);
drivers/media/dvb-core/dvb_net.c
1421
free_netdev(net);
drivers/media/dvb-core/dvb_net.c
88
struct net_device *net;
drivers/media/pci/saa7164/saa7164-dvb.c
451
dvb_net_init(&dvb->adapter, &dvb->net, &dvb->demux.dmx);
drivers/media/pci/saa7164/saa7164-dvb.c
509
dvb_net_release(&dvb->net);
drivers/media/pci/saa7164/saa7164.h
247
struct dvb_net net;
drivers/media/usb/au0828/au0828-dvb.c
494
dvb_net_init(&dvb->adapter, &dvb->net, &dvb->demux.dmx);
drivers/media/usb/au0828/au0828-dvb.c
506
dvb_net_release(&dvb->net);
drivers/media/usb/au0828/au0828-dvb.c
542
dvb_net_release(&dvb->net);
drivers/media/usb/au0828/au0828.h
93
struct dvb_net net;
drivers/media/usb/cx231xx/cx231xx-dvb.c
559
dvb_net_init(&dvb->adapter, &dvb->net, &dvb->demux.dmx);
drivers/media/usb/cx231xx/cx231xx-dvb.c
568
dvb_net_release(&dvb->net);
drivers/media/usb/cx231xx/cx231xx-dvb.c
593
dvb_net_release(&dvb->net);
drivers/media/usb/cx231xx/cx231xx-dvb.c
63
struct dvb_net net;
drivers/media/usb/em28xx/em28xx-dvb.c
1093
dvb_net_init(&dvb->adapter, &dvb->net, &dvb->demux.dmx);
drivers/media/usb/em28xx/em28xx-dvb.c
1106
dvb_net_release(&dvb->net);
drivers/media/usb/em28xx/em28xx-dvb.c
1131
dvb_net_release(&dvb->net);
drivers/media/usb/em28xx/em28xx-dvb.c
93
struct dvb_net net;
drivers/net/amt.c
1025
rt = ip_route_output_key(amt->net, &fl4);
drivers/net/amt.c
1084
rt = ip_route_output_key(amt->net, &fl4);
drivers/net/amt.c
1140
rt = ip_route_output_key(amt->net, &fl4);
drivers/net/amt.c
2613
rt = ip_route_output_ports(amt->net, &fl4, sk,
drivers/net/amt.c
2671
ip_select_ident(amt->net, skb, NULL);
drivers/net/amt.c
2673
err = ip_local_out(amt->net, sk, skb);
drivers/net/amt.c
2986
static struct sock *amt_create_sock(struct net *net, __be16 port)
drivers/net/amt.c
2998
err = udp_sock_create(net, &udp_conf, &sock);
drivers/net/amt.c
3010
sk = amt_create_sock(amt->net, amt->relay_port);
drivers/net/amt.c
3021
setup_udp_tunnel_sock(amt->net, sk, &tunnel_cfg);
drivers/net/amt.c
3218
struct net *link_net = rtnl_newlink_link_net(params);
drivers/net/amt.c
3224
amt->net = link_net;
drivers/net/amt.c
3274
amt->qrv = READ_ONCE(amt->net->ipv4.sysctl_igmp_qrv);
drivers/net/amt.c
568
ihv3->qrv = READ_ONCE(amt->net->ipv4.sysctl_igmp_qrv);
drivers/net/amt.c
634
rt = ip_route_output_ports(amt->net, &fl4, sk,
drivers/net/amt.c
691
ip_select_ident(amt->net, skb, NULL);
drivers/net/amt.c
693
err = ip_local_out(amt->net, sk, skb);
drivers/net/amt.c
723
rt = ip_route_output_ports(amt->net, &fl4, sk,
drivers/net/amt.c
782
ip_select_ident(amt->net, skb, NULL);
drivers/net/amt.c
784
err = ip_local_out(amt->net, sk, skb);
drivers/net/amt.c
842
if (ipv6_dev_get_saddr(amt->net, amt->dev, &ip6h->daddr, 0,
drivers/net/bareudp.c
137
!net_eq(bareudp->net,
drivers/net/bareudp.c
231
static struct sock *bareudp_create_sock(struct net *net, __be16 port)
drivers/net/bareudp.c
246
err = udp_sock_create(net, &udp_conf, &sock);
drivers/net/bareudp.c
260
sk = bareudp_create_sock(bareudp->net, port);
drivers/net/bareudp.c
271
setup_udp_tunnel_sock(bareudp->net, sk, &tunnel_cfg);
drivers/net/bareudp.c
306
bool xnet = !net_eq(bareudp->net, dev_net(bareudp->dev));
drivers/net/bareudp.c
323
sport = udp_flow_src_port(bareudp->net, skb,
drivers/net/bareudp.c
326
rt = udp_tunnel_dst_lookup(skb, dev, bareudp->net, 0, &saddr, &info->key,
drivers/net/bareudp.c
361
!net_eq(bareudp->net, dev_net(bareudp->dev)),
drivers/net/bareudp.c
376
bool xnet = !net_eq(bareudp->net, dev_net(bareudp->dev));
drivers/net/bareudp.c
393
sport = udp_flow_src_port(bareudp->net, skb,
drivers/net/bareudp.c
396
dst = udp_tunnel6_dst_lookup(skb, dev, bareudp->net, sk, 0, &saddr,
drivers/net/bareudp.c
50
struct net *net; /* netns for packet i/o */
drivers/net/bareudp.c
507
sport = udp_flow_src_port(bareudp->net, skb,
drivers/net/bareudp.c
515
rt = udp_tunnel_dst_lookup(skb, dev, bareudp->net, 0, &saddr,
drivers/net/bareudp.c
533
dst = udp_tunnel6_dst_lookup(skb, dev, bareudp->net, sk,
drivers/net/bareudp.c
646
static int bareudp_configure(struct net *net, struct net_device *dev,
drivers/net/bareudp.c
650
struct bareudp_net *bn = net_generic(net, bareudp_net_id);
drivers/net/bareudp.c
654
bareudp->net = net;
drivers/net/bareudp.c
707
struct net *link_net = rtnl_newlink_link_net(params);
drivers/net/bareudp.c
774
static __net_init int bareudp_init_net(struct net *net)
drivers/net/bareudp.c
776
struct bareudp_net *bn = net_generic(net, bareudp_net_id);
drivers/net/bareudp.c
782
static void __net_exit bareudp_exit_rtnl_net(struct net *net,
drivers/net/bareudp.c
785
struct bareudp_net *bn = net_generic(net, bareudp_net_id);
drivers/net/bonding/bond_main.c
4594
struct net *net;
drivers/net/bonding/bond_main.c
4627
net = dev_net(bond_dev);
drivers/net/bonding/bond_main.c
4629
if (!ns_capable(net->user_ns, CAP_NET_ADMIN))
drivers/net/bonding/bond_main.c
4632
slave_dev = __dev_get_by_name(net, ifr->ifr_slave);
drivers/net/bonding/bond_main.c
6526
int bond_create(struct net *net, const char *name)
drivers/net/bonding/bond_main.c
6541
dev_net_set(bond_dev, net);
drivers/net/bonding/bond_main.c
6559
static int __net_init bond_net_init(struct net *net)
drivers/net/bonding/bond_main.c
6561
struct bond_net *bn = net_generic(net, bond_net_id);
drivers/net/bonding/bond_main.c
6563
bn->net = net;
drivers/net/bonding/bond_main.c
6576
static void __net_exit bond_net_pre_exit(struct net *net)
drivers/net/bonding/bond_main.c
6578
struct bond_net *bn = net_generic(net, bond_net_id);
drivers/net/bonding/bond_main.c
6583
static void __net_exit bond_net_exit_rtnl(struct net *net,
drivers/net/bonding/bond_main.c
6586
struct bond_net *bn = net_generic(net, bond_net_id);
drivers/net/bonding/bond_main.c
6601
struct net *net;
drivers/net/bonding/bond_main.c
6603
list_for_each_entry(net, net_list, exit_list) {
drivers/net/bonding/bond_main.c
6604
bn = net_generic(net, bond_net_id);
drivers/net/bonding/bond_procfs.c
325
bn->proc_dir = proc_mkdir(KBUILD_MODNAME, bn->net->proc_net);
drivers/net/bonding/bond_procfs.c
337
remove_proc_entry(KBUILD_MODNAME, bn->net->proc_net);
drivers/net/bonding/bond_sysfs.c
827
to_ns_common(bn->net));
drivers/net/bonding/bond_sysfs.c
840
if (netdev_name_in_use(bn->net,
drivers/net/bonding/bond_sysfs.c
854
netdev_class_remove_file_ns(&bn->class_attr_bonding_masters, to_ns_common(bn->net));
drivers/net/bonding/bond_sysfs.c
96
rv = bond_create(bn->net, ifname);
drivers/net/can/m_can/m_can.c
1097
struct net_device *dev = cdev->net;
drivers/net/can/m_can/m_can.c
1120
netdev_completed_queue(cdev->net, transmitted, transmitted_frame_len);
drivers/net/can/m_can/m_can.c
1124
netif_wake_queue(cdev->net);
drivers/net/can/m_can/m_can.c
1137
netif_stop_queue(cdev->net);
drivers/net/can/m_can/m_can.c
1139
netdev_err_once(cdev->net, "hard_xmit called while TX FIFO full\n");
drivers/net/can/m_can/m_can.c
1210
if (!cdev->net->irq)
drivers/net/can/m_can/m_can.c
1238
struct net_device *dev = cdev->net;
drivers/net/can/m_can/m_can.c
1334
irq_wake_thread(cdev->net->irq, cdev->net);
drivers/net/can/m_can/m_can.c
1643
netdev_queue_set_dql_min_limit(netdev_get_tx_queue(cdev->net, 0),
drivers/net/can/m_can/m_can.c
1723
netdev_err(cdev->net, "failed to revert the NON-ISO bit in CCCR\n");
drivers/net/can/m_can/m_can.c
1736
struct net_device *dev = cdev->net;
drivers/net/can/m_can/m_can.c
1742
netdev_err(cdev->net, "Unsupported version number: %2d",
drivers/net/can/m_can/m_can.c
1801
netdev_err(cdev->net, "Unsupported version number: %2d",
drivers/net/can/m_can/m_can.c
1869
struct net_device *dev = cdev->net;
drivers/net/can/m_can/m_can.c
2039
m_can_clean(cdev->net);
drivers/net/can/m_can/m_can.c
2283
netdev_err(cdev->net, "Failed to set wakeup enable %pE\n",
drivers/net/can/m_can/m_can.c
2295
netdev_err(cdev->net, "Failed to select pinctrl state %pE\n",
drivers/net/can/m_can/m_can.c
2331
struct net_device *dev = cdev->net;
drivers/net/can/m_can/m_can.c
2350
netdev_err(cdev->net, "Total size of mram config(%u) exceeds mram(%u)\n",
drivers/net/can/m_can/m_can.c
2386
netdev_dbg(cdev->net,
drivers/net/can/m_can/m_can.c
2405
netdev_err(cdev->net, "no clock found\n");
drivers/net/can/m_can/m_can.c
2483
class_dev->net = net_dev;
drivers/net/can/m_can/m_can.c
2502
void m_can_class_free_dev(struct net_device *net)
drivers/net/can/m_can/m_can.c
2504
free_candev(net);
drivers/net/can/m_can/m_can.c
2537
ret = can_rx_offload_add_manual(cdev->net, &cdev->offload,
drivers/net/can/m_can/m_can.c
2543
if (!cdev->net->irq) {
drivers/net/can/m_can/m_can.c
2544
netdev_dbg(cdev->net, "Polling enabled, initialize hrtimer");
drivers/net/can/m_can/m_can.c
2558
netdev_err(cdev->net, "registering %s failed (err=%d)\n",
drivers/net/can/m_can/m_can.c
2559
cdev->net->name, ret);
drivers/net/can/m_can/m_can.c
2563
of_can_transceiver(cdev->net);
drivers/net/can/m_can/m_can.c
2565
netdev_info(cdev->net, "device registered (irq=%d, version=%d)\n",
drivers/net/can/m_can/m_can.c
2566
cdev->net->irq, cdev->version);
drivers/net/can/m_can/m_can.c
2591
unregister_candev(cdev->net);
drivers/net/can/m_can/m_can.c
2600
struct net_device *ndev = cdev->net;
drivers/net/can/m_can/m_can.c
2635
struct net_device *ndev = cdev->net;
drivers/net/can/m_can/m_can.c
390
netdev_err(cdev->net,
drivers/net/can/m_can/m_can.c
432
netdev_err(cdev->net, "failed to enable configuration mode\n");
drivers/net/can/m_can/m_can.c
446
netdev_err(cdev->net, "failed to disable configuration registers\n");
drivers/net/can/m_can/m_can.c
463
if (!cdev->net->irq)
drivers/net/can/m_can/m_can.c
472
if (!cdev->net->irq) {
drivers/net/can/m_can/m_can.c
473
netdev_dbg(cdev->net, "Start hrtimer\n");
drivers/net/can/m_can/m_can.c
488
if (!cdev->net->irq) {
drivers/net/can/m_can/m_can.c
489
netdev_dbg(cdev->net, "Stop hrtimer\n");
drivers/net/can/m_can/m_can.c
508
static void m_can_clean(struct net_device *net)
drivers/net/can/m_can/m_can.c
510
struct m_can_classdev *cdev = netdev_priv(net);
drivers/net/can/m_can/m_can.c
518
net->stats.tx_errors++;
drivers/net/can/m_can/m_can.c
524
can_free_echo_skb(cdev->net, i, NULL);
drivers/net/can/m_can/m_can.c
526
netdev_reset_queue(cdev->net);
drivers/net/can/m_can/m_can.c
543
struct net_device_stats *stats = &cdev->net->stats;
drivers/net/can/m_can/m_can.h
138
void m_can_class_free_dev(struct net_device *net);
drivers/net/can/m_can/m_can.h
85
struct net_device *net;
drivers/net/can/m_can/m_can_pci.c
126
mcan_class->net->irq = pci_irq_vector(pci, 0);
drivers/net/can/m_can/m_can_pci.c
152
m_can_class_free_dev(mcan_class->net);
drivers/net/can/m_can/m_can_pci.c
168
m_can_class_free_dev(mcan_class->net);
drivers/net/can/m_can/m_can_platform.c
140
mcan_class->net->irq = irq;
drivers/net/can/m_can/m_can_platform.c
163
m_can_class_free_dev(mcan_class->net);
drivers/net/can/m_can/m_can_platform.c
184
m_can_class_free_dev(mcan_class->net);
drivers/net/can/m_can/tcan4x5x-core.c
461
mcan_class->net->irq = spi->irq;
drivers/net/can/m_can/tcan4x5x-core.c
530
netdev_info(mcan_class->net, "TCAN4X5X successfully initialized.\n");
drivers/net/can/m_can/tcan4x5x-core.c
536
m_can_class_free_dev(mcan_class->net);
drivers/net/can/m_can/tcan4x5x-core.c
548
m_can_class_free_dev(priv->cdev.net);
drivers/net/can/softing/softing.h
40
struct net_device *net[2];
drivers/net/can/softing/softing_fw.c
443
for (j = 0; j < ARRAY_SIZE(card->net); ++j) {
drivers/net/can/softing/softing_fw.c
444
netdev = card->net[j];
drivers/net/can/softing/softing_fw.c
481
&& (softing_error_reporting(card->net[0])
drivers/net/can/softing/softing_fw.c
482
!= softing_error_reporting(card->net[1]))) {
drivers/net/can/softing/softing_fw.c
489
netdev = card->net[0];
drivers/net/can/softing/softing_fw.c
529
netdev = card->net[1];
drivers/net/can/softing/softing_fw.c
629
for (j = 0; j < ARRAY_SIZE(card->net); ++j) {
drivers/net/can/softing/softing_fw.c
632
netdev = card->net[j];
drivers/net/can/softing/softing_fw.c
660
for (j = 0; j < ARRAY_SIZE(card->net); ++j) {
drivers/net/can/softing/softing_fw.c
661
netdev = card->net[j];
drivers/net/can/softing/softing_main.c
118
for (j = 0; j < ARRAY_SIZE(card->net); ++j) {
drivers/net/can/softing/softing_main.c
119
if (card->net[j])
drivers/net/can/softing/softing_main.c
120
netif_stop_queue(card->net[j]);
drivers/net/can/softing/softing_main.c
177
for (j = 0; j < ARRAY_SIZE(card->net); ++j) {
drivers/net/can/softing/softing_main.c
178
netdev = card->net[j];
drivers/net/can/softing/softing_main.c
211
netdev = card->net[0];
drivers/net/can/softing/softing_main.c
213
netdev = card->net[1];
drivers/net/can/softing/softing_main.c
333
for (j = 0; j < ARRAY_SIZE(card->net); ++j) {
drivers/net/can/softing/softing_main.c
336
netdev = card->net[(j + offset + 1) % card->pdat->nbus];
drivers/net/can/softing/softing_main.c
739
for (j = 0; j < ARRAY_SIZE(card->net); ++j) {
drivers/net/can/softing/softing_main.c
740
if (!card->net[j])
drivers/net/can/softing/softing_main.c
742
softing_netdev_cleanup(card->net[j]);
drivers/net/can/softing/softing_main.c
743
card->net[j] = NULL;
drivers/net/can/softing/softing_main.c
765
if (pdat->nbus > ARRAY_SIZE(card->net)) {
drivers/net/can/softing/softing_main.c
811
for (j = 0; j < ARRAY_SIZE(card->net); ++j) {
drivers/net/can/softing/softing_main.c
812
card->net[j] = netdev =
drivers/net/can/softing/softing_main.c
820
priv = netdev_priv(card->net[j]);
drivers/net/can/softing/softing_main.c
825
card->net[j] = NULL;
drivers/net/can/softing/softing_main.c
835
for (j = 0; j < ARRAY_SIZE(card->net); ++j) {
drivers/net/can/softing/softing_main.c
836
if (!card->net[j])
drivers/net/can/softing/softing_main.c
838
softing_netdev_cleanup(card->net[j]);
drivers/net/can/spi/hi311x.c
145
struct net_device *net;
drivers/net/can/spi/hi311x.c
174
static void hi3110_clean(struct net_device *net)
drivers/net/can/spi/hi311x.c
176
struct hi3110_priv *priv = netdev_priv(net);
drivers/net/can/spi/hi311x.c
179
net->stats.tx_errors++;
drivers/net/can/spi/hi311x.c
182
can_free_echo_skb(priv->net, 0, NULL);
drivers/net/can/spi/hi311x.c
320
skb = alloc_can_skb(priv->net, &frame);
drivers/net/can/spi/hi311x.c
322
priv->net->stats.rx_dropped++;
drivers/net/can/spi/hi311x.c
352
priv->net->stats.rx_bytes += frame->len;
drivers/net/can/spi/hi311x.c
354
priv->net->stats.rx_packets++;
drivers/net/can/spi/hi311x.c
365
struct net_device *net)
drivers/net/can/spi/hi311x.c
367
struct hi3110_priv *priv = netdev_priv(net);
drivers/net/can/spi/hi311x.c
375
if (can_dev_dropped_skb(net, skb))
drivers/net/can/spi/hi311x.c
378
netif_stop_queue(net);
drivers/net/can/spi/hi311x.c
385
static int hi3110_do_set_mode(struct net_device *net, enum can_mode mode)
drivers/net/can/spi/hi311x.c
387
struct hi3110_priv *priv = netdev_priv(net);
drivers/net/can/spi/hi311x.c
391
hi3110_clean(net);
drivers/net/can/spi/hi311x.c
406
static int hi3110_get_berr_counter(const struct net_device *net,
drivers/net/can/spi/hi311x.c
409
struct hi3110_priv *priv = netdev_priv(net);
drivers/net/can/spi/hi311x.c
450
static int hi3110_do_set_bittiming(struct net_device *net)
drivers/net/can/spi/hi311x.c
452
struct hi3110_priv *priv = netdev_priv(net);
drivers/net/can/spi/hi311x.c
475
static int hi3110_setup(struct net_device *net)
drivers/net/can/spi/hi311x.c
477
hi3110_do_set_bittiming(net);
drivers/net/can/spi/hi311x.c
538
static int hi3110_stop(struct net_device *net)
drivers/net/can/spi/hi311x.c
540
struct hi3110_priv *priv = netdev_priv(net);
drivers/net/can/spi/hi311x.c
543
close_candev(net);
drivers/net/can/spi/hi311x.c
555
hi3110_clean(net);
drivers/net/can/spi/hi311x.c
573
struct net_device *net = priv->net;
drivers/net/can/spi/hi311x.c
579
hi3110_clean(net);
drivers/net/can/spi/hi311x.c
584
can_put_echo_skb(priv->tx_skb, net, 0, 0);
drivers/net/can/spi/hi311x.c
596
struct net_device *net = priv->net;
drivers/net/can/spi/hi311x.c
601
hi3110_setup(net);
drivers/net/can/spi/hi311x.c
605
netif_device_attach(net);
drivers/net/can/spi/hi311x.c
606
hi3110_clean(net);
drivers/net/can/spi/hi311x.c
608
netif_wake_queue(net);
drivers/net/can/spi/hi311x.c
619
hi3110_setup(net);
drivers/net/can/spi/hi311x.c
620
hi3110_clean(net);
drivers/net/can/spi/hi311x.c
622
netif_wake_queue(net);
drivers/net/can/spi/hi311x.c
631
struct net_device *net = priv->net;
drivers/net/can/spi/hi311x.c
662
skb = alloc_can_err_skb(net, &cf);
drivers/net/can/spi/hi311x.c
668
can_change_state(net, cf, tx_state, rx_state);
drivers/net/can/spi/hi311x.c
673
can_bus_off(net);
drivers/net/can/spi/hi311x.c
695
skb = alloc_can_err_skb(net, &cf);
drivers/net/can/spi/hi311x.c
701
priv->net->stats.tx_errors++;
drivers/net/can/spi/hi311x.c
705
priv->net->stats.rx_errors++;
drivers/net/can/spi/hi311x.c
709
priv->net->stats.rx_errors++;
drivers/net/can/spi/hi311x.c
713
priv->net->stats.rx_errors++;
drivers/net/can/spi/hi311x.c
717
priv->net->stats.tx_errors++;
drivers/net/can/spi/hi311x.c
722
netdev_dbg(priv->net, "Bus Error\n");
drivers/net/can/spi/hi311x.c
732
net->stats.tx_packets++;
drivers/net/can/spi/hi311x.c
733
net->stats.tx_bytes += can_get_echo_skb(net, 0, NULL);
drivers/net/can/spi/hi311x.c
735
netif_wake_queue(net);
drivers/net/can/spi/hi311x.c
745
static int hi3110_open(struct net_device *net)
drivers/net/can/spi/hi311x.c
747
struct hi3110_priv *priv = netdev_priv(net);
drivers/net/can/spi/hi311x.c
752
ret = open_candev(net);
drivers/net/can/spi/hi311x.c
776
ret = hi3110_setup(net);
drivers/net/can/spi/hi311x.c
784
netif_wake_queue(net);
drivers/net/can/spi/hi311x.c
795
close_candev(net);
drivers/net/can/spi/hi311x.c
831
struct net_device *net;
drivers/net/can/spi/hi311x.c
854
net = alloc_candev(sizeof(struct hi3110_priv), HI3110_TX_ECHO_SKB_MAX);
drivers/net/can/spi/hi311x.c
855
if (!net)
drivers/net/can/spi/hi311x.c
862
net->netdev_ops = &hi3110_netdev_ops;
drivers/net/can/spi/hi311x.c
863
net->ethtool_ops = &hi3110_ethtool_ops;
drivers/net/can/spi/hi311x.c
864
net->flags |= IFF_ECHO;
drivers/net/can/spi/hi311x.c
866
priv = netdev_priv(net);
drivers/net/can/spi/hi311x.c
877
priv->net = net;
drivers/net/can/spi/hi311x.c
927
SET_NETDEV_DEV(net, &spi->dev);
drivers/net/can/spi/hi311x.c
936
ret = register_candev(net);
drivers/net/can/spi/hi311x.c
940
netdev_info(net, "%x successfully initialized.\n", priv->model);
drivers/net/can/spi/hi311x.c
953
free_candev(net);
drivers/net/can/spi/hi311x.c
961
struct net_device *net = priv->net;
drivers/net/can/spi/hi311x.c
963
unregister_candev(net);
drivers/net/can/spi/hi311x.c
972
free_candev(net);
drivers/net/can/spi/hi311x.c
979
struct net_device *net = priv->net;
drivers/net/can/spi/hi311x.c
987
if (netif_running(net)) {
drivers/net/can/spi/hi311x.c
988
netif_device_detach(net);
drivers/net/can/spi/mcp251x.c
1000
netdev_err(net, "cannot allocate error skb\n");
drivers/net/can/spi/mcp251x.c
1009
struct net_device *net = priv->net;
drivers/net/can/spi/mcp251x.c
1015
mcp251x_clean(net);
drivers/net/can/spi/mcp251x.c
1023
can_put_echo_skb(priv->tx_skb, net, 0, 0);
drivers/net/can/spi/mcp251x.c
1035
struct net_device *net = priv->net;
drivers/net/can/spi/mcp251x.c
1041
mcp251x_setup(net, spi);
drivers/net/can/spi/mcp251x.c
1050
netif_device_attach(net);
drivers/net/can/spi/mcp251x.c
1051
mcp251x_clean(net);
drivers/net/can/spi/mcp251x.c
1053
netif_wake_queue(net);
drivers/net/can/spi/mcp251x.c
1063
mcp251x_clean(net);
drivers/net/can/spi/mcp251x.c
1064
netif_wake_queue(net);
drivers/net/can/spi/mcp251x.c
1065
mcp251x_error_skb(net, CAN_ERR_RESTARTED, 0);
drivers/net/can/spi/mcp251x.c
1074
struct net_device *net = priv->net;
drivers/net/can/spi/mcp251x.c
1173
net->stats.rx_over_errors++;
drivers/net/can/spi/mcp251x.c
1174
net->stats.rx_errors++;
drivers/net/can/spi/mcp251x.c
1177
net->stats.rx_over_errors++;
drivers/net/can/spi/mcp251x.c
1178
net->stats.rx_errors++;
drivers/net/can/spi/mcp251x.c
1183
mcp251x_error_skb(net, can_id, data1);
drivers/net/can/spi/mcp251x.c
1190
can_bus_off(net);
drivers/net/can/spi/mcp251x.c
1201
net->stats.tx_packets++;
drivers/net/can/spi/mcp251x.c
1202
net->stats.tx_bytes += can_get_echo_skb(net, 0,
drivers/net/can/spi/mcp251x.c
1206
netif_wake_queue(net);
drivers/net/can/spi/mcp251x.c
1213
static int mcp251x_open(struct net_device *net)
drivers/net/can/spi/mcp251x.c
1215
struct mcp251x_priv *priv = netdev_priv(net);
drivers/net/can/spi/mcp251x.c
1221
ret = open_candev(net);
drivers/net/can/spi/mcp251x.c
1252
ret = mcp251x_setup(net, spi);
drivers/net/can/spi/mcp251x.c
1259
netif_wake_queue(net);
drivers/net/can/spi/mcp251x.c
1280
close_candev(net);
drivers/net/can/spi/mcp251x.c
1333
struct net_device *net;
drivers/net/can/spi/mcp251x.c
1352
net = alloc_candev(sizeof(struct mcp251x_priv), TX_ECHO_SKB_MAX);
drivers/net/can/spi/mcp251x.c
1353
if (!net)
drivers/net/can/spi/mcp251x.c
1362
net->netdev_ops = &mcp251x_netdev_ops;
drivers/net/can/spi/mcp251x.c
1363
net->ethtool_ops = &mcp251x_ethtool_ops;
drivers/net/can/spi/mcp251x.c
1364
net->flags |= IFF_ECHO;
drivers/net/can/spi/mcp251x.c
1366
priv = netdev_priv(net);
drivers/net/can/spi/mcp251x.c
1373
priv->net = net;
drivers/net/can/spi/mcp251x.c
1432
SET_NETDEV_DEV(net, &spi->dev);
drivers/net/can/spi/mcp251x.c
1444
ret = register_candev(net);
drivers/net/can/spi/mcp251x.c
1456
netdev_info(net, "MCP%x successfully initialized.\n", priv->model);
drivers/net/can/spi/mcp251x.c
1460
unregister_candev(net);
drivers/net/can/spi/mcp251x.c
1471
free_candev(net);
drivers/net/can/spi/mcp251x.c
1479
struct net_device *net = priv->net;
drivers/net/can/spi/mcp251x.c
1481
unregister_candev(net);
drivers/net/can/spi/mcp251x.c
1490
free_candev(net);
drivers/net/can/spi/mcp251x.c
1497
struct net_device *net = priv->net;
drivers/net/can/spi/mcp251x.c
1504
if (netif_running(net)) {
drivers/net/can/spi/mcp251x.c
1505
netif_device_detach(net);
drivers/net/can/spi/mcp251x.c
229
struct net_device *net;
drivers/net/can/spi/mcp251x.c
271
static void mcp251x_clean(struct net_device *net)
drivers/net/can/spi/mcp251x.c
273
struct mcp251x_priv *priv = netdev_priv(net);
drivers/net/can/spi/mcp251x.c
276
net->stats.tx_errors++;
drivers/net/can/spi/mcp251x.c
279
can_free_echo_skb(priv->net, 0, NULL);
drivers/net/can/spi/mcp251x.c
714
skb = alloc_can_skb(priv->net, &frame);
drivers/net/can/spi/mcp251x.c
717
priv->net->stats.rx_dropped++;
drivers/net/can/spi/mcp251x.c
749
priv->net->stats.rx_bytes += frame->len;
drivers/net/can/spi/mcp251x.c
751
priv->net->stats.rx_packets++;
drivers/net/can/spi/mcp251x.c
794
struct net_device *net)
drivers/net/can/spi/mcp251x.c
796
struct mcp251x_priv *priv = netdev_priv(net);
drivers/net/can/spi/mcp251x.c
804
if (can_dev_dropped_skb(net, skb))
drivers/net/can/spi/mcp251x.c
807
netif_stop_queue(net);
drivers/net/can/spi/mcp251x.c
814
static int mcp251x_do_set_mode(struct net_device *net, enum can_mode mode)
drivers/net/can/spi/mcp251x.c
816
struct mcp251x_priv *priv = netdev_priv(net);
drivers/net/can/spi/mcp251x.c
820
mcp251x_clean(net);
drivers/net/can/spi/mcp251x.c
869
static int mcp251x_do_set_bittiming(struct net_device *net)
drivers/net/can/spi/mcp251x.c
871
struct mcp251x_priv *priv = netdev_priv(net);
drivers/net/can/spi/mcp251x.c
892
static int mcp251x_setup(struct net_device *net, struct spi_device *spi)
drivers/net/can/spi/mcp251x.c
894
mcp251x_do_set_bittiming(net);
drivers/net/can/spi/mcp251x.c
960
static int mcp251x_stop(struct net_device *net)
drivers/net/can/spi/mcp251x.c
962
struct mcp251x_priv *priv = netdev_priv(net);
drivers/net/can/spi/mcp251x.c
965
close_candev(net);
drivers/net/can/spi/mcp251x.c
976
mcp251x_clean(net);
drivers/net/can/spi/mcp251x.c
989
static void mcp251x_error_skb(struct net_device *net, int can_id, int data1)
drivers/net/can/spi/mcp251x.c
994
skb = alloc_can_err_skb(net, &frame);
drivers/net/can/usb/esd_usb.c
1073
msg->setbaud.net = priv->index;
drivers/net/can/usb/esd_usb.c
1163
baud_x->net = priv->index;
drivers/net/can/usb/esd_usb.c
143
u8 net;
drivers/net/can/usb/esd_usb.c
162
u8 net;
drivers/net/can/usb/esd_usb.c
175
u8 net;
drivers/net/can/usb/esd_usb.c
184
u8 net;
drivers/net/can/usb/esd_usb.c
192
u8 net;
drivers/net/can/usb/esd_usb.c
231
u8 net;
drivers/net/can/usb/esd_usb.c
515
if (msg->rx.net >= dev->net_count) {
drivers/net/can/usb/esd_usb.c
520
esd_usb_rx_can_msg(dev->nets[msg->rx.net], msg);
drivers/net/can/usb/esd_usb.c
524
if (msg->txdone.net >= dev->net_count) {
drivers/net/can/usb/esd_usb.c
529
esd_usb_tx_done_msg(dev->nets[msg->txdone.net],
drivers/net/can/usb/esd_usb.c
745
msg->filter.net = priv->index;
drivers/net/can/usb/esd_usb.c
857
msg->tx.net = priv->index;
drivers/net/can/usb/esd_usb.c
968
msg->filter.net = priv->index;
drivers/net/can/usb/esd_usb.c
981
msg->setbaud.net = priv->index;
drivers/net/can/usb/kvaser_usb/kvaser_usb_leaf.c
1102
struct kvaser_usb_net_priv *priv = leaf->net;
drivers/net/can/usb/kvaser_usb/kvaser_usb_leaf.c
1859
leaf->net = priv;
drivers/net/can/usb/kvaser_usb/kvaser_usb_leaf.c
475
struct kvaser_usb_net_priv *net;
drivers/net/can/vxcan.c
207
struct net *peer_net = rtnl_newlink_peer_net(params);
drivers/net/can/vxcan.c
308
static struct net *vxcan_get_link_net(const struct net_device *dev)
drivers/net/ethernet/broadcom/bnge/bnge_auxr.c
200
bd->auxr_dev->net = bd->netdev;
drivers/net/ethernet/broadcom/bnge/bnge_auxr.h
46
struct net_device *net;
drivers/net/ethernet/broadcom/bnxt/bnxt_ulp.c
155
struct net_device *dev = edev->net;
drivers/net/ethernet/broadcom/bnxt/bnxt_ulp.c
199
struct net_device *dev = edev->net;
drivers/net/ethernet/broadcom/bnxt/bnxt_ulp.c
239
struct net_device *dev = edev->net;
drivers/net/ethernet/broadcom/bnxt/bnxt_ulp.c
441
struct net_device *dev = edev->net;
drivers/net/ethernet/broadcom/bnxt/bnxt_ulp.c
475
struct bnxt *bp = netdev_priv(aux_priv->edev->net);
drivers/net/ethernet/broadcom/bnxt/bnxt_ulp.c
500
edev->net = bp->dev;
drivers/net/ethernet/intel/ice/ice_trace.h
363
#define TRACE_INCLUDE_FILE ../../drivers/net/ethernet/intel/ice/ice_trace
drivers/net/ethernet/marvell/prestera/prestera_flow.c
184
block = prestera_flow_block_create(sw, f->net, ingress);
drivers/net/ethernet/marvell/prestera/prestera_flow.c
80
struct net *net,
drivers/net/ethernet/marvell/prestera/prestera_flow.c
91
block->net = net;
drivers/net/ethernet/marvell/prestera/prestera_flow.h
21
struct net *net;
drivers/net/ethernet/marvell/prestera/prestera_flower.c
163
ingress_dev = __dev_get_by_index(block->net,
drivers/net/ethernet/mellanox/mlx5/core/en/tc/sample.c
335
psample_group.net = &init_net;
drivers/net/ethernet/mellanox/mlx5/core/en_accel/ipsec.c
1080
struct net *net = dev_net(x->xso.dev);
drivers/net/ethernet/mellanox/mlx5/core/en_accel/ipsec.c
1089
lockdep_is_held(&net->xfrm.xfrm_cfg_mutex) ||
drivers/net/ethernet/mellanox/mlx5/core/en_accel/ipsec.c
1090
lockdep_is_held(&net->xfrm.xfrm_state_lock));
drivers/net/ethernet/mellanox/mlx5/core/en_accel/ipsec.c
1099
XFRM_ADD_STATS(net, LINUX_MIB_XFRMINSTATEPROTOERROR, auth_packets);
drivers/net/ethernet/mellanox/mlx5/core/en_accel/ipsec.c
1103
XFRM_ADD_STATS(net, LINUX_MIB_XFRMINHDRERROR, trailer_packets);
drivers/net/ethernet/mellanox/mlx5/core/en_accel/ipsec.c
1113
XFRM_ADD_STATS(net, LINUX_MIB_XFRMINSTATESEQERROR, replay_packets);
drivers/net/ethernet/mellanox/mlx5/core/en_accel/ktls_rx.c
502
struct net *net = dev_net(netdev);
drivers/net/ethernet/mellanox/mlx5/core/en_accel/ktls_rx.c
517
sk = inet_lookup_established(net, iph->saddr, th->source,
drivers/net/ethernet/mellanox/mlx5/core/en_accel/ktls_rx.c
527
sk = __inet6_lookup_established(net, &ipv6h->saddr, th->source,
drivers/net/ethernet/mellanox/mlx5/core/en_accel/psp_rxtx.c
179
struct net *net = sock_net(skb->sk);
drivers/net/ethernet/mellanox/mlx5/core/en_accel/psp_rxtx.c
185
if (!psp_dev_encapsulate(net, skb, psp_st->spi, psp_st->ver, 0)) {
drivers/net/ethernet/mellanox/mlx5/core/en_tc.c
693
struct mlx5_core_dev *mlx5e_hairpin_get_mdev(struct net *net, int ifindex)
drivers/net/ethernet/mellanox/mlx5/core/en_tc.c
699
netdev = dev_get_by_index(net, ifindex);
drivers/net/ethernet/mellanox/mlx5/core/eswitch_offloads.c
4197
attr.net = mlx5_core_net(esw->dev);
drivers/net/ethernet/mellanox/mlx5/core/lag/lag.c
2284
.net = mlx5_core_net(dev),
drivers/net/ethernet/mellanox/mlx5/core/lag/lag.c
284
struct net *net;
drivers/net/ethernet/mellanox/mlx5/core/lag/lag.c
288
net = read_pnet(&ldev->net);
drivers/net/ethernet/mellanox/mlx5/core/lag/lag.c
289
unregister_netdevice_notifier_net(net, &ldev->nb);
drivers/net/ethernet/mellanox/mlx5/core/lag/lag.c
345
write_pnet(&ldev->net, mlx5_core_net(dev));
drivers/net/ethernet/mellanox/mlx5/core/lag/lag.c
346
if (register_netdevice_notifier_net(read_pnet(&ldev->net),
drivers/net/ethernet/mellanox/mlx5/core/lag/lag.h
96
possible_net_t net;
drivers/net/ethernet/mellanox/mlx5/core/lib/devcom.c
132
write_pnet(&comp->key.net, attr->net);
drivers/net/ethernet/mellanox/mlx5/core/lib/devcom.c
207
!net_eq(read_pnet(&devcom->key.net), attr->net))
drivers/net/ethernet/mellanox/mlx5/core/lib/devcom.c
30
possible_net_t net;
drivers/net/ethernet/mellanox/mlx5/core/lib/devcom.h
22
struct net *net;
drivers/net/ethernet/mellanox/mlx5/core/lib/sd.c
532
attr.net = mlx5_core_net(dev);
drivers/net/ethernet/mellanox/mlxsw/core.h
476
static inline struct net *mlxsw_core_net(struct mlxsw_core *mlxsw_core)
drivers/net/ethernet/mellanox/mlxsw/spectrum.h
1430
static inline struct net *mlxsw_sp_net(struct mlxsw_sp *mlxsw_sp)
drivers/net/ethernet/mellanox/mlxsw/spectrum.h
890
struct net *net;
drivers/net/ethernet/mellanox/mlxsw/spectrum.h
950
struct net *net);
drivers/net/ethernet/mellanox/mlxsw/spectrum_flow.c
13
mlxsw_sp_flow_block_create(struct mlxsw_sp *mlxsw_sp, struct net *net)
drivers/net/ethernet/mellanox/mlxsw/spectrum_flow.c
214
flow_block = mlxsw_sp_flow_block_create(mlxsw_sp, f->net);
drivers/net/ethernet/mellanox/mlxsw/spectrum_flow.c
23
block->net = net;
drivers/net/ethernet/mellanox/mlxsw/spectrum_flower.c
321
ingress_dev = __dev_get_by_index(block->net,
drivers/net/ethernet/mellanox/mlxsw/spectrum_ipip.c
628
struct net *net = dev_net(ol_dev);
drivers/net/ethernet/mellanox/mlxsw/spectrum_ipip.c
635
return dev_get_by_index_rcu(net, tun4->parms.link);
drivers/net/ethernet/mellanox/mlxsw/spectrum_ipip.c
638
return dev_get_by_index_rcu(net, tun6->parms.link);
drivers/net/ethernet/mellanox/mlxsw/spectrum_qdisc.c
2098
struct net *net)
drivers/net/ethernet/mellanox/mlxsw/spectrum_qdisc.c
2185
qevent_block = mlxsw_sp_qevent_block_create(mlxsw_sp, f->net);
drivers/net/ethernet/mellanox/mlxsw/spectrum_router.c
11264
struct net *net = mlxsw_sp_net(mlxsw_sp);
drivers/net/ethernet/mellanox/mlxsw/spectrum_router.c
11269
switch (READ_ONCE(net->ipv4.sysctl_fib_multipath_hash_policy)) {
drivers/net/ethernet/mellanox/mlxsw/spectrum_router.c
11287
hash_fields = READ_ONCE(net->ipv4.sysctl_fib_multipath_hash_fields);
drivers/net/ethernet/mellanox/mlxsw/spectrum_router.c
11402
struct net *net = mlxsw_sp_net(mlxsw_sp);
drivers/net/ethernet/mellanox/mlxsw/spectrum_router.c
11408
seed = READ_ONCE(net->ipv4.sysctl_fib_multipath_hash_seed).user_seed;
drivers/net/ethernet/mellanox/mlxsw/spectrum_router.c
11483
struct net *net = mlxsw_sp_net(mlxsw_sp);
drivers/net/ethernet/mellanox/mlxsw/spectrum_router.c
11491
usp = READ_ONCE(net->ipv4.sysctl_ip_fwd_update_priority);
drivers/net/ethernet/mellanox/mlxsw/spectrum_router.c
2848
static int mlxsw_sp_router_schedule_work(struct net *net,
drivers/net/ethernet/mellanox/mlxsw/spectrum_router.c
2855
if (!net_eq(net, mlxsw_sp_net(router->mlxsw_sp)))
drivers/net/ethernet/mellanox/mlxsw/spectrum_router.c
2887
struct net *net;
drivers/net/ethernet/mellanox/mlxsw/spectrum_router.c
2889
net = neigh_parms_net(n->parms);
drivers/net/ethernet/mellanox/mlxsw/spectrum_router.c
2890
return mlxsw_sp_router_schedule_work(net, router, n,
drivers/net/ethernet/mellanox/mlxsw/spectrum_span.c
426
0, 0, tun->net, parms.link, tun->fwmark, 0, 0);
drivers/net/ethernet/mellanox/mlxsw/spectrum_span.c
428
rt = ip_route_output_key(tun->net, &fl4);
drivers/net/ethernet/mellanox/mlxsw/spectrum_span.c
538
dst = ip6_route_output(t->net, NULL, &fl6);
drivers/net/ethernet/microsoft/mana/mana_en.c
2491
struct net_device *net)
drivers/net/ethernet/microsoft/mana/mana_en.c
2538
txq->ndev = net;
drivers/net/ethernet/microsoft/mana/mana_en.c
2539
txq->net_txq = netdev_get_tx_queue(net, i);
drivers/net/ethernet/microsoft/mana/mana_en.c
2609
netif_napi_add_locked(net, &cq->napi, mana_poll);
drivers/net/ethernet/microsoft/mana/mana_en.c
2618
netdev_err(net, "Failed to create %d TX queues, %d\n",
drivers/net/ethernet/microsoft/mana/mana_en.c
3014
struct net_device *net)
drivers/net/ethernet/netronome/nfp/crypto/tls.c
481
struct net *net = dev_net(netdev);
drivers/net/ethernet/netronome/nfp/crypto/tls.c
502
sk = inet_lookup_established(net, iph->saddr, th->source,
drivers/net/ethernet/netronome/nfp/crypto/tls.c
508
sk = __inet6_lookup_established(net, &ipv6h->saddr, th->source,
drivers/net/ethernet/netronome/nfp/flower/action.c
467
struct net *net = dev_net(netdev);
drivers/net/ethernet/netronome/nfp/flower/action.c
473
dst = ip6_dst_lookup_flow(net, NULL, &flow, NULL);
drivers/net/ethernet/netronome/nfp/flower/action.c
478
set_tun->ttl = READ_ONCE(net->ipv6.devconf_all->hop_limit);
drivers/net/ethernet/netronome/nfp/flower/action.c
482
struct net *net = dev_net(netdev);
drivers/net/ethernet/netronome/nfp/flower/action.c
493
rt = ip_route_output_key(net, &flow);
drivers/net/ethernet/netronome/nfp/flower/action.c
499
set_tun->ttl = READ_ONCE(net->ipv4.sysctl_ip_default_ttl);
drivers/net/ethernet/qlogic/netxen/netxen_nic_main.c
2732
struct net_device *net = to_net_dev(dev);
drivers/net/ethernet/qlogic/netxen/netxen_nic_main.c
2733
struct netxen_adapter *adapter = netdev_priv(net);
drivers/net/ethernet/qlogic/netxen/netxen_nic_main.c
2757
struct net_device *net = to_net_dev(dev);
drivers/net/ethernet/qlogic/netxen/netxen_nic_main.c
2761
adapter = netdev_priv(net);
drivers/net/ethernet/qualcomm/rmnet/rmnet_config.c
124
struct net *link_net = rtnl_newlink_link_net(params);
drivers/net/ethernet/sfc/tc_encap_actions.c
126
neigh->net = get_net_track(net, &neigh->ns_tracker, GFP_KERNEL_ACCOUNT);
drivers/net/ethernet/sfc/tc_encap_actions.c
135
put_net_track(neigh->net, &neigh->ns_tracker);
drivers/net/ethernet/sfc/tc_encap_actions.c
152
dst = ip6_dst_lookup_flow(net, NULL, &flow6, NULL);
drivers/net/ethernet/sfc/tc_encap_actions.c
173
rt = ip_route_output_key(net, &flow4);
drivers/net/ethernet/sfc/tc_encap_actions.c
219
put_net_track(net, &neigh->ns_tracker);
drivers/net/ethernet/sfc/tc_encap_actions.c
232
put_net_track(neigh->net, &neigh->ns_tracker);
drivers/net/ethernet/sfc/tc_encap_actions.c
47
put_net_track(neigh->net, &neigh->ns_tracker);
drivers/net/ethernet/sfc/tc_encap_actions.c
544
keys.net = read_pnet(&n->parms->net);
drivers/net/ethernet/sfc/tc_encap_actions.c
87
struct efx_tc_encap_action *encap, struct net *net,
drivers/net/ethernet/sfc/tc_encap_actions.h
48
struct net *net;
drivers/net/fjes/fjes_trace.h
361
#define TRACE_INCLUDE_PATH ../../drivers/net/fjes
drivers/net/geneve.c
1011
static struct geneve_sock *geneve_socket_create(struct net *net,
drivers/net/geneve.c
1014
struct geneve_net *gn = net_generic(net, geneve_net_id);
drivers/net/geneve.c
1024
sk = geneve_create_sock(net, geneve, ipv6);
drivers/net/geneve.c
104
struct net *net; /* netns for packet i/o */
drivers/net/geneve.c
1047
setup_udp_tunnel_sock(net, sk, &tunnel_cfg);
drivers/net/geneve.c
1080
static struct geneve_sock *geneve_find_sock(struct net *net,
drivers/net/geneve.c
1083
struct geneve_net *gn = net_generic(net, geneve_net_id);
drivers/net/geneve.c
1118
struct net *net = geneve->net;
drivers/net/geneve.c
1124
gs = geneve_find_sock(net, geneve, ipv6);
drivers/net/geneve.c
1130
gs = geneve_socket_create(net, geneve, ipv6);
drivers/net/geneve.c
1287
bool xnet = !net_eq(geneve->net, dev_net(geneve->dev));
drivers/net/geneve.c
1364
sport = udp_flow_src_port(geneve->net, skb,
drivers/net/geneve.c
1368
rt = udp_tunnel_dst_lookup(skb, dev, geneve->net, 0, &saddr,
drivers/net/geneve.c
1453
!net_eq(geneve->net, dev_net(geneve->dev)),
drivers/net/geneve.c
1481
sport = udp_flow_src_port(geneve->net, skb,
drivers/net/geneve.c
1485
dst = udp_tunnel6_dst_lookup(skb, dev, geneve->net, gs6->sk, 0,
drivers/net/geneve.c
1628
sport = udp_flow_src_port(geneve->net, skb,
drivers/net/geneve.c
1632
rt = udp_tunnel_dst_lookup(skb, dev, geneve->net, 0, &saddr,
drivers/net/geneve.c
1655
sport = udp_flow_src_port(geneve->net, skb,
drivers/net/geneve.c
1659
dst = udp_tunnel6_dst_lookup(skb, dev, geneve->net, gs6->sk, 0,
drivers/net/geneve.c
1713
struct net *net = dev_net(dev);
drivers/net/geneve.c
1714
struct geneve_net *gn = net_generic(net, geneve_net_id);
drivers/net/geneve.c
1935
static int geneve_configure(struct net *net, struct net_device *dev,
drivers/net/geneve.c
1939
struct geneve_net *gn = net_generic(net, geneve_net_id);
drivers/net/geneve.c
1951
geneve->net = net;
drivers/net/geneve.c
2280
struct rtable *rt = ip_route_output_key(geneve->net, &fl4);
drivers/net/geneve.c
2295
rt = rt6_lookup(geneve->net, &info->key.u.ipv6.dst, NULL, 0,
drivers/net/geneve.c
2316
struct net *link_net = rtnl_newlink_link_net(params);
drivers/net/geneve.c
2397
if (!rtnl_dev_link_net_capable(dev, geneve->net))
drivers/net/geneve.c
2564
struct net_device *geneve_dev_create_fb(struct net *net, const char *name,
drivers/net/geneve.c
2582
dev = rtnl_create_link(net, name, name_assign_type,
drivers/net/geneve.c
2588
err = geneve_configure(net, dev, NULL, &cfg);
drivers/net/geneve.c
2630
static __net_init int geneve_init_net(struct net *net)
drivers/net/geneve.c
2632
struct geneve_net *gn = net_generic(net, geneve_net_id);
drivers/net/geneve.c
2639
static void __net_exit geneve_exit_rtnl_net(struct net *net,
drivers/net/geneve.c
2642
struct geneve_net *gn = net_generic(net, geneve_net_id);
drivers/net/geneve.c
2649
static void __net_exit geneve_exit_net(struct net *net)
drivers/net/geneve.c
2651
const struct geneve_net *gn = net_generic(net, geneve_net_id);
drivers/net/geneve.c
704
!net_eq(geneve->net, dev_net(geneve->dev)))) {
drivers/net/geneve.c
782
static struct sock *geneve_create_sock(struct net *net,
drivers/net/geneve.c
808
err = udp_sock_create(net, &udp_conf, &sock);
drivers/net/gtp.c
1112
static int gtp_build_skb_outer_ip6(struct net *net, struct sk_buff *skb,
drivers/net/gtp.c
1122
rt = ip6_route_output_gtp(net, &fl6, pctx->sk, &pctx->peer.addr6,
drivers/net/gtp.c
1173
struct net *net = gtp->net;
drivers/net/gtp.c
1200
ret = gtp_build_skb_outer_ip6(net, skb, dev, pktinfo, pctx,
drivers/net/gtp.c
1222
struct net *net = gtp->net;
drivers/net/gtp.c
1251
ret = gtp_build_skb_outer_ip6(net, skb, dev, pktinfo, pctx, tos);
drivers/net/gtp.c
1409
struct net *net = gtp->net;
drivers/net/gtp.c
1429
err = udp_sock_create(net, &udp_conf, &sock);
drivers/net/gtp.c
1438
setup_udp_tunnel_sock(net, sock->sk, &tuncfg);
drivers/net/gtp.c
1473
struct net *link_net = rtnl_newlink_link_net(params);
drivers/net/gtp.c
1505
gtp->net = link_net;
drivers/net/gtp.c
1745
static struct gtp_dev *gtp_find_dev(struct net *src_net, struct nlattr *nla[])
drivers/net/gtp.c
1749
struct net *net;
drivers/net/gtp.c
1755
net = get_net_ns_by_fd(nla_get_u32(nla[GTPA_NET_NS_FD]));
drivers/net/gtp.c
1757
net = get_net(src_net);
drivers/net/gtp.c
1759
if (IS_ERR(net))
drivers/net/gtp.c
1763
dev = dev_get_by_index_rcu(net, nla_get_u32(nla[GTPA_LINK]));
drivers/net/gtp.c
1767
put_net(net);
drivers/net/gtp.c
2069
static struct pdp_ctx *gtp_find_pdp_by_link(struct net *net,
drivers/net/gtp.c
2077
gtp = gtp_find_dev(net, nla);
drivers/net/gtp.c
2114
static struct pdp_ctx *gtp_find_pdp(struct net *net, struct nlattr *nla[])
drivers/net/gtp.c
2119
pctx = gtp_find_pdp_by_link(net, nla);
drivers/net/gtp.c
2281
struct net *net = sock_net(skb->sk);
drivers/net/gtp.c
2289
for_each_netdev_rcu(net, dev) {
drivers/net/gtp.c
2476
static int __net_init gtp_net_init(struct net *net)
drivers/net/gtp.c
2478
struct gtp_net *gn = net_generic(net, gtp_net_id);
drivers/net/gtp.c
2484
static void __net_exit gtp_net_exit_rtnl(struct net *net,
drivers/net/gtp.c
2487
struct gtp_net *gn = net_generic(net, gtp_net_id);
drivers/net/gtp.c
363
static struct rt6_info *ip6_route_output_gtp(struct net *net,
drivers/net/gtp.c
377
dst = ip6_dst_lookup_flow(net, sk, fl6, NULL);
drivers/net/gtp.c
82
struct net *net;
drivers/net/hyperv/hyperv_net.h
227
int netvsc_send(struct net_device *net,
drivers/net/hyperv/hyperv_net.h
233
void netvsc_linkstatus_callback(struct net_device *net,
drivers/net/hyperv/hyperv_net.h
236
int netvsc_recv_callback(struct net_device *net,
drivers/net/hyperv/netvsc_drv.c
1080
static int netvsc_set_channels(struct net_device *net,
drivers/net/hyperv/netvsc_drv.c
1083
struct net_device_context *net_device_ctx = netdev_priv(net);
drivers/net/hyperv/netvsc_drv.c
1112
ret = netvsc_detach(net, nvdev);
drivers/net/hyperv/netvsc_drv.c
1116
ret = netvsc_attach(net, device_info);
drivers/net/hyperv/netvsc_drv.c
1119
if (netvsc_attach(net, device_info))
drivers/net/hyperv/netvsc_drv.c
1120
netdev_err(net, "restoring channel setting failed\n");
drivers/net/hyperv/netvsc_drv.c
114
static int netvsc_open(struct net_device *net)
drivers/net/hyperv/netvsc_drv.c
116
struct net_device_context *ndev_ctx = netdev_priv(net);
drivers/net/hyperv/netvsc_drv.c
122
netif_carrier_off(net);
drivers/net/hyperv/netvsc_drv.c
1224
static void netvsc_get_vf_stats(struct net_device *net,
drivers/net/hyperv/netvsc_drv.c
1227
struct net_device_context *ndev_ctx = netdev_priv(net);
drivers/net/hyperv/netvsc_drv.c
1254
static void netvsc_get_pcpu_stats(struct net_device *net,
drivers/net/hyperv/netvsc_drv.c
1257
struct net_device_context *ndev_ctx = netdev_priv(net);
drivers/net/hyperv/netvsc_drv.c
127
netdev_err(net, "unable to open device (ret %d).\n", ret);
drivers/net/hyperv/netvsc_drv.c
1313
static void netvsc_get_stats64(struct net_device *net,
drivers/net/hyperv/netvsc_drv.c
1316
struct net_device_context *ndev_ctx = netdev_priv(net);
drivers/net/hyperv/netvsc_drv.c
1327
netdev_stats_to_stats64(t, &net->stats);
drivers/net/hyperv/netvsc_drv.c
1329
netvsc_get_vf_stats(net, &vf_tot);
drivers/net/hyperv/netvsc_drv.c
133
netif_carrier_on(net);
drivers/net/hyperv/netvsc_drv.c
134
netvsc_tx_enable(nvdev, net);
drivers/net/hyperv/netvsc_drv.c
144
netdev_warn(net,
drivers/net/hyperv/netvsc_drv.c
200
static int netvsc_close(struct net_device *net)
drivers/net/hyperv/netvsc_drv.c
2006
struct net_device *net = hv_get_drvdata(device_obj);
drivers/net/hyperv/netvsc_drv.c
202
struct net_device_context *net_device_ctx = netdev_priv(net);
drivers/net/hyperv/netvsc_drv.c
2057
netif_carrier_on(net);
drivers/net/hyperv/netvsc_drv.c
2058
netvsc_tx_enable(net_device, net);
drivers/net/hyperv/netvsc_drv.c
2060
__netdev_notify_peers(net);
drivers/net/hyperv/netvsc_drv.c
2067
netif_carrier_off(net);
drivers/net/hyperv/netvsc_drv.c
2068
netvsc_tx_disable(net_device, net);
drivers/net/hyperv/netvsc_drv.c
2076
netif_carrier_off(net);
drivers/net/hyperv/netvsc_drv.c
2077
netvsc_tx_disable(net_device, net);
drivers/net/hyperv/netvsc_drv.c
208
netvsc_tx_disable(nvdev, net);
drivers/net/hyperv/netvsc_drv.c
216
netdev_err(net, "unable to close device (ret %d).\n", ret);
drivers/net/hyperv/netvsc_drv.c
222
netdev_err(net, "Ring buffer not empty after closing rndis\n");
drivers/net/hyperv/netvsc_drv.c
2489
struct net_device *net = NULL, *vf_netdev;
drivers/net/hyperv/netvsc_drv.c
2495
net = alloc_etherdev_mq(sizeof(struct net_device_context),
drivers/net/hyperv/netvsc_drv.c
2497
if (!net)
drivers/net/hyperv/netvsc_drv.c
2500
netif_carrier_off(net);
drivers/net/hyperv/netvsc_drv.c
2502
netvsc_init_settings(net);
drivers/net/hyperv/netvsc_drv.c
2504
net_device_ctx = netdev_priv(net);
drivers/net/hyperv/netvsc_drv.c
2508
netdev_dbg(net, "netvsc msg_enable: %d\n",
drivers/net/hyperv/netvsc_drv.c
2511
hv_set_drvdata(dev, net);
drivers/net/hyperv/netvsc_drv.c
2526
net->netdev_ops = &device_ops;
drivers/net/hyperv/netvsc_drv.c
2527
net->ethtool_ops = &ethtool_ops;
drivers/net/hyperv/netvsc_drv.c
2528
SET_NETDEV_DEV(net, &dev->device);
drivers/net/hyperv/netvsc_drv.c
2532
net->needed_headroom = RNDIS_AND_PPI_SIZE;
drivers/net/hyperv/netvsc_drv.c
2537
netif_set_real_num_tx_queues(net, 1);
drivers/net/hyperv/netvsc_drv.c
2538
netif_set_real_num_rx_queues(net, 1);
drivers/net/hyperv/netvsc_drv.c
2566
netdev_err(net, "unable to add netvsc device (ret %d)\n", ret);
drivers/net/hyperv/netvsc_drv.c
2570
eth_hw_addr_set(net, device_info->mac_adr);
drivers/net/hyperv/netvsc_drv.c
2576
net->features = net->hw_features |
drivers/net/hyperv/netvsc_drv.c
2579
net->vlan_features = net->features;
drivers/net/hyperv/netvsc_drv.c
2581
netdev_lockdep_set_classes(net);
drivers/net/hyperv/netvsc_drv.c
2583
net->xdp_features = NETDEV_XDP_ACT_BASIC | NETDEV_XDP_ACT_REDIRECT |
drivers/net/hyperv/netvsc_drv.c
2587
net->min_mtu = NETVSC_MTU_MIN;
drivers/net/hyperv/netvsc_drv.c
2589
net->max_mtu = NETVSC_MTU - ETH_HLEN;
drivers/net/hyperv/netvsc_drv.c
2591
net->max_mtu = ETH_DATA_LEN;
drivers/net/hyperv/netvsc_drv.c
2595
ret = register_netdevice(net);
drivers/net/hyperv/netvsc_drv.c
2613
for_each_netdev(dev_net(net), vf_netdev) {
drivers/net/hyperv/netvsc_drv.c
2618
if (net != get_netvsc_byslot(vf_netdev))
drivers/net/hyperv/netvsc_drv.c
2625
__netvsc_vf_setup(net, vf_netdev);
drivers/net/hyperv/netvsc_drv.c
2642
free_netdev(net);
drivers/net/hyperv/netvsc_drv.c
2650
struct net_device *vf_netdev, *net;
drivers/net/hyperv/netvsc_drv.c
2653
net = hv_get_drvdata(dev);
drivers/net/hyperv/netvsc_drv.c
2654
if (net == NULL) {
drivers/net/hyperv/netvsc_drv.c
2659
ndev_ctx = netdev_priv(net);
drivers/net/hyperv/netvsc_drv.c
2669
netvsc_xdp_set(net, NULL, NULL, nvdev);
drivers/net/hyperv/netvsc_drv.c
2683
unregister_netdevice(net);
drivers/net/hyperv/netvsc_drv.c
2691
free_netdev(net);
drivers/net/hyperv/netvsc_drv.c
2698
struct net_device *net;
drivers/net/hyperv/netvsc_drv.c
2701
net = hv_get_drvdata(dev);
drivers/net/hyperv/netvsc_drv.c
2703
ndev_ctx = netdev_priv(net);
drivers/net/hyperv/netvsc_drv.c
2721
ret = netvsc_detach(net, nvdev);
drivers/net/hyperv/netvsc_drv.c
2730
struct net_device *net = hv_get_drvdata(dev);
drivers/net/hyperv/netvsc_drv.c
2737
net_device_ctx = netdev_priv(net);
drivers/net/hyperv/netvsc_drv.c
2746
ret = netvsc_attach(net, device_info);
drivers/net/hyperv/netvsc_drv.c
416
static int netvsc_vf_xmit(struct net_device *net, struct net_device *vf_netdev,
drivers/net/hyperv/netvsc_drv.c
419
struct net_device_context *ndev_ctx = netdev_priv(net);
drivers/net/hyperv/netvsc_drv.c
442
static int netvsc_xmit(struct sk_buff *skb, struct net_device *net, bool xdp_tx)
drivers/net/hyperv/netvsc_drv.c
444
struct net_device_context *net_device_ctx = netdev_priv(net);
drivers/net/hyperv/netvsc_drv.c
460
netif_carrier_ok(vf_netdev) && !netpoll_tx_running(net) &&
drivers/net/hyperv/netvsc_drv.c
462
return netvsc_vf_xmit(net, vf_netdev, skb);
drivers/net/hyperv/netvsc_drv.c
520
if (hash != 0 && net->real_num_tx_queues > 1) {
drivers/net/hyperv/netvsc_drv.c
631
ret = netvsc_send(net, packet, rndis_msg, pb, skb, xdp_tx);
drivers/net/hyperv/netvsc_drv.c
645
net->stats.tx_dropped++;
drivers/net/hyperv/netvsc_drv.c
66
static void netvsc_change_rx_flags(struct net_device *net, int change)
drivers/net/hyperv/netvsc_drv.c
663
void netvsc_linkstatus_callback(struct net_device *net,
drivers/net/hyperv/netvsc_drv.c
668
struct net_device_context *ndev_ctx = netdev_priv(net);
drivers/net/hyperv/netvsc_drv.c
674
netdev_err(net, "invalid rndis_indicate_status packet, len: %u\n",
drivers/net/hyperv/netvsc_drv.c
68
struct net_device_context *ndev_ctx = netdev_priv(net);
drivers/net/hyperv/netvsc_drv.c
697
netdev_err(net, "invalid rndis_indicate_status packet\n");
drivers/net/hyperv/netvsc_drv.c
712
if (net->reg_state != NETREG_REGISTERED)
drivers/net/hyperv/netvsc_drv.c
752
static struct sk_buff *netvsc_alloc_recv_skb(struct net_device *net,
drivers/net/hyperv/netvsc_drv.c
76
inc = (net->flags & IFF_PROMISC) ? 1 : -1;
drivers/net/hyperv/netvsc_drv.c
795
skb->protocol = eth_type_trans(skb, net);
drivers/net/hyperv/netvsc_drv.c
81
inc = (net->flags & IFF_ALLMULTI) ? 1 : -1;
drivers/net/hyperv/netvsc_drv.c
817
if ((ppi_flags & NVSC_RSC_CSUM_INFO) && (net->features & NETIF_F_RXCSUM)) {
drivers/net/hyperv/netvsc_drv.c
823
if ((ppi_flags & NVSC_RSC_HASH_INFO) && (net->features & NETIF_F_RXHASH))
drivers/net/hyperv/netvsc_drv.c
841
int netvsc_recv_callback(struct net_device *net,
drivers/net/hyperv/netvsc_drv.c
845
struct net_device_context *net_device_ctx = netdev_priv(net);
drivers/net/hyperv/netvsc_drv.c
853
if (net->reg_state != NETREG_REGISTERED)
drivers/net/hyperv/netvsc_drv.c
856
act = netvsc_run_xdp(net, nvchan, &xdp);
drivers/net/hyperv/netvsc_drv.c
86
static void netvsc_set_rx_mode(struct net_device *net)
drivers/net/hyperv/netvsc_drv.c
870
skb = netvsc_alloc_recv_skb(net, nvchan, &xdp);
drivers/net/hyperv/netvsc_drv.c
88
struct net_device_context *ndev_ctx = netdev_priv(net);
drivers/net/hyperv/netvsc_drv.c
898
netvsc_xdp_xmit(skb, net);
drivers/net/hyperv/netvsc_drv.c
906
static void netvsc_get_drvinfo(struct net_device *net,
drivers/net/hyperv/netvsc_drv.c
913
static void netvsc_get_channels(struct net_device *net,
drivers/net/hyperv/netvsc_drv.c
916
struct net_device_context *net_device_ctx = netdev_priv(net);
drivers/net/hyperv/netvsc_drv.c
95
dev_uc_sync(vf_netdev, net);
drivers/net/hyperv/netvsc_drv.c
96
dev_mc_sync(vf_netdev, net);
drivers/net/hyperv/netvsc_trace.h
181
#define TRACE_INCLUDE_PATH ../../drivers/net/hyperv
drivers/net/hyperv/rndis_filter.c
1350
struct net_device *net = rndis_device->ndev;
drivers/net/hyperv/rndis_filter.c
1351
struct net_device_context *net_device_ctx = netdev_priv(net);
drivers/net/hyperv/rndis_filter.c
1370
net->hw_features &= ~NETVSC_SUPPORTED_HW_FEATURES;
drivers/net/hyperv/rndis_filter.c
1374
net->hw_features |= NETIF_F_RXCSUM;
drivers/net/hyperv/rndis_filter.c
1375
net->hw_features |= NETIF_F_SG;
drivers/net/hyperv/rndis_filter.c
1376
net->hw_features |= NETIF_F_RXHASH;
drivers/net/hyperv/rndis_filter.c
1380
net->hw_features |= NETIF_F_IP_CSUM;
drivers/net/hyperv/rndis_filter.c
1387
net->hw_features |= NETIF_F_TSO;
drivers/net/hyperv/rndis_filter.c
1400
net->hw_features |= NETIF_F_IPV6_CSUM;
drivers/net/hyperv/rndis_filter.c
1408
net->hw_features |= NETIF_F_TSO6;
drivers/net/hyperv/rndis_filter.c
1421
net->hw_features |= NETIF_F_LRO;
drivers/net/hyperv/rndis_filter.c
1423
if (net->features & NETIF_F_LRO) {
drivers/net/hyperv/rndis_filter.c
1435
net->features &= ~NETVSC_SUPPORTED_HW_FEATURES | net->hw_features;
drivers/net/hyperv/rndis_filter.c
1437
netif_set_tso_max_size(net, nvdev->netvsc_gso_max_size);
drivers/net/hyperv/rndis_filter.c
1439
ret = rndis_filter_set_offload_params(net, nvdev, &offloads);
drivers/net/hyperv/rndis_filter.c
1444
static void rndis_get_friendly_name(struct net_device *net,
drivers/net/hyperv/rndis_filter.c
1467
dev_set_alias(net, ifalias, len);
drivers/net/hyperv/rndis_filter.c
1473
struct net_device *net = hv_get_drvdata(dev);
drivers/net/hyperv/rndis_filter.c
1474
struct net_device_context *ndc = netdev_priv(net);
drivers/net/hyperv/rndis_filter.c
1502
rndis_device->ndev = net;
drivers/net/hyperv/rndis_filter.c
1514
if (ret == 0 && size == sizeof(u32) && mtu < net->mtu)
drivers/net/hyperv/rndis_filter.c
1515
net->mtu = mtu;
drivers/net/hyperv/rndis_filter.c
1525
if (!net->ifalias)
drivers/net/hyperv/rndis_filter.c
1526
rndis_get_friendly_name(net, rndis_device, net_device);
drivers/net/hyperv/rndis_filter.c
1535
netdev_dbg(net, "Device MAC %pM link state %s\n",
drivers/net/hyperv/rndis_filter.c
1573
if (!netif_is_rxfh_configured(net)) {
drivers/net/hyperv/rndis_filter.c
1592
netif_napi_add(net, &net_device->chan_table[i].napi,
drivers/net/hyperv/rndis_filter.c
1612
struct net_device *net = hv_get_drvdata(dev);
drivers/net/hyperv/rndis_filter.c
1615
ndc = netdev_priv(net);
drivers/net/ipvlan/ipvlan.h
177
void ipvlan_migrate_l3s_hook(struct net *oldnet, struct net *newnet);
drivers/net/ipvlan/ipvlan.h
190
static inline void ipvlan_migrate_l3s_hook(struct net *oldnet,
drivers/net/ipvlan/ipvlan.h
191
struct net *newnet)
drivers/net/ipvlan/ipvlan_core.c
431
struct net *net = dev_net(dev);
drivers/net/ipvlan/ipvlan_core.c
449
rt = ip_route_output_flow(net, &fl4, NULL);
drivers/net/ipvlan/ipvlan_core.c
461
err = ip_local_out(net, NULL, skb);
drivers/net/ipvlan/ipvlan_l3s.c
134
static int ipvlan_register_nf_hook(struct net *net)
drivers/net/ipvlan/ipvlan_l3s.c
136
struct ipvlan_netns *vnet = net_generic(net, ipvlan_netid);
drivers/net/ipvlan/ipvlan_l3s.c
140
err = nf_register_net_hooks(net, ipvl_nfops,
drivers/net/ipvlan/ipvlan_l3s.c
151
static void ipvlan_unregister_nf_hook(struct net *net)
drivers/net/ipvlan/ipvlan_l3s.c
153
struct ipvlan_netns *vnet = net_generic(net, ipvlan_netid);
drivers/net/ipvlan/ipvlan_l3s.c
160
nf_unregister_net_hooks(net, ipvl_nfops,
drivers/net/ipvlan/ipvlan_l3s.c
164
void ipvlan_migrate_l3s_hook(struct net *oldnet, struct net *newnet)
drivers/net/ipvlan/ipvlan_l3s.c
178
static void ipvlan_ns_exit(struct net *net)
drivers/net/ipvlan/ipvlan_l3s.c
180
struct ipvlan_netns *vnet = net_generic(net, ipvlan_netid);
drivers/net/ipvlan/ipvlan_l3s.c
184
nf_unregister_net_hooks(net, ipvl_nfops,
drivers/net/ipvlan/ipvlan_main.c
541
struct net *link_net = rtnl_newlink_link_net(params);
drivers/net/ipvlan/ipvlan_main.c
696
static struct net *ipvlan_get_link_net(const struct net_device *dev)
drivers/net/ipvlan/ipvlan_main.c
751
struct net *oldnet, *newnet = dev_net(dev);
drivers/net/loopback.c
207
static __net_init int loopback_net_init(struct net *net)
drivers/net/loopback.c
217
dev_net_set(dev, net);
drivers/net/loopback.c
223
net->loopback_dev = dev;
drivers/net/loopback.c
229
if (net_eq(net, &init_net))
drivers/net/macsec.c
1529
static struct net_device *get_dev_from_nl(struct net *net,
drivers/net/macsec.c
1535
dev = __dev_get_by_index(net, ifindex);
drivers/net/macsec.c
1571
static struct macsec_tx_sa *get_txsa_from_nl(struct net *net,
drivers/net/macsec.c
1589
dev = get_dev_from_nl(net, attrs);
drivers/net/macsec.c
1606
static struct macsec_rx_sc *get_rxsc_from_nl(struct net *net,
drivers/net/macsec.c
1617
dev = get_dev_from_nl(net, attrs);
drivers/net/macsec.c
1637
static struct macsec_rx_sa *get_rxsa_from_nl(struct net *net,
drivers/net/macsec.c
1654
rx_sc = get_rxsc_from_nl(net, attrs, tb_rxsc, devp, secyp);
drivers/net/macsec.c
3314
struct net *net = sock_net(skb->sk);
drivers/net/macsec.c
3325
for_each_netdev(net, dev) {
drivers/net/macsec.c
4167
struct net *link_net = rtnl_newlink_link_net(params);
drivers/net/macsec.c
4350
static struct net *macsec_get_link_net(const struct net_device *dev)
drivers/net/macvlan.c
1462
struct net *link_net = rtnl_newlink_link_net(params);
drivers/net/macvlan.c
1777
static struct net *macvlan_get_link_net(const struct net_device *dev)
drivers/net/macvtap.c
136
static struct net *macvtap_link_net(const struct net_device *dev)
drivers/net/netdevsim/bus.c
259
struct net *ns_a, *ns_b;
drivers/net/netdevsim/bus.c
355
struct net *ns;
drivers/net/netdevsim/fib.c
1183
static void nsim_nexthop_hw_flags_set(struct net *net,
drivers/net/netdevsim/fib.c
1189
nexthop_set_hw_flags(net, nexthop->id, false, trap);
drivers/net/netdevsim/fib.c
1195
nexthop_bucket_set_hw_flags(net, nexthop->id, i, false, trap);
drivers/net/netdevsim/fib.c
1202
struct net *net = devlink_net(data->devlink);
drivers/net/netdevsim/fib.c
1216
nsim_nexthop_hw_flags_set(net, nexthop, true);
drivers/net/netdevsim/fib.c
1230
struct net *net = devlink_net(data->devlink);
drivers/net/netdevsim/fib.c
1245
nsim_nexthop_hw_flags_set(net, nexthop, true);
drivers/net/netdevsim/fib.c
1315
nexthop_bucket_set_hw_flags(info->net, info->id,
drivers/net/netdevsim/fib.c
1356
struct net *net;
drivers/net/netdevsim/fib.c
1358
net = devlink_net(data->devlink);
drivers/net/netdevsim/fib.c
1359
nsim_nexthop_hw_flags_set(net, nexthop, false);
drivers/net/netdevsim/fib.c
1369
struct net *net = devlink_net(data->devlink);
drivers/net/netdevsim/fib.c
1406
nexthop_res_grp_activity_update(net, nhid, nexthop->occ, activity);
drivers/net/netdevsim/fib.c
318
nsim_fib4_rt_offload_failed_flag_set(struct net *net,
drivers/net/netdevsim/fib.c
333
fib_alias_hw_flags_set(net, &fri);
drivers/net/netdevsim/fib.c
336
static void nsim_fib4_rt_hw_flags_set(struct net *net,
drivers/net/netdevsim/fib.c
353
fib_alias_hw_flags_set(net, &fri);
drivers/net/netdevsim/fib.c
359
struct net *net = devlink_net(data->devlink);
drivers/net/netdevsim/fib.c
370
nsim_fib4_rt_hw_flags_set(net, fib4_rt, true);
drivers/net/netdevsim/fib.c
386
struct net *net = devlink_net(data->devlink);
drivers/net/netdevsim/fib.c
403
nsim_fib4_rt_hw_flags_set(net, fib4_rt, true);
drivers/net/netdevsim/fib.c
405
nsim_fib4_rt_hw_flags_set(net, fib4_rt_old, false);
drivers/net/netdevsim/fib.c
466
struct net *net = devlink_net(data->devlink);
drivers/net/netdevsim/fib.c
468
nsim_fib4_rt_offload_failed_flag_set(net, fen_info);
drivers/net/netdevsim/fib.c
648
struct net *net = devlink_net(data->devlink);
drivers/net/netdevsim/fib.c
652
fib6_info_hw_flags_set(net, rt_arr[i], false, false, true);
drivers/net/netdevsim/fib.c
667
struct net *net = devlink_net(data->devlink);
drivers/net/netdevsim/fib.c
671
fib6_info_hw_flags_set(net, fib6_rt_nh->rt, false, trap, false);
drivers/net/netdevsim/hwstats.c
223
struct net *net;
drivers/net/netdevsim/hwstats.c
227
net = nsim_dev_net(nsim_dev);
drivers/net/netdevsim/hwstats.c
235
netdev = dev_get_by_index(net, ifindex);
drivers/net/netdevsim/hwstats.c
407
struct net *net = nsim_dev_net(nsim_dev);
drivers/net/netdevsim/hwstats.c
414
err = register_netdevice_notifier_net(net, &hwstats->netdevice_nb);
drivers/net/netdevsim/hwstats.c
446
unregister_netdevice_notifier_net(net, &hwstats->netdevice_nb);
drivers/net/netdevsim/hwstats.c
473
struct net *net = nsim_dev_net(nsim_dev);
drivers/net/netdevsim/hwstats.c
477
unregister_netdevice_notifier_net(net, &hwstats->netdevice_nb);
drivers/net/netdevsim/netdevsim.h
384
static inline struct net *nsim_dev_net(struct nsim_dev *nsim_dev)
drivers/net/netdevsim/netdevsim.h
480
struct net *initial_net; /* Purpose of this is to carry net pointer
drivers/net/netdevsim/psp.c
24
struct net *net;
drivers/net/netdevsim/psp.c
46
net = sock_net(skb->sk);
drivers/net/netdevsim/psp.c
47
if (!psp_dev_encapsulate(net, skb, pas->tx.spi, pas->version, 0)) {
drivers/net/netkit.c
487
static struct net *netkit_get_link_net(const struct net_device *dev)
drivers/net/netkit.c
527
struct net *peer_net = rtnl_newlink_peer_net(params);
drivers/net/netkit.c
711
static struct net_device *netkit_dev_fetch(struct net *net, u32 ifindex, u32 which)
drivers/net/netkit.c
726
dev = __dev_get_by_index(net, ifindex);
drivers/net/ovpn/main.c
29
static void ovpn_priv_free(struct net_device *net)
drivers/net/ovpn/main.c
31
struct ovpn_priv *ovpn = netdev_priv(net);
drivers/net/ovpn/netlink.c
36
ovpn_get_dev_from_attrs(struct net *net, const struct genl_info *info,
drivers/net/ovpn/netlink.c
49
dev = dev_get_by_index_rcu(net, ifindex);
drivers/net/pfcp.c
162
struct net *net = pfcp->net;
drivers/net/pfcp.c
168
err = udp_sock_create(net, &udp_conf, &sock);
drivers/net/pfcp.c
176
setup_udp_tunnel_sock(net, sock->sk, &tuncfg);
drivers/net/pfcp.c
192
struct net *link_net = rtnl_newlink_link_net(params);
drivers/net/pfcp.c
197
pfcp->net = link_net;
drivers/net/pfcp.c
222
pfcp->net = NULL;
drivers/net/pfcp.c
23
struct net *net;
drivers/net/pfcp.c
242
static int __net_init pfcp_net_init(struct net *net)
drivers/net/pfcp.c
244
struct pfcp_net *pn = net_generic(net, pfcp_net_id);
drivers/net/pfcp.c
250
static void __net_exit pfcp_net_exit_rtnl(struct net *net,
drivers/net/pfcp.c
253
struct pfcp_net *pn = net_generic(net, pfcp_net_id);
drivers/net/ppp/ppp_generic.c
1047
static int ppp_unattached_ioctl(struct net *net, struct ppp_file *pf,
drivers/net/ppp/ppp_generic.c
1056
if (!ns_capable(net->user_ns, CAP_NET_ADMIN))
drivers/net/ppp/ppp_generic.c
1064
err = ppp_create_interface(net, file, &unit);
drivers/net/ppp/ppp_generic.c
1079
pn = ppp_pernet(net);
drivers/net/ppp/ppp_generic.c
1094
pn = ppp_pernet(net);
drivers/net/ppp/ppp_generic.c
1128
static __net_init int ppp_init_net(struct net *net)
drivers/net/ppp/ppp_generic.c
1130
struct ppp_net *pn = net_generic(net, ppp_net_id);
drivers/net/ppp/ppp_generic.c
1143
static __net_exit void ppp_exit_rtnl_net(struct net *net,
drivers/net/ppp/ppp_generic.c
1146
struct ppp_net *pn = net_generic(net, ppp_net_id);
drivers/net/ppp/ppp_generic.c
1154
static __net_exit void ppp_exit_net(struct net *net)
drivers/net/ppp/ppp_generic.c
1156
struct ppp_net *pn = net_generic(net, ppp_net_id);
drivers/net/ppp/ppp_generic.c
1235
static int ppp_dev_configure(struct net *src_net, struct net_device *dev,
drivers/net/ppp/ppp_generic.c
1314
struct net *link_net = rtnl_newlink_link_net(params);
drivers/net/ppp/ppp_generic.c
1378
static struct net *ppp_nl_get_link_net(const struct net_device *dev)
drivers/net/ppp/ppp_generic.c
157
struct net *ppp_net; /* the net we belong to */
drivers/net/ppp/ppp_generic.c
182
struct net *chan_net; /* the net channel belongs to */
drivers/net/ppp/ppp_generic.c
264
static int ppp_unattached_ioctl(struct net *net, struct ppp_file *pf,
drivers/net/ppp/ppp_generic.c
288
static int ppp_create_interface(struct net *net, struct file *file, int *unit);
drivers/net/ppp/ppp_generic.c
2906
int ppp_register_net_channel(struct net *net, struct ppp_channel *chan)
drivers/net/ppp/ppp_generic.c
2915
pn = ppp_pernet(net);
drivers/net/ppp/ppp_generic.c
2918
pch->chan_net = get_net_track(net, &pch->ns_tracker, GFP_KERNEL);
drivers/net/ppp/ppp_generic.c
309
static inline struct ppp_net *ppp_pernet(struct net *net)
drivers/net/ppp/ppp_generic.c
311
return net_generic(net, ppp_net_id);
drivers/net/ppp/ppp_generic.c
3355
static int ppp_create_interface(struct net *net, struct file *file, int *unit)
drivers/net/ppp/ppp_generic.c
3371
dev_net_set(dev, net);
drivers/net/ppp/ppp_generic.c
3376
err = ppp_dev_configure(net, dev, &conf);
drivers/net/ppp/pppoe.c
1079
static __net_init int pppoe_init_net(struct net *net)
drivers/net/ppp/pppoe.c
1081
struct pppoe_net *pn = pppoe_pernet(net);
drivers/net/ppp/pppoe.c
1086
pde = proc_create_net("pppoe", 0444, net->proc_net,
drivers/net/ppp/pppoe.c
1096
static __net_exit void pppoe_exit_net(struct net *net)
drivers/net/ppp/pppoe.c
1098
remove_proc_entry("pppoe", net->proc_net);
drivers/net/ppp/pppoe.c
121
static inline struct pppoe_net *pppoe_pernet(struct net *net)
drivers/net/ppp/pppoe.c
123
return net_generic(net, pppoe_net_id);
drivers/net/ppp/pppoe.c
513
static int pppoe_create(struct net *net, struct socket *sock, int kern)
drivers/net/ppp/pppoe.c
517
sk = sk_alloc(net, PF_PPPOX, GFP_KERNEL, &pppoe_sk_proto, kern);
drivers/net/ppp/pppoe.c
545
struct net *net = NULL;
drivers/net/ppp/pppoe.c
568
net = sock_net(sk);
drivers/net/ppp/pppoe.c
569
pn = pppoe_pernet(net);
drivers/net/ppp/pppoe.c
595
struct net *net = NULL;
drivers/net/ppp/pppoe.c
645
net = sock_net(sk);
drivers/net/ppp/pppoe.c
646
dev = dev_get_by_name(net, sp->sa_addr.pppoe.dev);
drivers/net/ppp/pppoe.c
652
pn = pppoe_pernet(net);
drivers/net/ppp/pppox.c
111
static int pppox_create(struct net *net, struct socket *sock, int protocol,
drivers/net/ppp/pppox.c
126
rc = pppox_protos[protocol]->create(net, sock, kern);
drivers/net/ppp/pptp.c
136
struct net *net;
drivers/net/ppp/pptp.c
138
net = sock_net(sk);
drivers/net/ppp/pptp.c
143
0, 0, sock_net_uid(net, sk));
drivers/net/ppp/pptp.c
146
return ip_route_output_flow(net, fl4, sk);
drivers/net/ppp/pptp.c
153
struct net *net = sock_net(sk);
drivers/net/ppp/pptp.c
260
ip_select_ident(net, skb, NULL);
drivers/net/ppp/pptp.c
263
ip_local_out(net, skb->sk, skb);
drivers/net/ppp/pptp.c
546
static int pptp_create(struct net *net, struct socket *sock, int kern)
drivers/net/ppp/pptp.c
553
sk = sk_alloc(net, PF_PPPOX, GFP_KERNEL, &pptp_sk_proto, kern);
drivers/net/rionet.c
406
unsigned char netid = rdev->net->hport->id;
drivers/net/rionet.c
553
unsigned char netid = rdev->net->hport->id;
drivers/net/rionet.c
564
rio_local_read_config_32(rdev->net->hport, RIO_SRC_OPS_CAR,
drivers/net/rionet.c
566
rio_local_read_config_32(rdev->net->hport, RIO_DST_OPS_CAR,
drivers/net/rionet.c
571
DRV_NAME, rdev->net->hport->name);
drivers/net/rionet.c
582
rc = rionet_setup_netdev(rdev->net->hport, ndev);
drivers/net/tap.c
448
struct net *net = current->nsproxy->net_ns;
drivers/net/tap.c
459
q = (struct tap_queue *)sk_alloc(net, AF_UNSPEC, GFP_KERNEL,
drivers/net/team/team_core.c
2483
struct net *net = genl_info_net(info);
drivers/net/team/team_core.c
2493
dev = dev_get_by_index(net, ifindex);
drivers/net/thunderbolt/main.c
1110
struct tbnet *net = netdev_priv(dev);
drivers/net/thunderbolt/main.c
1112
u16 frame_id = atomic_read(&net->frame_id);
drivers/net/thunderbolt/main.c
1126
if (tbnet_available_buffers(&net->tx_ring) < nframes) {
drivers/net/thunderbolt/main.c
1127
netif_stop_queue(net->dev);
drivers/net/thunderbolt/main.c
1131
frames[frame_index] = tbnet_get_tx_buffer(net);
drivers/net/thunderbolt/main.c
1181
frames[frame_index] = tbnet_get_tx_buffer(net);
drivers/net/thunderbolt/main.c
1219
if (!tbnet_xmit_csum_and_map(net, skb, frames, frame_index + 1))
drivers/net/thunderbolt/main.c
1223
tb_ring_tx(net->tx_ring.ring, &frames[i]->frame);
drivers/net/thunderbolt/main.c
1225
if (net->svc->prtcstns & TBNET_MATCH_FRAGS_ID)
drivers/net/thunderbolt/main.c
1226
atomic_inc(&net->frame_id);
drivers/net/thunderbolt/main.c
1228
net->stats.tx_packets++;
drivers/net/thunderbolt/main.c
1229
net->stats.tx_bytes += skb->len;
drivers/net/thunderbolt/main.c
1238
net->tx_ring.cons -= frame_index;
drivers/net/thunderbolt/main.c
1241
net->stats.tx_errors++;
drivers/net/thunderbolt/main.c
1249
struct tbnet *net = netdev_priv(dev);
drivers/net/thunderbolt/main.c
1251
stats->tx_packets = net->stats.tx_packets;
drivers/net/thunderbolt/main.c
1252
stats->rx_packets = net->stats.rx_packets;
drivers/net/thunderbolt/main.c
1253
stats->tx_bytes = net->stats.tx_bytes;
drivers/net/thunderbolt/main.c
1254
stats->rx_bytes = net->stats.rx_bytes;
drivers/net/thunderbolt/main.c
1255
stats->rx_errors = net->stats.rx_errors + net->stats.rx_length_errors +
drivers/net/thunderbolt/main.c
1256
net->stats.rx_over_errors + net->stats.rx_crc_errors +
drivers/net/thunderbolt/main.c
1257
net->stats.rx_missed_errors;
drivers/net/thunderbolt/main.c
1258
stats->tx_errors = net->stats.tx_errors;
drivers/net/thunderbolt/main.c
1259
stats->rx_length_errors = net->stats.rx_length_errors;
drivers/net/thunderbolt/main.c
1260
stats->rx_over_errors = net->stats.rx_over_errors;
drivers/net/thunderbolt/main.c
1261
stats->rx_crc_errors = net->stats.rx_crc_errors;
drivers/net/thunderbolt/main.c
1262
stats->rx_missed_errors = net->stats.rx_missed_errors;
drivers/net/thunderbolt/main.c
1276
const struct tbnet *net = netdev_priv(dev);
drivers/net/thunderbolt/main.c
1277
const struct tb_xdomain *xd = net->xd;
drivers/net/thunderbolt/main.c
1322
const struct tbnet *net = netdev_priv(dev);
drivers/net/thunderbolt/main.c
1323
const struct tb_xdomain *xd = net->xd;
drivers/net/thunderbolt/main.c
1346
struct tbnet *net;
drivers/net/thunderbolt/main.c
1349
dev = alloc_etherdev(sizeof(*net));
drivers/net/thunderbolt/main.c
1355
net = netdev_priv(dev);
drivers/net/thunderbolt/main.c
1356
INIT_DELAYED_WORK(&net->login_work, tbnet_login_work);
drivers/net/thunderbolt/main.c
1357
INIT_WORK(&net->connected_work, tbnet_connected_work);
drivers/net/thunderbolt/main.c
1358
INIT_WORK(&net->disconnect_work, tbnet_disconnect_work);
drivers/net/thunderbolt/main.c
1359
mutex_init(&net->connection_lock);
drivers/net/thunderbolt/main.c
1360
atomic_set(&net->command_id, 0);
drivers/net/thunderbolt/main.c
1361
atomic_set(&net->frame_id, 0);
drivers/net/thunderbolt/main.c
1362
net->svc = svc;
drivers/net/thunderbolt/main.c
1363
net->dev = dev;
drivers/net/thunderbolt/main.c
1364
net->xd = xd;
drivers/net/thunderbolt/main.c
1390
netif_napi_add(dev, &net->napi, tbnet_poll);
drivers/net/thunderbolt/main.c
1396
net->handler.uuid = &tbnet_svc_uuid;
drivers/net/thunderbolt/main.c
1397
net->handler.callback = tbnet_handle_packet;
drivers/net/thunderbolt/main.c
1398
net->handler.data = net;
drivers/net/thunderbolt/main.c
1399
tb_register_protocol_handler(&net->handler);
drivers/net/thunderbolt/main.c
1401
tb_service_set_drvdata(svc, net);
drivers/net/thunderbolt/main.c
1405
tb_unregister_protocol_handler(&net->handler);
drivers/net/thunderbolt/main.c
1415
struct tbnet *net = tb_service_get_drvdata(svc);
drivers/net/thunderbolt/main.c
1417
unregister_netdev(net->dev);
drivers/net/thunderbolt/main.c
1418
tb_unregister_protocol_handler(&net->handler);
drivers/net/thunderbolt/main.c
1419
free_netdev(net->dev);
drivers/net/thunderbolt/main.c
1430
struct tbnet *net = tb_service_get_drvdata(svc);
drivers/net/thunderbolt/main.c
1432
stop_login(net);
drivers/net/thunderbolt/main.c
1433
if (netif_running(net->dev)) {
drivers/net/thunderbolt/main.c
1434
netif_device_detach(net->dev);
drivers/net/thunderbolt/main.c
1435
tbnet_tear_down(net, true);
drivers/net/thunderbolt/main.c
1438
tb_unregister_protocol_handler(&net->handler);
drivers/net/thunderbolt/main.c
1445
struct tbnet *net = tb_service_get_drvdata(svc);
drivers/net/thunderbolt/main.c
1447
tb_register_protocol_handler(&net->handler);
drivers/net/thunderbolt/main.c
1449
netif_carrier_off(net->dev);
drivers/net/thunderbolt/main.c
1450
if (netif_running(net->dev)) {
drivers/net/thunderbolt/main.c
1451
netif_device_attach(net->dev);
drivers/net/thunderbolt/main.c
1452
start_login(net);
drivers/net/thunderbolt/main.c
242
static int tbnet_login_response(struct tbnet *net, u64 route, u8 sequence,
drivers/net/thunderbolt/main.c
246
struct tb_xdomain *xd = net->xd;
drivers/net/thunderbolt/main.c
252
memcpy(reply.receiver_mac, net->dev->dev_addr, ETH_ALEN);
drivers/net/thunderbolt/main.c
259
static int tbnet_login_request(struct tbnet *net, u8 sequence)
drivers/net/thunderbolt/main.c
263
struct tb_xdomain *xd = net->xd;
drivers/net/thunderbolt/main.c
268
atomic_inc_return(&net->command_id));
drivers/net/thunderbolt/main.c
271
request.transmit_path = net->local_transmit_path;
drivers/net/thunderbolt/main.c
279
static int tbnet_logout_response(struct tbnet *net, u64 route, u8 sequence,
drivers/net/thunderbolt/main.c
283
struct tb_xdomain *xd = net->xd;
drivers/net/thunderbolt/main.c
288
atomic_inc_return(&net->command_id));
drivers/net/thunderbolt/main.c
293
static int tbnet_logout_request(struct tbnet *net)
drivers/net/thunderbolt/main.c
297
struct tb_xdomain *xd = net->xd;
drivers/net/thunderbolt/main.c
302
atomic_inc_return(&net->command_id));
drivers/net/thunderbolt/main.c
310
static void start_login(struct tbnet *net)
drivers/net/thunderbolt/main.c
312
netdev_dbg(net->dev, "login started\n");
drivers/net/thunderbolt/main.c
314
mutex_lock(&net->connection_lock);
drivers/net/thunderbolt/main.c
315
net->login_sent = false;
drivers/net/thunderbolt/main.c
316
net->login_received = false;
drivers/net/thunderbolt/main.c
317
mutex_unlock(&net->connection_lock);
drivers/net/thunderbolt/main.c
319
queue_delayed_work(system_long_wq, &net->login_work,
drivers/net/thunderbolt/main.c
323
static void stop_login(struct tbnet *net)
drivers/net/thunderbolt/main.c
325
cancel_delayed_work_sync(&net->login_work);
drivers/net/thunderbolt/main.c
326
cancel_work_sync(&net->connected_work);
drivers/net/thunderbolt/main.c
328
netdev_dbg(net->dev, "login stopped\n");
drivers/net/thunderbolt/main.c
369
static void tbnet_tear_down(struct tbnet *net, bool send_logout)
drivers/net/thunderbolt/main.c
371
netif_carrier_off(net->dev);
drivers/net/thunderbolt/main.c
372
netif_stop_queue(net->dev);
drivers/net/thunderbolt/main.c
374
stop_login(net);
drivers/net/thunderbolt/main.c
376
mutex_lock(&net->connection_lock);
drivers/net/thunderbolt/main.c
378
if (net->login_sent && net->login_received) {
drivers/net/thunderbolt/main.c
382
netdev_dbg(net->dev, "sending logout request %u\n",
drivers/net/thunderbolt/main.c
384
ret = tbnet_logout_request(net);
drivers/net/thunderbolt/main.c
389
tb_ring_stop(net->rx_ring.ring);
drivers/net/thunderbolt/main.c
390
tb_ring_stop(net->tx_ring.ring);
drivers/net/thunderbolt/main.c
391
tbnet_free_buffers(&net->rx_ring);
drivers/net/thunderbolt/main.c
392
tbnet_free_buffers(&net->tx_ring);
drivers/net/thunderbolt/main.c
394
ret = tb_xdomain_disable_paths(net->xd,
drivers/net/thunderbolt/main.c
395
net->local_transmit_path,
drivers/net/thunderbolt/main.c
396
net->tx_ring.ring->hop,
drivers/net/thunderbolt/main.c
397
net->remote_transmit_path,
drivers/net/thunderbolt/main.c
398
net->rx_ring.ring->hop);
drivers/net/thunderbolt/main.c
400
netdev_warn(net->dev, "failed to disable DMA paths\n");
drivers/net/thunderbolt/main.c
402
tb_xdomain_release_in_hopid(net->xd, net->remote_transmit_path);
drivers/net/thunderbolt/main.c
403
net->remote_transmit_path = 0;
drivers/net/thunderbolt/main.c
406
net->login_retries = 0;
drivers/net/thunderbolt/main.c
407
net->login_sent = false;
drivers/net/thunderbolt/main.c
408
net->login_received = false;
drivers/net/thunderbolt/main.c
410
netdev_dbg(net->dev, "network traffic stopped\n");
drivers/net/thunderbolt/main.c
412
mutex_unlock(&net->connection_lock);
drivers/net/thunderbolt/main.c
418
struct tbnet *net = data;
drivers/net/thunderbolt/main.c
427
if (!uuid_equal(&pkg->hdr.initiator_uuid, net->xd->remote_uuid))
drivers/net/thunderbolt/main.c
429
if (!uuid_equal(&pkg->hdr.target_uuid, net->xd->local_uuid))
drivers/net/thunderbolt/main.c
434
if (route != net->xd->route)
drivers/net/thunderbolt/main.c
443
netdev_dbg(net->dev, "remote login request received\n");
drivers/net/thunderbolt/main.c
444
if (!netif_running(net->dev))
drivers/net/thunderbolt/main.c
447
ret = tbnet_login_response(net, route, sequence,
drivers/net/thunderbolt/main.c
450
netdev_dbg(net->dev, "remote login response sent\n");
drivers/net/thunderbolt/main.c
452
mutex_lock(&net->connection_lock);
drivers/net/thunderbolt/main.c
453
net->login_received = true;
drivers/net/thunderbolt/main.c
454
net->remote_transmit_path = pkg->transmit_path;
drivers/net/thunderbolt/main.c
460
if (net->login_retries >= TBNET_LOGIN_RETRIES ||
drivers/net/thunderbolt/main.c
461
!net->login_sent) {
drivers/net/thunderbolt/main.c
462
net->login_retries = 0;
drivers/net/thunderbolt/main.c
464
&net->login_work, 0);
drivers/net/thunderbolt/main.c
466
mutex_unlock(&net->connection_lock);
drivers/net/thunderbolt/main.c
468
queue_work(system_long_wq, &net->connected_work);
drivers/net/thunderbolt/main.c
473
netdev_dbg(net->dev, "remote logout request received\n");
drivers/net/thunderbolt/main.c
474
ret = tbnet_logout_response(net, route, sequence, command_id);
drivers/net/thunderbolt/main.c
476
netdev_dbg(net->dev, "remote logout response sent\n");
drivers/net/thunderbolt/main.c
477
queue_work(system_long_wq, &net->disconnect_work);
drivers/net/thunderbolt/main.c
486
netdev_warn(net->dev, "failed to send ThunderboltIP response\n");
drivers/net/thunderbolt/main.c
496
static int tbnet_alloc_rx_buffers(struct tbnet *net, unsigned int nbuffers)
drivers/net/thunderbolt/main.c
498
struct tbnet_ring *ring = &net->rx_ring;
drivers/net/thunderbolt/main.c
528
tf->dev = net->dev;
drivers/net/thunderbolt/main.c
545
static struct tbnet_frame *tbnet_get_tx_buffer(struct tbnet *net)
drivers/net/thunderbolt/main.c
547
struct tbnet_ring *ring = &net->tx_ring;
drivers/net/thunderbolt/main.c
570
struct tbnet *net = netdev_priv(tf->dev);
drivers/net/thunderbolt/main.c
573
net->tx_ring.prod++;
drivers/net/thunderbolt/main.c
575
if (tbnet_available_buffers(&net->tx_ring) >= TBNET_RING_SIZE / 2)
drivers/net/thunderbolt/main.c
576
netif_wake_queue(net->dev);
drivers/net/thunderbolt/main.c
579
static int tbnet_alloc_tx_buffers(struct tbnet *net)
drivers/net/thunderbolt/main.c
581
struct tbnet_ring *ring = &net->tx_ring;
drivers/net/thunderbolt/main.c
604
tf->dev = net->dev;
drivers/net/thunderbolt/main.c
621
struct tbnet *net = container_of(work, typeof(*net), connected_work);
drivers/net/thunderbolt/main.c
625
if (netif_carrier_ok(net->dev))
drivers/net/thunderbolt/main.c
628
mutex_lock(&net->connection_lock);
drivers/net/thunderbolt/main.c
629
connected = net->login_sent && net->login_received;
drivers/net/thunderbolt/main.c
630
mutex_unlock(&net->connection_lock);
drivers/net/thunderbolt/main.c
635
netdev_dbg(net->dev, "login successful, enabling paths\n");
drivers/net/thunderbolt/main.c
637
ret = tb_xdomain_alloc_in_hopid(net->xd, net->remote_transmit_path);
drivers/net/thunderbolt/main.c
638
if (ret != net->remote_transmit_path) {
drivers/net/thunderbolt/main.c
639
netdev_err(net->dev, "failed to allocate Rx HopID\n");
drivers/net/thunderbolt/main.c
650
tb_ring_start(net->tx_ring.ring);
drivers/net/thunderbolt/main.c
651
tb_ring_start(net->rx_ring.ring);
drivers/net/thunderbolt/main.c
653
ret = tbnet_alloc_rx_buffers(net, TBNET_RING_SIZE);
drivers/net/thunderbolt/main.c
657
ret = tbnet_alloc_tx_buffers(net);
drivers/net/thunderbolt/main.c
661
ret = tb_xdomain_enable_paths(net->xd, net->local_transmit_path,
drivers/net/thunderbolt/main.c
662
net->tx_ring.ring->hop,
drivers/net/thunderbolt/main.c
663
net->remote_transmit_path,
drivers/net/thunderbolt/main.c
664
net->rx_ring.ring->hop);
drivers/net/thunderbolt/main.c
666
netdev_err(net->dev, "failed to enable DMA paths\n");
drivers/net/thunderbolt/main.c
670
netif_carrier_on(net->dev);
drivers/net/thunderbolt/main.c
671
netif_start_queue(net->dev);
drivers/net/thunderbolt/main.c
673
netdev_dbg(net->dev, "network traffic started\n");
drivers/net/thunderbolt/main.c
677
tbnet_free_buffers(&net->tx_ring);
drivers/net/thunderbolt/main.c
679
tbnet_free_buffers(&net->rx_ring);
drivers/net/thunderbolt/main.c
681
tb_ring_stop(net->rx_ring.ring);
drivers/net/thunderbolt/main.c
682
tb_ring_stop(net->tx_ring.ring);
drivers/net/thunderbolt/main.c
683
tb_xdomain_release_in_hopid(net->xd, net->remote_transmit_path);
drivers/net/thunderbolt/main.c
688
struct tbnet *net = container_of(work, typeof(*net), login_work.work);
drivers/net/thunderbolt/main.c
692
if (netif_carrier_ok(net->dev))
drivers/net/thunderbolt/main.c
695
netdev_dbg(net->dev, "sending login request, retries=%u\n",
drivers/net/thunderbolt/main.c
696
net->login_retries);
drivers/net/thunderbolt/main.c
698
ret = tbnet_login_request(net, net->login_retries % 4);
drivers/net/thunderbolt/main.c
700
netdev_dbg(net->dev, "sending login request failed, ret=%d\n",
drivers/net/thunderbolt/main.c
702
if (net->login_retries++ < TBNET_LOGIN_RETRIES) {
drivers/net/thunderbolt/main.c
703
queue_delayed_work(system_long_wq, &net->login_work,
drivers/net/thunderbolt/main.c
706
netdev_info(net->dev, "ThunderboltIP login timed out\n");
drivers/net/thunderbolt/main.c
709
netdev_dbg(net->dev, "received login reply\n");
drivers/net/thunderbolt/main.c
711
net->login_retries = 0;
drivers/net/thunderbolt/main.c
713
mutex_lock(&net->connection_lock);
drivers/net/thunderbolt/main.c
714
net->login_sent = true;
drivers/net/thunderbolt/main.c
715
mutex_unlock(&net->connection_lock);
drivers/net/thunderbolt/main.c
717
queue_work(system_long_wq, &net->connected_work);
drivers/net/thunderbolt/main.c
723
struct tbnet *net = container_of(work, typeof(*net), disconnect_work);
drivers/net/thunderbolt/main.c
725
tbnet_tear_down(net, false);
drivers/net/thunderbolt/main.c
728
static bool tbnet_check_frame(struct tbnet *net, const struct tbnet_frame *tf,
drivers/net/thunderbolt/main.c
735
net->stats.rx_crc_errors++;
drivers/net/thunderbolt/main.c
738
net->stats.rx_over_errors++;
drivers/net/thunderbolt/main.c
745
net->stats.rx_length_errors++;
drivers/net/thunderbolt/main.c
755
net->stats.rx_length_errors++;
drivers/net/thunderbolt/main.c
762
if (net->skb && net->rx_hdr.frame_count) {
drivers/net/thunderbolt/main.c
764
if (frame_count != le32_to_cpu(net->rx_hdr.frame_count)) {
drivers/net/thunderbolt/main.c
765
net->stats.rx_length_errors++;
drivers/net/thunderbolt/main.c
772
if (frame_index != le16_to_cpu(net->rx_hdr.frame_index) + 1 ||
drivers/net/thunderbolt/main.c
773
frame_id != le16_to_cpu(net->rx_hdr.frame_id)) {
drivers/net/thunderbolt/main.c
774
net->stats.rx_missed_errors++;
drivers/net/thunderbolt/main.c
778
if (net->skb->len + frame_size > TBNET_MAX_MTU) {
drivers/net/thunderbolt/main.c
779
net->stats.rx_length_errors++;
drivers/net/thunderbolt/main.c
792
net->stats.rx_length_errors++;
drivers/net/thunderbolt/main.c
796
net->stats.rx_missed_errors++;
drivers/net/thunderbolt/main.c
805
struct tbnet *net = container_of(napi, struct tbnet, napi);
drivers/net/thunderbolt/main.c
806
unsigned int cleaned_count = tbnet_available_buffers(&net->rx_ring);
drivers/net/thunderbolt/main.c
807
struct device *dma_dev = tb_ring_dma_device(net->rx_ring.ring);
drivers/net/thunderbolt/main.c
825
tbnet_alloc_rx_buffers(net, cleaned_count);
drivers/net/thunderbolt/main.c
829
frame = tb_ring_poll(net->rx_ring.ring);
drivers/net/thunderbolt/main.c
840
net->rx_ring.cons++;
drivers/net/thunderbolt/main.c
844
if (!tbnet_check_frame(net, tf, hdr)) {
drivers/net/thunderbolt/main.c
848
dev_kfree_skb_any(net->skb);
drivers/net/thunderbolt/main.c
849
net->skb = NULL;
drivers/net/thunderbolt/main.c
857
skb = net->skb;
drivers/net/thunderbolt/main.c
863
net->stats.rx_errors++;
drivers/net/thunderbolt/main.c
870
net->skb = skb;
drivers/net/thunderbolt/main.c
877
net->rx_hdr.frame_size = hdr->frame_size;
drivers/net/thunderbolt/main.c
878
net->rx_hdr.frame_count = hdr->frame_count;
drivers/net/thunderbolt/main.c
879
net->rx_hdr.frame_index = hdr->frame_index;
drivers/net/thunderbolt/main.c
880
net->rx_hdr.frame_id = hdr->frame_id;
drivers/net/thunderbolt/main.c
881
last = le16_to_cpu(net->rx_hdr.frame_index) ==
drivers/net/thunderbolt/main.c
882
le32_to_cpu(net->rx_hdr.frame_count) - 1;
drivers/net/thunderbolt/main.c
885
net->stats.rx_bytes += frame_size;
drivers/net/thunderbolt/main.c
888
skb->protocol = eth_type_trans(skb, net->dev);
drivers/net/thunderbolt/main.c
890
napi_gro_receive(&net->napi, skb);
drivers/net/thunderbolt/main.c
891
net->skb = NULL;
drivers/net/thunderbolt/main.c
895
net->stats.rx_packets += rx_packets;
drivers/net/thunderbolt/main.c
898
tbnet_alloc_rx_buffers(net, cleaned_count);
drivers/net/thunderbolt/main.c
905
tb_ring_poll_complete(net->rx_ring.ring);
drivers/net/thunderbolt/main.c
912
struct tbnet *net = data;
drivers/net/thunderbolt/main.c
914
napi_schedule(&net->napi);
drivers/net/thunderbolt/main.c
919
struct tbnet *net = netdev_priv(dev);
drivers/net/thunderbolt/main.c
920
struct tb_xdomain *xd = net->xd;
drivers/net/thunderbolt/main.c
930
if (tbnet_e2e && net->svc->prtcstns & TBNET_E2E)
drivers/net/thunderbolt/main.c
938
net->tx_ring.ring = ring;
drivers/net/thunderbolt/main.c
943
tb_ring_free(net->tx_ring.ring);
drivers/net/thunderbolt/main.c
944
net->tx_ring.ring = NULL;
drivers/net/thunderbolt/main.c
947
net->local_transmit_path = hopid;
drivers/net/thunderbolt/main.c
953
net->tx_ring.ring->hop, sof_mask,
drivers/net/thunderbolt/main.c
954
eof_mask, tbnet_start_poll, net);
drivers/net/thunderbolt/main.c
958
tb_ring_free(net->tx_ring.ring);
drivers/net/thunderbolt/main.c
959
net->tx_ring.ring = NULL;
drivers/net/thunderbolt/main.c
962
net->rx_ring.ring = ring;
drivers/net/thunderbolt/main.c
964
tb_ring_throttling(net->tx_ring.ring, TBNET_THROTTLING);
drivers/net/thunderbolt/main.c
965
tb_ring_throttling(net->rx_ring.ring, TBNET_THROTTLING);
drivers/net/thunderbolt/main.c
967
napi_enable(&net->napi);
drivers/net/thunderbolt/main.c
968
start_login(net);
drivers/net/thunderbolt/main.c
975
struct tbnet *net = netdev_priv(dev);
drivers/net/thunderbolt/main.c
977
napi_disable(&net->napi);
drivers/net/thunderbolt/main.c
979
cancel_work_sync(&net->disconnect_work);
drivers/net/thunderbolt/main.c
980
tbnet_tear_down(net, true);
drivers/net/thunderbolt/main.c
982
tb_ring_free(net->rx_ring.ring);
drivers/net/thunderbolt/main.c
983
net->rx_ring.ring = NULL;
drivers/net/thunderbolt/main.c
985
tb_xdomain_release_out_hopid(net->xd, net->local_transmit_path);
drivers/net/thunderbolt/main.c
986
tb_ring_free(net->tx_ring.ring);
drivers/net/thunderbolt/main.c
987
net->tx_ring.ring = NULL;
drivers/net/thunderbolt/main.c
992
static bool tbnet_xmit_csum_and_map(struct tbnet *net, struct sk_buff *skb,
drivers/net/thunderbolt/main.c
996
struct device *dma_dev = tb_ring_dma_device(net->tx_ring.ring);
drivers/net/tun.c
2762
static int tun_set_iff(struct net *net, struct file *file, struct ifreq *ifr)
drivers/net/tun.c
2781
dev = __dev_get_by_name(net, ifr->ifr_name);
drivers/net/tun.c
2827
if (!ns_capable(net->user_ns, CAP_NET_ADMIN))
drivers/net/tun.c
2855
dev_net_set(dev, net);
drivers/net/tun.c
3114
struct net *net = sock_net(&tfile->sk);
drivers/net/tun.c
3143
if (!ns_capable(net->user_ns, CAP_NET_ADMIN))
drivers/net/tun.c
3145
return open_related_ns(&net->ns, get_net_ns);
drivers/net/tun.c
3158
ret = tun_set_iff(net, file, &ifr);
drivers/net/tun.c
3189
net = dev_net(tun->dev);
drivers/net/tun.c
3299
netif_get_mac_address(&ifr.ifr_hwaddr, net, tun->dev->name);
drivers/net/tun.c
3384
if (!ns_capable(net->user_ns, CAP_NET_ADMIN))
drivers/net/tun.c
3386
ret = open_related_ns(&net->ns, get_net_ns);
drivers/net/tun.c
3465
struct net *net = current->nsproxy->net_ns;
drivers/net/tun.c
3468
tfile = (struct tun_file *)sk_alloc(net, AF_UNSPEC, GFP_KERNEL,
drivers/net/tun.c
518
struct net *net = dev_net(tun->dev);
drivers/net/tun.c
522
!ns_capable(net->user_ns, CAP_NET_ADMIN);
drivers/net/usb/aqc111.c
1000
dev->net->hw_features |= AQ_SUPPORT_HW_FEATURE;
drivers/net/usb/aqc111.c
1001
dev->net->features |= AQ_SUPPORT_FEATURE;
drivers/net/usb/aqc111.c
1002
dev->net->vlan_features |= AQ_SUPPORT_VLAN_FEATURE;
drivers/net/usb/aqc111.c
1011
ETH_ALEN, dev->net->dev_addr);
drivers/net/usb/aqc111.c
1025
netif_carrier_off(dev->net);
drivers/net/usb/aqc111.c
105
netdev_warn(dev->net,
drivers/net/usb/aqc111.c
1052
netif_carrier_off(dev->net);
drivers/net/usb/aqc111.c
1145
new_skb = netdev_alloc_skb_ip_align(dev->net, pkt_len);
drivers/net/usb/aqc111.c
1216
if (!dev->can_dma_sg && (dev->net->features & NETIF_F_SG) &&
drivers/net/usb/aqc111.c
1363
ether_addr_copy(wol_cfg.hw_addr, dev->net->dev_addr);
drivers/net/usb/aqc111.c
1425
netif_carrier_off(dev->net);
drivers/net/usb/aqc111.c
200
static void aqc111_get_drvinfo(struct net_device *net,
drivers/net/usb/aqc111.c
203
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/aqc111.c
207
usbnet_get_drvinfo(net, info);
drivers/net/usb/aqc111.c
214
static void aqc111_get_wol(struct net_device *net,
drivers/net/usb/aqc111.c
217
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/aqc111.c
227
static int aqc111_set_wol(struct net_device *net,
drivers/net/usb/aqc111.c
230
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/aqc111.c
266
static int aqc111_get_link_ksettings(struct net_device *net,
drivers/net/usb/aqc111.c
269
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/aqc111.c
32
netdev_warn(dev->net,
drivers/net/usb/aqc111.c
368
static int aqc111_set_link_ksettings(struct net_device *net,
drivers/net/usb/aqc111.c
371
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/aqc111.c
422
static int aqc111_change_mtu(struct net_device *net, int new_mtu)
drivers/net/usb/aqc111.c
424
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/aqc111.c
428
WRITE_ONCE(net->mtu, new_mtu);
drivers/net/usb/aqc111.c
429
dev->hard_mtu = net->mtu + net->hard_header_len;
drivers/net/usb/aqc111.c
433
if (net->mtu > 1500)
drivers/net/usb/aqc111.c
441
if (dev->net->mtu > 12500) {
drivers/net/usb/aqc111.c
449
if (dev->net->mtu <= 4500)
drivers/net/usb/aqc111.c
451
else if (dev->net->mtu <= 9500)
drivers/net/usb/aqc111.c
453
else if (dev->net->mtu <= 12500)
drivers/net/usb/aqc111.c
464
static int aqc111_set_mac_addr(struct net_device *net, void *p)
drivers/net/usb/aqc111.c
466
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/aqc111.c
469
ret = eth_mac_addr(net, p);
drivers/net/usb/aqc111.c
475
ETH_ALEN, net->dev_addr);
drivers/net/usb/aqc111.c
478
static int aqc111_vlan_rx_kill_vid(struct net_device *net,
drivers/net/usb/aqc111.c
481
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/aqc111.c
504
static int aqc111_vlan_rx_add_vid(struct net_device *net, __be16 proto, u16 vid)
drivers/net/usb/aqc111.c
506
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/aqc111.c
51
netdev_warn(dev->net,
drivers/net/usb/aqc111.c
529
static void aqc111_set_rx_mode(struct net_device *net)
drivers/net/usb/aqc111.c
531
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/aqc111.c
535
mc_count = netdev_mc_count(net);
drivers/net/usb/aqc111.c
540
if (net->flags & IFF_PROMISC) {
drivers/net/usb/aqc111.c
542
} else if ((net->flags & IFF_ALLMULTI) || mc_count > AQ_MAX_MCAST) {
drivers/net/usb/aqc111.c
544
} else if (!netdev_mc_empty(net)) {
drivers/net/usb/aqc111.c
549
netdev_for_each_mc_addr(ha, net) {
drivers/net/usb/aqc111.c
566
static int aqc111_set_features(struct net_device *net,
drivers/net/usb/aqc111.c
569
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/aqc111.c
571
netdev_features_t changed = net->features ^ features;
drivers/net/usb/aqc111.c
664
ether_addr_copy(dev->net->perm_addr, buf);
drivers/net/usb/aqc111.c
702
netdev_dbg(dev->net, "usbnet_get_endpoints failed");
drivers/net/usb/aqc111.c
718
eth_hw_addr_set(dev->net, dev->net->perm_addr);
drivers/net/usb/aqc111.c
724
dev->net->needed_headroom += sizeof(u64);
drivers/net/usb/aqc111.c
725
dev->net->needed_tailroom += sizeof(u64);
drivers/net/usb/aqc111.c
727
dev->net->max_mtu = 16334;
drivers/net/usb/aqc111.c
729
dev->net->netdev_ops = &aqc111_netdev_ops;
drivers/net/usb/aqc111.c
730
dev->net->ethtool_ops = &aqc111_ethtool_ops;
drivers/net/usb/aqc111.c
735
dev->net->hw_features |= AQ_SUPPORT_HW_FEATURE;
drivers/net/usb/aqc111.c
736
dev->net->features |= AQ_SUPPORT_FEATURE;
drivers/net/usb/aqc111.c
737
dev->net->vlan_features |= AQ_SUPPORT_VLAN_FEATURE;
drivers/net/usb/aqc111.c
739
netif_set_tso_max_size(dev->net, 65535);
drivers/net/usb/aqc111.c
797
if (netif_carrier_ok(dev->net) != link)
drivers/net/usb/aqc111.c
859
if (dev->net->mtu > 12500 && dev->net->mtu <= 16334)
drivers/net/usb/aqc111.c
867
if (dev->net->mtu <= 4500)
drivers/net/usb/aqc111.c
869
else if (dev->net->mtu <= 9500)
drivers/net/usb/aqc111.c
871
else if (dev->net->mtu <= 12500)
drivers/net/usb/aqc111.c
873
else if (dev->net->mtu <= 16334)
drivers/net/usb/aqc111.c
878
netdev_info(dev->net, "Link Speed %d, USB %d", link_speed, usb_host);
drivers/net/usb/aqc111.c
885
if (dev->net->features & NETIF_F_RXCSUM) {
drivers/net/usb/aqc111.c
89
netdev_dbg(dev->net,
drivers/net/usb/aqc111.c
892
if (dev->net->features & NETIF_F_IP_CSUM)
drivers/net/usb/aqc111.c
895
if (dev->net->features & NETIF_F_IPV6_CSUM)
drivers/net/usb/aqc111.c
912
if (dev->net->features & NETIF_F_HW_VLAN_CTAG_FILTER)
drivers/net/usb/aqc111.c
949
aqc111_set_rx_mode(dev->net);
drivers/net/usb/aqc111.c
954
if (dev->net->mtu > 1500)
drivers/net/usb/aqc111.c
966
netif_carrier_on(dev->net);
drivers/net/usb/aqc111.c
985
netif_carrier_off(dev->net);
drivers/net/usb/asix.h
229
void asix_set_multicast(struct net_device *net);
drivers/net/usb/asix.h
241
void asix_get_wol(struct net_device *net, struct ethtool_wolinfo *wolinfo);
drivers/net/usb/asix.h
242
int asix_set_wol(struct net_device *net, struct ethtool_wolinfo *wolinfo);
drivers/net/usb/asix.h
244
int asix_get_eeprom_len(struct net_device *net);
drivers/net/usb/asix.h
245
int asix_get_eeprom(struct net_device *net, struct ethtool_eeprom *eeprom,
drivers/net/usb/asix.h
247
int asix_set_eeprom(struct net_device *net, struct ethtool_eeprom *eeprom,
drivers/net/usb/asix.h
250
int asix_set_mac_address(struct net_device *net, void *p);
drivers/net/usb/asix_common.c
158
netdev_err(dev->net, "asix_rx_fixup() Data Header synchronisation was lost, remaining %d\n",
drivers/net/usb/asix_common.c
190
netdev_err(dev->net, "asix_rx_fixup() Bad Header Length 0x%x, offset %d\n",
drivers/net/usb/asix_common.c
195
if (size > dev->net->mtu + ETH_HLEN + VLAN_HLEN) {
drivers/net/usb/asix_common.c
196
netdev_dbg(dev->net, "asix_rx_fixup() Bad RX Length %d\n",
drivers/net/usb/asix_common.c
207
rx->ax_skb = netdev_alloc_skb_ip_align(dev->net, size);
drivers/net/usb/asix_common.c
233
netdev_err(dev->net, "asix_rx_fixup() Bad SKB Length %d, %d\n",
drivers/net/usb/asix_common.c
33
netdev_warn(dev->net, "Failed to read reg index 0x%04x: %d\n",
drivers/net/usb/asix_common.c
339
netdev_err(dev->net, "invalid PHY address: %d\n", ret);
drivers/net/usb/asix_common.c
343
netdev_dbg(dev->net, "%s PHY address 0x%x\n",
drivers/net/usb/asix_common.c
349
netdev_err(dev->net, "Error reading PHY_ID register: %02x\n", ret);
drivers/net/usb/asix_common.c
360
netdev_err(dev->net, "Failed to send software reset: %02x\n", ret);
drivers/net/usb/asix_common.c
371
netdev_err(dev->net, "Error reading RX_CTL register: %02x\n", ret);
drivers/net/usb/asix_common.c
383
netdev_dbg(dev->net, "asix_write_rx_ctl() - mode = 0x%04x\n", mode);
drivers/net/usb/asix_common.c
386
netdev_err(dev->net, "Failed to write RX_CTL mode to 0x%04x: %02x\n",
drivers/net/usb/asix_common.c
399
netdev_err(dev->net, "Error reading Medium Status register: %02x\n",
drivers/net/usb/asix_common.c
412
netdev_dbg(dev->net, "asix_write_medium_mode() - mode = 0x%04x\n", mode);
drivers/net/usb/asix_common.c
416
netdev_err(dev->net, "Failed to write Medium Mode mode to 0x%04x: %02x\n",
drivers/net/usb/asix_common.c
426
netdev_dbg(dev->net, "asix_write_gpio() - value = 0x%04x\n", value);
drivers/net/usb/asix_common.c
429
netdev_err(dev->net, "Failed to write GPIO value 0x%04x: %02x\n",
drivers/net/usb/asix_common.c
441
void asix_set_multicast(struct net_device *net)
drivers/net/usb/asix_common.c
443
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/asix_common.c
447
if (net->flags & IFF_PROMISC) {
drivers/net/usb/asix_common.c
449
} else if (net->flags & IFF_ALLMULTI ||
drivers/net/usb/asix_common.c
450
netdev_mc_count(net) > AX_MAX_MCAST) {
drivers/net/usb/asix_common.c
452
} else if (netdev_mc_empty(net)) {
drivers/net/usb/asix_common.c
465
netdev_for_each_mc_addr(ha, net) {
drivers/net/usb/asix_common.c
504
netdev_dbg(dev->net, "asix_mdio_read() phy_id=0x%02x, loc=0x%02x, returns=0x%04x\n",
drivers/net/usb/asix_common.c
522
netdev_dbg(dev->net, "asix_mdio_write() phy_id=0x%02x, loc=0x%02x, val=0x%04x\n",
drivers/net/usb/asix_common.c
553
return __asix_mdio_read(priv->net, phy_id, regnum, false);
drivers/net/usb/asix_common.c
560
return __asix_mdio_write(priv->net, phy_id, regnum, val, false);
drivers/net/usb/asix_common.c
57
netdev_warn(dev->net, "Failed to write reg index 0x%04x: %d\n",
drivers/net/usb/asix_common.c
574
void asix_get_wol(struct net_device *net, struct ethtool_wolinfo *wolinfo)
drivers/net/usb/asix_common.c
576
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/asix_common.c
593
int asix_set_wol(struct net_device *net, struct ethtool_wolinfo *wolinfo)
drivers/net/usb/asix_common.c
595
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/asix_common.c
613
int asix_get_eeprom_len(struct net_device *net)
drivers/net/usb/asix_common.c
618
int asix_get_eeprom(struct net_device *net, struct ethtool_eeprom *eeprom,
drivers/net/usb/asix_common.c
621
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/asix_common.c
653
int asix_set_eeprom(struct net_device *net, struct ethtool_eeprom *eeprom,
drivers/net/usb/asix_common.c
656
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/asix_common.c
662
netdev_dbg(net, "write EEPROM len %d, offset %d, magic 0x%x\n",
drivers/net/usb/asix_common.c
685
netdev_err(net, "Failed to read EEPROM at offset 0x%02x.\n", first_word);
drivers/net/usb/asix_common.c
694
netdev_err(net, "Failed to read EEPROM at offset 0x%02x.\n", last_word);
drivers/net/usb/asix_common.c
704
netdev_err(net, "Failed to enable EEPROM write\n");
drivers/net/usb/asix_common.c
710
netdev_dbg(net, "write to EEPROM at offset 0x%02x, data 0x%04x\n",
drivers/net/usb/asix_common.c
715
netdev_err(net, "Failed to write EEPROM at offset 0x%02x.\n",
drivers/net/usb/asix_common.c
724
netdev_err(net, "Failed to disable EEPROM write\n");
drivers/net/usb/asix_common.c
734
int asix_set_mac_address(struct net_device *net, void *p)
drivers/net/usb/asix_common.c
736
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/asix_common.c
740
if (netif_running(net))
drivers/net/usb/asix_common.c
745
eth_hw_addr_set(net, addr->sa_data);
drivers/net/usb/asix_common.c
78
netdev_err(dev->net, "Failed to enable software MII access\n");
drivers/net/usb/asix_common.c
88
netdev_err(dev->net, "Failed to enable hardware MII access\n");
drivers/net/usb/asix_devices.c
1000
asix_mdio_write(dev->net, dev->mii.phy_id, MII_MARVELL_CTRL,
drivers/net/usb/asix_devices.c
1004
reg = asix_mdio_read(dev->net, dev->mii.phy_id,
drivers/net/usb/asix_devices.c
1006
netdev_dbg(dev->net, "MII_MARVELL_LED_CTRL (1) = 0x%04x\n", reg);
drivers/net/usb/asix_devices.c
1010
asix_mdio_write(dev->net, dev->mii.phy_id,
drivers/net/usb/asix_devices.c
1013
reg = asix_mdio_read(dev->net, dev->mii.phy_id,
drivers/net/usb/asix_devices.c
1015
netdev_dbg(dev->net, "MII_MARVELL_LED_CTRL (2) = 0x%04x\n", reg);
drivers/net/usb/asix_devices.c
1025
netdev_dbg(dev->net, "rtl8211cl_phy_init()\n");
drivers/net/usb/asix_devices.c
1027
asix_mdio_write (dev->net, dev->mii.phy_id, 0x1f, 0x0005);
drivers/net/usb/asix_devices.c
1028
asix_mdio_write (dev->net, dev->mii.phy_id, 0x0c, 0);
drivers/net/usb/asix_devices.c
1029
asix_mdio_write (dev->net, dev->mii.phy_id, 0x01,
drivers/net/usb/asix_devices.c
1030
asix_mdio_read (dev->net, dev->mii.phy_id, 0x01) | 0x0080);
drivers/net/usb/asix_devices.c
1031
asix_mdio_write (dev->net, dev->mii.phy_id, 0x1f, 0);
drivers/net/usb/asix_devices.c
1034
asix_mdio_write (dev->net, dev->mii.phy_id, 0x1f, 0x0002);
drivers/net/usb/asix_devices.c
1035
asix_mdio_write (dev->net, dev->mii.phy_id, 0x1a, 0x00cb);
drivers/net/usb/asix_devices.c
1036
asix_mdio_write (dev->net, dev->mii.phy_id, 0x1f, 0);
drivers/net/usb/asix_devices.c
1044
u16 reg = asix_mdio_read(dev->net, dev->mii.phy_id, MARVELL_LED_MANUAL);
drivers/net/usb/asix_devices.c
1046
netdev_dbg(dev->net, "marvell_led_status() read 0x%04x\n", reg);
drivers/net/usb/asix_devices.c
1062
netdev_dbg(dev->net, "marvell_led_status() writing 0x%04x\n", reg);
drivers/net/usb/asix_devices.c
1063
asix_mdio_write(dev->net, dev->mii.phy_id, MARVELL_LED_MANUAL, reg);
drivers/net/usb/asix_devices.c
1079
netdev_dbg(dev->net, "Failed to read GPIOS: %d\n", ret);
drivers/net/usb/asix_devices.c
1083
netdev_dbg(dev->net, "GPIO Status: 0x%04x\n", status);
drivers/net/usb/asix_devices.c
1088
netdev_dbg(dev->net, "Failed to read EEPROM: %d\n", ret);
drivers/net/usb/asix_devices.c
1094
netdev_dbg(dev->net, "EEPROM index 0x17 is 0x%04x\n", eeprom);
drivers/net/usb/asix_devices.c
1105
netdev_dbg(dev->net, "GPIO0: %d, PhyMode: %d\n", gpio0, data->phymode);
drivers/net/usb/asix_devices.c
1115
netdev_dbg(dev->net, "gpio phymode == 1 path\n");
drivers/net/usb/asix_devices.c
1122
netdev_dbg(dev->net, "PHYID=0x%08x\n", phyid);
drivers/net/usb/asix_devices.c
1142
asix_mdio_write(dev->net, dev->mii.phy_id, MII_ADVERTISE,
drivers/net/usb/asix_devices.c
1144
asix_mdio_write(dev->net, dev->mii.phy_id, MII_CTRL1000,
drivers/net/usb/asix_devices.c
1151
memcpy(data->mac_addr, dev->net->dev_addr, ETH_ALEN);
drivers/net/usb/asix_devices.c
1171
netdev_dbg(dev->net, "ax88178_link_reset()\n");
drivers/net/usb/asix_devices.c
118
static void ax88172_set_multicast(struct net_device *net)
drivers/net/usb/asix_devices.c
1192
netdev_dbg(dev->net, "ax88178_link_reset() speed: %u duplex: %d setting mode to 0x%04x\n",
drivers/net/usb/asix_devices.c
120
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/asix_devices.c
1228
if (dev->net->mtu > 1500)
drivers/net/usb/asix_devices.c
1238
static int ax88178_change_mtu(struct net_device *net, int new_mtu)
drivers/net/usb/asix_devices.c
124
if (net->flags & IFF_PROMISC) {
drivers/net/usb/asix_devices.c
1240
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/asix_devices.c
1241
int ll_mtu = new_mtu + net->hard_header_len + 4;
drivers/net/usb/asix_devices.c
1243
netdev_dbg(dev->net, "ax88178_change_mtu() new_mtu=%d\n", new_mtu);
drivers/net/usb/asix_devices.c
1248
WRITE_ONCE(net->mtu, new_mtu);
drivers/net/usb/asix_devices.c
1249
dev->hard_mtu = net->mtu + net->hard_header_len;
drivers/net/usb/asix_devices.c
126
} else if (net->flags & IFF_ALLMULTI ||
drivers/net/usb/asix_devices.c
127
netdev_mc_count(net) > AX_MAX_MCAST) {
drivers/net/usb/asix_devices.c
1283
netdev_dbg(dev->net, "Failed to read MAC address: %d\n", ret);
drivers/net/usb/asix_devices.c
129
} else if (netdev_mc_empty(net)) {
drivers/net/usb/asix_devices.c
1290
dev->mii.dev = dev->net;
drivers/net/usb/asix_devices.c
1301
dev->net->netdev_ops = &ax88178_netdev_ops;
drivers/net/usb/asix_devices.c
1302
dev->net->ethtool_ops = &ax88178_ethtool_ops;
drivers/net/usb/asix_devices.c
1303
dev->net->max_mtu = 16384 - (dev->net->hard_header_len + 4);
drivers/net/usb/asix_devices.c
142
netdev_for_each_mc_addr(ha, net) {
drivers/net/usb/asix_devices.c
169
netdev_dbg(dev->net, "ax88172_link_reset() speed: %u duplex: %d setting mode to 0x%04x\n",
drivers/net/usb/asix_devices.c
194
asix_mdio_write(dev->net, dev->mii.phy_id, MII_BMCR, reset_bits);
drivers/net/usb/asix_devices.c
201
if (asix_mdio_read(dev->net, dev->mii.phy_id, MII_BMCR)
drivers/net/usb/asix_devices.c
208
netdev_err(dev->net, "BMCR_RESET timeout on phy_id %d\n",
drivers/net/usb/asix_devices.c
240
netdev_dbg(dev->net, "read AX_CMD_READ_NODE_ID failed: %d\n",
drivers/net/usb/asix_devices.c
248
dev->mii.dev = dev->net;
drivers/net/usb/asix_devices.c
258
dev->net->netdev_ops = &ax88172_netdev_ops;
drivers/net/usb/asix_devices.c
259
dev->net->ethtool_ops = &ax88172_ethtool_ops;
drivers/net/usb/asix_devices.c
260
dev->net->needed_headroom = 4; /* cf asix_tx_fixup() */
drivers/net/usb/asix_devices.c
261
dev->net->needed_tailroom = 4; /* cf asix_tx_fixup() */
drivers/net/usb/asix_devices.c
264
asix_mdio_write(dev->net, dev->mii.phy_id, MII_ADVERTISE,
drivers/net/usb/asix_devices.c
339
ether_addr_copy(data->mac_addr, dev->net->dev_addr);
drivers/net/usb/asix_devices.c
377
netdev_dbg(dev->net, "Select PHY #1 failed: %d\n", ret);
drivers/net/usb/asix_devices.c
407
if (in_pm && (!asix_mdio_read_nopm(dev->net, dev->mii.phy_id,
drivers/net/usb/asix_devices.c
425
netdev_dbg(dev->net, "Write IPG,IPG1,IPG2 failed: %d\n", ret);
drivers/net/usb/asix_devices.c
430
ether_addr_copy(data->mac_addr, dev->net->dev_addr);
drivers/net/usb/asix_devices.c
442
netdev_dbg(dev->net, "RX_CTL is 0x%04x after all initializations\n",
drivers/net/usb/asix_devices.c
446
netdev_dbg(dev->net,
drivers/net/usb/asix_devices.c
470
netdev_dbg(dev->net, "Select PHY #1 failed: %d\n", ret);
drivers/net/usb/asix_devices.c
497
if (in_pm && (!asix_mdio_read_nopm(dev->net, dev->mii.phy_id,
drivers/net/usb/asix_devices.c
507
netdev_dbg(dev->net, "Write BQ setting failed: %d\n",
drivers/net/usb/asix_devices.c
513
phy14h = asix_mdio_read_nopm(dev->net, dev->mii.phy_id,
drivers/net/usb/asix_devices.c
515
phy15h = asix_mdio_read_nopm(dev->net, dev->mii.phy_id,
drivers/net/usb/asix_devices.c
517
phy16h = asix_mdio_read_nopm(dev->net, dev->mii.phy_id,
drivers/net/usb/asix_devices.c
520
netdev_dbg(dev->net,
drivers/net/usb/asix_devices.c
526
asix_mdio_write_nopm(dev->net, dev->mii.phy_id,
drivers/net/usb/asix_devices.c
53
if (netif_carrier_ok(dev->net) != link) {
drivers/net/usb/asix_devices.c
530
asix_mdio_write_nopm(dev->net, dev->mii.phy_id,
drivers/net/usb/asix_devices.c
534
asix_mdio_write_nopm(dev->net, dev->mii.phy_id,
drivers/net/usb/asix_devices.c
543
netdev_dbg(dev->net, "Write IPG,IPG1,IPG2 failed: %d\n", ret);
drivers/net/usb/asix_devices.c
548
memcpy(data->mac_addr, dev->net->dev_addr, ETH_ALEN);
drivers/net/usb/asix_devices.c
55
netdev_dbg(dev->net, "Link Status is: %d\n", link);
drivers/net/usb/asix_devices.c
569
netdev_dbg(dev->net, "RX_CTL is 0x%04x after all initializations\n",
drivers/net/usb/asix_devices.c
573
netdev_dbg(dev->net,
drivers/net/usb/asix_devices.c
601
if (netif_running(dev->net)) {
drivers/net/usb/asix_devices.c
612
netdev_dbg(dev->net, "ax88772_suspend: medium=0x%04x\n",
drivers/net/usb/asix_devices.c
62
eth_hw_addr_set(dev->net, addr);
drivers/net/usb/asix_devices.c
64
netdev_info(dev->net, "invalid hw address, using random\n");
drivers/net/usb/asix_devices.c
65
eth_hw_addr_random(dev->net);
drivers/net/usb/asix_devices.c
651
if (netif_running(dev->net)) {
drivers/net/usb/asix_devices.c
689
netdev_err(dev->net, "Could not register MDIO bus (err %d)\n", ret);
drivers/net/usb/asix_devices.c
710
netdev_err(dev->net, "Could not find PHY\n");
drivers/net/usb/asix_devices.c
716
netdev_err(dev->net, "Could not connect PHY\n");
drivers/net/usb/asix_devices.c
737
netdev_err(dev->net, "Could not find internal PHY\n");
drivers/net/usb/asix_devices.c
78
phy_reg = asix_mdio_read(dev->net, dev->mii.phy_id, MII_PHYSID1);
drivers/net/usb/asix_devices.c
805
priv->phylink_config.dev = &dev->net->dev;
drivers/net/usb/asix_devices.c
820
phylink = phylink_create(&priv->phylink_config, dev->net->dev.fwnode,
drivers/net/usb/asix_devices.c
847
netif_dbg(dev, ifup, dev->net,
drivers/net/usb/asix_devices.c
865
netdev_dbg(dev->net, "Failed to read MAC address: %d\n",
drivers/net/usb/asix_devices.c
873
dev->net->netdev_ops = &ax88772_netdev_ops;
drivers/net/usb/asix_devices.c
874
dev->net->ethtool_ops = &ax88772_ethtool_ops;
drivers/net/usb/asix_devices.c
875
dev->net->needed_headroom = 4; /* cf asix_tx_fixup() */
drivers/net/usb/asix_devices.c
876
dev->net->needed_tailroom = 4; /* cf asix_tx_fixup() */
drivers/net/usb/asix_devices.c
888
netdev_dbg(dev->net, "Failed to read STATMNGSTS_REG: %d\n", ret);
drivers/net/usb/asix_devices.c
903
netdev_dbg(dev->net, "Failed to reset AX88772: %d\n", ret);
drivers/net/usb/asix_devices.c
91
phy_reg = asix_mdio_read(dev->net, dev->mii.phy_id, MII_PHYSID2);
drivers/net/usb/asix_devices.c
995
netdev_dbg(dev->net, "marvell_phy_init()\n");
drivers/net/usb/asix_devices.c
997
reg = asix_mdio_read(dev->net, dev->mii.phy_id, MII_MARVELL_STATUS);
drivers/net/usb/asix_devices.c
998
netdev_dbg(dev->net, "MII_MARVELL_STATUS = 0x%04x\n", reg);
drivers/net/usb/ax88172a.c
177
netdev_err(dev->net, "Failed to read MAC address: %d\n", ret);
drivers/net/usb/ax88172a.c
181
eth_hw_addr_set(dev->net, buf);
drivers/net/usb/ax88172a.c
183
dev->net->netdev_ops = &ax88172a_netdev_ops;
drivers/net/usb/ax88172a.c
184
dev->net->ethtool_ops = &ax88172a_ethtool_ops;
drivers/net/usb/ax88172a.c
189
netdev_err(dev->net, "Failed to read software interface selection register: %d\n",
drivers/net/usb/ax88172a.c
194
netdev_dbg(dev->net, "AX_CMD_SW_PHY_STATUS = 0x%02x\n", buf[0]);
drivers/net/usb/ax88172a.c
197
netdev_dbg(dev->net, "use internal phy\n");
drivers/net/usb/ax88172a.c
201
netdev_dbg(dev->net, "use external phy\n");
drivers/net/usb/ax88172a.c
205
netdev_err(dev->net, "Interface mode not supported by driver\n");
drivers/net/usb/ax88172a.c
241
netdev_dbg(dev->net, "Stopping interface\n");
drivers/net/usb/ax88172a.c
244
netdev_info(dev->net, "Disconnecting from phy %s\n",
drivers/net/usb/ax88172a.c
272
netdev_dbg(dev->net, "RX_CTL is 0x%04x after software reset\n", rx_ctl);
drivers/net/usb/ax88172a.c
278
netdev_dbg(dev->net, "RX_CTL is 0x%04x setting to 0x0000\n", rx_ctl);
drivers/net/usb/ax88172a.c
286
netdev_err(dev->net, "Write IPG,IPG1,IPG2 failed: %d\n", ret);
drivers/net/usb/ax88172a.c
291
memcpy(data->mac_addr, dev->net->dev_addr, ETH_ALEN);
drivers/net/usb/ax88172a.c
303
netdev_dbg(dev->net, "RX_CTL is 0x%04x after all initializations\n",
drivers/net/usb/ax88172a.c
307
netdev_dbg(dev->net, "Medium Status is 0x%04x after all initializations\n",
drivers/net/usb/ax88172a.c
314
priv->phydev = phy_connect(dev->net, priv->phy_name,
drivers/net/usb/ax88172a.c
318
netdev_err(dev->net, "Could not connect to PHY device %s\n",
drivers/net/usb/ax88172a.c
324
netdev_info(dev->net, "Connected to phy %s\n", priv->phy_name);
drivers/net/usb/ax88172a.c
68
netdev_err(dev->net, "Could not allocate MDIO bus\n");
drivers/net/usb/ax88172a.c
82
netdev_err(dev->net, "Could not register MDIO bus\n");
drivers/net/usb/ax88172a.c
86
netdev_info(dev->net, "registered mdio bus %s\n", priv->mdio->id);
drivers/net/usb/ax88172a.c
98
netdev_info(dev->net, "deregistering mdio bus %s\n", priv->mdio->id);
drivers/net/usb/ax88179_178a.c
1260
netif_dbg(dev, ifup, dev->net,
drivers/net/usb/ax88179_178a.c
1265
netif_dbg(dev, ifup, dev->net,
drivers/net/usb/ax88179_178a.c
1270
eth_hw_addr_set(dev->net, mac);
drivers/net/usb/ax88179_178a.c
1272
dev->net->addr_assign_type = NET_ADDR_PERM;
drivers/net/usb/ax88179_178a.c
1274
netdev_info(dev->net, "invalid MAC address, using random\n");
drivers/net/usb/ax88179_178a.c
1278
dev->net->dev_addr);
drivers/net/usb/ax88179_178a.c
1296
dev->net->netdev_ops = &ax88179_netdev_ops;
drivers/net/usb/ax88179_178a.c
1297
dev->net->ethtool_ops = &ax88179_ethtool_ops;
drivers/net/usb/ax88179_178a.c
1298
dev->net->needed_headroom = 8;
drivers/net/usb/ax88179_178a.c
1299
dev->net->max_mtu = 4088;
drivers/net/usb/ax88179_178a.c
1302
dev->mii.dev = dev->net;
drivers/net/usb/ax88179_178a.c
1310
dev->net->features |= NETIF_F_SG | NETIF_F_IP_CSUM |
drivers/net/usb/ax88179_178a.c
1313
dev->net->hw_features |= dev->net->features;
drivers/net/usb/ax88179_178a.c
1315
netif_set_tso_max_size(dev->net, 16384);
drivers/net/usb/ax88179_178a.c
1444
dev->net->stats.rx_errors++;
drivers/net/usb/ax88179_178a.c
1460
ax_skb = netdev_alloc_skb_ip_align(dev->net, pkt_len);
drivers/net/usb/ax88179_178a.c
1490
if ((dev->net->features & NETIF_F_SG) && skb_linearize(skb))
drivers/net/usb/ax88179_178a.c
1540
netdev_info(dev->net, "ax88179 - Link status is: 0\n");
drivers/net/usb/ax88179_178a.c
1544
if (dev->net->mtu > 1500)
drivers/net/usb/ax88179_178a.c
1576
netif_carrier_on(dev->net);
drivers/net/usb/ax88179_178a.c
1578
netdev_info(dev->net, "ax88179 - Link status is: 1\n");
drivers/net/usb/ax88179_178a.c
1611
memcpy(dev->net->perm_addr, dev->net->dev_addr, ETH_ALEN);
drivers/net/usb/ax88179_178a.c
225
netdev_warn(dev->net, "Failed to read reg index 0x%04x: %d\n",
drivers/net/usb/ax88179_178a.c
249
netdev_warn(dev->net, "Failed to write reg index 0x%04x: %d\n",
drivers/net/usb/ax88179_178a.c
327
if (netif_carrier_ok(dev->net) != link) {
drivers/net/usb/ax88179_178a.c
330
netdev_info(dev->net, "ax88179 - Link status is: 0\n");
drivers/net/usb/ax88179_178a.c
514
ax88179_get_wol(struct net_device *net, struct ethtool_wolinfo *wolinfo)
drivers/net/usb/ax88179_178a.c
516
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/ax88179_178a.c
524
ax88179_set_wol(struct net_device *net, struct ethtool_wolinfo *wolinfo)
drivers/net/usb/ax88179_178a.c
526
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/ax88179_178a.c
537
static int ax88179_get_eeprom_len(struct net_device *net)
drivers/net/usb/ax88179_178a.c
543
ax88179_get_eeprom(struct net_device *net, struct ethtool_eeprom *eeprom,
drivers/net/usb/ax88179_178a.c
546
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/ax88179_178a.c
579
ax88179_set_eeprom(struct net_device *net, struct ethtool_eeprom *eeprom,
drivers/net/usb/ax88179_178a.c
582
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/ax88179_178a.c
589
netdev_dbg(net, "write EEPROM len %d, offset %d, magic 0x%x\n",
drivers/net/usb/ax88179_178a.c
612
netdev_err(net, "Failed to read EEPROM at offset 0x%02x.\n", first_word);
drivers/net/usb/ax88179_178a.c
621
netdev_err(net, "Failed to read EEPROM at offset 0x%02x.\n", last_word);
drivers/net/usb/ax88179_178a.c
629
netdev_dbg(net, "write to EEPROM at offset 0x%02x, data 0x%04x\n",
drivers/net/usb/ax88179_178a.c
634
netdev_err(net, "Failed to write EEPROM at offset 0x%02x.\n", i);
drivers/net/usb/ax88179_178a.c
643
netdev_err(net, "Failed to reload EEPROM data\n");
drivers/net/usb/ax88179_178a.c
653
static int ax88179_get_link_ksettings(struct net_device *net,
drivers/net/usb/ax88179_178a.c
656
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/ax88179_178a.c
663
static int ax88179_set_link_ksettings(struct net_device *net,
drivers/net/usb/ax88179_178a.c
666
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/ax88179_178a.c
811
static int ax88179_get_eee(struct net_device *net, struct ethtool_keee *edata)
drivers/net/usb/ax88179_178a.c
813
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/ax88179_178a.c
822
static int ax88179_set_eee(struct net_device *net, struct ethtool_keee *edata)
drivers/net/usb/ax88179_178a.c
824
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/ax88179_178a.c
867
static void ax88179_set_multicast(struct net_device *net)
drivers/net/usb/ax88179_178a.c
869
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/ax88179_178a.c
875
if (net->flags & IFF_PROMISC) {
drivers/net/usb/ax88179_178a.c
877
} else if (net->flags & IFF_ALLMULTI ||
drivers/net/usb/ax88179_178a.c
878
netdev_mc_count(net) > AX_MAX_MCAST) {
drivers/net/usb/ax88179_178a.c
880
} else if (netdev_mc_empty(net)) {
drivers/net/usb/ax88179_178a.c
891
netdev_for_each_mc_addr(ha, net) {
drivers/net/usb/ax88179_178a.c
908
ax88179_set_features(struct net_device *net, netdev_features_t features)
drivers/net/usb/ax88179_178a.c
911
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/ax88179_178a.c
912
netdev_features_t changed = net->features ^ features;
drivers/net/usb/ax88179_178a.c
936
static int ax88179_change_mtu(struct net_device *net, int new_mtu)
drivers/net/usb/ax88179_178a.c
938
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/ax88179_178a.c
941
WRITE_ONCE(net->mtu, new_mtu);
drivers/net/usb/ax88179_178a.c
942
dev->hard_mtu = net->mtu + net->hard_header_len;
drivers/net/usb/ax88179_178a.c
944
if (net->mtu > 1500) {
drivers/net/usb/ax88179_178a.c
964
static int ax88179_set_mac_addr(struct net_device *net, void *p)
drivers/net/usb/ax88179_178a.c
966
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/ax88179_178a.c
970
if (netif_running(net))
drivers/net/usb/ax88179_178a.c
975
eth_hw_addr_set(net, addr->sa_data);
drivers/net/usb/ax88179_178a.c
979
ETH_ALEN, net->dev_addr);
drivers/net/usb/cdc_eem.c
201
netdev_dbg(dev->net, "reserved command %04x\n",
drivers/net/usb/cdc_eem.c
249
netdev_warn(dev->net,
drivers/net/usb/cdc_eem.c
317
dev->net->stats.rx_errors++;
drivers/net/usb/cdc_eem.c
64
netdev_warn(dev->net, "link cmd failure\n");
drivers/net/usb/cdc_eem.c
79
dev->net->hard_header_len += EEM_HEAD + ETH_FCS_LEN + VLAN_HLEN;
drivers/net/usb/cdc_eem.c
80
dev->hard_mtu = dev->net->mtu + dev->net->hard_header_len;
drivers/net/usb/cdc_ether.c
329
dev->net->ethtool_ops = &cdc_ether_ethtool_ops;
drivers/net/usb/cdc_ether.c
425
netif_dbg(dev, timer, dev->net, "CDC: carrier %s\n",
drivers/net/usb/cdc_ether.c
427
if (netif_carrier_ok(dev->net) != !!event->wValue)
drivers/net/usb/cdc_ether.c
431
netif_dbg(dev, timer, dev->net, "CDC: speed change (len %d)\n",
drivers/net/usb/cdc_ether.c
442
netdev_err(dev->net, "CDC: unexpected notification %02x!\n",
drivers/net/usb/cdc_ether.c
476
if (!status && (dev->net->dev_addr[0] & 0x02))
drivers/net/usb/cdc_ether.c
477
eth_hw_addr_random(dev->net);
drivers/net/usb/cdc_ether.c
495
ether_addr_copy(eth_hdr(skb)->h_dest, dev->net->dev_addr);
drivers/net/usb/cdc_ether.c
521
netif_dbg(dev, timer, dev->net, "CDC: carrier %s\n",
drivers/net/usb/cdc_ether.c
525
netif_carrier_ok(dev->net))
drivers/net/usb/cdc_ether.c
526
netif_carrier_off(dev->net);
drivers/net/usb/cdc_ether.c
68
struct net_device *net = dev->net;
drivers/net/usb/cdc_ether.c
77
if (net->flags & IFF_PROMISC)
drivers/net/usb/cdc_ether.c
79
if (!netdev_mc_empty(net) || (net->flags & IFF_ALLMULTI))
drivers/net/usb/cdc_mbim.c
184
dev->net->flags |= IFF_NOARP;
drivers/net/usb/cdc_mbim.c
187
dev->net->features |= NETIF_F_HW_VLAN_CTAG_TX | NETIF_F_HW_VLAN_CTAG_FILTER;
drivers/net/usb/cdc_mbim.c
190
dev->net->netdev_ops = &cdc_mbim_netdev_ops;
drivers/net/usb/cdc_mbim.c
286
netif_err(dev, tx_err, dev->net,
drivers/net/usb/cdc_mbim.c
327
netdev = __vlan_find_dev_deep_rcu(dev->net, htons(ETH_P_8021Q),
drivers/net/usb/cdc_mbim.c
334
netdev = dev->net;
drivers/net/usb/cdc_mbim.c
391
skb = netdev_alloc_skb_ip_align(dev->net, len + ETH_HLEN);
drivers/net/usb/cdc_mbim.c
400
memcpy(eth_hdr(skb)->h_dest, dev->net->dev_addr, ETH_ALEN);
drivers/net/usb/cdc_mbim.c
453
netif_dbg(dev, rx_err, dev->net,
drivers/net/usb/cdc_mbim.c
477
netif_dbg(dev, rx_err, dev->net,
drivers/net/usb/cdc_ncm.c
1328
dev->net->stats.tx_dropped++;
drivers/net/usb/cdc_ncm.c
1333
dev->net->stats.tx_dropped++;
drivers/net/usb/cdc_ncm.c
1378
dev->net->stats.tx_dropped++;
drivers/net/usb/cdc_ncm.c
1472
dev->net->stats.tx_dropped++;
drivers/net/usb/cdc_ncm.c
1511
} else if (dev->net != NULL) {
drivers/net/usb/cdc_ncm.c
1514
netif_tx_lock_bh(dev->net);
drivers/net/usb/cdc_ncm.c
1515
usbnet_start_xmit(NULL, dev->net);
drivers/net/usb/cdc_ncm.c
1516
netif_tx_unlock_bh(dev->net);
drivers/net/usb/cdc_ncm.c
1569
netif_dbg(dev, rx_err, dev->net, "frame too short\n");
drivers/net/usb/cdc_ncm.c
1576
netif_dbg(dev, rx_err, dev->net,
drivers/net/usb/cdc_ncm.c
1584
netif_dbg(dev, rx_err, dev->net,
drivers/net/usb/cdc_ncm.c
1593
netif_dbg(dev, rx_err, dev->net,
drivers/net/usb/cdc_ncm.c
1617
netif_dbg(dev, rx_err, dev->net, "frame too short\n");
drivers/net/usb/cdc_ncm.c
1624
netif_dbg(dev, rx_err, dev->net,
drivers/net/usb/cdc_ncm.c
1632
netif_dbg(dev, rx_err, dev->net,
drivers/net/usb/cdc_ncm.c
1641
netif_dbg(dev, rx_err, dev->net,
drivers/net/usb/cdc_ncm.c
1662
netif_dbg(dev, rx_err, dev->net, "invalid NDP offset <%u>\n",
drivers/net/usb/cdc_ncm.c
1669
netif_dbg(dev, rx_err, dev->net, "invalid DPT16 length <%u>\n",
drivers/net/usb/cdc_ncm.c
1681
netif_dbg(dev, rx_err, dev->net, "Invalid nframes = %d\n", ret);
drivers/net/usb/cdc_ncm.c
1699
netif_dbg(dev, rx_err, dev->net, "invalid NDP offset <%u>\n",
drivers/net/usb/cdc_ncm.c
1706
netif_dbg(dev, rx_err, dev->net, "invalid DPT32 length <%u>\n",
drivers/net/usb/cdc_ncm.c
1718
netif_dbg(dev, rx_err, dev->net, "Invalid nframes = %d\n", ret);
drivers/net/usb/cdc_ncm.c
1765
netif_dbg(dev, rx_err, dev->net,
drivers/net/usb/cdc_ncm.c
1779
netif_dbg(dev, rx_err, dev->net,
drivers/net/usb/cdc_ncm.c
1809
netif_dbg(dev, rx_err, dev->net,
drivers/net/usb/cdc_ncm.c
1818
skb = netdev_alloc_skb_ip_align(dev->net, len);
drivers/net/usb/cdc_ncm.c
1886
if (netif_carrier_ok(dev->net) != !!event->wValue)
drivers/net/usb/cdc_ncm.c
346
netif_tx_lock_bh(dev->net);
drivers/net/usb/cdc_ncm.c
347
usbnet_start_xmit(NULL, dev->net);
drivers/net/usb/cdc_ncm.c
354
netif_tx_unlock_bh(dev->net);
drivers/net/usb/cdc_ncm.c
432
if (netif_running(dev->net))
drivers/net/usb/cdc_ncm.c
452
if (netif_running(dev->net) && val > ctx->tx_max) {
drivers/net/usb/cdc_ncm.c
453
netif_tx_lock_bh(dev->net);
drivers/net/usb/cdc_ncm.c
454
usbnet_start_xmit(NULL, dev->net);
drivers/net/usb/cdc_ncm.c
461
netif_tx_unlock_bh(dev->net);
drivers/net/usb/cdc_ncm.c
647
dev->net->mtu = min_t(int, dev->net->mtu, ctx->max_datagram_size - cdc_ncm_eth_hlen(dev));
drivers/net/usb/cdc_ncm.c
652
if (mbim_mtu != 0 && mbim_mtu < dev->net->mtu)
drivers/net/usb/cdc_ncm.c
653
dev->net->mtu = mbim_mtu;
drivers/net/usb/cdc_ncm.c
797
int cdc_ncm_change_mtu(struct net_device *net, int new_mtu)
drivers/net/usb/cdc_ncm.c
799
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/cdc_ncm.c
801
WRITE_ONCE(net->mtu, new_mtu);
drivers/net/usb/cdc_ncm.c
953
dev_info(&intf->dev, "MAC-Address: %pM\n", dev->net->dev_addr);
drivers/net/usb/cdc_ncm.c
974
dev->net->ethtool_ops = &cdc_ncm_ethtool_ops;
drivers/net/usb/cdc_ncm.c
977
dev->net->sysfs_groups[0] = &cdc_ncm_sysfs_attr_group;
drivers/net/usb/cdc_ncm.c
980
dev->net->netdev_ops = &cdc_ncm_netdev_ops;
drivers/net/usb/cdc_ncm.c
981
dev->net->max_mtu = cdc_ncm_max_dgram_size(dev) - cdc_ncm_eth_hlen(dev);
drivers/net/usb/ch9200.c
114
netdev_dbg(dev->net, "%s() index=0x%02x size=%d\n",
drivers/net/usb/ch9200.c
152
netdev_dbg(dev->net, "%s() index=0x%02x size=%d\n",
drivers/net/usb/ch9200.c
223
netdev_dbg(dev->net, "%s() speed:%d duplex:%d\n",
drivers/net/usb/ch9200.c
241
netif_carrier_on(dev->net);
drivers/net/usb/ch9200.c
244
netif_carrier_off(dev->net);
drivers/net/usb/ch9200.c
313
netdev_dbg(dev->net, "%s:\n\tusbnet VID:%0x PID:%0x\n", __func__,
drivers/net/usb/ch9200.c
348
dev->mii.dev = dev->net;
drivers/net/usb/ch9200.c
355
dev->hard_mtu = dev->net->mtu + dev->net->hard_header_len;
drivers/net/usb/ch9200.c
391
eth_hw_addr_set(dev->net, addr);
drivers/net/usb/cx82310_eth.c
100
netdev_err(dev->net, "got reply to command %#x, expected: %#x\n",
drivers/net/usb/cx82310_eth.c
106
netdev_err(dev->net, "command %#x failed: %#x\n", cmd,
drivers/net/usb/cx82310_eth.c
125
netdev_err(dev->net, "unable to enable ethernet mode: %d\n",
drivers/net/usb/cx82310_eth.c
166
dev->net->hard_header_len = 0;
drivers/net/usb/cx82310_eth.c
195
netdev_err(dev->net, "firmware not ready in time\n");
drivers/net/usb/cx82310_eth.c
208
netdev_err(dev->net, "unable to read MAC address: %d\n", ret);
drivers/net/usb/cx82310_eth.c
211
eth_hw_addr_set(dev->net, addr);
drivers/net/usb/cx82310_eth.c
283
netdev_info(dev->net, "router was rebooted, re-enabling ethernet mode");
drivers/net/usb/cx82310_eth.c
286
netdev_err(dev->net, "RX packet too long: %d B\n", len);
drivers/net/usb/cx82310_eth.c
74
netdev_err(dev->net, "send command %#x: error %d\n",
drivers/net/usb/cx82310_eth.c
87
netdev_err(dev->net, "reply receive error %d\n",
drivers/net/usb/cx82310_eth.c
95
netdev_err(dev->net, "no reply to command %#x\n", cmd);
drivers/net/usb/dm9601.c
134
netdev_err(dev->net, "%s read timed out!\n", phy ? "phy" : "eeprom");
drivers/net/usb/dm9601.c
142
netdev_dbg(dev->net, "read shared %d 0x%02x returned 0x%04x, %d\n",
drivers/net/usb/dm9601.c
177
netdev_err(dev->net, "%s write timed out!\n", phy ? "phy" : "eeprom");
drivers/net/usb/dm9601.c
201
static int dm9601_get_eeprom(struct net_device *net,
drivers/net/usb/dm9601.c
204
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/dm9601.c
228
netdev_dbg(dev->net, "Only internal phy supported\n");
drivers/net/usb/dm9601.c
234
netdev_err(dev->net, "MDIO read error: %d\n", err);
drivers/net/usb/dm9601.c
238
netdev_dbg(dev->net,
drivers/net/usb/dm9601.c
252
netdev_dbg(dev->net, "Only internal phy supported\n");
drivers/net/usb/dm9601.c
256
netdev_dbg(dev->net, "dm9601_mdio_write() phy_id=0x%02x, loc=0x%02x, val=0x%04x\n",
drivers/net/usb/dm9601.c
274
static void dm9601_set_multicast(struct net_device *net)
drivers/net/usb/dm9601.c
276
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/dm9601.c
285
if (net->flags & IFF_PROMISC) {
drivers/net/usb/dm9601.c
287
} else if (net->flags & IFF_ALLMULTI ||
drivers/net/usb/dm9601.c
288
netdev_mc_count(net) > DM_MAX_MCAST) {
drivers/net/usb/dm9601.c
290
} else if (!netdev_mc_empty(net)) {
drivers/net/usb/dm9601.c
293
netdev_for_each_mc_addr(ha, net) {
drivers/net/usb/dm9601.c
305
dm_write_async(dev, DM_PHY_ADDR, ETH_ALEN, dev->net->dev_addr);
drivers/net/usb/dm9601.c
308
static int dm9601_set_mac_address(struct net_device *net, void *p)
drivers/net/usb/dm9601.c
311
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/dm9601.c
314
dev_err(&net->dev, "not setting invalid mac address %pM\n",
drivers/net/usb/dm9601.c
319
eth_hw_addr_set(net, addr->sa_data);
drivers/net/usb/dm9601.c
347
dev->net->netdev_ops = &dm9601_netdev_ops;
drivers/net/usb/dm9601.c
348
dev->net->ethtool_ops = &dm9601_ethtool_ops;
drivers/net/usb/dm9601.c
349
dev->net->hard_header_len += DM_TX_OVERHEAD;
drivers/net/usb/dm9601.c
350
dev->hard_mtu = dev->net->mtu + dev->net->hard_header_len;
drivers/net/usb/dm9601.c
356
dev->rx_urb_size = dev->net->mtu + ETH_HLEN + DM_RX_OVERHEAD + 1;
drivers/net/usb/dm9601.c
358
dev->mii.dev = dev->net;
drivers/net/usb/dm9601.c
379
eth_hw_addr_set(dev->net, mac);
drivers/net/usb/dm9601.c
383
dev->net->dev_addr);
drivers/net/usb/dm9601.c
388
netdev_err(dev->net, "Error reading chip ID\n");
drivers/net/usb/dm9601.c
398
netdev_err(dev->net, "Error reading MODE_CTRL\n");
drivers/net/usb/dm9601.c
410
dm9601_set_multicast(dev->net);
drivers/net/usb/dm9601.c
412
dm9601_mdio_write(dev->net, dev->mii.phy_id, MII_BMCR, BMCR_RESET);
drivers/net/usb/dm9601.c
413
dm9601_mdio_write(dev->net, dev->mii.phy_id, MII_ADVERTISE,
drivers/net/usb/dm9601.c
443
if (status & 0x01) dev->net->stats.rx_fifo_errors++;
drivers/net/usb/dm9601.c
444
if (status & 0x02) dev->net->stats.rx_crc_errors++;
drivers/net/usb/dm9601.c
445
if (status & 0x04) dev->net->stats.rx_frame_errors++;
drivers/net/usb/dm9601.c
446
if (status & 0x20) dev->net->stats.rx_missed_errors++;
drivers/net/usb/dm9601.c
447
if (status & 0x90) dev->net->stats.rx_length_errors++;
drivers/net/usb/dm9601.c
526
if (netif_carrier_ok(dev->net) != link) {
drivers/net/usb/dm9601.c
528
netdev_dbg(dev->net, "Link Status is: %d\n", link);
drivers/net/usb/dm9601.c
539
netdev_dbg(dev->net, "link_reset() speed: %u duplex: %d\n",
drivers/net/usb/gl620a.c
102
netdev_dbg(dev->net, "genelink: invalid rx length %d\n",
drivers/net/usb/gl620a.c
128
netdev_dbg(dev->net, "genelink: invalid rx length %d\n",
drivers/net/usb/gl620a.c
181
dev->net->hard_header_len += 4;
drivers/net/usb/gl620a.c
76
if (skb->len < dev->net->hard_header_len)
drivers/net/usb/gl620a.c
84
netdev_dbg(dev->net,
drivers/net/usb/hso.c
1000
if (!netif_device_present(net)) {
drivers/net/usb/hso.c
130
struct net_device *net;
drivers/net/usb/hso.c
2070
sprintf(port_dev, "%s", dev2net(hso_dev)->net->name);
drivers/net/usb/hso.c
2357
if (hso_net->net)
drivers/net/usb/hso.c
2358
unregister_netdev(hso_net->net);
drivers/net/usb/hso.c
2370
if (hso_net->net)
drivers/net/usb/hso.c
2371
free_netdev(hso_net->net);
drivers/net/usb/hso.c
2384
static void hso_net_init(struct net_device *net)
drivers/net/usb/hso.c
2386
struct hso_net *hso_net = netdev_priv(net);
drivers/net/usb/hso.c
2391
net->netdev_ops = &hso_netdev_ops;
drivers/net/usb/hso.c
2392
net->watchdog_timeo = HSO_NET_TX_TIMEOUT;
drivers/net/usb/hso.c
2393
net->flags = IFF_POINTOPOINT | IFF_NOARP | IFF_MULTICAST;
drivers/net/usb/hso.c
2394
net->type = ARPHRD_NONE;
drivers/net/usb/hso.c
2395
net->mtu = DEFAULT_MTU - 14;
drivers/net/usb/hso.c
2396
net->tx_queue_len = 10;
drivers/net/usb/hso.c
2397
net->ethtool_ops = &ops;
drivers/net/usb/hso.c
2445
struct device *dev = &hso_net->net->dev;
drivers/net/usb/hso.c
2475
struct net_device *net;
drivers/net/usb/hso.c
2485
net = alloc_netdev(sizeof(struct hso_net), "hso%d", NET_NAME_UNKNOWN,
drivers/net/usb/hso.c
2487
if (!net) {
drivers/net/usb/hso.c
2492
hso_net = netdev_priv(net);
drivers/net/usb/hso.c
2495
hso_net->net = net;
drivers/net/usb/hso.c
2505
SET_NETDEV_DEV(net, &interface->dev);
drivers/net/usb/hso.c
2506
SET_NETDEV_DEVTYPE(net, &hso_type);
drivers/net/usb/hso.c
2532
result = register_netdev(net);
drivers/net/usb/hso.c
2556
free_netdev(net);
drivers/net/usb/hso.c
3062
hso_net->net);
drivers/net/usb/hso.c
3109
netif_stop_queue(dev2net(network_table[i])->net);
drivers/net/usb/hso.c
690
static int hso_net_open(struct net_device *net)
drivers/net/usb/hso.c
692
struct hso_net *odev = netdev_priv(net);
drivers/net/usb/hso.c
696
dev_err(&net->dev, "No net device !\n");
drivers/net/usb/hso.c
714
netif_start_queue(net);
drivers/net/usb/hso.c
720
static int hso_net_close(struct net_device *net)
drivers/net/usb/hso.c
722
struct hso_net *odev = netdev_priv(net);
drivers/net/usb/hso.c
725
netif_stop_queue(net);
drivers/net/usb/hso.c
748
if (!netif_device_present(odev->net)) {
drivers/net/usb/hso.c
762
netif_wake_queue(odev->net);
drivers/net/usb/hso.c
767
struct net_device *net)
drivers/net/usb/hso.c
769
struct hso_net *odev = netdev_priv(net);
drivers/net/usb/hso.c
773
netif_stop_queue(net);
drivers/net/usb/hso.c
802
net->stats.tx_errors++;
drivers/net/usb/hso.c
803
netif_start_queue(net);
drivers/net/usb/hso.c
805
net->stats.tx_packets++;
drivers/net/usb/hso.c
806
net->stats.tx_bytes += skb->len;
drivers/net/usb/hso.c
818
static void hso_net_tx_timeout(struct net_device *net, unsigned int txqueue)
drivers/net/usb/hso.c
820
struct hso_net *odev = netdev_priv(net);
drivers/net/usb/hso.c
826
dev_warn(&net->dev, "Tx timed out.\n");
drivers/net/usb/hso.c
833
net->stats.tx_errors++;
drivers/net/usb/hso.c
874
dev_err(&odev->net->dev,
drivers/net/usb/hso.c
881
odev->skb_rx_buf = netdev_alloc_skb(odev->net,
drivers/net/usb/hso.c
933
odev->net->stats.rx_packets++;
drivers/net/usb/hso.c
935
odev->net->stats.rx_bytes += odev->rx_buf_size;
drivers/net/usb/hso.c
980
struct net_device *net;
drivers/net/usb/hso.c
998
net = odev->net;
drivers/net/usb/int51x1.c
115
dev->net->hard_header_len += INT51X1_HEADER_SIZE;
drivers/net/usb/int51x1.c
116
dev->hard_mtu = dev->net->mtu + dev->net->hard_header_len;
drivers/net/usb/int51x1.c
117
dev->net->netdev_ops = &int51x1_netdev_ops;
drivers/net/usb/int51x1.c
32
netdev_err(dev->net, "unexpected tiny rx frame\n");
drivers/net/usb/ipheth.c
107
struct net_device *net;
drivers/net/usb/ipheth.c
188
dev->net->stats.rx_dropped++;
drivers/net/usb/ipheth.c
193
skb->dev = dev->net;
drivers/net/usb/ipheth.c
194
skb->protocol = eth_type_trans(skb, dev->net);
drivers/net/usb/ipheth.c
196
dev->net->stats.rx_packets++;
drivers/net/usb/ipheth.c
197
dev->net->stats.rx_bytes += len;
drivers/net/usb/ipheth.c
212
dev->net->stats.rx_length_errors++;
drivers/net/usb/ipheth.c
242
dev->net->stats.rx_length_errors++;
drivers/net/usb/ipheth.c
270
dev->net->stats.rx_length_errors++;
drivers/net/usb/ipheth.c
282
dev->net->stats.rx_errors++;
drivers/net/usb/ipheth.c
356
netif_wake_queue(dev->net);
drivers/net/usb/ipheth.c
387
netif_carrier_on(dev->net);
drivers/net/usb/ipheth.c
389
netif_wake_queue(dev->net);
drivers/net/usb/ipheth.c
391
netif_carrier_off(dev->net);
drivers/net/usb/ipheth.c
392
netif_stop_queue(dev->net);
drivers/net/usb/ipheth.c
409
struct net_device *net = dev->net;
drivers/net/usb/ipheth.c
430
eth_hw_addr_set(net, dev->ctrl_buf);
drivers/net/usb/ipheth.c
477
static int ipheth_open(struct net_device *net)
drivers/net/usb/ipheth.c
479
struct ipheth_device *dev = netdev_priv(net);
drivers/net/usb/ipheth.c
497
static int ipheth_close(struct net_device *net)
drivers/net/usb/ipheth.c
499
struct ipheth_device *dev = netdev_priv(net);
drivers/net/usb/ipheth.c
501
netif_stop_queue(net);
drivers/net/usb/ipheth.c
506
static netdev_tx_t ipheth_tx(struct sk_buff *skb, struct net_device *net)
drivers/net/usb/ipheth.c
508
struct ipheth_device *dev = netdev_priv(net);
drivers/net/usb/ipheth.c
515
dev->net->stats.tx_dropped++;
drivers/net/usb/ipheth.c
529
netif_stop_queue(net);
drivers/net/usb/ipheth.c
534
dev->net->stats.tx_errors++;
drivers/net/usb/ipheth.c
536
netif_wake_queue(net);
drivers/net/usb/ipheth.c
538
dev->net->stats.tx_packets++;
drivers/net/usb/ipheth.c
539
dev->net->stats.tx_bytes += skb->len;
drivers/net/usb/ipheth.c
546
static void ipheth_tx_timeout(struct net_device *net, unsigned int txqueue)
drivers/net/usb/ipheth.c
548
struct ipheth_device *dev = netdev_priv(net);
drivers/net/usb/ipheth.c
551
dev->net->stats.tx_errors++;
drivers/net/usb/ipheth.c
555
static u32 ipheth_ethtool_op_get_link(struct net_device *net)
drivers/net/usb/ipheth.c
557
struct ipheth_device *dev = netdev_priv(net);
drivers/net/usb/ipheth.c
558
return netif_carrier_ok(dev->net);
drivers/net/usb/ipheth.c
592
dev->net = netdev;
drivers/net/usb/ipheth.c
673
unregister_netdev(dev->net);
drivers/net/usb/ipheth.c
677
free_netdev(dev->net);
drivers/net/usb/kalmia.c
151
dev->net->hard_header_len += KALMIA_HEADER_LENGTH;
drivers/net/usb/kalmia.c
159
eth_hw_addr_set(dev->net, ethernet_addr);
drivers/net/usb/kalmia.c
203
netdev_dbg(dev->net, "Sending etherType: %02x%02x", ether_type_1,
drivers/net/usb/kalmia.c
222
netdev_dbg(dev->net,
drivers/net/usb/kalmia.c
261
netdev_dbg(dev->net,
drivers/net/usb/kalmia.c
267
netdev_err(dev->net,
drivers/net/usb/kalmia.c
275
netdev_dbg(dev->net,
drivers/net/usb/kalmia.c
299
netdev_dbg(dev->net, "Correct package length #%i", i
drivers/net/usb/kalmia.c
307
netdev_dbg(dev->net,
drivers/net/usb/kalmia.c
62
netdev_dbg(dev->net, "Sending init packet");
drivers/net/usb/kalmia.c
67
netdev_err(dev->net,
drivers/net/usb/kalmia.c
73
netdev_err(dev->net,
drivers/net/usb/kalmia.c
78
netdev_dbg(dev->net, "Successfully sent init packet.");
drivers/net/usb/kalmia.c
85
netdev_err(dev->net,
drivers/net/usb/kalmia.c
89
netdev_err(dev->net, "Unexpected init result length: %i\n",
drivers/net/usb/kaweth.c
1076
kaweth->net->name);
drivers/net/usb/kaweth.c
1110
netdev = kaweth->net;
drivers/net/usb/kaweth.c
1112
netdev_dbg(kaweth->net, "Unregistering net device\n");
drivers/net/usb/kaweth.c
212
struct net_device *net;
drivers/net/usb/kaweth.c
253
netdev_dbg(kaweth->net, "Setting URB size to %d\n", (unsigned)urb_size);
drivers/net/usb/kaweth.c
268
netdev_dbg(kaweth->net, "Set SOFS wait to %d\n", (unsigned)sofs_wait);
drivers/net/usb/kaweth.c
284
netdev_dbg(kaweth->net, "Set receive filter to %d\n",
drivers/net/usb/kaweth.c
329
netdev_dbg(kaweth->net, "High: %i, Low:%i\n", kaweth->firmware_buf[3],
drivers/net/usb/kaweth.c
332
netdev_dbg(kaweth->net,
drivers/net/usb/kaweth.c
335
netdev_dbg(kaweth->net, "Firmware length: %d\n", data_len);
drivers/net/usb/kaweth.c
378
netdev_dbg(kaweth->net, "kaweth_reset() returns %d.\n", result);
drivers/net/usb/kaweth.c
430
netif_carrier_on(kaweth->net);
drivers/net/usb/kaweth.c
432
netif_carrier_off(kaweth->net);
drivers/net/usb/kaweth.c
498
struct net_device *net = kaweth->net;
drivers/net/usb/kaweth.c
509
net->stats.rx_errors++;
drivers/net/usb/kaweth.c
524
net->stats.rx_errors++;
drivers/net/usb/kaweth.c
529
net->stats.rx_errors++;
drivers/net/usb/kaweth.c
542
net->name, status, count, (int)pkt_len);
drivers/net/usb/kaweth.c
547
if(kaweth->net && (count > 2)) {
drivers/net/usb/kaweth.c
570
skb->protocol = eth_type_trans(skb, net);
drivers/net/usb/kaweth.c
574
net->stats.rx_packets++;
drivers/net/usb/kaweth.c
575
net->stats.rx_bytes += pkt_len;
drivers/net/usb/kaweth.c
584
static int kaweth_open(struct net_device *net)
drivers/net/usb/kaweth.c
586
struct kaweth_device *kaweth = netdev_priv(net);
drivers/net/usb/kaweth.c
617
netif_start_queue(net);
drivers/net/usb/kaweth.c
647
static int kaweth_close(struct net_device *net)
drivers/net/usb/kaweth.c
649
struct kaweth_device *kaweth = netdev_priv(net);
drivers/net/usb/kaweth.c
651
netif_stop_queue(net);
drivers/net/usb/kaweth.c
688
kaweth->net->name, status);
drivers/net/usb/kaweth.c
690
netif_wake_queue(kaweth->net);
drivers/net/usb/kaweth.c
698
struct net_device *net)
drivers/net/usb/kaweth.c
700
struct kaweth_device *kaweth = netdev_priv(net);
drivers/net/usb/kaweth.c
708
netif_stop_queue(net);
drivers/net/usb/kaweth.c
715
net->stats.tx_errors++;
drivers/net/usb/kaweth.c
716
netif_start_queue(net);
drivers/net/usb/kaweth.c
737
dev_warn(&net->dev, "kaweth failed tx_urb %d\n", res);
drivers/net/usb/kaweth.c
739
net->stats.tx_errors++;
drivers/net/usb/kaweth.c
741
netif_start_queue(net);
drivers/net/usb/kaweth.c
746
net->stats.tx_packets++;
drivers/net/usb/kaweth.c
747
net->stats.tx_bytes += skb->len;
drivers/net/usb/kaweth.c
758
static void kaweth_set_rx_mode(struct net_device *net)
drivers/net/usb/kaweth.c
760
struct kaweth_device *kaweth = netdev_priv(net);
drivers/net/usb/kaweth.c
766
netdev_dbg(net, "Setting Rx mode to %d\n", packet_filter_bitmap);
drivers/net/usb/kaweth.c
769
if (net->flags & IFF_PROMISC) {
drivers/net/usb/kaweth.c
772
else if (!netdev_mc_empty(net) || (net->flags & IFF_ALLMULTI)) {
drivers/net/usb/kaweth.c
805
netdev_dbg(kaweth->net, "Set Rx mode to %d\n",
drivers/net/usb/kaweth.c
812
static void kaweth_tx_timeout(struct net_device *net, unsigned int txqueue)
drivers/net/usb/kaweth.c
814
struct kaweth_device *kaweth = netdev_priv(net);
drivers/net/usb/kaweth.c
816
dev_warn(&net->dev, "%s: Tx timed out. Resetting.\n", net->name);
drivers/net/usb/kaweth.c
817
net->stats.tx_errors++;
drivers/net/usb/kaweth.c
818
netif_trans_update(net);
drivers/net/usb/kaweth.c
918
kaweth->net = netdev;
drivers/net/usb/lan78xx.c
1003
netdev_warn(dev->net, "EEPROM read operation timeout");
drivers/net/usb/lan78xx.c
1027
netdev_warn(dev->net, "EEPROM is busy");
drivers/net/usb/lan78xx.c
1212
netdev_warn(dev->net,
drivers/net/usb/lan78xx.c
1246
netdev_warn(dev->net,
drivers/net/usb/lan78xx.c
1288
netdev_warn(dev->net,
drivers/net/usb/lan78xx.c
1331
netdev_warn(dev->net,
drivers/net/usb/lan78xx.c
1378
netdev_warn(dev->net, "%s timed out", __func__);
drivers/net/usb/lan78xx.c
1423
netdev_warn(dev->net, "dataport write failed %pe", ERR_PTR(ret));
drivers/net/usb/lan78xx.c
1471
netif_dbg(dev, drv, dev->net, "deferred multicast write 0x%08x\n",
drivers/net/usb/lan78xx.c
1498
netdev_warn(dev->net, "multicast write failed %pe", ERR_PTR(ret));
drivers/net/usb/lan78xx.c
1536
if (dev->net->flags & IFF_PROMISC) {
drivers/net/usb/lan78xx.c
1537
netif_dbg(dev, drv, dev->net, "promiscuous mode enabled");
drivers/net/usb/lan78xx.c
1540
if (dev->net->flags & IFF_ALLMULTI) {
drivers/net/usb/lan78xx.c
1541
netif_dbg(dev, drv, dev->net,
drivers/net/usb/lan78xx.c
1547
lan78xx_update_vlan_filter(pdata, dev->net, dev->net->features);
drivers/net/usb/lan78xx.c
1549
if (netdev_mc_count(dev->net)) {
drivers/net/usb/lan78xx.c
1553
netif_dbg(dev, drv, dev->net, "receive multicast hash filter");
drivers/net/usb/lan78xx.c
1651
netdev_err(dev->net, "kevent %d may have been dropped\n", work);
drivers/net/usb/lan78xx.c
1659
netdev_warn(dev->net,
drivers/net/usb/lan78xx.c
1667
netif_dbg(dev, link, dev->net, "PHY INTR: 0x%08x\n", intdata);
drivers/net/usb/lan78xx.c
1673
netdev_warn(dev->net,
drivers/net/usb/lan78xx.c
1772
netdev_warn(dev->net, "failed to get WoL %pe", ERR_PTR(ret));
drivers/net/usb/lan78xx.c
1816
static int lan78xx_get_eee(struct net_device *net, struct ethtool_keee *edata)
drivers/net/usb/lan78xx.c
1818
struct lan78xx_net *dev = netdev_priv(net);
drivers/net/usb/lan78xx.c
1823
static int lan78xx_set_eee(struct net_device *net, struct ethtool_keee *edata)
drivers/net/usb/lan78xx.c
1825
struct lan78xx_net *dev = netdev_priv(net);
drivers/net/usb/lan78xx.c
1830
static void lan78xx_get_drvinfo(struct net_device *net,
drivers/net/usb/lan78xx.c
1833
struct lan78xx_net *dev = netdev_priv(net);
drivers/net/usb/lan78xx.c
1839
static u32 lan78xx_get_msglevel(struct net_device *net)
drivers/net/usb/lan78xx.c
1841
struct lan78xx_net *dev = netdev_priv(net);
drivers/net/usb/lan78xx.c
1846
static void lan78xx_set_msglevel(struct net_device *net, u32 level)
drivers/net/usb/lan78xx.c
1848
struct lan78xx_net *dev = netdev_priv(net);
drivers/net/usb/lan78xx.c
1853
static int lan78xx_get_link_ksettings(struct net_device *net,
drivers/net/usb/lan78xx.c
1856
struct lan78xx_net *dev = netdev_priv(net);
drivers/net/usb/lan78xx.c
1861
static int lan78xx_set_link_ksettings(struct net_device *net,
drivers/net/usb/lan78xx.c
1864
struct lan78xx_net *dev = netdev_priv(net);
drivers/net/usb/lan78xx.c
1869
static void lan78xx_get_pause(struct net_device *net,
drivers/net/usb/lan78xx.c
1872
struct lan78xx_net *dev = netdev_priv(net);
drivers/net/usb/lan78xx.c
1877
static int lan78xx_set_pause(struct net_device *net,
drivers/net/usb/lan78xx.c
1880
struct lan78xx_net *dev = netdev_priv(net);
drivers/net/usb/lan78xx.c
1903
netdev_warn(dev->net,
drivers/net/usb/lan78xx.c
1968
netif_dbg(dev, ifup, dev->net,
drivers/net/usb/lan78xx.c
1976
netif_dbg(dev, ifup, dev->net,
drivers/net/usb/lan78xx.c
1981
netif_dbg(dev, ifup, dev->net,
drivers/net/usb/lan78xx.c
2006
eth_hw_addr_set(dev->net, addr);
drivers/net/usb/lan78xx.c
2098
netdev_err(dev->net, "can't allocate MDIO bus\n");
drivers/net/usb/lan78xx.c
2125
netdev_err(dev->net, "can't register MDIO bus\n");
drivers/net/usb/lan78xx.c
2129
netdev_dbg(dev->net, "registered mdiobus bus %s\n", dev->mdiobus->id);
drivers/net/usb/lan78xx.c
2206
netdev_err(dev->net, "Failed to sync IRQ enable register: %pe\n",
drivers/net/usb/lan78xx.c
2274
struct net_device *net = to_net_dev(config->dev);
drivers/net/usb/lan78xx.c
2275
struct lan78xx_net *dev = netdev_priv(net);
drivers/net/usb/lan78xx.c
2281
netdev_err(net, "Unsupported negotiation mode: %u\n", mode);
drivers/net/usb/lan78xx.c
2295
netdev_warn(net, "Unsupported interface mode: %d\n",
drivers/net/usb/lan78xx.c
2302
netdev_err(net, "Failed to config MAC with error %pe\n",
drivers/net/usb/lan78xx.c
2309
struct net_device *net = to_net_dev(config->dev);
drivers/net/usb/lan78xx.c
2310
struct lan78xx_net *dev = netdev_priv(net);
drivers/net/usb/lan78xx.c
2313
netif_stop_queue(net);
drivers/net/usb/lan78xx.c
2338
netdev_err(dev->net, "Failed to set MAC down with error %pe\n",
drivers/net/usb/lan78xx.c
2367
netdev_warn_once(dev->net, "Unexpected SuperSpeed for LAN7850 (USB 2.0 only)\n");
drivers/net/usb/lan78xx.c
2391
netdev_warn(dev->net, "Unsupported link speed: %d\n", speed);
drivers/net/usb/lan78xx.c
2463
netdev_warn(dev->net, "Unsupported USB speed: %d\n",
drivers/net/usb/lan78xx.c
2483
struct net_device *net = to_net_dev(config->dev);
drivers/net/usb/lan78xx.c
2484
struct lan78xx_net *dev = netdev_priv(net);
drivers/net/usb/lan78xx.c
2499
netdev_err(dev->net, "Unsupported speed %d\n", speed);
drivers/net/usb/lan78xx.c
2549
netif_start_queue(net);
drivers/net/usb/lan78xx.c
2554
netdev_err(dev->net, "Failed to set MAC up with error %pe\n",
drivers/net/usb/lan78xx.c
2583
struct net_device *net = to_net_dev(config->dev);
drivers/net/usb/lan78xx.c
2584
struct lan78xx_net *dev = netdev_priv(net);
drivers/net/usb/lan78xx.c
2592
struct net_device *net = to_net_dev(config->dev);
drivers/net/usb/lan78xx.c
2593
struct lan78xx_net *dev = netdev_priv(net);
drivers/net/usb/lan78xx.c
2633
netdev_info(dev->net,
drivers/net/usb/lan78xx.c
2664
netdev_warn(dev->net,
drivers/net/usb/lan78xx.c
2685
netdev_err(dev->net, "Unknown CHIP ID: 0x%08x\n", dev->chipid);
drivers/net/usb/lan78xx.c
2748
netdev_warn(dev->net, "Unsupported interface mode: %d\n",
drivers/net/usb/lan78xx.c
2804
pc->dev = &dev->net->dev;
drivers/net/usb/lan78xx.c
2839
phylink = phylink_create(pc, dev->net->dev.fwnode,
drivers/net/usb/lan78xx.c
2900
netdev_dbg(dev->net, "phydev->irq = %d\n", phydev->irq);
drivers/net/usb/lan78xx.c
2904
netdev_err(dev->net, "can't attach PHY to %s, error %pe\n",
drivers/net/usb/lan78xx.c
2993
netdev_dbg(dev->net, "unlink urb err, %d\n", ret);
drivers/net/usb/lan78xx.c
3019
netdev_err(dev->net, "MTU changed to %d from %d failed with %pe\n",
drivers/net/usb/lan78xx.c
3216
netdev_err(dev->net, "Failed to init LTM with error %pe\n", ERR_PTR(ret));
drivers/net/usb/lan78xx.c
3250
netdev_warn(dev->net, "USB bus speed not supported\n");
drivers/net/usb/lan78xx.c
3283
netdev_warn(dev->net,
drivers/net/usb/lan78xx.c
3385
ret = lan78xx_set_features(dev->net, dev->net->features);
drivers/net/usb/lan78xx.c
3389
lan78xx_set_multicast(dev->net);
drivers/net/usb/lan78xx.c
3410
netdev_warn(dev->net, "timeout waiting for PHY Reset");
drivers/net/usb/lan78xx.c
3431
RX_MAX_FRAME_LEN(dev->net->mtu));
drivers/net/usb/lan78xx.c
3462
static int lan78xx_open(struct net_device *net)
drivers/net/usb/lan78xx.c
3464
struct lan78xx_net *dev = netdev_priv(net);
drivers/net/usb/lan78xx.c
3467
netif_dbg(dev, ifup, dev->net, "open device");
drivers/net/usb/lan78xx.c
3485
netif_err(dev, ifup, dev->net,
drivers/net/usb/lan78xx.c
3519
netif_dbg(dev, ifdown, dev->net,
drivers/net/usb/lan78xx.c
3538
static int lan78xx_stop(struct net_device *net)
drivers/net/usb/lan78xx.c
3540
struct lan78xx_net *dev = netdev_priv(net);
drivers/net/usb/lan78xx.c
3542
netif_dbg(dev, ifup, dev->net, "stop device");
drivers/net/usb/lan78xx.c
3554
netif_info(dev, ifdown, dev->net,
drivers/net/usb/lan78xx.c
3556
net->stats.rx_packets, net->stats.tx_packets,
drivers/net/usb/lan78xx.c
3557
net->stats.rx_errors, net->stats.tx_errors);
drivers/net/usb/lan78xx.c
3612
dev->net->stats.tx_packets += entry->num_of_packet;
drivers/net/usb/lan78xx.c
3613
dev->net->stats.tx_bytes += entry->length;
drivers/net/usb/lan78xx.c
3615
dev->net->stats.tx_errors += entry->num_of_packet;
drivers/net/usb/lan78xx.c
3625
netif_dbg(dev, tx_err, dev->net,
drivers/net/usb/lan78xx.c
3633
netif_stop_queue(dev->net);
drivers/net/usb/lan78xx.c
3634
netif_dbg(dev, tx_err, dev->net,
drivers/net/usb/lan78xx.c
3639
netif_dbg(dev, tx_err, dev->net,
drivers/net/usb/lan78xx.c
3727
lan78xx_start_xmit(struct sk_buff *skb, struct net_device *net)
drivers/net/usb/lan78xx.c
3729
struct lan78xx_net *dev = netdev_priv(net);
drivers/net/usb/lan78xx.c
3748
netif_stop_queue(net);
drivers/net/usb/lan78xx.c
3750
netif_dbg(dev, hw, dev->net, "tx data len: %u, urb space %u",
drivers/net/usb/lan78xx.c
3772
netdev_warn(dev->net, "Unable to allocate lan78xx_priv");
drivers/net/usb/lan78xx.c
3788
dev->net->features = 0;
drivers/net/usb/lan78xx.c
3791
dev->net->features |= NETIF_F_HW_CSUM;
drivers/net/usb/lan78xx.c
3794
dev->net->features |= NETIF_F_RXCSUM;
drivers/net/usb/lan78xx.c
3797
dev->net->features |= NETIF_F_TSO | NETIF_F_TSO6 | NETIF_F_SG;
drivers/net/usb/lan78xx.c
3800
dev->net->features |= NETIF_F_HW_VLAN_CTAG_RX;
drivers/net/usb/lan78xx.c
3803
dev->net->features |= NETIF_F_HW_VLAN_CTAG_FILTER;
drivers/net/usb/lan78xx.c
3805
dev->net->hw_features = dev->net->features;
drivers/net/usb/lan78xx.c
3809
netdev_warn(dev->net,
drivers/net/usb/lan78xx.c
3817
netdev_warn(dev->net, "Registers INIT FAILED....");
drivers/net/usb/lan78xx.c
3823
netdev_warn(dev->net, "MDIO INIT FAILED.....");
drivers/net/usb/lan78xx.c
3827
dev->net->flags |= IFF_MULTICAST;
drivers/net/usb/lan78xx.c
3837
netdev_warn(dev->net, "Bind routine FAILED");
drivers/net/usb/lan78xx.c
3855
netif_dbg(dev, ifdown, dev->net, "free pdata");
drivers/net/usb/lan78xx.c
3869
if (!(dev->net->features & NETIF_F_RXCSUM) ||
drivers/net/usb/lan78xx.c
3873
!(dev->net->features & NETIF_F_HW_VLAN_CTAG_RX))) {
drivers/net/usb/lan78xx.c
3885
if ((dev->net->features & NETIF_F_HW_VLAN_CTAG_RX) &&
drivers/net/usb/lan78xx.c
3893
dev->net->stats.rx_packets++;
drivers/net/usb/lan78xx.c
3894
dev->net->stats.rx_bytes += skb->len;
drivers/net/usb/lan78xx.c
3896
skb->protocol = eth_type_trans(skb, dev->net);
drivers/net/usb/lan78xx.c
3898
netif_dbg(dev, rx_status, dev->net, "< rx, len %zu, type 0x%x\n",
drivers/net/usb/lan78xx.c
3938
netif_dbg(dev, rx_err, dev->net,
drivers/net/usb/lan78xx.c
3946
netif_dbg(dev, rx_err, dev->net,
drivers/net/usb/lan78xx.c
3953
netif_dbg(dev, rx_err, dev->net,
drivers/net/usb/lan78xx.c
3999
netif_dbg(dev, rx_err, dev->net, "drop\n");
drivers/net/usb/lan78xx.c
4000
dev->net->stats.rx_errors++;
drivers/net/usb/lan78xx.c
4012
netif_dbg(dev, rx_status, dev->net,
drivers/net/usb/lan78xx.c
4019
netif_warn(dev, rx_err, dev->net, "URB pointer mismatch");
drivers/net/usb/lan78xx.c
4025
dev->net->stats.rx_errors++;
drivers/net/usb/lan78xx.c
4026
dev->net->stats.rx_length_errors++;
drivers/net/usb/lan78xx.c
4027
netif_dbg(dev, rx_err, dev->net,
drivers/net/usb/lan78xx.c
4033
dev->net->stats.rx_errors++;
drivers/net/usb/lan78xx.c
4038
netif_dbg(dev, ifdown, dev->net,
drivers/net/usb/lan78xx.c
4045
dev->net->stats.rx_errors++;
drivers/net/usb/lan78xx.c
4051
dev->net->stats.rx_over_errors++;
drivers/net/usb/lan78xx.c
4056
dev->net->stats.rx_errors++;
drivers/net/usb/lan78xx.c
4057
netif_dbg(dev, rx_err, dev->net, "rx status %d\n", urb_status);
drivers/net/usb/lan78xx.c
4077
if (netif_device_present(dev->net) &&
drivers/net/usb/lan78xx.c
4078
netif_running(dev->net) &&
drivers/net/usb/lan78xx.c
4091
netif_dbg(dev, ifdown, dev->net, "device gone\n");
drivers/net/usb/lan78xx.c
4092
netif_device_detach(dev->net);
drivers/net/usb/lan78xx.c
4099
netif_dbg(dev, rx_err, dev->net,
drivers/net/usb/lan78xx.c
4105
netif_dbg(dev, ifdown, dev->net, "rx: stopped\n");
drivers/net/usb/lan78xx.c
414
struct net_device *net;
drivers/net/usb/lan78xx.c
4211
struct net_device_stats *stats = &dev->net->stats;
drivers/net/usb/lan78xx.c
4241
netif_tx_lock(dev->net);
drivers/net/usb/lan78xx.c
4242
if (netif_queue_stopped(dev->net)) {
drivers/net/usb/lan78xx.c
4244
netif_wake_queue(dev->net);
drivers/net/usb/lan78xx.c
4246
netif_tx_unlock(dev->net);
drivers/net/usb/lan78xx.c
4286
netif_stop_queue(dev->net);
drivers/net/usb/lan78xx.c
4288
netdev_dbg(dev->net,
drivers/net/usb/lan78xx.c
4296
netif_trans_update(dev->net);
drivers/net/usb/lan78xx.c
4300
netif_stop_queue(dev->net);
drivers/net/usb/lan78xx.c
4306
netif_dbg(dev, tx_err, dev->net,
drivers/net/usb/lan78xx.c
4308
netif_device_detach(dev->net);
drivers/net/usb/lan78xx.c
4312
netif_dbg(dev, tx_err, dev->net,
drivers/net/usb/lan78xx.c
4320
netdev_warn(dev->net, "failed to tx urb %d\n", ret);
drivers/net/usb/lan78xx.c
4322
dev->net->stats.tx_dropped += entry->num_of_packet;
drivers/net/usb/lan78xx.c
4367
netdev_dbg(dev->net, "rx buf state %d\n",
drivers/net/usb/lan78xx.c
4383
if (netif_device_present(dev->net) && netif_running(dev->net)) {
drivers/net/usb/lan78xx.c
4429
} else if (netif_carrier_ok(dev->net)) {
drivers/net/usb/lan78xx.c
4434
netif_tx_lock(dev->net);
drivers/net/usb/lan78xx.c
4435
if (netif_queue_stopped(dev->net)) {
drivers/net/usb/lan78xx.c
4436
netif_wake_queue(dev->net);
drivers/net/usb/lan78xx.c
4439
netif_tx_unlock(dev->net);
drivers/net/usb/lan78xx.c
4469
netdev_err(dev->net,
drivers/net/usb/lan78xx.c
4475
netif_wake_queue(dev->net);
drivers/net/usb/lan78xx.c
4486
netdev_err(dev->net,
drivers/net/usb/lan78xx.c
4501
netdev_info(dev->net, "PHY INT ack failed (%pe)\n",
drivers/net/usb/lan78xx.c
4534
netif_dbg(dev, ifdown, dev->net,
drivers/net/usb/lan78xx.c
4542
netdev_dbg(dev->net, "intr status %d\n", status);
drivers/net/usb/lan78xx.c
4546
if (!netif_device_present(dev->net) ||
drivers/net/usb/lan78xx.c
4547
!netif_running(dev->net)) {
drivers/net/usb/lan78xx.c
4548
netdev_warn(dev->net, "not submitting new status URB");
drivers/net/usb/lan78xx.c
4560
netif_dbg(dev, timer, dev->net,
drivers/net/usb/lan78xx.c
4562
netif_device_detach(dev->net);
drivers/net/usb/lan78xx.c
4565
netif_err(dev, timer, dev->net,
drivers/net/usb/lan78xx.c
4574
struct net_device *net;
drivers/net/usb/lan78xx.c
4581
net = dev->net;
drivers/net/usb/lan78xx.c
4588
unregister_netdev(net);
drivers/net/usb/lan78xx.c
4606
free_netdev(net);
drivers/net/usb/lan78xx.c
4609
static void lan78xx_tx_timeout(struct net_device *net, unsigned int txqueue)
drivers/net/usb/lan78xx.c
4611
struct lan78xx_net *dev = netdev_priv(net);
drivers/net/usb/lan78xx.c
4680
dev->net = netdev;
drivers/net/usb/lan78xx.c
5123
netif_dbg(dev, ifdown, dev->net,
drivers/net/usb/lan78xx.c
5161
netif_device_detach(dev->net);
drivers/net/usb/lan78xx.c
5166
netif_device_attach(dev->net);
drivers/net/usb/lan78xx.c
5178
netif_carrier_off(dev->net);
drivers/net/usb/lan78xx.c
5238
if (!netif_device_present(dev->net) ||
drivers/net/usb/lan78xx.c
5239
!netif_carrier_ok(dev->net) ||
drivers/net/usb/lan78xx.c
5248
netif_trans_update(dev->net);
drivers/net/usb/lan78xx.c
5252
netif_stop_queue(dev->net);
drivers/net/usb/lan78xx.c
5255
netif_device_detach(dev->net);
drivers/net/usb/lan78xx.c
5273
netif_dbg(dev, ifup, dev->net, "resuming device");
drivers/net/usb/lan78xx.c
5289
netif_device_detach(dev->net);
drivers/net/usb/lan78xx.c
5290
netdev_warn(dev->net, "Failed to submit intr URB");
drivers/net/usb/lan78xx.c
5296
if (netif_device_present(dev->net)) {
drivers/net/usb/lan78xx.c
5308
netif_device_present(dev->net) &&
drivers/net/usb/lan78xx.c
5310
netif_start_queue(dev->net);
drivers/net/usb/lan78xx.c
5367
netif_dbg(dev, ifup, dev->net, "(reset) resuming device");
drivers/net/usb/lan78xx.c
619
netdev_warn(dev->net,
drivers/net/usb/lan78xx.c
650
netdev_warn(dev->net,
drivers/net/usb/lan78xx.c
706
netdev_warn(dev->net,
drivers/net/usb/lan78xx.c
855
netif_dbg(dev, drv, dev->net, "start tx path");
drivers/net/usb/lan78xx.c
876
netif_dbg(dev, drv, dev->net, "stop tx path");
drivers/net/usb/lan78xx.c
905
netif_dbg(dev, drv, dev->net, "start rx path");
drivers/net/usb/lan78xx.c
926
netif_dbg(dev, drv, dev->net, "stop rx path");
drivers/net/usb/lg-vl600.c
118
netif_err(dev, ifup, dev->net, "Fragment too long\n");
drivers/net/usb/lg-vl600.c
119
dev->net->stats.rx_length_errors++;
drivers/net/usb/lg-vl600.c
126
netif_err(dev, ifup, dev->net, "Frame too short\n");
drivers/net/usb/lg-vl600.c
127
dev->net->stats.rx_length_errors++;
drivers/net/usb/lg-vl600.c
147
dev->net->stats.rx_errors++;
drivers/net/usb/lg-vl600.c
158
netif_err(dev, ifup, dev->net, "Packet too short\n");
drivers/net/usb/lg-vl600.c
165
netif_err(dev, ifup, dev->net,
drivers/net/usb/lg-vl600.c
187
memcpy(ethhdr->h_dest, dev->net->dev_addr, ETH_ALEN);
drivers/net/usb/lg-vl600.c
226
dev->net->stats.rx_errors++;
drivers/net/usb/lg-vl600.c
79
dev->net->flags |= IFF_NOARP;
drivers/net/usb/lg-vl600.c
81
dev->net->flags |= IFF_MULTICAST;
drivers/net/usb/mcs7830.c
349
static void mcs7830_data_set_multicast(struct net_device *net)
drivers/net/usb/mcs7830.c
351
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/mcs7830.c
361
if (net->flags & IFF_PROMISC) {
drivers/net/usb/mcs7830.c
363
} else if (net->flags & IFF_ALLMULTI ||
drivers/net/usb/mcs7830.c
364
netdev_mc_count(net) > MCS7830_MAX_MCAST) {
drivers/net/usb/mcs7830.c
366
} else if (netdev_mc_empty(net)) {
drivers/net/usb/mcs7830.c
377
netdev_for_each_mc_addr(ha, net) {
drivers/net/usb/mcs7830.c
389
ret = mcs7830_hif_set_mac_address(dev, dev->net->dev_addr);
drivers/net/usb/mcs7830.c
412
static void mcs7830_set_multicast(struct net_device *net)
drivers/net/usb/mcs7830.c
414
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/mcs7830.c
416
mcs7830_data_set_multicast(net);
drivers/net/usb/mcs7830.c
422
static int mcs7830_get_regs_len(struct net_device *net)
drivers/net/usb/mcs7830.c
424
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/mcs7830.c
435
static void mcs7830_get_regs(struct net_device *net, struct ethtool_regs *regs, void *data)
drivers/net/usb/mcs7830.c
437
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/mcs7830.c
472
struct net_device *net = dev->net;
drivers/net/usb/mcs7830.c
485
eth_hw_addr_set(net, addr);
drivers/net/usb/mcs7830.c
487
mcs7830_data_set_multicast(net);
drivers/net/usb/mcs7830.c
493
net->ethtool_ops = &mcs7830_ethtool_ops;
drivers/net/usb/mcs7830.c
494
net->netdev_ops = &mcs7830_netdev_ops;
drivers/net/usb/mcs7830.c
501
dev->mii.dev = net;
drivers/net/usb/mcs7830.c
504
dev->mii.phy_id = *((u8 *) net->dev_addr + 1);
drivers/net/usb/mcs7830.c
517
if (skb->len < dev->net->hard_header_len) {
drivers/net/usb/mcs7830.c
530
dev->net->stats.rx_errors++;
drivers/net/usb/mcs7830.c
535
dev->net->stats.rx_length_errors++;
drivers/net/usb/mcs7830.c
537
dev->net->stats.rx_frame_errors++;
drivers/net/usb/mcs7830.c
539
dev->net->stats.rx_crc_errors++;
drivers/net/usb/mcs7830.c
554
link_changed = netif_carrier_ok(dev->net) != link;
drivers/net/usb/mcs7830.c
557
netdev_dbg(dev->net, "Link Status is: %d\n", link);
drivers/net/usb/net1080.c
140
netdev_dbg(dev->net, "registers:\n");
drivers/net/usb/net1080.c
152
netdev_dbg(dev->net, "reg [0x%x] ==> error %d\n",
drivers/net/usb/net1080.c
155
netdev_dbg(dev->net, "reg [0x%x] = 0x%x\n", reg, *vp);
drivers/net/usb/net1080.c
183
netif_dbg(dev, link, dev->net,
drivers/net/usb/net1080.c
226
netif_dbg(dev, link, dev->net,
drivers/net/usb/net1080.c
268
netdev_dbg(dev->net, "can't read %s-%s status: %d\n",
drivers/net/usb/net1080.c
276
netdev_dbg(dev->net, "can't read USBCTL, %d\n", retval);
drivers/net/usb/net1080.c
286
netdev_dbg(dev->net, "can't read TTL, %d\n", retval);
drivers/net/usb/net1080.c
293
netdev_dbg(dev->net, "assigned TTL, %d ms\n", NC_READ_TTL_MS);
drivers/net/usb/net1080.c
295
netif_info(dev, link, dev->net, "port %c, peer %sconnected\n",
drivers/net/usb/net1080.c
313
netdev_dbg(dev->net, "net1080_check_conn read - %d\n", retval);
drivers/net/usb/net1080.c
334
netif_dbg(dev, rx_err, dev->net,
drivers/net/usb/net1080.c
346
if (skb->len < dev->net->hard_header_len)
drivers/net/usb/net1080.c
350
netdev_dbg(dev->net, "rx framesize %d range %d..%d mtu %d\n",
drivers/net/usb/net1080.c
351
skb->len, dev->net->hard_header_len, dev->hard_mtu,
drivers/net/usb/net1080.c
352
dev->net->mtu);
drivers/net/usb/net1080.c
353
dev->net->stats.rx_frame_errors++;
drivers/net/usb/net1080.c
362
dev->net->stats.rx_frame_errors++;
drivers/net/usb/net1080.c
363
netdev_dbg(dev->net, "packet too big, %d\n", packet_len);
drivers/net/usb/net1080.c
367
dev->net->stats.rx_frame_errors++;
drivers/net/usb/net1080.c
368
netdev_dbg(dev->net, "header too short, %d\n", hdr_len);
drivers/net/usb/net1080.c
373
netdev_dbg(dev->net, "header OOB, %d bytes\n", hdr_len - MIN_HEADER);
drivers/net/usb/net1080.c
385
dev->net->stats.rx_frame_errors++;
drivers/net/usb/net1080.c
386
netdev_dbg(dev->net, "bad pad\n");
drivers/net/usb/net1080.c
392
dev->net->stats.rx_frame_errors++;
drivers/net/usb/net1080.c
393
netdev_dbg(dev->net, "bad packet len %d (expected %d)\n",
drivers/net/usb/net1080.c
399
dev->net->stats.rx_fifo_errors++;
drivers/net/usb/net1080.c
400
netdev_dbg(dev->net, "(2+ dropped) rx packet_id mismatch 0x%x 0x%x\n",
drivers/net/usb/net1080.c
406
netdev_dbg(dev->net, "frame <rx h %d p %d id %d\n", header->hdr_len,
drivers/net/usb/net1080.c
467
netdev_dbg(dev->net, "frame >tx h %d p %d id %d\n",
drivers/net/usb/net1080.c
480
dev->net->hard_header_len += extra;
drivers/net/usb/net1080.c
481
dev->rx_urb_size = dev->net->hard_header_len + dev->net->mtu;
drivers/net/usb/pegasus.c
1025
static int pegasus_siocdevprivate(struct net_device *net, struct ifreq *rq,
drivers/net/usb/pegasus.c
1029
pegasus_t *pegasus = netdev_priv(net);
drivers/net/usb/pegasus.c
1051
static void pegasus_set_multicast(struct net_device *net)
drivers/net/usb/pegasus.c
1053
pegasus_t *pegasus = netdev_priv(net);
drivers/net/usb/pegasus.c
1055
if (net->flags & IFF_PROMISC) {
drivers/net/usb/pegasus.c
1057
netif_info(pegasus, link, net, "Promiscuous mode enabled\n");
drivers/net/usb/pegasus.c
1058
} else if (!netdev_mc_empty(net) || (net->flags & IFF_ALLMULTI)) {
drivers/net/usb/pegasus.c
1061
netif_dbg(pegasus, link, net, "set allmulti\n");
drivers/net/usb/pegasus.c
1121
netif_dbg(pegasus, drv, pegasus->net, "%s failed\n", __func__);
drivers/net/usb/pegasus.c
1127
set_carrier(pegasus->net);
drivers/net/usb/pegasus.c
1154
struct net_device *net;
drivers/net/usb/pegasus.c
1176
net = alloc_etherdev(sizeof(struct pegasus));
drivers/net/usb/pegasus.c
1177
if (!net)
drivers/net/usb/pegasus.c
1180
pegasus = netdev_priv(net);
drivers/net/usb/pegasus.c
1195
pegasus->net = net;
drivers/net/usb/pegasus.c
1198
net->watchdog_timeo = PEGASUS_TX_TIMEOUT;
drivers/net/usb/pegasus.c
1199
net->netdev_ops = &pegasus_netdev_ops;
drivers/net/usb/pegasus.c
1200
net->ethtool_ops = &ops;
drivers/net/usb/pegasus.c
1201
pegasus->mii.dev = net;
drivers/net/usb/pegasus.c
1230
SET_NETDEV_DEV(net, &intf->dev);
drivers/net/usb/pegasus.c
1231
pegasus_reset_wol(net);
drivers/net/usb/pegasus.c
1232
res = register_netdev(net);
drivers/net/usb/pegasus.c
1237
dev_info(&intf->dev, "%s, %s, %pM\n", net->name,
drivers/net/usb/pegasus.c
1238
usb_dev_id[dev_index].name, net->dev_addr);
drivers/net/usb/pegasus.c
124
netif_dbg(pegasus, drv, pegasus->net, "%s failed with %d\n", __func__, ret);
drivers/net/usb/pegasus.c
1246
free_netdev(net);
drivers/net/usb/pegasus.c
1263
unregister_netdev(pegasus->net);
drivers/net/usb/pegasus.c
1270
free_netdev(pegasus->net);
drivers/net/usb/pegasus.c
1277
netif_device_detach(pegasus->net);
drivers/net/usb/pegasus.c
1279
if (netif_running(pegasus->net)) {
drivers/net/usb/pegasus.c
1290
netif_device_attach(pegasus->net);
drivers/net/usb/pegasus.c
1291
if (netif_running(pegasus->net)) {
drivers/net/usb/pegasus.c
143
netif_dbg(pegasus, drv, pegasus->net, "%s failed with %d\n", __func__, ret);
drivers/net/usb/pegasus.c
176
netif_device_detach(pegasus->net);
drivers/net/usb/pegasus.c
177
netif_err(pegasus, drv, pegasus->net,
drivers/net/usb/pegasus.c
217
netif_dbg(p, drv, p->net, "%s failed\n", __func__);
drivers/net/usb/pegasus.c
283
netif_dbg(pegasus, drv, pegasus->net, "%s failed\n", __func__);
drivers/net/usb/pegasus.c
332
netif_dbg(pegasus, drv, pegasus->net, "%s failed\n", __func__);
drivers/net/usb/pegasus.c
370
eth_hw_addr_set(pegasus->net, node_id);
drivers/net/usb/pegasus.c
374
eth_hw_addr_random(pegasus->net);
drivers/net/usb/pegasus.c
375
netif_dbg(pegasus, drv, pegasus->net, "software assigned MAC address.\n");
drivers/net/usb/pegasus.c
421
netif_dbg(pegasus, drv, pegasus->net, "%s failed\n", __func__);
drivers/net/usb/pegasus.c
461
netif_dbg(pegasus, drv, pegasus->net, "%s failed\n", __func__);
drivers/net/usb/pegasus.c
468
struct net_device *net;
drivers/net/usb/pegasus.c
477
net = pegasus->net;
drivers/net/usb/pegasus.c
478
if (!netif_device_present(net) || !netif_running(net))
drivers/net/usb/pegasus.c
485
netif_dbg(pegasus, rx_err, net, "reset MAC\n");
drivers/net/usb/pegasus.c
490
netif_warn(pegasus, rx_err, net, "no rx stall recovery\n");
drivers/net/usb/pegasus.c
495
netif_dbg(pegasus, ifdown, net, "rx unlink, %d\n", status);
drivers/net/usb/pegasus.c
498
netif_dbg(pegasus, rx_err, net, "RX status %d\n", status);
drivers/net/usb/pegasus.c
507
netif_dbg(pegasus, rx_err, net,
drivers/net/usb/pegasus.c
509
net->stats.rx_errors++;
drivers/net/usb/pegasus.c
511
net->stats.rx_length_errors++;
drivers/net/usb/pegasus.c
513
net->stats.rx_crc_errors++;
drivers/net/usb/pegasus.c
515
net->stats.rx_frame_errors++;
drivers/net/usb/pegasus.c
541
pegasus->rx_skb->protocol = eth_type_trans(pegasus->rx_skb, net);
drivers/net/usb/pegasus.c
543
net->stats.rx_packets++;
drivers/net/usb/pegasus.c
544
net->stats.rx_bytes += pkt_len;
drivers/net/usb/pegasus.c
549
pegasus->rx_skb = __netdev_alloc_skb_ip_align(pegasus->net, PEGASUS_MTU,
drivers/net/usb/pegasus.c
561
netif_device_detach(pegasus->net);
drivers/net/usb/pegasus.c
587
pegasus->rx_skb = __netdev_alloc_skb_ip_align(pegasus->net,
drivers/net/usb/pegasus.c
591
netif_warn(pegasus, rx_err, pegasus->net, "low on memory\n");
drivers/net/usb/pegasus.c
602
netif_device_detach(pegasus->net);
drivers/net/usb/pegasus.c
614
struct net_device *net;
drivers/net/usb/pegasus.c
620
net = pegasus->net;
drivers/net/usb/pegasus.c
622
if (!netif_device_present(net) || !netif_running(net))
drivers/net/usb/pegasus.c
628
netif_stop_queue(net);
drivers/net/usb/pegasus.c
629
netif_warn(pegasus, tx_err, net, "no tx stall recovery\n");
drivers/net/usb/pegasus.c
634
netif_dbg(pegasus, ifdown, net, "tx unlink, %d\n", status);
drivers/net/usb/pegasus.c
637
netif_info(pegasus, tx_err, net, "TX status %d\n", status);
drivers/net/usb/pegasus.c
643
netif_trans_update(net); /* prevent tx timeout */
drivers/net/usb/pegasus.c
644
netif_wake_queue(net);
drivers/net/usb/pegasus.c
650
struct net_device *net;
drivers/net/usb/pegasus.c
655
net = pegasus->net;
drivers/net/usb/pegasus.c
668
netif_dbg(pegasus, timer, net, "intr status %d\n", status);
drivers/net/usb/pegasus.c
677
net->stats.tx_errors++;
drivers/net/usb/pegasus.c
679
net->stats.tx_fifo_errors++;
drivers/net/usb/pegasus.c
681
net->stats.tx_aborted_errors++;
drivers/net/usb/pegasus.c
683
net->stats.tx_window_errors++;
drivers/net/usb/pegasus.c
692
net->stats.rx_missed_errors += ((d[3] & 0x7f) << 8) | d[4];
drivers/net/usb/pegasus.c
697
netif_device_detach(pegasus->net);
drivers/net/usb/pegasus.c
699
netif_err(pegasus, timer, net,
drivers/net/usb/pegasus.c
703
static void pegasus_tx_timeout(struct net_device *net, unsigned int txqueue)
drivers/net/usb/pegasus.c
705
pegasus_t *pegasus = netdev_priv(net);
drivers/net/usb/pegasus.c
706
netif_warn(pegasus, timer, net, "tx timeout\n");
drivers/net/usb/pegasus.c
708
net->stats.tx_errors++;
drivers/net/usb/pegasus.c
712
struct net_device *net)
drivers/net/usb/pegasus.c
714
pegasus_t *pegasus = netdev_priv(net);
drivers/net/usb/pegasus.c
719
netif_stop_queue(net);
drivers/net/usb/pegasus.c
728
netif_warn(pegasus, tx_err, net, "fail tx, %d\n", res);
drivers/net/usb/pegasus.c
735
netif_device_detach(pegasus->net);
drivers/net/usb/pegasus.c
738
net->stats.tx_errors++;
drivers/net/usb/pegasus.c
739
netif_start_queue(net);
drivers/net/usb/pegasus.c
742
net->stats.tx_packets++;
drivers/net/usb/pegasus.c
743
net->stats.tx_bytes += skb->len;
drivers/net/usb/pegasus.c
770
netif_info(pegasus, timer, pegasus->net,
drivers/net/usb/pegasus.c
785
static void set_carrier(struct net_device *net)
drivers/net/usb/pegasus.c
787
pegasus_t *pegasus = netdev_priv(net);
drivers/net/usb/pegasus.c
794
netif_carrier_on(net);
drivers/net/usb/pegasus.c
796
netif_carrier_off(net);
drivers/net/usb/pegasus.c
847
static int pegasus_open(struct net_device *net)
drivers/net/usb/pegasus.c
849
pegasus_t *pegasus = netdev_priv(net);
drivers/net/usb/pegasus.c
853
pegasus->rx_skb = __netdev_alloc_skb_ip_align(pegasus->net,
drivers/net/usb/pegasus.c
859
set_registers(pegasus, EthID, 6, net->dev_addr);
drivers/net/usb/pegasus.c
867
netif_device_detach(pegasus->net);
drivers/net/usb/pegasus.c
868
netif_dbg(pegasus, ifup, net, "failed rx_urb, %d\n", res);
drivers/net/usb/pegasus.c
878
netif_device_detach(pegasus->net);
drivers/net/usb/pegasus.c
879
netif_dbg(pegasus, ifup, net, "failed intr_urb, %d\n", res);
drivers/net/usb/pegasus.c
883
res = enable_net_traffic(net, pegasus->usb);
drivers/net/usb/pegasus.c
885
netif_dbg(pegasus, ifup, net,
drivers/net/usb/pegasus.c
892
set_carrier(net);
drivers/net/usb/pegasus.c
893
netif_start_queue(net);
drivers/net/usb/pegasus.c
894
netif_dbg(pegasus, ifup, net, "open\n");
drivers/net/usb/pegasus.c
900
static int pegasus_close(struct net_device *net)
drivers/net/usb/pegasus.c
902
pegasus_t *pegasus = netdev_priv(net);
drivers/net/usb/pegasus.c
904
netif_stop_queue(net);
drivers/net/usb/pegasus.h
82
struct net_device *net;
drivers/net/usb/plusb.c
80
netif_dbg(dev, link, dev->net, "pl_reset --> %d\n", status);
drivers/net/usb/qmi_wwan.c
146
netdev_for_each_upper_dev_rcu(dev->net, ldev, iter) {
drivers/net/usb/qmi_wwan.c
159
return !list_empty(&dev->net->adj_list.upper);
drivers/net/usb/qmi_wwan.c
1596
netdev_for_each_upper_dev_rcu(dev->net, ldev, iter)
drivers/net/usb/qmi_wwan.c
166
struct net_device *net;
drivers/net/usb/qmi_wwan.c
188
net = qmimux_find_dev(dev, hdr->mux_id);
drivers/net/usb/qmi_wwan.c
189
if (!net)
drivers/net/usb/qmi_wwan.c
191
skbn = netdev_alloc_skb(net, pkt_len + LL_MAX_HEADER);
drivers/net/usb/qmi_wwan.c
217
net->stats.rx_errors++;
drivers/net/usb/qmi_wwan.c
220
dev_sw_netstats_rx_add(net, pkt_len);
drivers/net/usb/qmi_wwan.c
306
static void qmi_wwan_netdev_setup(struct net_device *net)
drivers/net/usb/qmi_wwan.c
308
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/qmi_wwan.c
312
net->header_ops = NULL; /* No header */
drivers/net/usb/qmi_wwan.c
313
net->type = ARPHRD_NONE;
drivers/net/usb/qmi_wwan.c
314
net->hard_header_len = 0;
drivers/net/usb/qmi_wwan.c
315
net->addr_len = 0;
drivers/net/usb/qmi_wwan.c
316
net->flags = IFF_POINTOPOINT | IFF_NOARP | IFF_MULTICAST;
drivers/net/usb/qmi_wwan.c
318
netdev_dbg(net, "mode: raw IP\n");
drivers/net/usb/qmi_wwan.c
319
} else if (!net->header_ops) { /* don't bother if already set */
drivers/net/usb/qmi_wwan.c
320
ether_setup(net);
drivers/net/usb/qmi_wwan.c
322
net->min_mtu = 0;
drivers/net/usb/qmi_wwan.c
323
net->max_mtu = ETH_MAX_MTU;
drivers/net/usb/qmi_wwan.c
325
netdev_dbg(net, "mode: Ethernet\n");
drivers/net/usb/qmi_wwan.c
329
usbnet_change_mtu(net, net->mtu);
drivers/net/usb/qmi_wwan.c
356
netdev_err(dev->net,
drivers/net/usb/qmi_wwan.c
365
if (netif_running(dev->net)) {
drivers/net/usb/qmi_wwan.c
366
netdev_err(dev->net, "Cannot change a running device\n");
drivers/net/usb/qmi_wwan.c
372
ret = call_netdevice_notifiers(NETDEV_PRE_TYPE_CHANGE, dev->net);
drivers/net/usb/qmi_wwan.c
375
netdev_err(dev->net, "Type change was refused\n");
drivers/net/usb/qmi_wwan.c
383
qmi_wwan_netdev_setup(dev->net);
drivers/net/usb/qmi_wwan.c
384
call_netdevice_notifiers(NETDEV_POST_TYPE_CHANGE, dev->net);
drivers/net/usb/qmi_wwan.c
427
netdev_err(dev->net, "mux_id already present\n");
drivers/net/usb/qmi_wwan.c
432
ret = qmimux_register_device(dev->net, mux_id);
drivers/net/usb/qmi_wwan.c
463
netdev_err(dev->net, "mux_id not present\n");
drivers/net/usb/qmi_wwan.c
507
netdev_err(dev->net,
drivers/net/usb/qmi_wwan.c
570
if (skb->len < dev->net->hard_header_len)
drivers/net/usb/qmi_wwan.c
604
skb->dev = dev->net; /* normally set by eth_type_trans */
drivers/net/usb/qmi_wwan.c
616
memcpy(eth_hdr(skb)->h_dest, dev->net->dev_addr, ETH_ALEN);
drivers/net/usb/qmi_wwan.c
831
if (ether_addr_equal(dev->net->dev_addr, default_modem_addr) ||
drivers/net/usb/qmi_wwan.c
832
ether_addr_equal(dev->net->dev_addr, buggy_fw_addr))
drivers/net/usb/qmi_wwan.c
833
eth_hw_addr_random(dev->net);
drivers/net/usb/qmi_wwan.c
836
if (possibly_iphdr(dev->net->dev_addr)) {
drivers/net/usb/qmi_wwan.c
837
u8 addr = dev->net->dev_addr[0];
drivers/net/usb/qmi_wwan.c
841
dev_addr_mod(dev->net, 0, &addr, 1);
drivers/net/usb/qmi_wwan.c
843
dev->net->netdev_ops = &qmi_wwan_netdev_ops;
drivers/net/usb/qmi_wwan.c
844
dev->net->sysfs_groups[0] = &qmi_wwan_sysfs_attr_group;
drivers/net/usb/r8152.c
9233
rtl_ethtool_get_eee(struct net_device *net, struct ethtool_keee *edata)
drivers/net/usb/r8152.c
9235
struct r8152 *tp = netdev_priv(net);
drivers/net/usb/r8152.c
9260
rtl_ethtool_set_eee(struct net_device *net, struct ethtool_keee *edata)
drivers/net/usb/r8152.c
9262
struct r8152 *tp = netdev_priv(net);
drivers/net/usb/r8153_ecm.c
106
dev->mii.dev = dev->net;
drivers/net/usb/rndis_host.c
292
struct net_device *net = dev->net;
drivers/net/usb/rndis_host.c
334
net->hard_header_len += sizeof (struct rndis_data_hdr);
drivers/net/usb/rndis_host.c
335
dev->hard_mtu = net->mtu + net->hard_header_len;
drivers/net/usb/rndis_host.c
339
netif_dbg(dev, probe, dev->net,
drivers/net/usb/rndis_host.c
349
net->netdev_ops = &rndis_netdev_ops;
drivers/net/usb/rndis_host.c
359
if (tmp <= net->hard_header_len) {
drivers/net/usb/rndis_host.c
369
dev->hard_mtu, tmp, tmp - net->hard_header_len);
drivers/net/usb/rndis_host.c
371
net->mtu = dev->hard_mtu - net->hard_header_len;
drivers/net/usb/rndis_host.c
399
netif_dbg(dev, probe, dev->net,
drivers/net/usb/rndis_host.c
406
netif_dbg(dev, probe, dev->net,
drivers/net/usb/rndis_host.c
422
eth_hw_addr_set(net, bp);
drivers/net/usb/rndis_host.c
468
if (!status && (dev->net->dev_addr[0] & 0x02))
drivers/net/usb/rndis_host.c
469
eth_hw_addr_random(dev->net);
drivers/net/usb/rndis_host.c
47
netdev_dbg(dev->net, "rndis status urb, len %d stat %d\n",
drivers/net/usb/rndis_host.c
499
if (skb->len < dev->net->hard_header_len)
drivers/net/usb/rndis_host.c
518
dev->net->stats.rx_frame_errors++;
drivers/net/usb/rndis_host.c
519
netdev_dbg(dev->net, "bad rndis message %d/%d/%d/%d, len %d\n",
drivers/net/usb/sierra_net.c
220
netdev_err(dev->net, "Non linear buffer-dropping\n");
drivers/net/usb/sierra_net.c
328
netdev_err(dev->net, "Submit %s failed %d\n", cmd_name, status);
drivers/net/usb/sierra_net.c
361
netdev_err(dev->net, "%s: Data length %d, exp >= %zu\n",
drivers/net/usb/sierra_net.c
368
netdev_err(dev->net, "Session idle, 0x%02x\n",
drivers/net/usb/sierra_net.c
380
netdev_err(dev->net, "Link type unsupported: 0x%02x\n",
drivers/net/usb/sierra_net.c
388
netdev_err(dev->net, "Protocol unsupported, 0x%02x\n",
drivers/net/usb/sierra_net.c
394
netdev_err(dev->net, "%s: LSI_UMTS_STATUS_LEN %d, exp %u\n",
drivers/net/usb/sierra_net.c
402
netdev_err(dev->net, "No coverage, 0x%02x\n", lsi->coverage);
drivers/net/usb/sierra_net.c
419
netdev_err(dev->net, "Invalid LSI\n");
drivers/net/usb/sierra_net.c
448
netdev_err(dev->net,
drivers/net/usb/sierra_net.c
452
netdev_err(dev->net,
drivers/net/usb/sierra_net.c
486
netdev_err(dev->net,
drivers/net/usb/sierra_net.c
496
netdev_err(dev->net, "%s: Bad packet,"
drivers/net/usb/sierra_net.c
504
netdev_err(dev->net, "%s: Bad packet, received"
drivers/net/usb/sierra_net.c
531
netdev_err(dev->net,
drivers/net/usb/sierra_net.c
535
netdev_err(dev->net, "Unrecognized HIP msg, "
drivers/net/usb/sierra_net.c
542
netdev_err(dev->net, "Unrecognized HIP msg, "
drivers/net/usb/sierra_net.c
602
netdev_err(dev->net, ": unexpected notification %02x!\n",
drivers/net/usb/sierra_net.c
608
static u32 sierra_net_get_link(struct net_device *net)
drivers/net/usb/sierra_net.c
610
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/sierra_net.c
612
return sierra_net_get_private(dev)->link_up && netif_running(net);
drivers/net/usb/sierra_net.c
692
dev->net->netdev_ops = &sierra_net_device_ops;
drivers/net/usb/sierra_net.c
697
dev_addr_mod(dev->net, ETH_ALEN - 2, mod, 2);
drivers/net/usb/sierra_net.c
712
dev->net->hard_header_len += SIERRA_NET_HIP_EXT_HDR_LEN;
drivers/net/usb/sierra_net.c
713
dev->hard_mtu = dev->net->mtu + dev->net->hard_header_len;
drivers/net/usb/sierra_net.c
714
dev->net->max_mtu = SIERRA_NET_MAX_SUPPORTED_MTU;
drivers/net/usb/sierra_net.c
717
dev->net->flags |= IFF_NOARP;
drivers/net/usb/sierra_net.c
718
dev->net->ethtool_ops = &sierra_net_ethtool_ops;
drivers/net/usb/sierra_net.c
719
netif_carrier_off(dev->net);
drivers/net/usb/sierra_net.c
762
netdev_err(dev->net,
drivers/net/usb/sierra_net.c
787
netdev_err(dev->net, "failed to get skb\n");
drivers/net/usb/sierra_net.c
788
dev->net->stats.rx_dropped++;
drivers/net/usb/sierra_net.c
808
netdev_err(dev->net, "Invalid HIP header %d\n",
drivers/net/usb/sierra_net.c
811
dev->net->stats.rx_length_errors++;
drivers/net/usb/sierra_net.c
819
netdev_err(dev->net, "HIP/ETH: Invalid pkt\n");
drivers/net/usb/sierra_net.c
821
dev->net->stats.rx_frame_errors++;
drivers/net/usb/sierra_net.c
835
memcpy(eth_hdr(skb)->h_dest, dev->net->dev_addr, ETH_ALEN);
drivers/net/usb/sierra_net.c
873
netdev_err(dev->net, "tx_fixup:"
drivers/net/usb/sierra_net.c
889
netdev_err(dev->net, "tx_fixup: no room for HIP\n");
drivers/net/usb/sierra_net.c
894
dev->net->stats.tx_carrier_errors++;
drivers/net/usb/smsc75xx.c
1006
netdev_warn(dev->net, "Failed to read PMT_CTL: %d\n", ret);
drivers/net/usb/smsc75xx.c
1014
netdev_warn(dev->net, "Failed to write PMT_CTL: %d\n", ret);
drivers/net/usb/smsc75xx.c
1023
netdev_warn(dev->net, "Failed to read PMT_CTL: %d\n",
drivers/net/usb/smsc75xx.c
1031
netdev_warn(dev->net, "timeout waiting for PHY Reset\n");
drivers/net/usb/smsc75xx.c
1044
netif_dbg(dev, ifup, dev->net, "entering smsc75xx_reset\n");
drivers/net/usb/smsc75xx.c
1048
netdev_warn(dev->net, "device not ready in smsc75xx_reset\n");
drivers/net/usb/smsc75xx.c
1054
netdev_warn(dev->net, "Failed to read HW_CFG: %d\n", ret);
drivers/net/usb/smsc75xx.c
1062
netdev_warn(dev->net, "Failed to write HW_CFG: %d\n", ret);
drivers/net/usb/smsc75xx.c
1071
netdev_warn(dev->net, "Failed to read HW_CFG: %d\n", ret);
drivers/net/usb/smsc75xx.c
1078
netdev_warn(dev->net, "timeout on completion of Lite Reset\n");
drivers/net/usb/smsc75xx.c
1082
netif_dbg(dev, ifup, dev->net, "Lite reset complete, resetting PHY\n");
drivers/net/usb/smsc75xx.c
1086
netdev_warn(dev->net, "Failed to read PMT_CTL: %d\n", ret);
drivers/net/usb/smsc75xx.c
1094
netdev_warn(dev->net, "Failed to write PMT_CTL: %d\n", ret);
drivers/net/usb/smsc75xx.c
1103
netdev_warn(dev->net, "Failed to read PMT_CTL: %d\n", ret);
drivers/net/usb/smsc75xx.c
1110
netdev_warn(dev->net, "timeout waiting for PHY Reset\n");
drivers/net/usb/smsc75xx.c
1114
netif_dbg(dev, ifup, dev->net, "PHY reset complete\n");
drivers/net/usb/smsc75xx.c
1118
netdev_warn(dev->net, "Failed to set mac address\n");
drivers/net/usb/smsc75xx.c
1122
netif_dbg(dev, ifup, dev->net, "MAC Address: %pM\n",
drivers/net/usb/smsc75xx.c
1123
dev->net->dev_addr);
drivers/net/usb/smsc75xx.c
1127
netdev_warn(dev->net, "Failed to read HW_CFG: %d\n", ret);
drivers/net/usb/smsc75xx.c
1131
netif_dbg(dev, ifup, dev->net, "Read Value from HW_CFG : 0x%08x\n",
drivers/net/usb/smsc75xx.c
1138
netdev_warn(dev->net, "Failed to write HW_CFG: %d\n", ret);
drivers/net/usb/smsc75xx.c
1144
netdev_warn(dev->net, "Failed to read HW_CFG: %d\n", ret);
drivers/net/usb/smsc75xx.c
1148
netif_dbg(dev, ifup, dev->net, "Read Value from HW_CFG after writing HW_CFG_BIR: 0x%08x\n",
drivers/net/usb/smsc75xx.c
1162
netif_dbg(dev, ifup, dev->net, "rx_urb_size=%ld\n",
drivers/net/usb/smsc75xx.c
1167
netdev_warn(dev->net, "Failed to write BURST_CAP: %d\n", ret);
drivers/net/usb/smsc75xx.c
1173
netdev_warn(dev->net, "Failed to read BURST_CAP: %d\n", ret);
drivers/net/usb/smsc75xx.c
1177
netif_dbg(dev, ifup, dev->net,
drivers/net/usb/smsc75xx.c
1182
netdev_warn(dev->net, "Failed to write BULK_IN_DLY: %d\n", ret);
drivers/net/usb/smsc75xx.c
1188
netdev_warn(dev->net, "Failed to read BULK_IN_DLY: %d\n", ret);
drivers/net/usb/smsc75xx.c
1192
netif_dbg(dev, ifup, dev->net,
drivers/net/usb/smsc75xx.c
1198
netdev_warn(dev->net, "Failed to read HW_CFG: %d\n", ret);
drivers/net/usb/smsc75xx.c
1202
netif_dbg(dev, ifup, dev->net, "HW_CFG: 0x%08x\n", buf);
drivers/net/usb/smsc75xx.c
1208
netdev_warn(dev->net, "Failed to write HW_CFG: %d\n", ret);
drivers/net/usb/smsc75xx.c
1214
netdev_warn(dev->net, "Failed to read HW_CFG: %d\n", ret);
drivers/net/usb/smsc75xx.c
1218
netif_dbg(dev, ifup, dev->net, "HW_CFG: 0x%08x\n", buf);
drivers/net/usb/smsc75xx.c
122
netdev_warn(dev->net, "Failed to write reg index 0x%08x: %d\n",
drivers/net/usb/smsc75xx.c
1225
netdev_warn(dev->net, "Failed to write FCT_RX_FIFO_END: %d\n", ret);
drivers/net/usb/smsc75xx.c
1229
netif_dbg(dev, ifup, dev->net, "FCT_RX_FIFO_END set to 0x%08x\n", buf);
drivers/net/usb/smsc75xx.c
1234
netdev_warn(dev->net, "Failed to write FCT_TX_FIFO_END: %d\n", ret);
drivers/net/usb/smsc75xx.c
1238
netif_dbg(dev, ifup, dev->net, "FCT_TX_FIFO_END set to 0x%08x\n", buf);
drivers/net/usb/smsc75xx.c
1242
netdev_warn(dev->net, "Failed to write INT_STS: %d\n", ret);
drivers/net/usb/smsc75xx.c
1248
netdev_warn(dev->net, "Failed to read ID_REV: %d\n", ret);
drivers/net/usb/smsc75xx.c
1252
netif_dbg(dev, ifup, dev->net, "ID_REV = 0x%08x\n", buf);
drivers/net/usb/smsc75xx.c
1256
netdev_warn(dev->net, "Failed to read E2P_CMD: %d\n", ret);
drivers/net/usb/smsc75xx.c
1264
netdev_warn(dev->net, "Failed to read LED_GPIO_CFG: %d\n", ret);
drivers/net/usb/smsc75xx.c
1273
netdev_warn(dev->net, "Failed to write LED_GPIO_CFG: %d\n", ret);
drivers/net/usb/smsc75xx.c
1280
netdev_warn(dev->net, "Failed to write FLOW: %d\n", ret);
drivers/net/usb/smsc75xx.c
1286
netdev_warn(dev->net, "Failed to write FCT_FLOW: %d\n", ret);
drivers/net/usb/smsc75xx.c
1293
netdev_warn(dev->net, "Failed to read RFE_CTL: %d\n", ret);
drivers/net/usb/smsc75xx.c
1301
netdev_warn(dev->net, "Failed to write RFE_CTL: %d\n", ret);
drivers/net/usb/smsc75xx.c
1307
netdev_warn(dev->net, "Failed to read RFE_CTL: %d\n", ret);
drivers/net/usb/smsc75xx.c
1311
netif_dbg(dev, ifup, dev->net, "RFE_CTL set to 0x%08x\n",
drivers/net/usb/smsc75xx.c
1315
smsc75xx_set_features(dev->net, dev->net->features);
drivers/net/usb/smsc75xx.c
1317
smsc75xx_set_multicast(dev->net);
drivers/net/usb/smsc75xx.c
1321
netdev_warn(dev->net, "Failed to initialize PHY: %d\n", ret);
drivers/net/usb/smsc75xx.c
1327
netdev_warn(dev->net, "Failed to read INT_EP_CTL: %d\n", ret);
drivers/net/usb/smsc75xx.c
1336
netdev_warn(dev->net, "Failed to write INT_EP_CTL: %d\n", ret);
drivers/net/usb/smsc75xx.c
1343
netdev_warn(dev->net, "Failed to read MAC_CR: %d\n", ret);
drivers/net/usb/smsc75xx.c
1350
netdev_warn(dev->net, "Failed to write MAC_CR: %d\n", ret);
drivers/net/usb/smsc75xx.c
1356
netdev_warn(dev->net, "Failed to read MAC_TX: %d\n", ret);
drivers/net/usb/smsc75xx.c
1364
netdev_warn(dev->net, "Failed to write MAC_TX: %d\n", ret);
drivers/net/usb/smsc75xx.c
1368
netif_dbg(dev, ifup, dev->net, "MAC_TX set to 0x%08x\n", buf);
drivers/net/usb/smsc75xx.c
1372
netdev_warn(dev->net, "Failed to read FCT_TX_CTL: %d\n", ret);
drivers/net/usb/smsc75xx.c
1380
netdev_warn(dev->net, "Failed to write FCT_TX_CTL: %d\n", ret);
drivers/net/usb/smsc75xx.c
1384
netif_dbg(dev, ifup, dev->net, "FCT_TX_CTL set to 0x%08x\n", buf);
drivers/net/usb/smsc75xx.c
1386
ret = smsc75xx_set_rx_max_frame_length(dev, dev->net->mtu + ETH_HLEN);
drivers/net/usb/smsc75xx.c
1388
netdev_warn(dev->net, "Failed to set max rx frame length\n");
drivers/net/usb/smsc75xx.c
1394
netdev_warn(dev->net, "Failed to read MAC_RX: %d\n", ret);
drivers/net/usb/smsc75xx.c
1402
netdev_warn(dev->net, "Failed to write MAC_RX: %d\n", ret);
drivers/net/usb/smsc75xx.c
1406
netif_dbg(dev, ifup, dev->net, "MAC_RX set to 0x%08x\n", buf);
drivers/net/usb/smsc75xx.c
1410
netdev_warn(dev->net, "Failed to read FCT_RX_CTL: %d\n", ret);
drivers/net/usb/smsc75xx.c
1418
netdev_warn(dev->net, "Failed to write FCT_RX_CTL: %d\n", ret);
drivers/net/usb/smsc75xx.c
1422
netif_dbg(dev, ifup, dev->net, "FCT_RX_CTL set to 0x%08x\n", buf);
drivers/net/usb/smsc75xx.c
1424
netif_dbg(dev, ifup, dev->net, "smsc75xx_reset, return 0\n");
drivers/net/usb/smsc75xx.c
1449
netdev_warn(dev->net, "usbnet_get_endpoints failed: %d\n", ret);
drivers/net/usb/smsc75xx.c
1467
dev->net->features |= NETIF_F_IP_CSUM | NETIF_F_IPV6_CSUM;
drivers/net/usb/smsc75xx.c
1470
dev->net->features |= NETIF_F_RXCSUM;
drivers/net/usb/smsc75xx.c
1472
dev->net->hw_features = NETIF_F_IP_CSUM | NETIF_F_IPV6_CSUM |
drivers/net/usb/smsc75xx.c
1477
netdev_warn(dev->net, "device not ready in smsc75xx_bind\n");
drivers/net/usb/smsc75xx.c
1486
netdev_warn(dev->net, "smsc75xx_reset error %d\n", ret);
drivers/net/usb/smsc75xx.c
1490
dev->net->netdev_ops = &smsc75xx_netdev_ops;
drivers/net/usb/smsc75xx.c
1491
dev->net->ethtool_ops = &smsc75xx_ethtool_ops;
drivers/net/usb/smsc75xx.c
1492
dev->net->flags |= IFF_MULTICAST;
drivers/net/usb/smsc75xx.c
1493
dev->net->hard_header_len += SMSC75XX_TX_OVERHEAD;
drivers/net/usb/smsc75xx.c
1494
dev->hard_mtu = dev->net->mtu + dev->net->hard_header_len;
drivers/net/usb/smsc75xx.c
1495
dev->net->max_mtu = MAX_SINGLE_PACKET_SIZE;
drivers/net/usb/smsc75xx.c
1511
netif_dbg(dev, ifdown, dev->net, "free pdata\n");
drivers/net/usb/smsc75xx.c
1531
netdev_warn(dev->net, "Error writing WUF_CFGX\n");
drivers/net/usb/smsc75xx.c
1537
netdev_warn(dev->net, "Error writing WUF_MASKX\n");
drivers/net/usb/smsc75xx.c
1543
netdev_warn(dev->net, "Error writing WUF_MASKX\n");
drivers/net/usb/smsc75xx.c
1549
netdev_warn(dev->net, "Error writing WUF_MASKX\n");
drivers/net/usb/smsc75xx.c
1555
netdev_warn(dev->net, "Error writing WUF_MASKX\n");
drivers/net/usb/smsc75xx.c
1570
netdev_warn(dev->net, "Error reading PMT_CTL\n");
drivers/net/usb/smsc75xx.c
1579
netdev_warn(dev->net, "Error writing PMT_CTL\n");
drivers/net/usb/smsc75xx.c
1596
netdev_warn(dev->net, "Error reading PMT_CTL\n");
drivers/net/usb/smsc75xx.c
1605
netdev_warn(dev->net, "Error writing PMT_CTL\n");
drivers/net/usb/smsc75xx.c
1615
netdev_warn(dev->net, "Error writing PMT_CTL\n");
drivers/net/usb/smsc75xx.c
1632
netdev_warn(dev->net, "Error reading PMT_CTL\n");
drivers/net/usb/smsc75xx.c
164
netdev_warn(dev->net, "Error reading MII_ACCESS\n");
drivers/net/usb/smsc75xx.c
1641
netdev_warn(dev->net, "Error writing PMT_CTL\n");
drivers/net/usb/smsc75xx.c
1658
netdev_warn(dev->net, "Error reading FCT_RX_CTL\n");
drivers/net/usb/smsc75xx.c
1663
netdev_dbg(dev->net, "rx fifo not empty in autosuspend\n");
drivers/net/usb/smsc75xx.c
1669
netdev_warn(dev->net, "Error reading PMT_CTL\n");
drivers/net/usb/smsc75xx.c
1678
netdev_warn(dev->net, "Error writing PMT_CTL\n");
drivers/net/usb/smsc75xx.c
1688
netdev_warn(dev->net, "Error writing PMT_CTL\n");
drivers/net/usb/smsc75xx.c
1702
netdev_dbg(dev->net, "enabling PHY wakeup interrupts\n");
drivers/net/usb/smsc75xx.c
1705
ret = smsc75xx_mdio_read_nopm(dev->net, mii->phy_id, PHY_INT_SRC);
drivers/net/usb/smsc75xx.c
1707
netdev_warn(dev->net, "Error reading PHY_INT_SRC\n");
drivers/net/usb/smsc75xx.c
1712
ret = smsc75xx_mdio_read_nopm(dev->net, mii->phy_id, PHY_INT_MASK);
drivers/net/usb/smsc75xx.c
1714
netdev_warn(dev->net, "Error reading PHY_INT_MASK\n");
drivers/net/usb/smsc75xx.c
1720
smsc75xx_mdio_write_nopm(dev->net, mii->phy_id, PHY_INT_MASK, ret);
drivers/net/usb/smsc75xx.c
1731
ret = smsc75xx_mdio_read_nopm(dev->net, mii->phy_id, MII_BMSR);
drivers/net/usb/smsc75xx.c
1733
netdev_warn(dev->net, "Error reading MII_BMSR\n");
drivers/net/usb/smsc75xx.c
1737
ret = smsc75xx_mdio_read_nopm(dev->net, mii->phy_id, MII_BMSR);
drivers/net/usb/smsc75xx.c
1739
netdev_warn(dev->net, "Error reading MII_BMSR\n");
drivers/net/usb/smsc75xx.c
1750
if (!netif_running(dev->net)) {
drivers/net/usb/smsc75xx.c
1752
netdev_dbg(dev->net, "autosuspend entering SUSPEND2\n");
drivers/net/usb/smsc75xx.c
1758
netdev_dbg(dev->net, "autosuspend entering SUSPEND1\n");
drivers/net/usb/smsc75xx.c
1764
netdev_warn(dev->net, "error enabling PHY wakeup ints\n");
drivers/net/usb/smsc75xx.c
1768
netdev_info(dev->net, "entering SUSPEND1 mode\n");
drivers/net/usb/smsc75xx.c
1776
netdev_warn(dev->net, "error enabling PHY wakeup ints\n");
drivers/net/usb/smsc75xx.c
1780
netdev_dbg(dev->net, "autosuspend entering SUSPEND3\n");
drivers/net/usb/smsc75xx.c
1793
netdev_warn(dev->net, "usbnet_suspend error\n");
drivers/net/usb/smsc75xx.c
1798
netdev_warn(dev->net, "error during last resume\n");
drivers/net/usb/smsc75xx.c
1816
netdev_info(dev->net, "entering SUSPEND2 mode\n");
drivers/net/usb/smsc75xx.c
1821
netdev_warn(dev->net, "Error reading WUCSR\n");
drivers/net/usb/smsc75xx.c
1829
netdev_warn(dev->net, "Error writing WUCSR\n");
drivers/net/usb/smsc75xx.c
1835
netdev_warn(dev->net, "Error reading PMT_CTL\n");
drivers/net/usb/smsc75xx.c
1843
netdev_warn(dev->net, "Error writing PMT_CTL\n");
drivers/net/usb/smsc75xx.c
1855
netdev_warn(dev->net, "error enabling PHY wakeup ints\n");
drivers/net/usb/smsc75xx.c
1864
netdev_info(dev->net, "entering SUSPEND1 mode\n");
drivers/net/usb/smsc75xx.c
1867
ret = smsc75xx_mdio_read_nopm(dev->net, mii->phy_id,
drivers/net/usb/smsc75xx.c
187
netdev_warn(dev->net, "MII is busy in smsc75xx_mdio_read\n");
drivers/net/usb/smsc75xx.c
1870
netdev_warn(dev->net, "Error reading PHY_MODE_CTRL_STS\n");
drivers/net/usb/smsc75xx.c
1876
smsc75xx_mdio_write_nopm(dev->net, mii->phy_id,
drivers/net/usb/smsc75xx.c
1892
netdev_warn(dev->net, "Error writing WUF_CFGX\n");
drivers/net/usb/smsc75xx.c
1899
netdev_info(dev->net, "enabling multicast detection\n");
drivers/net/usb/smsc75xx.c
1905
netdev_warn(dev->net, "Error writing wakeup filter\n");
drivers/net/usb/smsc75xx.c
1912
netdev_info(dev->net, "enabling ARP detection\n");
drivers/net/usb/smsc75xx.c
1918
netdev_warn(dev->net, "Error writing wakeup filter\n");
drivers/net/usb/smsc75xx.c
1926
netdev_warn(dev->net, "Error reading WUCSR\n");
drivers/net/usb/smsc75xx.c
1934
netdev_warn(dev->net, "Error writing WUCSR\n");
drivers/net/usb/smsc75xx.c
1938
netdev_info(dev->net, "enabling packet match detection\n");
drivers/net/usb/smsc75xx.c
1941
netdev_warn(dev->net, "Error reading WUCSR\n");
drivers/net/usb/smsc75xx.c
1949
netdev_warn(dev->net, "Error writing WUCSR\n");
drivers/net/usb/smsc75xx.c
1953
netdev_info(dev->net, "disabling packet match detection\n");
drivers/net/usb/smsc75xx.c
1956
netdev_warn(dev->net, "Error reading WUCSR\n");
drivers/net/usb/smsc75xx.c
1964
netdev_warn(dev->net, "Error writing WUCSR\n");
drivers/net/usb/smsc75xx.c
1972
netdev_warn(dev->net, "Error reading WUCSR\n");
drivers/net/usb/smsc75xx.c
1980
netdev_warn(dev->net, "Error writing WUCSR\n");
drivers/net/usb/smsc75xx.c
1985
netdev_info(dev->net, "enabling PHY wakeup\n");
drivers/net/usb/smsc75xx.c
1989
netdev_warn(dev->net, "Error reading PMT_CTL\n");
drivers/net/usb/smsc75xx.c
199
netdev_warn(dev->net, "Error writing MII_ACCESS\n");
drivers/net/usb/smsc75xx.c
1999
netdev_warn(dev->net, "Error writing PMT_CTL\n");
drivers/net/usb/smsc75xx.c
2005
netdev_info(dev->net, "enabling magic packet wakeup\n");
drivers/net/usb/smsc75xx.c
2008
netdev_warn(dev->net, "Error reading WUCSR\n");
drivers/net/usb/smsc75xx.c
2017
netdev_warn(dev->net, "Error writing WUCSR\n");
drivers/net/usb/smsc75xx.c
2023
netdev_info(dev->net, "enabling broadcast detection\n");
drivers/net/usb/smsc75xx.c
2026
netdev_warn(dev->net, "Error reading WUCSR\n");
drivers/net/usb/smsc75xx.c
2034
netdev_warn(dev->net, "Error writing WUCSR\n");
drivers/net/usb/smsc75xx.c
2040
netdev_info(dev->net, "enabling unicast detection\n");
drivers/net/usb/smsc75xx.c
2043
netdev_warn(dev->net, "Error reading WUCSR\n");
drivers/net/usb/smsc75xx.c
205
netdev_warn(dev->net, "Timed out reading MII reg %02X\n", idx);
drivers/net/usb/smsc75xx.c
2051
netdev_warn(dev->net, "Error writing WUCSR\n");
drivers/net/usb/smsc75xx.c
2059
netdev_warn(dev->net, "Failed to read MAC_RX: %d\n", ret);
drivers/net/usb/smsc75xx.c
2067
netdev_warn(dev->net, "Failed to write MAC_RX: %d\n", ret);
drivers/net/usb/smsc75xx.c
2072
netdev_info(dev->net, "entering SUSPEND0 mode\n");
drivers/net/usb/smsc75xx.c
2093
netdev_dbg(dev->net, "resume suspend_flags=0x%02x\n", suspend_flags);
drivers/net/usb/smsc75xx.c
2102
netdev_warn(dev->net, "Error reading WUCSR\n");
drivers/net/usb/smsc75xx.c
211
netdev_warn(dev->net, "Error reading MII_DATA\n");
drivers/net/usb/smsc75xx.c
2111
netdev_warn(dev->net, "Error writing WUCSR\n");
drivers/net/usb/smsc75xx.c
2118
netdev_warn(dev->net, "Error reading PMT_CTL\n");
drivers/net/usb/smsc75xx.c
2127
netdev_warn(dev->net, "Error writing PMT_CTL\n");
drivers/net/usb/smsc75xx.c
2133
netdev_info(dev->net, "resuming from SUSPEND2\n");
drivers/net/usb/smsc75xx.c
2137
netdev_warn(dev->net, "Error reading PMT_CTL\n");
drivers/net/usb/smsc75xx.c
2145
netdev_warn(dev->net, "Error writing PMT_CTL\n");
drivers/net/usb/smsc75xx.c
2152
netdev_warn(dev->net, "device not ready in smsc75xx_resume\n");
drivers/net/usb/smsc75xx.c
2162
if (!(dev->net->features & NETIF_F_RXCSUM) ||
drivers/net/usb/smsc75xx.c
2174
if (skb->len < dev->net->hard_header_len)
drivers/net/usb/smsc75xx.c
2195
netif_dbg(dev, rx_err, dev->net,
drivers/net/usb/smsc75xx.c
2202
netif_dbg(dev, rx_err, dev->net,
drivers/net/usb/smsc75xx.c
2204
dev->net->stats.rx_errors++;
drivers/net/usb/smsc75xx.c
2205
dev->net->stats.rx_dropped++;
drivers/net/usb/smsc75xx.c
2208
dev->net->stats.rx_crc_errors++;
drivers/net/usb/smsc75xx.c
2210
dev->net->stats.rx_frame_errors++;
drivers/net/usb/smsc75xx.c
2214
netif_dbg(dev, rx_err, dev->net,
drivers/net/usb/smsc75xx.c
2231
ax_skb = netdev_alloc_skb_ip_align(dev->net, size - 4);
drivers/net/usb/smsc75xx.c
2233
netdev_warn(dev->net, "Error allocating skb\n");
drivers/net/usb/smsc75xx.c
234
netdev_warn(dev->net, "MII is busy in smsc75xx_mdio_write\n");
drivers/net/usb/smsc75xx.c
241
netdev_warn(dev->net, "Error writing MII_DATA\n");
drivers/net/usb/smsc75xx.c
253
netdev_warn(dev->net, "Error writing MII_ACCESS\n");
drivers/net/usb/smsc75xx.c
259
netdev_warn(dev->net, "Timed out writing MII reg %02X\n", idx);
drivers/net/usb/smsc75xx.c
299
netdev_warn(dev->net, "Error reading E2P_CMD\n");
drivers/net/usb/smsc75xx.c
309
netdev_warn(dev->net, "EEPROM read operation timeout\n");
drivers/net/usb/smsc75xx.c
325
netdev_warn(dev->net, "Error reading E2P_CMD\n");
drivers/net/usb/smsc75xx.c
335
netdev_warn(dev->net, "EEPROM is busy\n");
drivers/net/usb/smsc75xx.c
356
netdev_warn(dev->net, "Error writing E2P_CMD\n");
drivers/net/usb/smsc75xx.c
366
netdev_warn(dev->net, "Error reading E2P_DATA\n");
drivers/net/usb/smsc75xx.c
394
netdev_warn(dev->net, "Error writing E2P_CMD\n");
drivers/net/usb/smsc75xx.c
408
netdev_warn(dev->net, "Error writing E2P_DATA\n");
drivers/net/usb/smsc75xx.c
416
netdev_warn(dev->net, "Error writing E2P_CMD\n");
drivers/net/usb/smsc75xx.c
438
netdev_warn(dev->net, "Error reading DP_SEL\n");
drivers/net/usb/smsc75xx.c
448
netdev_warn(dev->net, "smsc75xx_dataport_wait_not_busy timed out\n");
drivers/net/usb/smsc75xx.c
464
netdev_warn(dev->net, "smsc75xx_dataport_write busy on entry\n");
drivers/net/usb/smsc75xx.c
470
netdev_warn(dev->net, "Error reading DP_SEL\n");
drivers/net/usb/smsc75xx.c
478
netdev_warn(dev->net, "Error writing DP_SEL\n");
drivers/net/usb/smsc75xx.c
485
netdev_warn(dev->net, "Error writing DP_ADDR\n");
drivers/net/usb/smsc75xx.c
491
netdev_warn(dev->net, "Error writing DP_DATA\n");
drivers/net/usb/smsc75xx.c
497
netdev_warn(dev->net, "Error writing DP_CMD\n");
drivers/net/usb/smsc75xx.c
503
netdev_warn(dev->net, "smsc75xx_dataport_write timeout\n");
drivers/net/usb/smsc75xx.c
526
netif_dbg(dev, drv, dev->net, "deferred multicast write 0x%08x\n",
drivers/net/usb/smsc75xx.c
534
netdev_warn(dev->net, "Error writing RFE_CRL\n");
drivers/net/usb/smsc75xx.c
553
if (dev->net->flags & IFF_PROMISC) {
drivers/net/usb/smsc75xx.c
554
netif_dbg(dev, drv, dev->net, "promiscuous mode enabled\n");
drivers/net/usb/smsc75xx.c
556
} else if (dev->net->flags & IFF_ALLMULTI) {
drivers/net/usb/smsc75xx.c
557
netif_dbg(dev, drv, dev->net, "receive all multicast enabled\n");
drivers/net/usb/smsc75xx.c
559
} else if (!netdev_mc_empty(dev->net)) {
drivers/net/usb/smsc75xx.c
562
netif_dbg(dev, drv, dev->net, "receive multicast hash filter\n");
drivers/net/usb/smsc75xx.c
572
netif_dbg(dev, drv, dev->net, "receive own packets only\n");
drivers/net/usb/smsc75xx.c
600
netif_dbg(dev, link, dev->net, "rx pause %s, tx pause %s\n",
drivers/net/usb/smsc75xx.c
604
netif_dbg(dev, link, dev->net, "half duplex\n");
drivers/net/usb/smsc75xx.c
609
netdev_warn(dev->net, "Error writing FLOW\n");
drivers/net/usb/smsc75xx.c
615
netdev_warn(dev->net, "Error writing FCT_FLOW\n");
drivers/net/usb/smsc75xx.c
630
smsc75xx_mdio_write(dev->net, mii->phy_id, PHY_INT_SRC,
drivers/net/usb/smsc75xx.c
635
netdev_warn(dev->net, "Error writing INT_STS\n");
drivers/net/usb/smsc75xx.c
641
lcladv = smsc75xx_mdio_read(dev->net, mii->phy_id, MII_ADVERTISE);
drivers/net/usb/smsc75xx.c
642
rmtadv = smsc75xx_mdio_read(dev->net, mii->phy_id, MII_LPA);
drivers/net/usb/smsc75xx.c
644
netif_dbg(dev, link, dev->net, "speed: %u duplex: %d lcladv: %04x rmtadv: %04x\n",
drivers/net/usb/smsc75xx.c
655
netdev_warn(dev->net, "unexpected urb length %d\n",
drivers/net/usb/smsc75xx.c
662
netif_dbg(dev, link, dev->net, "intdata: 0x%08X\n", intdata);
drivers/net/usb/smsc75xx.c
667
netdev_warn(dev->net, "unexpected interrupt, intdata=0x%08X\n",
drivers/net/usb/smsc75xx.c
671
static int smsc75xx_ethtool_get_eeprom_len(struct net_device *net)
drivers/net/usb/smsc75xx.c
692
netdev_warn(dev->net, "EEPROM: magic value mismatch: 0x%x\n",
drivers/net/usb/smsc75xx.c
700
static void smsc75xx_ethtool_get_wol(struct net_device *net,
drivers/net/usb/smsc75xx.c
703
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/smsc75xx.c
710
static int smsc75xx_ethtool_set_wol(struct net_device *net,
drivers/net/usb/smsc75xx.c
713
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/smsc75xx.c
724
netdev_warn(dev->net, "device_set_wakeup_enable error %d\n", ret);
drivers/net/usb/smsc75xx.c
757
if (!platform_get_ethdev_address(&dev->udev->dev, dev->net)) {
drivers/net/usb/smsc75xx.c
758
if (is_valid_ether_addr(dev->net->dev_addr)) {
drivers/net/usb/smsc75xx.c
760
netif_dbg(dev, ifup, dev->net, "MAC address read from the device tree\n");
drivers/net/usb/smsc75xx.c
767
eth_hw_addr_set(dev->net, addr);
drivers/net/usb/smsc75xx.c
768
if (is_valid_ether_addr(dev->net->dev_addr)) {
drivers/net/usb/smsc75xx.c
770
netif_dbg(dev, ifup, dev->net,
drivers/net/usb/smsc75xx.c
777
eth_hw_addr_random(dev->net);
drivers/net/usb/smsc75xx.c
778
netif_dbg(dev, ifup, dev->net, "MAC address set to eth_random_addr\n");
drivers/net/usb/smsc75xx.c
783
u32 addr_lo = dev->net->dev_addr[0] | dev->net->dev_addr[1] << 8 |
drivers/net/usb/smsc75xx.c
784
dev->net->dev_addr[2] << 16 | dev->net->dev_addr[3] << 24;
drivers/net/usb/smsc75xx.c
785
u32 addr_hi = dev->net->dev_addr[4] | dev->net->dev_addr[5] << 8;
drivers/net/usb/smsc75xx.c
789
netdev_warn(dev->net, "Failed to write RX_ADDRH: %d\n", ret);
drivers/net/usb/smsc75xx.c
795
netdev_warn(dev->net, "Failed to write RX_ADDRL: %d\n", ret);
drivers/net/usb/smsc75xx.c
802
netdev_warn(dev->net, "Failed to write ADDR_FILTX: %d\n", ret);
drivers/net/usb/smsc75xx.c
808
netdev_warn(dev->net, "Failed to write ADDR_FILTX+4: %d\n", ret);
drivers/net/usb/smsc75xx.c
818
dev->mii.dev = dev->net;
drivers/net/usb/smsc75xx.c
827
smsc75xx_mdio_write(dev->net, dev->mii.phy_id, MII_BMCR, BMCR_RESET);
drivers/net/usb/smsc75xx.c
831
bmcr = smsc75xx_mdio_read(dev->net, dev->mii.phy_id, MII_BMCR);
drivers/net/usb/smsc75xx.c
833
netdev_warn(dev->net, "Error reading MII_BMCR\n");
drivers/net/usb/smsc75xx.c
840
netdev_warn(dev->net, "timeout on PHY Reset\n");
drivers/net/usb/smsc75xx.c
847
smsc75xx_mdio_write(dev->net, dev->mii.phy_id, MII_ADVERTISE,
drivers/net/usb/smsc75xx.c
850
smsc75xx_mdio_write(dev->net, dev->mii.phy_id, MII_CTRL1000,
drivers/net/usb/smsc75xx.c
854
ret = smsc75xx_mdio_read(dev->net, dev->mii.phy_id, PHY_INT_SRC);
drivers/net/usb/smsc75xx.c
856
netdev_warn(dev->net, "Error reading PHY_INT_SRC\n");
drivers/net/usb/smsc75xx.c
860
smsc75xx_mdio_write(dev->net, dev->mii.phy_id, PHY_INT_SRC, 0xffff);
drivers/net/usb/smsc75xx.c
862
smsc75xx_mdio_write(dev->net, dev->mii.phy_id, PHY_INT_MASK,
drivers/net/usb/smsc75xx.c
866
netif_dbg(dev, ifup, dev->net, "phy initialised successfully\n");
drivers/net/usb/smsc75xx.c
878
netdev_warn(dev->net, "Failed to read MAC_RX: %d\n", ret);
drivers/net/usb/smsc75xx.c
888
netdev_warn(dev->net, "Failed to write MAC_RX: %d\n", ret);
drivers/net/usb/smsc75xx.c
899
netdev_warn(dev->net, "Failed to write MAC_RX: %d\n", ret);
drivers/net/usb/smsc75xx.c
90
netdev_warn(dev->net, "Failed to read reg index 0x%08x: %d\n",
drivers/net/usb/smsc75xx.c
907
netdev_warn(dev->net, "Failed to write MAC_RX: %d\n", ret);
drivers/net/usb/smsc75xx.c
922
netdev_warn(dev->net, "Failed to set mac rx frame length\n");
drivers/net/usb/smsc75xx.c
950
netdev_warn(dev->net, "Error writing RFE_CTL\n");
drivers/net/usb/smsc75xx.c
967
netdev_warn(dev->net, "Failed to read PMT_CTL: %d\n", ret);
drivers/net/usb/smsc75xx.c
978
netdev_warn(dev->net, "timeout waiting for device ready\n");
drivers/net/usb/smsc75xx.c
989
smsc75xx_mdio_write(dev->net, mii->phy_id, MII_BMCR, 0x4040);
drivers/net/usb/smsc75xx.c
999
netdev_warn(dev->net, "Timeout waiting for PHY link up\n");
drivers/net/usb/smsc95xx.c
1007
netif_dbg(dev, ifup, dev->net,
drivers/net/usb/smsc95xx.c
1019
netif_dbg(dev, ifup, dev->net,
drivers/net/usb/smsc95xx.c
1027
netif_dbg(dev, ifup, dev->net, "Read Value from HW_CFG: 0x%08x\n",
drivers/net/usb/smsc95xx.c
104
netdev_warn(dev->net, "Failed to read reg index 0x%08x: %d\n",
drivers/net/usb/smsc95xx.c
1046
netif_dbg(dev, ifup, dev->net,
drivers/net/usb/smsc95xx.c
1056
netif_dbg(dev, ifup, dev->net, "ID_REV = 0x%08x\n", read_buf);
drivers/net/usb/smsc95xx.c
1089
ret = smsc95xx_set_features(dev->net, dev->net->features);
drivers/net/usb/smsc95xx.c
1091
netdev_warn(dev->net, "Failed to set checksum offload features\n");
drivers/net/usb/smsc95xx.c
1095
smsc95xx_set_multicast(dev->net);
drivers/net/usb/smsc95xx.c
1110
netdev_warn(dev->net, "Failed to start TX path\n");
drivers/net/usb/smsc95xx.c
1116
netdev_warn(dev->net, "Failed to start RX path\n");
drivers/net/usb/smsc95xx.c
1120
netif_dbg(dev, ifup, dev->net, "smsc95xx_reset, return 0\n");
drivers/net/usb/smsc95xx.c
1138
static void smsc95xx_handle_link_change(struct net_device *net)
drivers/net/usb/smsc95xx.c
1140
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/smsc95xx.c
1142
phy_print_status(net->phydev);
drivers/net/usb/smsc95xx.c
1156
netdev_warn(dev->net, "usbnet_get_endpoints failed: %d\n", ret);
drivers/net/usb/smsc95xx.c
1176
dev->net->features |= NETIF_F_IP_CSUM;
drivers/net/usb/smsc95xx.c
1178
dev->net->features |= NETIF_F_RXCSUM;
drivers/net/usb/smsc95xx.c
1180
dev->net->hw_features = NETIF_F_IP_CSUM | NETIF_F_RXCSUM;
drivers/net/usb/smsc95xx.c
1244
netdev_err(dev->net, "Could not register MDIO bus\n");
drivers/net/usb/smsc95xx.c
1250
netdev_err(dev->net, "no PHY found\n");
drivers/net/usb/smsc95xx.c
1272
dev->net->netdev_ops = &smsc95xx_netdev_ops;
drivers/net/usb/smsc95xx.c
1273
dev->net->ethtool_ops = &smsc95xx_ethtool_ops;
drivers/net/usb/smsc95xx.c
1274
dev->net->flags |= IFF_MULTICAST;
drivers/net/usb/smsc95xx.c
1275
dev->net->hard_header_len += SMSC95XX_TX_OVERHEAD_CSUM;
drivers/net/usb/smsc95xx.c
1276
dev->net->min_mtu = ETH_MIN_MTU;
drivers/net/usb/smsc95xx.c
1277
dev->net->max_mtu = ETH_DATA_LEN;
drivers/net/usb/smsc95xx.c
1278
dev->hard_mtu = dev->net->mtu + dev->net->hard_header_len;
drivers/net/usb/smsc95xx.c
1285
ret = phy_connect_direct(dev->net, pdata->phydev,
drivers/net/usb/smsc95xx.c
1289
netdev_err(dev->net, "can't attach PHY to %s\n", pdata->mdiobus->id);
drivers/net/usb/smsc95xx.c
1293
phy_attached_info(dev->net->phydev);
drivers/net/usb/smsc95xx.c
1321
phy_disconnect(dev->net->phydev);
drivers/net/usb/smsc95xx.c
1327
netif_dbg(dev, ifdown, dev->net, "free pdata\n");
drivers/net/usb/smsc95xx.c
1333
phy_start(dev->net->phydev);
drivers/net/usb/smsc95xx.c
1340
phy_stop(dev->net->phydev);
drivers/net/usb/smsc95xx.c
135
netdev_warn(dev->net, "Failed to write reg index 0x%08x: %d\n",
drivers/net/usb/smsc95xx.c
1487
netdev_info(dev->net, "rx fifo not empty in autosuspend\n");
drivers/net/usb/smsc95xx.c
1519
if (!netif_running(dev->net)) {
drivers/net/usb/smsc95xx.c
1521
netdev_dbg(dev->net, "autosuspend entering SUSPEND2\n");
drivers/net/usb/smsc95xx.c
1531
netdev_warn(dev->net, "EDPD not supported\n");
drivers/net/usb/smsc95xx.c
1535
netdev_dbg(dev->net, "autosuspend entering SUSPEND1\n");
drivers/net/usb/smsc95xx.c
1536
netdev_info(dev->net, "entering SUSPEND1 mode\n");
drivers/net/usb/smsc95xx.c
1540
netdev_dbg(dev->net, "autosuspend entering SUSPEND3\n");
drivers/net/usb/smsc95xx.c
155
netdev_warn(dev->net, "Error reading MII_ACCESS\n");
drivers/net/usb/smsc95xx.c
1555
netdev_warn(dev->net, "usbnet_suspend error\n");
drivers/net/usb/smsc95xx.c
1561
netdev_warn(dev->net, "error during last resume\n");
drivers/net/usb/smsc95xx.c
1579
netdev_info(dev->net, "entering SUSPEND2 mode\n");
drivers/net/usb/smsc95xx.c
1611
netdev_info(dev->net, "entering SUSPEND1 mode\n");
drivers/net/usb/smsc95xx.c
1628
netdev_warn(dev->net, "Unable to allocate filter_mask\n");
drivers/net/usb/smsc95xx.c
1639
netdev_info(dev->net, "enabling broadcast detection\n");
drivers/net/usb/smsc95xx.c
1652
netdev_info(dev->net, "enabling multicast detection\n");
drivers/net/usb/smsc95xx.c
1665
netdev_info(dev->net, "enabling ARP detection\n");
drivers/net/usb/smsc95xx.c
1677
netdev_info(dev->net, "enabling unicast detection\n");
drivers/net/usb/smsc95xx.c
1684
crc[filter/2] |= smsc_crc(dev->net->dev_addr, ETH_ALEN, filter);
drivers/net/usb/smsc95xx.c
1746
netdev_info(dev->net, "enabling pattern match wakeup\n");
drivers/net/usb/smsc95xx.c
1749
netdev_info(dev->net, "disabling pattern match wakeup\n");
drivers/net/usb/smsc95xx.c
1754
netdev_info(dev->net, "enabling magic packet wakeup\n");
drivers/net/usb/smsc95xx.c
1757
netdev_info(dev->net, "disabling magic packet wakeup\n");
drivers/net/usb/smsc95xx.c
1784
netdev_info(dev->net, "entering SUSPEND0 mode\n");
drivers/net/usb/smsc95xx.c
181
netdev_warn(dev->net, "%s: MII is busy\n", __func__);
drivers/net/usb/smsc95xx.c
1811
netdev_dbg(dev->net, "resume suspend_flags=0x%02x\n", suspend_flags);
drivers/net/usb/smsc95xx.c
1847
netdev_warn(dev->net, "usbnet_resume error\n");
drivers/net/usb/smsc95xx.c
1881
if (skb->len < dev->net->hard_header_len)
drivers/net/usb/smsc95xx.c
1899
netif_dbg(dev, rx_err, dev->net,
drivers/net/usb/smsc95xx.c
190
netdev_warn(dev->net, "Error writing MII_ADDR\n");
drivers/net/usb/smsc95xx.c
1905
netif_dbg(dev, rx_err, dev->net,
drivers/net/usb/smsc95xx.c
1907
dev->net->stats.rx_errors++;
drivers/net/usb/smsc95xx.c
1908
dev->net->stats.rx_dropped++;
drivers/net/usb/smsc95xx.c
1911
dev->net->stats.rx_crc_errors++;
drivers/net/usb/smsc95xx.c
1914
dev->net->stats.rx_frame_errors++;
drivers/net/usb/smsc95xx.c
1918
dev->net->stats.rx_length_errors++;
drivers/net/usb/smsc95xx.c
1923
netif_dbg(dev, rx_err, dev->net,
drivers/net/usb/smsc95xx.c
1930
if (dev->net->features & NETIF_F_RXCSUM)
drivers/net/usb/smsc95xx.c
1937
ax_skb = netdev_alloc_skb_ip_align(dev->net, size);
drivers/net/usb/smsc95xx.c
1939
netdev_warn(dev->net, "Error allocating skb\n");
drivers/net/usb/smsc95xx.c
1946
if (dev->net->features & NETIF_F_RXCSUM)
drivers/net/usb/smsc95xx.c
196
netdev_warn(dev->net, "Timed out reading MII reg %02X\n", idx);
drivers/net/usb/smsc95xx.c
203
netdev_warn(dev->net, "Error reading MII_DATA\n");
drivers/net/usb/smsc95xx.c
2049
netdev_info(dev->net, "hardware isn't capable of remote wakeup\n");
drivers/net/usb/smsc95xx.c
229
netdev_warn(dev->net, "%s: MII is busy\n", __func__);
drivers/net/usb/smsc95xx.c
237
netdev_warn(dev->net, "Error writing MII_DATA\n");
drivers/net/usb/smsc95xx.c
246
netdev_warn(dev->net, "Error writing MII_ADDR\n");
drivers/net/usb/smsc95xx.c
252
netdev_warn(dev->net, "Timed out writing MII reg %02X\n", idx);
drivers/net/usb/smsc95xx.c
322
netdev_warn(dev->net, "Error reading E2P_CMD\n");
drivers/net/usb/smsc95xx.c
332
netdev_warn(dev->net, "EEPROM read operation timeout\n");
drivers/net/usb/smsc95xx.c
348
netdev_warn(dev->net, "Error reading E2P_CMD\n");
drivers/net/usb/smsc95xx.c
358
netdev_warn(dev->net, "EEPROM is busy\n");
drivers/net/usb/smsc95xx.c
379
netdev_warn(dev->net, "Error writing E2P_CMD\n");
drivers/net/usb/smsc95xx.c
389
netdev_warn(dev->net, "Error reading E2P_DATA\n");
drivers/net/usb/smsc95xx.c
417
netdev_warn(dev->net, "Error writing E2P_DATA\n");
drivers/net/usb/smsc95xx.c
431
netdev_warn(dev->net, "Error writing E2P_DATA\n");
drivers/net/usb/smsc95xx.c
439
netdev_warn(dev->net, "Error writing E2P_CMD\n");
drivers/net/usb/smsc95xx.c
468
netdev_warn(dev->net, "Error write async cmd, sts=%d\n",
drivers/net/usb/smsc95xx.c
493
if (dev->net->flags & IFF_PROMISC) {
drivers/net/usb/smsc95xx.c
494
netif_dbg(dev, drv, dev->net, "promiscuous mode enabled\n");
drivers/net/usb/smsc95xx.c
497
} else if (dev->net->flags & IFF_ALLMULTI) {
drivers/net/usb/smsc95xx.c
498
netif_dbg(dev, drv, dev->net, "receive all multicast enabled\n");
drivers/net/usb/smsc95xx.c
501
} else if (!netdev_mc_empty(dev->net)) {
drivers/net/usb/smsc95xx.c
516
netif_dbg(dev, drv, dev->net, "HASHH=0x%08X, HASHL=0x%08X\n",
drivers/net/usb/smsc95xx.c
519
netif_dbg(dev, drv, dev->net, "receive own packets only\n");
drivers/net/usb/smsc95xx.c
529
netdev_warn(dev->net, "failed to initiate async write to HASHH\n");
drivers/net/usb/smsc95xx.c
533
netdev_warn(dev->net, "failed to initiate async write to HASHL\n");
drivers/net/usb/smsc95xx.c
537
netdev_warn(dev->net, "failed to initiate async write to MAC_CR\n");
drivers/net/usb/smsc95xx.c
570
netif_dbg(dev, link, dev->net, "rx pause %s, tx pause %s\n",
drivers/net/usb/smsc95xx.c
574
netif_dbg(dev, link, dev->net, "half duplex\n");
drivers/net/usb/smsc95xx.c
604
netdev_warn(dev->net,
drivers/net/usb/smsc95xx.c
611
netdev_warn(dev->net, "Error updating PHY flow control\n");
drivers/net/usb/smsc95xx.c
621
netdev_warn(dev->net, "unexpected urb length %d\n",
drivers/net/usb/smsc95xx.c
627
netif_dbg(dev, link, dev->net, "intdata: 0x%08X\n", intdata);
drivers/net/usb/smsc95xx.c
634
netdev_warn(dev->net, "unexpected interrupt, intdata=0x%08X\n",
drivers/net/usb/smsc95xx.c
666
netif_dbg(dev, hw, dev->net, "COE_CR = 0x%08x\n", read_buf);
drivers/net/usb/smsc95xx.c
670
static int smsc95xx_ethtool_get_eeprom_len(struct net_device *net)
drivers/net/usb/smsc95xx.c
691
netdev_warn(dev->net, "EEPROM: magic value mismatch, magic = 0x%x\n",
drivers/net/usb/smsc95xx.c
729
static void smsc95xx_ethtool_get_wol(struct net_device *net,
drivers/net/usb/smsc95xx.c
732
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/smsc95xx.c
739
static int smsc95xx_ethtool_set_wol(struct net_device *net,
drivers/net/usb/smsc95xx.c
742
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/smsc95xx.c
753
netdev_warn(dev->net, "device_set_wakeup_enable error %d\n", ret);
drivers/net/usb/smsc95xx.c
758
static u32 smsc95xx_get_link(struct net_device *net)
drivers/net/usb/smsc95xx.c
760
phy_read_status(net->phydev);
drivers/net/usb/smsc95xx.c
761
return net->phydev->link;
drivers/net/usb/smsc95xx.c
861
if (!platform_get_ethdev_address(&dev->udev->dev, dev->net)) {
drivers/net/usb/smsc95xx.c
862
if (is_valid_ether_addr(dev->net->dev_addr)) {
drivers/net/usb/smsc95xx.c
864
netif_dbg(dev, ifup, dev->net, "MAC address read from the device tree\n");
drivers/net/usb/smsc95xx.c
871
eth_hw_addr_set(dev->net, addr);
drivers/net/usb/smsc95xx.c
872
if (is_valid_ether_addr(dev->net->dev_addr)) {
drivers/net/usb/smsc95xx.c
874
netif_dbg(dev, ifup, dev->net, "MAC address read from EEPROM\n");
drivers/net/usb/smsc95xx.c
880
eth_hw_addr_random(dev->net);
drivers/net/usb/smsc95xx.c
881
netif_dbg(dev, ifup, dev->net, "MAC address set to eth_random_addr\n");
drivers/net/usb/smsc95xx.c
886
u32 addr_lo = dev->net->dev_addr[0] | dev->net->dev_addr[1] << 8 |
drivers/net/usb/smsc95xx.c
887
dev->net->dev_addr[2] << 16 | dev->net->dev_addr[3] << 24;
drivers/net/usb/smsc95xx.c
888
u32 addr_hi = dev->net->dev_addr[4] | dev->net->dev_addr[5] << 8;
drivers/net/usb/smsc95xx.c
937
netif_dbg(dev, ifup, dev->net, "entering smsc95xx_reset\n");
drivers/net/usb/smsc95xx.c
953
netdev_warn(dev->net, "timeout waiting for completion of Lite Reset\n");
drivers/net/usb/smsc95xx.c
961
netif_dbg(dev, ifup, dev->net, "MAC Address: %pM\n",
drivers/net/usb/smsc95xx.c
962
dev->net->dev_addr);
drivers/net/usb/smsc95xx.c
968
netif_dbg(dev, ifup, dev->net, "Read Value from HW_CFG : 0x%08x\n",
drivers/net/usb/smsc95xx.c
981
netif_dbg(dev, ifup, dev->net,
drivers/net/usb/smsc95xx.c
996
netif_dbg(dev, ifup, dev->net, "rx_urb_size=%ld\n",
drivers/net/usb/sr9700.c
109
netdev_dbg(dev->net, "read eeprom 0x%02x returned 0x%04x, %d\n",
drivers/net/usb/sr9700.c
284
netdev = dev->net;
drivers/net/usb/sr9700.c
346
netdev_err(dev->net, "unexpected tiny rx frame\n");
drivers/net/usb/sr9700.c
369
sr_skb = netdev_alloc_skb_ip_align(dev->net, len);
drivers/net/usb/sr9700.c
442
sr9700_handle_link_change(dev->net, link);
drivers/net/usb/sr9700.c
88
netdev_err(dev->net, "eeprom write timed out!\n");
drivers/net/usb/sr9800.c
102
netdev_err(dev->net, "%s : Bad SKB Length %d\n", __func__,
drivers/net/usb/sr9800.c
160
if (netif_carrier_ok(dev->net) != link) {
drivers/net/usb/sr9800.c
162
netdev_dbg(dev->net, "Link Status is: %d\n", link);
drivers/net/usb/sr9800.c
174
netdev_err(dev->net, "Failed to enable software MII access\n");
drivers/net/usb/sr9800.c
184
netdev_err(dev->net, "Failed to enable hardware MII access\n");
drivers/net/usb/sr9800.c
195
netdev_err(dev->net, "%s : Error reading PHYID register:%02x\n",
drivers/net/usb/sr9800.c
199
netdev_dbg(dev->net, "%s : returning 0x%04x\n", __func__,
drivers/net/usb/sr9800.c
214
netdev_err(dev->net, "Failed to send software reset:%02x\n",
drivers/net/usb/sr9800.c
227
netdev_err(dev->net, "Error reading RX_CTL register:%02x\n",
drivers/net/usb/sr9800.c
241
netdev_dbg(dev->net, "%s : mode = 0x%04x\n", __func__, mode);
drivers/net/usb/sr9800.c
244
netdev_err(dev->net,
drivers/net/usb/sr9800.c
258
netdev_err(dev->net,
drivers/net/usb/sr9800.c
270
netdev_dbg(dev->net, "%s : mode = 0x%04x\n", __func__, mode);
drivers/net/usb/sr9800.c
273
netdev_err(dev->net,
drivers/net/usb/sr9800.c
283
netdev_dbg(dev->net, "%s : value = 0x%04x\n", __func__, value);
drivers/net/usb/sr9800.c
286
netdev_err(dev->net, "Failed to write GPIO value 0x%04x:%02x\n",
drivers/net/usb/sr9800.c
295
static void sr_set_multicast(struct net_device *net)
drivers/net/usb/sr9800.c
297
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/sr9800.c
301
if (net->flags & IFF_PROMISC) {
drivers/net/usb/sr9800.c
303
} else if (net->flags & IFF_ALLMULTI ||
drivers/net/usb/sr9800.c
304
netdev_mc_count(net) > SR_MAX_MCAST) {
drivers/net/usb/sr9800.c
306
} else if (netdev_mc_empty(net)) {
drivers/net/usb/sr9800.c
320
netdev_for_each_mc_addr(ha, net) {
drivers/net/usb/sr9800.c
335
static int sr_mdio_read(struct net_device *net, int phy_id, int loc)
drivers/net/usb/sr9800.c
337
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/sr9800.c
346
netdev_dbg(dev->net,
drivers/net/usb/sr9800.c
354
sr_mdio_write(struct net_device *net, int phy_id, int loc, int val)
drivers/net/usb/sr9800.c
356
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/sr9800.c
359
netdev_dbg(dev->net,
drivers/net/usb/sr9800.c
378
phy_reg = sr_mdio_read(dev->net, dev->mii.phy_id, MII_PHYSID1);
drivers/net/usb/sr9800.c
389
phy_reg = sr_mdio_read(dev->net, dev->mii.phy_id, MII_PHYSID2);
drivers/net/usb/sr9800.c
399
sr_get_wol(struct net_device *net, struct ethtool_wolinfo *wolinfo)
drivers/net/usb/sr9800.c
401
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/sr9800.c
418
sr_set_wol(struct net_device *net, struct ethtool_wolinfo *wolinfo)
drivers/net/usb/sr9800.c
420
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/sr9800.c
438
static int sr_get_eeprom_len(struct net_device *net)
drivers/net/usb/sr9800.c
440
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/sr9800.c
446
static int sr_get_eeprom(struct net_device *net,
drivers/net/usb/sr9800.c
449
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/sr9800.c
472
static int sr_set_mac_address(struct net_device *net, void *p)
drivers/net/usb/sr9800.c
474
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/sr9800.c
478
if (netif_running(net))
drivers/net/usb/sr9800.c
483
eth_hw_addr_set(net, addr->sa_data);
drivers/net/usb/sr9800.c
526
netdev_dbg(dev->net, "%s : speed: %u duplex: %d mode: 0x%04x\n",
drivers/net/usb/sr9800.c
540
sr_mdio_write(dev->net, dev->mii.phy_id, MII_BMCR, BMCR_RESET);
drivers/net/usb/sr9800.c
541
sr_mdio_write(dev->net, dev->mii.phy_id, MII_ADVERTISE,
drivers/net/usb/sr9800.c
553
netdev_dbg(dev->net, "Write IPG,IPG1,IPG2 failed: %d\n", ret);
drivers/net/usb/sr9800.c
563
netdev_dbg(dev->net, "RX_CTL is 0x%04x after all initializations\n",
drivers/net/usb/sr9800.c
567
netdev_dbg(dev->net, "Medium Status:0x%04x after all initializations\n",
drivers/net/usb/sr9800.c
590
netdev_dbg(dev->net, "Select PHY #1 failed: %d\n", ret);
drivers/net/usb/sr9800.c
618
netdev_dbg(dev->net, "RX_CTL is 0x%04x after software reset\n", rx_ctl);
drivers/net/usb/sr9800.c
624
netdev_dbg(dev->net, "RX_CTL is 0x%04x setting to 0x0000\n", rx_ctl);
drivers/net/usb/sr9800.c
643
memcpy(data->mac_addr, dev->net->dev_addr, ETH_ALEN);
drivers/net/usb/sr9800.c
67
if (skb->len < dev->net->hard_header_len)
drivers/net/usb/sr9800.c
675
netdev_err(dev->net, "Failed to power down PHY : %d\n", ret);
drivers/net/usb/sr9800.c
683
netdev_err(dev->net, "Failed to reset PHY: %d\n", ret);
drivers/net/usb/sr9800.c
691
netdev_err(dev->net, "Failed to power up PHY: %d\n", ret);
drivers/net/usb/sr9800.c
699
netdev_err(dev->net, "Failed to reset PHY: %d\n", ret);
drivers/net/usb/sr9800.c
732
netdev_err(dev->net, "set LINK LED failed : %d\n", ret);
drivers/net/usb/sr9800.c
739
netdev_dbg(dev->net, "Failed to read MAC address: %d\n", ret);
drivers/net/usb/sr9800.c
742
eth_hw_addr_set(dev->net, addr);
drivers/net/usb/sr9800.c
743
netdev_dbg(dev->net, "mac addr : %pM\n", dev->net->dev_addr);
drivers/net/usb/sr9800.c
746
dev->mii.dev = dev->net;
drivers/net/usb/sr9800.c
753
dev->net->netdev_ops = &sr9800_netdev_ops;
drivers/net/usb/sr9800.c
754
dev->net->ethtool_ops = &sr9800_ethtool_ops;
drivers/net/usb/sr9800.c
760
netdev_dbg(dev->net, "Select PHY #1 failed: %d\n", ret);
drivers/net/usb/sr9800.c
770
netdev_dbg(dev->net, "RX_CTL is 0x%04x after software reset\n", rx_ctl);
drivers/net/usb/sr9800.c
776
netdev_dbg(dev->net, "RX_CTL is 0x%04x setting to 0x0000\n", rx_ctl);
drivers/net/usb/sr9800.c
780
netdev_dbg(dev->net, "PHYID=0x%08x\n", phyid);
drivers/net/usb/sr9800.c
79
netdev_err(dev->net, "%s : Bad Header Length\n",
drivers/net/usb/sr9800.c
793
netdev_err(dev->net, "Reset RX_CTL failed: %d\n", ret);
drivers/net/usb/sr9800.c
804
netdev_err(dev->net, "Reset RX_CTL failed: %d\n", ret);
drivers/net/usb/sr9800.c
810
netdev_dbg(dev->net, "%s : setting rx_urb_size with : %zu\n", __func__,
drivers/net/usb/sr9800.c
84
if ((size > dev->net->mtu + ETH_HLEN + VLAN_HLEN) ||
drivers/net/usb/sr9800.c
86
netdev_err(dev->net, "%s : Bad RX Length %d\n",
drivers/net/usb/sr9800.c
90
sr_skb = netdev_alloc_skb_ip_align(dev->net, size);
drivers/net/usb/usbnet.c
1007
int usbnet_get_link_ksettings_internal(struct net_device *net,
drivers/net/usb/usbnet.c
1010
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/usbnet.c
1035
int usbnet_set_link_ksettings_mii(struct net_device *net,
drivers/net/usb/usbnet.c
1038
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/usbnet.c
1057
u32 usbnet_get_link(struct net_device *net)
drivers/net/usb/usbnet.c
1059
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/usbnet.c
1070
return ethtool_op_get_link(net);
drivers/net/usb/usbnet.c
1074
int usbnet_nway_reset(struct net_device *net)
drivers/net/usb/usbnet.c
1076
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/usbnet.c
1085
int usbnet_mii_ioctl(struct net_device *net, struct ifreq *rq, int cmd)
drivers/net/usb/usbnet.c
1087
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/usbnet.c
1093
void usbnet_get_drvinfo(struct net_device *net, struct ethtool_drvinfo *info)
drivers/net/usb/usbnet.c
1095
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/usbnet.c
1104
u32 usbnet_get_msglevel(struct net_device *net)
drivers/net/usb/usbnet.c
1106
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/usbnet.c
1112
void usbnet_set_msglevel(struct net_device *net, u32 level)
drivers/net/usb/usbnet.c
1114
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/usbnet.c
1140
netif_carrier_on(dev->net);
drivers/net/usb/usbnet.c
1142
if (!netif_carrier_ok(dev->net)) {
drivers/net/usb/usbnet.c
1161
void usbnet_set_rx_mode(struct net_device *net)
drivers/net/usb/usbnet.c
1163
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/usbnet.c
1202
netdev_err(dev->net, "can't clear tx halt, status %d\n",
drivers/net/usb/usbnet.c
1207
netif_wake_queue(dev->net);
drivers/net/usb/usbnet.c
1222
netdev_err(dev->net, "can't clear rx halt, status %d\n",
drivers/net/usb/usbnet.c
1236
if (netif_running(dev->net))
drivers/net/usb/usbnet.c
1268
netdev_info(dev->net, "link reset failed (%d) usbnet usb-%s-%s, %s\n",
drivers/net/usb/usbnet.c
1289
netdev_dbg(dev->net, "kevent done, flags = 0x%lx\n", dev->flags);
drivers/net/usb/usbnet.c
1301
struct pcpu_sw_netstats *stats64 = this_cpu_ptr(dev->net->tstats);
drivers/net/usb/usbnet.c
1309
dev->net->stats.tx_errors++;
drivers/net/usb/usbnet.c
1331
netif_dbg(dev, link, dev->net,
drivers/net/usb/usbnet.c
1334
netif_stop_queue(dev->net);
drivers/net/usb/usbnet.c
1337
netif_dbg(dev, tx_err, dev->net,
drivers/net/usb/usbnet.c
1349
void usbnet_tx_timeout(struct net_device *net, unsigned int txqueue)
drivers/net/usb/usbnet.c
1351
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/usbnet.c
1398
netdev_tx_t usbnet_start_xmit(struct sk_buff *skb, struct net_device *net)
drivers/net/usb/usbnet.c
1400
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/usbnet.c
1419
netif_dbg(dev, tx_err, dev->net, "can't tx_fixup skb\n");
drivers/net/usb/usbnet.c
1426
netif_dbg(dev, tx_err, dev->net, "no urb\n");
drivers/net/usb/usbnet.c
1483
if (netif_queue_stopped(net)) {
drivers/net/usb/usbnet.c
1495
netif_stop_queue(net);
drivers/net/usb/usbnet.c
1498
netdev_dbg(dev->net, "Delaying transmission for resumption\n");
drivers/net/usb/usbnet.c
1505
netif_stop_queue(net);
drivers/net/usb/usbnet.c
1511
netif_dbg(dev, tx_err, dev->net,
drivers/net/usb/usbnet.c
1515
netif_trans_update(net);
drivers/net/usb/usbnet.c
1517
netdev_sent_queue(net, skb->len);
drivers/net/usb/usbnet.c
1519
netif_stop_queue (net);
drivers/net/usb/usbnet.c
1524
netif_dbg(dev, tx_err, dev->net, "drop, code %d\n", retval);
drivers/net/usb/usbnet.c
1526
dev->net->stats.tx_dropped++;
drivers/net/usb/usbnet.c
1535
netif_dbg(dev, tx_queued, dev->net,
drivers/net/usb/usbnet.c
1601
netdev_dbg(dev->net, "bogus skb state %d\n", entry->state);
drivers/net/usb/usbnet.c
1606
netdev_completed_queue(dev->net, pkts_compl, bytes_compl);
drivers/net/usb/usbnet.c
1620
} else if (netif_running (dev->net) &&
drivers/net/usb/usbnet.c
1621
netif_device_present (dev->net) &&
drivers/net/usb/usbnet.c
1622
netif_carrier_ok(dev->net) &&
drivers/net/usb/usbnet.c
1633
netif_dbg(dev, link, dev->net,
drivers/net/usb/usbnet.c
1640
netif_wake_queue(dev->net);
drivers/net/usb/usbnet.c
1664
struct net_device *net;
drivers/net/usb/usbnet.c
1675
netif_info(dev, probe, dev->net, "unregister '%s' usb-%s-%s, %s\n",
drivers/net/usb/usbnet.c
1680
net = dev->net;
drivers/net/usb/usbnet.c
1681
unregister_netdev(net);
drivers/net/usb/usbnet.c
1698
free_netdev(net);
drivers/net/usb/usbnet.c
1729
struct net_device *net;
drivers/net/usb/usbnet.c
175
eth_hw_addr_set(dev->net, addr);
drivers/net/usb/usbnet.c
1758
net = alloc_etherdev(sizeof(*dev));
drivers/net/usb/usbnet.c
1759
if (!net)
drivers/net/usb/usbnet.c
1763
SET_NETDEV_DEV(net, &udev->dev);
drivers/net/usb/usbnet.c
1765
dev = netdev_priv(net);
drivers/net/usb/usbnet.c
1789
dev->net = net;
drivers/net/usb/usbnet.c
1790
strscpy(net->name, "usb%d", sizeof(net->name));
drivers/net/usb/usbnet.c
1795
dev->hard_mtu = net->mtu + net->hard_header_len;
drivers/net/usb/usbnet.c
1796
net->min_mtu = 0;
drivers/net/usb/usbnet.c
1797
net->max_mtu = ETH_MAX_MTU;
drivers/net/usb/usbnet.c
1799
net->netdev_ops = &usbnet_netdev_ops;
drivers/net/usb/usbnet.c
180
static bool usbnet_needs_usb_name_format(struct usbnet *dev, struct net_device *net)
drivers/net/usb/usbnet.c
1800
net->watchdog_timeo = TX_TIMEOUT_JIFFIES;
drivers/net/usb/usbnet.c
1801
net->ethtool_ops = &usbnet_ethtool_ops;
drivers/net/usb/usbnet.c
1802
net->pcpu_stat_type = NETDEV_PCPU_STAT_TSTATS;
drivers/net/usb/usbnet.c
1815
!usbnet_needs_usb_name_format(dev, net))
drivers/net/usb/usbnet.c
1816
strscpy(net->name, "eth%d", sizeof(net->name));
drivers/net/usb/usbnet.c
1819
strscpy(net->name, "wlan%d", sizeof(net->name));
drivers/net/usb/usbnet.c
1822
strscpy(net->name, "wwan%d", sizeof(net->name));
drivers/net/usb/usbnet.c
1826
net->flags |= IFF_NOARP;
drivers/net/usb/usbnet.c
1829
net->max_mtu > (dev->hard_mtu - net->hard_header_len))
drivers/net/usb/usbnet.c
1830
net->max_mtu = dev->hard_mtu - net->hard_header_len;
drivers/net/usb/usbnet.c
1832
if (net->mtu > (dev->hard_mtu - net->hard_header_len))
drivers/net/usb/usbnet.c
1833
net->mtu = dev->hard_mtu - net->hard_header_len;
drivers/net/usb/usbnet.c
1869
if (!is_valid_ether_addr(net->dev_addr))
drivers/net/usb/usbnet.c
187
(is_zero_ether_addr(net->dev_addr) ||
drivers/net/usb/usbnet.c
1870
eth_hw_addr_random(net);
drivers/net/usb/usbnet.c
1873
SET_NETDEV_DEVTYPE(net, &wlan_type);
drivers/net/usb/usbnet.c
1875
SET_NETDEV_DEVTYPE(net, &wwan_type);
drivers/net/usb/usbnet.c
188
is_local_ether_addr(net->dev_addr));
drivers/net/usb/usbnet.c
1889
status = register_netdev(net);
drivers/net/usb/usbnet.c
1892
netif_info(dev, probe, dev->net,
drivers/net/usb/usbnet.c
1897
net->dev_addr);
drivers/net/usb/usbnet.c
1902
netif_device_attach(net);
drivers/net/usb/usbnet.c
1925
free_netdev(net);
drivers/net/usb/usbnet.c
1957
netif_device_detach(dev->net);
drivers/net/usb/usbnet.c
1965
netif_device_attach(dev->net);
drivers/net/usb/usbnet.c
1993
netif_trans_update(dev->net);
drivers/net/usb/usbnet.c
1995
netdev_sent_queue(dev->net, skb->len);
drivers/net/usb/usbnet.c
2007
if (netif_device_present(dev->net) &&
drivers/net/usb/usbnet.c
2013
netif_tx_wake_all_queues(dev->net);
drivers/net/usb/usbnet.c
205
netif_dbg(dev, ifdown, dev->net,
drivers/net/usb/usbnet.c
2056
netif_carrier_off(dev->net);
drivers/net/usb/usbnet.c
2073
netdev_dbg(dev->net, "usbnet_read_cmd cmd=0x%02x reqtype=%02x"
drivers/net/usb/usbnet.c
2090
netdev_dbg(dev->net,
drivers/net/usb/usbnet.c
2105
netdev_dbg(dev->net, "usbnet_write_cmd cmd=0x%02x reqtype=%02x"
drivers/net/usb/usbnet.c
213
netdev_dbg(dev->net, "intr status %d\n", status);
drivers/net/usb/usbnet.c
219
netif_err(dev, timer, dev->net,
drivers/net/usb/usbnet.c
2216
netdev_dbg(dev->net, "usbnet_write_cmd cmd=0x%02x reqtype=%02x"
drivers/net/usb/usbnet.c
2227
netdev_err(dev->net, "Error allocating buffer"
drivers/net/usb/usbnet.c
2251
netdev_err(dev->net, "Error submitting the control"
drivers/net/usb/usbnet.c
328
struct pcpu_sw_netstats *stats64 = this_cpu_ptr(dev->net->tstats);
drivers/net/usb/usbnet.c
339
skb->protocol = eth_type_trans(skb, dev->net);
drivers/net/usb/usbnet.c
346
netif_dbg(dev, rx_status, dev->net, "< rx, len %zu, type 0x%x\n",
drivers/net/usb/usbnet.c
355
netif_dbg(dev, rx_err, dev->net,
drivers/net/usb/usbnet.c
396
int usbnet_change_mtu(struct net_device *net, int new_mtu)
drivers/net/usb/usbnet.c
398
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/usbnet.c
399
int ll_mtu = new_mtu + net->hard_header_len;
drivers/net/usb/usbnet.c
406
WRITE_ONCE(net->mtu, new_mtu);
drivers/net/usb/usbnet.c
408
dev->hard_mtu = net->mtu + net->hard_header_len;
drivers/net/usb/usbnet.c
477
netdev_dbg(dev->net,
drivers/net/usb/usbnet.c
481
netdev_dbg(dev->net,
drivers/net/usb/usbnet.c
506
skb = __netdev_alloc_skb(dev->net, size, flags);
drivers/net/usb/usbnet.c
508
skb = __netdev_alloc_skb_ip_align(dev->net, size, flags);
drivers/net/usb/usbnet.c
510
netif_dbg(dev, rx_err, dev->net, "no rx skb\n");
drivers/net/usb/usbnet.c
526
if (netif_running(dev->net) &&
drivers/net/usb/usbnet.c
527
netif_device_present(dev->net) &&
drivers/net/usb/usbnet.c
540
netif_dbg(dev, ifdown, dev->net, "device gone\n");
drivers/net/usb/usbnet.c
541
netif_device_detach(dev->net);
drivers/net/usb/usbnet.c
547
netif_dbg(dev, rx_err, dev->net,
drivers/net/usb/usbnet.c
555
netif_dbg(dev, ifdown, dev->net, "rx: stopped\n");
drivers/net/usb/usbnet.c
575
dev->net->stats.rx_errors++;
drivers/net/usb/usbnet.c
585
dev->net->stats.rx_errors++;
drivers/net/usb/usbnet.c
586
dev->net->stats.rx_length_errors++;
drivers/net/usb/usbnet.c
587
netif_dbg(dev, rx_err, dev->net, "rx length %d\n", skb->len);
drivers/net/usb/usbnet.c
620
dev->net->stats.rx_errors++;
drivers/net/usb/usbnet.c
627
netif_dbg(dev, ifdown, dev->net,
drivers/net/usb/usbnet.c
638
dev->net->stats.rx_errors++;
drivers/net/usb/usbnet.c
641
netif_dbg(dev, link, dev->net,
drivers/net/usb/usbnet.c
652
dev->net->stats.rx_over_errors++;
drivers/net/usb/usbnet.c
657
dev->net->stats.rx_errors++;
drivers/net/usb/usbnet.c
658
netif_dbg(dev, rx_err, dev->net, "rx status %d\n", urb_status);
drivers/net/usb/usbnet.c
676
if (netif_running(dev->net) &&
drivers/net/usb/usbnet.c
685
netif_dbg(dev, rx_err, dev->net, "no read resubmitted\n");
drivers/net/usb/usbnet.c
693
netif_dbg(dev, rx_status, dev->net, "paused rx queue enabled\n");
drivers/net/usb/usbnet.c
713
netif_dbg(dev, rx_status, dev->net,
drivers/net/usb/usbnet.c
763
netdev_dbg(dev->net, "unlink urb err, %d\n", retval);
drivers/net/usb/usbnet.c
778
if (netif_running(dev->net)) {
drivers/net/usb/usbnet.c
817
netif_dbg(dev, ifdown, dev->net,
drivers/net/usb/usbnet.c
823
int usbnet_stop(struct net_device *net)
drivers/net/usb/usbnet.c
825
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/usbnet.c
830
netif_stop_queue(net);
drivers/net/usb/usbnet.c
832
netif_info(dev, ifdown, dev->net,
drivers/net/usb/usbnet.c
834
net->stats.rx_packets, net->stats.tx_packets,
drivers/net/usb/usbnet.c
835
net->stats.rx_errors, net->stats.tx_errors);
drivers/net/usb/usbnet.c
844
netif_info(dev, ifdown, dev->net,
drivers/net/usb/usbnet.c
874
netdev_reset_queue(net);
drivers/net/usb/usbnet.c
894
int usbnet_open(struct net_device *net)
drivers/net/usb/usbnet.c
896
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/usbnet.c
901
netif_info(dev, ifup, dev->net,
drivers/net/usb/usbnet.c
914
netif_info(dev, ifup, dev->net,
drivers/net/usb/usbnet.c
931
netif_err(dev, ifup, dev->net, "can't open; %d\n", retval);
drivers/net/usb/usbnet.c
940
netif_err(dev, ifup, dev->net,
drivers/net/usb/usbnet.c
947
netdev_reset_queue(net);
drivers/net/usb/usbnet.c
948
netif_start_queue (net);
drivers/net/usb/usbnet.c
949
netif_info(dev, ifup, dev->net,
drivers/net/usb/usbnet.c
952
dev->net->mtu,
drivers/net/usb/usbnet.c
993
int usbnet_get_link_ksettings_mii(struct net_device *net,
drivers/net/usb/usbnet.c
996
struct usbnet *dev = netdev_priv(net);
drivers/net/usb/zaurus.c
216
dev->net->hard_header_len += 6;
drivers/net/usb/zaurus.c
217
dev->rx_urb_size = dev->net->hard_header_len
drivers/net/usb/zaurus.c
218
+ dev->net->mtu;
drivers/net/usb/zaurus.c
78
dev->net->hard_header_len += 6;
drivers/net/usb/zaurus.c
79
dev->rx_urb_size = dev->net->hard_header_len + dev->net->mtu;
drivers/net/veth.c
1817
struct net *peer_net = rtnl_newlink_peer_net(params);
drivers/net/veth.c
1960
static struct net *veth_get_link_net(const struct net_device *dev)
drivers/net/vrf.c
1126
static int vrf_rcv_finish(struct net *net, struct sock *sk, struct sk_buff *skb)
drivers/net/vrf.c
1136
struct net *net = dev_net(dev);
drivers/net/vrf.c
1138
if (nf_hook(pf, hook, net, NULL, skb, dev, NULL, vrf_rcv_finish) != 1)
drivers/net/vrf.c
1235
static struct rt6_info *vrf_ip6_route_lookup(struct net *net,
drivers/net/vrf.c
1244
return ip6_pol_route(net, vrf->fib6_table, ifindex, fl6, skb, flags);
drivers/net/vrf.c
1259
struct net *net = dev_net(vrf_dev);
drivers/net/vrf.c
1264
rt6 = vrf_ip6_route_lookup(net, vrf_dev, &fl6, ifindex, skb,
drivers/net/vrf.c
1269
if (unlikely(&rt6->dst == &net->ipv6.ip6_null_entry->dst))
drivers/net/vrf.c
132
static struct vrf_map *netns_vrf_map(struct net *net)
drivers/net/vrf.c
134
struct netns_vrf *nn_vrf = net_generic(net, vrf_net_id);
drivers/net/vrf.c
1403
struct net *net = dev_net(dev);
drivers/net/vrf.c
1413
dst = &net->ipv6.ip6_null_entry->dst;
drivers/net/vrf.c
1420
rt = vrf_ip6_route_lookup(net, dev, fl6, fl6->flowi6_oif, NULL, flags);
drivers/net/vrf.c
1644
struct net *net;
drivers/net/vrf.c
1677
net = dev_net(dev);
drivers/net/vrf.c
1678
nn_vrf = net_generic(net, vrf_net_id);
drivers/net/vrf.c
1831
struct net *net = (struct net *)table->extra1;
drivers/net/vrf.c
1832
struct vrf_map *vmap = netns_vrf_map(net);
drivers/net/vrf.c
1867
static int vrf_netns_init_sysctl(struct net *net, struct netns_vrf *nn_vrf)
drivers/net/vrf.c
1876
table[0].extra1 = net;
drivers/net/vrf.c
1878
nn_vrf->ctl_hdr = register_net_sysctl_sz(net, "net/vrf", table,
drivers/net/vrf.c
1888
static void vrf_netns_exit_sysctl(struct net *net)
drivers/net/vrf.c
1890
struct netns_vrf *nn_vrf = net_generic(net, vrf_net_id);
drivers/net/vrf.c
1898
static int vrf_netns_init_sysctl(struct net *net, struct netns_vrf *nn_vrf)
drivers/net/vrf.c
1903
static void vrf_netns_exit_sysctl(struct net *net)
drivers/net/vrf.c
1909
static int __net_init vrf_netns_init(struct net *net)
drivers/net/vrf.c
1911
struct netns_vrf *nn_vrf = net_generic(net, vrf_net_id);
drivers/net/vrf.c
1916
return vrf_netns_init_sysctl(net, nn_vrf);
drivers/net/vrf.c
1919
static void __net_exit vrf_netns_exit(struct net *net)
drivers/net/vrf.c
1921
vrf_netns_exit_sysctl(net);
drivers/net/vrf.c
313
static int vrf_ifindex_lookup_by_table_id(struct net *net, u32 table_id)
drivers/net/vrf.c
315
struct vrf_map *vmap = netns_vrf_map(net);
drivers/net/vrf.c
395
static int vrf_ip6_local_out(struct net *net, struct sock *sk,
drivers/net/vrf.c
402
err = nf_hook(NFPROTO_IPV6, NF_INET_LOCAL_OUT, net,
drivers/net/vrf.c
406
err = dst_output(net, sk, skb);
drivers/net/vrf.c
415
struct net *net = dev_net(skb->dev);
drivers/net/vrf.c
419
struct dst_entry *dst_null = &net->ipv6.ip6_null_entry->dst;
drivers/net/vrf.c
436
dst = ip6_dst_lookup_flow(net, NULL, &fl6, NULL);
drivers/net/vrf.c
454
ret = vrf_ip6_local_out(net, skb->sk, skb);
drivers/net/vrf.c
475
static int vrf_ip_local_out(struct net *net, struct sock *sk,
drivers/net/vrf.c
482
err = nf_hook(NFPROTO_IPV4, NF_INET_LOCAL_OUT, net, sk,
drivers/net/vrf.c
485
err = dst_output(net, sk, skb);
drivers/net/vrf.c
496
struct net *net = dev_net(vrf_dev);
drivers/net/vrf.c
514
rt = ip_route_output_flow(net, &fl4, NULL);
drivers/net/vrf.c
601
static int vrf_finish_output6(struct net *net, struct sock *sk,
drivers/net/vrf.c
635
static int vrf_output6(struct net *net, struct sock *sk, struct sk_buff *skb)
drivers/net/vrf.c
638
net, sk, skb, NULL, skb_dst(skb)->dev,
drivers/net/vrf.c
662
static int vrf_output6_direct_finish(struct net *net, struct sock *sk,
drivers/net/vrf.c
667
return vrf_ip6_local_out(net, sk, skb);
drivers/net/vrf.c
670
static int vrf_output6_direct(struct net *net, struct sock *sk,
drivers/net/vrf.c
678
err = nf_hook(NFPROTO_IPV6, NF_INET_POST_ROUTING, net, sk, skb,
drivers/net/vrf.c
687
static int vrf_ip6_out_direct_finish(struct net *net, struct sock *sk,
drivers/net/vrf.c
692
err = vrf_output6_direct(net, sk, skb);
drivers/net/vrf.c
694
err = vrf_ip6_local_out(net, sk, skb);
drivers/net/vrf.c
703
struct net *net = dev_net(vrf_dev);
drivers/net/vrf.c
708
err = nf_hook(NFPROTO_IPV6, NF_INET_LOCAL_OUT, net, sk,
drivers/net/vrf.c
712
err = vrf_output6_direct(net, sk, skb);
drivers/net/vrf.c
752
struct net *net = dev_net(dev);
drivers/net/vrf.c
760
vrf->fib6_table = fib6_new_table(net, vrf->tb_id);
drivers/net/vrf.c
765
rt6 = ip6_dst_alloc(net, dev, flags);
drivers/net/vrf.c
796
static int vrf_finish_output(struct net *net, struct sock *sk, struct sk_buff *skb)
drivers/net/vrf.c
834
static int vrf_output(struct net *net, struct sock *sk, struct sk_buff *skb)
drivers/net/vrf.c
838
IP_UPD_PO_STATS(net, IPSTATS_MIB_OUT, skb->len);
drivers/net/vrf.c
844
net, sk, skb, NULL, dev,
drivers/net/vrf.c
868
static int vrf_output_direct_finish(struct net *net, struct sock *sk,
drivers/net/vrf.c
873
return vrf_ip_local_out(net, sk, skb);
drivers/net/vrf.c
876
static int vrf_output_direct(struct net *net, struct sock *sk,
drivers/net/vrf.c
884
err = nf_hook(NFPROTO_IPV4, NF_INET_POST_ROUTING, net, sk, skb,
drivers/net/vrf.c
893
static int vrf_ip_out_direct_finish(struct net *net, struct sock *sk,
drivers/net/vrf.c
898
err = vrf_output_direct(net, sk, skb);
drivers/net/vrf.c
900
err = vrf_ip_local_out(net, sk, skb);
drivers/net/vrf.c
909
struct net *net = dev_net(vrf_dev);
drivers/net/vrf.c
914
err = nf_hook(NFPROTO_IPV4, NF_INET_LOCAL_OUT, net, sk,
drivers/net/vrf.c
918
err = vrf_output_direct(net, sk, skb);
drivers/net/vxlan/vxlan_core.c
1151
struct net *net = dev_net(vxlan->dev);
drivers/net/vxlan/vxlan_core.c
1218
tdev = __dev_get_by_index(net, *ifindex);
drivers/net/vxlan/vxlan_core.c
141
static struct vxlan_dev *vxlan_find_vni(struct net *net, int ifindex,
drivers/net/vxlan/vxlan_core.c
147
vs = vxlan_find_sock(net, family, port, flags, ifindex);
drivers/net/vxlan/vxlan_core.c
1713
!net_eq(vxlan->net, dev_net(vxlan->dev)))) {
drivers/net/vxlan/vxlan_core.c
203
if (!net_eq(dev_net(vxlan->dev), vxlan->net) &&
drivers/net/vxlan/vxlan_core.c
205
peernet2id(dev_net(vxlan->dev), vxlan->net)))
drivers/net/vxlan/vxlan_core.c
2326
dst_vxlan = vxlan_find_vni(vxlan->net, dst_ifindex, vni,
drivers/net/vxlan/vxlan_core.c
2365
bool xnet = !net_eq(vxlan->net, dev_net(vxlan->dev));
drivers/net/vxlan/vxlan_core.c
2481
rt = udp_tunnel_dst_lookup(skb, dev, vxlan->net, ifindex,
drivers/net/vxlan/vxlan_core.c
2565
ndst = udp_tunnel6_dst_lookup(skb, dev, vxlan->net, sock6->sk,
drivers/net/vxlan/vxlan_core.c
266
struct net *net = dev_net(vxlan->dev);
drivers/net/vxlan/vxlan_core.c
282
rtnl_notify(skb, net, 0, RTNLGRP_NEIGH, NULL, GFP_ATOMIC);
drivers/net/vxlan/vxlan_core.c
285
rtnl_set_sk_err(net, RTNLGRP_NEIGH, err);
drivers/net/vxlan/vxlan_core.c
3211
struct net_device *lowerdev = __dev_get_by_index(vxlan->net,
drivers/net/vxlan/vxlan_core.c
3244
rt = udp_tunnel_dst_lookup(skb, dev, vxlan->net, 0,
drivers/net/vxlan/vxlan_core.c
3260
ndst = udp_tunnel6_dst_lookup(skb, dev, vxlan->net, sock6->sk,
drivers/net/vxlan/vxlan_core.c
3322
struct net *net = dev_net(dev);
drivers/net/vxlan/vxlan_core.c
3323
struct vxlan_net *vn = net_generic(net, vxlan_net_id);
drivers/net/vxlan/vxlan_core.c
3526
struct net_device *lowerdev = __dev_get_by_index(vxlan->net,
drivers/net/vxlan/vxlan_core.c
3546
static struct sock *vxlan_create_sock(struct net *net, bool ipv6,
drivers/net/vxlan/vxlan_core.c
3568
err = udp_sock_create(net, &udp_conf, &sock);
drivers/net/vxlan/vxlan_core.c
3577
static struct vxlan_sock *vxlan_socket_create(struct net *net, bool ipv6,
drivers/net/vxlan/vxlan_core.c
3595
sk = vxlan_create_sock(net, ipv6, port, flags, ifindex);
drivers/net/vxlan/vxlan_core.c
3605
hlist_add_head_rcu(&vs->hlist, vs_head(net, port));
drivers/net/vxlan/vxlan_core.c
3626
setup_udp_tunnel_sock(net, sk, &tunnel_cfg);
drivers/net/vxlan/vxlan_core.c
3642
vxlan->net, vxlan->cfg.remote_ifindex);
drivers/net/vxlan/vxlan_core.c
3646
vs = vxlan_find_sock(vxlan->net, ipv6 ? AF_INET6 : AF_INET,
drivers/net/vxlan/vxlan_core.c
3656
vs = vxlan_socket_create(vxlan->net, ipv6,
drivers/net/vxlan/vxlan_core.c
3703
int vxlan_vni_in_use(struct net *src_net, struct vxlan_dev *vxlan,
drivers/net/vxlan/vxlan_core.c
3734
static int vxlan_config_validate(struct net *src_net, struct vxlan_config *conf,
drivers/net/vxlan/vxlan_core.c
3889
struct net *src_net,
drivers/net/vxlan/vxlan_core.c
3907
vxlan->net = src_net;
drivers/net/vxlan/vxlan_core.c
3943
static int vxlan_dev_configure(struct net *src_net, struct net_device *dev,
drivers/net/vxlan/vxlan_core.c
3960
static int __vxlan_dev_create(struct net *net, struct net_device *dev,
drivers/net/vxlan/vxlan_core.c
3964
struct vxlan_net *vn = net_generic(net, vxlan_net_id);
drivers/net/vxlan/vxlan_core.c
3971
err = vxlan_dev_configure(net, dev, conf, extack);
drivers/net/vxlan/vxlan_core.c
3982
remote_dev = __dev_get_by_index(net, dst->remote_ifindex);
drivers/net/vxlan/vxlan_core.c
4400
struct net *link_net = rtnl_newlink_link_net(params);
drivers/net/vxlan/vxlan_core.c
4424
if (!rtnl_dev_link_net_capable(dev, vxlan->net))
drivers/net/vxlan/vxlan_core.c
4432
err = vxlan_config_validate(vxlan->net, &conf, &lowerdev,
drivers/net/vxlan/vxlan_core.c
4502
vxlan_config_apply(dev, &conf, lowerdev, vxlan->net, true);
drivers/net/vxlan/vxlan_core.c
4672
static struct net *vxlan_get_link_net(const struct net_device *dev)
drivers/net/vxlan/vxlan_core.c
4676
return READ_ONCE(vxlan->net);
drivers/net/vxlan/vxlan_core.c
4694
struct net_device *vxlan_dev_create(struct net *net, const char *name,
drivers/net/vxlan/vxlan_core.c
4704
dev = rtnl_create_link(net, name, name_assign_type,
drivers/net/vxlan/vxlan_core.c
4709
err = __vxlan_dev_create(net, dev, conf, NULL);
drivers/net/vxlan/vxlan_core.c
4915
nh = nexthop_find_by_id(info->net, info->id);
drivers/net/vxlan/vxlan_core.c
4924
static __net_init int vxlan_init_net(struct net *net)
drivers/net/vxlan/vxlan_core.c
4926
struct vxlan_net *vn = net_generic(net, vxlan_net_id);
drivers/net/vxlan/vxlan_core.c
4935
return register_nexthop_notifier(net, &vn->nexthop_notifier_block,
drivers/net/vxlan/vxlan_core.c
4948
static void __net_exit vxlan_exit_rtnl(struct net *net,
drivers/net/vxlan/vxlan_core.c
4951
struct vxlan_net *vn = net_generic(net, vxlan_net_id);
drivers/net/vxlan/vxlan_core.c
4953
ASSERT_RTNL_NET(net);
drivers/net/vxlan/vxlan_core.c
4955
__unregister_nexthop_notifier(net, &vn->nexthop_notifier_block);
drivers/net/vxlan/vxlan_core.c
4959
static void __net_exit vxlan_exit_net(struct net *net)
drivers/net/vxlan/vxlan_core.c
4961
struct vxlan_net *vn = net_generic(net, vxlan_net_id);
drivers/net/vxlan/vxlan_core.c
807
nh = nexthop_find_by_id(vxlan->net, nhid);
drivers/net/vxlan/vxlan_core.c
83
static struct vxlan_sock *vxlan_find_sock(struct net *net, sa_family_t family,
drivers/net/vxlan/vxlan_core.c
90
hlist_for_each_entry_rcu(vs, vs_head(net, port), hlist) {
drivers/net/vxlan/vxlan_mdb.c
1046
struct net *net = dev_net(vxlan->dev);
drivers/net/vxlan/vxlan_mdb.c
1061
rtnl_notify(skb, net, 0, RTNLGRP_MDB, NULL, GFP_KERNEL);
drivers/net/vxlan/vxlan_mdb.c
1064
rtnl_set_sk_err(net, RTNLGRP_MDB, err);
drivers/net/vxlan/vxlan_mdb.c
583
if (!__dev_get_by_index(cfg->vxlan->net, cfg->remote_ifindex)) {
drivers/net/vxlan/vxlan_multicast.c
216
struct vxlan_net *vn = net_generic(vxlan->net, vxlan_net_id);
drivers/net/vxlan/vxlan_multicast.c
255
struct vxlan_net *vn = net_generic(vxlan->net, vxlan_net_id);
drivers/net/vxlan/vxlan_private.h
199
int vxlan_vni_in_use(struct net *src_net, struct vxlan_dev *vxlan,
drivers/net/vxlan/vxlan_private.h
57
static inline struct hlist_head *vs_head(struct net *net, __be16 port)
drivers/net/vxlan/vxlan_private.h
59
struct vxlan_net *vn = net_generic(net, vxlan_net_id);
drivers/net/vxlan/vxlan_vnifilter.c
302
struct net *net = dev_net(vxlan->dev);
drivers/net/vxlan/vxlan_vnifilter.c
322
rtnl_notify(skb, net, 0, RTNLGRP_TUNNEL, NULL, GFP_KERNEL);
drivers/net/vxlan/vxlan_vnifilter.c
327
rtnl_set_sk_err(net, RTNLGRP_TUNNEL, err);
drivers/net/vxlan/vxlan_vnifilter.c
406
struct net *net = sock_net(skb->sk);
drivers/net/vxlan/vxlan_vnifilter.c
423
dev = dev_get_by_index_rcu(net, tmsg->ifindex);
drivers/net/vxlan/vxlan_vnifilter.c
439
for_each_netdev_rcu(net, dev) {
drivers/net/vxlan/vxlan_vnifilter.c
519
struct vxlan_net *vn = net_generic(vxlan->net, vxlan_net_id);
drivers/net/vxlan/vxlan_vnifilter.c
616
struct vxlan_net *vn = net_generic(vxlan->net, vxlan_net_id);
drivers/net/vxlan/vxlan_vnifilter.c
736
err = vxlan_vni_in_use(vxlan->net, vxlan, &vxlan->cfg, v);
drivers/net/vxlan/vxlan_vnifilter.c
944
struct net *net = sock_net(skb->sk);
drivers/net/vxlan/vxlan_vnifilter.c
959
dev = __dev_get_by_index(net, tmsg->ifindex);
drivers/net/wireguard/device.c
314
struct net *link_net = rtnl_newlink_link_net(params);
drivers/net/wireguard/device.c
414
static void __net_exit wg_netns_exit_rtnl(struct net *net, struct list_head *dev_kill_list)
drivers/net/wireguard/device.c
420
if (rcu_access_pointer(wg->creating_net) == net) {
drivers/net/wireguard/device.h
44
struct net __rcu *creating_net;
drivers/net/wireguard/netlink.c
491
struct net *net;
drivers/net/wireguard/netlink.c
493
net = rcu_dereference(wg->creating_net);
drivers/net/wireguard/netlink.c
494
ret = !net || !ns_capable(net->user_ns, CAP_NET_ADMIN) ? -EPERM : 0;
drivers/net/wireguard/ratelimiter.c
112
if (entry->net == net && entry->ip == ip) {
drivers/net/wireguard/ratelimiter.c
142
entry->net = net;
drivers/net/wireguard/ratelimiter.c
28
void *net;
drivers/net/wireguard/ratelimiter.c
84
bool wg_ratelimiter_allow(struct sk_buff *skb, struct net *net)
drivers/net/wireguard/ratelimiter.c
90
const u32 net_word = (unsigned long)net;
drivers/net/wireguard/ratelimiter.h
13
bool wg_ratelimiter_allow(struct sk_buff *skb, struct net *net);
drivers/net/wireguard/socket.c
350
struct net *net;
drivers/net/wireguard/socket.c
376
net = rcu_dereference(wg->creating_net);
drivers/net/wireguard/socket.c
377
net = net ? maybe_get_net(net) : NULL;
drivers/net/wireguard/socket.c
379
if (unlikely(!net))
drivers/net/wireguard/socket.c
386
ret = udp_sock_create(net, &port4, &new4);
drivers/net/wireguard/socket.c
392
setup_udp_tunnel_sock(net, new4->sk, &cfg);
drivers/net/wireguard/socket.c
397
ret = udp_sock_create(net, &port6, &new6);
drivers/net/wireguard/socket.c
407
setup_udp_tunnel_sock(net, new6->sk, &cfg);
drivers/net/wireguard/socket.c
414
put_net(net);
drivers/net/wireless/microchip/wilc1000/cfg80211.c
1859
int wilc_init_host_int(struct net_device *net)
drivers/net/wireless/microchip/wilc1000/cfg80211.c
1862
struct wilc_vif *vif = netdev_priv(net);
drivers/net/wireless/microchip/wilc1000/cfg80211.c
1868
ret = wilc_init(net, &priv->hif_drv);
drivers/net/wireless/microchip/wilc1000/cfg80211.c
1870
netdev_err(net, "Error while initializing hostinterface\n");
drivers/net/wireless/microchip/wilc1000/cfg80211.c
1875
void wilc_deinit_host_int(struct net_device *net)
drivers/net/wireless/microchip/wilc1000/cfg80211.c
1878
struct wilc_vif *vif = netdev_priv(net);
drivers/net/wireless/microchip/wilc1000/cfg80211.c
1888
netdev_err(net, "Error while deinitializing host interface\n");
drivers/net/wireless/microchip/wilc1000/cfg80211.h
14
void wilc_deinit_host_int(struct net_device *net);
drivers/net/wireless/microchip/wilc1000/cfg80211.h
15
int wilc_init_host_int(struct net_device *net);
drivers/net/wireless/virtual/mac80211_hwsim_main.c
1512
struct net *net;
drivers/net/wireless/virtual/mac80211_hwsim_main.c
1517
for_each_net_rcu(net) {
drivers/net/wireless/virtual/mac80211_hwsim_main.c
1518
if (data->netgroup == hwsim_net_get_netgroup(net)) {
drivers/net/wireless/virtual/mac80211_hwsim_main.c
1519
res = genlmsg_unicast(net, skb, portid);
drivers/net/wireless/virtual/mac80211_hwsim_main.c
306
static inline int hwsim_net_get_netgroup(struct net *net)
drivers/net/wireless/virtual/mac80211_hwsim_main.c
308
struct hwsim_net *hwsim_net = net_generic(net, hwsim_net_id);
drivers/net/wireless/virtual/mac80211_hwsim_main.c
313
static inline int hwsim_net_set_netgroup(struct net *net)
drivers/net/wireless/virtual/mac80211_hwsim_main.c
315
struct hwsim_net *hwsim_net = net_generic(net, hwsim_net_id);
drivers/net/wireless/virtual/mac80211_hwsim_main.c
321
static inline u32 hwsim_net_get_wmediumd(struct net *net)
drivers/net/wireless/virtual/mac80211_hwsim_main.c
323
struct hwsim_net *hwsim_net = net_generic(net, hwsim_net_id);
drivers/net/wireless/virtual/mac80211_hwsim_main.c
328
static inline void hwsim_net_set_wmediumd(struct net *net, u32 portid)
drivers/net/wireless/virtual/mac80211_hwsim_main.c
330
struct hwsim_net *hwsim_net = net_generic(net, hwsim_net_id);
drivers/net/wireless/virtual/mac80211_hwsim_main.c
5659
struct net *net;
drivers/net/wireless/virtual/mac80211_hwsim_main.c
5686
net = genl_info_net(info);
drivers/net/wireless/virtual/mac80211_hwsim_main.c
5688
net = &init_net;
drivers/net/wireless/virtual/mac80211_hwsim_main.c
5689
wiphy_net_set(hw->wiphy, net);
drivers/net/wireless/virtual/mac80211_hwsim_main.c
6072
data->netgroup = hwsim_net_get_netgroup(net);
drivers/net/wireless/virtual/mac80211_hwsim_main.c
6073
data->wmediumd = hwsim_net_get_wmediumd(net);
drivers/net/wireless/virtual/mac80211_hwsim_main.c
6317
static void hwsim_register_wmediumd(struct net *net, u32 portid)
drivers/net/wireless/virtual/mac80211_hwsim_main.c
6321
hwsim_net_set_wmediumd(net, portid);
drivers/net/wireless/virtual/mac80211_hwsim_main.c
6325
if (data->netgroup == hwsim_net_get_netgroup(net))
drivers/net/wireless/virtual/mac80211_hwsim_main.c
6552
struct net *net = genl_info_net(info);
drivers/net/wireless/virtual/mac80211_hwsim_main.c
6569
if (hwsim_net_get_wmediumd(net))
drivers/net/wireless/virtual/mac80211_hwsim_main.c
6572
hwsim_register_wmediumd(net, info->snd_portid);
drivers/net/wireless/virtual/mac80211_hwsim_main.c
7141
remove_user_radios(notify->portid, hwsim_net_get_netgroup(notify->net));
drivers/net/wireless/virtual/mac80211_hwsim_main.c
7143
if (notify->portid == hwsim_net_get_wmediumd(notify->net)) {
drivers/net/wireless/virtual/mac80211_hwsim_main.c
7146
hwsim_register_wmediumd(notify->net, 0);
drivers/net/wireless/virtual/mac80211_hwsim_main.c
7179
static __net_init int hwsim_init_net(struct net *net)
drivers/net/wireless/virtual/mac80211_hwsim_main.c
7181
return hwsim_net_set_netgroup(net);
drivers/net/wireless/virtual/mac80211_hwsim_main.c
7184
static void __net_exit hwsim_exit_net(struct net *net)
drivers/net/wireless/virtual/mac80211_hwsim_main.c
7191
if (!net_eq(wiphy_net(data->hw->wiphy), net))
drivers/net/wireless/virtual/mac80211_hwsim_main.c
7212
ida_free(&hwsim_netgroup_ida, hwsim_net_get_netgroup(net));
drivers/net/wireless/virtual/virt_wifi.c
531
struct net *link_net = rtnl_newlink_link_net(params);
drivers/platform/mellanox/mlxbf-tmfifo.c
143
struct virtio_net_config net;
drivers/platform/mellanox/mlxbf-tmfifo.c
678
config = &fifo->vdev[vdev_id]->config.net;
drivers/rapidio/devices/rio_mport_cdev.c
1641
struct rio_net *net;
drivers/rapidio/devices/rio_mport_cdev.c
1643
net = to_rio_net(dev);
drivers/rapidio/devices/rio_mport_cdev.c
1644
rmcd_debug(RDEV, "net_%d", net->id);
drivers/rapidio/devices/rio_mport_cdev.c
1645
kfree(net);
drivers/rapidio/devices/rio_mport_cdev.c
1706
if (mport->net == NULL) {
drivers/rapidio/devices/rio_mport_cdev.c
1707
struct rio_net *net;
drivers/rapidio/devices/rio_mport_cdev.c
1709
net = rio_alloc_net(mport);
drivers/rapidio/devices/rio_mport_cdev.c
1710
if (!net) {
drivers/rapidio/devices/rio_mport_cdev.c
1716
net->id = mport->id;
drivers/rapidio/devices/rio_mport_cdev.c
1717
net->hport = mport;
drivers/rapidio/devices/rio_mport_cdev.c
1718
dev_set_name(&net->dev, "rnet_%d", net->id);
drivers/rapidio/devices/rio_mport_cdev.c
1719
net->dev.parent = &mport->dev;
drivers/rapidio/devices/rio_mport_cdev.c
1720
net->dev.release = rio_release_net;
drivers/rapidio/devices/rio_mport_cdev.c
1721
err = rio_add_net(net);
drivers/rapidio/devices/rio_mport_cdev.c
1724
put_device(&net->dev);
drivers/rapidio/devices/rio_mport_cdev.c
1725
mport->net = NULL;
drivers/rapidio/devices/rio_mport_cdev.c
1730
rdev->net = mport->net;
drivers/rapidio/devices/rio_mport_cdev.c
1781
rdev->dev.parent = &mport->net->dev;
drivers/rapidio/devices/rio_mport_cdev.c
1808
struct rio_net *net;
drivers/rapidio/devices/rio_mport_cdev.c
1825
if (rdev && rdev->dev.parent == &mport->net->dev &&
drivers/rapidio/devices/rio_mport_cdev.c
1840
net = rdev->net;
drivers/rapidio/devices/rio_mport_cdev.c
1844
if (list_empty(&net->devices)) {
drivers/rapidio/devices/rio_mport_cdev.c
1845
rio_free_net(net);
drivers/rapidio/devices/rio_mport_cdev.c
1846
mport->net = NULL;
drivers/rapidio/rio-scan.c
1002
rio_clear_locks(net);
drivers/rapidio/rio-scan.c
1007
rio_destid_free(net, next_destid);
drivers/rapidio/rio-scan.c
1008
rio_update_route_tables(net);
drivers/rapidio/rio-scan.c
1009
rio_clear_locks(net);
drivers/rapidio/rio-scan.c
101
static void rio_destid_free(struct rio_net *net, u16 destid)
drivers/rapidio/rio-scan.c
1028
static void rio_build_route_tables(struct rio_net *net)
drivers/rapidio/rio-scan.c
103
struct rio_id_table *idtab = (struct rio_id_table *)net->enum_data;
drivers/rapidio/rio-scan.c
1035
list_for_each_entry(rswitch, &net->switches, node) {
drivers/rapidio/rio-scan.c
1038
rio_lock_device(net->hport, rdev->destid,
drivers/rapidio/rio-scan.c
1041
i < RIO_MAX_ROUTE_ENTRIES(net->hport->sys_size);
drivers/rapidio/rio-scan.c
1049
rio_unlock_device(net->hport, rdev->destid, rdev->hopcount);
drivers/rapidio/rio-scan.c
1067
struct rio_net *net = NULL;
drivers/rapidio/rio-scan.c
1095
net = rio_scan_alloc_net(mport, 0, 0);
drivers/rapidio/rio-scan.c
1096
if (!net) {
drivers/rapidio/rio-scan.c
1107
if (rio_disc_peer(net, mport, RIO_ANY_DESTID(mport->sys_size),
drivers/rapidio/rio-scan.c
1115
rio_build_route_tables(net);
drivers/rapidio/rio-scan.c
115
static u16 rio_destid_first(struct rio_net *net)
drivers/rapidio/rio-scan.c
118
struct rio_id_table *idtab = (struct rio_id_table *)net->enum_data;
drivers/rapidio/rio-scan.c
135
static u16 rio_destid_next(struct rio_net *net, u16 from)
drivers/rapidio/rio-scan.c
138
struct rio_id_table *idtab = (struct rio_id_table *)net->enum_data;
drivers/rapidio/rio-scan.c
191
static int rio_clear_locks(struct rio_net *net)
drivers/rapidio/rio-scan.c
193
struct rio_mport *port = net->hport;
drivers/rapidio/rio-scan.c
208
list_for_each_entry(rdev, &net->devices, net_list) {
drivers/rapidio/rio-scan.c
322
static struct rio_dev *rio_setup_device(struct rio_net *net,
drivers/rapidio/rio-scan.c
349
rdev->net = net;
drivers/rapidio/rio-scan.c
404
next_destid = rio_destid_alloc(net);
drivers/rapidio/rio-scan.c
431
dev_set_name(&rdev->dev, "%02x:s:%04x", rdev->net->id,
drivers/rapidio/rio-scan.c
441
dev_set_name(&rdev->dev, "%02x:e:%04x", rdev->net->id,
drivers/rapidio/rio-scan.c
445
rdev->dev.parent = &net->dev;
drivers/rapidio/rio-scan.c
526
static int rio_enum_peer(struct rio_net *net, struct rio_mport *port,
drivers/rapidio/rio-scan.c
56
static u16 rio_destid_alloc(struct rio_net *net)
drivers/rapidio/rio-scan.c
583
rdev = rio_setup_device(net, port, RIO_ANY_DESTID(port->sys_size),
drivers/rapidio/rio-scan.c
59
struct rio_id_table *idtab = (struct rio_id_table *)net->enum_data;
drivers/rapidio/rio-scan.c
604
destid = rio_destid_first(net);
drivers/rapidio/rio-scan.c
611
destid = rio_destid_next(net, destid + 1);
drivers/rapidio/rio-scan.c
643
if (rio_enum_peer(net, port, hopcount + 1,
drivers/rapidio/rio-scan.c
648
destid = rio_destid_next(net, cur_destid + 1);
drivers/rapidio/rio-scan.c
662
destid = rio_destid_next(net,
drivers/rapidio/rio-scan.c
690
next_destid = rio_destid_alloc(net);
drivers/rapidio/rio-scan.c
730
rio_disc_peer(struct rio_net *net, struct rio_mport *port, u16 destid,
drivers/rapidio/rio-scan.c
738
if ((rdev = rio_setup_device(net, port, destid, hopcount, 0))) {
drivers/rapidio/rio-scan.c
780
if (rio_disc_peer(net, port, ndestid,
drivers/rapidio/rio-scan.c
812
static void rio_scan_release_net(struct rio_net *net)
drivers/rapidio/rio-scan.c
814
pr_debug("RIO-SCAN: %s: net_%d\n", __func__, net->id);
drivers/rapidio/rio-scan.c
815
kfree(net->enum_data);
drivers/rapidio/rio-scan.c
82
static int rio_destid_reserve(struct rio_net *net, u16 destid)
drivers/rapidio/rio-scan.c
820
struct rio_net *net;
drivers/rapidio/rio-scan.c
822
net = to_rio_net(dev);
drivers/rapidio/rio-scan.c
823
pr_debug("RIO-SCAN: %s: net_%d\n", __func__, net->id);
drivers/rapidio/rio-scan.c
824
kfree(net);
drivers/rapidio/rio-scan.c
840
struct rio_net *net;
drivers/rapidio/rio-scan.c
842
net = rio_alloc_net(mport);
drivers/rapidio/rio-scan.c
844
if (net && do_enum) {
drivers/rapidio/rio-scan.c
85
struct rio_id_table *idtab = (struct rio_id_table *)net->enum_data;
drivers/rapidio/rio-scan.c
857
kfree(net);
drivers/rapidio/rio-scan.c
858
mport->net = NULL;
drivers/rapidio/rio-scan.c
859
net = NULL;
drivers/rapidio/rio-scan.c
861
net->enum_data = idtab;
drivers/rapidio/rio-scan.c
862
net->release = rio_scan_release_net;
drivers/rapidio/rio-scan.c
869
if (net) {
drivers/rapidio/rio-scan.c
870
net->id = mport->id;
drivers/rapidio/rio-scan.c
871
net->hport = mport;
drivers/rapidio/rio-scan.c
872
dev_set_name(&net->dev, "rnet_%d", net->id);
drivers/rapidio/rio-scan.c
873
net->dev.parent = &mport->dev;
drivers/rapidio/rio-scan.c
874
net->dev.release = rio_scan_release_dev;
drivers/rapidio/rio-scan.c
875
if (rio_add_net(net)) {
drivers/rapidio/rio-scan.c
876
put_device(&net->dev);
drivers/rapidio/rio-scan.c
877
net = NULL;
drivers/rapidio/rio-scan.c
881
return net;
drivers/rapidio/rio-scan.c
892
static void rio_update_route_tables(struct rio_net *net)
drivers/rapidio/rio-scan.c
899
list_for_each_entry(rdev, &net->devices, net_list) {
drivers/rapidio/rio-scan.c
903
list_for_each_entry(rswitch, &net->switches, node) {
drivers/rapidio/rio-scan.c
952
struct rio_net *net = NULL;
drivers/rapidio/rio-scan.c
978
net = rio_scan_alloc_net(mport, 1, 0);
drivers/rapidio/rio-scan.c
979
if (!net) {
drivers/rapidio/rio-scan.c
986
rio_destid_reserve(net, mport->host_deviceid);
drivers/rapidio/rio-scan.c
995
next_destid = rio_destid_alloc(net);
drivers/rapidio/rio-scan.c
997
if (rio_enum_peer(net, mport, 0, NULL, 0) < 0) {
drivers/rapidio/rio-sysfs.c
43
for (i = 0; i < RIO_MAX_ROUTE_ENTRIES(rdev->net->hport->sys_size);
drivers/rapidio/rio.c
1016
return rio_mport_chk_dev_access(rdev->net->hport,
drivers/rapidio/rio.c
110
struct rio_net *net = kzalloc_obj(*net);
drivers/rapidio/rio.c
112
if (net) {
drivers/rapidio/rio.c
113
INIT_LIST_HEAD(&net->node);
drivers/rapidio/rio.c
114
INIT_LIST_HEAD(&net->devices);
drivers/rapidio/rio.c
115
INIT_LIST_HEAD(&net->switches);
drivers/rapidio/rio.c
116
INIT_LIST_HEAD(&net->mports);
drivers/rapidio/rio.c
117
mport->net = net;
drivers/rapidio/rio.c
119
return net;
drivers/rapidio/rio.c
123
int rio_add_net(struct rio_net *net)
drivers/rapidio/rio.c
127
err = device_register(&net->dev);
drivers/rapidio/rio.c
131
list_add_tail(&net->node, &rio_nets);
drivers/rapidio/rio.c
138
void rio_free_net(struct rio_net *net)
drivers/rapidio/rio.c
141
if (!list_empty(&net->node))
drivers/rapidio/rio.c
142
list_del(&net->node);
drivers/rapidio/rio.c
144
if (net->release)
drivers/rapidio/rio.c
145
net->release(net);
drivers/rapidio/rio.c
146
device_unregister(&net->dev);
drivers/rapidio/rio.c
1621
rc = rio_lock_device(rdev->net->hport, rdev->destid,
drivers/rapidio/rio.c
1630
rc = rio_std_route_add_entry(rdev->net->hport, rdev->destid,
drivers/rapidio/rio.c
1634
rc = ops->add_entry(rdev->net->hport, rdev->destid,
drivers/rapidio/rio.c
1643
rio_unlock_device(rdev->net->hport, rdev->destid,
drivers/rapidio/rio.c
1674
rc = rio_lock_device(rdev->net->hport, rdev->destid,
drivers/rapidio/rio.c
1683
rc = rio_std_route_get_entry(rdev->net->hport, rdev->destid,
drivers/rapidio/rio.c
1687
rc = ops->get_entry(rdev->net->hport, rdev->destid,
drivers/rapidio/rio.c
1696
rio_unlock_device(rdev->net->hport, rdev->destid,
drivers/rapidio/rio.c
1722
rc = rio_lock_device(rdev->net->hport, rdev->destid,
drivers/rapidio/rio.c
1731
rc = rio_std_route_clr_table(rdev->net->hport, rdev->destid,
drivers/rapidio/rio.c
1734
rc = ops->clr_table(rdev->net->hport, rdev->destid,
drivers/rapidio/rio.c
1743
rio_unlock_device(rdev->net->hport, rdev->destid,
drivers/rapidio/rio.c
183
if (rdev->net) {
drivers/rapidio/rio.c
184
list_add_tail(&rdev->net_list, &rdev->net->devices);
drivers/rapidio/rio.c
187
&rdev->net->switches);
drivers/rapidio/rio.c
209
if (rdev->net) {
drivers/rapidio/rio.c
2110
static int rio_net_remove_children(struct rio_net *net)
drivers/rapidio/rio.c
2116
device_for_each_child(&net->dev, NULL, rio_mport_cleanup_callback);
drivers/rapidio/rio.c
2132
if (port->net && port->net->hport == port) {
drivers/rapidio/rio.c
2133
rio_net_remove_children(port->net);
drivers/rapidio/rio.c
2134
rio_free_net(port->net);
drivers/rapidio/rio.h
37
extern int rio_add_net(struct rio_net *net);
drivers/rapidio/rio.h
38
extern void rio_free_net(struct rio_net *net);
drivers/rapidio/rio_cm.c
1962
if (cm->mport == rdev->net->hport)
drivers/rapidio/rio_cm.c
2006
if (cm->mport == rdev->net->hport) {
drivers/rapidio/switches/idt_gen3.c
339
if (rdev->net->hport->host_deviceid == destid) {
drivers/tty/ipwireless/hardware.h
51
struct ipw_network *net);
drivers/tty/ipwireless/network.h
34
void ipwireless_network_notify_control_line_change(struct ipw_network *net,
drivers/tty/ipwireless/network.h
37
void ipwireless_network_packet_received(struct ipw_network *net,
drivers/tty/ipwireless/network.h
41
void ipwireless_network_free(struct ipw_network *net);
drivers/tty/ipwireless/network.h
42
void ipwireless_associate_network_tty(struct ipw_network *net,
drivers/tty/ipwireless/network.h
44
void ipwireless_disassociate_network_ttys(struct ipw_network *net,
drivers/tty/ipwireless/network.h
47
void ipwireless_ppp_open(struct ipw_network *net);
drivers/tty/ipwireless/network.h
49
void ipwireless_ppp_close(struct ipw_network *net);
drivers/tty/ipwireless/network.h
50
int ipwireless_ppp_channel_index(struct ipw_network *net);
drivers/tty/ipwireless/network.h
51
int ipwireless_ppp_unit_number(struct ipw_network *net);
drivers/tty/ipwireless/network.h
52
int ipwireless_ppp_mru(const struct ipw_network *net);
drivers/tty/ipwireless/tty.h
36
struct ipw_network *net);
drivers/tty/n_gsm.c
1387
if (dlci->adaption < 3 && !dlci->net)
drivers/tty/n_gsm.c
1430
if (dlci->net)
drivers/tty/n_gsm.c
189
struct net_device *net; /* network interface, if created */
drivers/tty/n_gsm.c
3898
static int gsm_mux_net_open(struct net_device *net)
drivers/tty/n_gsm.c
3901
netif_start_queue(net);
drivers/tty/n_gsm.c
3905
static int gsm_mux_net_close(struct net_device *net)
drivers/tty/n_gsm.c
3907
netif_stop_queue(net);
drivers/tty/n_gsm.c
3913
if (!dlci->net) {
drivers/tty/n_gsm.c
3919
free_netdev(dlci->net);
drivers/tty/n_gsm.c
3920
dlci->net = NULL;
drivers/tty/n_gsm.c
3930
if (dlci->net) {
drivers/tty/n_gsm.c
3931
unregister_netdev(dlci->net);
drivers/tty/n_gsm.c
3947
struct net_device *net)
drivers/tty/n_gsm.c
3949
struct gsm_mux_net *mux_net = netdev_priv(net);
drivers/tty/n_gsm.c
3954
net->stats.tx_packets++;
drivers/tty/n_gsm.c
3955
net->stats.tx_bytes += skb->len;
drivers/tty/n_gsm.c
3958
netif_trans_update(net);
drivers/tty/n_gsm.c
3964
static void gsm_mux_net_tx_timeout(struct net_device *net, unsigned int txqueue)
drivers/tty/n_gsm.c
3967
dev_dbg(&net->dev, "Tx timed out.\n");
drivers/tty/n_gsm.c
3970
net->stats.tx_errors++;
drivers/tty/n_gsm.c
3975
struct net_device *net = dlci->net;
drivers/tty/n_gsm.c
3977
struct gsm_mux_net *mux_net = netdev_priv(net);
drivers/tty/n_gsm.c
3984
net->stats.rx_dropped++;
drivers/tty/n_gsm.c
3991
skb->dev = net;
drivers/tty/n_gsm.c
3998
net->stats.rx_packets++;
drivers/tty/n_gsm.c
3999
net->stats.rx_bytes += size;
drivers/tty/n_gsm.c
4004
static void gsm_mux_net_init(struct net_device *net)
drivers/tty/n_gsm.c
4013
net->netdev_ops = &gsm_netdev_ops;
drivers/tty/n_gsm.c
4016
net->watchdog_timeo = GSM_NET_TX_TIMEOUT;
drivers/tty/n_gsm.c
4017
net->flags = IFF_POINTOPOINT | IFF_NOARP | IFF_MULTICAST;
drivers/tty/n_gsm.c
4018
net->type = ARPHRD_NONE;
drivers/tty/n_gsm.c
4019
net->tx_queue_len = 10;
drivers/tty/n_gsm.c
4029
if (!dlci->net)
drivers/tty/n_gsm.c
4031
mux_net = netdev_priv(dlci->net);
drivers/tty/n_gsm.c
4041
struct net_device *net;
drivers/tty/n_gsm.c
4062
net = alloc_netdev(sizeof(struct gsm_mux_net), netname,
drivers/tty/n_gsm.c
4064
if (!net) {
drivers/tty/n_gsm.c
4068
net->mtu = dlci->mtu;
drivers/tty/n_gsm.c
4069
net->min_mtu = MIN_MTU;
drivers/tty/n_gsm.c
4070
net->max_mtu = dlci->mtu;
drivers/tty/n_gsm.c
4071
mux_net = netdev_priv(net);
drivers/tty/n_gsm.c
4074
strscpy(nc->if_name, net->name); /* return net name */
drivers/tty/n_gsm.c
4081
dlci->net = net;
drivers/tty/n_gsm.c
4084
retval = register_netdev(net);
drivers/tty/n_gsm.c
4090
return net->ifindex; /* return network index */
drivers/usb/gadget/function/f_ecm.c
571
struct net_device *net;
drivers/usb/gadget/function/f_ecm.c
580
net = gether_connect(&ecm->port);
drivers/usb/gadget/function/f_ecm.c
581
if (IS_ERR(net))
drivers/usb/gadget/function/f_ecm.c
582
return PTR_ERR(net);
drivers/usb/gadget/function/f_ecm.c
684
struct net_device *net __free(detach_gadget) = NULL;
drivers/usb/gadget/function/f_ecm.c
694
if (!device_is_registered(&ecm_opts->net->dev)) {
drivers/usb/gadget/function/f_ecm.c
695
gether_set_gadget(ecm_opts->net, cdev->gadget);
drivers/usb/gadget/function/f_ecm.c
696
status = gether_register_netdev(ecm_opts->net);
drivers/usb/gadget/function/f_ecm.c
698
status = gether_attach_gadget(ecm_opts->net, cdev->gadget);
drivers/usb/gadget/function/f_ecm.c
702
net = ecm_opts->net;
drivers/usb/gadget/function/f_ecm.c
795
retain_and_null_ptr(net);
drivers/usb/gadget/function/f_ecm.c
843
if (device_is_registered(&opts->net->dev))
drivers/usb/gadget/function/f_ecm.c
844
gether_cleanup(netdev_priv(opts->net));
drivers/usb/gadget/function/f_ecm.c
846
free_netdev(opts->net);
drivers/usb/gadget/function/f_ecm.c
859
opts->net = gether_setup_default();
drivers/usb/gadget/function/f_ecm.c
860
if (IS_ERR(opts->net)) {
drivers/usb/gadget/function/f_ecm.c
861
struct net_device *net = opts->net;
drivers/usb/gadget/function/f_ecm.c
863
return ERR_CAST(net);
drivers/usb/gadget/function/f_ecm.c
931
gether_detach_gadget(ecm_opts->net);
drivers/usb/gadget/function/f_ecm.c
950
status = gether_get_host_addr_cdc(opts->net, ecm->ethaddr,
drivers/usb/gadget/function/f_ecm.c
958
ecm->port.ioport = netdev_priv(opts->net);
drivers/usb/gadget/function/f_eem.c
192
struct net_device *net;
drivers/usb/gadget/function/f_eem.c
220
net = gether_connect(&eem->port);
drivers/usb/gadget/function/f_eem.c
221
if (IS_ERR(net))
drivers/usb/gadget/function/f_eem.c
222
return PTR_ERR(net);
drivers/usb/gadget/function/f_eem.c
255
struct net_device *net __free(detach_gadget) = NULL;
drivers/usb/gadget/function/f_eem.c
261
if (!device_is_registered(&eem_opts->net->dev)) {
drivers/usb/gadget/function/f_eem.c
262
gether_set_gadget(eem_opts->net, cdev->gadget);
drivers/usb/gadget/function/f_eem.c
263
status = gether_register_netdev(eem_opts->net);
drivers/usb/gadget/function/f_eem.c
265
status = gether_attach_gadget(eem_opts->net, cdev->gadget);
drivers/usb/gadget/function/f_eem.c
269
net = eem_opts->net;
drivers/usb/gadget/function/f_eem.c
312
retain_and_null_ptr(net);
drivers/usb/gadget/function/f_eem.c
595
if (device_is_registered(&opts->net->dev))
drivers/usb/gadget/function/f_eem.c
596
gether_cleanup(netdev_priv(opts->net));
drivers/usb/gadget/function/f_eem.c
598
free_netdev(opts->net);
drivers/usb/gadget/function/f_eem.c
611
opts->net = gether_setup_default();
drivers/usb/gadget/function/f_eem.c
612
if (IS_ERR(opts->net)) {
drivers/usb/gadget/function/f_eem.c
613
struct net_device *net = opts->net;
drivers/usb/gadget/function/f_eem.c
615
return ERR_CAST(net);
drivers/usb/gadget/function/f_eem.c
648
gether_detach_gadget(opts->net);
drivers/usb/gadget/function/f_eem.c
665
eem->port.ioport = netdev_priv(opts->net);
drivers/usb/gadget/function/f_ncm.c
1451
struct net_device *net __free(detach_gadget) = NULL;
drivers/usb/gadget/function/f_ncm.c
1467
if (!device_is_registered(&ncm_opts->net->dev)) {
drivers/usb/gadget/function/f_ncm.c
1468
ncm_opts->net->mtu = (ncm_opts->max_segment_size - ETH_HLEN);
drivers/usb/gadget/function/f_ncm.c
1469
gether_set_gadget(ncm_opts->net, cdev->gadget);
drivers/usb/gadget/function/f_ncm.c
1470
status = gether_register_netdev(ncm_opts->net);
drivers/usb/gadget/function/f_ncm.c
1472
status = gether_attach_gadget(ncm_opts->net, cdev->gadget);
drivers/usb/gadget/function/f_ncm.c
1476
net = ncm_opts->net;
drivers/usb/gadget/function/f_ncm.c
1579
retain_and_null_ptr(net);
drivers/usb/gadget/function/f_ncm.c
1672
if (device_is_registered(&opts->net->dev))
drivers/usb/gadget/function/f_ncm.c
1673
gether_cleanup(netdev_priv(opts->net));
drivers/usb/gadget/function/f_ncm.c
1675
free_netdev(opts->net);
drivers/usb/gadget/function/f_ncm.c
1694
opts->net = gether_setup_default();
drivers/usb/gadget/function/f_ncm.c
1695
if (IS_ERR(opts->net)) {
drivers/usb/gadget/function/f_ncm.c
1696
struct net_device *net = opts->net;
drivers/usb/gadget/function/f_ncm.c
1698
return ERR_CAST(net);
drivers/usb/gadget/function/f_ncm.c
1759
gether_detach_gadget(ncm_opts->net);
drivers/usb/gadget/function/f_ncm.c
1778
status = gether_get_host_addr_cdc(opts->net, ncm->ethaddr,
drivers/usb/gadget/function/f_ncm.c
1788
ncm->port.ioport = netdev_priv(opts->net);
drivers/usb/gadget/function/f_ncm.c
896
struct net_device *net;
drivers/usb/gadget/function/f_ncm.c
919
net = gether_connect(&ncm->port);
drivers/usb/gadget/function/f_ncm.c
920
if (IS_ERR(net))
drivers/usb/gadget/function/f_ncm.c
921
return PTR_ERR(net);
drivers/usb/gadget/function/f_ncm.c
922
ncm->netdev = net;
drivers/usb/gadget/function/f_phonet.c
510
gphonet_set_gadget(phonet_opts->net, gadget);
drivers/usb/gadget/function/f_phonet.c
511
status = gphonet_register_netdev(phonet_opts->net);
drivers/usb/gadget/function/f_phonet.c
603
return gether_get_ifname(to_f_phonet_opts(item)->net, page, PAGE_SIZE);
drivers/usb/gadget/function/f_phonet.c
625
gphonet_cleanup(opts->net);
drivers/usb/gadget/function/f_phonet.c
627
free_netdev(opts->net);
drivers/usb/gadget/function/f_phonet.c
640
opts->net = gphonet_setup_default();
drivers/usb/gadget/function/f_phonet.c
641
if (IS_ERR(opts->net)) {
drivers/usb/gadget/function/f_phonet.c
642
struct net_device *net = opts->net;
drivers/usb/gadget/function/f_phonet.c
644
return ERR_CAST(net);
drivers/usb/gadget/function/f_phonet.c
687
fp->dev = opts->net;
drivers/usb/gadget/function/f_phonet.c
718
void gphonet_set_gadget(struct net_device *net, struct usb_gadget *g)
drivers/usb/gadget/function/f_phonet.c
720
SET_NETDEV_DEV(net, &g->dev);
drivers/usb/gadget/function/f_phonet.c
723
int gphonet_register_netdev(struct net_device *net)
drivers/usb/gadget/function/f_phonet.c
727
status = register_netdev(net);
drivers/usb/gadget/function/f_phonet.c
729
free_netdev(net);
drivers/usb/gadget/function/f_rndis.c
548
struct net_device *net;
drivers/usb/gadget/function/f_rndis.c
585
net = gether_connect(&rndis->port);
drivers/usb/gadget/function/f_rndis.c
586
if (IS_ERR(net))
drivers/usb/gadget/function/f_rndis.c
587
return PTR_ERR(net);
drivers/usb/gadget/function/f_rndis.c
589
rndis_set_param_dev(rndis->params, net,
drivers/usb/gadget/function/f_rndis.c
669
struct net_device *net __free(detach_gadget) = NULL;
drivers/usb/gadget/function/f_rndis.c
689
if (!device_is_registered(&rndis_opts->net->dev)) {
drivers/usb/gadget/function/f_rndis.c
690
gether_set_gadget(rndis_opts->net, cdev->gadget);
drivers/usb/gadget/function/f_rndis.c
691
status = gether_register_netdev(rndis_opts->net);
drivers/usb/gadget/function/f_rndis.c
693
status = gether_attach_gadget(rndis_opts->net, cdev->gadget);
drivers/usb/gadget/function/f_rndis.c
697
net = rndis_opts->net;
drivers/usb/gadget/function/f_rndis.c
798
retain_and_null_ptr(net);
drivers/usb/gadget/function/f_rndis.c
811
void rndis_borrow_net(struct usb_function_instance *f, struct net_device *net)
drivers/usb/gadget/function/f_rndis.c
816
if (device_is_registered(&opts->net->dev))
drivers/usb/gadget/function/f_rndis.c
817
gether_cleanup(netdev_priv(opts->net));
drivers/usb/gadget/function/f_rndis.c
819
free_netdev(opts->net);
drivers/usb/gadget/function/f_rndis.c
821
opts->net = net;
drivers/usb/gadget/function/f_rndis.c
878
if (device_is_registered(&opts->net->dev))
drivers/usb/gadget/function/f_rndis.c
879
gether_cleanup(netdev_priv(opts->net));
drivers/usb/gadget/function/f_rndis.c
881
free_netdev(opts->net);
drivers/usb/gadget/function/f_rndis.c
902
opts->net = gether_setup_default();
drivers/usb/gadget/function/f_rndis.c
903
if (IS_ERR(opts->net)) {
drivers/usb/gadget/function/f_rndis.c
904
struct net_device *net = opts->net;
drivers/usb/gadget/function/f_rndis.c
906
return ERR_CAST(net);
drivers/usb/gadget/function/f_rndis.c
960
gether_detach_gadget(rndis_opts->net);
drivers/usb/gadget/function/f_rndis.c
978
gether_get_host_addr_u8(opts->net, rndis->ethaddr);
drivers/usb/gadget/function/f_rndis.c
982
rndis->port.ioport = netdev_priv(opts->net);
drivers/usb/gadget/function/f_subset.c
258
struct net_device *net;
drivers/usb/gadget/function/f_subset.c
275
net = gether_connect(&geth->port);
drivers/usb/gadget/function/f_subset.c
276
return PTR_ERR_OR_ZERO(net);
drivers/usb/gadget/function/f_subset.c
302
struct net_device *net __free(detach_gadget) = NULL;
drivers/usb/gadget/function/f_subset.c
308
if (!device_is_registered(&gether_opts->net->dev)) {
drivers/usb/gadget/function/f_subset.c
309
gether_set_gadget(gether_opts->net, cdev->gadget);
drivers/usb/gadget/function/f_subset.c
310
status = gether_register_netdev(gether_opts->net);
drivers/usb/gadget/function/f_subset.c
312
status = gether_attach_gadget(gether_opts->net, cdev->gadget);
drivers/usb/gadget/function/f_subset.c
316
net = gether_opts->net;
drivers/usb/gadget/function/f_subset.c
367
retain_and_null_ptr(net);
drivers/usb/gadget/function/f_subset.c
414
if (device_is_registered(&opts->net->dev))
drivers/usb/gadget/function/f_subset.c
415
gether_cleanup(netdev_priv(opts->net));
drivers/usb/gadget/function/f_subset.c
417
free_netdev(opts->net);
drivers/usb/gadget/function/f_subset.c
430
opts->net = gether_setup_default();
drivers/usb/gadget/function/f_subset.c
431
if (IS_ERR(opts->net)) {
drivers/usb/gadget/function/f_subset.c
432
struct net_device *net = opts->net;
drivers/usb/gadget/function/f_subset.c
434
return ERR_CAST(net);
drivers/usb/gadget/function/f_subset.c
467
gether_detach_gadget(opts->net);
drivers/usb/gadget/function/f_subset.c
486
status = gether_get_host_addr_cdc(opts->net, geth->ethaddr,
drivers/usb/gadget/function/f_subset.c
495
geth->port.ioport = netdev_priv(opts->net);
drivers/usb/gadget/function/rndis.c
177
struct net_device *net;
drivers/usb/gadget/function/rndis.c
201
net = params->dev;
drivers/usb/gadget/function/rndis.c
202
stats = dev_get_stats(net, &temp);
drivers/usb/gadget/function/u_ecm.h
34
struct net_device *net;
drivers/usb/gadget/function/u_eem.h
34
struct net_device *net;
drivers/usb/gadget/function/u_ether.c
1003
dev = netdev_priv(net);
drivers/usb/gadget/function/u_ether.c
1008
void gether_set_qmult(struct net_device *net, unsigned qmult)
drivers/usb/gadget/function/u_ether.c
1012
dev = netdev_priv(net);
drivers/usb/gadget/function/u_ether.c
1017
unsigned gether_get_qmult(struct net_device *net)
drivers/usb/gadget/function/u_ether.c
1021
dev = netdev_priv(net);
drivers/usb/gadget/function/u_ether.c
1026
int gether_get_ifname(struct net_device *net, char *name, int len)
drivers/usb/gadget/function/u_ether.c
1028
struct eth_dev *dev = netdev_priv(net);
drivers/usb/gadget/function/u_ether.c
1033
dev->ifname_set ? net->name : netdev_name(net));
drivers/usb/gadget/function/u_ether.c
1039
int gether_set_ifname(struct net_device *net, const char *name, int len)
drivers/usb/gadget/function/u_ether.c
1041
struct eth_dev *dev = netdev_priv(net);
drivers/usb/gadget/function/u_ether.c
1060
strscpy(net->name, tmp);
drivers/usb/gadget/function/u_ether.c
1097
if (netif_queue_stopped(dev->net))
drivers/usb/gadget/function/u_ether.c
1098
netif_start_queue(dev->net);
drivers/usb/gadget/function/u_ether.c
110
static void eth_get_drvinfo(struct net_device *net, struct ethtool_drvinfo *p)
drivers/usb/gadget/function/u_ether.c
1117
unregister_netdev(dev->net);
drivers/usb/gadget/function/u_ether.c
1119
free_netdev(dev->net);
drivers/usb/gadget/function/u_ether.c
112
struct eth_dev *dev = netdev_priv(net);
drivers/usb/gadget/function/u_ether.c
1178
if (netif_running(dev->net)) {
drivers/usb/gadget/function/u_ether.c
1187
netif_carrier_on(dev->net);
drivers/usb/gadget/function/u_ether.c
1188
if (netif_running(dev->net))
drivers/usb/gadget/function/u_ether.c
1201
return dev->net;
drivers/usb/gadget/function/u_ether.c
1233
netif_stop_queue(dev->net);
drivers/usb/gadget/function/u_ether.c
1234
netif_carrier_off(dev->net);
drivers/usb/gadget/function/u_ether.c
179
size += sizeof(struct ethhdr) + dev->net->mtu + RX_EXTRA;
drivers/usb/gadget/function/u_ether.c
191
skb = __netdev_alloc_skb(dev->net, size + NET_IP_ALIGN, gfp_flags);
drivers/usb/gadget/function/u_ether.c
259
dev->net->stats.rx_errors++;
drivers/usb/gadget/function/u_ether.c
260
dev->net->stats.rx_length_errors++;
drivers/usb/gadget/function/u_ether.c
265
skb2->protocol = eth_type_trans(skb2, dev->net);
drivers/usb/gadget/function/u_ether.c
266
dev->net->stats.rx_packets++;
drivers/usb/gadget/function/u_ether.c
267
dev->net->stats.rx_bytes += skb2->len;
drivers/usb/gadget/function/u_ether.c
294
dev->net->stats.rx_over_errors++;
drivers/usb/gadget/function/u_ether.c
298
dev->net->stats.rx_errors++;
drivers/usb/gadget/function/u_ether.c
305
if (!netif_running(dev->net)) {
drivers/usb/gadget/function/u_ether.c
401
if (netif_running(dev->net))
drivers/usb/gadget/function/u_ether.c
416
dev->net->stats.tx_errors++;
drivers/usb/gadget/function/u_ether.c
424
dev->net->stats.tx_bytes += skb->len;
drivers/usb/gadget/function/u_ether.c
427
dev->net->stats.tx_packets++;
drivers/usb/gadget/function/u_ether.c
434
if (netif_carrier_ok(dev->net))
drivers/usb/gadget/function/u_ether.c
435
netif_wake_queue(dev->net);
drivers/usb/gadget/function/u_ether.c
458
struct net_device *net)
drivers/usb/gadget/function/u_ether.c
460
struct eth_dev *dev = netdev_priv(net);
drivers/usb/gadget/function/u_ether.c
479
netif_stop_queue(net);
drivers/usb/gadget/function/u_ether.c
531
netif_stop_queue(net);
drivers/usb/gadget/function/u_ether.c
585
netif_trans_update(net);
drivers/usb/gadget/function/u_ether.c
592
dev->net->stats.tx_dropped++;
drivers/usb/gadget/function/u_ether.c
596
netif_start_queue(net);
drivers/usb/gadget/function/u_ether.c
614
netif_wake_queue(dev->net);
drivers/usb/gadget/function/u_ether.c
617
static int eth_open(struct net_device *net)
drivers/usb/gadget/function/u_ether.c
619
struct eth_dev *dev = netdev_priv(net);
drivers/usb/gadget/function/u_ether.c
62
struct net_device *net;
drivers/usb/gadget/function/u_ether.c
623
if (netif_carrier_ok(dev->net))
drivers/usb/gadget/function/u_ether.c
635
static int eth_stop(struct net_device *net)
drivers/usb/gadget/function/u_ether.c
637
struct eth_dev *dev = netdev_priv(net);
drivers/usb/gadget/function/u_ether.c
641
netif_stop_queue(net);
drivers/usb/gadget/function/u_ether.c
644
dev->net->stats.rx_packets, dev->net->stats.tx_packets,
drivers/usb/gadget/function/u_ether.c
645
dev->net->stats.rx_errors, dev->net->stats.tx_errors
drivers/usb/gadget/function/u_ether.c
671
if (netif_carrier_ok(net)) {
drivers/usb/gadget/function/u_ether.c
747
struct net_device *net;
drivers/usb/gadget/function/u_ether.c
751
net = alloc_etherdev(sizeof *dev);
drivers/usb/gadget/function/u_ether.c
752
if (!net)
drivers/usb/gadget/function/u_ether.c
755
dev = netdev_priv(net);
drivers/usb/gadget/function/u_ether.c
765
dev->net = net;
drivers/usb/gadget/function/u_ether.c
767
snprintf(net->name, sizeof(net->name), "%s%%d", netname);
drivers/usb/gadget/function/u_ether.c
770
net->addr_assign_type = NET_ADDR_RANDOM;
drivers/usb/gadget/function/u_ether.c
774
net->addr_assign_type = NET_ADDR_SET;
drivers/usb/gadget/function/u_ether.c
776
eth_hw_addr_set(net, addr);
drivers/usb/gadget/function/u_ether.c
784
net->netdev_ops = &eth_netdev_ops;
drivers/usb/gadget/function/u_ether.c
786
net->ethtool_ops = &ops;
drivers/usb/gadget/function/u_ether.c
789
net->min_mtu = ETH_HLEN;
drivers/usb/gadget/function/u_ether.c
790
net->max_mtu = GETHER_MAX_MTU_SIZE;
drivers/usb/gadget/function/u_ether.c
793
SET_NETDEV_DEV(net, &g->dev);
drivers/usb/gadget/function/u_ether.c
794
SET_NETDEV_DEVTYPE(net, &gadget_type);
drivers/usb/gadget/function/u_ether.c
796
status = register_netdev(net);
drivers/usb/gadget/function/u_ether.c
799
free_netdev(net);
drivers/usb/gadget/function/u_ether.c
802
INFO(dev, "MAC %pM\n", net->dev_addr);
drivers/usb/gadget/function/u_ether.c
810
netif_carrier_off(net);
drivers/usb/gadget/function/u_ether.c
819
struct net_device *net;
drivers/usb/gadget/function/u_ether.c
822
net = alloc_etherdev(sizeof(*dev));
drivers/usb/gadget/function/u_ether.c
823
if (!net)
drivers/usb/gadget/function/u_ether.c
826
dev = netdev_priv(net);
drivers/usb/gadget/function/u_ether.c
836
dev->net = net;
drivers/usb/gadget/function/u_ether.c
838
snprintf(net->name, sizeof(net->name), "%s%%d", netname);
drivers/usb/gadget/function/u_ether.c
843
net->addr_assign_type = NET_ADDR_RANDOM;
drivers/usb/gadget/function/u_ether.c
847
net->netdev_ops = &eth_netdev_ops;
drivers/usb/gadget/function/u_ether.c
849
net->ethtool_ops = &ops;
drivers/usb/gadget/function/u_ether.c
850
SET_NETDEV_DEVTYPE(net, &gadget_type);
drivers/usb/gadget/function/u_ether.c
853
net->min_mtu = ETH_HLEN;
drivers/usb/gadget/function/u_ether.c
854
net->max_mtu = GETHER_MAX_MTU_SIZE;
drivers/usb/gadget/function/u_ether.c
856
return net;
drivers/usb/gadget/function/u_ether.c
860
int gether_register_netdev(struct net_device *net)
drivers/usb/gadget/function/u_ether.c
866
if (!net->dev.parent)
drivers/usb/gadget/function/u_ether.c
868
dev = netdev_priv(net);
drivers/usb/gadget/function/u_ether.c
871
eth_hw_addr_set(net, dev->dev_mac);
drivers/usb/gadget/function/u_ether.c
873
status = register_netdev(net);
drivers/usb/gadget/function/u_ether.c
885
netif_carrier_off(net);
drivers/usb/gadget/function/u_ether.c
892
void gether_set_gadget(struct net_device *net, struct usb_gadget *g)
drivers/usb/gadget/function/u_ether.c
896
dev = netdev_priv(net);
drivers/usb/gadget/function/u_ether.c
898
SET_NETDEV_DEV(net, &g->dev);
drivers/usb/gadget/function/u_ether.c
902
int gether_attach_gadget(struct net_device *net, struct usb_gadget *g)
drivers/usb/gadget/function/u_ether.c
906
ret = device_move(&net->dev, &g->dev, DPM_ORDER_DEV_AFTER_PARENT);
drivers/usb/gadget/function/u_ether.c
910
gether_set_gadget(net, g);
drivers/usb/gadget/function/u_ether.c
915
void gether_detach_gadget(struct net_device *net)
drivers/usb/gadget/function/u_ether.c
917
struct eth_dev *dev = netdev_priv(net);
drivers/usb/gadget/function/u_ether.c
919
device_move(&net->dev, NULL, DPM_ORDER_NONE);
drivers/usb/gadget/function/u_ether.c
924
int gether_set_dev_addr(struct net_device *net, const char *dev_addr)
drivers/usb/gadget/function/u_ether.c
929
dev = netdev_priv(net);
drivers/usb/gadget/function/u_ether.c
933
net->addr_assign_type = NET_ADDR_SET;
drivers/usb/gadget/function/u_ether.c
938
int gether_get_dev_addr(struct net_device *net, char *dev_addr, int len)
drivers/usb/gadget/function/u_ether.c
943
dev = netdev_priv(net);
drivers/usb/gadget/function/u_ether.c
954
int gether_set_host_addr(struct net_device *net, const char *host_addr)
drivers/usb/gadget/function/u_ether.c
959
dev = netdev_priv(net);
drivers/usb/gadget/function/u_ether.c
967
int gether_get_host_addr(struct net_device *net, char *host_addr, int len)
drivers/usb/gadget/function/u_ether.c
972
dev = netdev_priv(net);
drivers/usb/gadget/function/u_ether.c
983
int gether_get_host_addr_cdc(struct net_device *net, char *host_addr, int len)
drivers/usb/gadget/function/u_ether.c
990
dev = netdev_priv(net);
drivers/usb/gadget/function/u_ether.c
999
void gether_get_host_addr_u8(struct net_device *net, u8 host_mac[ETH_ALEN])
drivers/usb/gadget/function/u_ether.h
128
int gether_register_netdev(struct net_device *net);
drivers/usb/gadget/function/u_ether.h
151
void gether_set_gadget(struct net_device *net, struct usb_gadget *g);
drivers/usb/gadget/function/u_ether.h
164
int gether_attach_gadget(struct net_device *net, struct usb_gadget *g);
drivers/usb/gadget/function/u_ether.h
175
void gether_detach_gadget(struct net_device *net);
drivers/usb/gadget/function/u_ether.h
188
int gether_set_dev_addr(struct net_device *net, const char *dev_addr);
drivers/usb/gadget/function/u_ether.h
199
int gether_get_dev_addr(struct net_device *net, char *dev_addr, int len);
drivers/usb/gadget/function/u_ether.h
210
int gether_set_host_addr(struct net_device *net, const char *host_addr);
drivers/usb/gadget/function/u_ether.h
221
int gether_get_host_addr(struct net_device *net, char *host_addr, int len);
drivers/usb/gadget/function/u_ether.h
233
int gether_get_host_addr_cdc(struct net_device *net, char *host_addr, int len);
drivers/usb/gadget/function/u_ether.h
243
void gether_get_host_addr_u8(struct net_device *net, u8 host_mac[ETH_ALEN]);
drivers/usb/gadget/function/u_ether.h
253
void gether_set_qmult(struct net_device *net, unsigned qmult);
drivers/usb/gadget/function/u_ether.h
261
unsigned gether_get_qmult(struct net_device *net);
drivers/usb/gadget/function/u_ether.h
272
int gether_get_ifname(struct net_device *net, char *name, int len);
drivers/usb/gadget/function/u_ether.h
284
int gether_set_ifname(struct net_device *net, const char *name, int len);
drivers/usb/gadget/function/u_ether_configfs.h
106
qmult = gether_get_qmult(opts->net); \
drivers/usb/gadget/function/u_ether_configfs.h
128
gether_set_qmult(opts->net, val); \
drivers/usb/gadget/function/u_ether_configfs.h
145
ret = gether_get_ifname(opts->net, page, PAGE_SIZE); \
drivers/usb/gadget/function/u_ether_configfs.h
159
ret = gether_set_ifname(opts->net, page, len); \
drivers/usb/gadget/function/u_ether_configfs.h
36
result = gether_get_dev_addr(opts->net, page, PAGE_SIZE); \
drivers/usb/gadget/function/u_ether_configfs.h
54
ret = gether_set_dev_addr(opts->net, page); \
drivers/usb/gadget/function/u_ether_configfs.h
71
result = gether_get_host_addr(opts->net, page, PAGE_SIZE); \
drivers/usb/gadget/function/u_ether_configfs.h
89
ret = gether_set_host_addr(opts->net, page); \
drivers/usb/gadget/function/u_gether.h
34
struct net_device *net;
drivers/usb/gadget/function/u_ncm.h
34
struct net_device *net;
drivers/usb/gadget/function/u_phonet.h
17
struct net_device *net;
drivers/usb/gadget/function/u_phonet.h
21
void gphonet_set_gadget(struct net_device *net, struct usb_gadget *g);
drivers/usb/gadget/function/u_phonet.h
22
int gphonet_register_netdev(struct net_device *net);
drivers/usb/gadget/function/u_rndis.h
44
struct net_device *net;
drivers/usb/gadget/function/u_rndis.h
59
void rndis_borrow_net(struct usb_function_instance *f, struct net_device *net);
drivers/usb/gadget/legacy/cdc2.c
156
gether_set_qmult(ecm_opts->net, qmult);
drivers/usb/gadget/legacy/cdc2.c
157
if (!gether_set_host_addr(ecm_opts->net, host_addr))
drivers/usb/gadget/legacy/cdc2.c
159
if (!gether_set_dev_addr(ecm_opts->net, dev_addr))
drivers/usb/gadget/legacy/ether.c
310
struct net_device *net;
drivers/usb/gadget/legacy/ether.c
322
net = eem_opts->net;
drivers/usb/gadget/legacy/ether.c
336
net = ecm_opts->net;
drivers/usb/gadget/legacy/ether.c
349
net = geth_opts->net;
drivers/usb/gadget/legacy/ether.c
359
gether_set_qmult(net, qmult);
drivers/usb/gadget/legacy/ether.c
360
if (!gether_set_host_addr(net, host_addr))
drivers/usb/gadget/legacy/ether.c
362
if (!gether_set_dev_addr(net, dev_addr))
drivers/usb/gadget/legacy/ether.c
367
gether_set_gadget(net, cdev->gadget);
drivers/usb/gadget/legacy/ether.c
368
status = gether_register_netdev(net);
drivers/usb/gadget/legacy/ether.c
385
rndis_borrow_net(fi_rndis, net);
drivers/usb/gadget/legacy/g_ffs.c
311
struct net_device *net;
drivers/usb/gadget/legacy/g_ffs.c
325
net = ecm_opts->net;
drivers/usb/gadget/legacy/g_ffs.c
334
net = geth_opts->net;
drivers/usb/gadget/legacy/g_ffs.c
346
net = container_of(fi_rndis, struct f_rndis_opts,
drivers/usb/gadget/legacy/g_ffs.c
347
func_inst)->net;
drivers/usb/gadget/legacy/g_ffs.c
353
gether_set_qmult(net, qmult);
drivers/usb/gadget/legacy/g_ffs.c
354
if (!gether_set_host_addr(net, host_addr))
drivers/usb/gadget/legacy/g_ffs.c
356
if (!gether_set_dev_addr(net, dev_addr))
drivers/usb/gadget/legacy/g_ffs.c
361
gether_set_gadget(net, cdev->gadget);
drivers/usb/gadget/legacy/g_ffs.c
362
ret = gether_register_netdev(net);
drivers/usb/gadget/legacy/g_ffs.c
379
rndis_borrow_net(fi_rndis, net);
drivers/usb/gadget/legacy/multi.c
320
gether_set_qmult(ecm_opts->net, qmult);
drivers/usb/gadget/legacy/multi.c
321
if (!gether_set_host_addr(ecm_opts->net, host_addr))
drivers/usb/gadget/legacy/multi.c
323
if (!gether_set_dev_addr(ecm_opts->net, dev_addr))
drivers/usb/gadget/legacy/multi.c
336
gether_set_qmult(rndis_opts->net, qmult);
drivers/usb/gadget/legacy/multi.c
337
if (!gether_set_host_addr(rndis_opts->net, host_addr))
drivers/usb/gadget/legacy/multi.c
339
if (!gether_set_dev_addr(rndis_opts->net, dev_addr))
drivers/usb/gadget/legacy/multi.c
350
gether_set_gadget(ecm_opts->net, cdev->gadget);
drivers/usb/gadget/legacy/multi.c
351
status = gether_register_netdev(ecm_opts->net);
drivers/usb/gadget/legacy/multi.c
355
rndis_borrow_net(fi_rndis, ecm_opts->net);
drivers/usb/gadget/legacy/ncm.c
139
gether_set_qmult(ncm_opts->net, qmult);
drivers/usb/gadget/legacy/ncm.c
140
if (!gether_set_host_addr(ncm_opts->net, host_addr))
drivers/usb/gadget/legacy/ncm.c
142
if (!gether_set_dev_addr(ncm_opts->net, dev_addr))
drivers/vdpa/mlx5/net/mlx5_vnet.c
3884
if (add_config->net.max_vq_pairs > max_vqs / 2)
drivers/vdpa/mlx5/net/mlx5_vnet.c
3886
max_vqs = min_t(u32, max_vqs, 2 * add_config->net.max_vq_pairs);
drivers/vdpa/mlx5/net/mlx5_vnet.c
3919
err = config_func_mtu(mdev, add_config->net.mtu);
drivers/vdpa/mlx5/net/mlx5_vnet.c
3940
memcpy(ndev->config.mac, add_config->net.mac, ETH_ALEN);
drivers/vdpa/mlx5/net/mlx5_vnet.c
4078
(u8 *)add_config->net.mac);
drivers/vdpa/pds/vdpa_dev.c
688
vq_pairs = add_config->net.max_vq_pairs;
drivers/vdpa/pds/vdpa_dev.c
715
ether_addr_copy(pdsv->mac, add_config->net.mac);
drivers/vdpa/vdpa.c
1343
ether_addr_copy(set_config.net.mac, macaddr);
drivers/vdpa/vdpa.c
577
memcpy(config.net.mac, macaddr, sizeof(config.net.mac));
drivers/vdpa/vdpa.c
581
config.net.mtu =
drivers/vdpa/vdpa.c
586
config.net.max_vq_pairs =
drivers/vdpa/vdpa.c
588
if (!config.net.max_vq_pairs) {
drivers/vdpa/vdpa.c
607
config.net.max_vq_pairs > 1 &&
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
130
struct vdpasim_net *net = sim_to_net(vdpasim);
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
189
u64_stats_update_begin(&net->cq_stats.syncp);
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
190
net->cq_stats.requests += requests;
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
191
net->cq_stats.errors += errors;
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
192
net->cq_stats.successes += successes;
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
193
u64_stats_update_end(&net->cq_stats.syncp);
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
200
struct vdpasim_net *net = sim_to_net(vdpasim);
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
230
net->buffer, PAGE_SIZE);
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
249
net->buffer, read);
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
270
u64_stats_update_begin(&net->tx_stats.syncp);
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
271
net->tx_stats.pkts += tx_pkts;
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
272
net->tx_stats.bytes += tx_bytes;
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
273
net->tx_stats.errors += tx_errors;
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
274
u64_stats_update_end(&net->tx_stats.syncp);
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
276
u64_stats_update_begin(&net->rx_stats.syncp);
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
277
net->rx_stats.pkts += rx_pkts;
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
278
net->rx_stats.bytes += rx_bytes;
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
279
net->rx_stats.drops += rx_drops;
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
280
net->rx_stats.errors += rx_errors;
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
281
net->rx_stats.overruns += rx_overruns;
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
282
u64_stats_update_end(&net->rx_stats.syncp);
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
289
struct vdpasim_net *net = sim_to_net(vdpasim);
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
299
start = u64_stats_fetch_begin(&net->rx_stats.syncp);
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
300
rx_pkts = net->rx_stats.pkts;
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
301
rx_bytes = net->rx_stats.bytes;
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
302
rx_errors = net->rx_stats.errors;
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
303
rx_overruns = net->rx_stats.overruns;
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
304
rx_drops = net->rx_stats.drops;
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
305
} while (u64_stats_fetch_retry(&net->rx_stats.syncp, start));
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
341
start = u64_stats_fetch_begin(&net->tx_stats.syncp);
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
342
tx_pkts = net->tx_stats.pkts;
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
343
tx_bytes = net->tx_stats.bytes;
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
344
tx_errors = net->tx_stats.errors;
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
345
tx_drops = net->tx_stats.drops;
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
346
} while (u64_stats_fetch_retry(&net->tx_stats.syncp, start));
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
376
start = u64_stats_fetch_begin(&net->cq_stats.syncp);
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
377
cq_requests = net->cq_stats.requests;
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
378
cq_successes = net->cq_stats.successes;
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
379
cq_errors = net->cq_stats.errors;
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
380
} while (u64_stats_fetch_retry(&net->cq_stats.syncp, start));
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
426
ether_addr_copy(vio_config->mac, config->net.mac);
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
441
memcpy(vio_config->mac, config->net.mac, ETH_ALEN);
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
443
vio_config->mtu = cpu_to_vdpasim16(vdpasim, config->net.mtu);
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
451
struct vdpasim_net *net = sim_to_net(vdpasim);
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
453
kvfree(net->buffer);
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
462
struct vdpasim_net *net;
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
486
net = sim_to_net(simdev);
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
488
u64_stats_init(&net->tx_stats.syncp);
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
489
u64_stats_init(&net->rx_stats.syncp);
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
490
u64_stats_init(&net->cq_stats.syncp);
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
492
net->buffer = kvmalloc(PAGE_SIZE, GFP_KERNEL);
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
493
if (!net->buffer) {
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
91
struct vdpasim_net *net = sim_to_net(vdpasim);
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
96
if (is_broadcast_ether_addr(net->buffer + hdr_len) ||
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
97
is_multicast_ether_addr(net->buffer + hdr_len))
drivers/vdpa/vdpa_sim/vdpa_sim_net.c
99
if (!strncmp(net->buffer + hdr_len, vio_config->mac, ETH_ALEN))
drivers/vhost/net.c
1001
handle_tx_zerocopy(net, sock);
drivers/vhost/net.c
1003
handle_tx_copy(net, sock);
drivers/vhost/net.c
1030
static int vhost_net_rx_peek_head_len(struct vhost_net *net, struct sock *sk,
drivers/vhost/net.c
1033
struct vhost_net_virtqueue *rnvq = &net->vqs[VHOST_NET_VQ_RX];
drivers/vhost/net.c
1034
struct vhost_net_virtqueue *tnvq = &net->vqs[VHOST_NET_VQ_TX];
drivers/vhost/net.c
1044
vhost_net_busy_poll(net, rvq, tvq, busyloop_intr, true);
drivers/vhost/net.c
1149
static void handle_rx(struct vhost_net *net)
drivers/vhost/net.c
1151
struct vhost_net_virtqueue *nvq = &net->vqs[VHOST_NET_VQ_RX];
drivers/vhost/net.c
1189
vhost_disable_notify(&net->dev, vq);
drivers/vhost/net.c
1190
vhost_net_disable_vq(net, vq);
drivers/vhost/net.c
1202
sock_len = vhost_net_rx_peek_head_len(net, sock->sk,
drivers/vhost/net.c
1220
} else if (unlikely(vhost_enable_notify(&net->dev, vq))) {
drivers/vhost/net.c
1223
vhost_disable_notify(&net->dev, vq);
drivers/vhost/net.c
1300
vhost_net_enable_vq(net, vq);
drivers/vhost/net.c
1310
struct vhost_net *net = container_of(vq->dev, struct vhost_net, dev);
drivers/vhost/net.c
1312
handle_tx(net);
drivers/vhost/net.c
1319
struct vhost_net *net = container_of(vq->dev, struct vhost_net, dev);
drivers/vhost/net.c
1321
handle_rx(net);
drivers/vhost/net.c
1326
struct vhost_net *net = container_of(work, struct vhost_net,
drivers/vhost/net.c
1328
handle_tx(net);
drivers/vhost/net.c
1333
struct vhost_net *net = container_of(work, struct vhost_net,
drivers/vhost/net.c
1335
handle_rx(net);
drivers/vhost/net.c
333
static void vhost_net_tx_packet(struct vhost_net *net)
drivers/vhost/net.c
335
++net->tx_packets;
drivers/vhost/net.c
336
if (net->tx_packets < 1024)
drivers/vhost/net.c
338
net->tx_packets = 0;
drivers/vhost/net.c
339
net->tx_zcopy_err = 0;
drivers/vhost/net.c
342
static void vhost_net_tx_err(struct vhost_net *net)
drivers/vhost/net.c
344
++net->tx_zcopy_err;
drivers/vhost/net.c
347
static bool vhost_net_tx_select_zcopy(struct vhost_net *net)
drivers/vhost/net.c
352
return !net->tx_flush &&
drivers/vhost/net.c
353
net->tx_packets / 64 >= net->tx_zcopy_err;
drivers/vhost/net.c
372
static void vhost_zerocopy_signal_used(struct vhost_net *net,
drivers/vhost/net.c
382
vhost_net_tx_err(net);
drivers/vhost/net.c
489
static void vhost_tx_batch(struct vhost_net *net,
drivers/vhost/net.c
544
static void vhost_net_busy_poll_try_queue(struct vhost_net *net,
drivers/vhost/net.c
547
if (!vhost_vq_avail_empty(&net->dev, vq)) {
drivers/vhost/net.c
549
} else if (unlikely(vhost_enable_notify(&net->dev, vq))) {
drivers/vhost/net.c
550
vhost_disable_notify(&net->dev, vq);
drivers/vhost/net.c
555
static void vhost_net_busy_poll(struct vhost_net *net,
drivers/vhost/net.c
573
vhost_disable_notify(&net->dev, vq);
drivers/vhost/net.c
589
!vhost_vq_avail_empty(&net->dev, rvq)) ||
drivers/vhost/net.c
590
!vhost_vq_avail_empty(&net->dev, tvq))
drivers/vhost/net.c
599
vhost_net_busy_poll_try_queue(net, vq);
drivers/vhost/net.c
601
vhost_enable_notify(&net->dev, rvq);
drivers/vhost/net.c
606
static int vhost_net_tx_get_vq_desc(struct vhost_net *net,
drivers/vhost/net.c
612
struct vhost_net_virtqueue *rnvq = &net->vqs[VHOST_NET_VQ_RX];
drivers/vhost/net.c
622
vhost_tx_batch(net, tnvq,
drivers/vhost/net.c
626
vhost_net_busy_poll(net, rvq, tvq, busyloop_intr, false);
drivers/vhost/net.c
635
static bool vhost_exceeds_maxpend(struct vhost_net *net)
drivers/vhost/net.c
637
struct vhost_net_virtqueue *nvq = &net->vqs[VHOST_NET_VQ_TX];
drivers/vhost/net.c
656
static int get_tx_bufs(struct vhost_net *net,
drivers/vhost/net.c
666
ret = vhost_net_tx_get_vq_desc(net, nvq, out, in, msg,
drivers/vhost/net.c
701
struct vhost_net *net = container_of(vq->dev, struct vhost_net,
drivers/vhost/net.c
723
buf = page_frag_alloc_align(&net->pf_cache, buflen, GFP_KERNEL,
drivers/vhost/net.c
770
static void handle_tx_copy(struct vhost_net *net, struct socket *sock)
drivers/vhost/net.c
772
struct vhost_net_virtqueue *nvq = &net->vqs[VHOST_NET_VQ_TX];
drivers/vhost/net.c
794
vhost_tx_batch(net, nvq, sock, &msg);
drivers/vhost/net.c
796
head = get_tx_bufs(net, nvq, &msg, &out, &in, &len,
drivers/vhost/net.c
807
vhost_tx_batch(net, nvq, sock, &msg);
drivers/vhost/net.c
810
} else if (unlikely(vhost_enable_notify(&net->dev,
drivers/vhost/net.c
812
vhost_disable_notify(&net->dev, vq);
drivers/vhost/net.c
828
vhost_tx_batch(net, nvq, sock, &msg);
drivers/vhost/net.c
830
vhost_net_enable_vq(net, vq);
drivers/vhost/net.c
839
vhost_tx_batch(net, nvq, sock, &msg);
drivers/vhost/net.c
853
vhost_net_enable_vq(net, vq);
drivers/vhost/net.c
870
vhost_tx_batch(net, nvq, sock, &msg);
drivers/vhost/net.c
873
static void handle_tx_zerocopy(struct vhost_net *net, struct socket *sock)
drivers/vhost/net.c
875
struct vhost_net_virtqueue *nvq = &net->vqs[VHOST_NET_VQ_TX];
drivers/vhost/net.c
899
vhost_zerocopy_signal_used(net, vq);
drivers/vhost/net.c
902
head = get_tx_bufs(net, nvq, &msg, &out, &in, &len,
drivers/vhost/net.c
911
} else if (unlikely(vhost_enable_notify(&net->dev, vq))) {
drivers/vhost/net.c
912
vhost_disable_notify(&net->dev, vq);
drivers/vhost/net.c
919
&& !vhost_exceeds_maxpend(net)
drivers/vhost/net.c
920
&& vhost_net_tx_select_zcopy(net);
drivers/vhost/net.c
945
likely(!vhost_exceeds_maxpend(net))) {
drivers/vhost/net.c
966
vhost_net_enable_vq(net, vq);
drivers/vhost/net.c
974
vhost_add_used_and_signal(&net->dev, vq, head, 0);
drivers/vhost/net.c
976
vhost_zerocopy_signal_used(net, vq);
drivers/vhost/net.c
977
vhost_net_tx_packet(net);
drivers/vhost/net.c
983
static void handle_tx(struct vhost_net *net)
drivers/vhost/net.c
985
struct vhost_net_virtqueue *nvq = &net->vqs[VHOST_NET_VQ_TX];
drivers/vhost/net.c
997
vhost_disable_notify(&net->dev, vq);
drivers/vhost/net.c
998
vhost_net_disable_vq(net, vq);
drivers/vhost/vsock.c
101
found = !!vhost_vsock_get(cid, net);
drivers/vhost/vsock.c
289
vhost_transport_send_pkt(struct sk_buff *skb, struct net *net)
drivers/vhost/vsock.c
298
vsock = vhost_vsock_get(le64_to_cpu(hdr->dst_cid), net);
drivers/vhost/vsock.c
508
struct net *net = sock_net(sk_vsock(vsk));
drivers/vhost/vsock.c
51
struct net *net;
drivers/vhost/vsock.c
513
vsock = vhost_vsock_get(remote_cid, net);
drivers/vhost/vsock.c
585
vsock->net);
drivers/vhost/vsock.c
702
struct net *net;
drivers/vhost/vsock.c
718
net = current->nsproxy->net_ns;
drivers/vhost/vsock.c
719
vsock->net = get_net_track(net, &vsock->ns_tracker, GFP_KERNEL);
drivers/vhost/vsock.c
74
static struct vhost_vsock *vhost_vsock_get(u32 guest_cid, struct net *net)
drivers/vhost/vsock.c
811
put_net_track(vsock->net, &vsock->ns_tracker);
drivers/vhost/vsock.c
838
other = vhost_vsock_get(guest_cid, vsock->net);
drivers/vhost/vsock.c
87
vsock_net_check_mode(net, vsock->net))
drivers/vhost/vsock.c
97
struct net *net = sock_net(sk);
fs/afs/addr_list.c
220
ret = afs_merge_fs_addr4(net, alist, x[0], xport);
fs/afs/addr_list.c
222
ret = afs_merge_fs_addr6(net, alist, x, xport);
fs/afs/addr_list.c
243
afs_put_vlserverlist(net, vllist);
fs/afs/addr_list.c
258
ret = dns_query(cell->net->net, "afsdb", cell->name, cell->name_len,
fs/afs/addr_list.c
271
vllist = afs_parse_text_addrs(cell->net, result, ret, ',',
fs/afs/addr_list.c
283
int afs_merge_fs_addr4(struct afs_net *net, struct afs_addr_list *alist,
fs/afs/addr_list.c
300
peer = rxrpc_kernel_lookup_peer(net->socket, &srx, GFP_KERNEL);
fs/afs/addr_list.c
327
int afs_merge_fs_addr6(struct afs_net *net, struct afs_addr_list *alist,
fs/afs/addr_list.c
344
peer = rxrpc_kernel_lookup_peer(net->socket, &srx, GFP_KERNEL);
fs/afs/addr_list.c
83
struct afs_vlserver_list *afs_parse_text_addrs(struct afs_net *net,
fs/afs/addr_prefs.c
250
static int afs_add_address_pref(struct afs_net *net, struct afs_addr_preference_list **_preflist,
fs/afs/addr_prefs.c
330
static int afs_del_address_pref(struct afs_net *net, struct afs_addr_preference_list **_preflist,
fs/afs/addr_prefs.c
383
struct afs_net *net = afs_seq2net_single(m);
fs/afs/addr_prefs.c
391
old = rcu_dereference_protected(net->address_prefs,
fs/afs/addr_prefs.c
424
ret = afs_add_address_pref(net, &preflist, argc - 1, argv + 1);
fs/afs/addr_prefs.c
426
ret = afs_del_address_pref(net, &preflist, argc - 1, argv + 1);
fs/afs/addr_prefs.c
434
rcu_assign_pointer(net->address_prefs, preflist);
fs/afs/addr_prefs.c
436
smp_store_release(&net->address_pref_version, preflist->version);
fs/afs/addr_prefs.c
457
void afs_get_address_preferences_rcu(struct afs_net *net, struct afs_addr_list *alist)
fs/afs/addr_prefs.c
460
rcu_dereference(net->address_prefs);
fs/afs/addr_prefs.c
523
void afs_get_address_preferences(struct afs_net *net, struct afs_addr_list *alist)
fs/afs/addr_prefs.c
525
if (!net->address_prefs ||
fs/afs/addr_prefs.c
527
smp_load_acquire(&net->address_pref_version) == alist->addr_pref_version)
fs/afs/addr_prefs.c
531
afs_get_address_preferences_rcu(net, alist);
fs/afs/cell.c
100
up_read(&net->cells_lock);
fs/afs/cell.c
108
static struct afs_cell *afs_alloc_cell(struct afs_net *net,
fs/afs/cell.c
162
cell->net = net;
fs/afs/cell.c
181
vllist = afs_parse_text_addrs(net,
fs/afs/cell.c
208
atomic_inc(&net->cells_outstanding);
fs/afs/cell.c
220
afs_put_vlserverlist(cell->net, vllist);
fs/afs/cell.c
241
struct afs_cell *afs_lookup_cell(struct afs_net *net,
fs/afs/cell.c
255
cell = afs_find_cell(net, name, namesz, trace);
fs/afs/cell.c
27
static void afs_dec_cells_outstanding(struct afs_net *net)
fs/afs/cell.c
273
candidate = afs_alloc_cell(net, name, namesz, vllist);
fs/afs/cell.c
282
down_write(&net->cells_lock);
fs/afs/cell.c
284
pp = &net->cells.rb_node;
fs/afs/cell.c
29
if (atomic_dec_and_test(&net->cells_outstanding))
fs/afs/cell.c
30
wake_up_var(&net->cells_outstanding);
fs/afs/cell.c
302
ret = idr_alloc_cyclic(&net->cells_dyn_ino, candidate,
fs/afs/cell.c
313
rb_insert_color(&cell->net_node, &net->cells);
fs/afs/cell.c
314
up_write(&net->cells_lock);
fs/afs/cell.c
384
up_write(&net->cells_lock);
fs/afs/cell.c
397
up_write(&net->cells_lock);
fs/afs/cell.c
415
int afs_cell_init(struct afs_net *net, const char *rootcell)
fs/afs/cell.c
44
static struct afs_cell *afs_find_cell_locked(struct afs_net *net,
fs/afs/cell.c
450
new_root = afs_lookup_cell(net, rootcell, len, vllist,
fs/afs/cell.c
462
down_write(&net->cells_lock);
fs/afs/cell.c
463
old_root = rcu_replace_pointer(net->ws_cell, new_root,
fs/afs/cell.c
464
lockdep_is_held(&net->cells_lock));
fs/afs/cell.c
465
up_write(&net->cells_lock);
fs/afs/cell.c
561
afs_put_vlserverlist(cell->net, old);
fs/afs/cell.c
577
struct afs_net *net = cell->net;
fs/afs/cell.c
586
afs_put_vlserverlist(net, rcu_access_pointer(cell->vl_servers));
fs/afs/cell.c
592
afs_dec_cells_outstanding(net);
fs/afs/cell.c
60
cell = rcu_dereference_protected(net->ws_cell,
fs/afs/cell.c
605
down_write(&cell->net->cells_lock);
fs/afs/cell.c
606
idr_remove(&cell->net->cells_dyn_ino, cell->dynroot_ino);
fs/afs/cell.c
607
up_write(&cell->net->cells_lock);
fs/afs/cell.c
61
lockdep_is_held(&net->cells_lock));
fs/afs/cell.c
67
p = net->cells.rb_node;
fs/afs/cell.c
722
if (refcount_read(&cell->ref) > 0 && cell->net->live)
fs/afs/cell.c
737
static int afs_activate_cell(struct afs_net *net, struct afs_cell *cell)
fs/afs/cell.c
747
mutex_lock(&net->proc_cells_lock);
fs/afs/cell.c
748
for (p = &net->proc_cells.first; *p; p = &(*p)->next) {
fs/afs/cell.c
760
mutex_unlock(&net->proc_cells_lock);
fs/afs/cell.c
767
static void afs_deactivate_cell(struct afs_net *net, struct afs_cell *cell)
fs/afs/cell.c
773
mutex_lock(&net->proc_cells_lock);
fs/afs/cell.c
776
mutex_unlock(&net->proc_cells_lock);
fs/afs/cell.c
789
if (!cell->net->live)
fs/afs/cell.c
809
struct afs_net *net = cell->net;
fs/afs/cell.c
834
ret = afs_activate_cell(net, cell);
fs/afs/cell.c
854
if (next_manage < TIME64_MAX && cell->net->live) {
fs/afs/cell.c
866
down_write(&net->cells_lock);
fs/afs/cell.c
869
up_write(&net->cells_lock);
fs/afs/cell.c
878
afs_deactivate_cell(net, cell);
fs/afs/cell.c
881
rb_erase(&cell->net_node, &net->cells);
fs/afs/cell.c
883
up_write(&net->cells_lock);
fs/afs/cell.c
908
void afs_cell_purge(struct afs_net *net)
fs/afs/cell.c
915
down_write(&net->cells_lock);
fs/afs/cell.c
916
ws = rcu_replace_pointer(net->ws_cell, NULL,
fs/afs/cell.c
917
lockdep_is_held(&net->cells_lock));
fs/afs/cell.c
918
up_write(&net->cells_lock);
fs/afs/cell.c
92
struct afs_cell *afs_find_cell(struct afs_net *net,
fs/afs/cell.c
922
down_read(&net->cells_lock);
fs/afs/cell.c
923
for (cursor = rb_first(&net->cells); cursor; cursor = rb_next(cursor)) {
fs/afs/cell.c
933
up_read(&net->cells_lock);
fs/afs/cell.c
936
wait_var_event(&net->cells_outstanding,
fs/afs/cell.c
937
!atomic_read(&net->cells_outstanding));
fs/afs/cell.c
98
down_read(&net->cells_lock);
fs/afs/cell.c
99
cell = afs_find_cell_locked(net, name, namesz, reason);
fs/afs/cm_security.c
100
struct afs_net *net = container_of(work, struct afs_net, rx_oob_work);
fs/afs/cm_security.c
104
while (READ_ONCE(net->live) &&
fs/afs/cm_security.c
105
(oob = rxrpc_kernel_dequeue_oob(net->socket, &type))) {
fs/afs/cm_security.c
121
int afs_create_token_key(struct afs_net *net, struct socket *socket)
fs/afs/cm_security.c
170
net->fs_cm_token_key = key_ref_to_ptr(key);
fs/afs/cm_security.c
187
struct afs_net *net = server->cell->net;
fs/afs/cm_security.c
188
const struct key *key = net->fs_cm_token_key;
fs/afs/cm_security.c
272
memcpy(xdr, &net->uuid, 16); /* appdata.initiatorUuid */
fs/afs/cmservice.c
156
rxrpc_kernel_abort_call(call->net->socket, call->rxcall,
fs/afs/cmservice.c
423
if (memcmp(r, &call->net->uuid, sizeof(call->net->uuid)) == 0)
fs/afs/cmservice.c
515
reply.ia.uuid[0] = call->net->uuid.time_low;
fs/afs/cmservice.c
516
reply.ia.uuid[1] = htonl(ntohs(call->net->uuid.time_mid));
fs/afs/cmservice.c
517
reply.ia.uuid[2] = htonl(ntohs(call->net->uuid.time_hi_and_version));
fs/afs/cmservice.c
518
reply.ia.uuid[3] = htonl((s8) call->net->uuid.clock_seq_hi_and_reserved);
fs/afs/cmservice.c
519
reply.ia.uuid[4] = htonl((s8) call->net->uuid.clock_seq_low);
fs/afs/cmservice.c
521
reply.ia.uuid[loop + 5] = htonl((s8) call->net->uuid.node[loop]);
fs/afs/dir.c
911
struct afs_net *net = afs_i2net(dir);
fs/afs/dir.c
928
read_lock(&net->sysnames_lock);
fs/afs/dir.c
929
subs = net->sysnames;
fs/afs/dir.c
931
read_unlock(&net->sysnames_lock);
fs/afs/dynroot.c
111
cell = afs_lookup_cell(net, name, len, NULL,
fs/afs/dynroot.c
210
struct afs_net *net = afs_i2net(inode);
fs/afs/dynroot.c
214
if (!rcu_access_pointer(net->ws_cell))
fs/afs/dynroot.c
219
cell = rcu_dereference(net->ws_cell);
fs/afs/dynroot.c
228
down_read(&net->cells_lock);
fs/afs/dynroot.c
230
cell = rcu_dereference_protected(net->ws_cell, lockdep_is_held(&net->cells_lock));
fs/afs/dynroot.c
238
up_read(&net->cells_lock);
fs/afs/dynroot.c
284
static int afs_dynroot_readdir_cells(struct afs_net *net, struct dir_context *ctx)
fs/afs/dynroot.c
294
cell = idr_get_next(&net->cells_dyn_ino, &ix);
fs/afs/dynroot.c
332
struct afs_net *net = afs_d2net(file->f_path.dentry);
fs/afs/dynroot.c
339
if (rcu_access_pointer(net->ws_cell) &&
fs/afs/dynroot.c
345
if (rcu_access_pointer(net->ws_cell) &&
fs/afs/dynroot.c
352
down_read(&net->cells_lock);
fs/afs/dynroot.c
353
ret = afs_dynroot_readdir_cells(net, ctx);
fs/afs/dynroot.c
354
up_read(&net->cells_lock);
fs/afs/dynroot.c
97
struct afs_net *net = afs_d2net(dentry);
fs/afs/file.c
221
atomic_long_add(op->fetch.subreq->transferred, &op->net->n_fetch_bytes);
fs/afs/file.c
290
if (rxrpc_kernel_check_life(call->net->socket, call->rxcall))
fs/afs/fs_operation.c
365
afs_put_serverlist(op->net, op->server_list);
fs/afs/fs_operation.c
40
op->net = volume->cell->net;
fs/afs/fs_probe.c
105
afs_finished_fs_probe(net, server, estate);
fs/afs/fs_probe.c
114
static void afs_fs_probe_not_done(struct afs_net *net,
fs/afs/fs_probe.c
131
return afs_done_one_fs_probe(net, server, estate);
fs/afs/fs_probe.c
231
return afs_done_one_fs_probe(call->net, server, estate);
fs/afs/fs_probe.c
238
int afs_fs_probe_fileserver(struct afs_net *net, struct afs_server *server,
fs/afs/fs_probe.c
283
afs_get_address_preferences(net, new_alist);
fs/afs/fs_probe.c
301
if (!afs_fs_get_capabilities(net, server, estate, index, key))
fs/afs/fs_probe.c
302
afs_fs_probe_not_done(net, server, estate, index);
fs/afs/fs_probe.c
378
struct afs_net *net = container_of(timer, struct afs_net, fs_probe_timer);
fs/afs/fs_probe.c
380
if (!net->live || !queue_work(afs_wq, &net->fs_prober))
fs/afs/fs_probe.c
381
afs_dec_servers_outstanding(net);
fs/afs/fs_probe.c
387
static void afs_dispatch_fs_probe(struct afs_net *net, struct afs_server *server)
fs/afs/fs_probe.c
388
__releases(&net->fs_lock)
fs/afs/fs_probe.c
398
write_sequnlock(&net->fs_lock);
fs/afs/fs_probe.c
400
afs_fs_probe_fileserver(net, server, NULL, key);
fs/afs/fs_probe.c
401
afs_put_server(net, server, afs_server_trace_put_probe);
fs/afs/fs_probe.c
408
void afs_probe_fileserver(struct afs_net *net, struct afs_server *server)
fs/afs/fs_probe.c
410
write_seqlock(&net->fs_lock);
fs/afs/fs_probe.c
412
return afs_dispatch_fs_probe(net, server);
fs/afs/fs_probe.c
413
write_sequnlock(&net->fs_lock);
fs/afs/fs_probe.c
421
struct afs_net *net = container_of(work, struct afs_net, fs_prober);
fs/afs/fs_probe.c
426
if (!net->live) {
fs/afs/fs_probe.c
427
afs_dec_servers_outstanding(net);
fs/afs/fs_probe.c
433
if (list_empty(&net->fs_probe_fast) && list_empty(&net->fs_probe_slow)) {
fs/afs/fs_probe.c
434
afs_dec_servers_outstanding(net);
fs/afs/fs_probe.c
440
write_seqlock(&net->fs_lock);
fs/afs/fs_probe.c
446
if (!list_empty(&net->fs_probe_fast)) {
fs/afs/fs_probe.c
447
fast = list_first_entry(&net->fs_probe_fast, struct afs_server, probe_link);
fs/afs/fs_probe.c
456
if (!list_empty(&net->fs_probe_slow)) {
fs/afs/fs_probe.c
457
slow = list_first_entry(&net->fs_probe_slow, struct afs_server, probe_link);
fs/afs/fs_probe.c
472
afs_dispatch_fs_probe(net, server);
fs/afs/fs_probe.c
477
write_sequnlock(&net->fs_lock);
fs/afs/fs_probe.c
480
if (!queue_work(afs_wq, &net->fs_prober))
fs/afs/fs_probe.c
481
afs_dec_servers_outstanding(net);
fs/afs/fs_probe.c
484
if (timer_reduce(&net->fs_probe_timer, timer_at))
fs/afs/fs_probe.c
485
afs_dec_servers_outstanding(net);
fs/afs/fs_probe.c
488
afs_dec_servers_outstanding(net);
fs/afs/fs_probe.c
535
void afs_fs_probe_cleanup(struct afs_net *net)
fs/afs/fs_probe.c
537
if (timer_delete_sync(&net->fs_probe_timer))
fs/afs/fs_probe.c
538
afs_dec_servers_outstanding(net);
fs/afs/fs_probe.c
58
static void afs_schedule_fs_probe(struct afs_net *net,
fs/afs/fs_probe.c
63
if (!net->live)
fs/afs/fs_probe.c
69
afs_inc_servers_outstanding(net);
fs/afs/fs_probe.c
70
if (timer_reduce(&net->fs_probe_timer, atj))
fs/afs/fs_probe.c
71
afs_dec_servers_outstanding(net);
fs/afs/fs_probe.c
77
static void afs_finished_fs_probe(struct afs_net *net, struct afs_server *server,
fs/afs/fs_probe.c
82
write_seqlock(&net->fs_lock);
fs/afs/fs_probe.c
84
list_add_tail(&server->probe_link, &net->fs_probe_slow);
fs/afs/fs_probe.c
88
list_add_tail(&server->probe_link, &net->fs_probe_fast);
fs/afs/fs_probe.c
91
write_sequnlock(&net->fs_lock);
fs/afs/fs_probe.c
93
afs_schedule_fs_probe(net, server, !responded);
fs/afs/fs_probe.c
99
static void afs_done_one_fs_probe(struct afs_net *net, struct afs_server *server,
fs/afs/fsclient.c
1082
call = afs_alloc_flat_call(op->net, &afs_RXFSStoreData64,
fs/afs/fsclient.c
1136
call = afs_alloc_flat_call(op->net, &afs_RXFSStoreData,
fs/afs/fsclient.c
1207
call = afs_alloc_flat_call(op->net, &afs_RXFSStoreData64_as_Status,
fs/afs/fsclient.c
1252
call = afs_alloc_flat_call(op->net, &afs_RXFSStoreData_as_Status,
fs/afs/fsclient.c
1293
call = afs_alloc_flat_call(op->net, &afs_RXFSStoreStatus,
fs/afs/fsclient.c
1462
call = afs_alloc_flat_call(op->net, &afs_RXFSGetVolumeStatus, 2 * 4,
fs/afs/fsclient.c
1543
call = afs_alloc_flat_call(op->net, &afs_RXFSSetLock, 5 * 4, 6 * 4);
fs/afs/fsclient.c
1571
call = afs_alloc_flat_call(op->net, &afs_RXFSExtendLock, 4 * 4, 6 * 4);
fs/afs/fsclient.c
1598
call = afs_alloc_flat_call(op->net, &afs_RXFSReleaseLock, 4 * 4, 6 * 4);
fs/afs/fsclient.c
1635
int afs_fs_give_up_all_callbacks(struct afs_net *net, struct afs_server *server,
fs/afs/fsclient.c
1644
call = afs_alloc_flat_call(net, &afs_RXFSGiveUpAllCallBacks, 1 * 4, 0);
fs/afs/fsclient.c
1749
bool afs_fs_get_capabilities(struct afs_net *net, struct afs_server *server,
fs/afs/fsclient.c
1758
call = afs_alloc_flat_call(net, &afs_RXFSGetCapabilities, 1 * 4, 16 * 4);
fs/afs/fsclient.c
1957
call = afs_alloc_flat_call(op->net, &afs_RXFSInlineBulkStatus,
fs/afs/fsclient.c
2074
call = afs_alloc_flat_call(op->net, &afs_RXFSFetchACL, 16, (21 + 6) * 4);
fs/afs/fsclient.c
2115
call = afs_alloc_flat_call(op->net, &afs_RXFSStoreACL,
fs/afs/fsclient.c
281
call = afs_alloc_flat_call(op->net, &afs_RXFSFetchStatus,
fs/afs/fsclient.c
438
call = afs_alloc_flat_call(op->net, &afs_RXFSFetchData64, 32, (21 + 3 + 6) * 4);
fs/afs/fsclient.c
476
call = afs_alloc_flat_call(op->net, &afs_RXFSFetchData, 24, (21 + 3 + 6) * 4);
fs/afs/fsclient.c
548
call = afs_alloc_flat_call(op->net, &afs_RXFSCreateFile,
fs/afs/fsclient.c
602
call = afs_alloc_flat_call(op->net, &afs_RXFSMakeDir,
fs/afs/fsclient.c
682
call = afs_alloc_flat_call(op->net, &afs_RXFSRemoveFile,
fs/afs/fsclient.c
730
call = afs_alloc_flat_call(op->net, &afs_RXFSRemoveDir,
fs/afs/fsclient.c
809
call = afs_alloc_flat_call(op->net, &afs_RXFSLink, reqsz, (21 + 21 + 6) * 4);
fs/afs/fsclient.c
894
call = afs_alloc_flat_call(op->net, &afs_RXFSSymlink, reqsz,
fs/afs/fsclient.c
994
call = afs_alloc_flat_call(op->net, &afs_RXFSRename, reqsz, (21 + 21 + 6) * 4);
fs/afs/internal.h
1019
extern int afs_merge_fs_addr4(struct afs_net *net, struct afs_addr_list *addr,
fs/afs/internal.h
1021
extern int afs_merge_fs_addr6(struct afs_net *net, struct afs_addr_list *addr,
fs/afs/internal.h
1031
void afs_get_address_preferences_rcu(struct afs_net *net, struct afs_addr_list *alist);
fs/afs/internal.h
1032
void afs_get_address_preferences(struct afs_net *net, struct afs_addr_list *alist);
fs/afs/internal.h
1070
struct afs_cell *afs_lookup_cell(struct afs_net *net,
fs/afs/internal.h
1094
int afs_create_token_key(struct afs_net *net, struct socket *socket);
fs/afs/internal.h
1096
static inline int afs_create_token_key(struct afs_net *net, struct socket *socket)
fs/afs/internal.h
1197
int afs_fs_give_up_all_callbacks(struct afs_net *net, struct afs_server *server,
fs/afs/internal.h
1199
bool afs_fs_get_capabilities(struct afs_net *net, struct afs_server *server,
fs/afs/internal.h
1242
int afs_fs_probe_fileserver(struct afs_net *net, struct afs_server *server,
fs/afs/internal.h
1273
static inline struct afs_net *afs_net(struct net *net)
fs/afs/internal.h
1275
return net_generic(net, afs_net_id);
fs/afs/internal.h
1361
static inline int afs_proc_init(struct afs_net *net) { return 0; }
fs/afs/internal.h
1362
static inline void afs_proc_cleanup(struct afs_net *net) {}
fs/afs/internal.h
137
struct afs_net *net; /* The network namespace */
fs/afs/internal.h
1405
atomic_read(&call->net->nr_outstanding_calls),
fs/afs/internal.h
1415
atomic_read(&call->net->nr_outstanding_calls),
fs/afs/internal.h
1545
void afs_unuse_server(struct afs_net *net, struct afs_server *server,
fs/afs/internal.h
1547
void afs_unuse_server_notime(struct afs_net *net, struct afs_server *server,
fs/afs/internal.h
1552
void __net_exit afs_wait_for_servers(struct afs_net *net);
fs/afs/internal.h
1564
static inline void afs_inc_servers_outstanding(struct afs_net *net)
fs/afs/internal.h
1566
atomic_inc(&net->servers_outstanding);
fs/afs/internal.h
1569
static inline void afs_dec_servers_outstanding(struct afs_net *net)
fs/afs/internal.h
1571
if (atomic_dec_and_test(&net->servers_outstanding))
fs/afs/internal.h
1572
wake_up_var(&net->servers_outstanding);
fs/afs/internal.h
1633
struct afs_call *afs_vl_get_capabilities(struct afs_net *net,
fs/afs/internal.h
249
struct net *net_ns; /* Network namespace */
fs/afs/internal.h
278
struct net *net; /* Backpointer to the owning net namespace */
fs/afs/internal.h
375
struct afs_net *net;
fs/afs/internal.h
59
struct afs_net *net; /* the AFS net namespace stuff */
fs/afs/internal.h
871
struct afs_net *net; /* Network namespace */
fs/afs/main.c
102
net->sysnames = sysnames;
fs/afs/main.c
103
rwlock_init(&net->sysnames_lock);
fs/afs/main.c
106
ret = afs_proc_init(net);
fs/afs/main.c
111
ret = afs_cell_init(net, rootcell);
fs/afs/main.c
116
ret = afs_open_socket(net);
fs/afs/main.c
123
net->live = false;
fs/afs/main.c
124
afs_fs_probe_cleanup(net);
fs/afs/main.c
125
afs_cell_purge(net);
fs/afs/main.c
126
afs_wait_for_servers(net);
fs/afs/main.c
128
net->live = false;
fs/afs/main.c
129
afs_proc_cleanup(net);
fs/afs/main.c
131
afs_put_sysnames(net->sysnames);
fs/afs/main.c
133
idr_destroy(&net->cells_dyn_ino);
fs/afs/main.c
134
net->live = false;
fs/afs/main.c
141
static void __net_exit afs_net_exit(struct net *net_ns)
fs/afs/main.c
143
struct afs_net *net = afs_net(net_ns);
fs/afs/main.c
145
net->live = false;
fs/afs/main.c
146
afs_fs_probe_cleanup(net);
fs/afs/main.c
147
afs_cell_purge(net);
fs/afs/main.c
148
afs_wait_for_servers(net);
fs/afs/main.c
149
afs_close_socket(net);
fs/afs/main.c
150
afs_proc_cleanup(net);
fs/afs/main.c
151
afs_put_sysnames(net->sysnames);
fs/afs/main.c
152
idr_destroy(&net->cells_dyn_ino);
fs/afs/main.c
153
kfree_rcu(rcu_access_pointer(net->address_prefs), rcu);
fs/afs/main.c
65
static int __net_init afs_net_init(struct net *net_ns)
fs/afs/main.c
68
struct afs_net *net = afs_net(net_ns);
fs/afs/main.c
71
net->net = net_ns;
fs/afs/main.c
72
net->live = true;
fs/afs/main.c
73
generate_random_uuid((unsigned char *)&net->uuid);
fs/afs/main.c
75
INIT_WORK(&net->charge_preallocation_work, afs_charge_preallocation);
fs/afs/main.c
76
INIT_WORK(&net->rx_oob_work, afs_process_oob_queue);
fs/afs/main.c
77
mutex_init(&net->socket_mutex);
fs/afs/main.c
79
net->cells = RB_ROOT;
fs/afs/main.c
80
idr_init(&net->cells_dyn_ino);
fs/afs/main.c
81
init_rwsem(&net->cells_lock);
fs/afs/main.c
82
mutex_init(&net->cells_alias_lock);
fs/afs/main.c
83
mutex_init(&net->proc_cells_lock);
fs/afs/main.c
84
INIT_HLIST_HEAD(&net->proc_cells);
fs/afs/main.c
86
seqlock_init(&net->fs_lock);
fs/afs/main.c
87
INIT_LIST_HEAD(&net->fs_probe_fast);
fs/afs/main.c
88
INIT_LIST_HEAD(&net->fs_probe_slow);
fs/afs/main.c
89
INIT_HLIST_HEAD(&net->fs_proc);
fs/afs/main.c
91
INIT_WORK(&net->fs_prober, afs_fs_probe_dispatcher);
fs/afs/main.c
92
timer_setup(&net->fs_probe_timer, afs_fs_probe_timer, 0);
fs/afs/main.c
93
atomic_set(&net->servers_outstanding, 1);
fs/afs/mntpt.c
110
cell = afs_lookup_cell(ctx->net, p, size, NULL,
fs/afs/proc.c
125
cell = afs_lookup_cell(net, name, strlen(name), args,
fs/afs/proc.c
158
struct afs_net *net = afs_seq2net_single(m);
fs/afs/proc.c
167
preflist = rcu_dereference(net->address_prefs);
fs/afs/proc.c
207
struct afs_net *net;
fs/afs/proc.c
209
net = afs_seq2net_single(m);
fs/afs/proc.c
210
down_read(&net->cells_lock);
fs/afs/proc.c
211
cell = rcu_dereference_protected(net->ws_cell, lockdep_is_held(&net->cells_lock));
fs/afs/proc.c
214
up_read(&net->cells_lock);
fs/afs/proc.c
227
struct afs_net *net = afs_seq2net_single(m);
fs/afs/proc.c
247
if (!rcu_access_pointer(net->ws_cell))
fs/afs/proc.c
248
ret = afs_cell_init(net, buf);
fs/afs/proc.c
515
struct afs_net *net = afs_seq2net(m);
fs/afs/proc.c
516
struct afs_sysnames *sysnames = net->sysnames;
fs/afs/proc.c
525
__acquires(&net->sysnames_lock)
fs/afs/proc.c
527
struct afs_net *net = afs_seq2net(m);
fs/afs/proc.c
530
read_lock(&net->sysnames_lock);
fs/afs/proc.c
532
names = net->sysnames;
fs/afs/proc.c
540
struct afs_net *net = afs_seq2net(m);
fs/afs/proc.c
541
struct afs_sysnames *names = net->sysnames;
fs/afs/proc.c
550
__releases(&net->sysnames_lock)
fs/afs/proc.c
552
struct afs_net *net = afs_seq2net(m);
fs/afs/proc.c
554
read_unlock(&net->sysnames_lock);
fs/afs/proc.c
571
struct afs_net *net = afs_seq2net(m);
fs/afs/proc.c
627
write_lock(&net->sysnames_lock);
fs/afs/proc.c
628
kill = net->sysnames;
fs/afs/proc.c
629
net->sysnames = sysnames;
fs/afs/proc.c
630
write_unlock(&net->sysnames_lock);
fs/afs/proc.c
660
struct afs_net *net = afs_seq2net_single(m);
fs/afs/proc.c
665
atomic_read(&net->n_lookup),
fs/afs/proc.c
666
atomic_read(&net->n_reval),
fs/afs/proc.c
667
atomic_read(&net->n_inval),
fs/afs/proc.c
668
atomic_read(&net->n_relpg));
fs/afs/proc.c
671
atomic_read(&net->n_read_dir));
fs/afs/proc.c
674
atomic_read(&net->n_dir_cr),
fs/afs/proc.c
675
atomic_read(&net->n_dir_rm));
fs/afs/proc.c
678
atomic_read(&net->n_fetches),
fs/afs/proc.c
679
atomic_long_read(&net->n_fetch_bytes));
fs/afs/proc.c
681
atomic_read(&net->n_stores),
fs/afs/proc.c
682
atomic_long_read(&net->n_store_bytes));
fs/afs/proc.c
692
struct afs_net *net = cell->net;
fs/afs/proc.c
694
_enter("%p{%s},%p", cell, cell->name, net->proc_afs);
fs/afs/proc.c
696
dir = proc_net_mkdir(net->net, cell->name, net->proc_afs);
fs/afs/proc.c
714
remove_proc_subtree(cell->name, net->proc_afs);
fs/afs/proc.c
725
struct afs_net *net = cell->net;
fs/afs/proc.c
728
remove_proc_subtree(cell->name, net->proc_afs);
fs/afs/proc.c
735
int afs_proc_init(struct afs_net *net)
fs/afs/proc.c
741
p = proc_net_mkdir(net->net, "afs", net->net->proc_net);
fs/afs/proc.c
768
net->proc_afs = p;
fs/afs/proc.c
782
void afs_proc_cleanup(struct afs_net *net)
fs/afs/proc.c
784
proc_remove(net->proc_afs);
fs/afs/proc.c
785
net->proc_afs = NULL;
fs/afs/proc.c
91
struct afs_net *net = afs_seq2net(m);
fs/afs/rotate.c
487
afs_put_serverlist(op->net, op->server_list);
fs/afs/rotate.c
557
afs_get_address_preferences_rcu(op->net, sal);
fs/afs/rotate.c
655
afs_probe_fileserver(op->net, op->server);
fs/afs/rotate.c
69
afs_get_address_preferences(op->net, estate->addresses);
fs/afs/rxrpc.c
111
net->socket = socket;
fs/afs/rxrpc.c
112
afs_charge_preallocation(&net->charge_preallocation_work);
fs/afs/rxrpc.c
126
void afs_close_socket(struct afs_net *net)
fs/afs/rxrpc.c
130
cancel_work_sync(&net->charge_preallocation_work);
fs/afs/rxrpc.c
131
cancel_work_sync(&net->rx_oob_work);
fs/afs/rxrpc.c
134
kernel_listen(net->socket, 0);
fs/afs/rxrpc.c
138
cancel_work_sync(&net->charge_preallocation_work);
fs/afs/rxrpc.c
140
if (net->spare_incoming_call) {
fs/afs/rxrpc.c
141
afs_put_call(net->spare_incoming_call);
fs/afs/rxrpc.c
142
net->spare_incoming_call = NULL;
fs/afs/rxrpc.c
145
_debug("outstanding %u", atomic_read(&net->nr_outstanding_calls));
fs/afs/rxrpc.c
146
wait_var_event(&net->nr_outstanding_calls,
fs/afs/rxrpc.c
147
!atomic_read(&net->nr_outstanding_calls));
fs/afs/rxrpc.c
150
kernel_sock_shutdown(net->socket, SHUT_RDWR);
fs/afs/rxrpc.c
152
cancel_work_sync(&net->rx_oob_work);
fs/afs/rxrpc.c
153
net->socket->sk->sk_user_data = NULL;
fs/afs/rxrpc.c
154
sock_release(net->socket);
fs/afs/rxrpc.c
155
key_put(net->fs_cm_token_key);
fs/afs/rxrpc.c
164
static struct afs_call *afs_alloc_call(struct afs_net *net,
fs/afs/rxrpc.c
176
call->net = net;
fs/afs/rxrpc.c
186
o = atomic_inc_return(&net->nr_outstanding_calls);
fs/afs/rxrpc.c
194
struct afs_net *net = call->net;
fs/afs/rxrpc.c
202
rxrpc_kernel_shutdown_call(net->socket, call->rxcall);
fs/afs/rxrpc.c
203
rxrpc_kernel_put_call(net->socket, call->rxcall);
fs/afs/rxrpc.c
209
afs_unuse_server_notime(call->net, call->server, afs_server_trace_unuse_call);
fs/afs/rxrpc.c
212
o = atomic_read(&net->nr_outstanding_calls);
fs/afs/rxrpc.c
217
o = atomic_dec_return(&net->nr_outstanding_calls);
fs/afs/rxrpc.c
219
wake_up_var(&net->nr_outstanding_calls);
fs/afs/rxrpc.c
227
struct afs_net *net = call->net;
fs/afs/rxrpc.c
233
o = atomic_read(&net->nr_outstanding_calls);
fs/afs/rxrpc.c
253
struct afs_net *net = call->net;
fs/afs/rxrpc.c
259
o = atomic_read(&net->nr_outstanding_calls);
fs/afs/rxrpc.c
281
struct afs_call *afs_alloc_flat_call(struct afs_net *net,
fs/afs/rxrpc.c
287
call = afs_alloc_call(net, type, GFP_NOFS);
fs/afs/rxrpc.c
361
atomic_read(&call->net->nr_outstanding_calls));
fs/afs/rxrpc.c
382
rxcall = rxrpc_kernel_begin_call(call->net->socket, call->peer, call->key,
fs/afs/rxrpc.c
415
ret = rxrpc_kernel_send_data(call->net->socket, rxcall,
fs/afs/rxrpc.c
426
ret = rxrpc_kernel_send_data(call->net->socket,
fs/afs/rxrpc.c
447
rxrpc_kernel_abort_call(call->net->socket, rxcall,
fs/afs/rxrpc.c
458
rxrpc_kernel_recv_data(call->net->socket, rxcall,
fs/afs/rxrpc.c
476
rxrpc_kernel_shutdown_call(call->net->socket, call->rxcall);
fs/afs/rxrpc.c
48
int afs_open_socket(struct afs_net *net)
fs/afs/rxrpc.c
542
ret = rxrpc_kernel_recv_data(call->net->socket,
fs/afs/rxrpc.c
56
ret = sock_create_kern(net->net, AF_RXRPC, SOCK_DGRAM, PF_INET6, &socket);
fs/afs/rxrpc.c
585
rxrpc_kernel_abort_call(call->net->socket, call->rxcall,
fs/afs/rxrpc.c
601
rxrpc_kernel_abort_call(call->net->socket, call->rxcall,
fs/afs/rxrpc.c
607
rxrpc_kernel_abort_call(call->net->socket, call->rxcall,
fs/afs/rxrpc.c
61
socket->sk->sk_user_data = net;
fs/afs/rxrpc.c
656
if (!rxrpc_kernel_check_life(call->net->socket, call->rxcall)) {
fs/afs/rxrpc.c
675
if (rxrpc_kernel_abort_call(call->net->socket, call->rxcall,
fs/afs/rxrpc.c
710
atomic_read(&call->net->nr_outstanding_calls),
fs/afs/rxrpc.c
749
struct afs_net *net =
fs/afs/rxrpc.c
751
struct afs_call *call = net->spare_incoming_call;
fs/afs/rxrpc.c
753
while (READ_ONCE(net->live)) {
fs/afs/rxrpc.c
755
call = afs_alloc_call(net, &afs_RXCMxxxx, GFP_KERNEL);
fs/afs/rxrpc.c
766
if (rxrpc_kernel_charge_accept(net->socket,
fs/afs/rxrpc.c
774
net->spare_incoming_call = call;
fs/afs/rxrpc.c
796
struct afs_net *net = afs_sock2net(sk);
fs/afs/rxrpc.c
803
if (net->live)
fs/afs/rxrpc.c
804
queue_work(afs_wq, &net->charge_preallocation_work);
fs/afs/rxrpc.c
81
ret = afs_create_token_key(net, socket);
fs/afs/rxrpc.c
860
struct afs_net *net = call->net;
fs/afs/rxrpc.c
865
rxrpc_kernel_set_tx_length(net->socket, call->rxcall, 0);
fs/afs/rxrpc.c
874
switch (rxrpc_kernel_send_data(net->socket, call->rxcall, &msg, 0,
fs/afs/rxrpc.c
882
rxrpc_kernel_abort_call(net->socket, call->rxcall,
fs/afs/rxrpc.c
897
struct afs_net *net = call->net;
fs/afs/rxrpc.c
904
rxrpc_kernel_set_tx_length(net->socket, call->rxcall, len);
fs/afs/rxrpc.c
915
n = rxrpc_kernel_send_data(net->socket, call->rxcall, &msg, len,
fs/afs/rxrpc.c
925
rxrpc_kernel_abort_call(net->socket, call->rxcall,
fs/afs/rxrpc.c
937
struct afs_net *net = call->net;
fs/afs/rxrpc.c
946
ret = rxrpc_kernel_recv_data(net->socket, call->rxcall, iter,
fs/afs/rxrpc.c
992
struct afs_net *net = sk->sk_user_data;
fs/afs/rxrpc.c
994
if (READ_ONCE(net->live))
fs/afs/rxrpc.c
995
queue_work(afs_wq, &net->rx_oob_work);
fs/afs/security.c
57
cell->net->net, NULL);
fs/afs/security.c
91
cell->net->net);
fs/afs/server.c
100
hlist_add_head_rcu(&server->proc_link, &net->fs_proc);
fs/afs/server.c
101
write_sequnlock(&net->fs_lock);
fs/afs/server.c
116
struct afs_net *net = cell->net;
fs/afs/server.c
144
afs_inc_servers_outstanding(net);
fs/afs/server.c
186
_enter("%p,%pU", cell->net, uuid);
fs/afs/server.c
235
ret = afs_fs_probe_fileserver(cell->net, server, alist, key);
fs/afs/server.c
247
afs_dec_servers_outstanding(cell->net);
fs/afs/server.c
257
afs_put_server(cell->net, server, afs_server_trace_unuse_create_fail);
fs/afs/server.c
278
afs_unuse_server(cell->net, server, afs_server_trace_unuse_create_fail);
fs/afs/server.c
331
void afs_put_server(struct afs_net *net, struct afs_server *server,
fs/afs/server.c
346
__afs_put_server(net, server);
fs/afs/server.c
353
void afs_unuse_server_notime(struct afs_net *net, struct afs_server *server,
fs/afs/server.c
365
afs_put_server(net, server, reason);
fs/afs/server.c
371
void afs_unuse_server(struct afs_net *net, struct afs_server *server,
fs/afs/server.c
389
afs_put_server(net, server, reason);
fs/afs/server.c
405
static void __afs_put_server(struct afs_net *net, struct afs_server *server)
fs/afs/server.c
408
afs_dec_servers_outstanding(net);
fs/afs/server.c
411
static void afs_give_up_callbacks(struct afs_net *net, struct afs_server *server)
fs/afs/server.c
416
afs_fs_give_up_all_callbacks(net, server, &alist->addrs[alist->preferred], NULL);
fs/afs/server.c
429
if (server->cell->net->live ||
fs/afs/server.c
470
struct afs_net *net = server->cell->net;
fs/afs/server.c
484
afs_give_up_callbacks(net, server);
fs/afs/server.c
491
write_seqlock(&net->fs_lock);
fs/afs/server.c
495
write_sequnlock(&net->fs_lock);
fs/afs/server.c
497
afs_put_server(net, server, afs_server_trace_destroy);
fs/afs/server.c
529
void afs_wait_for_servers(struct afs_net *net)
fs/afs/server.c
533
atomic_dec(&net->servers_outstanding);
fs/afs/server.c
534
wait_var_event(&net->servers_outstanding,
fs/afs/server.c
535
!atomic_read(&net->servers_outstanding));
fs/afs/server.c
576
afs_fs_probe_fileserver(op->net, server, alist, key);
fs/afs/server.c
73
struct afs_net *net = cell->net;
fs/afs/server.c
99
write_seqlock(&net->fs_lock);
fs/afs/server_list.c
100
afs_unuse_server_notime(volume->cell->net, server,
fs/afs/server_list.c
12
void afs_put_serverlist(struct afs_net *net, struct afs_server_list *slist)
fs/afs/server_list.c
125
afs_put_serverlist(volume->cell->net, slist);
fs/afs/server_list.c
18
afs_unuse_server(net, slist->servers[i].server,
fs/afs/super.c
292
cell = afs_lookup_cell(ctx->net, cellname, cellnamesz,
fs/afs/super.c
632
ctx->net = afs_net(fc->net_ns);
fs/afs/super.c
635
cell = afs_find_cell(ctx->net, NULL, 0, afs_cell_trace_use_fc);
fs/afs/vl_alias.c
115
hlist_for_each_entry_rcu(p, &cell->net->proc_cells, proc_link) {
fs/afs/vl_alias.c
191
if (mutex_lock_interruptible(&cell->net->proc_cells_lock) < 0)
fs/afs/vl_alias.c
194
hlist_for_each_entry(p, &cell->net->proc_cells, proc_link) {
fs/afs/vl_alias.c
202
mutex_unlock(&cell->net->proc_cells_lock);
fs/afs/vl_alias.c
207
if (mutex_lock_interruptible(&cell->net->proc_cells_lock) < 0) {
fs/afs/vl_alias.c
215
mutex_unlock(&cell->net->proc_cells_lock);
fs/afs/vl_alias.c
25
.net = cell->net,
fs/afs/vl_alias.c
272
master = afs_lookup_cell(cell->net, cell_name, name_len, NULL,
fs/afs/vl_alias.c
320
struct afs_net *net = cell->net;
fs/afs/vl_alias.c
323
if (mutex_lock_interruptible(&net->cells_alias_lock) < 0)
fs/afs/vl_alias.c
334
mutex_unlock(&net->cells_alias_lock);
fs/afs/vl_list.c
117
ret = afs_merge_fs_addr4(net, alist, x[0], port);
fs/afs/vl_list.c
130
ret = afs_merge_fs_addr6(net, alist, x, port);
fs/afs/vl_list.c
264
addrs = afs_extract_vl_addrs(cell->net, &b, end, bs.nr_addrs, bs.port);
fs/afs/vl_list.c
273
afs_put_vlserver(cell->net, server);
fs/afs/vl_list.c
283
afs_put_vlserver(cell->net, server);
fs/afs/vl_list.c
303
afs_put_vlserver(cell->net, server);
fs/afs/vl_list.c
339
afs_put_vlserverlist(cell->net, previous);
fs/afs/vl_list.c
344
afs_put_vlserver(cell->net, server);
fs/afs/vl_list.c
346
afs_put_vlserverlist(cell->net, vllist);
fs/afs/vl_list.c
347
afs_put_vlserverlist(cell->net, previous);
fs/afs/vl_list.c
43
void afs_put_vlserver(struct afs_net *net, struct afs_vlserver *vlserver)
fs/afs/vl_list.c
63
void afs_put_vlserverlist(struct afs_net *net, struct afs_vlserver_list *vllist)
fs/afs/vl_list.c
70
afs_put_vlserver(net, vllist->servers[i].server);
fs/afs/vl_list.c
89
static struct afs_addr_list *afs_extract_vl_addrs(struct afs_net *net,
fs/afs/vl_probe.c
146
static bool afs_do_probe_vlserver(struct afs_net *net,
fs/afs/vl_probe.c
185
call = afs_vl_get_capabilities(net, alist, index, key, server,
fs/afs/vl_probe.c
204
int afs_send_vl_probes(struct afs_net *net, struct key *key,
fs/afs/vl_probe.c
218
afs_do_probe_vlserver(net, server, key, i, &e))
fs/afs/vl_rotate.c
181
afs_put_vlserverlist(vc->cell->net, vc->server_list);
fs/afs/vl_rotate.c
193
error = afs_send_vl_probes(vc->cell->net, vc->key, vc->server_list);
fs/afs/vl_rotate.c
376
struct afs_net *net = vc->cell->net;
fs/afs/vl_rotate.c
397
afs_put_vlserverlist(net, vc->server_list);
fs/afs/vlclient.c
116
struct afs_net *net = vc->cell->net;
fs/afs/vlclient.c
129
call = afs_alloc_flat_call(net, &afs_RXVLGetEntryByNameU, reqsz,
fs/afs/vlclient.c
227
ret = afs_merge_fs_addr4(call->net, alist, *bp++, AFS_FS_PORT);
fs/afs/vlclient.c
265
struct afs_net *net = vc->cell->net;
fs/afs/vlclient.c
271
call = afs_alloc_flat_call(net, &afs_RXVLGetAddrsU,
fs/afs/vlclient.c
362
afs_put_vlserver(call->net, call->vlserver);
fs/afs/vlclient.c
385
struct afs_call *afs_vl_get_capabilities(struct afs_net *net,
fs/afs/vlclient.c
397
call = afs_alloc_flat_call(net, &afs_RXVLGetCapabilities, 1 * 4, 16 * 4);
fs/afs/vlclient.c
501
ret = afs_merge_fs_addr4(call->net, alist, bp[1], ntohl(bp[2]));
fs/afs/vlclient.c
510
ret = afs_merge_fs_addr6(call->net, alist, bp + 1, ntohl(bp[5]));
fs/afs/vlclient.c
639
struct afs_net *net = vc->cell->net;
fs/afs/vlclient.c
644
call = afs_alloc_flat_call(net, &afs_YFSVLGetEndpoints,
fs/afs/vlclient.c
759
struct afs_net *net = vc->cell->net;
fs/afs/vlclient.c
765
call = afs_alloc_flat_call(net, &afs_YFSVLGetCellName, 1 * 4, 0);
fs/afs/volume.c
250
afs_put_serverlist(volume->cell->net, slist);
fs/afs/volume.c
412
afs_put_serverlist(volume->cell->net, discard);
fs/afs/yfsclient.c
1048
call = afs_alloc_flat_call(op->net, &yfs_RXYFSRename,
fs/afs/yfsclient.c
1200
call = afs_alloc_flat_call(op->net, &yfs_RXYFSRename_Replace,
fs/afs/yfsclient.c
1246
call = afs_alloc_flat_call(op->net, &yfs_RXYFSRename_NoReplace,
fs/afs/yfsclient.c
1290
call = afs_alloc_flat_call(op->net, &yfs_RXYFSRename_Exchange,
fs/afs/yfsclient.c
1349
call = afs_alloc_flat_call(op->net, &yfs_RXYFSStoreData64,
fs/afs/yfsclient.c
1409
call = afs_alloc_flat_call(op->net, &yfs_RXYFSStoreData64_as_Status,
fs/afs/yfsclient.c
1452
call = afs_alloc_flat_call(op->net, &yfs_RXYFSStoreStatus,
fs/afs/yfsclient.c
1623
call = afs_alloc_flat_call(op->net, &yfs_RXYFSGetVolumeStatus,
fs/afs/yfsclient.c
1688
call = afs_alloc_flat_call(op->net, &yfs_RXYFSSetLock,
fs/afs/yfsclient.c
1721
call = afs_alloc_flat_call(op->net, &yfs_RXYFSExtendLock,
fs/afs/yfsclient.c
1752
call = afs_alloc_flat_call(op->net, &yfs_RXYFSReleaseLock,
fs/afs/yfsclient.c
1818
call = afs_alloc_flat_call(op->net, &yfs_RXYFSFetchStatus,
fs/afs/yfsclient.c
1995
call = afs_alloc_flat_call(op->net, &yfs_RXYFSInlineBulkStatus,
fs/afs/yfsclient.c
2162
call = afs_alloc_flat_call(op->net, &yfs_RXYFSFetchOpaqueACL,
fs/afs/yfsclient.c
2208
call = afs_alloc_flat_call(op->net, &yfs_RXYFSStoreOpaqueACL2,
fs/afs/yfsclient.c
480
call = afs_alloc_flat_call(op->net, &yfs_RXYFSFetchData64,
fs/afs/yfsclient.c
571
call = afs_alloc_flat_call(op->net, &afs_RXFSCreateFile, reqsz, rplsz);
fs/afs/yfsclient.c
621
call = afs_alloc_flat_call(op->net, &yfs_RXFSMakeDir, reqsz, rplsz);
fs/afs/yfsclient.c
700
call = afs_alloc_flat_call(op->net, &yfs_RXYFSRemoveFile2,
fs/afs/yfsclient.c
772
call = afs_alloc_flat_call(op->net, &yfs_RXYFSRemoveFile,
fs/afs/yfsclient.c
814
call = afs_alloc_flat_call(op->net, &yfs_RXYFSRemoveDir,
fs/afs/yfsclient.c
885
call = afs_alloc_flat_call(op->net, &yfs_RXYFSLink,
fs/afs/yfsclient.c
964
call = afs_alloc_flat_call(op->net, &yfs_RXYFSSymlink,
fs/lockd/clntlock.c
234
struct net *net = host->net;
fs/lockd/clntlock.c
243
lockd_up(net, NULL); /* note: this cannot fail as lockd is already running */
fs/lockd/clntlock.c
294
lockd_down(net);
fs/lockd/clntlock.c
51
status = lockd_up(nlm_init->net, nlm_init->cred);
fs/lockd/clntlock.c
58
nlm_init->net, nlm_init->cred);
fs/lockd/clntlock.c
69
lockd_down(nlm_init->net);
fs/lockd/clntlock.c
81
struct net *net = host->net;
fs/lockd/clntlock.c
84
lockd_down(net);
fs/lockd/host.c
120
nsm = nsm_get_handle(ni->net, ni->sap, ni->salen,
fs/lockd/host.c
164
host->net = ni->net;
fs/lockd/host.c
180
struct lockd_net *ln = net_generic(host->net, lockd_net_id);
fs/lockd/host.c
221
struct net *net,
fs/lockd/host.c
233
.net = net,
fs/lockd/host.c
239
struct lockd_net *ln = net_generic(net, lockd_net_id);
fs/lockd/host.c
249
if (host->net != net)
fs/lockd/host.c
365
struct net *net = SVC_NET(rqstp);
fs/lockd/host.c
374
.net = net,
fs/lockd/host.c
376
struct lockd_net *ln = net_generic(net, lockd_net_id);
fs/lockd/host.c
385
nlm_gc_hosts(net);
fs/lockd/host.c
389
if (host->net != net)
fs/lockd/host.c
480
.net = host->net,
fs/lockd/host.c
51
static void nlm_gc_hosts(struct net *net);
fs/lockd/host.c
585
void nlm_host_rebooted(const struct net *net, const struct lockd_reboot *info)
fs/lockd/host.c
590
nsm = nsm_reboot_lookup(net, info);
fs/lockd/host.c
611
static void nlm_complain_hosts(struct net *net)
fs/lockd/host.c
616
if (net) {
fs/lockd/host.c
617
struct lockd_net *ln = net_generic(net, lockd_net_id);
fs/lockd/host.c
62
struct net *net; /* network namespace to bind */
fs/lockd/host.c
622
net->ns.inum);
fs/lockd/host.c
624
net->ns.inum);
fs/lockd/host.c
633
if (net && host->net != net)
fs/lockd/host.c
637
host->h_inuse, host->h_expires, host->net->ns.inum);
fs/lockd/host.c
642
nlm_shutdown_hosts_net(struct net *net)
fs/lockd/host.c
651
net ? net->ns.inum : 0);
fs/lockd/host.c
653
if (net && host->net != net)
fs/lockd/host.c
664
nlm_gc_hosts(net);
fs/lockd/host.c
665
nlm_complain_hosts(net);
fs/lockd/host.c
686
nlm_gc_hosts(struct net *net)
fs/lockd/host.c
693
net ? net->ns.inum : 0);
fs/lockd/host.c
695
if (net && host->net != net)
fs/lockd/host.c
701
nlmsvc_mark_resources(net);
fs/lockd/host.c
704
if (net && host->net != net)
fs/lockd/host.c
711
host->net->ns.inum);
fs/lockd/host.c
718
if (net) {
fs/lockd/host.c
719
struct lockd_net *ln = net_generic(net, lockd_net_id);
fs/lockd/lockd.h
111
struct net *net; /* host net */
fs/lockd/lockd.h
283
struct net *net,
fs/lockd/lockd.h
294
void nlm_shutdown_hosts_net(struct net *net);
fs/lockd/lockd.h
295
void nlm_host_rebooted(const struct net *net,
fs/lockd/lockd.h
304
struct nsm_handle *nsm_get_handle(const struct net *net,
fs/lockd/lockd.h
309
struct nsm_handle *nsm_reboot_lookup(const struct net *net,
fs/lockd/lockd.h
326
__be32 nlmsvc_unlock(struct net *net, struct nlm_file *, struct lockd_lock *);
fs/lockd/lockd.h
330
__be32 nlmsvc_cancel_blocked(struct net *net, struct nlm_file *, struct lockd_lock *);
fs/lockd/lockd.h
347
void nlmsvc_mark_resources(struct net *);
fs/lockd/mon.c
111
clnt = nsm_create(host->net, host->nodename);
fs/lockd/mon.c
115
host->net->ns.inum);
fs/lockd/mon.c
317
struct nsm_handle *nsm_get_handle(const struct net *net,
fs/lockd/mon.c
323
struct lockd_net *ln = net_generic(net, lockd_net_id);
fs/lockd/mon.c
379
struct nsm_handle *nsm_reboot_lookup(const struct net *net,
fs/lockd/mon.c
383
struct lockd_net *ln = net_generic(net, lockd_net_id);
fs/lockd/mon.c
68
static struct rpc_clnt *nsm_create(struct net *net, const char *nodename)
fs/lockd/mon.c
75
.net = net,
fs/lockd/svc.c
110
static void set_grace_period(struct net *net)
fs/lockd/svc.c
112
unsigned long grace_period = get_lockd_grace_period(net);
fs/lockd/svc.c
113
struct lockd_net *ln = net_generic(net, lockd_net_id);
fs/lockd/svc.c
115
locks_start_grace(net, &ln->lockd_manager);
fs/lockd/svc.c
127
struct net *net = &init_net;
fs/lockd/svc.c
128
struct lockd_net *ln = net_generic(net, lockd_net_id);
fs/lockd/svc.c
158
struct net *net, const int family,
fs/lockd/svc.c
164
xprt = svc_find_xprt(serv, name, net, family, 0);
fs/lockd/svc.c
166
return svc_xprt_create(serv, name, net, family, port,
fs/lockd/svc.c
172
static int create_lockd_family(struct svc_serv *serv, struct net *net,
fs/lockd/svc.c
175
struct lockd_net *ln = net_generic(net, lockd_net_id);
fs/lockd/svc.c
178
err = create_lockd_listener(serv, "udp", net, family,
fs/lockd/svc.c
183
return create_lockd_listener(serv, "tcp", net, family,
fs/lockd/svc.c
197
static int make_socks(struct svc_serv *serv, struct net *net,
fs/lockd/svc.c
203
err = create_lockd_family(serv, net, PF_INET, cred);
fs/lockd/svc.c
207
err = create_lockd_family(serv, net, PF_INET6, cred);
fs/lockd/svc.c
218
svc_xprt_destroy_all(serv, net, true);
fs/lockd/svc.c
222
static int lockd_up_net(struct svc_serv *serv, struct net *net,
fs/lockd/svc.c
225
struct lockd_net *ln = net_generic(net, lockd_net_id);
fs/lockd/svc.c
231
error = svc_bind(serv, net);
fs/lockd/svc.c
235
error = make_socks(serv, net, cred);
fs/lockd/svc.c
238
set_grace_period(net);
fs/lockd/svc.c
239
dprintk("%s: per-net data created; net=%x\n", __func__, net->ns.inum);
fs/lockd/svc.c
247
static void lockd_down_net(struct svc_serv *serv, struct net *net)
fs/lockd/svc.c
249
struct lockd_net *ln = net_generic(net, lockd_net_id);
fs/lockd/svc.c
253
nlm_shutdown_hosts_net(net);
fs/lockd/svc.c
256
svc_xprt_destroy_all(serv, net, true);
fs/lockd/svc.c
260
__func__, net->ns.inum);
fs/lockd/svc.c
388
int lockd_up(struct net *net, const struct cred *cred)
fs/lockd/svc.c
398
error = lockd_up_net(nlmsvc_serv, net, cred);
fs/lockd/svc.c
414
lockd_down(struct net *net)
fs/lockd/svc.c
417
lockd_down_net(nlmsvc_serv, net);
fs/lockd/svc.c
554
static int lockd_init_net(struct net *net)
fs/lockd/svc.c
556
struct lockd_net *ln = net_generic(net, lockd_net_id);
fs/lockd/svc.c
565
static void lockd_exit_net(struct net *net)
fs/lockd/svc.c
567
struct lockd_net *ln = net_generic(net, lockd_net_id);
fs/lockd/svc.c
571
net->ns.inum, __func__);
fs/lockd/svc.c
574
net->ns.inum, __func__);
fs/lockd/svc.c
577
net->ns.inum, __func__);
fs/lockd/svc.c
714
struct net *net = genl_info_net(info);
fs/lockd/svc.c
715
struct lockd_net *ln = net_generic(net, lockd_net_id);
fs/lockd/svc.c
733
if (net == &init_net)
fs/lockd/svc.c
740
if (net == &init_net)
fs/lockd/svc.c
747
if (net == &init_net)
fs/lockd/svc.c
763
struct net *net = genl_info_net(info);
fs/lockd/svc.c
764
struct lockd_net *ln = net_generic(net, lockd_net_id);
fs/lockd/svc.c
86
static unsigned long get_lockd_grace_period(struct net *net)
fs/lockd/svc.c
88
struct lockd_net *ln = net_generic(net, lockd_net_id);
fs/lockd/svc4proc.c
413
struct net *net = SVC_NET(rqstp);
fs/lockd/svc4proc.c
420
if (locks_in_grace(net))
fs/lockd/svc4proc.c
434
resp->xdrgen.stat.stat = nlmsvc_cancel_blocked(net, file, &argp->lock);
fs/lockd/svc4proc.c
475
struct net *net = SVC_NET(rqstp);
fs/lockd/svc4proc.c
482
if (locks_in_grace(net))
fs/lockd/svc4proc.c
496
resp->xdrgen.stat.stat = nlmsvc_unlock(net, file, &argp->lock);
fs/lockd/svc4proc.c
717
struct net *net = SVC_NET(rqstp);
fs/lockd/svc4proc.c
726
if (locks_in_grace(net))
fs/lockd/svc4proc.c
739
resp->status = nlmsvc_cancel_blocked(net, file, &argp->lock);
fs/lockd/svc4proc.c
780
struct net *net = SVC_NET(rqstp);
fs/lockd/svc4proc.c
789
if (locks_in_grace(net))
fs/lockd/svc4proc.c
802
resp->status = nlmsvc_unlock(net, file, &argp->lock);
fs/lockd/svclock.c
672
nlmsvc_unlock(struct net *net, struct nlm_file *file, struct lockd_lock *lock)
fs/lockd/svclock.c
687
nlmsvc_cancel_blocked(net, file, lock);
fs/lockd/svclock.c
710
nlmsvc_cancel_blocked(struct net *net, struct nlm_file *file, struct lockd_lock *lock)
fs/lockd/svclock.c
726
if (locks_in_grace(net))
fs/lockd/svcproc.c
420
struct net *net = SVC_NET(rqstp);
fs/lockd/svcproc.c
427
if (locks_in_grace(net))
fs/lockd/svcproc.c
441
resp->xdrgen.stat.stat = nlmsvc_cancel_blocked(net, file, &argp->lock);
fs/lockd/svcproc.c
477
struct net *net = SVC_NET(rqstp);
fs/lockd/svcproc.c
484
if (locks_in_grace(net))
fs/lockd/svcproc.c
498
resp->xdrgen.stat.stat = nlmsvc_unlock(net, file, &argp->lock);
fs/lockd/svcproc.c
734
struct net *net = SVC_NET(rqstp);
fs/lockd/svcproc.c
743
if (locks_in_grace(net))
fs/lockd/svcproc.c
756
resp->status = nlmsvc_cancel_blocked(net, file, &argp->lock);
fs/lockd/svcproc.c
801
struct net *net = SVC_NET(rqstp);
fs/lockd/svcproc.c
810
if (locks_in_grace(net))
fs/lockd/svcproc.c
823
resp->status = nlmsvc_unlock(net, file, &argp->lock);
fs/lockd/svcsubs.c
409
if ((hint->net == NULL) ||
fs/lockd/svcsubs.c
410
(host->net == hint->net))
fs/lockd/svcsubs.c
444
nlmsvc_mark_resources(struct net *net)
fs/lockd/svcsubs.c
448
dprintk("lockd: %s for net %x\n", __func__, net ? net->ns.inum : 0);
fs/lockd/svcsubs.c
449
hint.net = net;
fs/nfs/blocklayout/rpc_pipefs.c
162
struct net *net = sb->s_fs_info;
fs/nfs/blocklayout/rpc_pipefs.c
163
struct nfs_net *nn = net_generic(net, nfs_net_id);
fs/nfs/blocklayout/rpc_pipefs.c
193
static int nfs4blocklayout_register_net(struct net *net, struct rpc_pipe *pipe)
fs/nfs/blocklayout/rpc_pipefs.c
198
pipefs_sb = rpc_get_sb_net(net);
fs/nfs/blocklayout/rpc_pipefs.c
202
rpc_put_sb_net(net);
fs/nfs/blocklayout/rpc_pipefs.c
206
static void nfs4blocklayout_unregister_net(struct net *net,
fs/nfs/blocklayout/rpc_pipefs.c
211
pipefs_sb = rpc_get_sb_net(net);
fs/nfs/blocklayout/rpc_pipefs.c
214
rpc_put_sb_net(net);
fs/nfs/blocklayout/rpc_pipefs.c
218
static int nfs4blocklayout_net_init(struct net *net)
fs/nfs/blocklayout/rpc_pipefs.c
220
struct nfs_net *nn = net_generic(net, nfs_net_id);
fs/nfs/blocklayout/rpc_pipefs.c
228
err = nfs4blocklayout_register_net(net, nn->bl_device_pipe);
fs/nfs/blocklayout/rpc_pipefs.c
234
static void nfs4blocklayout_net_exit(struct net *net)
fs/nfs/blocklayout/rpc_pipefs.c
236
struct nfs_net *nn = net_generic(net, nfs_net_id);
fs/nfs/blocklayout/rpc_pipefs.c
238
nfs4blocklayout_unregister_net(net, nn->bl_device_pipe);
fs/nfs/blocklayout/rpc_pipefs.c
55
struct net *net = server->nfs_client->cl_net;
fs/nfs/blocklayout/rpc_pipefs.c
56
struct nfs_net *nn = net_generic(net, nfs_net_id);
fs/nfs/cache_lib.c
127
int nfs_cache_register_net(struct net *net, struct cache_detail *cd)
fs/nfs/cache_lib.c
133
pipefs_sb = rpc_get_sb_net(net);
fs/nfs/cache_lib.c
136
rpc_put_sb_net(net);
fs/nfs/cache_lib.c
148
void nfs_cache_unregister_net(struct net *net, struct cache_detail *cd)
fs/nfs/cache_lib.c
152
pipefs_sb = rpc_get_sb_net(net);
fs/nfs/cache_lib.c
155
rpc_put_sb_net(net);
fs/nfs/cache_lib.h
27
extern int nfs_cache_register_net(struct net *net, struct cache_detail *cd);
fs/nfs/cache_lib.h
28
extern void nfs_cache_unregister_net(struct net *net, struct cache_detail *cd);
fs/nfs/callback.c
124
static void nfs_callback_down_net(u32 minorversion, struct svc_serv *serv, struct net *net)
fs/nfs/callback.c
126
struct nfs_net *nn = net_generic(net, nfs_net_id);
fs/nfs/callback.c
131
dprintk("NFS: destroy per-net callback data; net=%x\n", net->ns.inum);
fs/nfs/callback.c
132
svc_xprt_destroy_all(serv, net, false);
fs/nfs/callback.c
136
struct net *net, struct rpc_xprt *xprt)
fs/nfs/callback.c
138
struct nfs_net *nn = net_generic(net, nfs_net_id);
fs/nfs/callback.c
144
dprintk("NFS: create per-net callback data; net=%x\n", net->ns.inum);
fs/nfs/callback.c
146
ret = svc_bind(serv, net);
fs/nfs/callback.c
154
ret = nfs4_callback_up_net(serv, net);
fs/nfs/callback.c
169
"net = %x\n", ret, net->ns.inum);
fs/nfs/callback.c
213
struct net *net = xprt->xprt_net;
fs/nfs/callback.c
223
ret = nfs_callback_up_net(minorversion, serv, net, xprt);
fs/nfs/callback.c
242
nfs_callback_down_net(minorversion, serv, net);
fs/nfs/callback.c
250
void nfs_callback_down(int minorversion, struct net *net, struct rpc_xprt *xprt)
fs/nfs/callback.c
257
nfs_callback_down_net(minorversion, serv, net);
fs/nfs/callback.c
41
static int nfs4_callback_up_net(struct svc_serv *serv, struct net *net)
fs/nfs/callback.c
45
struct nfs_net *nn = net_generic(net, nfs_net_id);
fs/nfs/callback.c
47
ret = svc_xprt_create(serv, "tcp", net, PF_INET,
fs/nfs/callback.c
54
nn->nfs_callback_tcpport, PF_INET, net->ns.inum);
fs/nfs/callback.c
56
ret = svc_xprt_create(serv, "tcp", net, PF_INET6,
fs/nfs/callback.c
62
nn->nfs_callback_tcpport6, PF_INET6, net->ns.inum);
fs/nfs/callback.h
188
extern void nfs_callback_down(int minorversion, struct net *net,
fs/nfs/callback.h
26
struct net *net;
fs/nfs/callback_proc.c
515
clp = nfs4_find_client_sessionid(cps->net, args->csa_addr,
fs/nfs/callback_xdr.c
945
.net = SVC_NET(rqstp),
fs/nfs/client.c
1278
void nfs_clients_init(struct net *net)
fs/nfs/client.c
1280
struct nfs_net *nn = net_generic(net, nfs_net_id);
fs/nfs/client.c
1294
nfs_netns_sysfs_setup(nn, net);
fs/nfs/client.c
1297
void nfs_clients_exit(struct net *net)
fs/nfs/client.c
1299
struct nfs_net *nn = net_generic(net, nfs_net_id);
fs/nfs/client.c
1302
nfs_cleanup_cb_ident_idr(net);
fs/nfs/client.c
1477
int nfs_fs_proc_net_init(struct net *net)
fs/nfs/client.c
1479
struct nfs_net *nn = net_generic(net, nfs_net_id);
fs/nfs/client.c
1482
nn->proc_nfsfs = proc_net_mkdir(net, "nfsfs", net->proc_net);
fs/nfs/client.c
1500
remove_proc_subtree("nfsfs", net->proc_net);
fs/nfs/client.c
1505
void nfs_fs_proc_net_exit(struct net *net)
fs/nfs/client.c
1507
remove_proc_subtree("nfsfs", net->proc_net);
fs/nfs/client.c
183
clp->cl_net = get_net_track(cl_init->net, &clp->cl_ns_tracker, GFP_KERNEL);
fs/nfs/client.c
206
static void nfs_cleanup_cb_ident_idr(struct net *net)
fs/nfs/client.c
208
struct nfs_net *nn = net_generic(net, nfs_net_id);
fs/nfs/client.c
228
static void nfs_cleanup_cb_ident_idr(struct net *net)
fs/nfs/client.c
293
struct nfs_net *nn = net_generic(data->net, nfs_net_id);
fs/nfs/client.c
423
struct nfs_net *nn = net_generic(cl_init->net, nfs_net_id);
fs/nfs/client.c
527
.net = clp->cl_net,
fs/nfs/client.c
600
.net = clp->cl_net,
fs/nfs/client.c
745
.net = fc->net_ns,
fs/nfs/dns_resolve.c
20
ssize_t nfs_dns_resolve_name(struct net *net, char *name, size_t namelen,
fs/nfs/dns_resolve.c
244
key.addrlen = rpc_pton(cd->net, buf1, len,
fs/nfs/dns_resolve.c
28
ip_len = dns_query(net, NULL, name, namelen, NULL, &ip_addr, NULL,
fs/nfs/dns_resolve.c
31
ret = rpc_pton(net, ip_addr, ip_len, sa, salen);
fs/nfs/dns_resolve.c
342
ssize_t nfs_dns_resolve_name(struct net *net, char *name,
fs/nfs/dns_resolve.c
351
struct nfs_net *nn = net_generic(net, nfs_net_id);
fs/nfs/dns_resolve.c
382
int nfs_dns_resolver_cache_init(struct net *net)
fs/nfs/dns_resolve.c
385
struct nfs_net *nn = net_generic(net, nfs_net_id);
fs/nfs/dns_resolve.c
387
nn->nfs_dns_resolve = cache_create_net(&nfs_dns_resolve_template, net);
fs/nfs/dns_resolve.c
391
err = nfs_cache_register_net(net, nn->nfs_dns_resolve);
fs/nfs/dns_resolve.c
397
cache_destroy_net(nn->nfs_dns_resolve, net);
fs/nfs/dns_resolve.c
401
void nfs_dns_resolver_cache_destroy(struct net *net)
fs/nfs/dns_resolve.c
403
struct nfs_net *nn = net_generic(net, nfs_net_id);
fs/nfs/dns_resolve.c
405
nfs_cache_unregister_net(net, nn->nfs_dns_resolve);
fs/nfs/dns_resolve.c
406
cache_destroy_net(nn->nfs_dns_resolve, net);
fs/nfs/dns_resolve.c
409
static int nfs4_dns_net_init(struct net *net)
fs/nfs/dns_resolve.c
411
return nfs_dns_resolver_cache_init(net);
fs/nfs/dns_resolve.c
414
static void nfs4_dns_net_exit(struct net *net)
fs/nfs/dns_resolve.c
416
nfs_dns_resolver_cache_destroy(net);
fs/nfs/dns_resolve.c
428
struct net *net = sb->s_fs_info;
fs/nfs/dns_resolve.c
429
struct nfs_net *nn = net_generic(net, nfs_net_id);
fs/nfs/dns_resolve.h
20
static inline int nfs_dns_resolver_cache_init(struct net *net)
fs/nfs/dns_resolve.h
25
static inline void nfs_dns_resolver_cache_destroy(struct net *net)
fs/nfs/dns_resolve.h
30
extern int nfs_dns_resolver_cache_init(struct net *net);
fs/nfs/dns_resolve.h
31
extern void nfs_dns_resolver_cache_destroy(struct net *net);
fs/nfs/dns_resolve.h
34
extern ssize_t nfs_dns_resolve_name(struct net *net, char *name,
fs/nfs/filelayout/filelayoutdev.c
163
da = nfs4_decode_mp_ds_addr(net, &stream, gfp_flags);
fs/nfs/filelayout/filelayoutdev.c
173
dsaddr->ds_list[i] = nfs4_pnfs_ds_add(net, &dsaddrs, gfp_flags);
fs/nfs/filelayout/filelayoutdev.c
79
struct net *net = server->nfs_client->cl_net;
fs/nfs/flexfilelayout/flexfilelayoutdev.c
156
new_ds->ds = nfs4_pnfs_ds_add(net, &dsaddrs, gfp_flags);
fs/nfs/flexfilelayout/flexfilelayoutdev.c
52
struct net *net = server->nfs_client->cl_net;
fs/nfs/flexfilelayout/flexfilelayoutdev.c
84
da = nfs4_decode_mp_ds_addr(net, &stream, gfp_flags);
fs/nfs/fs_context.c
1712
struct net *net = nfss->nfs_client->cl_net;
fs/nfs/fs_context.c
1732
if (fc->net_ns != net) {
fs/nfs/fs_context.c
1734
fc->net_ns = get_net(net);
fs/nfs/inode.c
2628
static int nfs_net_init(struct net *net)
fs/nfs/inode.c
2630
struct nfs_net *nn = net_generic(net, nfs_net_id);
fs/nfs/inode.c
2633
nfs_clients_init(net);
fs/nfs/inode.c
2635
if (!rpc_proc_register(net, &nn->rpcstats)) {
fs/nfs/inode.c
2640
err = nfs_fs_proc_net_init(net);
fs/nfs/inode.c
2647
rpc_proc_unregister(net, "nfs");
fs/nfs/inode.c
2649
nfs_clients_exit(net);
fs/nfs/inode.c
2653
static void nfs_net_exit(struct net *net)
fs/nfs/inode.c
2655
rpc_proc_unregister(net, "nfs");
fs/nfs/inode.c
2656
nfs_fs_proc_net_exit(net);
fs/nfs/inode.c
2657
nfs_clients_exit(net);
fs/nfs/internal.h
205
struct net *net;
fs/nfs/internal.h
212
extern void nfs_clients_init(struct net *net);
fs/nfs/internal.h
213
extern void nfs_clients_exit(struct net *net);
fs/nfs/internal.h
228
extern struct nfs_client *nfs4_find_client_ident(struct net *, int);
fs/nfs/internal.h
230
nfs4_find_client_sessionid(struct net *, const struct sockaddr *,
fs/nfs/internal.h
238
struct net *net);
fs/nfs/internal.h
265
extern int nfs_fs_proc_net_init(struct net *net);
fs/nfs/internal.h
266
extern void nfs_fs_proc_net_exit(struct net *net);
fs/nfs/internal.h
268
static inline int nfs_fs_proc_net_init(struct net *net)
fs/nfs/internal.h
272
static inline void nfs_fs_proc_net_exit(struct net *net)
fs/nfs/internal.h
83
struct net *net;
fs/nfs/localio.c
172
if (status || !rcu_access_pointer(clp->cl_uuid.net) || !clp->cl_uuid.dom)
fs/nfs/localio.c
68
return !!rcu_access_pointer(clp->cl_uuid.net);
fs/nfs/mount_clnt.c
154
.net = info->net,
fs/nfs/nfs3client.c
99
.net = mds_clp->cl_net,
fs/nfs/nfs4_fs.h
303
size_t salen, struct net *net, int port);
fs/nfs/nfs4client.c
1071
.net = parent_client->cl_net,
fs/nfs/nfs4client.c
1144
struct sockaddr_storage *sap, size_t salen, struct net *net)
fs/nfs/nfs4client.c
1150
.net = net,
fs/nfs/nfs4client.c
1166
.net = net,
fs/nfs/nfs4client.c
383
.net = old->cl_net,
fs/nfs/nfs4client.c
649
nfs4_find_client_ident(struct net *net, int cb_ident)
fs/nfs/nfs4client.c
652
struct nfs_net *nn = net_generic(net, nfs_net_id);
fs/nfs/nfs4client.c
692
nfs4_find_client_sessionid(struct net *net, const struct sockaddr *addr,
fs/nfs/nfs4client.c
696
struct nfs_net *nn = net_generic(net, nfs_net_id);
fs/nfs/nfs4client.c
806
.net = mds_clp->cl_net,
fs/nfs/nfs4client.c
968
.net = fc->net_ns,
fs/nfs/nfs4namespace.c
168
size_t salen, struct net *net, int port)
fs/nfs/nfs4namespace.c
173
ret = rpc_pton(net, string, len, sa, salen);
fs/nfs/nfs4namespace.c
175
ret = rpc_uaddr2sockaddr(net, string, len, sa, salen);
fs/nfs/nfs4namespace.c
177
ret = nfs_dns_resolve_name(net, string, len, ss, salen);
fs/nfs/nfs4namespace.c
486
struct net *net = rpc_net_ns(server->client);
fs/nfs/nfs4namespace.c
508
sap, sizeof(*sap), net, 0);
fs/nfs/nfs4namespace.c
518
error = nfs4_update_server(server, hostname, sap, salen, net);
fs/nfs/nfs4proc.c
4036
.net = clp->cl_net,
fs/nfs/pnfs.h
418
struct nfs4_pnfs_ds *nfs4_pnfs_ds_add(const struct net *net,
fs/nfs/pnfs.h
425
struct nfs4_pnfs_ds_addr *nfs4_decode_mp_ds_addr(struct net *net,
fs/nfs/pnfs.h
63
const struct net *ds_net;
fs/nfs/pnfs_nfs.c
1062
nfs4_decode_mp_ds_addr(struct net *net, struct xdr_stream *xdr, gfp_t gfp_flags)
fs/nfs/pnfs_nfs.c
1110
if (!rpc_pton(net, buf, portstr-buf, (struct sockaddr *)&da->da_addr,
fs/nfs/pnfs_nfs.c
722
nfs4_pnfs_ds_add(const struct net *net, struct list_head *dsaddrs, gfp_t gfp_flags)
fs/nfs/pnfs_nfs.c
724
struct nfs_net *nn = net_generic(net, nfs_net_id);
fs/nfs/pnfs_nfs.c
748
ds->ds_net = net;
fs/nfs/pnfs_nfs.c
831
.net = clp->cl_net,
fs/nfs/pnfs_nfs.c
904
.net = clp->cl_net,
fs/nfs/super.c
844
.net = fc->net_ns,
fs/nfs/sysfs.c
134
kobject)->net);
fs/nfs/sysfs.c
164
nfs_net_kobj)->net);
fs/nfs/sysfs.c
174
struct net *net)
fs/nfs/sysfs.c
180
p->net = net;
fs/nfs/sysfs.c
200
void nfs_netns_sysfs_setup(struct nfs_net *netns, struct net *net)
fs/nfs/sysfs.c
204
clp = nfs_netns_client_alloc(&nfs_kset->kobj, net);
fs/nfs/sysfs.h
14
struct net *net;
fs/nfs/sysfs.h
23
void nfs_netns_sysfs_setup(struct nfs_net *netns, struct net *net);
fs/nfs_common/grace.c
104
grace_init_net(struct net *net)
fs/nfs_common/grace.c
106
struct list_head *grace_list = net_generic(net, grace_net_id);
fs/nfs_common/grace.c
113
grace_exit_net(struct net *net)
fs/nfs_common/grace.c
115
struct list_head *grace_list = net_generic(net, grace_net_id);
fs/nfs_common/grace.c
119
net->ns.inum, __func__);
fs/nfs_common/grace.c
30
locks_start_grace(struct net *net, struct lock_manager *lm)
fs/nfs_common/grace.c
32
struct list_head *grace_list = net_generic(net, grace_net_id);
fs/nfs_common/grace.c
39
net->ns.inum, (net == &init_net) ? "(init_net)" : "");
fs/nfs_common/grace.c
64
__state_in_grace(struct net *net, bool open)
fs/nfs_common/grace.c
66
struct list_head *grace_list = net_generic(net, grace_net_id);
fs/nfs_common/grace.c
91
bool locks_in_grace(struct net *net)
fs/nfs_common/grace.c
93
return __state_in_grace(net, false);
fs/nfs_common/grace.c
97
bool opens_in_grace(struct net *net)
fs/nfs_common/grace.c
99
return __state_in_grace(net, true);
fs/nfs_common/nfslocalio.c
105
spinlock_t *list_lock, struct net *net,
fs/nfs_common/nfslocalio.c
136
rcu_assign_pointer(nfs_uuid->net, net);
fs/nfs_common/nfslocalio.c
157
if (unlikely(!rcu_access_pointer(nfs_uuid->net))) {
fs/nfs_common/nfslocalio.c
161
RCU_INIT_POINTER(nfs_uuid->net, NULL);
fs/nfs_common/nfslocalio.c
251
if (rcu_access_pointer(nfs_uuid->net) == NULL) {
fs/nfs_common/nfslocalio.c
271
struct net *net;
fs/nfs_common/nfslocalio.c
285
net = rcu_dereference(uuid->net);
fs/nfs_common/nfslocalio.c
286
if (!net || !nfs_to->nfsd_net_try_get(net)) {
fs/nfs_common/nfslocalio.c
292
localio = nfs_to->nfsd_open_local_fh(net, uuid->dom, rpc_clnt, cred,
fs/nfs_common/nfslocalio.c
298
nfs_to_nfsd_net_put(net);
fs/nfs_common/nfslocalio.c
40
RCU_INIT_POINTER(nfs_uuid->net, NULL);
fs/nfs_common/nfslocalio.c
53
if (rcu_access_pointer(nfs_uuid->net)) {
fs/nfs_common/nfslocalio.c
78
if (!rcu_access_pointer(nfs_uuid->net)) {
fs/nfs_common/nfslocalio.c
80
if (!rcu_access_pointer(nfs_uuid->net)) {
fs/nfsd/export.c
1726
exp_rootfh(struct net *net, struct auth_domain *clp, char *name,
fs/nfsd/export.c
1734
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/export.c
1775
struct nfsd_net *nn = net_generic(cd->net, nfsd_net_id);
fs/nfsd/export.c
1966
rqst_exp_find(struct cache_req *reqp, struct net *net,
fs/nfsd/export.c
1970
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/export.c
2190
nfsd_export_init(struct net *net)
fs/nfsd/export.c
2193
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/export.c
2195
dprintk("nfsd: initializing export module (net: %x).\n", net->ns.inum);
fs/nfsd/export.c
2197
nn->svc_export_cache = cache_create_net(&svc_export_cache_template, net);
fs/nfsd/export.c
2200
rv = cache_register_net(nn->svc_export_cache, net);
fs/nfsd/export.c
2204
nn->svc_expkey_cache = cache_create_net(&svc_expkey_cache_template, net);
fs/nfsd/export.c
2209
rv = cache_register_net(nn->svc_expkey_cache, net);
fs/nfsd/export.c
2215
cache_destroy_net(nn->svc_expkey_cache, net);
fs/nfsd/export.c
2217
cache_unregister_net(nn->svc_export_cache, net);
fs/nfsd/export.c
2219
cache_destroy_net(nn->svc_export_cache, net);
fs/nfsd/export.c
2227
nfsd_export_flush(struct net *net)
fs/nfsd/export.c
2229
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/export.c
2239
nfsd_export_shutdown(struct net *net)
fs/nfsd/export.c
2241
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/export.c
2243
dprintk("nfsd: shutting down export module (net: %x).\n", net->ns.inum);
fs/nfsd/export.c
2245
cache_unregister_net(nn->svc_expkey_cache, net);
fs/nfsd/export.c
2246
cache_unregister_net(nn->svc_export_cache, net);
fs/nfsd/export.c
2247
cache_destroy_net(nn->svc_expkey_cache, net);
fs/nfsd/export.c
2248
cache_destroy_net(nn->svc_export_cache, net);
fs/nfsd/export.c
2249
svcauth_unix_purge(net);
fs/nfsd/export.c
2251
dprintk("nfsd: export shutdown complete (net: %x).\n", net->ns.inum);
fs/nfsd/export.h
113
int nfsd_export_init(struct net *);
fs/nfsd/export.h
114
void nfsd_export_shutdown(struct net *);
fs/nfsd/export.h
115
void nfsd_export_flush(struct net *);
fs/nfsd/export.h
121
int exp_rootfh(struct net *, struct auth_domain *,
fs/nfsd/export.h
135
struct svc_export *rqst_exp_find(struct cache_req *reqp, struct net *net,
fs/nfsd/filecache.c
1040
nfsd_file_lookup_locked(const struct net *net, const struct cred *cred,
fs/nfsd/filecache.c
1052
if (nf->nf_net != net)
fs/nfsd/filecache.c
1130
nfsd_file_do_acquire(struct svc_rqst *rqstp, struct net *net,
fs/nfsd/filecache.c
1150
status = fh_verify_local(net, cred, client, fhp, type,
fs/nfsd/filecache.c
1158
nf = nfsd_file_lookup_locked(net, current_cred(), inode, need, want_gc);
fs/nfsd/filecache.c
1164
new = nfsd_file_alloc(net, inode, need, want_gc);
fs/nfsd/filecache.c
1172
nf = nfsd_file_lookup_locked(net, current_cred(), inode, need, want_gc);
fs/nfsd/filecache.c
1354
nfsd_file_acquire_local(struct net *net, struct svc_cred *cred,
fs/nfsd/filecache.c
1366
beres = nfsd_file_do_acquire(NULL, net, cred, client, fhp, may_flags,
fs/nfsd/filecache.c
211
nfsd_file_alloc(struct net *net, struct inode *inode, unsigned char need,
fs/nfsd/filecache.c
226
nf->nf_net = net;
fs/nfsd/filecache.c
383
struct net *
fs/nfsd/filecache.c
387
struct net *net = NULL;
fs/nfsd/filecache.c
391
net = nf->nf_net;
fs/nfsd/filecache.c
394
return net;
fs/nfsd/filecache.c
743
void nfsd_file_close_export(struct net *net, const struct path *path)
fs/nfsd/filecache.c
755
if (nf->nf_net == net &&
fs/nfsd/filecache.c
911
__nfsd_file_cache_purge(struct net *net)
fs/nfsd/filecache.c
918
if (net) {
fs/nfsd/filecache.c
919
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/filecache.c
931
if (!net || nf->nf_net == net)
fs/nfsd/filecache.c
964
nfsd_free_fcache_disposal_net(struct net *net)
fs/nfsd/filecache.c
966
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/filecache.c
973
nfsd_file_cache_start_net(struct net *net)
fs/nfsd/filecache.c
975
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/filecache.c
987
nfsd_file_cache_purge(struct net *net)
fs/nfsd/filecache.c
991
__nfsd_file_cache_purge(net);
fs/nfsd/filecache.c
995
nfsd_file_cache_shutdown_net(struct net *net)
fs/nfsd/filecache.c
997
nfsd_file_cache_purge(net);
fs/nfsd/filecache.c
998
nfsd_free_fcache_disposal_net(net);
fs/nfsd/filecache.h
42
struct net *nf_net;
fs/nfsd/filecache.h
64
void nfsd_file_cache_purge(struct net *);
fs/nfsd/filecache.h
66
int nfsd_file_cache_start_net(struct net *net);
fs/nfsd/filecache.h
67
void nfsd_file_cache_shutdown_net(struct net *net);
fs/nfsd/filecache.h
69
struct net *nfsd_file_put_local(struct nfsd_file __rcu **nf);
fs/nfsd/filecache.h
73
void nfsd_file_close_export(struct net *net, const struct path *path);
fs/nfsd/filecache.h
83
__be32 nfsd_file_acquire_local(struct net *net, struct svc_cred *cred,
fs/nfsd/idmap.h
43
int nfsd_idmap_init(struct net *);
fs/nfsd/idmap.h
44
void nfsd_idmap_shutdown(struct net *);
fs/nfsd/idmap.h
46
static inline int nfsd_idmap_init(struct net *net)
fs/nfsd/idmap.h
50
static inline void nfsd_idmap_shutdown(struct net *net)
fs/nfsd/localio.c
110
nfsd_net_put(net);
fs/nfsd/localio.c
115
nfsd_net_put(net);
fs/nfsd/localio.c
160
struct net *net = SVC_NET(rqstp);
fs/nfsd/localio.c
161
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/localio.c
165
net, rqstp->rq_client, THIS_MODULE);
fs/nfsd/localio.c
47
nfsd_open_local_fh(struct net *net, struct auth_domain *dom,
fs/nfsd/localio.c
61
if (!nfsd_net_try_get(net))
fs/nfsd/localio.c
82
beres = nfsd_file_acquire_local(net, &rq_cred, dom,
fs/nfsd/localio.c
93
if (!nfsd_net_try_get(net)) {
fs/nfsd/localio.c
95
nfsd_net_put(net);
fs/nfsd/netns.h
242
bool nfsd_net_try_get(struct net *net);
fs/nfsd/netns.h
243
void nfsd_net_put(struct net *net);
fs/nfsd/nfs4callback.c
1045
static int max_cb_time(struct net *net)
fs/nfsd/nfs4callback.c
1047
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfs4callback.c
1118
struct nfsd_net *nn = net_generic(clp->net, nfsd_net_id);
fs/nfsd/nfs4callback.c
1119
int maxtime = max_cb_time(clp->net);
fs/nfsd/nfs4callback.c
1126
.net = clp->net,
fs/nfsd/nfs4idmap.c
465
nfsd_idmap_init(struct net *net)
fs/nfsd/nfs4idmap.c
468
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfs4idmap.c
470
nn->idtoname_cache = cache_create_net(&idtoname_cache_template, net);
fs/nfsd/nfs4idmap.c
473
rv = cache_register_net(nn->idtoname_cache, net);
fs/nfsd/nfs4idmap.c
476
nn->nametoid_cache = cache_create_net(&nametoid_cache_template, net);
fs/nfsd/nfs4idmap.c
481
rv = cache_register_net(nn->nametoid_cache, net);
fs/nfsd/nfs4idmap.c
487
cache_destroy_net(nn->nametoid_cache, net);
fs/nfsd/nfs4idmap.c
489
cache_unregister_net(nn->idtoname_cache, net);
fs/nfsd/nfs4idmap.c
491
cache_destroy_net(nn->idtoname_cache, net);
fs/nfsd/nfs4idmap.c
496
nfsd_idmap_shutdown(struct net *net)
fs/nfsd/nfs4idmap.c
498
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfs4idmap.c
500
cache_unregister_net(nn->idtoname_cache, net);
fs/nfsd/nfs4idmap.c
501
cache_unregister_net(nn->nametoid_cache, net);
fs/nfsd/nfs4idmap.c
502
cache_destroy_net(nn->idtoname_cache, net);
fs/nfsd/nfs4idmap.c
503
cache_destroy_net(nn->nametoid_cache, net);
fs/nfsd/nfs4layouts.c
690
nn = net_generic(ls->ls_stid.sc_client->net, nfsd_net_id);
fs/nfsd/nfs4layouts.c
824
nn = net_generic(clp->net, nfsd_net_id);
fs/nfsd/nfs4proc.c
1566
void nfsd4_cancel_copy_by_sb(struct net *net, struct super_block *sb)
fs/nfsd/nfs4proc.c
1568
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfs4proc.c
2726
struct net *net = SVC_NET(rqstp);
fs/nfsd/nfs4proc.c
2763
if (locks_in_grace(net) && !lcp->lc_reclaim)
fs/nfsd/nfs4proc.c
2766
if (!locks_in_grace(net) && lcp->lc_reclaim)
fs/nfsd/nfs4proc.c
565
struct net *net = SVC_NET(rqstp);
fs/nfsd/nfs4proc.c
566
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfs4proc.c
625
if (opens_in_grace(net) && open->op_claim_type != NFS4_OPEN_CLAIM_PREVIOUS)
fs/nfsd/nfs4proc.c
628
if (!opens_in_grace(net) && open->op_claim_type == NFS4_OPEN_CLAIM_PREVIOUS)
fs/nfsd/nfs4recover.c
1004
struct nfsd_net *nn = net_generic(clp->net, nfsd_net_id);
fs/nfsd/nfs4recover.c
1041
struct nfsd_net *nn = net_generic(clp->net, nfsd_net_id);
fs/nfsd/nfs4recover.c
1091
struct nfsd_net *nn = net_generic(clp->net, nfsd_net_id);
fs/nfsd/nfs4recover.c
1133
struct nfsd_net *nn = net_generic(clp->net, nfsd_net_id);
fs/nfsd/nfs4recover.c
1172
struct nfsd_net *nn = net_generic(clp->net, nfsd_net_id);
fs/nfsd/nfs4recover.c
1213
struct nfsd_net *nn = net_generic(clp->net, nfsd_net_id);
fs/nfsd/nfs4recover.c
129
struct nfsd_net *nn = net_generic(clp->net, nfsd_net_id);
fs/nfsd/nfs4recover.c
1352
nfs4_cld_state_init(struct net *net)
fs/nfsd/nfs4recover.c
1354
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfs4recover.c
1372
nfs4_cld_state_shutdown(struct net *net)
fs/nfsd/nfs4recover.c
1374
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfs4recover.c
1437
nfsd4_cld_tracking_init(struct net *net)
fs/nfsd/nfs4recover.c
1440
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfs4recover.c
1444
status = nfs4_cld_state_init(net);
fs/nfsd/nfs4recover.c
1448
status = __nfsd4_init_cld_pipe(net);
fs/nfsd/nfs4recover.c
1483
nfsd4_remove_cld_pipe(net);
fs/nfsd/nfs4recover.c
1485
nfs4_cld_state_shutdown(net);
fs/nfsd/nfs4recover.c
1490
nfsd4_cld_tracking_exit(struct net *net)
fs/nfsd/nfs4recover.c
1492
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfs4recover.c
1495
nfsd4_remove_cld_pipe(net);
fs/nfsd/nfs4recover.c
1496
nfs4_cld_state_shutdown(net);
fs/nfsd/nfs4recover.c
1719
nfsd4_umh_cltrack_init(struct net *net)
fs/nfsd/nfs4recover.c
1722
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfs4recover.c
1726
if (net != &init_net) {
fs/nfsd/nfs4recover.c
1756
struct nfsd_net *nn = net_generic(clp->net, nfsd_net_id);
fs/nfsd/nfs4recover.c
1873
static inline int check_for_legacy_methods(int status, struct net *net)
fs/nfsd/nfs4recover.c
1875
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfs4recover.c
1882
status = nn->client_tracking_ops->init(net);
fs/nfsd/nfs4recover.c
1901
static inline int check_for_legacy_methods(int status, struct net *net)
fs/nfsd/nfs4recover.c
1908
nfsd4_client_tracking_init(struct net *net)
fs/nfsd/nfs4recover.c
1910
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfs4recover.c
1919
status = nn->client_tracking_ops->init(net);
fs/nfsd/nfs4recover.c
1924
status = nn->client_tracking_ops->init(net);
fs/nfsd/nfs4recover.c
1929
status = check_for_legacy_methods(status, net);
fs/nfsd/nfs4recover.c
1933
status = nn->client_tracking_ops->init(net);
fs/nfsd/nfs4recover.c
1944
nfsd4_client_tracking_exit(struct net *net)
fs/nfsd/nfs4recover.c
1946
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfs4recover.c
1950
nn->client_tracking_ops->exit(net);
fs/nfsd/nfs4recover.c
1958
struct nfsd_net *nn = net_generic(clp->net, nfsd_net_id);
fs/nfsd/nfs4recover.c
1967
struct nfsd_net *nn = net_generic(clp->net, nfsd_net_id);
fs/nfsd/nfs4recover.c
1976
struct nfsd_net *nn = net_generic(clp->net, nfsd_net_id);
fs/nfsd/nfs4recover.c
1995
struct net *net = sb->s_fs_info;
fs/nfsd/nfs4recover.c
1996
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfs4recover.c
300
struct nfsd_net *nn = net_generic(clp->net, nfsd_net_id);
fs/nfsd/nfs4recover.c
410
nfsd4_recdir_load(struct net *net) {
fs/nfsd/nfs4recover.c
412
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfs4recover.c
429
nfsd4_init_recdir(struct net *net)
fs/nfsd/nfs4recover.c
431
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfs4recover.c
463
nfsd4_shutdown_recdir(struct net *net)
fs/nfsd/nfs4recover.c
465
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfs4recover.c
474
nfs4_legacy_state_init(struct net *net)
fs/nfsd/nfs4recover.c
476
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfs4recover.c
492
nfs4_legacy_state_shutdown(struct net *net)
fs/nfsd/nfs4recover.c
494
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfs4recover.c
500
nfsd4_load_reboot_recovery_data(struct net *net)
fs/nfsd/nfs4recover.c
504
status = nfsd4_init_recdir(net);
fs/nfsd/nfs4recover.c
508
status = nfsd4_recdir_load(net);
fs/nfsd/nfs4recover.c
510
nfsd4_shutdown_recdir(net);
fs/nfsd/nfs4recover.c
516
nfsd4_legacy_tracking_init(struct net *net)
fs/nfsd/nfs4recover.c
521
if (net != &init_net) {
fs/nfsd/nfs4recover.c
526
status = nfs4_legacy_state_init(net);
fs/nfsd/nfs4recover.c
530
status = nfsd4_load_reboot_recovery_data(net);
fs/nfsd/nfs4recover.c
537
nfs4_legacy_state_shutdown(net);
fs/nfsd/nfs4recover.c
542
nfsd4_legacy_tracking_exit(struct net *net)
fs/nfsd/nfs4recover.c
544
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfs4recover.c
547
nfsd4_shutdown_recdir(net);
fs/nfsd/nfs4recover.c
548
nfs4_legacy_state_shutdown(net);
fs/nfsd/nfs4recover.c
58
int (*init)(struct net *);
fs/nfsd/nfs4recover.c
584
struct nfsd_net *nn = net_generic(clp->net, nfsd_net_id);
fs/nfsd/nfs4recover.c
59
void (*exit)(struct net *);
fs/nfsd/nfs4recover.c
863
nfsd4_cld_register_net(struct net *net, struct rpc_pipe *pipe)
fs/nfsd/nfs4recover.c
868
sb = rpc_get_sb_net(net);
fs/nfsd/nfs4recover.c
872
rpc_put_sb_net(net);
fs/nfsd/nfs4recover.c
877
nfsd4_cld_unregister_net(struct net *net, struct rpc_pipe *pipe)
fs/nfsd/nfs4recover.c
881
sb = rpc_get_sb_net(net);
fs/nfsd/nfs4recover.c
884
rpc_put_sb_net(net);
fs/nfsd/nfs4recover.c
890
__nfsd4_init_cld_pipe(struct net *net)
fs/nfsd/nfs4recover.c
893
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfs4recover.c
913
ret = nfsd4_cld_register_net(net, cn->cn_pipe);
fs/nfsd/nfs4recover.c
933
nfsd4_init_cld_pipe(struct net *net)
fs/nfsd/nfs4recover.c
937
status = __nfsd4_init_cld_pipe(net);
fs/nfsd/nfs4recover.c
944
nfsd4_remove_cld_pipe(struct net *net)
fs/nfsd/nfs4recover.c
946
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfs4recover.c
949
nfsd4_cld_unregister_net(net, cn->cn_pipe);
fs/nfsd/nfs4state.c
1001
static void nfs4_free_cpntf_statelist(struct net *net, struct nfs4_stid *stid)
fs/nfsd/nfs4state.c
1006
nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfs4state.c
1184
nfs4_free_cpntf_statelist(clp->net, s);
fs/nfsd/nfs4state.c
1280
struct nfsd_net *nn = net_generic(clp->net, nfsd_net_id);
fs/nfsd/nfs4state.c
1311
struct nfsd_net *nn = net_generic(clp->net, nfsd_net_id);
fs/nfsd/nfs4state.c
1335
struct nfsd_net *nn = net_generic(dp->dl_stid.sc_client->net,
fs/nfsd/nfs4state.c
1363
struct nfsd_net *nn = net_generic(dp->dl_stid.sc_client->net,
fs/nfsd/nfs4state.c
1555
nfs4_free_cpntf_statelist(stid->sc_client->net, stid);
fs/nfsd/nfs4state.c
1713
struct nfsd_net *nn = net_generic(oo->oo_owner.so_client->net,
fs/nfsd/nfs4state.c
172
struct nfsd_net *nn = net_generic(clp->net, nfsd_net_id);
fs/nfsd/nfs4state.c
188
struct nfsd_net *nn = net_generic(clp->net, nfsd_net_id);
fs/nfsd/nfs4state.c
207
struct nfsd_net *nn = net_generic(clp->net, nfsd_net_id);
fs/nfsd/nfs4state.c
2108
struct nfsd_net *nn = net_generic(ses->se_client->net,
fs/nfsd/nfs4state.c
221
struct nfsd_net *nn = net_generic(clp->net, nfsd_net_id);
fs/nfsd/nfs4state.c
2381
__find_in_sessionid_hashtbl(struct nfs4_sessionid *sessionid, struct net *net)
fs/nfsd/nfs4state.c
2385
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfs4state.c
2404
find_in_sessionid_hashtbl(struct nfs4_sessionid *sessionid, struct net *net,
fs/nfsd/nfs4state.c
2410
session = __find_in_sessionid_hashtbl(sessionid, net);
fs/nfsd/nfs4state.c
2426
struct nfsd_net *nn = net_generic(clp->net, nfsd_net_id);
fs/nfsd/nfs4state.c
248
struct nfsd_net *nn = net_generic(clp->net, nfsd_net_id);
fs/nfsd/nfs4state.c
2564
struct nfsd_net *nn = net_generic(clp->net, nfsd_net_id);
fs/nfsd/nfs4state.c
2593
struct nfsd_net *nn = net_generic(clp->net, nfsd_net_id);
fs/nfsd/nfs4state.c
260
struct nfsd_net *nn = net_generic(clp->net, nfsd_net_id);
fs/nfsd/nfs4state.c
2615
struct nfsd_net *nn = net_generic(clp->net, nfsd_net_id);
fs/nfsd/nfs4state.c
2676
struct nfsd_net *nn = net_generic(clp->net, nfsd_net_id);
fs/nfsd/nfs4state.c
2685
clp->net->ns.inum);
fs/nfsd/nfs4state.c
3257
struct nfsd_net *nn = net_generic(clp->net, nfsd_net_id);
fs/nfsd/nfs4state.c
333
struct nfsd_net *nn = net_generic(clp->net, nfsd_net_id);
fs/nfsd/nfs4state.c
3398
struct net *net = SVC_NET(rqstp);
fs/nfsd/nfs4state.c
3399
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfs4state.c
3418
clp->net = net;
fs/nfsd/nfs4state.c
3483
struct nfsd_net *nn = net_generic(clp->net, nfsd_net_id);
fs/nfsd/nfs4state.c
3498
struct nfsd_net *nn = net_generic(clp->net, nfsd_net_id);
fs/nfsd/nfs4state.c
3582
conn->cb_addrlen = rpc_uaddr2sockaddr(clp->net, se->se_callback_addr_val,
fs/nfsd/nfs4state.c
4305
struct net *net = SVC_NET(rqstp);
fs/nfsd/nfs4state.c
4306
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfs4state.c
4311
session = find_in_sessionid_hashtbl(&bcts->sessionid, net, &status);
fs/nfsd/nfs4state.c
4359
struct net *net = SVC_NET(r);
fs/nfsd/nfs4state.c
4360
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfs4state.c
4370
ses = find_in_sessionid_hashtbl(sessionid, net, &status);
fs/nfsd/nfs4state.c
4512
struct net *net = SVC_NET(rqstp);
fs/nfsd/nfs4state.c
4513
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfs4state.c
4527
session = find_in_sessionid_hashtbl(&seq->sessionid, net, &status);
fs/nfsd/nfs4state.c
5364
move_to_close_lru(struct nfs4_ol_stateid *s, struct net *net)
fs/nfsd/nfs4state.c
5368
struct nfsd_net *nn = net_generic(s->st_stid.sc_client->net,
fs/nfsd/nfs4state.c
5534
struct nfsd_net *nn = net_generic(dp->dl_stid.sc_client->net,
fs/nfsd/nfs4state.c
5636
nn = net_generic(clp->net, nfsd_net_id);
fs/nfsd/nfs4state.c
6183
struct nfsd_net *nn = net_generic(clp->net, nfsd_net_id);
fs/nfsd/nfs4state.c
6456
if (locks_in_grace(clp->net))
fs/nfsd/nfs4state.c
7252
check_special_stateids(struct net *net, svc_fh *current_fh, stateid_t *stateid, int flags)
fs/nfsd/nfs4state.c
7256
else if (opens_in_grace(net)) {
fs/nfsd/nfs4state.c
742
nn = net_generic(clp->net, nfsd_net_id);
fs/nfsd/nfs4state.c
7573
struct net *net = SVC_NET(rqstp);
fs/nfsd/nfs4state.c
7574
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfs4state.c
7582
status = check_special_stateids(net, fhp, stateid, flags);
fs/nfsd/nfs4state.c
7949
nfs4_free_cpntf_statelist(clp->net, &stp->st_stid);
fs/nfsd/nfs4state.c
7969
struct net *net = SVC_NET(rqstp);
fs/nfsd/nfs4state.c
7970
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfs4state.c
7999
move_to_close_lru(stp, net);
fs/nfsd/nfs4state.c
8104
nn = net_generic(clp->net, nfsd_net_id);
fs/nfsd/nfs4state.c
8122
struct net *net = lo->lo_owner.so_client->net;
fs/nfsd/nfs4state.c
8123
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfs4state.c
8447
struct net *net = SVC_NET(rqstp);
fs/nfsd/nfs4state.c
8448
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfs4state.c
8504
if (locks_in_grace(net) && !lock->lk_reclaim)
fs/nfsd/nfs4state.c
8507
if (!locks_in_grace(net) && lock->lk_reclaim)
fs/nfsd/nfs4state.c
9091
static int nfs4_state_create_net(struct net *net)
fs/nfsd/nfs4state.c
9093
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfs4state.c
9136
get_net(net);
fs/nfsd/nfs4state.c
9151
put_net(net);
fs/nfsd/nfs4state.c
9162
nfs4_state_destroy_net(struct net *net)
fs/nfsd/nfs4state.c
9166
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfs4state.c
9187
put_net(net);
fs/nfsd/nfs4state.c
9191
nfs4_state_start_net(struct net *net)
fs/nfsd/nfs4state.c
9193
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfs4state.c
9196
ret = nfs4_state_create_net(net);
fs/nfsd/nfs4state.c
9199
locks_start_grace(net, &nn->nfsd4_manager);
fs/nfsd/nfs4state.c
9200
nfsd4_client_tracking_init(net);
fs/nfsd/nfs4state.c
9206
nn->nfsd4_grace, net->ns.inum);
fs/nfsd/nfs4state.c
9213
net->ns.inum);
fs/nfsd/nfs4state.c
9243
nfs4_state_shutdown_net(struct net *net)
fs/nfsd/nfs4state.c
9247
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfs4state.c
9268
nfsd4_client_tracking_exit(net);
fs/nfsd/nfs4state.c
9269
nfs4_state_destroy_net(net);
fs/nfsd/nfs4state.c
9588
struct nfsd_net *nn = net_generic(clp->net, nfsd_net_id);
fs/nfsd/nfs4state.c
994
nn = net_generic(copy->cp_clp->net, nfsd_net_id);
fs/nfsd/nfsctl.c
1363
struct net *net = sb->s_fs_info;
fs/nfsd/nfsctl.c
1365
nfsd_shutdown_threads(net);
fs/nfsd/nfsctl.c
1368
put_net(net);
fs/nfsd/nfsctl.c
141
static int exports_net_open(struct net *net, struct file *file)
fs/nfsd/nfsctl.c
145
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfsctl.c
153
get_net(net);
fs/nfsd/nfsctl.c
162
put_net(cd->net);
fs/nfsd/nfsctl.c
1647
struct net *net = genl_info_net(info);
fs/nfsd/nfsctl.c
1648
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfsctl.c
1721
ret = nfsd_svc(nrpools, nthreads, net, current_cred(), scope);
fs/nfsd/nfsctl.c
1739
struct net *net = genl_info_net(info);
fs/nfsd/nfsctl.c
1740
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfsctl.c
1770
for (i = 0; i < nfsd_nrpools(net); ++i) {
fs/nfsd/nfsctl.c
1955
struct net *net = genl_info_net(info);
fs/nfsd/nfsctl.c
1966
err = nfsd_create_serv(net);
fs/nfsd/nfsctl.c
1972
nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfsctl.c
2006
if (WARN_ON_ONCE(xprt->xpt_net != net)) {
fs/nfsd/nfsctl.c
2041
svc_xprt_destroy_all(serv, net, false);
fs/nfsd/nfsctl.c
2064
xprt = svc_find_listener(serv, xcl_name, net, sa);
fs/nfsd/nfsctl.c
2073
ret = svc_xprt_create_from_sa(serv, xcl_name, net, sa, 0,
fs/nfsd/nfsctl.c
2081
nfsd_destroy_serv(net);
fs/nfsd/nfsctl.c
209
static inline struct net *netns(struct file *file)
fs/nfsd/nfsctl.c
2186
struct net *net = genl_info_net(info);
fs/nfsd/nfsctl.c
2204
nla_put_u32(skb, NFSD_A_POOL_MODE_NPOOLS, nfsd_nrpools(net));
fs/nfsd/nfsctl.c
2229
struct net *net = genl_info_net(info);
fs/nfsd/nfsctl.c
2230
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfsctl.c
2256
if (!genl_has_listeners(&nfsd_nl_family, cd->net, NFSD_NLGRP_EXPORTD))
fs/nfsd/nfsctl.c
2275
return genlmsg_multicast_netns(&nfsd_nl_family, cd->net, msg, 0,
fs/nfsd/nfsctl.c
2327
struct net *net = genl_info_net(info);
fs/nfsd/nfsctl.c
2328
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfsctl.c
2335
trace_nfsd_ctl_unlock_fs(net,
fs/nfsd/nfsctl.c
234
struct net *net = netns(file);
fs/nfsd/nfsctl.c
2347
nfsd4_cancel_copy_by_sb(net, path.dentry->d_sb);
fs/nfsd/nfsctl.c
2376
struct net *net = genl_info_net(info);
fs/nfsd/nfsctl.c
2377
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfsctl.c
2384
trace_nfsd_ctl_unlock_export(net,
fs/nfsd/nfsctl.c
2394
nfsd_file_close_export(net, &path);
fs/nfsd/nfsctl.c
2414
static __net_init int nfsd_net_init(struct net *net)
fs/nfsd/nfsctl.c
2416
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfsctl.c
2423
retval = nfsd_export_init(net);
fs/nfsd/nfsctl.c
2426
retval = nfsd_idmap_init(net);
fs/nfsd/nfsctl.c
2436
if (!nfsd_proc_stat_init(net)) {
fs/nfsd/nfsctl.c
2459
nfsd_idmap_shutdown(net);
fs/nfsd/nfsctl.c
2461
nfsd_export_shutdown(net);
fs/nfsd/nfsctl.c
247
if (rpc_pton(net, fo_path, size, sap, salen) == 0)
fs/nfsd/nfsctl.c
2475
static __net_exit void nfsd_net_pre_exit(struct net *net)
fs/nfsd/nfsctl.c
2477
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfsctl.c
2489
static __net_exit void nfsd_net_exit(struct net *net)
fs/nfsd/nfsctl.c
2491
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfsctl.c
2495
nfsd_proc_stat_shutdown(net);
fs/nfsd/nfsctl.c
2497
nfsd_idmap_shutdown(net);
fs/nfsd/nfsctl.c
2498
nfsd_export_shutdown(net);
fs/nfsd/nfsctl.c
250
trace_nfsd_ctl_unlock_ip(net, sap, svc_addr_len(sap));
fs/nfsd/nfsctl.c
422
struct net *net = netns(file);
fs/nfsd/nfsctl.c
431
trace_nfsd_ctl_threads(net, newthreads);
fs/nfsd/nfsctl.c
433
rv = nfsd_svc(1, &newthreads, net, file->f_cred, NULL);
fs/nfsd/nfsctl.c
438
rv = nfsd_nrthreads(net);
fs/nfsd/nfsctl.c
476
struct net *net = netns(file);
fs/nfsd/nfsctl.c
479
npools = nfsd_nrpools(net);
fs/nfsd/nfsctl.c
506
trace_nfsd_ctl_pool_threads(net, i, nthreads[i]);
fs/nfsd/nfsctl.c
516
rv = nfsd_set_nrthreads(i, nthreads, net);
fs/nfsd/nfsctl.c
521
rv = nfsd_get_nrthreads(npools, nthreads, net);
fs/nfsd/nfsctl.c
711
static ssize_t __write_ports_names(char *buf, struct net *net)
fs/nfsd/nfsctl.c
713
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfsctl.c
725
static ssize_t __write_ports_addfd(char *buf, struct net *net, const struct cred *cred)
fs/nfsd/nfsctl.c
729
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfsctl.c
735
trace_nfsd_ctl_ports_addfd(net, fd);
fs/nfsd/nfsctl.c
737
err = nfsd_create_serv(net);
fs/nfsd/nfsctl.c
742
err = svc_addsock(serv, net, fd, buf, SIMPLE_TRANSACTION_LIMIT, cred);
fs/nfsd/nfsctl.c
745
nfsd_destroy_serv(net);
fs/nfsd/nfsctl.c
754
static ssize_t __write_ports_addxprt(char *buf, struct net *net, const struct cred *cred)
fs/nfsd/nfsctl.c
759
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfsctl.c
767
trace_nfsd_ctl_ports_addxprt(net, transport, port);
fs/nfsd/nfsctl.c
769
err = nfsd_create_serv(net);
fs/nfsd/nfsctl.c
774
err = svc_xprt_create(serv, transport, net,
fs/nfsd/nfsctl.c
779
err = svc_xprt_create(serv, transport, net,
fs/nfsd/nfsctl.c
786
xprt = svc_find_xprt(serv, transport, net, PF_INET, port);
fs/nfsd/nfsctl.c
793
nfsd_destroy_serv(net);
fs/nfsd/nfsctl.c
799
struct net *net)
fs/nfsd/nfsctl.c
802
return __write_ports_names(buf, net);
fs/nfsd/nfsctl.c
805
return __write_ports_addfd(buf, net, file->f_cred);
fs/nfsd/nfsctl.c
808
return __write_ports_addxprt(buf, net, file->f_cred);
fs/nfsd/nfsd.h
135
int nfsd_create_serv(struct net *net);
fs/nfsd/nfsd.h
136
void nfsd_destroy_serv(struct net *net);
fs/nfsd/nfsd.h
180
int nfs4_state_start_net(struct net *net);
fs/nfsd/nfsd.h
182
void nfs4_state_shutdown_net(struct net *net);
fs/nfsd/nfsd.h
193
static inline int nfs4_state_start_net(struct net *net) { return 0; }
fs/nfsd/nfsd.h
195
static inline void nfs4_state_shutdown_net(struct net *net) { }
fs/nfsd/nfsd.h
87
int nfsd_svc(int n, int *nservers, struct net *net,
fs/nfsd/nfsd.h
91
int nfsd_nrthreads(struct net *);
fs/nfsd/nfsd.h
92
int nfsd_nrpools(struct net *);
fs/nfsd/nfsd.h
93
int nfsd_get_nrthreads(int n, int *, struct net *);
fs/nfsd/nfsd.h
94
int nfsd_set_nrthreads(int n, int *, struct net *);
fs/nfsd/nfsd.h
95
void nfsd_shutdown_threads(struct net *net);
fs/nfsd/nfsfh.c
147
static bool fh_append_mac(struct svc_fh *fhp, struct net *net)
fs/nfsd/nfsfh.c
149
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfsfh.c
178
static bool fh_verify_mac(struct svc_fh *fhp, struct net *net)
fs/nfsd/nfsfh.c
180
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfsfh.c
200
static __be32 nfsd_set_fh_dentry(struct svc_rqst *rqstp, struct net *net,
fs/nfsd/nfsfh.c
249
net, client, gssclient,
fs/nfsd/nfsfh.c
299
if (!fh_verify_mac(fhp, net)) {
fs/nfsd/nfsfh.c
382
struct net *net, struct svc_cred *cred,
fs/nfsd/nfsfh.c
387
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfsfh.c
394
error = nfsd_set_fh_dentry(rqstp, net, cred, client,
fs/nfsd/nfsfh.c
498
fh_verify_local(struct net *net, struct svc_cred *cred,
fs/nfsd/nfsfh.c
502
return __fh_verify(NULL, net, cred, client, NULL,
fs/nfsd/nfsfh.c
565
if (!fh_append_mac(fhp, exp->cd->net))
fs/nfsd/nfsfh.h
223
__be32 fh_verify_local(struct net *, struct svc_cred *, struct auth_domain *,
fs/nfsd/nfssvc.c
207
bool nfsd_net_try_get(struct net *net) __must_hold(rcu)
fs/nfsd/nfssvc.c
209
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfssvc.c
214
void nfsd_net_put(struct net *net) __must_hold(rcu)
fs/nfsd/nfssvc.c
216
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfssvc.c
240
int nfsd_nrthreads(struct net *net)
fs/nfsd/nfssvc.c
243
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfssvc.c
349
static int nfsd_startup_net(struct net *net, const struct cred *cred)
fs/nfsd/nfssvc.c
351
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfssvc.c
368
ret = lockd_up(net, cred);
fs/nfsd/nfssvc.c
374
ret = nfsd_file_cache_start_net(net);
fs/nfsd/nfssvc.c
385
ret = nfs4_state_start_net(net);
fs/nfsd/nfssvc.c
395
nfsd_file_cache_shutdown_net(net);
fs/nfsd/nfssvc.c
398
lockd_down(net);
fs/nfsd/nfssvc.c
406
static void nfsd_shutdown_net(struct net *net)
fs/nfsd/nfssvc.c
408
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfssvc.c
41
static int nfsd_acl_rpcbind_set(struct net *,
fs/nfsd/nfssvc.c
414
nfsd_export_flush(net);
fs/nfsd/nfssvc.c
415
nfs4_state_shutdown_net(net);
fs/nfsd/nfssvc.c
417
nfsd_file_cache_shutdown_net(net);
fs/nfsd/nfssvc.c
419
lockd_down(net);
fs/nfsd/nfssvc.c
438
struct net *net = dev_net(dev);
fs/nfsd/nfssvc.c
439
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfssvc.c
468
struct net *net = dev_net(dev);
fs/nfsd/nfssvc.c
469
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfssvc.c
50
static int nfsd_rpcbind_set(struct net *,
fs/nfsd/nfssvc.c
502
void nfsd_destroy_serv(struct net *net)
fs/nfsd/nfssvc.c
504
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfssvc.c
527
svc_xprt_destroy_all(serv, net, true);
fs/nfsd/nfssvc.c
528
nfsd_shutdown_net(net);
fs/nfsd/nfssvc.c
571
void nfsd_shutdown_threads(struct net *net)
fs/nfsd/nfssvc.c
573
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfssvc.c
585
nfsd_destroy_serv(net);
fs/nfsd/nfssvc.c
596
int nfsd_create_serv(struct net *net)
fs/nfsd/nfssvc.c
599
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfssvc.c
624
error = svc_bind(serv, net);
fs/nfsd/nfssvc.c
645
int nfsd_nrpools(struct net *net)
fs/nfsd/nfssvc.c
647
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfssvc.c
655
int nfsd_get_nrthreads(int n, int *nthreads, struct net *net)
fs/nfsd/nfssvc.c
657
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfssvc.c
680
int nfsd_set_nrthreads(int n, int *nthreads, struct net *net)
fs/nfsd/nfssvc.c
685
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfssvc.c
751
nfsd_svc(int n, int *nthreads, struct net *net, const struct cred *cred, const char *scope)
fs/nfsd/nfssvc.c
754
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfssvc.c
764
error = nfsd_create_serv(net);
fs/nfsd/nfssvc.c
769
error = nfsd_startup_net(net, cred);
fs/nfsd/nfssvc.c
772
error = nfsd_set_nrthreads(n, nthreads, net);
fs/nfsd/nfssvc.c
778
nfsd_destroy_serv(net);
fs/nfsd/nfssvc.c
793
nfsd_acl_rpcbind_set(struct net *net, const struct svc_program *progp,
fs/nfsd/nfssvc.c
798
!nfsd_vers(net_generic(net, nfsd_net_id), version, NFSD_TEST))
fs/nfsd/nfssvc.c
800
return svc_generic_rpcbind_set(net, progp, version, family,
fs/nfsd/nfssvc.c
839
nfsd_rpcbind_set(struct net *net, const struct svc_program *progp,
fs/nfsd/nfssvc.c
843
if (!nfsd_vers(net_generic(net, nfsd_net_id), version, NFSD_TEST))
fs/nfsd/nfssvc.c
845
return svc_generic_rpcbind_set(net, progp, version, family,
fs/nfsd/nfssvc.c
888
struct net *net = perm_sock->xpt_net;
fs/nfsd/nfssvc.c
889
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/nfssvc.c
918
trace_nfsd_dynthread_kill(net, pool);
fs/nfsd/nfssvc.c
925
trace_nfsd_dynthread_trylock_fail(net, pool);
fs/nfsd/nfssvc.c
935
trace_nfsd_dynthread_start(net, pool);
fs/nfsd/nfssvc.c
943
trace_nfsd_dynthread_trylock_fail(net, pool);
fs/nfsd/state.h
522
struct net *net;
fs/nfsd/state.h
867
void nfsd4_cancel_copy_by_sb(struct net *net, struct super_block *sb);
fs/nfsd/state.h
878
static inline void nfsd4_cancel_copy_by_sb(struct net *net, struct super_block *sb)
fs/nfsd/state.h
894
extern int nfsd4_client_tracking_init(struct net *net);
fs/nfsd/state.h
895
extern void nfsd4_client_tracking_exit(struct net *net);
fs/nfsd/stats.c
32
struct net *net = pde_data(file_inode(seq->file));
fs/nfsd/stats.c
33
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/stats.c
76
struct proc_dir_entry *nfsd_proc_stat_init(struct net *net)
fs/nfsd/stats.c
78
struct nfsd_net *nn = net_generic(net, nfsd_net_id);
fs/nfsd/stats.c
80
return svc_proc_register(net, &nn->nfsd_svcstats, &nfsd_proc_ops);
fs/nfsd/stats.c
83
void nfsd_proc_stat_shutdown(struct net *net)
fs/nfsd/stats.c
85
svc_proc_unregister(net, "nfsd");
fs/nfsd/stats.h
13
struct proc_dir_entry *nfsd_proc_stat_init(struct net *net);
fs/nfsd/stats.h
14
void nfsd_proc_stat_shutdown(struct net *net);
fs/nfsd/trace.h
108
__entry->netns_ino = net->ns.inum;
fs/nfsd/trace.h
122
TP_PROTO(const struct net *net, const struct svc_pool *pool), \
fs/nfsd/trace.h
123
TP_ARGS(net, pool))
fs/nfsd/trace.h
1987
const struct net *net,
fs/nfsd/trace.h
1991
TP_ARGS(net, addr, addrlen),
fs/nfsd/trace.h
1997
__entry->netns_ino = net->ns.inum;
fs/nfsd/trace.h
2007
const struct net *net,
fs/nfsd/trace.h
2010
TP_ARGS(net, path),
fs/nfsd/trace.h
2016
__entry->netns_ino = net->ns.inum;
fs/nfsd/trace.h
2026
const struct net *net,
fs/nfsd/trace.h
2029
TP_ARGS(net, path),
fs/nfsd/trace.h
2035
__entry->netns_ino = net->ns.inum;
fs/nfsd/trace.h
2045
const struct net *net,
fs/nfsd/trace.h
2050
TP_ARGS(net, domain, path, maxsize),
fs/nfsd/trace.h
2058
__entry->netns_ino = net->ns.inum;
fs/nfsd/trace.h
2070
const struct net *net,
fs/nfsd/trace.h
2073
TP_ARGS(net, newthreads),
fs/nfsd/trace.h
2079
__entry->netns_ino = net->ns.inum;
fs/nfsd/trace.h
2089
const struct net *net,
fs/nfsd/trace.h
2093
TP_ARGS(net, pool, nrthreads),
fs/nfsd/trace.h
2100
__entry->netns_ino = net->ns.inum;
fs/nfsd/trace.h
2111
const struct net *net,
fs/nfsd/trace.h
2114
TP_ARGS(net, mesg),
fs/nfsd/trace.h
2120
__entry->netns_ino = net->ns.inum;
fs/nfsd/trace.h
2130
const struct net *net,
fs/nfsd/trace.h
2133
TP_ARGS(net, fd),
fs/nfsd/trace.h
2139
__entry->netns_ino = net->ns.inum;
fs/nfsd/trace.h
2149
const struct net *net,
fs/nfsd/trace.h
2153
TP_ARGS(net, transport, port),
fs/nfsd/trace.h
2160
__entry->netns_ino = net->ns.inum;
fs/nfsd/trace.h
2171
const struct net *net,
fs/nfsd/trace.h
2174
TP_ARGS(net, bsize),
fs/nfsd/trace.h
2180
__entry->netns_ino = net->ns.inum;
fs/nfsd/trace.h
2190
const struct net *net,
fs/nfsd/trace.h
2193
TP_ARGS(net, minthreads),
fs/nfsd/trace.h
2199
__entry->netns_ino = net->ns.inum;
fs/nfsd/trace.h
2209
const struct net *net,
fs/nfsd/trace.h
2214
TP_ARGS(net, name, namelen, time),
fs/nfsd/trace.h
2221
__entry->netns_ino = net->ns.inum;
fs/nfsd/trace.h
2232
const struct net *net,
fs/nfsd/trace.h
2235
TP_ARGS(net, recdir),
fs/nfsd/trace.h
2241
__entry->netns_ino = net->ns.inum;
fs/nfsd/trace.h
2251
const struct net *net
fs/nfsd/trace.h
2253
TP_ARGS(net),
fs/nfsd/trace.h
2258
__entry->netns_ino = net->ns.inum;
fs/nfsd/trace.h
2730
__entry->netns_ino = clp->net->ns.inum;
fs/nfsd/trace.h
96
const struct net *net,
fs/nfsd/trace.h
99
TP_ARGS(net, pool),
fs/proc/proc_net.c
100
p->net = get_net_track(current->nsproxy->net_ns, &p->ns_tracker,
fs/proc/proc_net.c
111
put_net_track(p->net, &p->ns_tracker);
fs/proc/proc_net.c
181
struct net *net;
fs/proc/proc_net.c
184
net = get_proc_net(inode);
fs/proc/proc_net.c
185
if (!net)
fs/proc/proc_net.c
188
err = single_open(file, de->single_show, net);
fs/proc/proc_net.c
190
put_net(net);
fs/proc/proc_net.c
269
static struct net *get_proc_task_net(struct inode *dir)
fs/proc/proc_net.c
273
struct net *net = NULL;
fs/proc/proc_net.c
282
net = get_net(ns->net_ns);
fs/proc/proc_net.c
287
if (net && (fs_info->pidonly == PROC_PIDONLY_ON) &&
fs/proc/proc_net.c
288
security_capable(fs_info->mounter_cred, net->user_ns, CAP_NET_ADMIN, CAP_OPT_NONE) < 0) {
fs/proc/proc_net.c
289
put_net(net);
fs/proc/proc_net.c
290
net = NULL;
fs/proc/proc_net.c
293
return net;
fs/proc/proc_net.c
30
static inline struct net *PDE_NET(struct proc_dir_entry *pde)
fs/proc/proc_net.c
300
struct net *net;
fs/proc/proc_net.c
303
net = get_proc_task_net(dir);
fs/proc/proc_net.c
304
if (net != NULL) {
fs/proc/proc_net.c
305
de = proc_lookup_de(dir, dentry, net->proc_net);
fs/proc/proc_net.c
306
put_net(net);
fs/proc/proc_net.c
316
struct net *net;
fs/proc/proc_net.c
318
net = get_proc_task_net(inode);
fs/proc/proc_net.c
322
if (net != NULL) {
fs/proc/proc_net.c
323
stat->nlink = net->proc_net->nlink;
fs/proc/proc_net.c
324
put_net(net);
fs/proc/proc_net.c
339
struct net *net;
fs/proc/proc_net.c
342
net = get_proc_task_net(file_inode(file));
fs/proc/proc_net.c
343
if (net != NULL) {
fs/proc/proc_net.c
344
ret = proc_readdir_de(file, ctx, net->proc_net);
fs/proc/proc_net.c
345
put_net(net);
fs/proc/proc_net.c
35
static struct net *get_proc_net(const struct inode *inode)
fs/proc/proc_net.c
356
static __net_init int proc_net_ns_init(struct net *net)
fs/proc/proc_net.c
375
netd->data = net;
fs/proc/proc_net.c
382
uid = make_kuid(net->user_ns, 0);
fs/proc/proc_net.c
386
gid = make_kgid(net->user_ns, 0);
fs/proc/proc_net.c
396
net_statd = proc_net_mkdir(net, "stat", netd);
fs/proc/proc_net.c
400
net->proc_net = netd;
fs/proc/proc_net.c
401
net->proc_net_stat = net_statd;
fs/proc/proc_net.c
410
static __net_exit void proc_net_ns_exit(struct net *net)
fs/proc/proc_net.c
412
remove_proc_entry("stat", net->proc_net);
fs/proc/proc_net.c
413
pde_free(net->proc_net);
fs/proc/proc_net.c
44
struct net *net;
fs/proc/proc_net.c
51
net = get_proc_net(inode);
fs/proc/proc_net.c
52
if (!net)
fs/proc/proc_net.c
57
put_net(net);
fs/proc/proc_net.c
61
p->net = net;
fs/proc/proc_net.c
62
netns_tracker_alloc(net, &p->ns_tracker, GFP_KERNEL);
fs/proc/proc_net.c
72
put_net_track(priv->net, &priv->ns_tracker);
fs/smb/client/cifs_debug.c
149
if (server->net)
fs/smb/client/cifs_debug.c
150
seq_printf(m, " Net namespace: %u ", server->net->ns.inum);
fs/smb/client/cifs_debug.c
541
if (server->net)
fs/smb/client/cifs_debug.c
542
seq_printf(m, " Net namespace: %u ", server->net->ns.inum);
fs/smb/client/cifsglob.h
1000
static inline struct net *cifs_net_ns(struct TCP_Server_Info *srv)
fs/smb/client/cifsglob.h
1002
return srv->net;
fs/smb/client/cifsglob.h
1005
static inline void cifs_set_net_ns(struct TCP_Server_Info *srv, struct net *net)
fs/smb/client/cifsglob.h
1007
srv->net = net;
fs/smb/client/cifsglob.h
1012
static inline struct net *cifs_net_ns(struct TCP_Server_Info *srv)
fs/smb/client/cifsglob.h
1017
static inline void cifs_set_net_ns(struct TCP_Server_Info *srv, struct net *net)
fs/smb/client/cifsglob.h
695
struct net *net;
fs/smb/client/connect.c
3365
struct net *net = cifs_net_ns(server);
fs/smb/client/connect.c
3368
rc = sock_create_kern(net, sfamily, SOCK_STREAM,
fs/smb/client/smbdirect.c
255
struct net *net = cifs_net_ns(server);
fs/smb/client/smbdirect.c
306
ret = smbdirect_socket_create_kern(net, &sc);
fs/smb/server/transport_rdma.c
377
struct net *net = current->nsproxy->net_ns;
fs/smb/server/transport_rdma.c
412
ret = smbdirect_socket_create_kern(net, &sc);
fs/smb/smbdirect/internal.h
49
int smbdirect_socket_init_new(struct net *net, struct smbdirect_socket *sc);
fs/smb/smbdirect/socket.c
54
int smbdirect_socket_init_new(struct net *net, struct smbdirect_socket *sc)
fs/smb/smbdirect/socket.c
61
id = rdma_create_id(net,
fs/smb/smbdirect/socket.c
86
int smbdirect_socket_create_kern(struct net *net, struct smbdirect_socket **_sc)
fs/smb/smbdirect/socket.c
96
ret = smbdirect_socket_init_new(net, sc);
fs/sysfs/mount.c
61
struct net *netns = to_net_ns(ns);
include/linux/bnxt/ulp.h
67
struct net_device *net;
include/linux/can/core.h
50
int can_rx_register(struct net *net, struct net_device *dev,
include/linux/can/core.h
55
extern void can_rx_unregister(struct net *net, struct net_device *dev,
include/linux/ceph/messenger.h
109
possible_net_t net;
include/linux/dns_resolver.h
29
struct net;
include/linux/dns_resolver.h
30
extern int dns_query(struct net *net, const char *type, const char *name, size_t namelen,
include/linux/filelock.h
77
struct net;
include/linux/filelock.h
78
void locks_start_grace(struct net *, struct lock_manager *);
include/linux/filelock.h
80
bool locks_in_grace(struct net *);
include/linux/filelock.h
81
bool opens_in_grace(struct net *);
include/linux/filter.h
1743
static inline bool bpf_sk_lookup_run_v4(const struct net *net, int protocol,
include/linux/filter.h
1753
run_array = rcu_dereference(net->bpf.run_array[NETNS_BPF_SK_LOOKUP]);
include/linux/filter.h
1780
static inline bool bpf_sk_lookup_run_v6(const struct net *net, int protocol,
include/linux/filter.h
1792
run_array = rcu_dereference(net->bpf.run_array[NETNS_BPF_SK_LOOKUP]);
include/linux/fs_context.h
22
struct net;
include/linux/fs_context.h
98
struct net *net_ns; /* The network namespace for this mount */
include/linux/if_bridge.h
97
void brioctl_set(int (*hook)(struct net *net, unsigned int cmd,
include/linux/if_bridge.h
99
int br_ioctl_call(struct net *net, unsigned int cmd, void __user *uarg);
include/linux/if_pppox.h
63
int (*create)(struct net *net, struct socket *sock, int kern);
include/linux/if_vlan.h
80
extern void vlan_ioctl_set(int (*hook)(struct net *, void __user *));
include/linux/inet.h
56
extern int inet_pton_with_scope(struct net *net, unsigned short af,
include/linux/inetdevice.h
123
#define IN_DEV_NET_ROUTE_LOCALNET(in_dev, net) \
include/linux/inetdevice.h
124
IN_DEV_NET_ORCONF(in_dev, net, ROUTE_LOCALNET)
include/linux/inetdevice.h
177
void inet_netconf_notify_devconf(struct net *net, int event, int type,
include/linux/inetdevice.h
180
struct net_device *__ip_dev_find(struct net *net, __be32 addr, bool devref);
include/linux/inetdevice.h
181
static inline struct net_device *ip_dev_find(struct net *net, __be32 addr)
include/linux/inetdevice.h
183
return __ip_dev_find(net, addr, true);
include/linux/inetdevice.h
187
int devinet_ioctl(struct net *net, unsigned int cmd, struct ifreq *);
include/linux/inetdevice.h
198
struct in_device *inetdev_by_index(struct net *, int);
include/linux/inetdevice.h
200
__be32 inet_confirm_addr(struct net *net, struct in_device *in_dev, __be32 dst,
include/linux/inetdevice.h
204
struct in_ifaddr *inet_lookup_ifaddr_rcu(struct net *net, __be32 addr);
include/linux/inetdevice.h
229
#define in_dev_for_each_ifa_rtnl_net(net, ifa, in_dev) \
include/linux/inetdevice.h
230
for (ifa = rtnl_net_dereference(net, (in_dev)->ifa_list); ifa; \
include/linux/inetdevice.h
231
ifa = rtnl_net_dereference(net, ifa->ifa_next))
include/linux/inetdevice.h
57
#define IPV4_DEVCONF_ALL(net, attr) \
include/linux/inetdevice.h
58
IPV4_DEVCONF((*(net)->ipv4.devconf_all), attr)
include/linux/inetdevice.h
59
#define IPV4_DEVCONF_ALL_RO(net, attr) READ_ONCE(IPV4_DEVCONF_ALL(net, attr))
include/linux/inetdevice.h
89
#define IN_DEV_NET_ORCONF(in_dev, net, attr) \
include/linux/inetdevice.h
90
(IPV4_DEVCONF_ALL_RO(net, attr) || \
include/linux/key.h
34
struct net;
include/linux/key.h
370
#define request_key_net(type, description, net, callout_info) \
include/linux/key.h
371
request_key_tag(type, description, net->key_domain, callout_info)
include/linux/key.h
382
#define request_key_net_rcu(type, description, net) \
include/linux/key.h
383
request_key_rcu(type, description, net->key_domain)
include/linux/lockd/bind.h
42
struct net *net;
include/linux/lockd/bind.h
76
extern int lockd_up(struct net *net, const struct cred *cred);
include/linux/lockd/bind.h
77
extern void lockd_down(struct net *net);
include/linux/lsm_audit.h
85
struct lsm_network_audit *net;
include/linux/mlx5/driver.h
1391
static inline struct net *mlx5_core_net(struct mlx5_core_dev *dev)
include/linux/mroute.h
92
int ipmr_get_route(struct net *net, struct sk_buff *skb,
include/linux/mroute6.h
104
extern int ip6mr_get_route(struct net *net, struct sk_buff *skb,
include/linux/mroute6.h
108
bool mroute6_is_socket(struct net *net, struct sk_buff *skb);
include/linux/mroute6.h
132
static inline bool mroute6_is_socket(struct net *net, struct sk_buff *skb)
include/linux/mroute6.h
34
extern int ip6_mr_output(struct net *net, struct sock *sk, struct sk_buff *skb);
include/linux/mroute6.h
63
ip6_mr_output(struct net *net, struct sock *sk, struct sk_buff *skb)
include/linux/mroute6.h
65
return ip6_output(net, sk, skb);
include/linux/mroute_base.h
197
static inline int mr_call_mfc_notifiers(struct net *net,
include/linux/mroute_base.h
212
return call_fib_notifiers(net, event_type, &info.info);
include/linux/mroute_base.h
249
possible_net_t net;
include/linux/mroute_base.h
266
static inline bool mr_can_free_table(struct net *net)
include/linux/mroute_base.h
268
return !check_net(net) || !net_initialized(net);
include/linux/mroute_base.h
281
mr_table_alloc(struct net *net, u32 id,
include/linux/mroute_base.h
285
struct net *net));
include/linux/mroute_base.h
304
struct mr_table *(*iter)(struct net *net,
include/linux/mroute_base.h
312
int mr_dump(struct net *net, struct notifier_block *nb, unsigned short family,
include/linux/mroute_base.h
313
int (*rules_dump)(struct net *net,
include/linux/mroute_base.h
316
struct mr_table *(*mr_iter)(struct net *net,
include/linux/mroute_base.h
355
struct mr_table *(*iter)(struct net *net,
include/linux/mroute_base.h
366
static inline int mr_dump(struct net *net, struct notifier_block *nb,
include/linux/mroute_base.h
368
int (*rules_dump)(struct net *net,
include/linux/mroute_base.h
371
struct mr_table *(*mr_iter)(struct net *net,
include/linux/mroute_base.h
401
void *mr_vif_seq_idx(struct net *net, struct mr_vif_iter *iter, loff_t pos);
include/linux/mroute_base.h
414
void *mr_mfc_seq_idx(struct net *net,
include/linux/mroute_base.h
444
static inline void *mr_vif_seq_idx(struct net *net, struct mr_vif_iter *iter,
include/linux/mroute_base.h
461
static inline void *mr_mfc_seq_idx(struct net *net,
include/linux/mroute_base.h
73
static inline int mr_call_vif_notifiers(struct net *net,
include/linux/mroute_base.h
93
return call_fib_notifiers(net, event_type, &info.info);
include/linux/net.h
257
int (*create)(struct net *net, struct socket *sock,
include/linux/net.h
276
int __sock_create(struct net *net, int family, int type, int proto,
include/linux/net.h
279
int sock_create_kern(struct net *net, int family, int type, int proto, struct socket **res);
include/linux/net.h
54
struct net;
include/linux/netdevice.h
2791
struct net *dev_net(const struct net_device *dev)
include/linux/netdevice.h
2797
struct net *dev_net_rcu(const struct net_device *dev)
include/linux/netdevice.h
2803
void dev_net_set(struct net_device *dev, struct net *net)
include/linux/netdevice.h
2805
write_pnet(&dev->nd_net, net);
include/linux/netdevice.h
2833
#define SET_NETDEV_DEV(net, pdev) ((net)->dev.parent = (pdev))
include/linux/netdevice.h
2839
#define SET_NETDEV_DEVTYPE(net, devtype) ((net)->dev.type = (devtype))
include/linux/netdevice.h
3011
struct net *af_packet_net;
include/linux/netdevice.h
3256
int register_netdevice_notifier_net(struct net *net, struct notifier_block *nb);
include/linux/netdevice.h
3257
int unregister_netdevice_notifier_net(struct net *net,
include/linux/netdevice.h
3360
#define for_each_netdev(net, d) \
include/linux/netdevice.h
3361
list_for_each_entry(d, &(net)->dev_base_head, dev_list)
include/linux/netdevice.h
3362
#define for_each_netdev_reverse(net, d) \
include/linux/netdevice.h
3363
list_for_each_entry_reverse(d, &(net)->dev_base_head, dev_list)
include/linux/netdevice.h
3364
#define for_each_netdev_rcu(net, d) \
include/linux/netdevice.h
3365
list_for_each_entry_rcu(d, &(net)->dev_base_head, dev_list)
include/linux/netdevice.h
3366
#define for_each_netdev_safe(net, d, n) \
include/linux/netdevice.h
3367
list_for_each_entry_safe(d, n, &(net)->dev_base_head, dev_list)
include/linux/netdevice.h
3368
#define for_each_netdev_continue(net, d) \
include/linux/netdevice.h
3369
list_for_each_entry_continue(d, &(net)->dev_base_head, dev_list)
include/linux/netdevice.h
3370
#define for_each_netdev_continue_reverse(net, d) \
include/linux/netdevice.h
3371
list_for_each_entry_continue_reverse(d, &(net)->dev_base_head, \
include/linux/netdevice.h
3373
#define for_each_netdev_continue_rcu(net, d) \
include/linux/netdevice.h
3374
list_for_each_entry_continue_rcu(d, &(net)->dev_base_head, dev_list)
include/linux/netdevice.h
3380
#define for_each_netdev_dump(net, d, ifindex) \
include/linux/netdevice.h
3381
for (; (d = xa_find(&(net)->dev_by_index, &ifindex, \
include/linux/netdevice.h
3387
struct net *net;
include/linux/netdevice.h
3389
net = dev_net(dev);
include/linux/netdevice.h
3391
return lh == &net->dev_base_head ? NULL : net_device_entry(lh);
include/linux/netdevice.h
3397
struct net *net;
include/linux/netdevice.h
3399
net = dev_net(dev);
include/linux/netdevice.h
3401
return lh == &net->dev_base_head ? NULL : net_device_entry(lh);
include/linux/netdevice.h
3404
static inline struct net_device *first_net_device(struct net *net)
include/linux/netdevice.h
3406
return list_empty(&net->dev_base_head) ? NULL :
include/linux/netdevice.h
3407
net_device_entry(net->dev_base_head.next);
include/linux/netdevice.h
3410
struct net_device *dev_getbyhwaddr(struct net *net, unsigned short type,
include/linux/netdevice.h
3412
struct net_device *dev_getbyhwaddr_rcu(struct net *net, unsigned short type,
include/linux/netdevice.h
3414
struct net_device *dev_getfirstbyhwtype(struct net *net, unsigned short type);
include/linux/netdevice.h
3425
struct net_device *dev_get_by_name(struct net *net, const char *name);
include/linux/netdevice.h
3426
struct net_device *dev_get_by_name_rcu(struct net *net, const char *name);
include/linux/netdevice.h
3427
struct net_device *__dev_get_by_name(struct net *net, const char *name);
include/linux/netdevice.h
3428
bool netdev_name_in_use(struct net *net, const char *name);
include/linux/netdevice.h
3437
int dev_loopback_xmit(struct net *net, struct sock *sk, struct sk_buff *newskb);
include/linux/netdevice.h
3483
struct net_device *dev_get_by_index(struct net *net, int ifindex);
include/linux/netdevice.h
3484
struct net_device *__dev_get_by_index(struct net *net, int ifindex);
include/linux/netdevice.h
3485
struct net_device *netdev_get_by_index(struct net *net, int ifindex,
include/linux/netdevice.h
3487
struct net_device *netdev_get_by_index_lock(struct net *net, int ifindex);
include/linux/netdevice.h
3488
struct net_device *netdev_get_by_name(struct net *net, const char *name,
include/linux/netdevice.h
3490
struct net_device *netdev_get_by_flags_rcu(struct net *net, netdevice_tracker *tracker,
include/linux/netdevice.h
3492
struct net_device *dev_get_by_index_rcu(struct net *net, int ifindex);
include/linux/netdevice.h
4342
int dev_ioctl(struct net *net, unsigned int cmd, struct ifreq *ifr,
include/linux/netdevice.h
4344
int dev_ifconf(struct net *net, struct ifconf __user *ifc);
include/linux/netdevice.h
4352
int dev_ethtool(struct net *net, struct ifreq *ifr, void __user *userdata);
include/linux/netdevice.h
4363
int __dev_change_net_namespace(struct net_device *dev, struct net *net,
include/linux/netdevice.h
4366
int dev_change_net_namespace(struct net_device *dev, struct net *net,
include/linux/netdevice.h
4379
int netif_get_mac_address(struct sockaddr *sa, struct net *net, char *dev_name);
include/linux/netdevice.h
5180
void dev_load(struct net *net, const char *name);
include/linux/netdevice.h
739
static inline bool net_has_fallback_tunnels(const struct net *net)
include/linux/netdevice.h
745
(net_eq(net, &init_net) && fb_tunnels_only_for_init_net == 1);
include/linux/netfilter.h
167
struct net *net,
include/linux/netfilter.h
168
int (*okfn)(struct net *, struct sock *, struct sk_buff *))
include/linux/netfilter.h
175
p->net = net;
include/linux/netfilter.h
199
int nf_register_net_hook(struct net *net, const struct nf_hook_ops *ops);
include/linux/netfilter.h
200
void nf_unregister_net_hook(struct net *net, const struct nf_hook_ops *ops);
include/linux/netfilter.h
201
int nf_register_net_hooks(struct net *net, const struct nf_hook_ops *reg,
include/linux/netfilter.h
203
void nf_unregister_net_hooks(struct net *net, const struct nf_hook_ops *reg,
include/linux/netfilter.h
227
static inline int nf_hook(u_int8_t pf, unsigned int hook, struct net *net,
include/linux/netfilter.h
230
int (*okfn)(struct net *, struct sock *, struct sk_buff *))
include/linux/netfilter.h
245
hook_head = rcu_dereference(net->nf.hooks_ipv4[hook]);
include/linux/netfilter.h
248
hook_head = rcu_dereference(net->nf.hooks_ipv6[hook]);
include/linux/netfilter.h
252
if (WARN_ON_ONCE(hook >= ARRAY_SIZE(net->nf.hooks_arp)))
include/linux/netfilter.h
254
hook_head = rcu_dereference(net->nf.hooks_arp[hook]);
include/linux/netfilter.h
259
hook_head = rcu_dereference(net->nf.hooks_bridge[hook]);
include/linux/netfilter.h
271
sk, net, okfn);
include/linux/netfilter.h
298
NF_HOOK_COND(uint8_t pf, unsigned int hook, struct net *net, struct sock *sk,
include/linux/netfilter.h
300
int (*okfn)(struct net *, struct sock *, struct sk_buff *),
include/linux/netfilter.h
306
((ret = nf_hook(pf, hook, net, sk, skb, in, out, okfn)) == 1))
include/linux/netfilter.h
307
ret = okfn(net, sk, skb);
include/linux/netfilter.h
312
NF_HOOK(uint8_t pf, unsigned int hook, struct net *net, struct sock *sk, struct sk_buff *skb,
include/linux/netfilter.h
314
int (*okfn)(struct net *, struct sock *, struct sk_buff *))
include/linux/netfilter.h
316
int ret = nf_hook(pf, hook, net, sk, skb, in, out, okfn);
include/linux/netfilter.h
318
ret = okfn(net, sk, skb);
include/linux/netfilter.h
323
NF_HOOK_LIST(uint8_t pf, unsigned int hook, struct net *net, struct sock *sk,
include/linux/netfilter.h
325
int (*okfn)(struct net *, struct sock *, struct sk_buff *))
include/linux/netfilter.h
339
hook_head = rcu_dereference(net->nf.hooks_ipv4[hook]);
include/linux/netfilter.h
342
hook_head = rcu_dereference(net->nf.hooks_ipv6[hook]);
include/linux/netfilter.h
352
nf_hook_state_init(&state, hook, pf, in, out, sk, net, okfn);
include/linux/netfilter.h
375
int nf_route(struct net *net, struct dst_entry **dst, struct flowi *fl,
include/linux/netfilter.h
409
NF_HOOK_COND(uint8_t pf, unsigned int hook, struct net *net, struct sock *sk,
include/linux/netfilter.h
411
int (*okfn)(struct net *, struct sock *, struct sk_buff *),
include/linux/netfilter.h
414
return okfn(net, sk, skb);
include/linux/netfilter.h
418
NF_HOOK(uint8_t pf, unsigned int hook, struct net *net, struct sock *sk,
include/linux/netfilter.h
420
int (*okfn)(struct net *, struct sock *, struct sk_buff *))
include/linux/netfilter.h
422
return okfn(net, sk, skb);
include/linux/netfilter.h
426
NF_HOOK_LIST(uint8_t pf, unsigned int hook, struct net *net, struct sock *sk,
include/linux/netfilter.h
428
int (*okfn)(struct net *, struct sock *, struct sk_buff *))
include/linux/netfilter.h
433
static inline int nf_hook(u_int8_t pf, unsigned int hook, struct net *net,
include/linux/netfilter.h
436
int (*okfn)(struct net *, struct sock *, struct sk_buff *))
include/linux/netfilter.h
470
int (*update)(struct net *net, struct sk_buff *skb);
include/linux/netfilter.h
498
int (*enable)(struct net *net);
include/linux/netfilter.h
499
void (*disable)(struct net *net);
include/linux/netfilter.h
84
struct net *net;
include/linux/netfilter.h
85
int (*okfn)(struct net *, struct sock *, struct sk_buff *);
include/linux/netfilter/ipset/ip_set.h
230
int (*create)(struct net *net, struct ip_set *set,
include/linux/netfilter/ipset/ip_set.h
311
extern ip_set_id_t ip_set_get_byname(struct net *net,
include/linux/netfilter/ipset/ip_set.h
313
extern void ip_set_put_byindex(struct net *net, ip_set_id_t index);
include/linux/netfilter/ipset/ip_set.h
314
extern void ip_set_name_byindex(struct net *net, ip_set_id_t index, char *name);
include/linux/netfilter/ipset/ip_set.h
315
extern ip_set_id_t ip_set_nfnl_get_byindex(struct net *net, ip_set_id_t index);
include/linux/netfilter/ipset/ip_set.h
316
extern void ip_set_nfnl_put(struct net *net, ip_set_id_t index);
include/linux/netfilter/nf_conntrack_proto_gre.h
30
struct net *net, struct nf_conntrack_tuple *tuple);
include/linux/netfilter/nfnetlink.h
11
struct net *net;
include/linux/netfilter/nfnetlink.h
45
int (*commit)(struct net *net, struct sk_buff *skb);
include/linux/netfilter/nfnetlink.h
46
int (*abort)(struct net *net, struct sk_buff *skb,
include/linux/netfilter/nfnetlink.h
48
bool (*valid_genid)(struct net *net, u32 genid);
include/linux/netfilter/nfnetlink.h
54
int nfnetlink_has_listeners(struct net *net, unsigned int group);
include/linux/netfilter/nfnetlink.h
55
int nfnetlink_send(struct sk_buff *skb, struct net *net, u32 portid,
include/linux/netfilter/nfnetlink.h
57
int nfnetlink_set_err(struct net *net, u32 portid, u32 group, int error);
include/linux/netfilter/nfnetlink.h
58
int nfnetlink_unicast(struct sk_buff *skb, struct net *net, u32 portid);
include/linux/netfilter/nfnetlink.h
59
void nfnetlink_broadcast(struct net *net, struct sk_buff *skb, __u32 portid,
include/linux/netfilter/nfnetlink_acct.h
16
struct nf_acct *nfnl_acct_find_get(struct net *net, const char *filter_name);
include/linux/netfilter/nfnetlink_acct.h
19
int nfnl_acct_overquota(struct net *net, struct nf_acct *nfacct);
include/linux/netfilter/nfnetlink_osf.h
31
const struct nf_osf_info *info, struct net *net,
include/linux/netfilter/x_tables.h
105
struct net *net;
include/linux/netfilter/x_tables.h
127
struct net *net;
include/linux/netfilter/x_tables.h
139
struct net *net;
include/linux/netfilter/x_tables.h
319
struct xt_table *xt_register_table(struct net *net,
include/linux/netfilter/x_tables.h
324
void xt_unregister_table_pre_exit(struct net *net, u8 af, const char *name);
include/linux/netfilter/x_tables.h
325
struct xt_table *xt_unregister_table_exit(struct net *net, u8 af, const char *name);
include/linux/netfilter/x_tables.h
338
struct xt_table *xt_find_table(struct net *net, u8 af, const char *name);
include/linux/netfilter/x_tables.h
339
struct xt_table *xt_find_table_lock(struct net *net, u_int8_t af,
include/linux/netfilter/x_tables.h
341
struct xt_table *xt_request_find_table_lock(struct net *net, u_int8_t af,
include/linux/netfilter/x_tables.h
345
int xt_proto_init(struct net *net, u_int8_t af);
include/linux/netfilter/x_tables.h
346
void xt_proto_fini(struct net *net, u_int8_t af);
include/linux/netfilter/x_tables.h
44
static inline struct net *xt_net(const struct xt_action_param *par)
include/linux/netfilter/x_tables.h
46
return par->state->net;
include/linux/netfilter/x_tables.h
465
int xt_register_template(const struct xt_table *t, int(*table_init)(struct net *net));
include/linux/netfilter/x_tables.h
85
struct net *net;
include/linux/netfilter_arp/arp_tables.h
52
int arpt_register_table(struct net *net, const struct xt_table *table,
include/linux/netfilter_arp/arp_tables.h
55
void arpt_unregister_table(struct net *net, const char *name);
include/linux/netfilter_bridge.h
17
int br_handle_frame_finish(struct net *net, struct sock *sk, struct sk_buff *skb);
include/linux/netfilter_bridge.h
59
nf_bridge_get_physindev(const struct sk_buff *skb, struct net *net)
include/linux/netfilter_bridge.h
63
return nf_bridge ? dev_get_by_index_rcu(net, nf_bridge->physinif) : NULL;
include/linux/netfilter_bridge/ebtables.h
106
extern int ebt_register_table(struct net *net,
include/linux/netfilter_bridge/ebtables.h
109
extern void ebt_unregister_table(struct net *net, const char *tablename);
include/linux/netfilter_bridge/ebtables.h
110
void ebt_unregister_table_pre_exit(struct net *net, const char *tablename);
include/linux/netfilter_bridge/ebtables.h
125
int ebt_register_template(const struct ebt_table *t, int(*table_init)(struct net *net));
include/linux/netfilter_ipv4.h
19
int ip_route_me_harder(struct net *net, struct sock *sk, struct sk_buff *skb, unsigned addr_type);
include/linux/netfilter_ipv4.h
26
int nf_ip_route(struct net *net, struct dst_entry **dst, struct flowi *fl,
include/linux/netfilter_ipv4.h
34
static inline int nf_ip_route(struct net *net, struct dst_entry **dst,
include/linux/netfilter_ipv4/ip_tables.h
25
int ipt_register_table(struct net *net, const struct xt_table *table,
include/linux/netfilter_ipv4/ip_tables.h
29
void ipt_unregister_table_exit(struct net *net, const char *name);
include/linux/netfilter_ipv6.h
40
static inline int nf_ipv6_chk_addr(struct net *net, const struct in6_addr *addr,
include/linux/netfilter_ipv6.h
44
return ipv6_chk_addr(net, addr, dev, strict);
include/linux/netfilter_ipv6.h
50
int __nf_ip6_route(struct net *net, struct dst_entry **dst,
include/linux/netfilter_ipv6.h
53
static inline int nf_ip6_route(struct net *net, struct dst_entry **dst,
include/linux/netfilter_ipv6.h
57
return __nf_ip6_route(net, dst, fl, strict);
include/linux/netfilter_ipv6.h
65
int br_ip6_fragment(struct net *net, struct sock *sk, struct sk_buff *skb,
include/linux/netfilter_ipv6.h
67
int (*output)(struct net *, struct sock *sk,
include/linux/netfilter_ipv6.h
71
static inline int nf_br_ip6_fragment(struct net *net, struct sock *sk,
include/linux/netfilter_ipv6.h
74
int (*output)(struct net *, struct sock *sk,
include/linux/netfilter_ipv6.h
79
return br_ip6_fragment(net, sk, skb, data, output);
include/linux/netfilter_ipv6.h
85
int ip6_route_me_harder(struct net *net, struct sock *sk, struct sk_buff *skb);
include/linux/netfilter_ipv6.h
87
static inline int nf_ip6_route_me_harder(struct net *net, struct sock *sk, struct sk_buff *skb)
include/linux/netfilter_ipv6.h
90
return ip6_route_me_harder(net, sk, skb);
include/linux/netfilter_ipv6/ip6_tables.h
27
int ip6t_register_table(struct net *net, const struct xt_table *table,
include/linux/netfilter_ipv6/ip6_tables.h
30
void ip6t_unregister_table_exit(struct net *net, const char *name);
include/linux/netlink.h
12
struct net;
include/linux/netlink.h
312
struct net *net;
include/linux/netlink.h
51
int (*bind)(struct net *net, int group);
include/linux/netlink.h
52
void (*unbind)(struct net *net, int group);
include/linux/netlink.h
56
struct sock *__netlink_kernel_create(struct net *net, int unit,
include/linux/netlink.h
60
netlink_kernel_create(struct net *net, int unit, struct netlink_kernel_cfg *cfg)
include/linux/netlink.h
62
return __netlink_kernel_create(net, unit, THIS_MODULE, cfg);
include/linux/nfs_fs_sb.h
125
struct net *cl_net;
include/linux/nfslocalio.h
101
net = nfs_to->nfsd_file_put_local(localio);
include/linux/nfslocalio.h
103
if (net)
include/linux/nfslocalio.h
104
nfs_to_nfsd_net_put(net);
include/linux/nfslocalio.h
35
struct net __rcu *net; /* nfsd's network namespace */
include/linux/nfslocalio.h
45
struct net *, struct auth_domain *, struct module *);
include/linux/nfslocalio.h
56
bool (*nfsd_net_try_get)(struct net *);
include/linux/nfslocalio.h
57
void (*nfsd_net_put)(struct net *);
include/linux/nfslocalio.h
58
struct nfsd_file *(*nfsd_open_local_fh)(struct net *,
include/linux/nfslocalio.h
65
struct net *(*nfsd_file_put_local)(struct nfsd_file __rcu **);
include/linux/nfslocalio.h
80
static inline void nfs_to_nfsd_net_put(struct net *net)
include/linux/nfslocalio.h
88
nfs_to->nfsd_net_put(net);
include/linux/nfslocalio.h
99
struct net *net;
include/linux/ns/ns_common_types.h
133
struct net *: &(__ns)->ns, \
include/linux/ns/ns_common_types.h
134
const struct net *: &(__ns)->ns, \
include/linux/ns/ns_common_types.h
149
struct net *: NET_NS_INIT_INO, \
include/linux/ns/ns_common_types.h
16
struct net;
include/linux/ns/ns_common_types.h
160
struct net *: &init_net, \
include/linux/ns/ns_common_types.h
171
struct net *: NET_NS_INIT_ID, \
include/linux/ns/ns_common_types.h
182
struct net *: (IS_ENABLED(CONFIG_NET_NS) ? &netns_operations : NULL), \
include/linux/ns/ns_common_types.h
202
X(net, CLONE_NEWNET) \
include/linux/ns/ns_common_types.h
26
extern struct net init_net;
include/linux/nsfs.h
31
struct net *: current->nsproxy->net_ns, \
include/linux/nsproxy.h
38
struct net *net_ns;
include/linux/nstree.h
37
struct net *: &(net_ns_tree), \
include/linux/ppp_channel.h
61
extern int ppp_register_net_channel(struct net *, struct ppp_channel *);
include/linux/proc_fs.h
232
struct net;
include/linux/proc_fs.h
235
struct net *net, const char *name, struct proc_dir_entry *parent)
include/linux/proc_fs.h
237
return _proc_mkdir(name, 0, parent, net, true);
include/linux/rio.h
178
struct rio_net *net; /* RIO net this device resides in */
include/linux/rio.h
270
struct rio_net *net; /* RIO net this mport is attached to */
include/linux/rio.h
329
void (*release)(struct rio_net *net);
include/linux/rio_drv.h
148
return rio_mport_read_config_32(rdev->net->hport, rdev->destid,
include/linux/rio_drv.h
164
return rio_mport_write_config_32(rdev->net->hport, rdev->destid,
include/linux/rio_drv.h
180
return rio_mport_read_config_16(rdev->net->hport, rdev->destid,
include/linux/rio_drv.h
196
return rio_mport_write_config_16(rdev->net->hport, rdev->destid,
include/linux/rio_drv.h
211
return rio_mport_read_config_8(rdev->net->hport, rdev->destid,
include/linux/rio_drv.h
226
return rio_mport_write_config_8(rdev->net->hport, rdev->destid,
include/linux/rio_drv.h
243
return rio_mport_send_doorbell(rdev->net->hport, rdev->destid, data);
include/linux/rtnetlink.h
101
void __rtnl_net_lock(struct net *net);
include/linux/rtnetlink.h
102
void __rtnl_net_unlock(struct net *net);
include/linux/rtnetlink.h
103
void rtnl_net_lock(struct net *net);
include/linux/rtnetlink.h
104
void rtnl_net_unlock(struct net *net);
include/linux/rtnetlink.h
105
int rtnl_net_trylock(struct net *net);
include/linux/rtnetlink.h
106
int rtnl_net_lock_killable(struct net *net);
include/linux/rtnetlink.h
109
bool rtnl_net_is_locked(struct net *net);
include/linux/rtnetlink.h
111
#define ASSERT_RTNL_NET(net) \
include/linux/rtnetlink.h
112
WARN_ONCE(!rtnl_net_is_locked(net), \
include/linux/rtnetlink.h
116
bool lockdep_rtnl_net_is_held(struct net *net);
include/linux/rtnetlink.h
118
#define rcu_dereference_rtnl_net(net, p) \
include/linux/rtnetlink.h
119
rcu_dereference_check(p, lockdep_rtnl_net_is_held(net))
include/linux/rtnetlink.h
12
extern int rtnetlink_send(struct sk_buff *skb, struct net *net, u32 pid, u32 group, int echo);
include/linux/rtnetlink.h
120
#define rtnl_net_dereference(net, p) \
include/linux/rtnetlink.h
121
rcu_dereference_protected(p, lockdep_rtnl_net_is_held(net))
include/linux/rtnetlink.h
122
#define rcu_replace_pointer_rtnl_net(net, rp, p) \
include/linux/rtnetlink.h
123
rcu_replace_pointer(rp, p, lockdep_rtnl_net_is_held(net))
include/linux/rtnetlink.h
125
static inline void __rtnl_net_lock(struct net *net) {}
include/linux/rtnetlink.h
126
static inline void __rtnl_net_unlock(struct net *net) {}
include/linux/rtnetlink.h
128
static inline void rtnl_net_lock(struct net *net)
include/linux/rtnetlink.h
133
static inline void rtnl_net_unlock(struct net *net)
include/linux/rtnetlink.h
138
static inline int rtnl_net_trylock(struct net *net)
include/linux/rtnetlink.h
14
static inline int rtnetlink_maybe_send(struct sk_buff *skb, struct net *net,
include/linux/rtnetlink.h
143
static inline int rtnl_net_lock_killable(struct net *net)
include/linux/rtnetlink.h
148
static inline void ASSERT_RTNL_NET(struct net *net)
include/linux/rtnetlink.h
153
#define rcu_dereference_rtnl_net(net, p) \
include/linux/rtnetlink.h
155
#define rtnl_net_dereference(net, p) \
include/linux/rtnetlink.h
157
#define rcu_replace_pointer_rtnl_net(net, rp, p) \
include/linux/rtnetlink.h
17
return !skb ? 0 : rtnetlink_send(skb, net, pid, group, echo);
include/linux/rtnetlink.h
20
extern int rtnl_unicast(struct sk_buff *skb, struct net *net, u32 pid);
include/linux/rtnetlink.h
21
extern void rtnl_notify(struct sk_buff *skb, struct net *net, u32 pid,
include/linux/rtnetlink.h
221
static inline int rtnl_has_listeners(const struct net *net, u32 group)
include/linux/rtnetlink.h
223
struct sock *rtnl = net->rtnl;
include/linux/rtnetlink.h
23
extern void rtnl_set_sk_err(struct net *net, u32 group, int error);
include/linux/rtnetlink.h
238
rtnl_notify_needed(const struct net *net, u16 nlflags, u32 group)
include/linux/rtnetlink.h
240
return (nlflags & NLM_F_ECHO) || rtnl_has_listeners(net, group);
include/linux/seq_file_net.h
13
struct net *net;
include/linux/seq_file_net.h
18
static inline struct net *seq_file_net(struct seq_file *seq)
include/linux/seq_file_net.h
21
return ((struct seq_net_private *)seq->private)->net;
include/linux/seq_file_net.h
31
static inline struct net *seq_file_single_net(struct seq_file *seq)
include/linux/seq_file_net.h
34
return (struct net *)seq->private;
include/linux/seq_file_net.h
8
struct net;
include/linux/seq_file_net.h
9
extern struct net init_net;
include/linux/skbuff.h
1572
u32 __skb_get_hash_symmetric_net(const struct net *net, const struct sk_buff *skb);
include/linux/skbuff.h
1579
void __skb_get_hash_net(const struct net *net, struct sk_buff *skb);
include/linux/skbuff.h
1594
bool __skb_flow_dissect(const struct net *net,
include/linux/skbuff.h
1618
skb_flow_dissect_flow_keys_basic(const struct net *net,
include/linux/skbuff.h
1625
return __skb_flow_dissect(net, skb, &flow_keys_basic_dissector, flow,
include/linux/skbuff.h
1652
static inline __u32 skb_get_hash_net(const struct net *net, struct sk_buff *skb)
include/linux/skbuff.h
1655
__skb_get_hash_net(net, skb);
include/linux/smbdirect.h
62
int smbdirect_socket_create_kern(struct net *net, struct smbdirect_socket **_sc);
include/linux/sock_diag.h
90
const struct net *n = sock_net(sk);
include/linux/sunrpc/addr.h
17
size_t rpc_pton(struct net *, const char *, const size_t,
include/linux/sunrpc/addr.h
20
size_t rpc_uaddr2sockaddr(struct net *, const char *, const size_t,
include/linux/sunrpc/cache.h
133
struct net *net;
include/linux/sunrpc/cache.h
241
extern int cache_register_net(struct cache_detail *cd, struct net *net);
include/linux/sunrpc/cache.h
242
extern void cache_unregister_net(struct cache_detail *cd, struct net *net);
include/linux/sunrpc/cache.h
244
extern struct cache_detail *cache_create_net(const struct cache_detail *tmpl, struct net *net);
include/linux/sunrpc/cache.h
245
extern void cache_destroy_net(struct cache_detail *cd, struct net *net);
include/linux/sunrpc/clnt.h
136
struct net *net;
include/linux/sunrpc/clnt.h
200
int rpcb_create_local(struct net *);
include/linux/sunrpc/clnt.h
201
void rpcb_put_local(struct net *);
include/linux/sunrpc/clnt.h
202
int rpcb_register(struct net *, u32, u32, int, unsigned short);
include/linux/sunrpc/clnt.h
203
int rpcb_v4_register(struct net *net, const u32 program,
include/linux/sunrpc/clnt.h
224
struct net * rpc_net_ns(struct rpc_clnt *);
include/linux/sunrpc/clnt.h
35
struct net *net;
include/linux/sunrpc/rpc_pipe_fs.h
108
extern int rpc_add_pipe_dir_object(struct net *net,
include/linux/sunrpc/rpc_pipe_fs.h
111
extern void rpc_remove_pipe_dir_object(struct net *net,
include/linux/sunrpc/rpc_pipe_fs.h
115
struct net *net,
include/linux/sunrpc/rpc_pipe_fs.h
136
extern bool gssd_running(struct net *net);
include/linux/sunrpc/rpc_pipe_fs.h
86
extern int rpc_pipefs_init_net(struct net *net);
include/linux/sunrpc/rpc_pipe_fs.h
87
extern void rpc_pipefs_exit_net(struct net *net);
include/linux/sunrpc/rpc_pipe_fs.h
88
extern struct super_block *rpc_get_sb_net(const struct net *net);
include/linux/sunrpc/rpc_pipe_fs.h
89
extern void rpc_put_sb_net(const struct net *net);
include/linux/sunrpc/sched.h
273
struct net;
include/linux/sunrpc/sched.h
274
void rpc_show_tasks(struct net *);
include/linux/sunrpc/stats.h
42
struct net;
include/linux/sunrpc/stats.h
44
int rpc_proc_init(struct net *);
include/linux/sunrpc/stats.h
45
void rpc_proc_exit(struct net *);
include/linux/sunrpc/stats.h
46
struct proc_dir_entry * rpc_proc_register(struct net *,struct rpc_stat *);
include/linux/sunrpc/stats.h
47
void rpc_proc_unregister(struct net *,const char *);
include/linux/sunrpc/stats.h
49
struct proc_dir_entry * svc_proc_register(struct net *, struct svc_stat *,
include/linux/sunrpc/stats.h
51
void svc_proc_unregister(struct net *, const char *);
include/linux/sunrpc/stats.h
56
static inline int rpc_proc_init(struct net *net)
include/linux/sunrpc/stats.h
61
static inline void rpc_proc_exit(struct net *net)
include/linux/sunrpc/stats.h
64
static inline struct proc_dir_entry *rpc_proc_register(struct net *net, struct rpc_stat *s) { return NULL; }
include/linux/sunrpc/stats.h
65
static inline void rpc_proc_unregister(struct net *net, const char *p) {}
include/linux/sunrpc/stats.h
68
static inline struct proc_dir_entry *svc_proc_register(struct net *net, struct svc_stat *s,
include/linux/sunrpc/stats.h
70
static inline void svc_proc_unregister(struct net *net, const char *p) {}
include/linux/sunrpc/svc.h
258
struct net *rq_bc_net; /* pointer to backchannel's
include/linux/sunrpc/svc.h
397
int (*pg_rpcbind_set)(struct net *net,
include/linux/sunrpc/svc.h
454
void svc_rpcb_cleanup(struct svc_serv *serv, struct net *net);
include/linux/sunrpc/svc.h
455
int svc_bind(struct svc_serv *serv, struct net *net);
include/linux/sunrpc/svc.h
475
int svc_register(const struct svc_serv *, struct net *, const int,
include/linux/sunrpc/svc.h
493
int svc_generic_rpcbind_set(struct net *net,
include/linux/sunrpc/svc_xprt.h
162
void svc_xprt_init(struct net *, struct svc_xprt_class *, struct svc_xprt *,
include/linux/sunrpc/svc_xprt.h
165
struct net *net, struct sockaddr *sap,
include/linux/sunrpc/svc_xprt.h
168
struct net *net, const int family,
include/linux/sunrpc/svc_xprt.h
17
struct net *net,
include/linux/sunrpc/svc_xprt.h
171
void svc_xprt_destroy_all(struct svc_serv *serv, struct net *net,
include/linux/sunrpc/svc_xprt.h
181
struct net *net, const struct sockaddr *sa);
include/linux/sunrpc/svc_xprt.h
183
struct net *net, const sa_family_t af,
include/linux/sunrpc/svc_xprt.h
77
struct net *xpt_net;
include/linux/sunrpc/svcauth.h
168
extern void svcauth_unix_purge(struct net *net);
include/linux/sunrpc/svcauth.h
172
extern int unix_gid_cache_create(struct net *net);
include/linux/sunrpc/svcauth.h
173
extern void unix_gid_cache_destroy(struct net *net);
include/linux/sunrpc/svcauth_gss.h
21
int gss_svc_init_net(struct net *net);
include/linux/sunrpc/svcauth_gss.h
22
void gss_svc_shutdown_net(struct net *net);
include/linux/sunrpc/svcsock.h
66
int svc_addsock(struct svc_serv *serv, struct net *net,
include/linux/sunrpc/xprt.h
313
struct net *xprt_net;
include/linux/sunrpc/xprt.h
351
struct net * net;
include/linux/sunrpc/xprt.h
402
struct rpc_xprt * xprt_alloc(struct net *net, size_t size,
include/linux/sunrpc/xprt.h
50
struct net;
include/linux/sunrpc/xprtmultipath.h
25
struct net * xps_net;
include/linux/udp.h
233
static inline struct sock *udp_tunnel_sk(const struct net *net, bool is_ipv6)
include/linux/udp.h
236
return rcu_dereference(net->ipv4.udp_tunnel_gro[is_ipv6].sk);
include/linux/udp.h
30
static inline u32 udp_hashfn(const struct net *net, u32 num, u32 mask)
include/linux/udp.h
32
return (num + net_hash_mix(net)) & mask;
include/linux/usb/cdc_ncm.h
157
int cdc_ncm_change_mtu(struct net_device *net, int new_mtu);
include/linux/usb/usbnet.h
266
extern int usbnet_open(struct net_device *net);
include/linux/usb/usbnet.h
267
extern int usbnet_stop(struct net_device *net);
include/linux/usb/usbnet.h
269
struct net_device *net);
include/linux/usb/usbnet.h
270
extern void usbnet_tx_timeout(struct net_device *net, unsigned int txqueue);
include/linux/usb/usbnet.h
271
extern int usbnet_change_mtu(struct net_device *net, int new_mtu);
include/linux/usb/usbnet.h
283
extern int usbnet_get_link_ksettings_mii(struct net_device *net,
include/linux/usb/usbnet.h
285
extern int usbnet_set_link_ksettings_mii(struct net_device *net,
include/linux/usb/usbnet.h
287
extern int usbnet_get_link_ksettings_internal(struct net_device *net,
include/linux/usb/usbnet.h
289
extern u32 usbnet_get_link(struct net_device *net);
include/linux/usb/usbnet.h
292
extern void usbnet_set_rx_mode(struct net_device *net);
include/linux/usb/usbnet.h
294
extern int usbnet_mii_ioctl(struct net_device *net, struct ifreq *rq, int cmd);
include/linux/usb/usbnet.h
295
extern int usbnet_nway_reset(struct net_device *net);
include/linux/usb/usbnet.h
42
struct net_device *net;
include/linux/vdpa.h
118
} net;
include/linux/virtio_vsock.h
176
struct net *net;
include/linux/virtio_vsock.h
189
int (*send_pkt)(struct sk_buff *skb, struct net *net);
include/linux/virtio_vsock.h
284
struct sk_buff *skb, struct net *net);
include/media/videobuf2-dvb.h
36
struct dvb_net net;
include/net/act_api.h
126
int (*lookup)(struct net *net, struct tc_action **a, u32 index);
include/net/act_api.h
127
int (*init)(struct net *net, struct nlattr *nla,
include/net/act_api.h
131
int (*walk)(struct net *, struct sk_buff *,
include/net/act_api.h
159
int tc_action_net_init(struct net *net, struct tc_action_net *tn,
include/net/act_api.h
168
tn->idrinfo->net = net;
include/net/act_api.h
180
struct net *net;
include/net/act_api.h
182
list_for_each_entry(net, net_list, exit_list) {
include/net/act_api.h
183
struct tc_action_net *tn = net_generic(net, id);
include/net/act_api.h
19
struct net *net;
include/net/act_api.h
216
int tcf_action_init(struct net *net, struct tcf_proto *tp, struct nlattr *nla,
include/net/act_api.h
222
struct tc_action *tcf_action_init_1(struct net *net, struct tcf_proto *tp,
include/net/addrconf.h
112
int addrconf_add_ifaddr(struct net *net, void __user *arg);
include/net/addrconf.h
113
int addrconf_del_ifaddr(struct net *net, void __user *arg);
include/net/addrconf.h
114
int addrconf_set_dstaddr(struct net *net, void __user *arg);
include/net/addrconf.h
116
int ipv6_chk_addr(struct net *net, const struct in6_addr *addr,
include/net/addrconf.h
118
int ipv6_chk_addr_and_flags(struct net *net, const struct in6_addr *addr,
include/net/addrconf.h
123
int ipv6_chk_home_addr(struct net *net, const struct in6_addr *addr);
include/net/addrconf.h
126
int ipv6_chk_rpl_srh_loop(struct net *net, const struct in6_addr *segs,
include/net/addrconf.h
135
struct net_device *ipv6_dev_find(struct net *net, const struct in6_addr *addr,
include/net/addrconf.h
138
struct inet6_ifaddr *ipv6_get_ifaddr(struct net *net,
include/net/addrconf.h
142
int ipv6_dev_get_saddr(struct net *net, const struct net_device *dev,
include/net/addrconf.h
156
int addrconf_prefix_rcv_add_addr(struct net *net, struct net_device *dev,
include/net/addrconf.h
238
u32 ipv6_addr_label(struct net *net, const struct in6_addr *addr,
include/net/addrconf.h
320
bool ipv6_chk_acast_addr(struct net *net, struct net_device *dev,
include/net/addrconf.h
322
bool ipv6_chk_acast_addr_src(struct net *net, struct net_device *dev,
include/net/addrconf.h
336
void inet6_netconf_notify_devconf(struct net *net, int event, int type,
include/net/af_vsock.h
231
struct net *net);
include/net/af_vsock.h
234
struct net *net);
include/net/af_vsock.h
276
static inline enum vsock_net_mode vsock_net_mode(struct net *net)
include/net/af_vsock.h
278
if (!net)
include/net/af_vsock.h
281
return READ_ONCE(net->vsock.mode);
include/net/af_vsock.h
289
static inline bool vsock_net_set_child_mode(struct net *net,
include/net/af_vsock.h
295
if (try_cmpxchg(&net->vsock.child_ns_mode_locked,
include/net/af_vsock.h
297
WRITE_ONCE(net->vsock.child_ns_mode, mode);
include/net/af_vsock.h
304
static inline enum vsock_net_mode vsock_net_child_mode(struct net *net)
include/net/af_vsock.h
306
return READ_ONCE(net->vsock.child_ns_mode);
include/net/af_vsock.h
315
static inline bool vsock_net_check_mode(struct net *ns0, struct net *ns1)
include/net/amt.h
316
struct net *net;
include/net/arp.h
61
int arp_ioctl(struct net *net, unsigned int cmd, void __user *arg);
include/net/bluetooth/bluetooth.h
425
struct sock *bt_sock_alloc(struct net *net, struct socket *sock,
include/net/bluetooth/bluetooth.h
631
int bt_procfs_init(struct net *net, const char *name,
include/net/bluetooth/bluetooth.h
634
void bt_procfs_cleanup(struct net *net, const char *name);
include/net/bonding.h
670
struct net *net; /* Associated network namespace */
include/net/bonding.h
680
int bond_create(struct net *net, const char *name);
include/net/bonding.h
681
int bond_create_sysfs(struct bond_net *net);
include/net/bonding.h
682
void bond_destroy_sysfs(struct bond_net *net);
include/net/cfg80211.h
6679
static inline struct net *wiphy_net(struct wiphy *wiphy)
include/net/cfg80211.h
6684
static inline void wiphy_net_set(struct wiphy *wiphy, struct net *net)
include/net/cfg80211.h
6686
write_pnet(&wiphy->_net, net);
include/net/cfg802154.h
255
static inline struct net *wpan_phy_net(struct wpan_phy *wpan_phy)
include/net/cfg802154.h
260
static inline void wpan_phy_net_set(struct wpan_phy *wpan_phy, struct net *net)
include/net/cfg802154.h
262
write_pnet(&wpan_phy->_net, net);
include/net/devlink.h
1637
struct net *devlink_net(const struct devlink *devlink);
include/net/devlink.h
1644
size_t priv_size, struct net *net,
include/net/dst.h
348
struct net *net)
include/net/dst.h
359
skb_scrub_packet(skb, !net_eq(net, dev_net(dev)));
include/net/dst.h
373
struct net *net)
include/net/dst.h
377
__skb_tunnel_rx(skb, dev, net);
include/net/dst.h
392
int dst_discard_out(struct net *net, struct sock *sk, struct sk_buff *skb);
include/net/dst.h
40
int (*output)(struct net *net, struct sock *sk, struct sk_buff *skb);
include/net/dst.h
463
INDIRECT_CALLABLE_DECLARE(int ip6_output(struct net *, struct sock *,
include/net/dst.h
465
INDIRECT_CALLABLE_DECLARE(int ip_output(struct net *, struct sock *,
include/net/dst.h
468
static inline int dst_output(struct net *net, struct sock *sk, struct sk_buff *skb)
include/net/dst.h
472
net, sk, skb);
include/net/dst.h
505
static inline struct dst_entry *xfrm_lookup(struct net *net,
include/net/dst.h
515
xfrm_lookup_with_ifid(struct net *net, struct dst_entry *dst_orig,
include/net/dst.h
522
static inline struct dst_entry *xfrm_lookup_route(struct net *net,
include/net/dst.h
537
struct dst_entry *xfrm_lookup(struct net *net, struct dst_entry *dst_orig,
include/net/dst.h
541
struct dst_entry *xfrm_lookup_with_ifid(struct net *net,
include/net/dst.h
547
struct dst_entry *xfrm_lookup_route(struct net *net, struct dst_entry *dst_orig,
include/net/dst.h
585
static inline struct net *dst_dev_net_rcu(const struct dst_entry *dst)
include/net/dst.h
600
static inline struct net *skb_dst_dev_net(const struct sk_buff *skb)
include/net/dst.h
605
static inline struct net *skb_dst_dev_net_rcu(const struct sk_buff *skb)
include/net/dst_ops.h
13
struct net;
include/net/dst_ops.h
34
int (*local_out)(struct net *net, struct sock *sk, struct sk_buff *skb);
include/net/fib_notifier.h
31
unsigned int (*fib_seq_read)(const struct net *net);
include/net/fib_notifier.h
32
int (*fib_dump)(struct net *net, struct notifier_block *nb,
include/net/fib_notifier.h
41
int call_fib_notifiers(struct net *net, enum fib_event_type event_type,
include/net/fib_notifier.h
43
int register_fib_notifier(struct net *net, struct notifier_block *nb,
include/net/fib_notifier.h
46
int unregister_fib_notifier(struct net *net, struct notifier_block *nb);
include/net/fib_notifier.h
48
fib_notifier_ops_register(const struct fib_notifier_ops *tmpl, struct net *net);
include/net/fib_rules.h
100
struct net *fro_net;
include/net/fib_rules.h
196
struct net *);
include/net/fib_rules.h
203
int fib_rules_dump(struct net *net, struct notifier_block *nb, int family,
include/net/fib_rules.h
205
unsigned int fib_rules_seq_read(const struct net *net, int family);
include/net/fib_rules.h
207
int fib_newrule(struct net *net, struct sk_buff *skb, struct nlmsghdr *nlh,
include/net/fib_rules.h
209
int fib_delrule(struct net *net, struct sk_buff *skb, struct nlmsghdr *nlh,
include/net/fib_rules.h
35
struct net *fr_net;
include/net/flow_dissector.h
13
struct net;
include/net/flow_dissector.h
484
int flow_dissector_bpf_prog_attach_check(struct net *net,
include/net/flow_offload.h
595
struct net *net;
include/net/genetlink.h
146
static inline struct net *genl_info_net(const struct genl_info *info)
include/net/genetlink.h
151
static inline void genl_info_net_set(struct genl_info *info, struct net *net)
include/net/genetlink.h
153
write_pnet(&info->_net, net);
include/net/genetlink.h
487
struct net *net, struct sk_buff *skb,
include/net/genetlink.h
497
return nlmsg_multicast_filtered(net->genl_sock, skb, portid, group,
include/net/genetlink.h
511
struct net *net, struct sk_buff *skb,
include/net/genetlink.h
514
return genlmsg_multicast_netns_filtered(family, net, skb, portid,
include/net/genetlink.h
553
static inline int genlmsg_unicast(struct net *net, struct sk_buff *skb, u32 portid)
include/net/genetlink.h
555
return nlmsg_unicast(net->genl_sock, skb, portid);
include/net/genetlink.h
629
struct net *net, u32 portid,
include/net/genetlink.h
635
return netlink_set_err(net->genl_sock, portid, group, code);
include/net/genetlink.h
639
struct net *net, unsigned int group)
include/net/genetlink.h
644
return netlink_has_listeners(net->genl_sock, group);
include/net/geneve.h
72
struct net_device *geneve_dev_create_fb(struct net *net, const char *name,
include/net/gre.h
35
struct net_device *gretap_fb_dev_create(struct net *net, const char *name,
include/net/icmp.h
29
#define ICMP_INC_STATS(net, field) SNMP_INC_STATS((net)->mib.icmp_statistics, field)
include/net/icmp.h
30
#define __ICMP_INC_STATS(net, field) __SNMP_INC_STATS((net)->mib.icmp_statistics, field)
include/net/icmp.h
31
#define ICMPMSGOUT_INC_STATS(net, field) SNMP_INC_STATS_ATOMIC_LONG((net)->mib.icmpmsg_statistics, field+256)
include/net/icmp.h
32
#define ICMPMSGIN_INC_STATS(net, field) SNMP_INC_STATS_ATOMIC_LONG((net)->mib.icmpmsg_statistics, field)
include/net/icmp.h
37
struct net;
include/net/icmp.h
61
void icmp_out_count(struct net *net, unsigned char type);
include/net/inet6_hashtables.h
101
return inet6_lookup_listener(net, skb, doff, saddr, sport,
include/net/inet6_hashtables.h
106
struct sock *inet6_steal_sock(struct net *net, struct sk_buff *skb, int doff,
include/net/inet6_hashtables.h
131
reuse_sk = inet6_lookup_reuseport(net, sk, skb, doff,
include/net/inet6_hashtables.h
151
struct net *net = skb_dst_dev_net_rcu(skb);
include/net/inet6_hashtables.h
155
sk = inet6_steal_sock(net, skb, doff, &ip6h->saddr, sport, &ip6h->daddr, dport,
include/net/inet6_hashtables.h
162
return __inet6_lookup(net, skb, doff, &ip6h->saddr, sport,
include/net/inet6_hashtables.h
167
struct sock *inet6_lookup(const struct net *net, struct sk_buff *skb, int doff,
include/net/inet6_hashtables.h
172
static inline bool inet6_match(const struct net *net, const struct sock *sk,
include/net/inet6_hashtables.h
178
if (!net_eq(sock_net(sk), net) ||
include/net/inet6_hashtables.h
186
return inet_sk_bound_dev_eq(net, READ_ONCE(sk->sk_bound_dev_if), dif,
include/net/inet6_hashtables.h
45
struct sock *__inet6_lookup_established(const struct net *net,
include/net/inet6_hashtables.h
52
typedef u32 (inet6_ehashfn_t)(const struct net *net,
include/net/inet6_hashtables.h
60
struct sock *inet6_lookup_reuseport(const struct net *net, struct sock *sk,
include/net/inet6_hashtables.h
68
struct sock *inet6_lookup_listener(const struct net *net,
include/net/inet6_hashtables.h
76
struct sock *inet6_lookup_run_sk_lookup(const struct net *net,
include/net/inet6_hashtables.h
85
static inline struct sock *__inet6_lookup(const struct net *net,
include/net/inet6_hashtables.h
94
struct sock *sk = __inet6_lookup_established(net, saddr, sport,
include/net/inet_common.h
19
struct net;
include/net/inet_common.h
61
struct net *net);
include/net/inet_frag.h
124
int fqdir_init(struct fqdir **fqdirp, struct inet_frags *f, struct net *net);
include/net/inet_frag.h
20
struct net *net;
include/net/inet_hashtables.h
115
static inline struct net *ib_net(const struct inet_bind_bucket *ib)
include/net/inet_hashtables.h
120
static inline struct net *ib2_net(const struct inet_bind2_bucket *ib)
include/net/inet_hashtables.h
218
inet_bind_bucket_create(struct kmem_cache *cachep, struct net *net,
include/net/inet_hashtables.h
224
const struct net *net, unsigned short port,
include/net/inet_hashtables.h
228
inet_bind2_bucket_create(struct kmem_cache *cachep, struct net *net,
include/net/inet_hashtables.h
238
const struct net *net,
include/net/inet_hashtables.h
243
const struct net *net, unsigned short port,
include/net/inet_hashtables.h
246
static inline u32 inet_bhashfn(const struct net *net, const __u16 lport,
include/net/inet_hashtables.h
249
return (lport + net_hash_mix(net)) & (bhash_size - 1);
include/net/inet_hashtables.h
254
const struct net *net, unsigned short port)
include/net/inet_hashtables.h
260
hash = ipv6_portaddr_hash(net, &sk->sk_v6_rcv_saddr, port);
include/net/inet_hashtables.h
263
hash = ipv4_portaddr_hash(net, sk->sk_rcv_saddr, port);
include/net/inet_hashtables.h
282
inet_bhash2_addr_any_hashbucket(const struct sock *sk, const struct net *net, int port);
include/net/inet_hashtables.h
310
struct sock *__inet_lookup_listener(const struct net *net,
include/net/inet_hashtables.h
317
static inline struct sock *inet_lookup_listener(struct net *net,
include/net/inet_hashtables.h
323
return __inet_lookup_listener(net, skb, doff, saddr, sport,
include/net/inet_hashtables.h
356
static inline bool inet_match(const struct net *net, const struct sock *sk,
include/net/inet_hashtables.h
360
if (!net_eq(sock_net(sk), net) ||
include/net/inet_hashtables.h
366
return inet_sk_bound_dev_eq(net, READ_ONCE(sk->sk_bound_dev_if), dif,
include/net/inet_hashtables.h
373
struct sock *__inet_lookup_established(const struct net *net,
include/net/inet_hashtables.h
378
typedef u32 (inet_ehashfn_t)(const struct net *net,
include/net/inet_hashtables.h
386
struct sock *inet_lookup_reuseport(const struct net *net, struct sock *sk,
include/net/inet_hashtables.h
392
struct sock *inet_lookup_run_sk_lookup(const struct net *net,
include/net/inet_hashtables.h
399
static inline struct sock *inet_lookup_established(struct net *net,
include/net/inet_hashtables.h
404
return __inet_lookup_established(net, saddr, sport, daddr,
include/net/inet_hashtables.h
408
static inline struct sock *__inet_lookup(struct net *net,
include/net/inet_hashtables.h
418
sk = __inet_lookup_established(net, saddr, sport,
include/net/inet_hashtables.h
424
return __inet_lookup_listener(net, skb, doff, saddr,
include/net/inet_hashtables.h
428
static inline struct sock *inet_lookup(struct net *net,
include/net/inet_hashtables.h
437
sk = __inet_lookup(net, skb, doff, saddr, sport, daddr,
include/net/inet_hashtables.h
446
struct sock *inet_steal_sock(struct net *net, struct sk_buff *skb, int doff,
include/net/inet_hashtables.h
471
reuse_sk = inet_lookup_reuseport(net, sk, skb, doff,
include/net/inet_hashtables.h
492
struct net *net = skb_dst_dev_net_rcu(skb);
include/net/inet_hashtables.h
496
sk = inet_steal_sock(net, skb, doff, iph->saddr, sport, iph->daddr, dport,
include/net/inet_hashtables.h
503
return __inet_lookup(net, skb, doff, iph->saddr, sport,
include/net/inet_sock.h
120
struct net *net = sock_net(sk);
include/net/inet_sock.h
122
if (!bound_dev_if && READ_ONCE(net->ipv4.sysctl_tcp_l3mdev_accept))
include/net/inet_sock.h
123
return l3mdev_master_ifindex_by_index(net, skb->skb_iif);
include/net/inet_sock.h
132
struct net *net = sock_net(sk);
include/net/inet_sock.h
134
if (!READ_ONCE(net->ipv4.sysctl_tcp_l3mdev_accept))
include/net/inet_sock.h
135
return l3mdev_master_ifindex_by_index(net,
include/net/inet_sock.h
150
static inline bool inet_sk_bound_dev_eq(const struct net *net,
include/net/inet_sock.h
155
return inet_bound_dev_eq(!!READ_ONCE(net->ipv4.sysctl_tcp_l3mdev_accept),
include/net/inet_sock.h
433
static inline bool inet_can_nonlocal_bind(struct net *net,
include/net/inet_sock.h
436
return READ_ONCE(net->ipv4.sysctl_ip_nonlocal_bind) ||
include/net/inet_sock.h
441
static inline bool inet_addr_valid_or_nonlocal(struct net *net,
include/net/inet_sock.h
446
return inet_can_nonlocal_bind(net, inet) ||
include/net/inet_timewait_sock.h
129
struct net *twsk_net(const struct inet_timewait_sock *twsk)
include/net/inet_timewait_sock.h
135
void twsk_net_set(struct inet_timewait_sock *twsk, struct net *net)
include/net/inet_timewait_sock.h
137
write_pnet(&twsk->tw_net, net);
include/net/ioam6.h
48
static inline struct ioam6_pernet_data *ioam6_pernet(struct net *net)
include/net/ioam6.h
51
return net->ipv6.ioam6_data;
include/net/ioam6.h
57
struct ioam6_namespace *ioam6_namespace(struct net *net, __be16 id);
include/net/ioam6.h
71
void ioam6_event(enum ioam6_event_type type, struct net *net, gfp_t gfp,
include/net/ip.h
169
void ip_protocol_deliver_rcu(struct net *net, struct sk_buff *skb, int proto);
include/net/ip.h
171
int ip_mr_output(struct net *net, struct sock *sk, struct sk_buff *skb);
include/net/ip.h
172
int ip_output(struct net *net, struct sock *sk, struct sk_buff *skb);
include/net/ip.h
173
int ip_mc_output(struct net *net, struct sock *sk, struct sk_buff *skb);
include/net/ip.h
174
int ip_do_fragment(struct net *net, struct sock *sk, struct sk_buff *skb,
include/net/ip.h
175
int (*output)(struct net *, struct sock *, struct sk_buff *));
include/net/ip.h
215
int __ip_local_out(struct net *net, struct sock *sk, struct sk_buff *skb);
include/net/ip.h
216
int ip_local_out(struct net *net, struct sock *sk, struct sk_buff *skb);
include/net/ip.h
233
int ip_send_skb(struct net *net, struct sk_buff *skb);
include/net/ip.h
294
#define IP_INC_STATS(net, field) SNMP_INC_STATS64((net)->mib.ip_statistics, field)
include/net/ip.h
295
#define __IP_INC_STATS(net, field) __SNMP_INC_STATS64((net)->mib.ip_statistics, field)
include/net/ip.h
296
#define IP_ADD_STATS(net, field, val) SNMP_ADD_STATS64((net)->mib.ip_statistics, field, val)
include/net/ip.h
297
#define __IP_ADD_STATS(net, field, val) __SNMP_ADD_STATS64((net)->mib.ip_statistics, field, val)
include/net/ip.h
298
#define IP_UPD_PO_STATS(net, field, val) SNMP_UPD_PO_STATS64((net)->mib.ip_statistics, field, val)
include/net/ip.h
299
#define __IP_UPD_PO_STATS(net, field, val) __SNMP_UPD_PO_STATS64((net)->mib.ip_statistics, field, val)
include/net/ip.h
300
#define NET_INC_STATS(net, field) SNMP_INC_STATS((net)->mib.net_statistics, field)
include/net/ip.h
301
#define __NET_INC_STATS(net, field) __SNMP_INC_STATS((net)->mib.net_statistics, field)
include/net/ip.h
302
#define NET_ADD_STATS(net, field, adnd) SNMP_ADD_STATS((net)->mib.net_statistics, field, adnd)
include/net/ip.h
303
#define __NET_ADD_STATS(net, field, adnd) __SNMP_ADD_STATS((net)->mib.net_statistics, field, adnd)
include/net/ip.h
353
static inline void inet_get_local_port_range(const struct net *net, int *low, int *high)
include/net/ip.h
355
u32 range = READ_ONCE(net->ipv4.ip_local_ports.range);
include/net/ip.h
363
static inline bool inet_is_local_reserved_port(const struct net *net, unsigned short port)
include/net/ip.h
365
if (!net->ipv4.sysctl_local_reserved_ports)
include/net/ip.h
367
return test_bit(port, net->ipv4.sysctl_local_reserved_ports);
include/net/ip.h
375
static inline bool inet_port_requires_bind_service(struct net *net, unsigned short port)
include/net/ip.h
377
return port < READ_ONCE(net->ipv4.sysctl_ip_prot_sock);
include/net/ip.h
381
static inline bool inet_is_local_reserved_port(struct net *net, unsigned short port)
include/net/ip.h
386
static inline bool inet_port_requires_bind_service(struct net *net, unsigned short port)
include/net/ip.h
403
#define IP4_REPLY_MARK(net, mark) \
include/net/ip.h
404
(READ_ONCE((net)->ipv4.sysctl_fwmark_reflect) ? (mark) : 0)
include/net/ip.h
473
struct net *net;
include/net/ip.h
478
net = dev_net_rcu(dev);
include/net/ip.h
479
if (READ_ONCE(net->ipv4.sysctl_ip_fwd_use_pmtu) ||
include/net/ip.h
555
void __ip_select_ident(struct net *net, struct iphdr *iph, int segs);
include/net/ip.h
557
static inline void ip_select_ident_segs(struct net *net, struct sk_buff *skb,
include/net/ip.h
585
__ip_select_ident(net, iph, segs);
include/net/ip.h
589
static inline void ip_select_ident(struct net *net, struct sk_buff *skb,
include/net/ip.h
592
ip_select_ident_segs(net, skb, sk, 1);
include/net/ip.h
705
static inline u32 ipv4_portaddr_hash(const struct net *net,
include/net/ip.h
709
return jhash_1word((__force u32)saddr, net_hash_mix(net)) ^ port;
include/net/ip.h
744
int ip_defrag(struct net *net, struct sk_buff *skb, u32 user);
include/net/ip.h
746
struct sk_buff *ip_check_defrag(struct net *net, struct sk_buff *skb, u32 user);
include/net/ip.h
748
static inline struct sk_buff *ip_check_defrag(struct net *net, struct sk_buff *skb, u32 user)
include/net/ip.h
767
int __ip_options_echo(struct net *net, struct ip_options *dopt,
include/net/ip.h
769
static inline int ip_options_echo(struct net *net, struct ip_options *dopt,
include/net/ip.h
772
return __ip_options_echo(net, dopt, skb, &IPCB(skb)->opt);
include/net/ip.h
776
int __ip_options_compile(struct net *net, struct ip_options *opt,
include/net/ip.h
778
int ip_options_compile(struct net *net, struct ip_options *opt,
include/net/ip.h
780
int ip_options_get(struct net *net, struct ip_options_rcu **optp,
include/net/ip.h
818
bool icmp_global_allow(struct net *net);
include/net/ip.h
819
void icmp_global_consume(struct net *net);
include/net/ip6_fib.h
101
static inline bool fib6_routes_require_src(const struct net *net)
include/net/ip6_fib.h
103
return net->ipv6.fib6_routes_require_src > 0;
include/net/ip6_fib.h
106
static inline void fib6_routes_require_src_inc(struct net *net)
include/net/ip6_fib.h
108
net->ipv6.fib6_routes_require_src++;
include/net/ip6_fib.h
111
static inline void fib6_routes_require_src_dec(struct net *net)
include/net/ip6_fib.h
113
net->ipv6.fib6_routes_require_src--;
include/net/ip6_fib.h
434
struct fib6_table *fib6_get_table(struct net *net, u32 id);
include/net/ip6_fib.h
435
struct fib6_table *fib6_new_table(struct net *net, u32 id);
include/net/ip6_fib.h
436
struct dst_entry *fib6_rule_lookup(struct net *net, struct flowi6 *fl6,
include/net/ip6_fib.h
443
int fib6_lookup(struct net *net, int oif, struct flowi6 *fl6,
include/net/ip6_fib.h
447
int fib6_table_lookup(struct net *net, struct fib6_table *table,
include/net/ip6_fib.h
451
void fib6_select_path(const struct net *net, struct fib6_result *res,
include/net/ip6_fib.h
463
void fib6_clean_all(struct net *net, int (*func)(struct fib6_info *, void *arg),
include/net/ip6_fib.h
465
void fib6_clean_all_skip_notify(struct net *net,
include/net/ip6_fib.h
490
int fib6_nh_init(struct net *net, struct fib6_nh *fib6_nh,
include/net/ip6_fib.h
496
static inline int fib6_nh_init(struct net *net, struct fib6_nh *fib6_nh,
include/net/ip6_fib.h
514
int call_fib6_entry_notifiers(struct net *net,
include/net/ip6_fib.h
518
int call_fib6_multipath_entry_notifiers(struct net *net,
include/net/ip6_fib.h
523
int call_fib6_entry_notifiers_replace(struct net *net, struct fib6_info *rt);
include/net/ip6_fib.h
525
void fib6_rt_update(struct net *net, struct fib6_info *rt,
include/net/ip6_fib.h
528
static inline void fib6_rt_update(struct net *net, struct fib6_info *rt,
include/net/ip6_fib.h
538
void fib6_run_gc(unsigned long expires, struct net *net, bool force);
include/net/ip6_fib.h
576
static inline void fib6_may_remove_gc_list(struct net *net,
include/net/ip6_fib.h
584
gc_args.timeout = READ_ONCE(net->ipv6.sysctl.ip6_rt_gc_interval);
include/net/ip6_fib.h
606
int call_fib6_notifiers(struct net *net, enum fib_event_type event_type,
include/net/ip6_fib.h
609
int __net_init fib6_notifier_init(struct net *net);
include/net/ip6_fib.h
610
void __net_exit fib6_notifier_exit(struct net *net);
include/net/ip6_fib.h
612
unsigned int fib6_tables_seq_read(const struct net *net);
include/net/ip6_fib.h
613
int fib6_tables_dump(struct net *net, struct notifier_block *nb,
include/net/ip6_fib.h
616
void fib6_update_sernum(struct net *net, struct fib6_info *rt);
include/net/ip6_fib.h
618
void fib6_update_sernum_upto_root(struct net *net, struct fib6_info *rt);
include/net/ip6_fib.h
620
static inline void fib6_update_sernum_upto_root(struct net *net, struct fib6_info *rt)
include/net/ip6_fib.h
630
void fib6_info_hw_flags_set(struct net *net, struct fib6_info *f6i,
include/net/ip6_fib.h
640
INDIRECT_CALLABLE_DECLARE(struct rt6_info *ip6_pol_route_output(struct net *net,
include/net/ip6_fib.h
645
INDIRECT_CALLABLE_DECLARE(struct rt6_info *ip6_pol_route_input(struct net *net,
include/net/ip6_fib.h
650
INDIRECT_CALLABLE_DECLARE(struct rt6_info *__ip6_route_redirect(struct net *net,
include/net/ip6_fib.h
655
INDIRECT_CALLABLE_DECLARE(struct rt6_info *ip6_pol_route_lookup(struct net *net,
include/net/ip6_fib.h
661
struct net *net,
include/net/ip6_fib.h
672
net, table, fl6, skb, flags);
include/net/ip6_fib.h
676
static inline bool fib6_has_custom_rules(const struct net *net)
include/net/ip6_fib.h
678
return net->ipv6.fib6_has_custom_rules;
include/net/ip6_fib.h
684
int fib6_rules_dump(struct net *net, struct notifier_block *nb,
include/net/ip6_fib.h
686
unsigned int fib6_rules_seq_read(const struct net *net);
include/net/ip6_fib.h
688
static inline bool fib6_rules_early_flow_dissect(struct net *net,
include/net/ip6_fib.h
695
if (!net->ipv6.fib6_rules_require_fldissect)
include/net/ip6_fib.h
699
__skb_flow_dissect(net, skb, &flow_keys_dissector,
include/net/ip6_fib.h
709
static inline bool fib6_has_custom_rules(const struct net *net)
include/net/ip6_fib.h
725
static inline int fib6_rules_dump(struct net *net, struct notifier_block *nb,
include/net/ip6_fib.h
730
static inline unsigned int fib6_rules_seq_read(const struct net *net)
include/net/ip6_fib.h
734
static inline bool fib6_rules_early_flow_dissect(struct net *net,
include/net/ip6_fib.h
91
static inline bool fib6_routes_require_src(const struct net *net)
include/net/ip6_fib.h
96
static inline void fib6_routes_require_src_inc(struct net *net) {}
include/net/ip6_fib.h
97
static inline void fib6_routes_require_src_dec(struct net *net) {}
include/net/ip6_route.h
100
return ip6_route_output_flags(net, sk, fl6, 0);
include/net/ip6_route.h
113
struct dst_entry *ip6_route_lookup(struct net *net, struct flowi6 *fl6,
include/net/ip6_route.h
115
struct rt6_info *ip6_pol_route(struct net *net, struct fib6_table *table,
include/net/ip6_route.h
123
int ipv6_route_ioctl(struct net *net, unsigned int cmd,
include/net/ip6_route.h
128
int ip6_ins_rt(struct net *net, struct fib6_info *f6i);
include/net/ip6_route.h
130
int ip6_del_rt(struct net *net, struct fib6_info *f6i, bool skip_notify);
include/net/ip6_route.h
132
static inline int ip6_del_rt(struct net *net, struct fib6_info *f6i,
include/net/ip6_route.h
143
static inline int ip6_route_get_saddr(struct net *net, struct fib6_info *f6i,
include/net/ip6_route.h
155
l3mdev = dev_get_by_index_rcu(net, l3mdev_index);
include/net/ip6_route.h
162
err = ipv6_dev_get_saddr(net, same_vrf ? dev : l3mdev, daddr, prefs, saddr);
include/net/ip6_route.h
169
struct rt6_info *rt6_lookup(struct net *net, const struct in6_addr *daddr,
include/net/ip6_route.h
172
u32 rt6_multipath_hash(const struct net *net, const struct flowi6 *fl6,
include/net/ip6_route.h
177
void fib6_force_start_gc(struct net *net);
include/net/ip6_route.h
179
struct fib6_info *addrconf_f6i_alloc(struct net *net, struct inet6_dev *idev,
include/net/ip6_route.h
183
struct rt6_info *ip6_dst_alloc(struct net *net, struct net_device *dev,
include/net/ip6_route.h
190
struct fib6_info *rt6_get_dflt_router(struct net *net,
include/net/ip6_route.h
193
struct fib6_info *rt6_add_dflt_router(struct net *net,
include/net/ip6_route.h
199
void rt6_purge_dflt_routers(struct net *net);
include/net/ip6_route.h
204
void ip6_update_pmtu(struct sk_buff *skb, struct net *net, __be32 mtu, int oif,
include/net/ip6_route.h
207
void ip6_redirect(struct sk_buff *skb, struct net *net, int oif, u32 mark,
include/net/ip6_route.h
209
void ip6_redirect_no_header(struct sk_buff *skb, struct net *net, int oif);
include/net/ip6_route.h
217
struct net *net;
include/net/ip6_route.h
224
void rt6_clean_tohost(struct net *net, struct in6_addr *gateway);
include/net/ip6_route.h
289
int ip6_fragment(struct net *net, struct sock *sk, struct sk_buff *skb,
include/net/ip6_route.h
290
int (*output)(struct net *, struct sock *, struct sk_buff *));
include/net/ip6_route.h
292
static inline int ip6_fragment(struct net *net, struct sock *sk,
include/net/ip6_route.h
294
int (*output)(struct net *, struct sock *,
include/net/ip6_route.h
88
struct dst_entry *ip6_route_input_lookup(struct net *net,
include/net/ip6_route.h
93
struct dst_entry *ip6_route_output_flags(struct net *net, const struct sock *sk,
include/net/ip6_route.h
96
static inline struct dst_entry *ip6_route_output(struct net *net,
include/net/ip6_tunnel.h
150
struct net *ip6_tnl_get_link_net(const struct net_device *dev);
include/net/ip6_tunnel.h
50
struct net *net; /* netns for packet i/o */
include/net/ip_fib.h
140
struct net *fib_net;
include/net/ip_fib.h
165
int __net_init fib4_semantics_init(struct net *net);
include/net/ip_fib.h
166
void __net_exit fib4_semantics_exit(struct net *net);
include/net/ip_fib.h
208
__be32 fib_info_update_nhc_saddr(struct net *net, struct fib_nh_common *nhc,
include/net/ip_fib.h
210
__be32 fib_result_prefsrc(struct net *net, struct fib_result *res);
include/net/ip_fib.h
247
int call_fib4_notifiers(struct net *net, enum fib_event_type event_type,
include/net/ip_fib.h
250
int __net_init fib4_notifier_init(struct net *net);
include/net/ip_fib.h
251
void __net_exit fib4_notifier_exit(struct net *net);
include/net/ip_fib.h
253
void fib_info_notify_update(struct net *net, struct nl_info *info);
include/net/ip_fib.h
254
int fib_notify(struct net *net, struct notifier_block *nb,
include/net/ip_fib.h
280
int fib_table_insert(struct net *, struct fib_table *, struct fib_config *,
include/net/ip_fib.h
282
int fib_table_delete(struct net *, struct fib_table *, struct fib_config *,
include/net/ip_fib.h
286
int fib_table_flush(struct net *net, struct fib_table *table, bool flush_all);
include/net/ip_fib.h
296
static inline struct fib_table *fib_get_table(struct net *net, u32 id)
include/net/ip_fib.h
302
&net->ipv4.fib_table_hash[TABLE_LOCAL_INDEX] :
include/net/ip_fib.h
303
&net->ipv4.fib_table_hash[TABLE_MAIN_INDEX];
include/net/ip_fib.h
310
static inline struct fib_table *fib_new_table(struct net *net, u32 id)
include/net/ip_fib.h
312
return fib_get_table(net, id);
include/net/ip_fib.h
315
static inline int fib_lookup(struct net *net, const struct flowi4 *flp,
include/net/ip_fib.h
323
tb = fib_get_table(net, RT_TABLE_MAIN);
include/net/ip_fib.h
335
static inline bool fib4_has_custom_rules(const struct net *net)
include/net/ip_fib.h
345
static inline int fib4_rules_dump(struct net *net, struct notifier_block *nb,
include/net/ip_fib.h
351
static inline unsigned int fib4_rules_seq_read(const struct net *net)
include/net/ip_fib.h
356
static inline bool fib4_rules_early_flow_dissect(struct net *net,
include/net/ip_fib.h
364
int __net_init fib4_rules_init(struct net *net);
include/net/ip_fib.h
365
void __net_exit fib4_rules_exit(struct net *net);
include/net/ip_fib.h
367
struct fib_table *fib_new_table(struct net *net, u32 id);
include/net/ip_fib.h
368
struct fib_table *fib_get_table(struct net *net, u32 id);
include/net/ip_fib.h
370
int __fib_lookup(struct net *net, struct flowi4 *flp,
include/net/ip_fib.h
373
static inline int fib_lookup(struct net *net, struct flowi4 *flp,
include/net/ip_fib.h
380
if (net->ipv4.fib_has_custom_rules)
include/net/ip_fib.h
381
return __fib_lookup(net, flp, res, flags);
include/net/ip_fib.h
387
tb = rcu_dereference_rtnl(net->ipv4.fib_main);
include/net/ip_fib.h
394
tb = rcu_dereference_rtnl(net->ipv4.fib_default);
include/net/ip_fib.h
406
static inline bool fib4_has_custom_rules(const struct net *net)
include/net/ip_fib.h
408
return net->ipv4.fib_has_custom_rules;
include/net/ip_fib.h
412
int fib4_rules_dump(struct net *net, struct notifier_block *nb,
include/net/ip_fib.h
414
unsigned int fib4_rules_seq_read(const struct net *net);
include/net/ip_fib.h
416
static inline bool fib4_rules_early_flow_dissect(struct net *net,
include/net/ip_fib.h
423
if (!net->ipv4.fib_rules_require_fldissect)
include/net/ip_fib.h
427
__skb_flow_dissect(net, skb, &flow_keys_dissector,
include/net/ip_fib.h
468
static inline int fib_num_tclassid_users(struct net *net)
include/net/ip_fib.h
470
return atomic_read(&net->ipv4.fib_num_tclassid_users);
include/net/ip_fib.h
473
static inline int fib_num_tclassid_users(struct net *net)
include/net/ip_fib.h
478
int fib_unmerge(struct net *net);
include/net/ip_fib.h
542
int fib_multipath_hash(const struct net *net, const struct flowi4 *fl4,
include/net/ip_fib.h
554
static inline u32 fib_multipath_hash_from_keys(const struct net *net,
include/net/ip_fib.h
560
mp_seed = READ_ONCE(net->ipv4.sysctl_fib_multipath_hash_seed.mp_seed);
include/net/ip_fib.h
566
static inline u32 fib_multipath_hash_from_keys(const struct net *net,
include/net/ip_fib.h
573
int fib_check_nh(struct net *net, struct fib_nh *nh, u32 table, u8 scope,
include/net/ip_fib.h
577
void fib_select_path(struct net *net, struct fib_result *res,
include/net/ip_fib.h
580
int fib_nh_init(struct net *net, struct fib_nh *fib_nh,
include/net/ip_fib.h
583
void fib_nh_release(struct net *net, struct fib_nh *fib_nh);
include/net/ip_fib.h
584
int fib_nh_common_init(struct net *net, struct fib_nh_common *nhc,
include/net/ip_fib.h
591
void fib_alias_hw_flags_set(struct net *net, const struct fib_rt_info *fri);
include/net/ip_fib.h
622
void fib_flush(struct net *net);
include/net/ip_fib.h
642
int __net_init fib_proc_init(struct net *net);
include/net/ip_fib.h
643
void __net_exit fib_proc_exit(struct net *net);
include/net/ip_fib.h
645
static inline int fib_proc_init(struct net *net)
include/net/ip_fib.h
649
static inline void fib_proc_exit(struct net *net)
include/net/ip_fib.h
656
int ip_valid_fib_dump_req(struct net *net, const struct nlmsghdr *nlh,
include/net/ip_tunnels.h
160
struct net *net; /* netns for packet i/o */
include/net/ip_tunnels.h
361
struct net *net, int oif,
include/net/ip_tunnels.h
368
fl4->flowi4_l3mdev = l3mdev_master_upper_ifindex_by_index(net, oif);
include/net/ip_tunnels.h
396
struct net *ip_tunnel_get_link_net(const struct net_device *dev);
include/net/ip_tunnels.h
398
int ip_tunnel_init_net(struct net *net, unsigned int ip_tnl_net_id,
include/net/ip_tunnels.h
400
void ip_tunnel_delete_net(struct net *net, unsigned int id,
include/net/ip_tunnels.h
429
int ip_tunnel_newlink(struct net *net, struct net_device *dev,
include/net/ip_vs.h
1305
struct net *net; /* Needed by timer routines */
include/net/ip_vs.h
2175
ret = nf_ct_netns_get(svc->ipvs->net, svc->af);
include/net/ip_vs.h
2191
nf_ct_netns_put(svc->ipvs->net, svc->af);
include/net/ip_vs.h
60
static inline struct netns_ipvs *net_ipvs(struct net* net)
include/net/ip_vs.h
62
return net->ipvs;
include/net/ipv6.h
1022
int ip6_rcv_finish(struct net *net, struct sock *sk, struct sk_buff *skb);
include/net/ipv6.h
1060
int ip6_dst_lookup(struct net *net, struct sock *sk, struct dst_entry **dst,
include/net/ipv6.h
1063
struct dst_entry *ip6_dst_lookup_flow(struct net *net, const struct sock *sk, struct flowi6 *fl6,
include/net/ipv6.h
1066
static inline struct dst_entry *ip6_dst_lookup_flow(struct net *net, const struct sock *sk,
include/net/ipv6.h
1077
struct dst_entry *ip6_blackhole_route(struct net *net,
include/net/ipv6.h
1084
int ip6_output(struct net *net, struct sock *sk, struct sk_buff *skb);
include/net/ipv6.h
1088
void ip6_protocol_deliver_rcu(struct net *net, struct sk_buff *skb, int nexthdr,
include/net/ipv6.h
1091
int __ip6_local_out(struct net *net, struct sock *sk, struct sk_buff *skb);
include/net/ipv6.h
1092
int ip6_local_out(struct net *net, struct sock *sk, struct sk_buff *skb);
include/net/ipv6.h
1201
int ac6_proc_init(struct net *net);
include/net/ipv6.h
1202
void ac6_proc_exit(struct net *net);
include/net/ipv6.h
1205
int tcp6_proc_init(struct net *net);
include/net/ipv6.h
1206
void tcp6_proc_exit(struct net *net);
include/net/ipv6.h
1207
int udp6_proc_init(struct net *net);
include/net/ipv6.h
1208
void udp6_proc_exit(struct net *net);
include/net/ipv6.h
1215
static inline int ac6_proc_init(struct net *net) { return 0; }
include/net/ipv6.h
1216
static inline void ac6_proc_exit(struct net *net) { }
include/net/ipv6.h
1222
struct ctl_table *ipv6_icmp_sysctl_init(struct net *net);
include/net/ipv6.h
1224
struct ctl_table *ipv6_route_sysctl_init(struct net *net);
include/net/ipv6.h
1225
size_t ipv6_route_sysctl_table_size(struct net *net);
include/net/ipv6.h
201
#define IP6_REPLY_MARK(net, mark) \
include/net/ipv6.h
202
((net)->ipv6.sysctl.fwmark_reflect ? (mark) : 0)
include/net/ipv6.h
210
#define _DEVINC(net, statname, mod, idev, field) \
include/net/ipv6.h
215
mod##SNMP_INC_STATS64((net)->mib.statname##_statistics, (field));\
include/net/ipv6.h
219
#define _DEVINCATOMIC(net, statname, mod, idev, field) \
include/net/ipv6.h
224
mod##SNMP_INC_STATS((net)->mib.statname##_statistics, (field));\
include/net/ipv6.h
228
#define _DEVINC_ATOMIC_ATOMIC(net, statname, idev, field) \
include/net/ipv6.h
233
SNMP_INC_STATS_ATOMIC_LONG((net)->mib.statname##_statistics, (field));\
include/net/ipv6.h
236
#define _DEVADD(net, statname, mod, idev, field, val) \
include/net/ipv6.h
243
mod##SNMP_ADD_STATS((net)->mib.statname##_statistics, _field, _val);\
include/net/ipv6.h
246
#define _DEVUPD(net, statname, mod, idev, field, val) \
include/net/ipv6.h
252
mod##SNMP_UPD_PO_STATS((net)->mib.statname##_statistics, field, _val);\
include/net/ipv6.h
257
#define IP6_INC_STATS(net, idev,field) \
include/net/ipv6.h
258
_DEVINC(net, ipv6, , idev, field)
include/net/ipv6.h
259
#define __IP6_INC_STATS(net, idev,field) \
include/net/ipv6.h
260
_DEVINC(net, ipv6, __, idev, field)
include/net/ipv6.h
261
#define IP6_ADD_STATS(net, idev,field,val) \
include/net/ipv6.h
262
_DEVADD(net, ipv6, , idev, field, val)
include/net/ipv6.h
263
#define __IP6_ADD_STATS(net, idev,field,val) \
include/net/ipv6.h
264
_DEVADD(net, ipv6, __, idev, field, val)
include/net/ipv6.h
265
#define IP6_UPD_PO_STATS(net, idev,field,val) \
include/net/ipv6.h
266
_DEVUPD(net, ipv6, , idev, field, val)
include/net/ipv6.h
267
#define __IP6_UPD_PO_STATS(net, idev,field,val) \
include/net/ipv6.h
268
_DEVUPD(net, ipv6, __, idev, field, val)
include/net/ipv6.h
269
#define ICMP6_INC_STATS(net, idev, field) \
include/net/ipv6.h
270
_DEVINCATOMIC(net, icmpv6, , idev, field)
include/net/ipv6.h
271
#define __ICMP6_INC_STATS(net, idev, field) \
include/net/ipv6.h
272
_DEVINCATOMIC(net, icmpv6, __, idev, field)
include/net/ipv6.h
274
#define ICMP6MSGOUT_INC_STATS(net, idev, field) \
include/net/ipv6.h
275
_DEVINC_ATOMIC_ATOMIC(net, icmpv6msg, idev, field +256)
include/net/ipv6.h
276
#define ICMP6MSGIN_INC_STATS(net, idev, field) \
include/net/ipv6.h
277
_DEVINC_ATOMIC_ATOMIC(net, icmpv6msg, idev, field)
include/net/ipv6.h
334
struct net *fl_net;
include/net/ipv6.h
417
bool ip6_autoflowlabel(struct net *net, const struct sock *sk);
include/net/ipv6.h
714
static inline u32 ipv6_portaddr_hash(const struct net *net,
include/net/ipv6.h
718
unsigned int hash, mix = net_hash_mix(net);
include/net/ipv6.h
821
__be32 ipv6_select_ident(struct net *net,
include/net/ipv6.h
824
__be32 ipv6_proxy_select_ident(struct net *net, struct sk_buff *skb);
include/net/ipv6.h
858
static inline bool ipv6_can_nonlocal_bind(const struct net *net,
include/net/ipv6.h
861
return READ_ONCE(net->ipv6.sysctl.ip_nonlocal_bind) ||
include/net/ipv6.h
876
static inline __be32 ip6_make_flowlabel(const struct net *net,
include/net/ipv6.h
892
auto_flowlabels = READ_ONCE(net->ipv6.sysctl.auto_flowlabels);
include/net/ipv6.h
907
if (READ_ONCE(net->ipv6.sysctl.flowlabel_state_ranges))
include/net/ipv6.h
913
static inline int ip6_default_np_autolabel(const struct net *net)
include/net/ipv6.h
915
switch (READ_ONCE(net->ipv6.sysctl.auto_flowlabels)) {
include/net/ipv6.h
926
static inline __be32 ip6_make_flowlabel(const struct net *net, struct sk_buff *skb,
include/net/ipv6.h
932
static inline int ip6_default_np_autolabel(const struct net *net)
include/net/ipv6.h
939
static inline int ip6_multipath_hash_policy(const struct net *net)
include/net/ipv6.h
941
return READ_ONCE(net->ipv6.sysctl.multipath_hash_policy);
include/net/ipv6.h
943
static inline u32 ip6_multipath_hash_fields(const struct net *net)
include/net/ipv6.h
945
return READ_ONCE(net->ipv6.sysctl.multipath_hash_fields);
include/net/ipv6.h
948
static inline int ip6_multipath_hash_policy(const struct net *net)
include/net/ipv6.h
952
static inline u32 ip6_multipath_hash_fields(const struct net *net)
include/net/ipv6.h
963
static inline void ip6_ecmp_set_mp_hash(const struct net *net,
include/net/ipv6.h
966
if (ip6_multipath_hash_policy(net) == 0 && txhash)
include/net/ipv6_frag.h
65
ip6frag_expire_frag_queue(struct net *net, struct frag_queue *fq)
include/net/ipv6_frag.h
86
dev = dev_get_by_index_rcu(net, fq->iif);
include/net/ipv6_frag.h
90
__IP6_INC_STATS(net, __in6_dev_get(dev), IPSTATS_MIB_REASMFAILS);
include/net/ipv6_frag.h
91
__IP6_INC_STATS(net, __in6_dev_get(dev), IPSTATS_MIB_REASMTIMEOUT);
include/net/l3mdev.h
133
int l3mdev_master_upper_ifindex_by_index_rcu(struct net *net, int ifindex);
include/net/l3mdev.h
135
int l3mdev_master_upper_ifindex_by_index(struct net *net, int ifindex)
include/net/l3mdev.h
138
ifindex = l3mdev_master_upper_ifindex_by_index_rcu(net, ifindex);
include/net/l3mdev.h
145
u32 l3mdev_fib_table_by_index(struct net *net, int ifindex);
include/net/l3mdev.h
157
static inline bool netif_index_is_l3_master(struct net *net, int ifindex)
include/net/l3mdev.h
167
dev = dev_get_by_index_rcu(net, ifindex);
include/net/l3mdev.h
176
struct dst_entry *l3mdev_link_scope_lookup(struct net *net, struct flowi6 *fl6);
include/net/l3mdev.h
21
typedef int (*lookup_by_table_id_t)(struct net *net, u32 table_d);
include/net/l3mdev.h
249
static inline int l3mdev_master_ifindex_by_index(struct net *net, int ifindex)
include/net/l3mdev.h
255
int l3mdev_master_upper_ifindex_by_index_rcu(struct net *net, int ifindex)
include/net/l3mdev.h
260
int l3mdev_master_upper_ifindex_by_index(struct net *net, int ifindex)
include/net/l3mdev.h
279
static inline u32 l3mdev_fib_table_by_index(struct net *net, int ifindex)
include/net/l3mdev.h
284
static inline bool netif_index_is_l3_master(struct net *net, int ifindex)
include/net/l3mdev.h
290
struct dst_entry *l3mdev_link_scope_lookup(struct net *net, struct flowi6 *fl6)
include/net/l3mdev.h
333
int l3mdev_ifindex_lookup_by_table_id(enum l3mdev_type l3type, struct net *net,
include/net/l3mdev.h
340
int l3mdev_fib_rule_match(struct net *net, struct flowi *fl,
include/net/l3mdev.h
359
void l3mdev_update_flow(struct net *net, struct flowi *fl)
include/net/l3mdev.h
56
int l3mdev_ifindex_lookup_by_table_id(enum l3mdev_type l3type, struct net *net,
include/net/l3mdev.h
59
int l3mdev_fib_rule_match(struct net *net, struct flowi *fl,
include/net/l3mdev.h
76
void l3mdev_update_flow(struct net *net, struct flowi *fl);
include/net/l3mdev.h
90
static inline int l3mdev_master_ifindex_by_index(struct net *net, int ifindex)
include/net/l3mdev.h
98
dev = dev_get_by_index_rcu(net, ifindex);
include/net/llc_conn.h
108
struct llc_addr *laddr, const struct net *net);
include/net/llc_conn.h
93
struct sock *llc_sk_alloc(struct net *net, int family, gfp_t priority,
include/net/lwtunnel.h
122
int lwtunnel_build_state(struct net *net, u16 encap_type,
include/net/lwtunnel.h
132
int lwtunnel_output(struct net *net, struct sock *sk, struct sk_buff *skb);
include/net/lwtunnel.h
219
static inline int lwtunnel_build_state(struct net *net, u16 encap_type,
include/net/lwtunnel.h
251
static inline int lwtunnel_output(struct net *net, struct sock *sk, struct sk_buff *skb)
include/net/lwtunnel.h
33
int (*orig_output)(struct net *net, struct sock *sk, struct sk_buff *skb);
include/net/lwtunnel.h
40
int (*build_state)(struct net *net, struct nlattr *encap,
include/net/lwtunnel.h
45
int (*output)(struct net *net, struct sock *sk, struct sk_buff *skb);
include/net/mctp.h
142
unsigned int net;
include/net/mctp.h
191
unsigned int net;
include/net/mctp.h
285
int mctp_dst_from_extaddr(struct mctp_dst *dst, struct net *net, int ifindex,
include/net/mctp.h
289
int mctp_route_lookup(struct net *net, unsigned int dnet,
include/net/mctp.h
305
unsigned int mctp_default_net(struct net *net);
include/net/mctp.h
306
int mctp_default_net_set(struct net *net, unsigned int index);
include/net/mctpdevice.h
24
unsigned int net;
include/net/ndisc.h
199
void (*prefix_rcv_add_addr)(struct net *net, struct net_device *dev,
include/net/ndisc.h
268
static inline void ndisc_ops_prefix_rcv_add_addr(struct net *net,
include/net/ndisc.h
280
dev->ndisc_ops->prefix_rcv_add_addr(net, dev, pinfo, in6_dev,
include/net/neighbour.h
182
possible_net_t net;
include/net/neighbour.h
376
struct net *neigh_parms_net(const struct neigh_parms *parms)
include/net/neighbour.h
378
return read_pnet(&parms->net);
include/net/neighbour.h
392
struct pneigh_entry *pneigh_lookup(struct neigh_table *tbl, struct net *net,
include/net/neighbour.h
394
int pneigh_create(struct neigh_table *tbl, struct net *net, const void *key,
include/net/neighbour.h
397
int pneigh_delete(struct neigh_table *tbl, struct net *net, const void *key,
include/net/neighbour.h
400
static inline struct net *pneigh_net(const struct pneigh_entry *pneigh)
include/net/neighbour.h
402
return read_pnet(&pneigh->net);
include/net/neighbour.h
73
possible_net_t net;
include/net/net_namespace.h
209
extern struct net init_net;
include/net/net_namespace.h
212
struct net *copy_net_ns(u64 flags, struct user_namespace *user_ns,
include/net/net_namespace.h
213
struct net *old_net);
include/net/net_namespace.h
215
void net_ns_get_ownership(const struct net *net, kuid_t *uid, kgid_t *gid);
include/net/net_namespace.h
220
struct net *get_net_ns_by_fd(int fd);
include/net/net_namespace.h
226
static inline struct net *copy_net_ns(u64 flags,
include/net/net_namespace.h
227
struct user_namespace *user_ns, struct net *old_net)
include/net/net_namespace.h
234
static inline void net_ns_get_ownership(const struct net *net,
include/net/net_namespace.h
248
static inline struct net *get_net_ns_by_fd(int fd)
include/net/net_namespace.h
257
struct net *get_net_ns_by_pid(pid_t pid);
include/net/net_namespace.h
267
static inline struct net *to_net_ns(struct ns_common *ns)
include/net/net_namespace.h
269
return container_of(ns, struct net, ns);
include/net/net_namespace.h
273
void __put_net(struct net *net);
include/net/net_namespace.h
276
static inline struct net *get_net(struct net *net)
include/net/net_namespace.h
278
ns_ref_inc(net);
include/net/net_namespace.h
279
return net;
include/net/net_namespace.h
282
static inline struct net *maybe_get_net(struct net *net)
include/net/net_namespace.h
289
if (!ns_ref_get(net))
include/net/net_namespace.h
290
net = NULL;
include/net/net_namespace.h
291
return net;
include/net/net_namespace.h
295
static inline void put_net(struct net *net)
include/net/net_namespace.h
297
if (ns_ref_put(net))
include/net/net_namespace.h
298
__put_net(net);
include/net/net_namespace.h
302
int net_eq(const struct net *net1, const struct net *net2)
include/net/net_namespace.h
307
static inline int check_net(const struct net *net)
include/net/net_namespace.h
309
return ns_ref_read(net) != 0;
include/net/net_namespace.h
313
void net_passive_dec(struct net *net);
include/net/net_namespace.h
317
static inline struct net *get_net(struct net *net)
include/net/net_namespace.h
319
return net;
include/net/net_namespace.h
322
static inline void put_net(struct net *net)
include/net/net_namespace.h
326
static inline struct net *maybe_get_net(struct net *net)
include/net/net_namespace.h
328
return net;
include/net/net_namespace.h
332
int net_eq(const struct net *net1, const struct net *net2)
include/net/net_namespace.h
337
static inline int check_net(const struct net *net)
include/net/net_namespace.h
344
static inline void net_passive_dec(struct net *net)
include/net/net_namespace.h
346
refcount_dec(&net->passive);
include/net/net_namespace.h
350
static inline void net_passive_inc(struct net *net)
include/net/net_namespace.h
352
refcount_inc(&net->passive);
include/net/net_namespace.h
356
static inline bool net_initialized(const struct net *net)
include/net/net_namespace.h
358
return READ_ONCE(net->list.next);
include/net/net_namespace.h
361
static inline void __netns_tracker_alloc(struct net *net,
include/net/net_namespace.h
367
ref_tracker_alloc(refcounted ? &net->refcnt_tracker :
include/net/net_namespace.h
368
&net->notrefcnt_tracker,
include/net/net_namespace.h
373
static inline void netns_tracker_alloc(struct net *net, netns_tracker *tracker,
include/net/net_namespace.h
376
__netns_tracker_alloc(net, tracker, true, gfp);
include/net/net_namespace.h
379
static inline void __netns_tracker_free(struct net *net,
include/net/net_namespace.h
384
ref_tracker_free(refcounted ? &net->refcnt_tracker :
include/net/net_namespace.h
385
&net->notrefcnt_tracker, tracker);
include/net/net_namespace.h
389
static inline struct net *get_net_track(struct net *net,
include/net/net_namespace.h
392
get_net(net);
include/net/net_namespace.h
393
netns_tracker_alloc(net, tracker, gfp);
include/net/net_namespace.h
394
return net;
include/net/net_namespace.h
397
static inline void put_net_track(struct net *net, netns_tracker *tracker)
include/net/net_namespace.h
399
__netns_tracker_free(net, tracker, true);
include/net/net_namespace.h
400
put_net(net);
include/net/net_namespace.h
405
struct net __rcu *net;
include/net/net_namespace.h
409
static inline void write_pnet(possible_net_t *pnet, struct net *net)
include/net/net_namespace.h
412
rcu_assign_pointer(pnet->net, net);
include/net/net_namespace.h
416
static inline struct net *read_pnet(const possible_net_t *pnet)
include/net/net_namespace.h
419
return rcu_dereference_protected(pnet->net, true);
include/net/net_namespace.h
425
static inline struct net *read_pnet_rcu(const possible_net_t *pnet)
include/net/net_namespace.h
428
return rcu_dereference(pnet->net);
include/net/net_namespace.h
454
int peernet2id_alloc(struct net *net, struct net *peer, gfp_t gfp);
include/net/net_namespace.h
455
int peernet2id(const struct net *net, struct net *peer);
include/net/net_namespace.h
456
bool peernet_has_id(const struct net *net, struct net *peer);
include/net/net_namespace.h
457
struct net *get_net_ns_by_id(const struct net *net, int id);
include/net/net_namespace.h
483
int (*init)(struct net *net);
include/net/net_namespace.h
484
void (*pre_exit)(struct net *net);
include/net/net_namespace.h
485
void (*exit)(struct net *net);
include/net/net_namespace.h
488
void (*exit_rtnl)(struct net *net,
include/net/net_namespace.h
520
#define register_net_sysctl(net, path, table) \
include/net/net_namespace.h
521
register_net_sysctl_sz(net, path, table, ARRAY_SIZE(table))
include/net/net_namespace.h
524
struct ctl_table_header *register_net_sysctl_sz(struct net *net, const char *path,
include/net/net_namespace.h
529
static inline struct ctl_table_header *register_net_sysctl_sz(struct net *net,
include/net/net_namespace.h
539
static inline int rt_genid_ipv4(const struct net *net)
include/net/net_namespace.h
541
return atomic_read(&net->ipv4.rt_genid);
include/net/net_namespace.h
545
static inline int rt_genid_ipv6(const struct net *net)
include/net/net_namespace.h
547
return atomic_read(&net->ipv6.fib6_sernum);
include/net/net_namespace.h
551
static inline void rt_genid_bump_ipv4(struct net *net)
include/net/net_namespace.h
553
atomic_inc(&net->ipv4.rt_genid);
include/net/net_namespace.h
556
extern void (*__fib6_flush_trees)(struct net *net);
include/net/net_namespace.h
557
static inline void rt_genid_bump_ipv6(struct net *net)
include/net/net_namespace.h
560
__fib6_flush_trees(net);
include/net/net_namespace.h
565
net_ieee802154_lowpan(struct net *net)
include/net/net_namespace.h
567
return &net->ieee802154_lowpan;
include/net/net_namespace.h
572
static inline void rt_genid_bump_all(struct net *net)
include/net/net_namespace.h
574
rt_genid_bump_ipv4(net);
include/net/net_namespace.h
575
rt_genid_bump_ipv6(net);
include/net/net_namespace.h
578
static inline int fnhe_genid(const struct net *net)
include/net/net_namespace.h
580
return atomic_read(&net->fnhe_genid);
include/net/net_namespace.h
583
static inline void fnhe_genid_bump(struct net *net)
include/net/net_namespace.h
585
atomic_inc(&net->fnhe_genid);
include/net/netfilter/br_netfilter.h
25
int br_nf_hook_thresh(unsigned int hook, struct net *net, struct sock *sk,
include/net/netfilter/br_netfilter.h
28
int (*okfn)(struct net *, struct sock *,
include/net/netfilter/br_netfilter.h
41
int br_nf_pre_routing_finish_bridge(struct net *net, struct sock *sk, struct sk_buff *skb);
include/net/netfilter/br_netfilter.h
56
const struct net *net);
include/net/netfilter/br_netfilter.h
59
int br_validate_ipv6(struct net *net, struct sk_buff *skb);
include/net/netfilter/br_netfilter.h
64
static inline int br_validate_ipv6(struct net *net, struct sk_buff *skb)
include/net/netfilter/ipv4/nf_defrag_ipv4.h
5
struct net;
include/net/netfilter/ipv4/nf_defrag_ipv4.h
6
int nf_defrag_ipv4_enable(struct net *net);
include/net/netfilter/ipv4/nf_defrag_ipv4.h
7
void nf_defrag_ipv4_disable(struct net *net);
include/net/netfilter/ipv4/nf_dup_ipv4.h
8
void nf_dup_ipv4(struct net *net, struct sk_buff *skb, unsigned int hooknum,
include/net/netfilter/ipv4/nf_reject.h
11
void nf_send_reset(struct net *net, struct sock *, struct sk_buff *oldskb,
include/net/netfilter/ipv4/nf_reject.h
13
struct sk_buff *nf_reject_skb_v4_unreach(struct net *net,
include/net/netfilter/ipv4/nf_reject.h
17
struct sk_buff *nf_reject_skb_v4_tcp_reset(struct net *net,
include/net/netfilter/ipv6/nf_defrag_ipv6.h
13
int nf_ct_frag6_gather(struct net *net, struct sk_buff *skb, u32 user);
include/net/netfilter/ipv6/nf_defrag_ipv6.h
8
int nf_defrag_ipv6_enable(struct net *net);
include/net/netfilter/ipv6/nf_defrag_ipv6.h
9
void nf_defrag_ipv6_disable(struct net *net);
include/net/netfilter/ipv6/nf_dup_ipv6.h
7
void nf_dup_ipv6(struct net *net, struct sk_buff *skb, unsigned int hooknum,
include/net/netfilter/ipv6/nf_reject.h
10
void nf_send_reset6(struct net *net, struct sock *sk, struct sk_buff *oldskb,
include/net/netfilter/ipv6/nf_reject.h
12
struct sk_buff *nf_reject_skb_v6_tcp_reset(struct net *net,
include/net/netfilter/ipv6/nf_reject.h
16
struct sk_buff *nf_reject_skb_v6_unreach(struct net *net,
include/net/netfilter/ipv6/nf_reject.h
8
void nf_send_unreach6(struct net *net, struct sk_buff *skb_in, unsigned char code,
include/net/netfilter/nf_conntrack.h
155
extern struct net init_net;
include/net/netfilter/nf_conntrack.h
157
static inline struct net *nf_ct_net(const struct nf_conn *ct)
include/net/netfilter/nf_conntrack.h
189
int nf_ct_netns_get(struct net *net, u8 nfproto);
include/net/netfilter/nf_conntrack.h
190
void nf_ct_netns_put(struct net *net, u8 nfproto);
include/net/netfilter/nf_conntrack.h
202
u_int16_t l3num, struct net *net,
include/net/netfilter/nf_conntrack.h
235
struct net *net;
include/net/netfilter/nf_conntrack.h
252
struct nf_conn *nf_conntrack_alloc(struct net *net,
include/net/netfilter/nf_conntrack.h
352
struct nf_conn *nf_ct_tmpl_alloc(struct net *net,
include/net/netfilter/nf_conntrack.h
358
u32 nf_conntrack_count(const struct net *net);
include/net/netfilter/nf_conntrack.h
368
static inline struct nf_conntrack_net *nf_ct_pernet(const struct net *net)
include/net/netfilter/nf_conntrack.h
370
return net_generic(net, nf_conntrack_net_id);
include/net/netfilter/nf_conntrack.h
374
int nf_ct_handle_fragments(struct net *net, struct sk_buff *skb,
include/net/netfilter/nf_conntrack.h
377
#define NF_CT_STAT_INC(net, count) __this_cpu_inc((net)->ct.stat->count)
include/net/netfilter/nf_conntrack.h
378
#define NF_CT_STAT_INC_ATOMIC(net, count) this_cpu_inc((net)->ct.stat->count)
include/net/netfilter/nf_conntrack.h
379
#define NF_CT_STAT_ADD_ATOMIC(net, count, v) this_cpu_add((net)->ct.stat->count, (v))
include/net/netfilter/nf_conntrack_acct.h
33
struct net *net = nf_ct_net(ct);
include/net/netfilter/nf_conntrack_acct.h
36
if (!net->ct.sysctl_acct)
include/net/netfilter/nf_conntrack_acct.h
51
static inline bool nf_ct_acct_enabled(struct net *net)
include/net/netfilter/nf_conntrack_acct.h
54
return net->ct.sysctl_acct != 0;
include/net/netfilter/nf_conntrack_acct.h
61
static inline void nf_ct_set_acct(struct net *net, bool enable)
include/net/netfilter/nf_conntrack_acct.h
64
net->ct.sysctl_acct = enable;
include/net/netfilter/nf_conntrack_acct.h
79
void nf_conntrack_acct_pernet_init(struct net *net);
include/net/netfilter/nf_conntrack_core.h
28
int nf_conntrack_init_net(struct net *net);
include/net/netfilter/nf_conntrack_core.h
29
void nf_conntrack_cleanup_net(struct net *net);
include/net/netfilter/nf_conntrack_core.h
32
void nf_conntrack_proto_pernet_init(struct net *net);
include/net/netfilter/nf_conntrack_core.h
48
nf_conntrack_find_get(struct net *net,
include/net/netfilter/nf_conntrack_count.h
19
struct nf_conncount_data *nf_conncount_init(struct net *net, unsigned int keylen);
include/net/netfilter/nf_conntrack_count.h
20
void nf_conncount_destroy(struct net *net, struct nf_conncount_data *data);
include/net/netfilter/nf_conntrack_count.h
22
unsigned int nf_conncount_count_skb(struct net *net,
include/net/netfilter/nf_conntrack_count.h
28
int nf_conncount_add_skb(struct net *net, const struct sk_buff *skb,
include/net/netfilter/nf_conntrack_count.h
33
bool nf_conncount_gc_list(struct net *net,
include/net/netfilter/nf_conntrack_ecache.h
105
struct net *net = nf_ct_net(ct);
include/net/netfilter/nf_conntrack_ecache.h
108
if (!rcu_access_pointer(net->ct.nf_conntrack_event_cb))
include/net/netfilter/nf_conntrack_ecache.h
153
void nf_conntrack_ecache_work(struct net *net, enum nf_ct_ecache_state state);
include/net/netfilter/nf_conntrack_ecache.h
155
void nf_conntrack_ecache_pernet_init(struct net *net);
include/net/netfilter/nf_conntrack_ecache.h
156
void nf_conntrack_ecache_pernet_fini(struct net *net);
include/net/netfilter/nf_conntrack_ecache.h
158
struct nf_conntrack_net_ecache *nf_conn_pernet_ecache(const struct net *net);
include/net/netfilter/nf_conntrack_ecache.h
160
static inline bool nf_conntrack_ecache_dwork_pending(const struct net *net)
include/net/netfilter/nf_conntrack_ecache.h
162
return net->ct.ecache_dwork_pending;
include/net/netfilter/nf_conntrack_ecache.h
173
static inline void nf_conntrack_ecache_work(struct net *net,
include/net/netfilter/nf_conntrack_ecache.h
178
static inline void nf_conntrack_ecache_pernet_init(struct net *net)
include/net/netfilter/nf_conntrack_ecache.h
182
static inline void nf_conntrack_ecache_pernet_fini(struct net *net)
include/net/netfilter/nf_conntrack_ecache.h
185
static inline bool nf_conntrack_ecache_dwork_pending(const struct net *net) { return false; }
include/net/netfilter/nf_conntrack_ecache.h
72
void nf_conntrack_register_notifier(struct net *net,
include/net/netfilter/nf_conntrack_ecache.h
74
void nf_conntrack_unregister_notifier(struct net *net);
include/net/netfilter/nf_conntrack_expect.h
112
int nf_conntrack_expect_pernet_init(struct net *net);
include/net/netfilter/nf_conntrack_expect.h
113
void nf_conntrack_expect_pernet_fini(struct net *net);
include/net/netfilter/nf_conntrack_expect.h
119
__nf_ct_expect_find(struct net *net,
include/net/netfilter/nf_conntrack_expect.h
124
nf_ct_expect_find_get(struct net *net,
include/net/netfilter/nf_conntrack_expect.h
129
nf_ct_find_expectation(struct net *net,
include/net/netfilter/nf_conntrack_expect.h
144
void nf_ct_expect_iterate_net(struct net *net,
include/net/netfilter/nf_conntrack_expect.h
26
possible_net_t net;
include/net/netfilter/nf_conntrack_expect.h
81
static inline struct net *nf_ct_exp_net(struct nf_conntrack_expect *exp)
include/net/netfilter/nf_conntrack_expect.h
83
return read_pnet(&exp->net);
include/net/netfilter/nf_conntrack_l4proto.h
126
void nf_conntrack_generic_init_net(struct net *net);
include/net/netfilter/nf_conntrack_l4proto.h
127
void nf_conntrack_tcp_init_net(struct net *net);
include/net/netfilter/nf_conntrack_l4proto.h
128
void nf_conntrack_udp_init_net(struct net *net);
include/net/netfilter/nf_conntrack_l4proto.h
129
void nf_conntrack_gre_init_net(struct net *net);
include/net/netfilter/nf_conntrack_l4proto.h
130
void nf_conntrack_sctp_init_net(struct net *net);
include/net/netfilter/nf_conntrack_l4proto.h
131
void nf_conntrack_icmp_init_net(struct net *net);
include/net/netfilter/nf_conntrack_l4proto.h
132
void nf_conntrack_icmpv6_init_net(struct net *net);
include/net/netfilter/nf_conntrack_l4proto.h
173
static inline struct nf_generic_net *nf_generic_pernet(struct net *net)
include/net/netfilter/nf_conntrack_l4proto.h
175
return &net->ct.nf_ct_proto.generic;
include/net/netfilter/nf_conntrack_l4proto.h
178
static inline struct nf_tcp_net *nf_tcp_pernet(struct net *net)
include/net/netfilter/nf_conntrack_l4proto.h
180
return &net->ct.nf_ct_proto.tcp;
include/net/netfilter/nf_conntrack_l4proto.h
183
static inline struct nf_udp_net *nf_udp_pernet(struct net *net)
include/net/netfilter/nf_conntrack_l4proto.h
185
return &net->ct.nf_ct_proto.udp;
include/net/netfilter/nf_conntrack_l4proto.h
188
static inline struct nf_icmp_net *nf_icmp_pernet(struct net *net)
include/net/netfilter/nf_conntrack_l4proto.h
190
return &net->ct.nf_ct_proto.icmp;
include/net/netfilter/nf_conntrack_l4proto.h
193
static inline struct nf_icmp_net *nf_icmpv6_pernet(struct net *net)
include/net/netfilter/nf_conntrack_l4proto.h
195
return &net->ct.nf_ct_proto.icmpv6;
include/net/netfilter/nf_conntrack_l4proto.h
214
static inline struct nf_sctp_net *nf_sctp_pernet(struct net *net)
include/net/netfilter/nf_conntrack_l4proto.h
216
return &net->ct.nf_ct_proto.sctp;
include/net/netfilter/nf_conntrack_l4proto.h
221
static inline struct nf_gre_net *nf_gre_pernet(struct net *net)
include/net/netfilter/nf_conntrack_l4proto.h
223
return &net->ct.nf_ct_proto.gre;
include/net/netfilter/nf_conntrack_l4proto.h
51
struct net *net, void *data);
include/net/netfilter/nf_conntrack_l4proto.h
66
struct net *net,
include/net/netfilter/nf_conntrack_l4proto.h
71
struct net *net,
include/net/netfilter/nf_conntrack_labels.h
40
struct net *net = nf_ct_net(ct);
include/net/netfilter/nf_conntrack_labels.h
42
if (atomic_read(&net->ct.labels_used) == 0)
include/net/netfilter/nf_conntrack_labels.h
55
int nf_connlabels_get(struct net *net, unsigned int bit);
include/net/netfilter/nf_conntrack_labels.h
56
void nf_connlabels_put(struct net *net);
include/net/netfilter/nf_conntrack_labels.h
58
static inline int nf_connlabels_get(struct net *net, unsigned int bit) { return 0; }
include/net/netfilter/nf_conntrack_labels.h
59
static inline void nf_connlabels_put(struct net *net) {}
include/net/netfilter/nf_conntrack_timeout.h
108
void nf_ct_untimeout(struct net *net, struct nf_ct_timeout *timeout);
include/net/netfilter/nf_conntrack_timeout.h
109
int nf_ct_set_timeout(struct net *net, struct nf_conn *ct, u8 l3num, u8 l4num,
include/net/netfilter/nf_conntrack_timeout.h
113
static inline int nf_ct_set_timeout(struct net *net, struct nf_conn *ct,
include/net/netfilter/nf_conntrack_timeout.h
128
struct nf_ct_timeout *(*timeout_find_get)(struct net *net, const char *name);
include/net/netfilter/nf_conntrack_timestamp.h
30
struct net *net = nf_ct_net(ct);
include/net/netfilter/nf_conntrack_timestamp.h
32
if (!net->ct.sysctl_tstamp)
include/net/netfilter/nf_conntrack_timestamp.h
42
void nf_conntrack_tstamp_pernet_init(struct net *net);
include/net/netfilter/nf_conntrack_timestamp.h
44
static inline void nf_conntrack_tstamp_pernet_init(struct net *net) {}
include/net/netfilter/nf_flow_table.h
374
int nf_flow_rule_route_ipv4(struct net *net, struct flow_offload *flow,
include/net/netfilter/nf_flow_table.h
377
int nf_flow_rule_route_ipv6(struct net *net, struct flow_offload *flow,
include/net/netfilter/nf_flow_table.h
410
#define NF_FLOW_TABLE_STAT_INC(net, count) __this_cpu_inc((net)->ft.stat->count)
include/net/netfilter/nf_flow_table.h
411
#define NF_FLOW_TABLE_STAT_DEC(net, count) __this_cpu_dec((net)->ft.stat->count)
include/net/netfilter/nf_flow_table.h
412
#define NF_FLOW_TABLE_STAT_INC_ATOMIC(net, count) \
include/net/netfilter/nf_flow_table.h
413
this_cpu_inc((net)->ft.stat->count)
include/net/netfilter/nf_flow_table.h
414
#define NF_FLOW_TABLE_STAT_DEC_ATOMIC(net, count) \
include/net/netfilter/nf_flow_table.h
415
this_cpu_dec((net)->ft.stat->count)
include/net/netfilter/nf_flow_table.h
418
int nf_flow_table_init_proc(struct net *net);
include/net/netfilter/nf_flow_table.h
419
void nf_flow_table_fini_proc(struct net *net);
include/net/netfilter/nf_flow_table.h
421
static inline int nf_flow_table_init_proc(struct net *net)
include/net/netfilter/nf_flow_table.h
426
static inline void nf_flow_table_fini_proc(struct net *net)
include/net/netfilter/nf_flow_table.h
60
int (*action)(struct net *net,
include/net/netfilter/nf_flow_table.h
86
possible_net_t net;
include/net/netfilter/nf_log.h
39
typedef void nf_logfn(struct net *net,
include/net/netfilter/nf_log.h
65
int nf_log_set(struct net *net, u_int8_t pf, const struct nf_logger *logger);
include/net/netfilter/nf_log.h
66
void nf_log_unset(struct net *net, const struct nf_logger *logger);
include/net/netfilter/nf_log.h
68
int nf_log_bind_pf(struct net *net, u_int8_t pf,
include/net/netfilter/nf_log.h
70
void nf_log_unbind_pf(struct net *net, u_int8_t pf);
include/net/netfilter/nf_log.h
80
void nf_log_packet(struct net *net,
include/net/netfilter/nf_log.h
90
void nf_log_trace(struct net *net,
include/net/netfilter/nf_nat.h
100
int nf_nat_inet_register_fn(struct net *net, const struct nf_hook_ops *ops);
include/net/netfilter/nf_nat.h
101
void nf_nat_inet_unregister_fn(struct net *net, const struct nf_hook_ops *ops);
include/net/netfilter/nf_nat.h
71
int nf_nat_register_fn(struct net *net, u8 pf, const struct nf_hook_ops *ops,
include/net/netfilter/nf_nat.h
73
void nf_nat_unregister_fn(struct net *net, u8 pf, const struct nf_hook_ops *ops,
include/net/netfilter/nf_nat.h
94
int nf_nat_ipv4_register_fn(struct net *net, const struct nf_hook_ops *ops);
include/net/netfilter/nf_nat.h
95
void nf_nat_ipv4_unregister_fn(struct net *net, const struct nf_hook_ops *ops);
include/net/netfilter/nf_nat.h
97
int nf_nat_ipv6_register_fn(struct net *net, const struct nf_hook_ops *ops);
include/net/netfilter/nf_nat.h
98
void nf_nat_ipv6_unregister_fn(struct net *net, const struct nf_hook_ops *ops);
include/net/netfilter/nf_queue.h
38
void (*nf_hook_drop)(struct net *net);
include/net/netfilter/nf_socket.h
10
struct sock *nf_sk_lookup_slow_v6(struct net *net, const struct sk_buff *skb,
include/net/netfilter/nf_socket.h
7
struct sock *nf_sk_lookup_slow_v4(struct net *net, const struct sk_buff *skb,
include/net/netfilter/nf_synproxy.h
30
static inline struct synproxy_net *synproxy_pernet(struct net *net)
include/net/netfilter/nf_synproxy.h
32
return net_generic(net, synproxy_net_id);
include/net/netfilter/nf_synproxy.h
52
void synproxy_send_client_synack(struct net *net, const struct sk_buff *skb,
include/net/netfilter/nf_synproxy.h
56
bool synproxy_recv_client_ack(struct net *net,
include/net/netfilter/nf_synproxy.h
65
int nf_synproxy_ipv4_init(struct synproxy_net *snet, struct net *net);
include/net/netfilter/nf_synproxy.h
66
void nf_synproxy_ipv4_fini(struct synproxy_net *snet, struct net *net);
include/net/netfilter/nf_synproxy.h
69
void synproxy_send_client_synack_ipv6(struct net *net,
include/net/netfilter/nf_synproxy.h
74
bool synproxy_recv_client_ack_ipv6(struct net *net, const struct sk_buff *skb,
include/net/netfilter/nf_synproxy.h
80
int nf_synproxy_ipv6_init(struct synproxy_net *snet, struct net *net);
include/net/netfilter/nf_synproxy.h
81
void nf_synproxy_ipv6_fini(struct synproxy_net *snet, struct net *net);
include/net/netfilter/nf_synproxy.h
84
nf_synproxy_ipv6_init(struct synproxy_net *snet, struct net *net) { return 0; }
include/net/netfilter/nf_synproxy.h
86
nf_synproxy_ipv6_fini(struct synproxy_net *snet, struct net *net) {};
include/net/netfilter/nf_tables.h
1185
int (*ops_register)(struct net *net, const struct nf_hook_ops *ops);
include/net/netfilter/nf_tables.h
1186
void (*ops_unregister)(struct net *net, const struct nf_hook_ops *ops);
include/net/netfilter/nf_tables.h
1402
struct nft_object *nft_obj_lookup(const struct net *net,
include/net/netfilter/nf_tables.h
1407
void nft_obj_notify(struct net *net, const struct nft_table *table,
include/net/netfilter/nf_tables.h
1497
struct nft_flowtable *nft_flowtable_lookup(const struct net *net,
include/net/netfilter/nf_tables.h
1562
static inline unsigned int nft_gencursor_next(const struct net *net)
include/net/netfilter/nf_tables.h
1564
return net->nft.gencursor + 1 == 1 ? 1 : 0;
include/net/netfilter/nf_tables.h
1567
static inline u8 nft_genmask_next(const struct net *net)
include/net/netfilter/nf_tables.h
1569
return 1 << nft_gencursor_next(net);
include/net/netfilter/nf_tables.h
1572
static inline u8 nft_genmask_cur(const struct net *net)
include/net/netfilter/nf_tables.h
1575
return 1 << READ_ONCE(net->nft.gencursor);
include/net/netfilter/nf_tables.h
1616
static inline void nft_set_elem_change_active(const struct net *net,
include/net/netfilter/nf_tables.h
1620
ext->genmask ^= nft_genmask_next(net);
include/net/netfilter/nf_tables.h
1668
struct net *net;
include/net/netfilter/nf_tables.h
1864
struct net *net;
include/net/netfilter/nf_tables.h
1896
ctx->net = trans->net;
include/net/netfilter/nf_tables.h
1921
void nft_setelem_data_deactivate(const struct net *net,
include/net/netfilter/nf_tables.h
1931
void nf_tables_trans_destroy_flush_work(struct net *net);
include/net/netfilter/nf_tables.h
1937
__printf(2, 3) int nft_request_module(struct net *net, const char *fmt, ...);
include/net/netfilter/nf_tables.h
1939
static inline int nft_request_module(struct net *net, const char *fmt, ...) { return -ENOENT; }
include/net/netfilter/nf_tables.h
1960
static inline struct nftables_pernet *nft_pernet(const struct net *net)
include/net/netfilter/nf_tables.h
1962
return net_generic(net, nf_tables_net_id);
include/net/netfilter/nf_tables.h
1965
static inline u64 nft_net_tstamp(const struct net *net)
include/net/netfilter/nf_tables.h
1967
return nft_pernet(net)->tstamp;
include/net/netfilter/nf_tables.h
214
struct net *net;
include/net/netfilter/nf_tables.h
462
const struct nft_set_ext * (*lookup)(const struct net *net,
include/net/netfilter/nf_tables.h
472
int (*insert)(const struct net *net,
include/net/netfilter/nf_tables.h
476
void (*activate)(const struct net *net,
include/net/netfilter/nf_tables.h
479
struct nft_elem_priv * (*deactivate)(const struct net *net,
include/net/netfilter/nf_tables.h
482
void (*flush)(const struct net *net,
include/net/netfilter/nf_tables.h
485
void (*remove)(const struct net *net,
include/net/netfilter/nf_tables.h
491
struct nft_elem_priv * (*get)(const struct net *net,
include/net/netfilter/nf_tables.h
51
static inline struct net *nft_net(const struct nft_pktinfo *pkt)
include/net/netfilter/nf_tables.h
53
return pkt->state->net;
include/net/netfilter/nf_tables.h
586
possible_net_t net;
include/net/netfilter/nf_tables.h
644
struct nft_set *nft_set_lookup_global(const struct net *net,
include/net/netfilter/nf_tables.h
650
struct nft_set_ext *nft_set_catchall_lookup(const struct net *net,
include/net/netfilter/nf_tables.h
975
bool (*gc)(struct net *net,
include/net/netfilter/nf_tables_core.h
101
nft_rbtree_lookup(const struct net *net, const struct nft_set *set,
include/net/netfilter/nf_tables_core.h
104
nft_bitmap_lookup(const struct net *net, const struct nft_set *set,
include/net/netfilter/nf_tables_core.h
107
nft_hash_lookup_fast(const struct net *net, const struct nft_set *set,
include/net/netfilter/nf_tables_core.h
110
nft_hash_lookup(const struct net *net, const struct nft_set *set,
include/net/netfilter/nf_tables_core.h
115
nft_set_do_lookup(const struct net *net, const struct nft_set *set,
include/net/netfilter/nf_tables_core.h
120
nft_pipapo_lookup(const struct net *net, const struct nft_set *set,
include/net/netfilter/nf_tables_core.h
124
nft_pipapo_avx2_lookup(const struct net *net, const struct nft_set *set,
include/net/netfilter/nf_tables_core.h
98
nft_rhash_lookup(const struct net *net, const struct nft_set *set,
include/net/netfilter/nf_tables_offload.h
34
struct net *net;
include/net/netfilter/nf_tables_offload.h
84
struct nft_flow_rule *nft_flow_rule_create(struct net *net, const struct nft_rule *rule);
include/net/netfilter/nf_tables_offload.h
87
int nft_flow_rule_offload_commit(struct net *net);
include/net/netfilter/nf_tproxy.h
116
struct net *net,
include/net/netfilter/nf_tproxy.h
122
nf_tproxy_get_sock_v6(struct net *net, struct sk_buff *skb, int thoff,
include/net/netfilter/nf_tproxy.h
56
nf_tproxy_handle_time_wait4(struct net *net, struct sk_buff *skb,
include/net/netfilter/nf_tproxy.h
83
nf_tproxy_get_sock_v4(struct net *net, struct sk_buff *skb,
include/net/netfilter/xt_rateest.h
24
struct xt_rateest *xt_rateest_lookup(struct net *net, const char *name);
include/net/netfilter/xt_rateest.h
25
void xt_rateest_put(struct net *net, struct xt_rateest *est);
include/net/netlabel.h
417
int netlbl_cfg_unlbl_static_add(struct net *net,
include/net/netlabel.h
424
int netlbl_cfg_unlbl_static_del(struct net *net,
include/net/netlabel.h
527
static inline int netlbl_cfg_unlbl_static_add(struct net *net,
include/net/netlabel.h
537
static inline int netlbl_cfg_unlbl_static_del(struct net *net,
include/net/netlink.h
495
struct net *nl_net;
include/net/netns/generic.h
40
static inline void *net_generic(const struct net *net, unsigned int id)
include/net/netns/generic.h
46
ng = rcu_dereference(net->gen);
include/net/netns/hash.h
7
static inline u32 net_hash_mix(const struct net *net)
include/net/netns/hash.h
9
return net->hash_mix;
include/net/nexthop.h
148
struct net *net;
include/net/nexthop.h
234
struct net *net;
include/net/nexthop.h
247
int register_nexthop_notifier(struct net *net, struct notifier_block *nb,
include/net/nexthop.h
249
int __unregister_nexthop_notifier(struct net *net, struct notifier_block *nb);
include/net/nexthop.h
250
int unregister_nexthop_notifier(struct net *net, struct notifier_block *nb);
include/net/nexthop.h
251
void nexthop_set_hw_flags(struct net *net, u32 id, bool offload, bool trap);
include/net/nexthop.h
252
void nexthop_bucket_set_hw_flags(struct net *net, u32 id, u16 bucket_index,
include/net/nexthop.h
254
void nexthop_res_grp_activity_update(struct net *net, u32 id, u16 num_buckets,
include/net/nexthop.h
261
struct nexthop *nexthop_find_by_id(struct net *net, u32 id);
include/net/nexthop.h
83
struct net *net;
include/net/phonet/phonet.h
42
struct sock *pn_find_sock_by_sa(struct net *net, const struct sockaddr_pn *sa);
include/net/phonet/phonet.h
43
void pn_deliver_sock_broadcast(struct net *net, struct sk_buff *skb);
include/net/phonet/phonet.h
49
struct sock *pn_find_sock_by_res(struct net *net, u8 res);
include/net/phonet/pn_dev.h
16
struct net;
include/net/phonet/pn_dev.h
23
struct phonet_device_list *phonet_device_list(struct net *net);
include/net/phonet/pn_dev.h
35
struct net_device *phonet_device_get(struct net *net);
include/net/phonet/pn_dev.h
40
int phonet_address_lookup(struct net *net, u8 addr);
include/net/phonet/pn_dev.h
41
void phonet_address_notify(struct net *net, int event, u32 ifindex, u8 addr);
include/net/phonet/pn_dev.h
45
void rtm_phonet_notify(struct net *net, int event, u32 ifindex, u8 dst);
include/net/phonet/pn_dev.h
46
struct net_device *phonet_route_get_rcu(struct net *net, u8 daddr);
include/net/phonet/pn_dev.h
47
struct net_device *phonet_route_output(struct net *net, u8 daddr);
include/net/ping.h
33
int (*ipv6_chk_addr)(struct net *net, const struct in6_addr *addr,
include/net/pkt_cls.h
242
struct net *net;
include/net/pkt_cls.h
253
static inline int tcf_exts_init(struct tcf_exts *exts, struct net *net,
include/net/pkt_cls.h
257
return tcf_exts_init_ex(exts, net, action, police, NULL, 0, false);
include/net/pkt_cls.h
270
exts->net = maybe_get_net(exts->net);
include/net/pkt_cls.h
271
if (exts->net)
include/net/pkt_cls.h
272
netns_tracker_alloc(exts->net, &exts->ns_tracker, GFP_KERNEL);
include/net/pkt_cls.h
273
return exts->net != NULL;
include/net/pkt_cls.h
282
if (exts->net)
include/net/pkt_cls.h
283
put_net_track(exts->net, &exts->ns_tracker);
include/net/pkt_cls.h
378
int tcf_exts_validate(struct net *net, struct tcf_proto *tp,
include/net/pkt_cls.h
382
int tcf_exts_validate_ex(struct net *net, struct tcf_proto *tp, struct nlattr **tb,
include/net/pkt_cls.h
422
struct net *net;
include/net/pkt_cls.h
486
int (*change)(struct net *net, void *,
include/net/pkt_cls.h
568
tcf_change_indev(struct net *net, struct nlattr *indev_tlv,
include/net/pkt_cls.h
579
dev = __dev_get_by_name(net, indev);
include/net/pkt_cls.h
64
int tcf_exts_init_ex(struct tcf_exts *exts, struct net *net, int action,
include/net/pkt_sched.h
136
static inline struct net *qdisc_net(struct Qdisc *q)
include/net/psample.h
10
struct net *net;
include/net/psample.h
33
struct psample_group *psample_group_get(struct net *net, u32 group_num);
include/net/psp/functions.h
20
bool psp_dev_encapsulate(struct net *net, struct sk_buff *skb, __be32 spi,
include/net/raw.h
25
bool raw_v4_match(struct net *net, const struct sock *sk, unsigned short num,
include/net/raw.h
43
static inline u32 raw_hashfunc(const struct net *net, u32 proto)
include/net/raw.h
45
return hash_32(net_hash_mix(net) ^ proto, RAW_HTABLE_LOG);
include/net/raw.h
89
static inline bool raw_sk_bound_dev_eq(struct net *net, int bound_dev_if,
include/net/raw.h
93
return inet_bound_dev_eq(READ_ONCE(net->ipv4.sysctl_raw_l3mdev_accept),
include/net/rawv6.h
9
bool raw_v6_match(struct net *net, const struct sock *sk, unsigned short num,
include/net/route.h
131
void rt_cache_flush(struct net *net);
include/net/route.h
160
struct rtable *ip_route_output_key_hash(struct net *net, struct flowi4 *flp,
include/net/route.h
162
struct rtable *ip_route_output_key_hash_rcu(struct net *net, struct flowi4 *flp,
include/net/route.h
166
static inline struct rtable *__ip_route_output_key(struct net *net,
include/net/route.h
169
return ip_route_output_key_hash(net, flp, NULL);
include/net/route.h
172
struct rtable *ip_route_output_flow(struct net *, struct flowi4 *flp,
include/net/route.h
174
struct dst_entry *ipv4_blackhole_route(struct net *net,
include/net/route.h
177
static inline struct rtable *ip_route_output_key(struct net *net, struct flowi4 *flp)
include/net/route.h
179
return ip_route_output_flow(net, flp, NULL);
include/net/route.h
186
static inline struct rtable *ip_route_output(struct net *net, __be32 daddr,
include/net/route.h
198
return ip_route_output_key(net, &fl4);
include/net/route.h
201
static inline struct rtable *ip_route_output_ports(struct net *net, struct flowi4 *fl4,
include/net/route.h
210
daddr, saddr, dport, sport, sock_net_uid(net, sk));
include/net/route.h
213
return ip_route_output_flow(net, fl4, sk);
include/net/route.h
246
void ipv4_update_pmtu(struct sk_buff *skb, struct net *net, u32 mtu, int oif,
include/net/route.h
249
void ipv4_redirect(struct sk_buff *skb, struct net *net, int oif, u8 protocol);
include/net/route.h
253
unsigned int inet_addr_type(struct net *net, __be32 addr);
include/net/route.h
254
unsigned int inet_addr_type_table(struct net *net, __be32 addr, u32 tb_id);
include/net/route.h
255
unsigned int inet_dev_addr_type(struct net *net, const struct net_device *dev,
include/net/route.h
257
unsigned int inet_addr_type_dev_table(struct net *net,
include/net/route.h
261
int ip_rt_ioctl(struct net *, unsigned int cmd, struct rtentry *rt);
include/net/route.h
342
struct net *net = sock_net(sk);
include/net/route.h
348
rt = __ip_route_output_key(net, fl4);
include/net/route.h
355
return ip_route_output_flow(net, fl4, sk);
include/net/route.h
390
const struct net *net;
include/net/route.h
393
net = dst_dev_net_rcu(dst);
include/net/route.h
394
hoplimit = READ_ONCE(net->ipv4.sysctl_ip_default_ttl);
include/net/rtnetlink.h
101
static inline struct net *rtnl_newlink_peer_net(struct rtnl_newlink_params *p)
include/net/rtnetlink.h
194
struct net *(*get_link_net)(const struct net_device *dev);
include/net/rtnetlink.h
246
struct net *rtnl_link_get_net(struct net *src_net, struct nlattr *tb[]);
include/net/rtnetlink.h
247
struct net_device *rtnl_create_link(struct net *net, const char *ifname,
include/net/rtnetlink.h
258
struct net *rtnl_get_net_ns_capable(struct sock *sk, int netnsid);
include/net/rtnetlink.h
260
const struct net *link_net);
include/net/rtnetlink.h
82
struct net *src_net;
include/net/rtnetlink.h
83
struct net *link_net;
include/net/rtnetlink.h
84
struct net *peer_net;
include/net/rtnetlink.h
93
static inline struct net *rtnl_newlink_link_net(struct rtnl_newlink_params *p)
include/net/sch_generic.h
370
int (*change)(struct net *net, struct sk_buff *,
include/net/sch_generic.h
390
void * (*tmplt_create)(struct net *net,
include/net/sch_generic.h
403
int (*dump)(struct net*, struct tcf_proto*, void *,
include/net/sch_generic.h
406
int (*terse_dump)(struct net *net,
include/net/sch_generic.h
411
struct net *net,
include/net/sch_generic.h
495
struct net *net;
include/net/sch_generic.h
514
struct tcf_block *tcf_block_lookup(struct net *net, u32 block_index);
include/net/sctp/sctp.h
105
struct sctp_transport *sctp_transport_get_next(struct net *net,
include/net/sctp/sctp.h
107
struct sctp_transport *sctp_transport_get_idx(struct net *net,
include/net/sctp/sctp.h
109
int sctp_transport_lookup_process(sctp_callback_t cb, struct net *net,
include/net/sctp/sctp.h
113
struct net *net, int *pos, void *p);
include/net/sctp/sctp.h
115
struct net *net, int *pos, void *p);
include/net/sctp/sctp.h
122
int sctp_primitive_ASSOCIATE(struct net *, struct sctp_association *, void *arg);
include/net/sctp/sctp.h
123
int sctp_primitive_SHUTDOWN(struct net *, struct sctp_association *, void *arg);
include/net/sctp/sctp.h
124
int sctp_primitive_ABORT(struct net *, struct sctp_association *, void *arg);
include/net/sctp/sctp.h
125
int sctp_primitive_SEND(struct net *, struct sctp_association *, void *arg);
include/net/sctp/sctp.h
126
int sctp_primitive_REQUESTHEARTBEAT(struct net *, struct sctp_association *, void *arg);
include/net/sctp/sctp.h
127
int sctp_primitive_ASCONF(struct net *, struct sctp_association *, void *arg);
include/net/sctp/sctp.h
128
int sctp_primitive_RECONF(struct net *net, struct sctp_association *asoc,
include/net/sctp/sctp.h
138
struct sock *sctp_err_lookup(struct net *net, int family, struct sk_buff *,
include/net/sctp/sctp.h
156
struct net *net,
include/net/sctp/sctp.h
163
bool sctp_sk_bound_dev_eq(struct net *net, int bound_dev_if, int dif, int sdif);
include/net/sctp/sctp.h
168
int __net_init sctp_proc_init(struct net *net);
include/net/sctp/sctp.h
207
#define SCTP_INC_STATS(net, field) SNMP_INC_STATS((net)->sctp.sctp_statistics, field)
include/net/sctp/sctp.h
208
#define __SCTP_INC_STATS(net, field) __SNMP_INC_STATS((net)->sctp.sctp_statistics, field)
include/net/sctp/sctp.h
209
#define SCTP_DEC_STATS(net, field) SNMP_DEC_STATS((net)->sctp.sctp_statistics, field)
include/net/sctp/sctp.h
298
void sctp_dbg_objcnt_init(struct net *);
include/net/sctp/sctp.h
305
static inline void sctp_dbg_objcnt_init(struct net *net) { return; }
include/net/sctp/sctp.h
312
int sctp_sysctl_net_register(struct net *net);
include/net/sctp/sctp.h
313
void sctp_sysctl_net_unregister(struct net *net);
include/net/sctp/sctp.h
317
static inline int sctp_sysctl_net_register(struct net *net) { return 0; }
include/net/sctp/sctp.h
318
static inline void sctp_sysctl_net_unregister(struct net *net) { return; }
include/net/sctp/sctp.h
494
static inline int sctp_phashfn(struct net *net, __u16 lport)
include/net/sctp/sctp.h
496
return (net_hash_mix(net) + lport) & (sctp_port_hashsize - 1);
include/net/sctp/sctp.h
500
static inline int sctp_ep_hashfn(struct net *net, __u16 lport)
include/net/sctp/sctp.h
502
return (net_hash_mix(net) + lport) & (sctp_ep_hashsize - 1);
include/net/sctp/sctp.h
77
int sctp_copy_local_addr_list(struct net *net, struct sctp_bind_addr *addr,
include/net/sctp/sctp.h
81
void sctp_addr_wq_mgmt(struct net *, struct sctp_sockaddr_entry *, int);
include/net/sctp/sctp.h
82
int sctp_udp_sock_start(struct net *net);
include/net/sctp/sctp.h
83
void sctp_udp_sock_stop(struct net *net);
include/net/sctp/sm.h
160
struct net *net,
include/net/sctp/sm.h
303
int sctp_do_sm(struct net *net, enum sctp_event_type event_type,
include/net/sctp/sm.h
54
struct net *net,
include/net/sctp/structs.h
1176
int sctp_bind_addr_copy(struct net *net, struct sctp_bind_addr *dest,
include/net/sctp/structs.h
1205
int sctp_in_scope(struct net *net, const union sctp_addr *addr,
include/net/sctp/structs.h
1248
struct net *net;
include/net/sctp/structs.h
1352
struct net *net,
include/net/sctp/structs.h
1355
bool sctp_has_association(struct net *net, const union sctp_addr *laddr,
include/net/sctp/structs.h
1358
int sctp_verify_init(struct net *net, const struct sctp_endpoint *ep,
include/net/sctp/structs.h
89
struct net *net;
include/net/sctp/structs.h
990
struct sctp_transport *sctp_transport_new(struct net *, const union sctp_addr *,
include/net/sctp/ulpevent.h
142
struct net *net, struct sk_buff_head *queue,
include/net/secure_seq.h
22
secure_tcp_seq_and_ts_off(const struct net *net, __be32 saddr, __be32 daddr,
include/net/secure_seq.h
37
secure_tcpv6_seq_and_ts_off(const struct net *net, const __be32 *saddr,
include/net/secure_seq.h
7
struct net;
include/net/secure_seq.h
8
extern struct net init_net;
include/net/seg6.h
44
static inline struct seg6_pernet_data *seg6_pernet(struct net *net)
include/net/seg6.h
47
return net->ipv6.seg6_data;
include/net/seg6_hmac.h
45
extern struct seg6_hmac_info *seg6_hmac_info_lookup(struct net *net, u32 key);
include/net/seg6_hmac.h
46
extern int seg6_hmac_info_add(struct net *net, u32 key,
include/net/seg6_hmac.h
48
extern int seg6_hmac_info_del(struct net *net, u32 key);
include/net/seg6_hmac.h
49
extern int seg6_push_hmac(struct net *net, struct in6_addr *saddr,
include/net/seg6_hmac.h
53
extern int seg6_hmac_net_init(struct net *net);
include/net/seg6_hmac.h
54
extern void seg6_hmac_net_exit(struct net *net);
include/net/seg6_hmac.h
56
static inline int seg6_hmac_net_init(struct net *net) { return 0; }
include/net/seg6_hmac.h
57
static inline void seg6_hmac_net_exit(struct net *net) {}
include/net/sock.h
105
struct net;
include/net/sock.h
1483
static inline void sock_prot_inuse_add(const struct net *net,
include/net/sock.h
1486
this_cpu_add(net->core.prot_inuse->val[prot->inuse_idx], val);
include/net/sock.h
1489
static inline void sock_inuse_add(const struct net *net, int val)
include/net/sock.h
1491
this_cpu_add(net->core.prot_inuse->all, val);
include/net/sock.h
1494
int sock_prot_inuse_get(struct net *net, struct proto *proto);
include/net/sock.h
1495
int sock_inuse_get(struct net *net);
include/net/sock.h
1497
static inline void sock_prot_inuse_add(const struct net *net,
include/net/sock.h
1502
static inline void sock_inuse_add(const struct net *net, int val)
include/net/sock.h
1839
struct sock *sk_alloc(struct net *net, int family, gfp_t priority,
include/net/sock.h
2168
static inline kuid_t sock_net_uid(const struct net *net, const struct sock *sk)
include/net/sock.h
2170
return sk ? sk_uid(sk) : make_kuid(net->user_ns, 0);
include/net/sock.h
711
struct net *sock_net(const struct sock *sk)
include/net/sock.h
717
void sock_net_set(struct sock *sk, struct net *net)
include/net/sock.h
719
write_pnet(&sk->sk_net, net);
include/net/tc_act/tc_connmark.h
8
struct net *net;
include/net/tc_act/tc_ctinfo.h
9
struct net *net;
include/net/tcp.h
1398
int tcp_set_default_congestion_control(struct net *net, const char *name);
include/net/tcp.h
1399
void tcp_get_default_congestion_control(struct net *net, char *name);
include/net/tcp.h
1844
struct net *net = sock_net((struct sock *)tp);
include/net/tcp.h
1852
return val ? : READ_ONCE(net->ipv4.sysctl_tcp_keepalive_intvl);
include/net/tcp.h
1857
struct net *net = sock_net((struct sock *)tp);
include/net/tcp.h
1863
return val ? : READ_ONCE(net->ipv4.sysctl_tcp_keepalive_time);
include/net/tcp.h
1868
struct net *net = sock_net((struct sock *)tp);
include/net/tcp.h
1876
return val ? : READ_ONCE(net->ipv4.sysctl_tcp_keepalive_probes);
include/net/tcp.h
1975
bool tcp_oow_rate_limited(struct net *net, const struct sk_buff *skb,
include/net/tcp.h
1980
static inline void tcp_mib_init(struct net *net)
include/net/tcp.h
1983
TCP_ADD_STATS(net, TCP_MIB_RTOALGORITHM, 1);
include/net/tcp.h
1984
TCP_ADD_STATS(net, TCP_MIB_RTOMIN, TCP_RTO_MIN*1000/HZ);
include/net/tcp.h
1985
TCP_ADD_STATS(net, TCP_MIB_RTOMAX, TCP_RTO_MAX*1000/HZ);
include/net/tcp.h
1986
TCP_ADD_STATS(net, TCP_MIB_MAXCONN, -1);
include/net/tcp.h
2113
void tcp_fastopen_ctx_destroy(struct net *net);
include/net/tcp.h
2114
int tcp_fastopen_reset_cipher(struct net *net, struct sock *sk,
include/net/tcp.h
2116
int tcp_fastopen_get_cipher(struct net *net, struct inet_connection_sock *icsk,
include/net/tcp.h
2123
void tcp_fastopen_init_key_once(struct net *net);
include/net/tcp.h
2452
struct net *net = sock_net((struct sock *)tp);
include/net/tcp.h
2457
return val ?: READ_ONCE(net->ipv4.sysctl_tcp_notsent_lowat);
include/net/tcp.h
2529
const struct net *net,
include/net/tcp.h
2708
static inline struct ip_options_rcu *tcp_v4_save_options(struct net *net,
include/net/tcp.h
2718
if (dopt && __ip_options_echo(net, &dopt->opt, skb, opt)) {
include/net/tcp.h
3088
tcp_v4_init_seq_and_ts_off(const struct net *net,
include/net/tcp.h
3091
tcp_v6_init_seq_and_ts_off(const struct net *net,
include/net/tcp.h
344
#define TCP_INC_STATS(net, field) SNMP_INC_STATS((net)->mib.tcp_statistics, field)
include/net/tcp.h
345
#define __TCP_INC_STATS(net, field) __SNMP_INC_STATS((net)->mib.tcp_statistics, field)
include/net/tcp.h
346
#define TCP_DEC_STATS(net, field) SNMP_DEC_STATS((net)->mib.tcp_statistics, field)
include/net/tcp.h
347
#define TCP_ADD_STATS(net, field, val) SNMP_ADD_STATS((net)->mib.tcp_statistics, field, val)
include/net/tcp.h
534
void tcp_parse_options(const struct net *net, const struct sk_buff *skb,
include/net/tcp.h
707
bool cookie_timestamp_decode(const struct net *net,
include/net/tcp.h
710
static inline bool cookie_ecn_ok(const struct net *net, const struct dst_entry *dst)
include/net/tcp.h
712
return READ_ONCE(net->ipv4.sysctl_tcp_ecn) ||
include/net/tcp.h
729
static inline struct request_sock *cookie_bpf_check(struct net *net, struct sock *sk,
include/net/transp_v6.h
41
int ip6_datagram_send_ctl(struct net *net, struct sock *sk, struct msghdr *msg,
include/net/udp.h
106
const struct net *net,
include/net/udp.h
109
return &table->hash[udp_hashfn(net, num, table->mask)];
include/net/udp.h
317
u32 udp_ehashfn(const struct net *net, const __be32 laddr, const __u16 lport,
include/net/udp.h
344
static inline __be16 udp_flow_src_port(struct net *net, struct sk_buff *skb,
include/net/udp.h
351
inet_get_local_port_range(net, &min, &max);
include/net/udp.h
385
static inline bool udp_sk_bound_dev_eq(const struct net *net, int bound_dev_if,
include/net/udp.h
389
return inet_bound_dev_eq(!!READ_ONCE(net->ipv4.sysctl_udp_l3mdev_accept),
include/net/udp.h
437
struct sock *udp4_lib_lookup(const struct net *net, __be32 saddr, __be16 sport,
include/net/udp.h
439
struct sock *__udp4_lib_lookup(const struct net *net, __be32 saddr,
include/net/udp.h
444
struct sock *udp6_lib_lookup(const struct net *net,
include/net/udp.h
448
struct sock *__udp6_lib_lookup(const struct net *net,
include/net/udp.h
525
#define __UDP_INC_STATS(net, field) \
include/net/udp.h
526
__SNMP_INC_STATS((net)->mib.udp_statistics, field)
include/net/udp.h
527
#define UDP_INC_STATS(net, field) \
include/net/udp.h
528
SNMP_INC_STATS((net)->mib.udp_statistics, field)
include/net/udp.h
529
#define __UDP6_INC_STATS(net, field) \
include/net/udp.h
530
__SNMP_INC_STATS((net)->mib.udp_stats_in6, field)
include/net/udp.h
531
#define UDP6_INC_STATS(net, field) \
include/net/udp.h
532
SNMP_INC_STATS((net)->mib.udp_stats_in6, field)
include/net/udp_tunnel.h
183
struct net *net, int oif,
include/net/udp_tunnel.h
190
struct net *net,
include/net/udp_tunnel.h
211
void udp_tunnel_update_gro_lookup(struct net *net, struct sock *sk, bool add);
include/net/udp_tunnel.h
214
static inline void udp_tunnel_update_gro_lookup(struct net *net,
include/net/udp_tunnel.h
44
int udp_sock_create4(struct net *net, struct udp_port_cfg *cfg,
include/net/udp_tunnel.h
48
int udp_sock_create6(struct net *net, struct udp_port_cfg *cfg,
include/net/udp_tunnel.h
51
static inline int udp_sock_create6(struct net *net, struct udp_port_cfg *cfg,
include/net/udp_tunnel.h
58
static inline int udp_sock_create(struct net *net,
include/net/udp_tunnel.h
63
return udp_sock_create4(net, cfg, sockp);
include/net/udp_tunnel.h
66
return udp_sock_create6(net, cfg, sockp);
include/net/udp_tunnel.h
97
void setup_udp_tunnel_sock(struct net *net, struct sock *sk,
include/net/vxlan.h
296
struct net *net; /* netns for packet i/o */
include/net/vxlan.h
362
struct net_device *vxlan_dev_create(struct net *net, const char *name,
include/net/wext.h
10
int wext_handle_ioctl(struct net *net, unsigned int cmd,
include/net/wext.h
12
int compat_wext_handle_ioctl(struct net *net, unsigned int cmd,
include/net/wext.h
18
static inline int wext_handle_ioctl(struct net *net, unsigned int cmd,
include/net/wext.h
23
static inline int compat_wext_handle_ioctl(struct net *net, unsigned int cmd,
include/net/wext.h
31
int wext_proc_init(struct net *net);
include/net/wext.h
32
void wext_proc_exit(struct net *net);
include/net/wext.h
34
static inline int wext_proc_init(struct net *net)
include/net/wext.h
38
static inline void wext_proc_exit(struct net *net)
include/net/wext.h
7
struct net;
include/net/xfrm.h
1144
struct net *net; /* netns for packet i/o */
include/net/xfrm.h
1269
static inline bool __xfrm_check_nopolicy(struct net *net, struct sk_buff *skb,
include/net/xfrm.h
1272
if (!READ_ONCE(net->xfrm.policy_count[dir]) && !secpath_exists(skb))
include/net/xfrm.h
1273
return READ_ONCE(net->xfrm.policy_default[dir]) == XFRM_USERPOLICY_ACCEPT;
include/net/xfrm.h
1294
struct net *net = dev_net(skb->dev);
include/net/xfrm.h
1319
return __xfrm_check_nopolicy(net, skb, dir) ||
include/net/xfrm.h
1351
int __xfrm_decode_session(struct net *net, struct sk_buff *skb, struct flowi *fl,
include/net/xfrm.h
1354
static inline int xfrm_decode_session(struct net *net, struct sk_buff *skb, struct flowi *fl,
include/net/xfrm.h
1357
return __xfrm_decode_session(net, skb, fl, family, 0);
include/net/xfrm.h
1360
static inline int xfrm_decode_session_reverse(struct net *net, struct sk_buff *skb,
include/net/xfrm.h
1364
return __xfrm_decode_session(net, skb, fl, family, 1);
include/net/xfrm.h
1371
struct net *net = dev_net(skb->dev);
include/net/xfrm.h
1373
if (!READ_ONCE(net->xfrm.policy_count[XFRM_POLICY_OUT]) &&
include/net/xfrm.h
1374
READ_ONCE(net->xfrm.policy_default[XFRM_POLICY_OUT]) == XFRM_USERPOLICY_ACCEPT)
include/net/xfrm.h
1440
static inline int xfrm_decode_session_reverse(struct net *net, struct sk_buff *skb,
include/net/xfrm.h
1664
int xfrm_state_init(struct net *net);
include/net/xfrm.h
1665
void xfrm_state_fini(struct net *net);
include/net/xfrm.h
1687
int xfrm_proc_init(struct net *net);
include/net/xfrm.h
1688
void xfrm_proc_fini(struct net *net);
include/net/xfrm.h
1691
int xfrm_sysctl_init(struct net *net);
include/net/xfrm.h
1693
void xfrm_sysctl_fini(struct net *net);
include/net/xfrm.h
1695
static inline void xfrm_sysctl_fini(struct net *net)
include/net/xfrm.h
1702
int xfrm_state_walk(struct net *net, struct xfrm_state_walk *walk,
include/net/xfrm.h
1704
void xfrm_state_walk_done(struct xfrm_state_walk *walk, struct net *net);
include/net/xfrm.h
1705
struct xfrm_state *xfrm_state_alloc(struct net *net);
include/net/xfrm.h
1713
struct xfrm_state *xfrm_stateonly_find(struct net *net, u32 mark, u32 if_id,
include/net/xfrm.h
1718
struct xfrm_state *xfrm_state_lookup_byspi(struct net *net, __be32 spi,
include/net/xfrm.h
1721
void xfrm_state_update_stats(struct net *net);
include/net/xfrm.h
1739
struct xfrm_state *xfrm_state_lookup(struct net *net, u32 mark,
include/net/xfrm.h
1742
struct xfrm_state *xfrm_input_state_lookup(struct net *net, u32 mark,
include/net/xfrm.h
1746
struct xfrm_state *xfrm_state_lookup_byaddr(struct net *net, u32 mark,
include/net/xfrm.h
1785
struct xfrm_state *xfrm_find_acq_byseq(struct net *net, u32 mark, u32 seq, u32 pcpu_num);
include/net/xfrm.h
1787
int xfrm_state_flush(struct net *net, u8 proto, bool task_valid);
include/net/xfrm.h
1788
int xfrm_dev_state_flush(struct net *net, struct net_device *dev, bool task_valid);
include/net/xfrm.h
1789
int xfrm_dev_policy_flush(struct net *net, struct net_device *dev,
include/net/xfrm.h
1791
void xfrm_sad_getinfo(struct net *net, struct xfrmk_sadinfo *si);
include/net/xfrm.h
1792
void xfrm_spd_getinfo(struct net *net, struct xfrmk_spdinfo *si);
include/net/xfrm.h
1800
int xfrm_trans_queue_net(struct net *net, struct sk_buff *skb,
include/net/xfrm.h
1801
int (*finish)(struct net *, struct sock *,
include/net/xfrm.h
1804
int (*finish)(struct net *, struct sock *,
include/net/xfrm.h
1836
int xfrm4_output(struct net *net, struct sock *sk, struct sk_buff *skb);
include/net/xfrm.h
1856
__be32 xfrm6_tunnel_alloc_spi(struct net *net, xfrm_address_t *saddr);
include/net/xfrm.h
1857
__be32 xfrm6_tunnel_spi_lookup(struct net *net, const xfrm_address_t *saddr);
include/net/xfrm.h
1858
int xfrm6_output(struct net *net, struct sock *sk, struct sk_buff *skb);
include/net/xfrm.h
1880
struct xfrm_policy *xfrm_policy_alloc(struct net *net, gfp_t gfp);
include/net/xfrm.h
1883
int xfrm_policy_walk(struct net *net, struct xfrm_policy_walk *walk,
include/net/xfrm.h
1886
void xfrm_policy_walk_done(struct xfrm_policy_walk *walk, struct net *net);
include/net/xfrm.h
1888
struct xfrm_policy *xfrm_policy_bysel_ctx(struct net *net,
include/net/xfrm.h
1894
struct xfrm_policy *xfrm_policy_byid(struct net *net,
include/net/xfrm.h
1898
int xfrm_policy_flush(struct net *net, u8 type, bool task_valid);
include/net/xfrm.h
1899
void xfrm_policy_hash_rebuild(struct net *net);
include/net/xfrm.h
1904
struct xfrm_state *xfrm_find_acq(struct net *net, const struct xfrm_mark *mark,
include/net/xfrm.h
1914
const struct xfrm_kmaddress *k, struct net *net,
include/net/xfrm.h
1916
struct xfrm_state *xfrm_migrate_state_find(struct xfrm_migrate *m, struct net *net,
include/net/xfrm.h
1920
struct net *net,
include/net/xfrm.h
1928
struct net *net,
include/net/xfrm.h
1932
struct xfrm_kmaddress *k, struct net *net,
include/net/xfrm.h
1940
int km_report(struct net *net, u8 proto, struct xfrm_selector *sel,
include/net/xfrm.h
1992
static inline int xfrm_aevent_is_on(struct net *net)
include/net/xfrm.h
1998
nlsk = rcu_dereference(net->xfrm.nlsk);
include/net/xfrm.h
2005
static inline int xfrm_acquire_is_on(struct net *net)
include/net/xfrm.h
2011
nlsk = rcu_dereference(net->xfrm.nlsk);
include/net/xfrm.h
2124
int xfrm_dev_state_add(struct net *net, struct xfrm_state *x,
include/net/xfrm.h
2127
int xfrm_dev_policy_add(struct net *net, struct xfrm_policy *xp,
include/net/xfrm.h
2196
static inline int xfrm_dev_state_add(struct net *net, struct xfrm_state *x,
include/net/xfrm.h
2211
static inline int xfrm_dev_policy_add(struct net *net, struct xfrm_policy *xp,
include/net/xfrm.h
2373
int xfrm_nat_keepalive_net_init(struct net *net);
include/net/xfrm.h
2374
int xfrm_nat_keepalive_net_fini(struct net *net);
include/net/xfrm.h
325
static inline struct net *xs_net(struct xfrm_state *x)
include/net/xfrm.h
356
struct net *net;
include/net/xfrm.h
360
struct net *net;
include/net/xfrm.h
374
struct net *net;
include/net/xfrm.h
395
struct dst_entry *(*blackhole_route)(struct net *net, struct dst_entry *orig);
include/net/xfrm.h
424
int (*output)(struct net *net, struct sock *sk, struct sk_buff *skb);
include/net/xfrm.h
513
int (*user_init)(struct net *net, struct xfrm_state *x,
include/net/xfrm.h
520
int (*output)(struct net *net, struct sock *sk, struct sk_buff *skb);
include/net/xfrm.h
55
#define XFRM_INC_STATS(net, field) SNMP_INC_STATS((net)->mib.xfrm_statistics, field)
include/net/xfrm.h
56
#define XFRM_ADD_STATS(net, field, val) SNMP_ADD_STATS((net)->mib.xfrm_statistics, field, val)
include/net/xfrm.h
58
#define XFRM_INC_STATS(net, field) ((void)(net))
include/net/xfrm.h
59
#define XFRM_ADD_STATS(net, field, val) ((void)(net))
include/net/xfrm.h
670
static inline struct net *xp_net(const struct xfrm_policy *xp)
include/net/xfrm.h
724
int (*report)(struct net *net, u8 proto, struct xfrm_selector *sel, xfrm_address_t *addr);
include/net/xfrm.h
730
struct net *net,
include/rdma/ib_addr.h
43
struct net *net;
include/rdma/ib_verbs.h
3063
struct ib_device *_ib_alloc_device(size_t size, struct net *net);
include/rdma/ib_verbs.h
3071
#define ib_alloc_device_with_net(drv_struct, member, net) \
include/rdma/ib_verbs.h
3074
struct drv_struct, member)), net), \
include/rdma/ib_verbs.h
5056
const struct net *net);
include/rdma/ib_verbs.h
5059
static inline struct net *rdma_dev_net(struct ib_device *device)
include/rdma/rdma_cm.h
133
__rdma_create_kernel_id(struct net *net, rdma_cm_event_handler event_handler,
include/rdma/rdma_cm.h
157
#define rdma_create_id(net, event_handler, context, ps, qp_type) \
include/rdma/rdma_cm.h
158
__rdma_create_kernel_id(net, event_handler, context, ps, qp_type, \
include/rdma/rdma_netlink.h
106
int rdma_nl_multicast(struct net *net, struct sk_buff *skb,
include/rdma/rdma_netlink.h
87
int rdma_nl_unicast(struct net *net, struct sk_buff *skb, u32 pid);
include/rdma/rdma_netlink.h
96
int rdma_nl_unicast_wait(struct net *net, struct sk_buff *skb, __u32 pid);
include/trace/events/fib6.h
15
TP_PROTO(const struct net *net, const struct fib6_result *res,
include/trace/events/fib6.h
18
TP_ARGS(net, res, table, flp),
include/trace/events/fib6.h
72
if (res->f6i == net->ipv6.fib6_null_entry) {
include/trace/events/handshake.h
105
__entry->netns_ino = net->ns.inum;
include/trace/events/handshake.h
114
const struct net *net, \
include/trace/events/handshake.h
118
TP_ARGS(net, req, sk))
include/trace/events/handshake.h
122
const struct net *net,
include/trace/events/handshake.h
127
TP_ARGS(net, req, sk, fd),
include/trace/events/handshake.h
138
__entry->netns_ino = net->ns.inum;
include/trace/events/handshake.h
147
const struct net *net, \
include/trace/events/handshake.h
152
TP_ARGS(net, req, sk, fd))
include/trace/events/handshake.h
156
const struct net *net,
include/trace/events/handshake.h
161
TP_ARGS(net, req, sk, err),
include/trace/events/handshake.h
172
__entry->netns_ino = net->ns.inum;
include/trace/events/handshake.h
181
const struct net *net, \
include/trace/events/handshake.h
186
TP_ARGS(net, req, sk, err))
include/trace/events/handshake.h
244
const struct net *net,
include/trace/events/handshake.h
249
TP_ARGS(net, req, sk, status),
include/trace/events/handshake.h
260
__entry->netns_ino = net->ns.inum;
include/trace/events/handshake.h
92
const struct net *net,
include/trace/events/handshake.h
96
TP_ARGS(net, req, sk),
include/trace/events/net.h
3
#define TRACE_SYSTEM net
include/uapi/linux/mctp.h
44
unsigned int net;
include/uapi/linux/mctp.h
90
unsigned int net;
kernel/audit.c
1010
if (reply->net)
kernel/audit.c
1011
put_net(reply->net);
kernel/audit.c
1024
netlink_unicast(audit_get_sk(reply->net), reply->skb, reply->portid, 0);
kernel/audit.c
1055
reply->net = get_net(sock_net(NETLINK_CB(request_skb).sk));
kernel/audit.c
119
struct net *net;
kernel/audit.c
1677
static int audit_multicast_bind(struct net *net, int group)
kernel/audit.c
1687
static void audit_multicast_unbind(struct net *net, int group)
kernel/audit.c
1692
static int __net_init audit_net_init(struct net *net)
kernel/audit.c
1702
struct audit_net *aunet = net_generic(net, audit_net_id);
kernel/audit.c
1704
aunet->sk = netlink_kernel_create(net, NETLINK_AUDIT, &cfg);
kernel/audit.c
1715
static void __net_exit audit_net_exit(struct net *net)
kernel/audit.c
1717
struct audit_net *aunet = net_generic(net, audit_net_id);
kernel/audit.c
220
struct net *net;
kernel/audit.c
331
static struct sock *audit_get_sk(const struct net *net)
kernel/audit.c
335
if (!net)
kernel/audit.c
338
aunet = net_generic(net, audit_net_id);
kernel/audit.c
523
put_net(ac->net);
kernel/audit.c
539
static int auditd_set(struct pid *pid, u32 portid, struct net *net,
kernel/audit.c
546
if (!pid || !net)
kernel/audit.c
554
ac_new->net = get_net(net);
kernel/audit.c
733
struct net *net;
kernel/audit.c
752
net = get_net(ac->net);
kernel/audit.c
753
sk = audit_get_sk(net);
kernel/audit.c
758
put_net(net);
kernel/audit.c
887
struct net *net = NULL;
kernel/audit.c
902
net = get_net(ac->net);
kernel/audit.c
903
sk = audit_get_sk(net);
kernel/audit.c
941
if (net) {
kernel/audit.c
942
put_net(net);
kernel/audit.c
943
net = NULL;
kernel/audit.c
964
struct sock *sk = audit_get_sk(dest->net);
kernel/audit.c
973
put_net(dest->net);
kernel/audit.h
248
struct net *net;
kernel/auditfilter.c
1186
dest->net = get_net(sock_net(NETLINK_CB(request_skb).sk));
kernel/auditfilter.c
1197
put_net(dest->net);
kernel/bpf/cgroup.c
2529
const struct net *net = ctx ? sock_net(ctx->sk) : &init_net;
kernel/bpf/cgroup.c
2531
return net->net_cookie;
kernel/bpf/devmap.c
1020
dev = __dev_map_alloc_node(net, dtab, &val, idx);
kernel/bpf/devmap.c
901
static struct bpf_dtab_netdev *__dev_map_alloc_node(struct net *net,
kernel/bpf/devmap.c
915
dev->dev = dev_get_by_index(net, val->ifindex);
kernel/bpf/devmap.c
949
static long __dev_map_update_elem(struct net *net, struct bpf_map *map,
kernel/bpf/devmap.c
973
dev = __dev_map_alloc_node(net, dtab, &val, i);
kernel/bpf/devmap.c
998
static long __dev_map_hash_update_elem(struct net *net, struct bpf_map *map,
kernel/bpf/net_namespace.c
107
struct net *net;
kernel/bpf/net_namespace.c
116
net = net_link->net;
kernel/bpf/net_namespace.c
117
if (!net)
kernel/bpf/net_namespace.c
124
idx = link_index(net, type, net_link);
kernel/bpf/net_namespace.c
127
cnt = link_count(net, type);
kernel/bpf/net_namespace.c
129
netns_bpf_run_array_detach(net, type);
kernel/bpf/net_namespace.c
133
old_array = rcu_dereference_protected(net->bpf.run_array[type],
kernel/bpf/net_namespace.c
140
fill_prog_array(net, type, new_array);
kernel/bpf/net_namespace.c
141
rcu_assign_pointer(net->bpf.run_array[type], new_array);
kernel/bpf/net_namespace.c
145
net_link->net = NULL;
kernel/bpf/net_namespace.c
171
struct net *net;
kernel/bpf/net_namespace.c
181
net = net_link->net;
kernel/bpf/net_namespace.c
182
if (!net || !check_net(net)) {
kernel/bpf/net_namespace.c
188
run_array = rcu_dereference_protected(net->bpf.run_array[type],
kernel/bpf/net_namespace.c
190
idx = link_index(net, type, net_link);
kernel/bpf/net_namespace.c
20
struct net *net;
kernel/bpf/net_namespace.c
209
struct net *net;
kernel/bpf/net_namespace.c
212
net = net_link->net;
kernel/bpf/net_namespace.c
213
if (net && check_net(net))
kernel/bpf/net_namespace.c
214
inum = net->ns.inum;
kernel/bpf/net_namespace.c
247
struct net *net,
kernel/bpf/net_namespace.c
254
run_array = rcu_dereference_protected(net->bpf.run_array[type],
kernel/bpf/net_namespace.c
274
struct net *net;
kernel/bpf/net_namespace.c
284
net = get_net_ns_by_fd(attr->query.target_fd);
kernel/bpf/net_namespace.c
285
if (IS_ERR(net))
kernel/bpf/net_namespace.c
286
return PTR_ERR(net);
kernel/bpf/net_namespace.c
289
ret = __netns_bpf_prog_query(attr, uattr, net, type);
kernel/bpf/net_namespace.c
292
put_net(net);
kernel/bpf/net_namespace.c
301
struct net *net;
kernel/bpf/net_namespace.c
311
net = current->nsproxy->net_ns;
kernel/bpf/net_namespace.c
315
if (!list_empty(&net->bpf.links[type])) {
kernel/bpf/net_namespace.c
322
ret = flow_dissector_bpf_prog_attach_check(net, prog);
kernel/bpf/net_namespace.c
331
attached = net->bpf.progs[type];
kernel/bpf/net_namespace.c
338
run_array = rcu_dereference_protected(net->bpf.run_array[type],
kernel/bpf/net_namespace.c
349
rcu_assign_pointer(net->bpf.run_array[type], run_array);
kernel/bpf/net_namespace.c
352
net->bpf.progs[type] = prog;
kernel/bpf/net_namespace.c
363
static int __netns_bpf_prog_detach(struct net *net,
kernel/bpf/net_namespace.c
370
if (!list_empty(&net->bpf.links[type]))
kernel/bpf/net_namespace.c
373
attached = net->bpf.progs[type];
kernel/bpf/net_namespace.c
376
netns_bpf_run_array_detach(net, type);
kernel/bpf/net_namespace.c
377
net->bpf.progs[type] = NULL;
kernel/bpf/net_namespace.c
420
static int netns_bpf_link_attach(struct net *net, struct bpf_link *link,
kernel/bpf/net_namespace.c
430
cnt = link_count(net, type);
kernel/bpf/net_namespace.c
436
if (net->bpf.progs[type]) {
kernel/bpf/net_namespace.c
443
err = flow_dissector_bpf_prog_attach_check(net, link->prog);
kernel/bpf/net_namespace.c
461
list_add_tail(&net_link->node, &net->bpf.links[type]);
kernel/bpf/net_namespace.c
463
fill_prog_array(net, type, run_array);
kernel/bpf/net_namespace.c
464
run_array = rcu_replace_pointer(net->bpf.run_array[type], run_array,
kernel/bpf/net_namespace.c
482
struct net *net;
kernel/bpf/net_namespace.c
493
net = get_net_ns_by_fd(attr->link_create.target_fd);
kernel/bpf/net_namespace.c
494
if (IS_ERR(net))
kernel/bpf/net_namespace.c
495
return PTR_ERR(net);
kernel/bpf/net_namespace.c
504
net_link->net = net;
kernel/bpf/net_namespace.c
513
err = netns_bpf_link_attach(net, &net_link->link, netns_type);
kernel/bpf/net_namespace.c
519
put_net(net);
kernel/bpf/net_namespace.c
523
put_net(net);
kernel/bpf/net_namespace.c
527
static int __net_init netns_bpf_pernet_init(struct net *net)
kernel/bpf/net_namespace.c
532
INIT_LIST_HEAD(&net->bpf.links[type]);
kernel/bpf/net_namespace.c
537
static void __net_exit netns_bpf_pernet_pre_exit(struct net *net)
kernel/bpf/net_namespace.c
544
netns_bpf_run_array_detach(net, type);
kernel/bpf/net_namespace.c
545
list_for_each_entry(net_link, &net->bpf.links[type], node) {
kernel/bpf/net_namespace.c
546
net_link->net = NULL; /* auto-detach link */
kernel/bpf/net_namespace.c
549
if (net->bpf.progs[type])
kernel/bpf/net_namespace.c
55
static void netns_bpf_run_array_detach(struct net *net,
kernel/bpf/net_namespace.c
550
bpf_prog_put(net->bpf.progs[type]);
kernel/bpf/net_namespace.c
60
run_array = rcu_replace_pointer(net->bpf.run_array[type], NULL,
kernel/bpf/net_namespace.c
65
static int link_index(struct net *net, enum netns_bpf_attach_type type,
kernel/bpf/net_namespace.c
71
list_for_each_entry(pos, &net->bpf.links[type], node) {
kernel/bpf/net_namespace.c
79
static int link_count(struct net *net, enum netns_bpf_attach_type type)
kernel/bpf/net_namespace.c
84
list_for_each(pos, &net->bpf.links[type])
kernel/bpf/net_namespace.c
89
static void fill_prog_array(struct net *net, enum netns_bpf_attach_type type,
kernel/bpf/net_namespace.c
95
list_for_each_entry(pos, &net->bpf.links[type], node) {
kernel/bpf/offload.c
431
struct net *net;
kernel/bpf/offload.c
438
net = maybe_get_net(dev_net(aux->offload->netdev));
kernel/bpf/offload.c
439
ns = net ? &net->ns : NULL;
kernel/bpf/offload.c
505
struct net *net = current->nsproxy->net_ns;
kernel/bpf/offload.c
522
offmap->netdev = __dev_get_by_index(net, attr->map_ifindex);
kernel/bpf/offload.c
642
struct net *net;
kernel/bpf/offload.c
649
net = maybe_get_net(dev_net(args->offmap->netdev));
kernel/bpf/offload.c
650
ns = net ? &net->ns : NULL;
kernel/bpf/tcx.c
125
struct net *net = current->nsproxy->net_ns;
kernel/bpf/tcx.c
13
struct net *net = current->nsproxy->net_ns;
kernel/bpf/tcx.c
130
dev = __dev_get_by_index(net, attr->query.target_ifindex);
kernel/bpf/tcx.c
20
dev = __dev_get_by_index(net, attr->target_ifindex);
kernel/bpf/tcx.c
312
struct net *net = current->nsproxy->net_ns;
kernel/bpf/tcx.c
319
dev = __dev_get_by_index(net, attr->link_create.target_ifindex);
kernel/bpf/tcx.c
62
struct net *net = current->nsproxy->net_ns;
kernel/bpf/tcx.c
68
dev = __dev_get_by_index(net, attr->target_ifindex);
lib/kobject_uevent.c
413
const struct net *net = container_of(ns, struct net, ns);
lib/kobject_uevent.c
415
ret = uevent_net_broadcast_tagged(net->uevent_sock->sk, env,
lib/kobject_uevent.c
746
struct net *net;
lib/kobject_uevent.c
757
net = sock_net(NETLINK_CB(skb).sk);
lib/kobject_uevent.c
758
if (!netlink_ns_capable(skb, net->user_ns, CAP_SYS_ADMIN)) {
lib/kobject_uevent.c
763
ret = uevent_net_broadcast(net->uevent_sock->sk, skb, extack);
lib/kobject_uevent.c
773
static int uevent_net_init(struct net *net)
lib/kobject_uevent.c
786
ue_sk->sk = netlink_kernel_create(net, NETLINK_KOBJECT_UEVENT, &cfg);
lib/kobject_uevent.c
793
net->uevent_sock = ue_sk;
lib/kobject_uevent.c
805
static void uevent_net_exit(struct net *net)
lib/kobject_uevent.c
807
struct uevent_sock *ue_sk = net->uevent_sock;
net/6lowpan/ndisc.c
188
static void lowpan_ndisc_prefix_rcv_add_addr(struct net *net,
net/6lowpan/ndisc.c
204
err = addrconf_prefix_rcv_add_addr(net, dev, pinfo, in6_dev,
net/8021q/vlan.c
220
struct net *net = dev_net(real_dev);
net/8021q/vlan.c
221
struct vlan_net *vn = net_generic(net, vlan_net_id);
net/8021q/vlan.c
265
dev_net_set(new_dev, net);
net/8021q/vlan.c
506
static int vlan_ioctl_handler(struct net *net, void __user *arg)
net/8021q/vlan.c
530
dev = __dev_get_by_name(net, args.device1);
net/8021q/vlan.c
542
if (!ns_capable(net->user_ns, CAP_NET_ADMIN))
net/8021q/vlan.c
552
if (!ns_capable(net->user_ns, CAP_NET_ADMIN))
net/8021q/vlan.c
561
if (!ns_capable(net->user_ns, CAP_NET_ADMIN))
net/8021q/vlan.c
570
if (!ns_capable(net->user_ns, CAP_NET_ADMIN))
net/8021q/vlan.c
575
vn = net_generic(net, vlan_net_id);
net/8021q/vlan.c
585
if (!ns_capable(net->user_ns, CAP_NET_ADMIN))
net/8021q/vlan.c
592
if (!ns_capable(net->user_ns, CAP_NET_ADMIN))
net/8021q/vlan.c
624
static int __net_init vlan_init_net(struct net *net)
net/8021q/vlan.c
626
struct vlan_net *vn = net_generic(net, vlan_net_id);
net/8021q/vlan.c
631
err = vlan_proc_init(net);
net/8021q/vlan.c
636
static void __net_exit vlan_exit_net(struct net *net)
net/8021q/vlan.c
638
vlan_proc_cleanup(net);
net/8021q/vlan_netlink.c
142
struct net *link_net = rtnl_newlink_link_net(params);
net/8021q/vlan_netlink.c
281
static struct net *vlan_get_link_net(const struct net_device *dev)
net/8021q/vlanproc.c
100
remove_proc_entry(name_root, net->proc_net);
net/8021q/vlanproc.c
111
int __net_init vlan_proc_init(struct net *net)
net/8021q/vlanproc.c
113
struct vlan_net *vn = net_generic(net, vlan_net_id);
net/8021q/vlanproc.c
115
vn->proc_vlan_dir = proc_net_mkdir(net, name_root, net->proc_net);
net/8021q/vlanproc.c
128
vlan_proc_cleanup(net);
net/8021q/vlanproc.c
204
struct net *net = seq_file_net(seq);
net/8021q/vlanproc.c
205
struct vlan_net *vn = net_generic(net, vlan_net_id);
net/8021q/vlanproc.c
92
void vlan_proc_cleanup(struct net *net)
net/8021q/vlanproc.c
94
struct vlan_net *vn = net_generic(net, vlan_net_id);
net/8021q/vlanproc.h
11
void vlan_proc_cleanup(struct net *net);
net/8021q/vlanproc.h
15
#define vlan_proc_init(net) (0)
net/8021q/vlanproc.h
16
#define vlan_proc_cleanup(net) do {} while (0)
net/8021q/vlanproc.h
6
struct net;
net/8021q/vlanproc.h
8
int vlan_proc_init(struct net *net);
net/atm/common.c
139
int vcc_create(struct net *net, struct socket *sock, int protocol, int family, int kern)
net/atm/common.c
147
sk = sk_alloc(net, family, GFP_KERNEL, &vcc_proto, kern);
net/atm/common.h
14
int vcc_create(struct net *net, struct socket *sock, int protocol, int family, int kern);
net/atm/pvc.c
132
static int pvc_create(struct net *net, struct socket *sock, int protocol,
net/atm/pvc.c
135
if (net != &init_net)
net/atm/pvc.c
139
return vcc_create(net, sock, protocol, PF_ATMPVC, kern);
net/batman-adv/hard-interface.c
103
static struct net *batadv_getlink_net(const struct net_device *netdev,
net/batman-adv/hard-interface.c
104
struct net *fallback_net)
net/batman-adv/hard-interface.c
127
struct net *net1,
net/batman-adv/hard-interface.c
129
struct net *net2)
net/batman-adv/hard-interface.c
133
const struct net *dev1_parent_net;
net/batman-adv/hard-interface.c
134
const struct net *dev2_parent_net;
net/batman-adv/hard-interface.c
163
struct net *net = dev_net(net_dev);
net/batman-adv/hard-interface.c
165
struct net *parent_net;
net/batman-adv/hard-interface.c
177
parent_net = batadv_getlink_net(net_dev, net);
net/batman-adv/hard-interface.c
180
if (net == parent_net && iflink == net_dev->ifindex)
net/batman-adv/hard-interface.c
184
parent_dev = __dev_get_by_index((struct net *)parent_net, iflink);
net/batman-adv/hard-interface.c
191
if (batadv_mutual_parents(net_dev, net, parent_dev, parent_net))
net/batman-adv/hard-interface.c
232
struct net *real_net;
net/batman-adv/hard-interface.c
233
struct net *net;
net/batman-adv/hard-interface.c
251
net = dev_net(hard_iface->mesh_iface);
net/batman-adv/hard-interface.c
252
real_net = batadv_getlink_net(netdev, net);
net/batman-adv/hard-interface.c
255
if (net == real_net && netdev->ifindex == iflink) {
net/batman-adv/netlink.c
1136
batadv_netlink_get_meshif_from_ifindex(struct net *net, int ifindex)
net/batman-adv/netlink.c
1140
mesh_iface = dev_get_by_index(net, ifindex);
net/batman-adv/netlink.c
1164
batadv_netlink_get_meshif_from_info(struct net *net, struct genl_info *info)
net/batman-adv/netlink.c
1173
return batadv_netlink_get_meshif_from_ifindex(net, ifindex);
net/batman-adv/netlink.c
1205
struct net *net, int ifindex)
net/batman-adv/netlink.c
1210
hard_dev = dev_get_by_index(net, ifindex);
net/batman-adv/netlink.c
1245
struct net *net, struct genl_info *info)
net/batman-adv/netlink.c
1254
return batadv_netlink_get_hardif_from_ifindex(bat_priv, net, ifindex);
net/batman-adv/netlink.c
1289
batadv_get_vlan_from_info(struct batadv_priv *bat_priv, struct net *net,
net/batman-adv/netlink.c
1319
struct net *net = genl_info_net(info);
net/batman-adv/netlink.c
1338
mesh_iface = batadv_netlink_get_meshif_from_info(net, info);
net/batman-adv/netlink.c
1347
hard_iface = batadv_netlink_get_hardif_from_info(bat_priv, net,
net/batman-adv/netlink.c
1358
vlan = batadv_get_vlan_from_info(bat_priv, net, info);
net/batman-adv/translation-table.c
599
struct net *net = dev_net(mesh_iface);
net/batman-adv/translation-table.c
612
in_dev = dev_get_by_index(net, ifindex);
net/bluetooth/af_bluetooth.c
113
static int bt_sock_create(struct net *net, struct socket *sock, int proto,
net/bluetooth/af_bluetooth.c
118
if (net != &init_net)
net/bluetooth/af_bluetooth.c
132
err = bt_proto[proto]->create(net, sock, proto, kern);
net/bluetooth/af_bluetooth.c
143
struct sock *bt_sock_alloc(struct net *net, struct socket *sock,
net/bluetooth/af_bluetooth.c
148
sk = sk_alloc(net, PF_BLUETOOTH, prio, prot, kern);
net/bluetooth/af_bluetooth.c
885
int bt_procfs_init(struct net *net, const char *name,
net/bluetooth/af_bluetooth.c
891
if (!proc_create_seq_data(name, 0, net->proc_net, &bt_seq_ops, sk_list))
net/bluetooth/af_bluetooth.c
896
void bt_procfs_cleanup(struct net *net, const char *name)
net/bluetooth/af_bluetooth.c
898
remove_proc_entry(name, net->proc_net);
net/bluetooth/af_bluetooth.c
901
int bt_procfs_init(struct net *net, const char *name,
net/bluetooth/af_bluetooth.c
908
void bt_procfs_cleanup(struct net *net, const char *name)
net/bluetooth/bnep/sock.c
195
static int bnep_sock_create(struct net *net, struct socket *sock, int protocol,
net/bluetooth/bnep/sock.c
205
sk = bt_sock_alloc(net, sock, &bnep_proto, protocol, GFP_ATOMIC, kern);
net/bluetooth/hci_sock.c
2202
static int hci_sock_create(struct net *net, struct socket *sock, int protocol,
net/bluetooth/hci_sock.c
2214
sk = bt_sock_alloc(net, sock, &hci_sk_proto, protocol, GFP_ATOMIC,
net/bluetooth/hidp/sock.c
246
static int hidp_sock_create(struct net *net, struct socket *sock, int protocol,
net/bluetooth/hidp/sock.c
256
sk = bt_sock_alloc(net, sock, &hidp_proto, protocol, GFP_ATOMIC, kern);
net/bluetooth/iso.c
936
static struct sock *iso_sock_alloc(struct net *net, struct socket *sock,
net/bluetooth/iso.c
941
sk = bt_sock_alloc(net, sock, &iso_proto, proto, prio, kern);
net/bluetooth/iso.c
958
static int iso_sock_create(struct net *net, struct socket *sock, int protocol,
net/bluetooth/iso.c
972
sk = iso_sock_alloc(net, sock, protocol, GFP_ATOMIC, kern);
net/bluetooth/l2cap_sock.c
1974
static struct sock *l2cap_sock_alloc(struct net *net, struct socket *sock,
net/bluetooth/l2cap_sock.c
1980
sk = bt_sock_alloc(net, sock, &l2cap_proto, proto, prio, kern);
net/bluetooth/l2cap_sock.c
1995
static int l2cap_sock_create(struct net *net, struct socket *sock, int protocol,
net/bluetooth/l2cap_sock.c
2018
sk = l2cap_sock_alloc(net, sock, protocol, GFP_ATOMIC, kern, chan);
net/bluetooth/l2cap_sock.c
45
static struct sock *l2cap_sock_alloc(struct net *net, struct socket *sock,
net/bluetooth/rfcomm/sock.c
281
static struct sock *rfcomm_sock_alloc(struct net *net, struct socket *sock,
net/bluetooth/rfcomm/sock.c
291
sk = bt_sock_alloc(net, sock, &rfcomm_proto, proto, prio, kern);
net/bluetooth/rfcomm/sock.c
315
static int rfcomm_sock_create(struct net *net, struct socket *sock,
net/bluetooth/rfcomm/sock.c
329
sk = rfcomm_sock_alloc(net, sock, protocol, GFP_ATOMIC, kern);
net/bluetooth/sco.c
609
static struct sock *sco_sock_alloc(struct net *net, struct socket *sock,
net/bluetooth/sco.c
614
sk = bt_sock_alloc(net, sock, &sco_proto, proto, prio, kern);
net/bluetooth/sco.c
631
static int sco_sock_create(struct net *net, struct socket *sock, int protocol,
net/bluetooth/sco.c
645
sk = sco_sock_alloc(net, sock, protocol, GFP_ATOMIC, kern);
net/bpf/test_run.c
1040
struct net *net = current->nsproxy->net_ns;
net/bpf/test_run.c
1041
struct net_device *dev = net->loopback_dev;
net/bpf/test_run.c
1106
sk = sk_alloc(net, AF_UNSPEC, GFP_USER, &bpf_dummy_proto, 1);
net/bpf/test_run.c
1162
dev = dev_get_by_index(net, ctx->ifindex);
net/bpf/test_run.c
1220
dst_hold(&net->ipv6.ip6_null_entry->dst);
net/bpf/test_run.c
1221
skb_dst_set(skb, &net->ipv6.ip6_null_entry->dst);
net/bpf/test_run.c
1264
if (dev && dev != net->loopback_dev)
net/bpf/test_run.c
1728
if (user->net || user->sk || user->okfn)
net/bpf/test_run.c
1780
struct net *net = current->nsproxy->net_ns;
net/bpf/test_run.c
1781
struct net_device *dev = net->loopback_dev;
net/bridge/br.c
405
static void __net_exit br_net_exit_rtnl(struct net *net,
net/bridge/br.c
410
ASSERT_RTNL_NET(net);
net/bridge/br.c
412
for_each_netdev(net, dev)
net/bridge/br_fdb.c
181
struct net *net = dev_net(br->dev);
net/bridge/br_fdb.c
199
rtnl_notify(skb, net, 0, RTNLGRP_NEIGH, NULL, GFP_ATOMIC);
net/bridge/br_fdb.c
202
rtnl_set_sk_err(net, RTNLGRP_NEIGH, err);
net/bridge/br_forward.c
100
net = dev_net(indev);
net/bridge/br_forward.c
111
net = dev_net(skb->dev);
net/bridge/br_forward.c
116
net, NULL, skb, indev, skb->dev,
net/bridge/br_forward.c
33
int br_dev_queue_push_xmit(struct net *net, struct sock *sk, struct sk_buff *skb)
net/bridge/br_forward.c
63
int br_forward_finish(struct net *net, struct sock *sk, struct sk_buff *skb)
net/bridge/br_forward.c
67
net, sk, skb, NULL, skb->dev,
net/bridge/br_forward.c
78
struct net *net;
net/bridge/br_if.c
462
int br_add_bridge(struct net *net, const char *name)
net/bridge/br_if.c
473
dev_net_set(dev, net);
net/bridge/br_if.c
482
int br_del_bridge(struct net *net, const char *name)
net/bridge/br_if.c
487
dev = __dev_get_by_name(net, name);
net/bridge/br_input.c
259
static int br_handle_local_finish(struct net *net, struct sock *sk, struct sk_buff *skb)
net/bridge/br_input.c
27
br_netif_receive_skb(struct net *net, struct sock *sk, struct sk_buff *skb)
net/bridge/br_input.c
273
struct net *net;
net/bridge/br_input.c
276
net = dev_net(skb->dev);
net/bridge/br_input.c
282
e = rcu_dereference(net->nf.hooks_bridge[NF_BR_PRE_ROUTING]);
net/bridge/br_input.c
288
net, br_handle_frame_finish);
net/bridge/br_input.c
312
net = dev_net(skb->dev);
net/bridge/br_input.c
313
br_handle_frame_finish(net, NULL, skb);
net/bridge/br_input.c
76
int br_handle_frame_finish(struct net *net, struct sock *sk, struct sk_buff *skb)
net/bridge/br_ioctl.c
21
static int get_bridge_ifindices(struct net *net, int *indices, int num)
net/bridge/br_ioctl.c
27
for_each_netdev_rcu(net, dev) {
net/bridge/br_ioctl.c
339
static int old_deviceless(struct net *net, void __user *data)
net/bridge/br_ioctl.c
364
args[2] = get_bridge_ifindices(net, indices, args[2]);
net/bridge/br_ioctl.c
379
if (!ns_capable(net->user_ns, CAP_NET_ADMIN))
net/bridge/br_ioctl.c
388
return br_add_bridge(net, buf);
net/bridge/br_ioctl.c
390
return br_del_bridge(net, buf);
net/bridge/br_ioctl.c
397
int br_ioctl_stub(struct net *net, unsigned int cmd, void __user *uarg)
net/bridge/br_ioctl.c
406
if (!ns_capable(net->user_ns, CAP_NET_ADMIN))
net/bridge/br_ioctl.c
423
ret = old_deviceless(net, uarg);
net/bridge/br_ioctl.c
430
if (!ns_capable(net->user_ns, CAP_NET_ADMIN)) {
net/bridge/br_ioctl.c
442
ret = br_add_bridge(net, buf);
net/bridge/br_ioctl.c
444
ret = br_del_bridge(net, buf);
net/bridge/br_ioctl.c
452
dev = __dev_get_by_name(net, ifr.ifr_name);
net/bridge/br_ioctl.c
87
struct net *net = dev_net(br->dev);
net/bridge/br_ioctl.c
91
if (!ns_capable(net->user_ns, CAP_NET_ADMIN))
net/bridge/br_ioctl.c
94
dev = __dev_get_by_index(net, ifindex);
net/bridge/br_mdb.c
1235
struct net *net = dev_net(dev);
net/bridge/br_mdb.c
1259
pdev = __dev_get_by_index(net, cfg->entry->ifindex);
net/bridge/br_mdb.c
527
struct net *net = dev_net(dev);
net/bridge/br_mdb.c
544
rtnl_notify(skb, net, 0, RTNLGRP_MDB, NULL, GFP_ATOMIC);
net/bridge/br_mdb.c
547
rtnl_set_sk_err(net, RTNLGRP_MDB, err);
net/bridge/br_mdb.c
620
struct net *net = dev_net(dev);
net/bridge/br_mdb.c
640
rtnl_notify(skb, net, 0, RTNLGRP_MDB, NULL, GFP_ATOMIC);
net/bridge/br_mdb.c
644
rtnl_set_sk_err(net, RTNLGRP_MDB, err);
net/bridge/br_netfilter_hooks.c
100
const struct net *net)
net/bridge/br_netfilter_hooks.c
102
struct brnf_net *brnet = net_generic(net, brnf_net_id);
net/bridge/br_netfilter_hooks.c
108
static inline bool is_vlan_arp(const struct sk_buff *skb, const struct net *net)
net/bridge/br_netfilter_hooks.c
1093
struct net *net;
net/bridge/br_netfilter_hooks.c
110
struct brnf_net *brnet = net_generic(net, brnf_net_id);
net/bridge/br_netfilter_hooks.c
1101
net = dev_net(dev);
net/bridge/br_netfilter_hooks.c
1102
brnet = net_generic(net, brnf_net_id);
net/bridge/br_netfilter_hooks.c
1106
ret = nf_register_net_hooks(net, br_nf_ops, ARRAY_SIZE(br_nf_ops));
net/bridge/br_netfilter_hooks.c
1123
int br_nf_hook_thresh(unsigned int hook, struct net *net,
net/bridge/br_netfilter_hooks.c
1127
int (*okfn)(struct net *, struct sock *,
net/bridge/br_netfilter_hooks.c
1136
e = rcu_dereference(net->nf.hooks_bridge[hook]);
net/bridge/br_netfilter_hooks.c
1138
return okfn(net, sk, skb);
net/bridge/br_netfilter_hooks.c
1161
sk, net, okfn);
net/bridge/br_netfilter_hooks.c
1165
ret = okfn(net, sk, skb);
net/bridge/br_netfilter_hooks.c
121
static inline bool is_pppoe_ip(const struct sk_buff *skb, const struct net *net)
net/bridge/br_netfilter_hooks.c
123
struct brnf_net *brnet = net_generic(net, brnf_net_id);
net/bridge/br_netfilter_hooks.c
1233
static int br_netfilter_sysctl_init_net(struct net *net)
net/bridge/br_netfilter_hooks.c
1238
if (!net_eq(net, &init_net)) {
net/bridge/br_netfilter_hooks.c
1244
brnet = net_generic(net, brnf_net_id);
net/bridge/br_netfilter_hooks.c
1254
brnet->ctl_hdr = register_net_sysctl_sz(net, "net/bridge", table,
net/bridge/br_netfilter_hooks.c
1257
if (!net_eq(net, &init_net))
net/bridge/br_netfilter_hooks.c
1266
static void br_netfilter_sysctl_exit_net(struct net *net,
net/bridge/br_netfilter_hooks.c
1272
if (!net_eq(net, &init_net))
net/bridge/br_netfilter_hooks.c
1276
static int __net_init brnf_init_net(struct net *net)
net/bridge/br_netfilter_hooks.c
1278
return br_netfilter_sysctl_init_net(net);
net/bridge/br_netfilter_hooks.c
1282
static void __net_exit brnf_exit_net(struct net *net)
net/bridge/br_netfilter_hooks.c
1286
brnet = net_generic(net, brnf_net_id);
net/bridge/br_netfilter_hooks.c
1288
nf_unregister_net_hooks(net, br_nf_ops, ARRAY_SIZE(br_nf_ops));
net/bridge/br_netfilter_hooks.c
1293
br_netfilter_sysctl_exit_net(net, brnet);
net/bridge/br_netfilter_hooks.c
130
const struct net *net)
net/bridge/br_netfilter_hooks.c
132
struct brnf_net *brnet = net_generic(net, brnf_net_id);
net/bridge/br_netfilter_hooks.c
206
static int br_validate_ipv4(struct net *net, struct sk_buff *skb)
net/bridge/br_netfilter_hooks.c
229
__IP_INC_STATS(net, IPSTATS_MIB_INTRUNCATEDPKTS);
net/bridge/br_netfilter_hooks.c
235
__IP_INC_STATS(net, IPSTATS_MIB_INDISCARDS);
net/bridge/br_netfilter_hooks.c
248
__IP_INC_STATS(net, IPSTATS_MIB_CSUMERRORS);
net/bridge/br_netfilter_hooks.c
250
__IP_INC_STATS(net, IPSTATS_MIB_INHDRERRORS);
net/bridge/br_netfilter_hooks.c
276
int br_nf_pre_routing_finish_bridge(struct net *net, struct sock *sk, struct sk_buff *skb)
net/bridge/br_netfilter_hooks.c
294
br_indev = nf_bridge_get_physindev(skb, net);
net/bridge/br_netfilter_hooks.c
307
ret = br_handle_frame_finish(net, sk, skb);
net/bridge/br_netfilter_hooks.c
376
static int br_nf_pre_routing_finish(struct net *net, struct sock *sk, struct sk_buff *skb)
net/bridge/br_netfilter_hooks.c
384
br_indev = nf_bridge_get_physindev(skb, net);
net/bridge/br_netfilter_hooks.c
409
net, sk, skb, skb->dev,
net/bridge/br_netfilter_hooks.c
430
br_nf_hook_thresh(NF_BR_PRE_ROUTING, net, sk, skb, skb->dev, NULL,
net/bridge/br_netfilter_hooks.c
437
const struct net *net)
net/bridge/br_netfilter_hooks.c
440
struct brnf_net *brnet = net_generic(net, brnf_net_id);
net/bridge/br_netfilter_hooks.c
454
struct net_device *setup_pre_routing(struct sk_buff *skb, const struct net *net)
net/bridge/br_netfilter_hooks.c
465
skb->dev = brnf_get_logical_dev(skb, skb->dev, net);
net/bridge/br_netfilter_hooks.c
501
brnet = net_generic(state->net, brnf_net_id);
net/bridge/br_netfilter_hooks.c
502
if (IS_IPV6(skb) || is_vlan_ipv6(skb, state->net) ||
net/bridge/br_netfilter_hooks.c
503
is_pppoe_ipv6(skb, state->net)) {
net/bridge/br_netfilter_hooks.c
519
if (!IS_IP(skb) && !is_vlan_ip(skb, state->net) &&
net/bridge/br_netfilter_hooks.c
520
!is_pppoe_ip(skb, state->net))
net/bridge/br_netfilter_hooks.c
525
if (br_validate_ipv4(state->net, skb))
net/bridge/br_netfilter_hooks.c
530
if (!setup_pre_routing(skb, state->net))
net/bridge/br_netfilter_hooks.c
539
NF_HOOK(NFPROTO_IPV4, NF_INET_PRE_ROUTING, state->net, state->sk, skb,
net/bridge/br_netfilter_hooks.c
639
static int br_nf_forward_finish(struct net *net, struct sock *sk, struct sk_buff *skb)
net/bridge/br_netfilter_hooks.c
644
if (!IS_ARP(skb) && !is_vlan_arp(skb, net)) {
net/bridge/br_netfilter_hooks.c
652
in = nf_bridge_get_physindev(skb, net);
net/bridge/br_netfilter_hooks.c
667
br_nf_hook_thresh(NF_BR_FORWARD, net, sk, skb, in, skb->dev,
net/bridge/br_netfilter_hooks.c
705
if (br_validate_ipv4(state->net, skb))
net/bridge/br_netfilter_hooks.c
710
if (br_validate_ipv6(state->net, skb))
net/bridge/br_netfilter_hooks.c
721
NF_HOOK(pf, NF_INET_FORWARD, state->net, NULL, skb,
net/bridge/br_netfilter_hooks.c
722
brnf_get_logical_dev(skb, state->in, state->net),
net/bridge/br_netfilter_hooks.c
741
brnet = net_generic(state->net, brnf_net_id);
net/bridge/br_netfilter_hooks.c
745
if (is_vlan_arp(skb, state->net))
net/bridge/br_netfilter_hooks.c
752
if (is_vlan_arp(skb, state->net))
net/bridge/br_netfilter_hooks.c
757
NF_HOOK(NFPROTO_ARP, NF_ARP_FORWARD, state->net, state->sk, skb,
net/bridge/br_netfilter_hooks.c
773
if (IS_IP(skb) || is_vlan_ip(skb, state->net) ||
net/bridge/br_netfilter_hooks.c
774
is_pppoe_ip(skb, state->net))
net/bridge/br_netfilter_hooks.c
776
if (IS_IPV6(skb) || is_vlan_ipv6(skb, state->net) ||
net/bridge/br_netfilter_hooks.c
777
is_pppoe_ipv6(skb, state->net))
net/bridge/br_netfilter_hooks.c
779
if (IS_ARP(skb) || is_vlan_arp(skb, state->net))
net/bridge/br_netfilter_hooks.c
785
static int br_nf_push_frag_xmit(struct net *net, struct sock *sk, struct sk_buff *skb)
net/bridge/br_netfilter_hooks.c
805
return br_dev_queue_push_xmit(net, sk, skb);
net/bridge/br_netfilter_hooks.c
809
br_nf_ip_fragment(struct net *net, struct sock *sk, struct sk_buff *skb,
net/bridge/br_netfilter_hooks.c
810
int (*output)(struct net *, struct sock *, struct sk_buff *))
net/bridge/br_netfilter_hooks.c
818
IP_INC_STATS(net, IPSTATS_MIB_FRAGFAILS);
net/bridge/br_netfilter_hooks.c
823
return ip_do_fragment(net, sk, skb, output);
net/bridge/br_netfilter_hooks.c
835
static int br_nf_dev_queue_xmit(struct net *net, struct sock *sk, struct sk_buff *skb)
net/bridge/br_netfilter_hooks.c
857
return br_dev_queue_push_xmit(net, sk, skb);
net/bridge/br_netfilter_hooks.c
871
if (br_validate_ipv4(net, skb))
net/bridge/br_netfilter_hooks.c
892
ret = br_nf_ip_fragment(net, sk, skb, br_nf_push_frag_xmit);
net/bridge/br_netfilter_hooks.c
900
if (br_validate_ipv6(net, skb))
net/bridge/br_netfilter_hooks.c
913
ret = ip6_fragment(net, sk, skb, br_nf_push_frag_xmit);
net/bridge/br_netfilter_hooks.c
918
return br_dev_queue_push_xmit(net, sk, skb);
net/bridge/br_netfilter_hooks.c
92
static inline bool is_vlan_ip(const struct sk_buff *skb, const struct net *net)
net/bridge/br_netfilter_hooks.c
94
struct brnf_net *brnet = net_generic(net, brnf_net_id);
net/bridge/br_netfilter_hooks.c
944
if (IS_IP(skb) || is_vlan_ip(skb, state->net) ||
net/bridge/br_netfilter_hooks.c
945
is_pppoe_ip(skb, state->net))
net/bridge/br_netfilter_hooks.c
947
else if (IS_IPV6(skb) || is_vlan_ipv6(skb, state->net) ||
net/bridge/br_netfilter_hooks.c
948
is_pppoe_ipv6(skb, state->net))
net/bridge/br_netfilter_hooks.c
964
NF_HOOK(pf, NF_INET_POST_ROUTING, state->net, state->sk, skb,
net/bridge/br_netfilter_hooks.c
988
state->okfn(state->net, state->sk, skb);
net/bridge/br_netfilter_ipv6.c
101
static int br_nf_pre_routing_finish_ipv6(struct net *net, struct sock *sk, struct sk_buff *skb)
net/bridge/br_netfilter_ipv6.c
107
br_indev = nf_bridge_get_physindev(skb, net);
net/bridge/br_netfilter_ipv6.c
134
net, sk, skb, skb->dev, NULL,
net/bridge/br_netfilter_ipv6.c
153
br_nf_hook_thresh(NF_BR_PRE_ROUTING, net, sk, skb,
net/bridge/br_netfilter_ipv6.c
168
if (br_validate_ipv6(state->net, skb))
net/bridge/br_netfilter_ipv6.c
174
if (!setup_pre_routing(skb, state->net))
net/bridge/br_netfilter_ipv6.c
183
NF_HOOK(NFPROTO_IPV6, NF_INET_PRE_ROUTING, state->net, state->sk, skb,
net/bridge/br_netfilter_ipv6.c
44
int br_validate_ipv6(struct net *net, struct sk_buff *skb)
net/bridge/br_netfilter_ipv6.c
67
__IP6_INC_STATS(net, idev,
net/bridge/br_netfilter_ipv6.c
72
__IP6_INC_STATS(net, idev,
net/bridge/br_netfilter_ipv6.c
84
__IP6_INC_STATS(net, idev, IPSTATS_MIB_INHDRERRORS);
net/bridge/br_netlink.c
636
struct net *net;
net/bridge/br_netlink.c
650
net = dev_net(dev);
net/bridge/br_netlink.c
664
rtnl_notify(skb, net, 0, RTNLGRP_LINK, NULL, GFP_ATOMIC);
net/bridge/br_netlink.c
667
rtnl_set_sk_err(net, RTNLGRP_LINK, err);
net/bridge/br_private.h
897
int br_dev_queue_push_xmit(struct net *net, struct sock *sk, struct sk_buff *skb);
net/bridge/br_private.h
900
int br_forward_finish(struct net *net, struct sock *sk, struct sk_buff *skb);
net/bridge/br_private.h
915
int br_add_bridge(struct net *net, const char *name);
net/bridge/br_private.h
916
int br_del_bridge(struct net *net, const char *name);
net/bridge/br_private.h
928
int br_handle_frame_finish(struct net *net, struct sock *sk, struct sk_buff *skb);
net/bridge/br_private.h
965
int br_ioctl_stub(struct net *net, unsigned int cmd, void __user *uarg);
net/bridge/br_stp_bpdu.c
29
static int br_send_bpdu_finish(struct net *net, struct sock *sk,
net/bridge/br_vlan.c
1923
struct net *net;
net/bridge/br_vlan.c
1933
net = dev_net(p->dev);
net/bridge/br_vlan.c
1937
net = dev_net(br->dev);
net/bridge/br_vlan.c
1974
rtnl_notify(skb, net, 0, RTNLGRP_BRVLAN, NULL, GFP_KERNEL);
net/bridge/br_vlan.c
1978
rtnl_set_sk_err(net, RTNLGRP_BRVLAN, err);
net/bridge/br_vlan.c
2123
struct net *net = sock_net(skb->sk);
net/bridge/br_vlan.c
2139
dev = dev_get_by_index_rcu(net, bvm->ifindex);
net/bridge/br_vlan.c
2149
for_each_netdev_rcu(net, dev) {
net/bridge/br_vlan.c
2292
struct net *net = sock_net(skb->sk);
net/bridge/br_vlan.c
2306
dev = __dev_get_by_index(net, bvm->ifindex);
net/bridge/netfilter/ebt_log.c
183
struct net *net = xt_net(par);
net/bridge/netfilter/ebt_log.c
194
nf_log_packet(net, NFPROTO_BRIDGE, xt_hooknum(par), skb,
net/bridge/netfilter/ebt_log.c
198
ebt_log_packet(net, NFPROTO_BRIDGE, xt_hooknum(par), skb,
net/bridge/netfilter/ebt_log.c
74
ebt_log_packet(struct net *net, u_int8_t pf, unsigned int hooknum,
net/bridge/netfilter/ebt_log.c
82
if (!net_eq(net, &init_net) && !sysctl_nf_log_all_netns)
net/bridge/netfilter/ebt_nflog.c
27
struct net *net = xt_net(par);
net/bridge/netfilter/ebt_nflog.c
36
nf_log_packet(net, PF_BRIDGE, xt_hooknum(par), skb, xt_in(par),
net/bridge/netfilter/ebtable_broute.c
100
ebt_unregister_table_pre_exit(net, "broute");
net/bridge/netfilter/ebtable_broute.c
103
static void __net_exit broute_net_exit(struct net *net)
net/bridge/netfilter/ebtable_broute.c
105
ebt_unregister_table(net, "broute");
net/bridge/netfilter/ebtable_broute.c
59
s->net, NULL);
net/bridge/netfilter/ebtable_broute.c
93
static int broute_table_init(struct net *net)
net/bridge/netfilter/ebtable_broute.c
95
return ebt_register_table(net, &broute_table, &ebt_ops_broute);
net/bridge/netfilter/ebtable_broute.c
98
static void __net_exit broute_net_pre_exit(struct net *net)
net/bridge/netfilter/ebtable_filter.c
74
static int frame_filter_table_init(struct net *net)
net/bridge/netfilter/ebtable_filter.c
76
return ebt_register_table(net, &frame_filter, ebt_ops_filter);
net/bridge/netfilter/ebtable_filter.c
79
static void __net_exit frame_filter_net_pre_exit(struct net *net)
net/bridge/netfilter/ebtable_filter.c
81
ebt_unregister_table_pre_exit(net, "filter");
net/bridge/netfilter/ebtable_filter.c
84
static void __net_exit frame_filter_net_exit(struct net *net)
net/bridge/netfilter/ebtable_filter.c
86
ebt_unregister_table(net, "filter");
net/bridge/netfilter/ebtable_nat.c
74
static int frame_nat_table_init(struct net *net)
net/bridge/netfilter/ebtable_nat.c
76
return ebt_register_table(net, &frame_nat, ebt_ops_nat);
net/bridge/netfilter/ebtable_nat.c
79
static void __net_exit frame_nat_net_pre_exit(struct net *net)
net/bridge/netfilter/ebtable_nat.c
81
ebt_unregister_table_pre_exit(net, "nat");
net/bridge/netfilter/ebtable_nat.c
84
static void __net_exit frame_nat_net_exit(struct net *net)
net/bridge/netfilter/ebtable_nat.c
86
ebt_unregister_table(net, "nat");
net/bridge/netfilter/ebtables.c
1011
static int do_replace_finish(struct net *net, struct ebt_replace *repl,
net/bridge/netfilter/ebtables.c
1035
ret = translate_table(net, repl->name, newinfo);
net/bridge/netfilter/ebtables.c
1040
t = find_table_lock(net, repl->name, &ret, &ebt_mutex);
net/bridge/netfilter/ebtables.c
1087
ebt_cleanup_entry, net, NULL);
net/bridge/netfilter/ebtables.c
1102
ebt_cleanup_entry, net, NULL);
net/bridge/netfilter/ebtables.c
1111
static int do_replace(struct net *net, sockptr_t arg, unsigned int len)
net/bridge/netfilter/ebtables.c
1156
ret = do_replace_finish(net, &tmp, newinfo);
net/bridge/netfilter/ebtables.c
1166
static void __ebt_unregister_table(struct net *net, struct ebt_table *table)
net/bridge/netfilter/ebtables.c
1169
ebt_cleanup_entry, net, NULL);
net/bridge/netfilter/ebtables.c
1179
int ebt_register_table(struct net *net, const struct ebt_table *input_table,
net/bridge/netfilter/ebtables.c
1182
struct ebt_pernet *ebt_net = net_generic(net, ebt_pernet_id);
net/bridge/netfilter/ebtables.c
1231
ret = translate_table(net, repl->name, newinfo);
net/bridge/netfilter/ebtables.c
1269
ret = nf_register_net_hooks(net, ops, num_ops);
net/bridge/netfilter/ebtables.c
1272
__ebt_unregister_table(net, table);
net/bridge/netfilter/ebtables.c
1294
int ebt_register_template(const struct ebt_table *t, int (*table_init)(struct net *net))
net/bridge/netfilter/ebtables.c
1342
void ebt_unregister_table_pre_exit(struct net *net, const char *name)
net/bridge/netfilter/ebtables.c
1344
struct ebt_pernet *ebt_net = net_generic(net, ebt_pernet_id);
net/bridge/netfilter/ebtables.c
1353
nf_unregister_net_hooks(net, t->ops, hweight32(t->valid_hooks));
net/bridge/netfilter/ebtables.c
1362
void ebt_unregister_table(struct net *net, const char *name)
net/bridge/netfilter/ebtables.c
1364
struct ebt_pernet *ebt_net = net_generic(net, ebt_pernet_id);
net/bridge/netfilter/ebtables.c
1374
__ebt_unregister_table(net, t);
net/bridge/netfilter/ebtables.c
1384
static int do_update_counters(struct net *net, const char *name,
net/bridge/netfilter/ebtables.c
1399
t = find_table_lock(net, name, &ret, &ebt_mutex);
net/bridge/netfilter/ebtables.c
1430
static int update_counters(struct net *net, sockptr_t arg, unsigned int len)
net/bridge/netfilter/ebtables.c
1444
return do_update_counters(net, hlp.name, hlp.counters,
net/bridge/netfilter/ebtables.c
2292
static int compat_do_replace(struct net *net, sockptr_t arg, unsigned int len)
net/bridge/netfilter/ebtables.c
2303
if (ret == -EINVAL && do_replace(net, arg, len) == 0)
net/bridge/netfilter/ebtables.c
2380
ret = do_replace_finish(net, &tmp, newinfo);
net/bridge/netfilter/ebtables.c
2394
static int compat_update_counters(struct net *net, sockptr_t arg,
net/bridge/netfilter/ebtables.c
2408
return update_counters(net, arg, len);
net/bridge/netfilter/ebtables.c
2410
return do_update_counters(net, hlp.name, compat_ptr(hlp.counters),
net/bridge/netfilter/ebtables.c
2420
struct net *net = sock_net(sk);
net/bridge/netfilter/ebtables.c
2431
t = find_table_lock(net, tmp.name, &ret, &ebt_mutex);
net/bridge/netfilter/ebtables.c
2489
struct net *net = sock_net(sk);
net/bridge/netfilter/ebtables.c
2494
if (!ns_capable(net->user_ns, CAP_NET_ADMIN))
net/bridge/netfilter/ebtables.c
2512
t = find_table_lock(net, tmp.name, &ret, &ebt_mutex);
net/bridge/netfilter/ebtables.c
2558
struct net *net = sock_net(sk);
net/bridge/netfilter/ebtables.c
2561
if (!ns_capable(net->user_ns, CAP_NET_ADMIN))
net/bridge/netfilter/ebtables.c
2570
ret = compat_do_replace(net, arg, len);
net/bridge/netfilter/ebtables.c
2573
ret = do_replace(net, arg, len);
net/bridge/netfilter/ebtables.c
2578
ret = compat_update_counters(net, arg, len);
net/bridge/netfilter/ebtables.c
2581
ret = update_counters(net, arg, len);
net/bridge/netfilter/ebtables.c
2600
static int __net_init ebt_pernet_init(struct net *net)
net/bridge/netfilter/ebtables.c
2602
struct ebt_pernet *ebt_net = net_generic(net, ebt_pernet_id);
net/bridge/netfilter/ebtables.c
2609
static void __net_exit ebt_pernet_exit(struct net *net)
net/bridge/netfilter/ebtables.c
2611
struct ebt_pernet *ebt_net = net_generic(net, ebt_pernet_id);
net/bridge/netfilter/ebtables.c
322
find_inlist_lock_noload(struct net *net, const char *name, int *error,
net/bridge/netfilter/ebtables.c
325
struct ebt_pernet *ebt_net = net_generic(net, ebt_pernet_id);
net/bridge/netfilter/ebtables.c
344
*error = tmpl->table_init(net);
net/bridge/netfilter/ebtables.c
368
find_inlist_lock(struct net *net, const char *name, const char *prefix,
net/bridge/netfilter/ebtables.c
372
find_inlist_lock_noload(net, name, error, mutex),
net/bridge/netfilter/ebtables.c
377
find_table_lock(struct net *net, const char *name, int *error,
net/bridge/netfilter/ebtables.c
380
return find_inlist_lock(net, name, "ebtable_", error, mutex);
net/bridge/netfilter/ebtables.c
53
int (*table_init)(struct net *net);
net/bridge/netfilter/ebtables.c
624
ebt_cleanup_match(struct ebt_entry_match *m, struct net *net, unsigned int *i)
net/bridge/netfilter/ebtables.c
631
par.net = net;
net/bridge/netfilter/ebtables.c
642
ebt_cleanup_watcher(struct ebt_entry_watcher *w, struct net *net, unsigned int *i)
net/bridge/netfilter/ebtables.c
649
par.net = net;
net/bridge/netfilter/ebtables.c
660
ebt_cleanup_entry(struct ebt_entry *e, struct net *net, unsigned int *cnt)
net/bridge/netfilter/ebtables.c
670
EBT_WATCHER_ITERATE(e, ebt_cleanup_watcher, net, NULL);
net/bridge/netfilter/ebtables.c
671
EBT_MATCH_ITERATE(e, ebt_cleanup_match, net, NULL);
net/bridge/netfilter/ebtables.c
674
par.net = net;
net/bridge/netfilter/ebtables.c
685
ebt_check_entry(struct ebt_entry *e, struct net *net,
net/bridge/netfilter/ebtables.c
738
mtpar.net = tgpar.net = net;
net/bridge/netfilter/ebtables.c
794
EBT_WATCHER_ITERATE(e, ebt_cleanup_watcher, net, &j);
net/bridge/netfilter/ebtables.c
796
EBT_MATCH_ITERATE(e, ebt_cleanup_match, net, &i);
net/bridge/netfilter/ebtables.c
871
static int translate_table(struct net *net, const char *name,
net/bridge/netfilter/ebtables.c
980
ebt_check_entry, net, newinfo, name, &i, cl_s, udc_cnt);
net/bridge/netfilter/ebtables.c
983
ebt_cleanup_entry, net, &i);
net/bridge/netfilter/nf_conntrack_bridge.c
116
err = output(net, sk, data, skb2);
net/bridge/netfilter/nf_conntrack_bridge.c
162
err = ip_defrag(state->net, skb,
net/bridge/netfilter/nf_conntrack_bridge.c
190
err = nf_ct_frag6_gather(state->net, skb,
net/bridge/netfilter/nf_conntrack_bridge.c
26
static int nf_br_ip_fragment(struct net *net, struct sock *sk,
net/bridge/netfilter/nf_conntrack_bridge.c
29
int (*output)(struct net *, struct sock *sk,
net/bridge/netfilter/nf_conntrack_bridge.c
338
int (*output)(struct net *, struct sock *sk,
net/bridge/netfilter/nf_conntrack_bridge.c
350
nf_br_ip_fragment(state->net, state->sk, skb, &data, output);
net/bridge/netfilter/nf_conntrack_bridge.c
353
nf_br_ip6_fragment(state->net, state->sk, skb, &data, output);
net/bridge/netfilter/nf_conntrack_bridge.c
385
static int nf_ct_bridge_refrag_post(struct net *net, struct sock *sk,
net/bridge/netfilter/nf_conntrack_bridge.c
395
return br_dev_queue_push_xmit(net, sk, skb);
net/bridge/netfilter/nf_conntrack_bridge.c
85
err = output(net, sk, data, skb);
net/bridge/netfilter/nft_reject_bridge.c
101
nskb = nf_reject_skb_v6_unreach(net, oldskb, NULL, hook, code);
net/bridge/netfilter/nft_reject_bridge.c
45
static void nft_reject_br_send_v4_tcp_reset(struct net *net,
net/bridge/netfilter/nft_reject_bridge.c
52
nskb = nf_reject_skb_v4_tcp_reset(net, oldskb, NULL, hook);
net/bridge/netfilter/nft_reject_bridge.c
61
static void nft_reject_br_send_v4_unreach(struct net *net,
net/bridge/netfilter/nft_reject_bridge.c
68
nskb = nf_reject_skb_v4_unreach(net, oldskb, NULL, hook, code);
net/bridge/netfilter/nft_reject_bridge.c
77
static void nft_reject_br_send_v6_tcp_reset(struct net *net,
net/bridge/netfilter/nft_reject_bridge.c
84
nskb = nf_reject_skb_v6_tcp_reset(net, oldskb, NULL, hook);
net/bridge/netfilter/nft_reject_bridge.c
94
static void nft_reject_br_send_v6_unreach(struct net *net,
net/can/af_can.c
114
static int can_create(struct net *net, struct socket *sock, int protocol,
net/can/af_can.c
158
sk = sk_alloc(net, PF_CAN, GFP_KERNEL, cp->prot, kern);
net/can/af_can.c
176
sock_prot_inuse_add(net, sk->sk_prot, 1);
net/can/af_can.c
305
static struct can_dev_rcv_lists *can_dev_rcv_lists_find(struct net *net,
net/can/af_can.c
312
return net->can.rx_alldev_list;
net/can/af_can.c
444
int can_rx_register(struct net *net, struct net_device *dev, canid_t can_id,
net/can/af_can.c
451
struct can_rcv_lists_stats *rcv_lists_stats = net->can.rcv_lists_stats;
net/can/af_can.c
458
if (dev && !net_eq(net, dev_net(dev)))
net/can/af_can.c
465
spin_lock_bh(&net->can.rcvlists_lock);
net/can/af_can.c
467
dev_rcv_lists = can_dev_rcv_lists_find(net, dev);
net/can/af_can.c
484
spin_unlock_bh(&net->can.rcvlists_lock);
net/can/af_can.c
513
void can_rx_unregister(struct net *net, struct net_device *dev, canid_t can_id,
net/can/af_can.c
519
struct can_rcv_lists_stats *rcv_lists_stats = net->can.rcv_lists_stats;
net/can/af_can.c
525
if (dev && !net_eq(net, dev_net(dev)))
net/can/af_can.c
528
spin_lock_bh(&net->can.rcvlists_lock);
net/can/af_can.c
530
dev_rcv_lists = can_dev_rcv_lists_find(net, dev);
net/can/af_can.c
562
spin_unlock_bh(&net->can.rcvlists_lock);
net/can/af_can.c
657
struct net *net = dev_net(dev);
net/can/af_can.c
658
struct can_pkg_stats *pkg_stats = net->can.pkg_stats;
net/can/af_can.c
670
matches = can_rcv_filter(net->can.rx_alldev_list, skb);
net/can/af_can.c
673
dev_rcv_lists = can_dev_rcv_lists_find(net, dev);
net/can/af_can.c
798
static int can_pernet_init(struct net *net)
net/can/af_can.c
800
spin_lock_init(&net->can.rcvlists_lock);
net/can/af_can.c
801
net->can.rx_alldev_list = kzalloc_obj(*net->can.rx_alldev_list);
net/can/af_can.c
802
if (!net->can.rx_alldev_list)
net/can/af_can.c
804
net->can.pkg_stats = kzalloc_obj(*net->can.pkg_stats);
net/can/af_can.c
805
if (!net->can.pkg_stats)
net/can/af_can.c
807
net->can.rcv_lists_stats = kzalloc_obj(*net->can.rcv_lists_stats);
net/can/af_can.c
808
if (!net->can.rcv_lists_stats)
net/can/af_can.c
814
timer_setup(&net->can.stattimer, can_stat_update,
net/can/af_can.c
816
mod_timer(&net->can.stattimer,
net/can/af_can.c
819
net->can.pkg_stats->jiffies_init = jiffies;
net/can/af_can.c
820
can_init_proc(net);
net/can/af_can.c
826
kfree(net->can.pkg_stats);
net/can/af_can.c
828
kfree(net->can.rx_alldev_list);
net/can/af_can.c
833
static void can_pernet_exit(struct net *net)
net/can/af_can.c
836
can_remove_proc(net);
net/can/af_can.c
838
timer_delete_sync(&net->can.stattimer);
net/can/af_can.c
841
kfree(net->can.rx_alldev_list);
net/can/af_can.c
842
kfree(net->can.pkg_stats);
net/can/af_can.c
843
kfree(net->can.rcv_lists_stats);
net/can/af_can.h
100
void can_remove_proc(struct net *net);
net/can/af_can.h
99
void can_init_proc(struct net *net);
net/can/bcm.c
1917
struct net *net;
net/can/bcm.c
1924
net = sock_net(sk);
net/can/bcm.c
1942
if (net->can.bcmproc_dir && bo->bcm_proc_read)
net/can/bcm.c
1943
remove_proc_entry(bo->procname, net->can.bcmproc_dir);
net/can/bcm.c
197
static char *bcm_proc_getifname(struct net *net, char *result, int ifindex)
net/can/bcm.c
1970
can_rx_unregister(net, NULL, op->can_id,
net/can/bcm.c
1993
sock_prot_inuse_add(net, sk->sk_prot, -1);
net/can/bcm.c
2005
struct net *net = sock_net(sk);
net/can/bcm.c
2022
dev = dev_get_by_index(net, addr->can_ifindex);
net/can/bcm.c
2042
if (net->can.bcmproc_dir) {
net/can/bcm.c
2046
net->can.bcmproc_dir,
net/can/bcm.c
205
dev = dev_get_by_index_rcu(net, ifindex);
net/can/bcm.c
2142
static int canbcm_pernet_init(struct net *net)
net/can/bcm.c
2146
net->can.bcmproc_dir = proc_net_mkdir(net, "can-bcm", net->proc_net);
net/can/bcm.c
2152
static void canbcm_pernet_exit(struct net *net)
net/can/bcm.c
2156
if (net->can.bcmproc_dir)
net/can/bcm.c
2157
remove_proc_entry("can-bcm", net->proc_net);
net/can/bcm.c
218
struct net *net = m->private;
net/can/bcm.c
227
seq_printf(m, " / bound %s", bcm_proc_getifname(net, ifname, bo->ifindex));
net/can/bcm.c
244
bcm_proc_getifname(net, ifname, op->ifindex));
net/can/bcm.c
273
bcm_proc_getifname(net, ifname, op->ifindex));
net/can/gw.c
1080
struct net *net = sock_net(skb->sk);
net/can/gw.c
1114
hlist_for_each_entry(gwj, &net->can.cgw_list, list) {
net/can/gw.c
1158
gwj->src.dev = __dev_get_by_index(net, gwj->ccgw.src_idx);
net/can/gw.c
1166
gwj->dst.dev = __dev_get_by_index(net, gwj->ccgw.dst_idx);
net/can/gw.c
1183
err = cgw_register_filter(net, gwj);
net/can/gw.c
1185
hlist_add_head_rcu(&gwj->list, &net->can.cgw_list);
net/can/gw.c
1195
static void cgw_remove_all_jobs(struct net *net)
net/can/gw.c
1202
hlist_for_each_entry_safe(gwj, nx, &net->can.cgw_list, list) {
net/can/gw.c
1204
cgw_unregister_filter(net, gwj);
net/can/gw.c
1212
struct net *net = sock_net(skb->sk);
net/can/gw.c
1241
cgw_remove_all_jobs(net);
net/can/gw.c
1250
hlist_for_each_entry_safe(gwj, nx, &net->can.cgw_list, list) {
net/can/gw.c
1275
cgw_unregister_filter(net, gwj);
net/can/gw.c
1284
static int __net_init cangw_pernet_init(struct net *net)
net/can/gw.c
1286
INIT_HLIST_HEAD(&net->can.cgw_list);
net/can/gw.c
1292
struct net *net;
net/can/gw.c
1295
list_for_each_entry(net, net_list, exit_list)
net/can/gw.c
1296
cgw_remove_all_jobs(net);
net/can/gw.c
575
static inline int cgw_register_filter(struct net *net, struct cgw_job *gwj)
net/can/gw.c
577
return can_rx_register(net, gwj->src.dev, gwj->ccgw.filter.can_id,
net/can/gw.c
582
static inline void cgw_unregister_filter(struct net *net, struct cgw_job *gwj)
net/can/gw.c
584
can_rx_unregister(net, gwj->src.dev, gwj->ccgw.filter.can_id,
net/can/gw.c
610
struct net *net = dev_net(dev);
net/can/gw.c
621
hlist_for_each_entry_safe(gwj, nx, &net->can.cgw_list, list) {
net/can/gw.c
624
cgw_unregister_filter(net, gwj);
net/can/gw.c
778
struct net *net = sock_net(skb->sk);
net/can/gw.c
784
hlist_for_each_entry_rcu(gwj, &net->can.cgw_list, list) {
net/can/isotp.c
1312
struct net *net;
net/can/isotp.c
1318
net = sock_net(sk);
net/can/isotp.c
1353
can_rx_unregister(net, so->dev, so->rxid,
net/can/isotp.c
1357
can_rx_unregister(net, so->dev, so->txid,
net/can/isotp.c
1386
sock_prot_inuse_add(net, sk->sk_prot, -1);
net/can/isotp.c
1397
struct net *net = sock_net(sk);
net/can/isotp.c
1461
dev = dev_get_by_index(net, addr->can_ifindex);
net/can/isotp.c
1480
can_rx_register(net, dev, rx_id, SINGLE_MASK(rx_id),
net/can/isotp.c
1487
can_rx_register(net, dev, tx_id, SINGLE_MASK(tx_id),
net/can/j1939/socket.c
451
struct net *net;
net/can/j1939/socket.c
462
net = sock_net(sk);
net/can/j1939/socket.c
481
ndev = dev_get_by_index(net, addr->can_ifindex);
net/can/proc.c
117
struct net *net = timer_container_of(net, t, can.stattimer);
net/can/proc.c
118
struct can_pkg_stats *pkg_stats = net->can.pkg_stats;
net/can/proc.c
130
can_init_stats(net);
net/can/proc.c
134
can_init_stats(net);
net/can/proc.c
138
can_init_stats(net);
net/can/proc.c
142
can_init_stats(net);
net/can/proc.c
146
can_init_stats(net);
net/can/proc.c
181
mod_timer(&net->can.stattimer, round_jiffies(jiffies + HZ));
net/can/proc.c
218
struct net *net = m->private;
net/can/proc.c
219
struct can_pkg_stats *pkg_stats = net->can.pkg_stats;
net/can/proc.c
220
struct can_rcv_lists_stats *rcv_lists_stats = net->can.rcv_lists_stats;
net/can/proc.c
232
if (net->can.stattimer.function == can_stat_update) {
net/can/proc.c
283
struct net *net = m->private;
net/can/proc.c
284
struct can_rcv_lists_stats *rcv_lists_stats = net->can.rcv_lists_stats;
net/can/proc.c
285
struct can_pkg_stats *pkg_stats = net->can.pkg_stats;
net/can/proc.c
289
if (net->can.stattimer.function == can_stat_update) {
net/can/proc.c
294
can_init_stats(net);
net/can/proc.c
320
struct net *net = m->private;
net/can/proc.c
327
dev_rcv_lists = net->can.rx_alldev_list;
net/can/proc.c
331
for_each_netdev_rcu(net, dev) {
net/can/proc.c
374
struct net *net = m->private;
net/can/proc.c
382
dev_rcv_lists = net->can.rx_alldev_list;
net/can/proc.c
387
for_each_netdev_rcu(net, dev) {
net/can/proc.c
407
struct net *net = m->private;
net/can/proc.c
415
dev_rcv_lists = net->can.rx_alldev_list;
net/can/proc.c
420
for_each_netdev_rcu(net, dev) {
net/can/proc.c
439
void can_init_proc(struct net *net)
net/can/proc.c
442
net->can.proc_dir = proc_net_mkdir(net, "can", net->proc_net);
net/can/proc.c
444
if (!net->can.proc_dir) {
net/can/proc.c
451
net->can.pde_stats = proc_create_net_single(CAN_PROC_STATS, 0644,
net/can/proc.c
452
net->can.proc_dir, can_stats_proc_show, NULL);
net/can/proc.c
453
net->can.pde_reset_stats = proc_create_net_single(CAN_PROC_RESET_STATS,
net/can/proc.c
454
0644, net->can.proc_dir, can_reset_stats_proc_show,
net/can/proc.c
456
net->can.pde_rcvlist_err = proc_create_net_single(CAN_PROC_RCVLIST_ERR,
net/can/proc.c
457
0644, net->can.proc_dir, can_rcvlist_proc_show,
net/can/proc.c
459
net->can.pde_rcvlist_all = proc_create_net_single(CAN_PROC_RCVLIST_ALL,
net/can/proc.c
460
0644, net->can.proc_dir, can_rcvlist_proc_show,
net/can/proc.c
462
net->can.pde_rcvlist_fil = proc_create_net_single(CAN_PROC_RCVLIST_FIL,
net/can/proc.c
463
0644, net->can.proc_dir, can_rcvlist_proc_show,
net/can/proc.c
465
net->can.pde_rcvlist_inv = proc_create_net_single(CAN_PROC_RCVLIST_INV,
net/can/proc.c
466
0644, net->can.proc_dir, can_rcvlist_proc_show,
net/can/proc.c
468
net->can.pde_rcvlist_eff = proc_create_net_single(CAN_PROC_RCVLIST_EFF,
net/can/proc.c
469
0644, net->can.proc_dir, can_rcvlist_eff_proc_show, NULL);
net/can/proc.c
470
net->can.pde_rcvlist_sff = proc_create_net_single(CAN_PROC_RCVLIST_SFF,
net/can/proc.c
471
0644, net->can.proc_dir, can_rcvlist_sff_proc_show, NULL);
net/can/proc.c
477
void can_remove_proc(struct net *net)
net/can/proc.c
479
if (!net->can.proc_dir)
net/can/proc.c
482
if (net->can.pde_stats)
net/can/proc.c
483
remove_proc_entry(CAN_PROC_STATS, net->can.proc_dir);
net/can/proc.c
485
if (net->can.pde_reset_stats)
net/can/proc.c
486
remove_proc_entry(CAN_PROC_RESET_STATS, net->can.proc_dir);
net/can/proc.c
488
if (net->can.pde_rcvlist_err)
net/can/proc.c
489
remove_proc_entry(CAN_PROC_RCVLIST_ERR, net->can.proc_dir);
net/can/proc.c
491
if (net->can.pde_rcvlist_all)
net/can/proc.c
492
remove_proc_entry(CAN_PROC_RCVLIST_ALL, net->can.proc_dir);
net/can/proc.c
494
if (net->can.pde_rcvlist_fil)
net/can/proc.c
495
remove_proc_entry(CAN_PROC_RCVLIST_FIL, net->can.proc_dir);
net/can/proc.c
497
if (net->can.pde_rcvlist_inv)
net/can/proc.c
498
remove_proc_entry(CAN_PROC_RCVLIST_INV, net->can.proc_dir);
net/can/proc.c
500
if (net->can.pde_rcvlist_eff)
net/can/proc.c
501
remove_proc_entry(CAN_PROC_RCVLIST_EFF, net->can.proc_dir);
net/can/proc.c
503
if (net->can.pde_rcvlist_sff)
net/can/proc.c
504
remove_proc_entry(CAN_PROC_RCVLIST_SFF, net->can.proc_dir);
net/can/proc.c
506
remove_proc_entry("can", net->proc_net);
net/can/proc.c
79
static void can_init_stats(struct net *net)
net/can/proc.c
81
struct can_pkg_stats *pkg_stats = net->can.pkg_stats;
net/can/proc.c
82
struct can_rcv_lists_stats *rcv_lists_stats = net->can.rcv_lists_stats;
net/can/raw.c
215
static int raw_enable_filters(struct net *net, struct net_device *dev,
net/can/raw.c
223
err = can_rx_register(net, dev, filter[i].can_id,
net/can/raw.c
229
can_rx_unregister(net, dev, filter[i].can_id,
net/can/raw.c
239
static int raw_enable_errfilter(struct net *net, struct net_device *dev,
net/can/raw.c
245
err = can_rx_register(net, dev, 0, err_mask | CAN_ERR_FLAG,
net/can/raw.c
251
static void raw_disable_filters(struct net *net, struct net_device *dev,
net/can/raw.c
258
can_rx_unregister(net, dev, filter[i].can_id,
net/can/raw.c
262
static inline void raw_disable_errfilter(struct net *net,
net/can/raw.c
269
can_rx_unregister(net, dev, 0, err_mask | CAN_ERR_FLAG,
net/can/raw.c
273
static inline void raw_disable_allfilters(struct net *net,
net/can/raw.c
279
raw_disable_filters(net, dev, sk, ro->filter, ro->count);
net/can/raw.c
280
raw_disable_errfilter(net, dev, sk, ro->err_mask);
net/can/raw.c
283
static int raw_enable_allfilters(struct net *net, struct net_device *dev,
net/can/raw.c
289
err = raw_enable_filters(net, dev, sk, ro->filter, ro->count);
net/can/raw.c
291
err = raw_enable_errfilter(net, dev, sk, ro->err_mask);
net/can/raw.c
293
raw_disable_filters(net, dev, sk, ro->filter,
net/can/raw.c
413
struct net *net;
net/can/raw.c
419
net = sock_net(sk);
net/can/raw.c
439
raw_disable_allfilters(net, NULL, sk);
net/can/raw.c
457
sock_prot_inuse_add(net, sk->sk_prot, -1);
net/ceph/ceph_common.c
144
if (!net_eq(current->nsproxy->net_ns, read_pnet(&client->msgr.net)))
net/ceph/messenger.c
1695
write_pnet(&msgr->net, get_net(current->nsproxy->net_ns));
net/ceph/messenger.c
1702
put_net(read_pnet(&msgr->net));
net/ceph/messenger.c
448
ret = sock_create_kern(read_pnet(&con->msgr->net), ss.ss_family,
net/core/dev.c
1001
dev = dev_get_by_index_rcu(net, ifindex);
net/core/dev.c
10010
int netif_get_mac_address(struct sockaddr *sa, struct net *net, char *dev_name)
net/core/dev.c
10019
dev = dev_get_by_name_rcu(net, dev_name);
net/core/dev.c
10152
struct net *net;
net/core/dev.c
10160
net = dev->rtnl_link_ops->get_link_net(dev);
net/core/dev.c
10161
return __dev_get_by_index(net, dev_get_iflink(dev));
net/core/dev.c
1020
struct net_device *netdev_get_by_index(struct net *net, int ifindex,
net/core/dev.c
1025
dev = dev_get_by_index(net, ifindex);
net/core/dev.c
1064
netdev_put_lock(struct net_device *dev, struct net *net,
net/core/dev.c
10676
struct net *net = current->nsproxy->net_ns;
net/core/dev.c
10684
dev = dev_get_by_index(net, attr->link_create.target_ifindex);
net/core/dev.c
1069
dev->moving_ns || !net_eq(dev_net(dev), net)) {
net/core/dev.c
1079
__netdev_put_lock_ops_compat(struct net_device *dev, struct net *net)
net/core/dev.c
10803
static int dev_index_reserve(struct net *net, u32 ifindex)
net/core/dev.c
10813
err = xa_alloc_cyclic(&net->dev_by_index, &ifindex, NULL,
net/core/dev.c
10814
xa_limit_31b, &net->ifindex, GFP_KERNEL);
net/core/dev.c
10816
err = xa_insert(&net->dev_by_index, ifindex, NULL, GFP_KERNEL);
net/core/dev.c
10823
static void dev_index_release(struct net *net, int ifindex)
net/core/dev.c
10826
WARN_ON(xa_erase(&net->dev_by_index, ifindex));
net/core/dev.c
1083
dev->moving_ns || !net_eq(dev_net(dev), net)) {
net/core/dev.c
1103
struct net_device *netdev_get_by_index_lock(struct net *net, int ifindex)
net/core/dev.c
1107
dev = dev_get_by_index(net, ifindex);
net/core/dev.c
1111
return __netdev_put_lock(dev, net);
net/core/dev.c
1115
netdev_get_by_index_lock_ops_compat(struct net *net, int ifindex)
net/core/dev.c
1119
dev = dev_get_by_index(net, ifindex);
net/core/dev.c
1123
return __netdev_put_lock_ops_compat(dev, net);
net/core/dev.c
1127
netdev_xa_find_lock(struct net *net, struct net_device *dev,
net/core/dev.c
11330
struct net *net = dev_net(dev);
net/core/dev.c
11341
BUG_ON(!net);
net/core/dev.c
1135
dev = xa_find(&net->dev_by_index, index, ULONG_MAX, XA_PRESENT);
net/core/dev.c
11354
ret = dev_get_valid_name(net, dev, dev->name);
net/core/dev.c
11391
ret = dev_index_reserve(net, dev->ifindex);
net/core/dev.c
1143
dev = __netdev_put_lock(dev, net);
net/core/dev.c
11506
dev_index_release(net, dev->ifindex);
net/core/dev.c
1152
netdev_xa_find_lock_ops_compat(struct net *net, struct net_device *dev,
net/core/dev.c
11556
struct net *net = dev_net(dev);
net/core/dev.c
11559
if (rtnl_net_lock_killable(net))
net/core/dev.c
11564
rtnl_net_unlock(net);
net/core/dev.c
1160
dev = xa_find(&net->dev_by_index, index, ULONG_MAX, XA_PRESENT);
net/core/dev.c
1168
dev = __netdev_put_lock_ops_compat(dev, net);
net/core/dev.c
1194
int netdev_get_name(struct net *net, char *name, int ifindex)
net/core/dev.c
1201
dev = dev_get_by_index_rcu(net, ifindex);
net/core/dev.c
1235
struct net_device *dev_getbyhwaddr_rcu(struct net *net, unsigned short type,
net/core/dev.c
1240
for_each_netdev_rcu(net, dev)
net/core/dev.c
12530
int __dev_change_net_namespace(struct net_device *dev, struct net *net,
net/core/dev.c
12535
struct net *net_old = dev_net(dev);
net/core/dev.c
12556
if (net_eq(net_old, net))
net/core/dev.c
12563
if (netdev_name_in_use(net, dev->name)) {
net/core/dev.c
12570
err = dev_prep_valid_name(net, dev, pat, new_name, EEXIST);
net/core/dev.c
12581
if (netdev_name_in_use(net, name_node->name)) {
net/core/dev.c
12591
err = dev_index_reserve(net, new_ifindex);
net/core/dev.c
1260
struct net_device *dev_getbyhwaddr(struct net *net, unsigned short type,
net/core/dev.c
12600
err = dev_index_reserve(net, dev->ifindex);
net/core/dev.c
12602
err = dev_index_reserve(net, 0);
net/core/dev.c
12643
new_nsid = peernet2id_alloc(dev_net(dev), net, GFP_KERNEL);
net/core/dev.c
12659
move_netdevice_notifiers_dev_net(dev, net);
net/core/dev.c
1266
for_each_netdev(net, dev)
net/core/dev.c
12663
dev_net_set(dev, net);
net/core/dev.c
12687
err = netdev_change_owner(dev, net_old, net);
net/core/dev.c
1274
struct net_device *dev_getfirstbyhwtype(struct net *net, unsigned short type)
net/core/dev.c
1279
for_each_netdev_rcu(net, dev)
net/core/dev.c
12911
static int __net_init netdev_init(struct net *net)
net/core/dev.c
12916
INIT_LIST_HEAD(&net->dev_base_head);
net/core/dev.c
12918
net->dev_name_head = netdev_create_hash();
net/core/dev.c
12919
if (net->dev_name_head == NULL)
net/core/dev.c
12922
net->dev_index_head = netdev_create_hash();
net/core/dev.c
12923
if (net->dev_index_head == NULL)
net/core/dev.c
12926
xa_init_flags(&net->dev_by_index, XA_FLAGS_ALLOC1);
net/core/dev.c
12928
RAW_INIT_NOTIFIER_HEAD(&net->netdev_chain);
net/core/dev.c
12933
kfree(net->dev_name_head);
net/core/dev.c
1302
struct net_device *netdev_get_by_flags_rcu(struct net *net, netdevice_tracker *tracker,
net/core/dev.c
13021
static void __net_exit netdev_exit(struct net *net)
net/core/dev.c
13023
kfree(net->dev_name_head);
net/core/dev.c
13024
kfree(net->dev_index_head);
net/core/dev.c
13025
xa_destroy(&net->dev_by_index);
net/core/dev.c
13026
if (net != &init_net)
net/core/dev.c
13027
WARN_ON_ONCE(!list_empty(&net->dev_base_head));
net/core/dev.c
13035
static void __net_exit default_device_exit_net(struct net *net)
net/core/dev.c
13044
for_each_netdev_safe(net, dev, aux) {
net/core/dev.c
1307
for_each_netdev_rcu(net, dev) {
net/core/dev.c
13082
struct net *net;
net/core/dev.c
13086
list_for_each_entry(net, net_list, exit_list) {
net/core/dev.c
13087
default_device_exit_net(net);
net/core/dev.c
13091
list_for_each_entry(net, net_list, exit_list) {
net/core/dev.c
13092
for_each_netdev_reverse(net, dev) {
net/core/dev.c
1358
static int __dev_alloc_name(struct net *net, const char *name, char *res)
net/core/dev.c
1379
for_each_netdev(net, d) {
net/core/dev.c
1416
static int dev_prep_valid_name(struct net *net, struct net_device *dev,
net/core/dev.c
1424
return __dev_alloc_name(net, want_name, out_name);
net/core/dev.c
1426
if (netdev_name_in_use(net, want_name))
net/core/dev.c
1453
static int dev_get_valid_name(struct net *net, struct net_device *dev,
net/core/dev.c
1458
ret = dev_prep_valid_name(net, dev, name, dev->name, EEXIST);
net/core/dev.c
1464
struct net *net = dev_net(dev);
net/core/dev.c
1470
ASSERT_RTNL_NET(net);
net/core/dev.c
1478
err = dev_get_valid_name(net, dev, newname);
net/core/dev.c
1507
netdev_name_node_add(net, dev->name_node);
net/core/dev.c
187
static inline void dev_base_seq_inc(struct net *net)
net/core/dev.c
189
unsigned int val = net->dev_base_seq + 1;
net/core/dev.c
191
WRITE_ONCE(net->dev_base_seq, val ?: 1);
net/core/dev.c
1923
struct net *net)
net/core/dev.c
1928
for_each_netdev(net, dev) {
net/core/dev.c
1938
for_each_netdev_continue_reverse(net, dev)
net/core/dev.c
194
static inline struct hlist_head *dev_name_hash(struct net *net, const char *name)
net/core/dev.c
1944
struct net *net)
net/core/dev.c
1948
for_each_netdev(net, dev)
net/core/dev.c
196
unsigned int hash = full_name_hash(net, name, strnlen(name, IFNAMSIZ));
net/core/dev.c
1970
struct net *net;
net/core/dev.c
198
return &net->dev_name_head[hash_32(hash, NETDEV_HASHBITS)];
net/core/dev.c
1984
for_each_net(net) {
net/core/dev.c
1985
__rtnl_net_lock(net);
net/core/dev.c
1986
err = call_netdevice_register_net_notifiers(nb, net);
net/core/dev.c
1987
__rtnl_net_unlock(net);
net/core/dev.c
1998
for_each_net_continue_reverse(net) {
net/core/dev.c
1999
__rtnl_net_lock(net);
net/core/dev.c
2000
call_netdevice_unregister_net_notifiers(nb, net);
net/core/dev.c
2001
__rtnl_net_unlock(net);
net/core/dev.c
201
static inline struct hlist_head *dev_index_hash(struct net *net, int ifindex)
net/core/dev.c
2025
struct net *net;
net/core/dev.c
203
return &net->dev_index_head[ifindex & (NETDEV_HASHENTRIES - 1)];
net/core/dev.c
2035
for_each_net(net) {
net/core/dev.c
2036
__rtnl_net_lock(net);
net/core/dev.c
2037
call_netdevice_unregister_net_notifiers(nb, net);
net/core/dev.c
2038
__rtnl_net_unlock(net);
net/core/dev.c
2048
static int __register_netdevice_notifier_net(struct net *net,
net/core/dev.c
2054
err = raw_notifier_chain_register(&net->netdev_chain, nb);
net/core/dev.c
2060
err = call_netdevice_register_net_notifiers(nb, net);
net/core/dev.c
2067
raw_notifier_chain_unregister(&net->netdev_chain, nb);
net/core/dev.c
2071
static int __unregister_netdevice_notifier_net(struct net *net,
net/core/dev.c
2076
err = raw_notifier_chain_unregister(&net->netdev_chain, nb);
net/core/dev.c
2080
call_netdevice_unregister_net_notifiers(nb, net);
net/core/dev.c
2099
int register_netdevice_notifier_net(struct net *net, struct notifier_block *nb)
net/core/dev.c
2103
rtnl_net_lock(net);
net/core/dev.c
2104
err = __register_netdevice_notifier_net(net, nb, false);
net/core/dev.c
2105
rtnl_net_unlock(net);
net/core/dev.c
2127
int unregister_netdevice_notifier_net(struct net *net,
net/core/dev.c
2132
rtnl_net_lock(net);
net/core/dev.c
2133
err = __unregister_netdevice_notifier_net(net, nb);
net/core/dev.c
2134
rtnl_net_unlock(net);
net/core/dev.c
2140
static void __move_netdevice_notifier_net(struct net *src_net,
net/core/dev.c
2141
struct net *dst_net,
net/core/dev.c
2153
struct net *net;
net/core/dev.c
2159
net = dev_net_rcu(dev);
net/core/dev.c
2160
net_passive_inc(net);
net/core/dev.c
2163
rtnl_net_lock(net);
net/core/dev.c
2167
if (!net_eq(net, rcu_access_pointer(dev->nd_net.net))) {
net/core/dev.c
2168
rtnl_net_unlock(net);
net/core/dev.c
2169
net_passive_dec(net);
net/core/dev.c
2178
struct net *net = dev_net(dev);
net/core/dev.c
2180
rtnl_net_unlock(net);
net/core/dev.c
2181
net_passive_dec(net);
net/core/dev.c
2218
struct net *net)
net/core/dev.c
2223
__move_netdevice_notifier_net(dev_net(dev), net, nn->nb);
net/core/dev.c
2238
struct net *net = dev_net(info->dev);
net/core/dev.c
2247
ret = raw_notifier_call_chain(&net->netdev_chain, val, info);
net/core/dev.c
2271
struct net *net = dev_net(info->dev);
net/core/dev.c
2275
return raw_notifier_call_chain_robust(&net->netdev_chain,
net/core/dev.c
302
static void netdev_name_node_add(struct net *net,
net/core/dev.c
306
dev_name_hash(net, name_node->name));
net/core/dev.c
314
static struct netdev_name_node *netdev_name_node_lookup(struct net *net,
net/core/dev.c
317
struct hlist_head *head = dev_name_hash(net, name);
net/core/dev.c
326
static struct netdev_name_node *netdev_name_node_lookup_rcu(struct net *net,
net/core/dev.c
329
struct hlist_head *head = dev_name_hash(net, name);
net/core/dev.c
338
bool netdev_name_in_use(struct net *net, const char *name)
net/core/dev.c
340
return netdev_name_node_lookup(net, name);
net/core/dev.c
347
struct net *net = dev_net(dev);
net/core/dev.c
349
name_node = netdev_name_node_lookup(net, name);
net/core/dev.c
355
netdev_name_node_add(net, name_node);
net/core/dev.c
381
struct net *net = dev_net(dev);
net/core/dev.c
383
name_node = netdev_name_node_lookup(net, name);
net/core/dev.c
410
struct net *net = dev_net(dev);
net/core/dev.c
414
list_add_tail_rcu(&dev->dev_list, &net->dev_base_head);
net/core/dev.c
415
netdev_name_node_add(net, dev->name_node);
net/core/dev.c
417
dev_index_hash(net, dev->ifindex));
net/core/dev.c
420
netdev_name_node_add(net, name_node);
net/core/dev.c
423
WARN_ON(xa_store(&net->dev_by_index, dev->ifindex, dev, GFP_KERNEL));
net/core/dev.c
425
dev_base_seq_inc(net);
net/core/dev.c
434
struct net *net = dev_net(dev);
net/core/dev.c
4341
int dev_loopback_xmit(struct net *net, struct sock *sk, struct sk_buff *skb)
net/core/dev.c
438
xa_erase(&net->dev_by_index, dev->ifindex);
net/core/dev.c
808
netdev_napi_by_id(struct net *net, unsigned int napi_id)
net/core/dev.c
818
if (!net_eq(net, dev_net(napi->dev)))
net/core/dev.c
836
netdev_napi_by_id_lock(struct net *net, unsigned int napi_id)
net/core/dev.c
842
napi = netdev_napi_by_id(net, napi_id);
net/core/dev.c
852
dev = __netdev_put_lock(dev, net);
net/core/dev.c
857
napi = netdev_napi_by_id(net, napi_id);
net/core/dev.c
879
struct net_device *__dev_get_by_name(struct net *net, const char *name)
net/core/dev.c
883
node_name = netdev_name_node_lookup(net, name);
net/core/dev.c
900
struct net_device *dev_get_by_name_rcu(struct net *net, const char *name)
net/core/dev.c
904
node_name = netdev_name_node_lookup_rcu(net, name);
net/core/dev.c
910
struct net_device *dev_get_by_name(struct net *net, const char *name)
net/core/dev.c
915
dev = dev_get_by_name_rcu(net, name);
net/core/dev.c
935
struct net_device *netdev_get_by_name(struct net *net, const char *name,
net/core/dev.c
940
dev = dev_get_by_name(net, name);
net/core/dev.c
9477
struct net *net = dev_net(dev);
net/core/dev.c
9480
if (!net_eq(net, dev_net(iter->dev)))
net/core/dev.c
9489
if (!net_eq(net, dev_net(iter->dev)))
net/core/dev.c
9502
struct net *net = dev_net(dev);
net/core/dev.c
9505
if (!net_eq(net, dev_net(iter->dev)))
net/core/dev.c
9514
if (!net_eq(net, dev_net(iter->dev)))
net/core/dev.c
9527
struct net *net = dev_net(dev);
net/core/dev.c
9530
if (!net_eq(net, dev_net(iter->dev)))
net/core/dev.c
9539
if (!net_eq(net, dev_net(iter->dev)))
net/core/dev.c
958
struct net_device *__dev_get_by_index(struct net *net, int ifindex)
net/core/dev.c
961
struct hlist_head *head = dev_index_hash(net, ifindex);
net/core/dev.c
982
struct net_device *dev_get_by_index_rcu(struct net *net, int ifindex)
net/core/dev.c
985
struct hlist_head *head = dev_index_hash(net, ifindex);
net/core/dev.c
996
struct net_device *dev_get_by_index(struct net *net, int ifindex)
net/core/dev.h
11
struct net;
net/core/dev.h
128
int netdev_get_name(struct net *net, char *name, int ifindex);
net/core/dev.h
31
netdev_napi_by_id_lock(struct net *net, unsigned int napi_id);
net/core/dev.h
34
struct net_device *netdev_put_lock(struct net_device *dev, struct net *net,
net/core/dev.h
38
__netdev_put_lock(struct net_device *dev, struct net *net)
net/core/dev.h
40
return netdev_put_lock(dev, net, NULL);
net/core/dev.h
44
netdev_xa_find_lock(struct net *net, struct net_device *dev,
net/core/dev.h
49
#define for_each_netdev_lock_scoped(net, var_name, ifindex) \
net/core/dev.h
51
(var_name = netdev_xa_find_lock(net, var_name, &ifindex)); \
net/core/dev.h
55
netdev_get_by_index_lock_ops_compat(struct net *net, int ifindex);
net/core/dev.h
57
netdev_xa_find_lock_ops_compat(struct net *net, struct net_device *dev,
net/core/dev.h
63
#define for_each_netdev_lock_ops_compat_scoped(net, var_name, ifindex) \
net/core/dev.h
65
(var_name = netdev_xa_find_lock_ops_compat(net, var_name, \
net/core/dev_api.c
119
int dev_change_net_namespace(struct net_device *dev, struct net *net,
net/core/dev_api.c
122
return __dev_change_net_namespace(dev, net, pat, 0, NULL);
net/core/dev_ioctl.c
140
static int dev_ifsioc_locked(struct net *net, struct ifreq *ifr, unsigned int cmd)
net/core/dev_ioctl.c
143
struct net_device *dev = dev_get_by_name_rcu(net, ifr->ifr_name);
net/core/dev_ioctl.c
29
static int dev_ifname(struct net *net, struct ifreq *ifr)
net/core/dev_ioctl.c
32
return netdev_get_name(net, ifr->ifr_name, ifr->ifr_ifindex);
net/core/dev_ioctl.c
40
int dev_ifconf(struct net *net, struct ifconf __user *uifc)
net/core/dev_ioctl.c
541
static int dev_ifsioc(struct net *net, struct ifreq *ifr, void __user *data,
net/core/dev_ioctl.c
545
struct net_device *dev = __dev_get_by_name(net, ifr->ifr_name);
net/core/dev_ioctl.c
663
void dev_load(struct net *net, const char *name)
net/core/dev_ioctl.c
669
dev = dev_get_by_name_rcu(net, name);
net/core/dev_ioctl.c
69
rtnl_net_lock(net);
net/core/dev_ioctl.c
699
int dev_ioctl(struct net *net, unsigned int cmd, struct ifreq *ifr,
net/core/dev_ioctl.c
70
for_each_netdev(net, dev) {
net/core/dev_ioctl.c
708
return dev_ifname(net, ifr);
net/core/dev_ioctl.c
722
dev_load(net, ifr->ifr_name);
net/core/dev_ioctl.c
723
ret = netif_get_mac_address(&ifr->ifr_hwaddr, net,
net/core/dev_ioctl.c
741
dev_load(net, ifr->ifr_name);
net/core/dev_ioctl.c
743
ret = dev_ifsioc_locked(net, ifr, cmd);
net/core/dev_ioctl.c
750
dev_load(net, ifr->ifr_name);
net/core/dev_ioctl.c
751
ret = dev_ethtool(net, ifr, data);
net/core/dev_ioctl.c
765
dev_load(net, ifr->ifr_name);
net/core/dev_ioctl.c
766
if (!ns_capable(net->user_ns, CAP_NET_ADMIN))
net/core/dev_ioctl.c
769
rtnl_net_lock(net);
net/core/dev_ioctl.c
77
rtnl_net_unlock(net);
net/core/dev_ioctl.c
770
ret = dev_ifsioc(net, ifr, data, cmd);
net/core/dev_ioctl.c
771
rtnl_net_unlock(net);
net/core/dev_ioctl.c
808
if (!ns_capable(net->user_ns, CAP_NET_ADMIN))
net/core/dev_ioctl.c
813
dev_load(net, ifr->ifr_name);
net/core/dev_ioctl.c
815
rtnl_net_lock(net);
net/core/dev_ioctl.c
816
ret = dev_ifsioc(net, ifr, data, cmd);
net/core/dev_ioctl.c
817
rtnl_net_unlock(net);
net/core/dev_ioctl.c
82
rtnl_net_unlock(net);
net/core/dev_ioctl.c
840
dev_load(net, ifr->ifr_name);
net/core/dev_ioctl.c
842
rtnl_net_lock(net);
net/core/dev_ioctl.c
843
ret = dev_ifsioc(net, ifr, data, cmd);
net/core/dev_ioctl.c
844
rtnl_net_unlock(net);
net/core/dst.c
30
int dst_discard_out(struct net *net, struct sock *sk, struct sk_buff *skb)
net/core/failover.c
218
struct net *net = dev_net(failover_dev);
net/core/failover.c
222
for_each_netdev(net, dev) {
net/core/fib_notifier.c
106
unsigned int fib_seq = fib_seq_sum(net);
net/core/fib_notifier.c
108
err = fib_net_dump(net, nb, extack);
net/core/fib_notifier.c
112
if (fib_dump_is_consistent(net, nb, cb, fib_seq))
net/core/fib_notifier.c
120
int unregister_fib_notifier(struct net *net, struct notifier_block *nb)
net/core/fib_notifier.c
122
struct fib_notifier_net *fn_net = net_generic(net, fib_notifier_net_id);
net/core/fib_notifier.c
129
struct net *net)
net/core/fib_notifier.c
131
struct fib_notifier_net *fn_net = net_generic(net, fib_notifier_net_id);
net/core/fib_notifier.c
142
fib_notifier_ops_register(const struct fib_notifier_ops *tmpl, struct net *net)
net/core/fib_notifier.c
151
err = __fib_notifier_ops_register(ops, net);
net/core/fib_notifier.c
170
static int __net_init fib_notifier_net_init(struct net *net)
net/core/fib_notifier.c
172
struct fib_notifier_net *fn_net = net_generic(net, fib_notifier_net_id);
net/core/fib_notifier.c
179
static void __net_exit fib_notifier_net_exit(struct net *net)
net/core/fib_notifier.c
181
struct fib_notifier_net *fn_net = net_generic(net, fib_notifier_net_id);
net/core/fib_notifier.c
30
int call_fib_notifiers(struct net *net, enum fib_event_type event_type,
net/core/fib_notifier.c
33
struct fib_notifier_net *fn_net = net_generic(net, fib_notifier_net_id);
net/core/fib_notifier.c
41
static unsigned int fib_seq_sum(struct net *net)
net/core/fib_notifier.c
43
struct fib_notifier_net *fn_net = net_generic(net, fib_notifier_net_id);
net/core/fib_notifier.c
51
fib_seq += ops->fib_seq_read(net);
net/core/fib_notifier.c
59
static int fib_net_dump(struct net *net, struct notifier_block *nb,
net/core/fib_notifier.c
62
struct fib_notifier_net *fn_net = net_generic(net, fib_notifier_net_id);
net/core/fib_notifier.c
70
err = ops->fib_dump(net, nb, extack);
net/core/fib_notifier.c
82
static bool fib_dump_is_consistent(struct net *net, struct notifier_block *nb,
net/core/fib_notifier.c
86
struct fib_notifier_net *fn_net = net_generic(net, fib_notifier_net_id);
net/core/fib_notifier.c
89
if (fib_seq == fib_seq_sum(net))
net/core/fib_notifier.c
98
int register_fib_notifier(struct net *net, struct notifier_block *nb,
net/core/fib_rules.c
1006
int fib_delrule(struct net *net, struct sk_buff *skb, struct nlmsghdr *nlh,
net/core/fib_rules.c
1022
ops = lookup_rules_ops(net, frh->family);
net/core/fib_rules.c
1036
err = fib_nl2rule(net, nlh, extack, ops, tb, &nlrule, &user_priority);
net/core/fib_rules.c
104
static struct fib_rules_ops *lookup_rules_ops(const struct net *net,
net/core/fib_rules.c
1041
rtnl_net_lock(net);
net/core/fib_rules.c
1097
call_fib_rule_notifiers(net, FIB_EVENT_RULE_DEL, rule, ops, NULL);
net/core/fib_rules.c
110
list_for_each_entry_rcu(ops, &net->rules_ops, list) {
net/core/fib_rules.c
1100
rtnl_net_unlock(net);
net/core/fib_rules.c
1111
rtnl_net_unlock(net);
net/core/fib_rules.c
1293
struct net *net = sock_net(skb->sk);
net/core/fib_rules.c
1307
ops = lookup_rules_ops(net, family);
net/core/fib_rules.c
1316
list_for_each_entry_rcu(ops, &net->rules_ops, list) {
net/core/fib_rules.c
1338
struct net *net;
net/core/fib_rules.c
1342
net = ops->fro_net;
net/core/fib_rules.c
1355
rtnl_notify(skb, net, pid, ops->nlgroup, nlh, GFP_KERNEL);
net/core/fib_rules.c
1358
rtnl_set_sk_err(net, ops->nlgroup, err);
net/core/fib_rules.c
139
struct net *net;
net/core/fib_rules.c
1402
struct net *net = dev_net(dev);
net/core/fib_rules.c
1409
list_for_each_entry(ops, &net->rules_ops, list)
net/core/fib_rules.c
141
net = ops->fro_net;
net/core/fib_rules.c
1414
list_for_each_entry(ops, &net->rules_ops, list) {
net/core/fib_rules.c
1421
list_for_each_entry(ops, &net->rules_ops, list)
net/core/fib_rules.c
1433
static int __net_init fib_rules_net_init(struct net *net)
net/core/fib_rules.c
1435
INIT_LIST_HEAD(&net->rules_ops);
net/core/fib_rules.c
1436
spin_lock_init(&net->rules_mod_lock);
net/core/fib_rules.c
1440
static void __net_exit fib_rules_net_exit(struct net *net)
net/core/fib_rules.c
1442
WARN_ON_ONCE(!list_empty(&net->rules_ops));
net/core/fib_rules.c
151
spin_lock(&net->rules_mod_lock);
net/core/fib_rules.c
152
list_for_each_entry(o, &net->rules_ops, list)
net/core/fib_rules.c
156
list_add_tail_rcu(&ops->list, &net->rules_ops);
net/core/fib_rules.c
159
spin_unlock(&net->rules_mod_lock);
net/core/fib_rules.c
165
fib_rules_register(const struct fib_rules_ops *tmpl, struct net *net)
net/core/fib_rules.c
175
ops->fro_net = net;
net/core/fib_rules.c
201
struct net *net = ops->fro_net;
net/core/fib_rules.c
203
spin_lock(&net->rules_mod_lock);
net/core/fib_rules.c
205
spin_unlock(&net->rules_mod_lock);
net/core/fib_rules.c
382
static int call_fib_rule_notifiers(struct net *net,
net/core/fib_rules.c
394
ASSERT_RTNL_NET(net);
net/core/fib_rules.c
398
return call_fib_notifiers(net, event_type, &info.info);
net/core/fib_rules.c
402
int fib_rules_dump(struct net *net, struct notifier_block *nb, int family,
net/core/fib_rules.c
409
ops = lookup_rules_ops(net, family);
net/core/fib_rules.c
428
unsigned int fib_rules_seq_read(const struct net *net, int family)
net/core/fib_rules.c
433
ops = lookup_rules_ops(net, family);
net/core/fib_rules.c
573
static int fib_nl2rule(struct net *net, struct nlmsghdr *nlh,
net/core/fib_rules.c
606
nlrule->fr_net = net;
net/core/fib_rules.c
675
if (current_user_ns() != net->user_ns) {
net/core/fib_rules.c
877
int fib_newrule(struct net *net, struct sk_buff *skb, struct nlmsghdr *nlh,
net/core/fib_rules.c
893
ops = lookup_rules_ops(net, frh->family);
net/core/fib_rules.c
907
err = fib_nl2rule(net, nlh, extack, ops, tb, &rule, &user_priority);
net/core/fib_rules.c
912
rtnl_net_lock(net);
net/core/fib_rules.c
928
err = call_fib_rule_notifiers(net, FIB_EVENT_RULE_ADD, rule, ops,
net/core/fib_rules.c
982
rtnl_net_unlock(net);
net/core/fib_rules.c
992
rtnl_net_unlock(net);
net/core/filter.c
12355
struct net *net;
net/core/filter.c
12366
net = dev_net(skb->dev);
net/core/filter.c
12367
if (net != sock_net(sk))
net/core/filter.c
12393
if (!READ_ONCE(net->ipv4.sysctl_tcp_window_scaling))
net/core/filter.c
12401
if (attrs->sack_ok && !READ_ONCE(net->ipv4.sysctl_tcp_sack))
net/core/filter.c
12405
if (!READ_ONCE(net->ipv4.sysctl_tcp_timestamps))
net/core/filter.c
2213
static int bpf_out_neigh_v6(struct net *net, struct sk_buff *skb,
net/core/filter.c
2261
IP6_INC_STATS(net, ip6_dst_idev(dst), IPSTATS_MIB_OUTNOROUTES);
net/core/filter.c
2271
struct net *net = dev_net(dev);
net/core/filter.c
2286
dst = ip6_dst_lookup_flow(net, NULL, &fl6, NULL);
net/core/filter.c
2296
err = bpf_out_neigh_v6(net, skb, dev, nh);
net/core/filter.c
2318
static int bpf_out_neigh_v4(struct net *net, struct sk_buff *skb,
net/core/filter.c
2380
struct net *net = dev_net(dev);
net/core/filter.c
2395
rt = ip_route_output_flow(net, &fl4, NULL);
net/core/filter.c
2407
err = bpf_out_neigh_v4(net, skb, dev, nh);
net/core/filter.c
2522
struct net *net = dev_net(skb->dev);
net/core/filter.c
2526
dev = dev_get_by_index_rcu(net, ri->tgt_index);
net/core/filter.c
2537
net_eq(net, dev_net(dev))))
net/core/filter.c
5285
const struct net *net = sk ? sock_net(sk) : &init_net;
net/core/filter.c
5287
return net->net_cookie;
net/core/filter.c
6221
static int bpf_ipv4_fib_lookup(struct net *net, struct bpf_fib_lookup *params,
net/core/filter.c
6233
dev = dev_get_by_index_rcu(net, params->ifindex);
net/core/filter.c
6270
tb = fib_get_table(net, tbid);
net/core/filter.c
6282
fl4.flowi4_uid = sock_net_uid(net, NULL);
net/core/filter.c
6284
err = fib_lookup(net, &fl4, &res, FIB_LOOKUP_NOREF);
net/core/filter.c
6303
fib_select_path(net, &res, &fl4, NULL);
net/core/filter.c
6325
params->ipv4_src = fib_result_prefsrc(net, &res);
net/core/filter.c
6360
static int bpf_ipv6_fib_lookup(struct net *net, struct bpf_fib_lookup *params,
net/core/filter.c
6378
dev = dev_get_by_index_rcu(net, params->ifindex);
net/core/filter.c
6415
tb = fib6_get_table(net, tbid);
net/core/filter.c
6419
err = fib6_table_lookup(net, tb, oif, &fl6, &res, strict);
net/core/filter.c
6427
fl6.flowi6_uid = sock_net_uid(net, NULL);
net/core/filter.c
6429
err = fib6_lookup(net, oif, &fl6, &res, strict);
net/core/filter.c
6433
res.f6i == net->ipv6.fib6_null_entry))
net/core/filter.c
6450
fib6_select_path(net, &res, &fl6, fl6.flowi6_oif,
net/core/filter.c
6475
err = ipv6_dev_get_saddr(net, dev, &fl6.daddr, 0, src);
net/core/filter.c
6539
struct net *net = dev_net(skb->dev);
net/core/filter.c
6555
rc = bpf_ipv4_fib_lookup(net, params, flags, check_mtu);
net/core/filter.c
6560
rc = bpf_ipv6_fib_lookup(net, params, flags, check_mtu);
net/core/filter.c
6571
dev = dev_get_by_index_rcu(net, params->ifindex);
net/core/filter.c
6596
struct net *netns = dev_net(dev_curr);
net/core/filter.c
6995
static struct sock *sk_lookup(struct net *net, struct bpf_sock_tuple *tuple,
net/core/filter.c
7006
sk = __inet_lookup(net, NULL, 0,
net/core/filter.c
7011
sk = __udp4_lib_lookup(net, src4, tuple->ipv4.sport,
net/core/filter.c
7020
sk = __inet6_lookup(net, NULL, 0,
net/core/filter.c
7025
sk = __udp6_lib_lookup(net, src6, tuple->ipv6.sport,
net/core/filter.c
7043
struct net *caller_net, u32 ifindex, u8 proto, u64 netns_id,
net/core/filter.c
7047
struct net *net;
net/core/filter.c
7068
net = caller_net;
net/core/filter.c
7069
sk = sk_lookup(net, tuple, ifindex, sdif, family, proto);
net/core/filter.c
7071
net = get_net_ns_by_id(caller_net, netns_id);
net/core/filter.c
7072
if (unlikely(!net))
net/core/filter.c
7074
sk = sk_lookup(net, tuple, ifindex, sdif, family, proto);
net/core/filter.c
7075
put_net(net);
net/core/filter.c
7084
struct net *caller_net, u32 ifindex, u8 proto, u64 netns_id,
net/core/filter.c
7115
struct net *caller_net;
net/core/filter.c
7219
struct net *caller_net = dev_net(dev);
net/core/filter.c
7243
struct net *caller_net = dev_net(dev);
net/core/filter.c
7267
struct net *caller_net = dev_net(dev);
net/core/filter.c
7305
struct net *caller_net = dev_net(dev);
net/core/filter.c
7329
struct net *caller_net = dev_net(dev);
net/core/filter.c
7353
struct net *caller_net = dev_net(dev);
net/core/flow_dissector.c
1057
bool __skb_flow_dissect(const struct net *net,
net/core/flow_dissector.c
1123
if (!net) {
net/core/flow_dissector.c
1125
net = dev_net_rcu(skb->dev);
net/core/flow_dissector.c
1127
net = sock_net(skb->sk);
net/core/flow_dissector.c
1131
DEBUG_NET_WARN_ON_ONCE(!net);
net/core/flow_dissector.c
1132
if (net) {
net/core/flow_dissector.c
1138
run_array = rcu_dereference(net->bpf.run_array[type]);
net/core/flow_dissector.c
1872
u32 __skb_get_hash_symmetric_net(const struct net *net, const struct sk_buff *skb)
net/core/flow_dissector.c
1879
__skb_flow_dissect(net, skb, &flow_keys_dissector_symmetric,
net/core/flow_dissector.c
1896
void __skb_get_hash_net(const struct net *net, struct sk_buff *skb)
net/core/flow_dissector.c
1903
__skb_flow_dissect(net, skb, &flow_keys_dissector,
net/core/flow_dissector.c
77
int flow_dissector_bpf_prog_attach_check(struct net *net,
net/core/flow_dissector.c
82
if (net == &init_net) {
net/core/flow_dissector.c
88
struct net *ns;
net/core/lock_debug.c
16
struct net *net = dev_net(dev);
net/core/lock_debug.c
69
ASSERT_RTNL_NET(net);
net/core/lock_debug.c
79
static int __net_init rtnl_net_debug_net_init(struct net *net)
net/core/lock_debug.c
83
nb = net_generic(net, rtnl_net_debug_net_id);
net/core/lock_debug.c
86
return register_netdevice_notifier_net(net, nb);
net/core/lock_debug.c
89
static void __net_exit rtnl_net_debug_net_exit(struct net *net)
net/core/lock_debug.c
93
nb = net_generic(net, rtnl_net_debug_net_id);
net/core/lock_debug.c
94
unregister_netdevice_notifier_net(net, nb);
net/core/lwt_bpf.c
147
static int bpf_output(struct net *net, struct sock *sk, struct sk_buff *skb)
net/core/lwt_bpf.c
167
return dst->lwtstate->orig_output(net, sk, skb);
net/core/lwt_bpf.c
189
struct net *net;
net/core/lwt_bpf.c
203
net = sock_net(sk);
net/core/lwt_bpf.c
205
net = dev_net(skb_dst(skb)->dev);
net/core/lwt_bpf.c
215
fl4.flowi4_uid = sock_net_uid(net, sk);
net/core/lwt_bpf.c
222
rt = ip_route_output_key(net, &fl4);
net/core/lwt_bpf.c
234
fl6.flowi6_uid = sock_net_uid(net, sk);
net/core/lwt_bpf.c
240
dst = ip6_dst_lookup_flow(net, skb->sk, &fl6, NULL);
net/core/lwt_bpf.c
378
static int bpf_build_state(struct net *net, struct nlattr *nla,
net/core/lwtunnel.c
113
int lwtunnel_build_state(struct net *net, u16 encap_type,
net/core/lwtunnel.c
137
ret = ops->build_state(net, encap, family, cfg, lws, extack);
net/core/lwtunnel.c
320
int lwtunnel_output(struct net *net, struct sock *sk, struct sk_buff *skb)
net/core/lwtunnel.c
356
ret = ops->output(net, sk, skb);
net/core/neighbour.c
1747
struct net *net, int ifindex)
net/core/neighbour.c
1752
if ((p->dev && p->dev->ifindex == ifindex && net_eq(neigh_parms_net(p), net)) ||
net/core/neighbour.c
1753
(!p->dev && !ifindex && net_eq(net, &init_net)))
net/core/neighbour.c
1764
struct net *net = dev_net(dev);
net/core/neighbour.c
1775
write_pnet(&p->net, net);
net/core/neighbour.c
1831
write_pnet(&tbl->parms.net, &init_net);
net/core/neighbour.c
1948
struct net *net = sock_net(skb->sk);
net/core/neighbour.c
1968
dev = __dev_get_by_index(net, ndm->ndm_ifindex);
net/core/neighbour.c
1985
err = pneigh_delete(tbl, net, nla_data(dst_attr), dev);
net/core/neighbour.c
2015
struct net *net = sock_net(skb->sk);
net/core/neighbour.c
2049
dev = __dev_get_by_index(net, ndm->ndm_ifindex);
net/core/neighbour.c
2081
err = pneigh_create(tbl, net, dst, dev, ndm_flags, protocol,
net/core/neighbour.c
2384
struct net *net = sock_net(skb->sk);
net/core/neighbour.c
2445
p = lookup_neigh_parms(tbl, net, ifindex);
net/core/neighbour.c
2530
!net_eq(net, &init_net))
net/core/neighbour.c
2581
struct net *net = sock_net(skb->sk);
net/core/neighbour.c
2616
if (!net_eq(neigh_parms_net(p), net))
net/core/neighbour.c
2796
struct net *net = sock_net(skb->sk);
net/core/neighbour.c
2813
if (idx < s_idx || !net_eq(dev_net(n->dev), net))
net/core/neighbour.c
2838
struct net *net = sock_net(skb->sk);
net/core/neighbour.c
2852
if (idx < s_idx || pneigh_net(n) != net)
net/core/neighbour.c
3059
struct net *net = sock_net(in_skb->sk);
net/core/neighbour.c
3100
dev = dev_get_by_index_rcu(net, ndm->ndm_ifindex);
net/core/neighbour.c
3111
pn = pneigh_lookup(tbl, net, dst, dev);
net/core/neighbour.c
3137
return rtnl_unicast(skb, net, pid);
net/core/neighbour.c
3248
struct net *net = seq_file_net(seq);
net/core/neighbour.c
3250
if (!net_eq(dev_net(n->dev), net))
net/core/neighbour.c
3340
struct net *net = seq_file_net(seq);
net/core/neighbour.c
3349
while (pn && !net_eq(pneigh_net(pn), net))
net/core/neighbour.c
3364
struct net *net = seq_file_net(seq);
net/core/neighbour.c
3369
} while (pn && !net_eq(pneigh_net(pn), net));
net/core/neighbour.c
3377
while (pn && !net_eq(pneigh_net(pn), net))
net/core/neighbour.c
352
static void pneigh_queue_purge(struct sk_buff_head *list, struct net *net,
net/core/neighbour.c
3562
struct net *net;
net/core/neighbour.c
3565
net = dev_net_rcu(n->dev);
net/core/neighbour.c
3577
rtnl_notify(skb, net, 0, RTNLGRP_NEIGH, NULL, GFP_ATOMIC);
net/core/neighbour.c
3580
rtnl_set_sk_err(net, RTNLGRP_NEIGH, err);
net/core/neighbour.c
3619
static void neigh_copy_dflt_parms(struct net *net, struct neigh_parms *p,
net/core/neighbour.c
3626
for_each_netdev_rcu(net, dev) {
net/core/neighbour.c
3640
struct net *net = neigh_parms_net(p);
net/core/neighbour.c
3650
neigh_copy_dflt_parms(net, p, index);
net/core/neighbour.c
366
if (net == NULL || net_eq(dev_net(dev), net)) {
net/core/neighbour.c
755
struct net *net, const void *pkey,
net/core/neighbour.c
769
net_eq(pneigh_net(n), net) &&
net/core/neighbour.c
779
int pneigh_create(struct neigh_table *tbl, struct net *net,
net/core/neighbour.c
790
n = pneigh_lookup(tbl, net, pkey, dev);
net/core/neighbour.c
801
write_pnet(&n->net, net);
net/core/neighbour.c
834
int pneigh_delete(struct neigh_table *tbl, struct net *net, const void *pkey,
net/core/neighbour.c
850
net_eq(pneigh_net(n), net)) {
net/core/net-procfs.c
232
struct net *net = seq_file_net(seq);
net/core/net-procfs.c
257
nxt = READ_ONCE(net->ptype_all.next);
net/core/net-procfs.c
263
if (nxt != &net->ptype_all && nxt != &net->ptype_specific)
net/core/net-procfs.c
266
if (nxt == &net->ptype_all) {
net/core/net-procfs.c
268
nxt = READ_ONCE(net->ptype_specific.next);
net/core/net-procfs.c
269
if (nxt != &net->ptype_specific)
net/core/net-procfs.c
325
static int __net_init dev_proc_net_init(struct net *net)
net/core/net-procfs.c
329
if (!proc_create_net("dev", 0444, net->proc_net, &dev_seq_ops,
net/core/net-procfs.c
332
if (!proc_create_seq("softnet_stat", 0444, net->proc_net,
net/core/net-procfs.c
335
if (!proc_create_net("ptype", 0444, net->proc_net, &ptype_seq_ops,
net/core/net-procfs.c
339
if (wext_proc_init(net))
net/core/net-procfs.c
345
remove_proc_entry("ptype", net->proc_net);
net/core/net-procfs.c
347
remove_proc_entry("softnet_stat", net->proc_net);
net/core/net-procfs.c
349
remove_proc_entry("dev", net->proc_net);
net/core/net-procfs.c
353
static void __net_exit dev_proc_net_exit(struct net *net)
net/core/net-procfs.c
355
wext_proc_exit(net);
net/core/net-procfs.c
357
remove_proc_entry("ptype", net->proc_net);
net/core/net-procfs.c
358
remove_proc_entry("softnet_stat", net->proc_net);
net/core/net-procfs.c
359
remove_proc_entry("dev", net->proc_net);
net/core/net-procfs.c
393
static int __net_init dev_mc_net_init(struct net *net)
net/core/net-procfs.c
395
if (!proc_create_net("dev_mcast", 0, net->proc_net, &dev_mc_seq_ops,
net/core/net-procfs.c
401
static void __net_exit dev_mc_net_exit(struct net *net)
net/core/net-procfs.c
403
remove_proc_entry("dev_mcast", net->proc_net);
net/core/net-sysfs.c
1179
net_ns_get_ownership(ns ? container_of(ns, struct net, ns) : NULL,
net/core/net-sysfs.c
163
struct net *net = dev_net(netdev);
net/core/net-sysfs.c
167
if (!ns_capable(net->user_ns, CAP_NET_ADMIN))
net/core/net-sysfs.c
1853
struct net *net = dev_net(dev);
net/core/net-sysfs.c
1858
if (!ns_capable(net->user_ns, CAP_NET_ADMIN))
net/core/net-sysfs.c
1929
net_ns_get_ownership(ns ? container_of(ns, struct net, ns) : NULL,
net/core/net-sysfs.c
194
struct net *net = dev_net(netdev);
net/core/net-sysfs.c
198
if (!ns_capable(net->user_ns, CAP_NET_ADMIN))
net/core/net-sysfs.c
2162
struct net *net = current->nsproxy->net_ns;
net/core/net-sysfs.c
2164
return ns_capable(net->user_ns, CAP_SYS_ADMIN);
net/core/net-sysfs.c
2169
struct net *net = current->nsproxy->net_ns;
net/core/net-sysfs.c
2171
if (net)
net/core/net-sysfs.c
2172
refcount_inc(&net->passive);
net/core/net-sysfs.c
2174
return net ? to_ns_common(net) : NULL;
net/core/net-sysfs.c
2244
const struct net *net = dev_net(dev);
net/core/net-sysfs.c
2246
net_ns_get_ownership(net, uid, gid);
net/core/net-sysfs.c
2355
int netdev_change_owner(struct net_device *ndev, const struct net *net_old,
net/core/net-sysfs.c
2356
const struct net *net_new)
net/core/net-sysfs.c
564
struct net *net = dev_net(netdev);
net/core/net-sysfs.c
568
if (!ns_capable(net->user_ns, CAP_NET_ADMIN))
net/core/net-sysfs.h
11
int netdev_change_owner(struct net_device *, const struct net *net_old,
net/core/net-sysfs.h
12
const struct net *net_new);
net/core/net-sysfs.h
9
int netdev_queue_update_kobjects(struct net_device *net,
net/core/net_namespace.c
1006
struct net *peer, *target = net;
net/core/net_namespace.c
1021
peer = get_net_ns_by_id(net, nla_get_s32(tb[NETNSA_NSID]));
net/core/net_namespace.c
1048
fillargs.ref_nsid = peernet2id(net, peer);
net/core/net_namespace.c
1062
err = rtnl_unicast(msg, net, NETLINK_CB(skb).portid);
net/core/net_namespace.c
1075
struct net *tgt_net;
net/core/net_namespace.c
1076
struct net *ref_net;
net/core/net_namespace.c
1123
struct net *net;
net/core/net_namespace.c
1125
net = rtnl_get_net_ns_capable(sk, nla_get_s32(tb[i]));
net/core/net_namespace.c
1126
if (IS_ERR(net)) {
net/core/net_namespace.c
1130
return PTR_ERR(net);
net/core/net_namespace.c
1134
net_cb->tgt_net = net;
net/core/net_namespace.c
115
rcu_assign_pointer(net->gen, ng);
net/core/net_namespace.c
1179
static void rtnl_net_notifyid(struct net *net, int cmd, int id, u32 portid,
net/core/net_namespace.c
1199
rtnl_notify(msg, net, portid, RTNLGRP_NSID, nlh, gfp);
net/core/net_namespace.c
120
static int ops_init(const struct pernet_operations *ops, struct net *net)
net/core/net_namespace.c
1205
rtnl_set_sk_err(net, RTNLGRP_NSID, err);
net/core/net_namespace.c
1265
net_cachep = kmem_cache_create("net_namespace", sizeof(struct net),
net/core/net_namespace.c
1309
struct net *net;
net/core/net_namespace.c
131
err = net_assign_generic(net, *ops->id, data);
net/core/net_namespace.c
1317
for_each_net(net) {
net/core/net_namespace.c
1318
error = ops_init(ops, net);
net/core/net_namespace.c
1321
list_add_tail(&net->exit_list, &net_exit_list);
net/core/net_namespace.c
1336
struct net *net;
net/core/net_namespace.c
1339
for_each_net(net)
net/core/net_namespace.c
1340
list_add_tail(&net->exit_list, &net_exit_list);
net/core/net_namespace.c
137
err = ops->init(net);
net/core/net_namespace.c
142
ng = rcu_dereference_protected(net->gen,
net/core/net_namespace.c
1512
struct net *net = NULL;
net/core/net_namespace.c
1518
net = get_net(nsproxy->net_ns);
net/core/net_namespace.c
1521
return net ? &net->ns : NULL;
net/core/net_namespace.c
1532
struct net *net = to_net_ns(ns);
net/core/net_namespace.c
1534
if (!ns_capable(net->user_ns, CAP_SYS_ADMIN) ||
net/core/net_namespace.c
1539
nsproxy->net_ns = get_net(net);
net/core/net_namespace.c
157
struct net *net;
net/core/net_namespace.c
160
list_for_each_entry(net, net_exit_list, exit_list)
net/core/net_namespace.c
161
ops->pre_exit(net);
net/core/net_namespace.c
171
struct net *net;
net/core/net_namespace.c
175
list_for_each_entry(net, net_exit_list, exit_list) {
net/core/net_namespace.c
176
__rtnl_net_lock(net);
net/core/net_namespace.c
181
ops->exit_rtnl(net, &dev_kill_list);
net/core/net_namespace.c
184
__rtnl_net_unlock(net);
net/core/net_namespace.c
196
struct net *net;
net/core/net_namespace.c
198
list_for_each_entry(net, net_exit_list, exit_list) {
net/core/net_namespace.c
199
ops->exit(net);
net/core/net_namespace.c
211
struct net *net;
net/core/net_namespace.c
214
list_for_each_entry(net, net_exit_list, exit_list)
net/core/net_namespace.c
215
kfree(net_generic(net, *ops->id));
net/core/net_namespace.c
270
static int alloc_netid(struct net *net, struct net *peer, int reqid)
net/core/net_namespace.c
279
return idr_alloc(&net->netns_ids, peer, min, max, GFP_ATOMIC);
net/core/net_namespace.c
288
static int net_eq_idr(int id, void *net, void *peer)
net/core/net_namespace.c
290
if (net_eq(net, peer))
net/core/net_namespace.c
296
static int __peernet2id(const struct net *net, struct net *peer)
net/core/net_namespace.c
298
int id = idr_for_each(&net->netns_ids, net_eq_idr, peer);
net/core/net_namespace.c
309
static void rtnl_net_notifyid(struct net *net, int cmd, int id, u32 portid,
net/core/net_namespace.c
314
int peernet2id_alloc(struct net *net, struct net *peer, gfp_t gfp)
net/core/net_namespace.c
318
if (!check_net(net))
net/core/net_namespace.c
321
spin_lock(&net->nsid_lock);
net/core/net_namespace.c
322
id = __peernet2id(net, peer);
net/core/net_namespace.c
324
spin_unlock(&net->nsid_lock);
net/core/net_namespace.c
334
spin_unlock(&net->nsid_lock);
net/core/net_namespace.c
338
id = alloc_netid(net, peer, -1);
net/core/net_namespace.c
339
spin_unlock(&net->nsid_lock);
net/core/net_namespace.c
345
rtnl_net_notifyid(net, RTM_NEWNSID, id, 0, NULL, gfp);
net/core/net_namespace.c
352
int peernet2id(const struct net *net, struct net *peer)
net/core/net_namespace.c
357
id = __peernet2id(net, peer);
net/core/net_namespace.c
367
bool peernet_has_id(const struct net *net, struct net *peer)
net/core/net_namespace.c
369
return peernet2id(net, peer) >= 0;
net/core/net_namespace.c
372
struct net *get_net_ns_by_id(const struct net *net, int id)
net/core/net_namespace.c
374
struct net *peer;
net/core/net_namespace.c
380
peer = idr_find(&net->netns_ids, id);
net/core/net_namespace.c
389
static __net_init void preinit_net_sysctl(struct net *net)
net/core/net_namespace.c
391
net->core.sysctl_somaxconn = SOMAXCONN;
net/core/net_namespace.c
395
net->core.sysctl_optmem_max = 128 * 1024;
net/core/net_namespace.c
396
net->core.sysctl_txrehash = SOCK_TXREHASH_ENABLED;
net/core/net_namespace.c
397
net->core.sysctl_tstamp_allow_data = 1;
net/core/net_namespace.c
398
net->core.sysctl_txq_reselection = msecs_to_jiffies(1000);
net/core/net_namespace.c
402
static __net_init int preinit_net(struct net *net, struct user_namespace *user_ns)
net/core/net_namespace.c
406
ret = ns_common_init(net);
net/core/net_namespace.c
410
refcount_set(&net->passive, 1);
net/core/net_namespace.c
411
ref_tracker_dir_init(&net->refcnt_tracker, 128, "net_refcnt");
net/core/net_namespace.c
412
ref_tracker_dir_init(&net->notrefcnt_tracker, 128, "net_notrefcnt");
net/core/net_namespace.c
414
net->hash_mix = get_random_u32();
net/core/net_namespace.c
415
net->dev_base_seq = 1;
net/core/net_namespace.c
416
net->user_ns = user_ns;
net/core/net_namespace.c
418
idr_init(&net->netns_ids);
net/core/net_namespace.c
419
spin_lock_init(&net->nsid_lock);
net/core/net_namespace.c
420
mutex_init(&net->ipv4.ra_mutex);
net/core/net_namespace.c
423
mutex_init(&net->rtnl_mutex);
net/core/net_namespace.c
424
lock_set_cmp_fn(&net->rtnl_mutex, rtnl_net_lock_cmp_fn, NULL);
net/core/net_namespace.c
427
INIT_LIST_HEAD(&net->ptype_all);
net/core/net_namespace.c
428
INIT_LIST_HEAD(&net->ptype_specific);
net/core/net_namespace.c
429
preinit_net_sysctl(net);
net/core/net_namespace.c
436
static __net_init int setup_net(struct net *net)
net/core/net_namespace.c
443
net->net_cookie = ns_tree_gen_id(net);
net/core/net_namespace.c
446
error = ops_init(ops, net);
net/core/net_namespace.c
451
list_add_tail_rcu(&net->list, &net_namespace_list);
net/core/net_namespace.c
453
ns_tree_add_raw(net);
net/core/net_namespace.c
461
list_add(&net->exit_list, &net_exit_list);
net/core/net_namespace.c
481
static struct net *net_alloc(void)
net/core/net_namespace.c
483
struct net *net = NULL;
net/core/net_namespace.c
49
struct net init_net;
net/core/net_namespace.c
490
net = kmem_cache_zalloc(net_cachep, GFP_KERNEL);
net/core/net_namespace.c
491
if (!net)
net/core/net_namespace.c
495
net->key_domain = kzalloc_obj(struct key_tag);
net/core/net_namespace.c
496
if (!net->key_domain)
net/core/net_namespace.c
498
refcount_set(&net->key_domain->usage, 1);
net/core/net_namespace.c
501
rcu_assign_pointer(net->gen, ng);
net/core/net_namespace.c
503
return net;
net/core/net_namespace.c
507
kmem_cache_free(net_cachep, net);
net/core/net_namespace.c
508
net = NULL;
net/core/net_namespace.c
520
struct net *net, *next;
net/core/net_namespace.c
525
llist_for_each_entry_safe(net, next, kill_list, defer_free_list)
net/core/net_namespace.c
526
kmem_cache_free(net_cachep, net);
net/core/net_namespace.c
530
void net_passive_dec(struct net *net)
net/core/net_namespace.c
532
if (refcount_dec_and_test(&net->passive)) {
net/core/net_namespace.c
533
kfree(rcu_access_pointer(net->gen));
net/core/net_namespace.c
536
ref_tracker_dir_exit(&net->notrefcnt_tracker);
net/core/net_namespace.c
539
llist_add(&net->defer_free_list, &defer_free_list);
net/core/net_namespace.c
549
struct net *copy_net_ns(u64 flags,
net/core/net_namespace.c
550
struct user_namespace *user_ns, struct net *old_net)
net/core/net_namespace.c
553
struct net *net;
net/core/net_namespace.c
563
net = net_alloc();
net/core/net_namespace.c
564
if (!net) {
net/core/net_namespace.c
569
rv = preinit_net(net, user_ns);
net/core/net_namespace.c
572
net->ucounts = ucounts;
net/core/net_namespace.c
579
rv = setup_net(net);
net/core/net_namespace.c
585
ns_common_free(net);
net/core/net_namespace.c
587
key_remove_domain(net->key_domain);
net/core/net_namespace.c
590
net_passive_dec(net);
net/core/net_namespace.c
595
return net;
net/core/net_namespace.c
607
void net_ns_get_ownership(const struct net *net, kuid_t *uid, kgid_t *gid)
net/core/net_namespace.c
609
if (net) {
net/core/net_namespace.c
610
kuid_t ns_root_uid = make_kuid(net->user_ns, 0);
net/core/net_namespace.c
611
kgid_t ns_root_gid = make_kgid(net->user_ns, 0);
net/core/net_namespace.c
625
static void unhash_nsid(struct net *last)
net/core/net_namespace.c
627
struct net *tmp, *peer;
net/core/net_namespace.c
665
struct net *net, *tmp, *last;
net/core/net_namespace.c
677
llist_for_each_entry(net, net_kill_list, cleanup_list) {
net/core/net_namespace.c
678
ns_tree_remove(net);
net/core/net_namespace.c
679
list_del_rcu(&net->list);
net/core/net_namespace.c
680
net->is_dying = true;
net/core/net_namespace.c
692
last = list_last_entry(&net_namespace_list, struct net, list);
net/core/net_namespace.c
697
llist_for_each_entry(net, net_kill_list, cleanup_list) {
net/core/net_namespace.c
698
idr_destroy(&net->netns_ids);
net/core/net_namespace.c
699
list_add_tail(&net->exit_list, &net_exit_list);
net/core/net_namespace.c
714
list_for_each_entry_safe(net, tmp, &net_exit_list, exit_list) {
net/core/net_namespace.c
715
list_del_init(&net->exit_list);
net/core/net_namespace.c
716
ns_common_free(net);
net/core/net_namespace.c
717
dec_net_namespaces(net->ucounts);
net/core/net_namespace.c
719
key_remove_domain(net->key_domain);
net/core/net_namespace.c
721
put_user_ns(net->user_ns);
net/core/net_namespace.c
722
net_passive_dec(net);
net/core/net_namespace.c
745
void __put_net(struct net *net)
net/core/net_namespace.c
747
ref_tracker_dir_exit(&net->refcnt_tracker);
net/core/net_namespace.c
749
if (llist_add(&net->cleanup_list, &cleanup_list))
net/core/net_namespace.c
762
struct net *net;
net/core/net_namespace.c
764
net = maybe_get_net(container_of(ns, struct net, ns));
net/core/net_namespace.c
765
if (net)
net/core/net_namespace.c
766
return &net->ns;
net/core/net_namespace.c
771
struct net *get_net_ns_by_fd(int fd)
net/core/net_namespace.c
781
return get_net(container_of(ns, struct net, ns));
net/core/net_namespace.c
789
struct net *get_net_ns_by_pid(pid_t pid)
net/core/net_namespace.c
792
struct net *net;
net/core/net_namespace.c
795
net = ERR_PTR(-ESRCH);
net/core/net_namespace.c
803
net = get_net(nsproxy->net_ns);
net/core/net_namespace.c
807
return net;
net/core/net_namespace.c
812
static void net_ns_net_debugfs(struct net *net)
net/core/net_namespace.c
814
ref_tracker_dir_symlink(&net->refcnt_tracker, "netns-%llx-%u-refcnt",
net/core/net_namespace.c
815
net->net_cookie, net->ns.inum);
net/core/net_namespace.c
816
ref_tracker_dir_symlink(&net->notrefcnt_tracker, "netns-%llx-%u-notrefcnt",
net/core/net_namespace.c
817
net->net_cookie, net->ns.inum);
net/core/net_namespace.c
829
static void net_ns_net_debugfs(struct net *net)
net/core/net_namespace.c
83
static int net_assign_generic(struct net *net, unsigned int id, void *data)
net/core/net_namespace.c
834
static __net_init int net_ns_net_init(struct net *net)
net/core/net_namespace.c
836
net_ns_net_debugfs(net);
net/core/net_namespace.c
855
struct net *net = sock_net(skb->sk);
net/core/net_namespace.c
858
struct net *peer;
net/core/net_namespace.c
887
spin_lock(&net->nsid_lock);
net/core/net_namespace.c
888
if (__peernet2id(net, peer) >= 0) {
net/core/net_namespace.c
889
spin_unlock(&net->nsid_lock);
net/core/net_namespace.c
89
old_ng = rcu_dereference_protected(net->gen,
net/core/net_namespace.c
897
err = alloc_netid(net, peer, nsid);
net/core/net_namespace.c
898
spin_unlock(&net->nsid_lock);
net/core/net_namespace.c
900
rtnl_net_notifyid(net, RTM_NEWNSID, err, NETLINK_CB(skb).portid,
net/core/net_namespace.c
999
struct net *net = sock_net(skb->sk);
net/core/netdev-genl.c
1265
struct net *net;
net/core/netdev-genl.c
1335
net = genl_info_net(info);
net/core/netdev-genl.c
1337
net = get_net_ns_by_id(net, netns_lease);
net/core/netdev-genl.c
1338
if (!net) {
net/core/netdev-genl.c
1344
dev_lease = netdev_get_by_index(net, ifindex_lease, &dev_tracker,
net/core/netdev-genl.c
1356
dev_lease = netdev_put_lock(dev_lease, net, &dev_tracker);
net/core/netdev-genl.c
1403
put_net(net);
net/core/netdev-genl.c
1411
put_net(net);
net/core/netdev-genl.c
150
struct net *net = sock_net(skb->sk);
net/core/netdev-genl.c
153
for_each_netdev_lock_scoped(net, netdev, ctx->ifindex) {
net/core/netdev-genl.c
298
struct net *net = sock_net(skb->sk);
net/core/netdev-genl.c
307
netdev = netdev_get_by_index_lock(net, ifindex);
net/core/netdev-genl.c
315
for_each_netdev_lock_scoped(net, netdev, ctx->ifindex) {
net/core/netdev-genl.c
398
struct net *net, *peer_net;
net/core/netdev-genl.c
423
net = dev_net_rcu(orig_netdev);
net/core/netdev-genl.c
424
if (!net_eq(net, peer_net)) {
net/core/netdev-genl.c
425
s32 id = peernet2id_alloc(net, peer_net, GFP_ATOMIC);
net/core/netdev-genl.c
622
struct net *net = sock_net(skb->sk);
net/core/netdev-genl.c
631
netdev = netdev_get_by_index_lock_ops_compat(net, ifindex);
net/core/netdev-genl.c
639
for_each_netdev_lock_ops_compat_scoped(net, netdev,
net/core/netdev-genl.c
906
struct net *net = sock_net(skb->sk);
net/core/netdev-genl.c
921
netdev = netdev_get_by_index_lock_ops_compat(net, ifindex);
net/core/netdev-genl.c
939
for_each_netdev_lock_ops_compat_scoped(net, netdev, ctx->ifindex) {
net/core/netpoll.c
549
struct net *net = current->nsproxy->net_ns;
net/core/netpoll.c
557
ndev = __dev_get_by_name(net, np->dev_name);
net/core/netpoll.c
559
ndev = dev_getbyhwaddr(net, ARPHRD_ETHER, np->dev_mac);
net/core/page_pool_user.c
305
struct net *net;
net/core/page_pool_user.c
312
net = dev_net(pool->slow.netdev);
net/core/page_pool_user.c
314
if (!genl_has_listeners(&netdev_nl_family, net, NETDEV_NLGRP_PAGE_POOL))
net/core/page_pool_user.c
328
genlmsg_multicast_netns(&netdev_nl_family, net, ntf,
net/core/page_pool_user.c
86
struct net *net = sock_net(skb->sk);
net/core/page_pool_user.c
96
for_each_netdev_dump(net, netdev, state->ifindex) {
net/core/pktgen.c
2152
return dev_get_by_name(pn->net, b);
net/core/pktgen.c
2419
x = xfrm_state_lookup_byspi(pn->net, htonl(pkt_dev->spi), AF_INET);
net/core/pktgen.c
2422
x = xfrm_stateonly_find(pn->net, DUMMY_MARK, 0,
net/core/pktgen.c
2703
struct net *net = dev_net(pkt_dev->odev);
net/core/pktgen.c
2723
XFRM_INC_STATS(net, LINUX_MIB_XFRMOUTSTATEMODEERROR);
net/core/pktgen.c
2728
XFRM_INC_STATS(net, LINUX_MIB_XFRMOUTSTATEPROTOERROR);
net/core/pktgen.c
3484
remove_proc_entry(t->tsk->comm, t->net->proc_dir);
net/core/pktgen.c
3719
if (t->net->pktgen_exiting)
net/core/pktgen.c
3835
pkt_dev = __pktgen_NN_threads(t->net, ifname, FIND);
net/core/pktgen.c
3873
err = pktgen_setup_dev(t->net, pkt_dev, ifname);
net/core/pktgen.c
3879
pkt_dev->entry = proc_create_data(ifname, 0600, t->net->proc_dir,
net/core/pktgen.c
3957
t->net = pn;
net/core/pktgen.c
4019
static int __net_init pg_net_init(struct net *net)
net/core/pktgen.c
4021
struct pktgen_net *pn = net_generic(net, pg_net_id);
net/core/pktgen.c
4025
pn->net = net;
net/core/pktgen.c
4028
pn->proc_dir = proc_mkdir(PG_PROC_DIR, pn->net->proc_net);
net/core/pktgen.c
4062
remove_proc_entry(PG_PROC_DIR, pn->net->proc_net);
net/core/pktgen.c
4066
static void __net_exit pg_net_exit(struct net *net)
net/core/pktgen.c
4068
struct pktgen_net *pn = net_generic(net, pg_net_id);
net/core/pktgen.c
4088
remove_proc_entry(PG_PROC_DIR, pn->net->proc_net);
net/core/pktgen.c
452
struct net *net;
net/core/pktgen.c
474
struct pktgen_net *net;
net/core/rtnetlink.c
188
void __rtnl_net_lock(struct net *net)
net/core/rtnetlink.c
1880
struct net *src_net, gfp_t gfp)
net/core/rtnetlink.c
1885
struct net *link_net = dev->rtnl_link_ops->get_link_net(dev);
net/core/rtnetlink.c
192
mutex_lock(&net->rtnl_mutex);
net/core/rtnetlink.c
196
void __rtnl_net_unlock(struct net *net)
net/core/rtnetlink.c
200
mutex_unlock(&net->rtnl_mutex);
net/core/rtnetlink.c
204
void rtnl_net_lock(struct net *net)
net/core/rtnetlink.c
2060
struct net_device *dev, struct net *src_net,
net/core/rtnetlink.c
207
__rtnl_net_lock(net);
net/core/rtnetlink.c
211
void rtnl_net_unlock(struct net *net)
net/core/rtnetlink.c
213
__rtnl_net_unlock(net);
net/core/rtnetlink.c
218
int rtnl_net_trylock(struct net *net)
net/core/rtnetlink.c
223
__rtnl_net_lock(net);
net/core/rtnetlink.c
229
int rtnl_net_lock_killable(struct net *net)
net/core/rtnetlink.c
234
__rtnl_net_lock(net);
net/core/rtnetlink.c
239
static int rtnl_net_cmp_locks(const struct net *net_a, const struct net *net_b)
net/core/rtnetlink.c
2422
struct net *rtnl_get_net_ns_capable(struct sock *sk, int netnsid)
net/core/rtnetlink.c
2424
struct net *net;
net/core/rtnetlink.c
2426
net = get_net_ns_by_id(sock_net(sk), netnsid);
net/core/rtnetlink.c
2427
if (!net)
net/core/rtnetlink.c
2433
if (!sk_ns_capable(sk, net->user_ns, CAP_NET_ADMIN)) {
net/core/rtnetlink.c
2434
put_net(net);
net/core/rtnetlink.c
2437
return net;
net/core/rtnetlink.c
2442
const struct net *link_net)
net/core/rtnetlink.c
2498
struct net *net = sock_net(skb->sk);
net/core/rtnetlink.c
2504
struct net *tgt_net = net;
net/core/rtnetlink.c
2569
err = rtnl_fill_ifinfo(skb, dev, net, RTM_NEWLINK,
net/core/rtnetlink.c
257
const struct net *net_a, *net_b;
net/core/rtnetlink.c
259
net_a = container_of(a, struct net, rtnl_mutex.dep_map);
net/core/rtnetlink.c
260
net_b = container_of(b, struct net, rtnl_mutex.dep_map);
net/core/rtnetlink.c
2616
static struct net *rtnl_link_get_net_ifla(struct nlattr *tb[])
net/core/rtnetlink.c
2618
struct net *net = NULL;
net/core/rtnetlink.c
2624
net = get_net_ns_by_pid(nla_get_u32(tb[IFLA_NET_NS_PID]));
net/core/rtnetlink.c
2626
net = get_net_ns_by_fd(nla_get_u32(tb[IFLA_NET_NS_FD]));
net/core/rtnetlink.c
2628
return net;
net/core/rtnetlink.c
2631
struct net *rtnl_link_get_net(struct net *src_net, struct nlattr *tb[])
net/core/rtnetlink.c
2633
struct net *net = rtnl_link_get_net_ifla(tb);
net/core/rtnetlink.c
2635
if (!net)
net/core/rtnetlink.c
2636
net = get_net(src_net);
net/core/rtnetlink.c
2638
return net;
net/core/rtnetlink.c
2649
static struct net *rtnl_link_get_net_by_nlattr(struct net *src_net,
net/core/rtnetlink.c
265
bool rtnl_net_is_locked(struct net *net)
net/core/rtnetlink.c
2652
struct net *net;
net/core/rtnetlink.c
2660
net = get_net_ns_by_id(src_net, nla_get_u32(tb[IFLA_TARGET_NETNSID]));
net/core/rtnetlink.c
2661
if (!net)
net/core/rtnetlink.c
2664
return net;
net/core/rtnetlink.c
2667
static struct net *rtnl_link_get_net_capable(const struct sk_buff *skb,
net/core/rtnetlink.c
2668
struct net *src_net,
net/core/rtnetlink.c
267
return rtnl_is_locked() && mutex_is_locked(&net->rtnl_mutex);
net/core/rtnetlink.c
2671
struct net *net;
net/core/rtnetlink.c
2673
net = rtnl_link_get_net_by_nlattr(src_net, tb);
net/core/rtnetlink.c
2674
if (IS_ERR(net))
net/core/rtnetlink.c
2675
return net;
net/core/rtnetlink.c
2677
if (!netlink_ns_capable(skb, net->user_ns, cap)) {
net/core/rtnetlink.c
2678
put_net(net);
net/core/rtnetlink.c
2682
return net;
net/core/rtnetlink.c
271
bool lockdep_rtnl_net_is_held(struct net *net)
net/core/rtnetlink.c
273
return lockdep_rtnl_is_held() && lockdep_is_held(&net->rtnl_mutex);
net/core/rtnetlink.c
277
static int rtnl_net_cmp_locks(const struct net *net_a, const struct net *net_b)
net/core/rtnetlink.c
288
struct net *net[3];
net/core/rtnetlink.c
302
put_net(rtnl_nets->net[i]);
net/core/rtnetlink.c
303
rtnl_nets->net[i] = NULL;
net/core/rtnetlink.c
3094
struct net *tgt_net, struct ifinfomsg *ifm,
net/core/rtnetlink.c
317
static void rtnl_nets_add(struct rtnl_nets *rtnl_nets, struct net *net)
net/core/rtnetlink.c
321
DEBUG_NET_WARN_ON_ONCE(rtnl_nets->len == ARRAY_SIZE(rtnl_nets->net));
net/core/rtnetlink.c
324
switch (rtnl_net_cmp_locks(rtnl_nets->net[i], net)) {
net/core/rtnetlink.c
326
put_net(net);
net/core/rtnetlink.c
329
swap(rtnl_nets->net[i], net);
net/core/rtnetlink.c
333
rtnl_nets->net[i] = net;
net/core/rtnetlink.c
344
__rtnl_net_lock(rtnl_nets->net[i]);
net/core/rtnetlink.c
3475
static struct net_device *rtnl_dev_get(struct net *net,
net/core/rtnetlink.c
3487
return __dev_get_by_name(net, ifname);
net/core/rtnetlink.c
3490
static struct net_device *rtnl_dev_get_rcu(struct net *net,
net/core/rtnetlink.c
3502
return dev_get_by_name_rcu(net, ifname);
net/core/rtnetlink.c
3509
struct net *net = sock_net(skb->sk);
net/core/rtnetlink.c
3513
struct net *tgt_net;
net/core/rtnetlink.c
352
__rtnl_net_unlock(rtnl_nets->net[i]);
net/core/rtnetlink.c
3525
tgt_net = rtnl_link_get_net_capable(skb, net, tb, CAP_NET_ADMIN);
net/core/rtnetlink.c
3532
rtnl_nets_add(&rtnl_nets, get_net(net));
net/core/rtnetlink.c
3538
dev = __dev_get_by_index(net, ifm->ifi_index);
net/core/rtnetlink.c
3540
dev = rtnl_dev_get(net, tb);
net/core/rtnetlink.c
3555
static int rtnl_group_dellink(const struct net *net, int group)
net/core/rtnetlink.c
3564
for_each_netdev(net, dev) {
net/core/rtnetlink.c
3578
for_each_netdev_safe(net, dev, aux) {
net/core/rtnetlink.c
3611
struct net *net = sock_net(skb->sk);
net/core/rtnetlink.c
3615
struct net *tgt_net = net;
net/core/rtnetlink.c
3684
struct net_device *rtnl_create_link(struct net *net, const char *ifname,
net/core/rtnetlink.c
3735
dev_net_set(dev, net);
net/core/rtnetlink.c
3789
struct net_device *dev, struct net *tgt_net,
net/core/rtnetlink.c
3853
struct net *net, struct net *tgt_net,
net/core/rtnetlink.c
3861
for_each_netdev_safe(net, dev, aux) {
net/core/rtnetlink.c
3874
struct net *tgt_net, struct net *link_net,
net/core/rtnetlink.c
3875
struct net *peer_net,
net/core/rtnetlink.c
3948
static struct net *rtnl_get_peer_net(struct sk_buff *skb,
net/core/rtnetlink.c
3955
struct net *net;
net/core/rtnetlink.c
3974
net = rtnl_link_get_net_ifla(attrs);
net/core/rtnetlink.c
3975
if (IS_ERR_OR_NULL(net))
net/core/rtnetlink.c
3976
return net;
net/core/rtnetlink.c
3978
if (!netlink_ns_capable(skb, net->user_ns, CAP_NET_ADMIN)) {
net/core/rtnetlink.c
3979
put_net(net);
net/core/rtnetlink.c
3983
return net;
net/core/rtnetlink.c
3988
struct net *tgt_net, struct net *link_net,
net/core/rtnetlink.c
3989
struct net *peer_net,
net/core/rtnetlink.c
3995
struct net *net = sock_net(skb->sk);
net/core/rtnetlink.c
3996
struct net *device_net;
net/core/rtnetlink.c
4004
tgt_net : net;
net/core/rtnetlink.c
4031
return rtnl_group_changelink(skb, net, tgt_net,
net/core/rtnetlink.c
4051
struct net *tgt_net, *link_net = NULL, *peer_net = NULL;
net/core/rtnetlink.c
4223
struct net *net = sock_net(skb->sk);
net/core/rtnetlink.c
4227
struct net *tgt_net = net;
net/core/rtnetlink.c
4293
err = rtnl_fill_ifinfo(nskb, dev, net,
net/core/rtnetlink.c
4314
err = rtnl_unicast(nskb, net, NETLINK_CB(skb).portid);
net/core/rtnetlink.c
4369
struct net *net = sock_net(skb->sk);
net/core/rtnetlink.c
4387
dev = __dev_get_by_index(net, ifm->ifi_index);
net/core/rtnetlink.c
4389
dev = rtnl_dev_get(net, tb);
net/core/rtnetlink.c
4429
struct net *net = sock_net(skb->sk);
net/core/rtnetlink.c
4457
for_each_netdev_rcu(net, dev) {
net/core/rtnetlink.c
4519
struct net *net = dev_net(dev);
net/core/rtnetlink.c
4544
rtnl_set_sk_err(net, RTNLGRP_LINK, err);
net/core/rtnetlink.c
4551
struct net *net = dev_net(dev);
net/core/rtnetlink.c
4553
rtnl_notify(skb, net, portid, RTNLGRP_LINK, nlh, flags);
net/core/rtnetlink.c
4633
struct net *net = dev_net(dev);
net/core/rtnetlink.c
4648
rtnl_notify(skb, net, 0, RTNLGRP_NEIGH, NULL, GFP_ATOMIC);
net/core/rtnetlink.c
4651
rtnl_set_sk_err(net, RTNLGRP_NEIGH, err);
net/core/rtnetlink.c
4721
struct net *net = sock_net(skb->sk);
net/core/rtnetlink.c
4740
dev = __dev_get_by_index(net, ndm->ndm_ifindex);
net/core/rtnetlink.c
4833
struct net *net = sock_net(skb->sk);
net/core/rtnetlink.c
4860
dev = __dev_get_by_index(net, ndm->ndm_ifindex);
net/core/rtnetlink.c
5093
struct net *net = sock_net(skb->sk);
net/core/rtnetlink.c
5111
br_dev = __dev_get_by_index(net, br_idx);
net/core/rtnetlink.c
5118
for_each_netdev_dump(net, dev, ctx->ifindex) {
net/core/rtnetlink.c
5235
struct net *net = sock_net(in_skb->sk);
net/core/rtnetlink.c
5256
dev = __dev_get_by_index(net, brport_idx);
net/core/rtnetlink.c
5269
br_dev = __dev_get_by_index(net, br_idx);
net/core/rtnetlink.c
5320
return rtnl_unicast(skb, net, NETLINK_CB(in_skb).portid);
net/core/rtnetlink.c
5494
struct net *net = sock_net(skb->sk);
net/core/rtnetlink.c
5508
for_each_netdev_rcu(net, dev) {
net/core/rtnetlink.c
5568
struct net *net = dev_net(dev);
net/core/rtnetlink.c
5592
rtnl_notify(skb, net, 0, RTNLGRP_LINK, NULL, GFP_ATOMIC);
net/core/rtnetlink.c
5598
rtnl_set_sk_err(net, RTNLGRP_LINK, err);
net/core/rtnetlink.c
5605
struct net *net = sock_net(skb->sk);
net/core/rtnetlink.c
5619
dev = __dev_get_by_index(net, ifm->ifi_index);
net/core/rtnetlink.c
5685
struct net *net = sock_net(skb->sk);
net/core/rtnetlink.c
5700
dev = __dev_get_by_index(net, ifm->ifi_index);
net/core/rtnetlink.c
6372
struct net *net = sock_net(skb->sk);
net/core/rtnetlink.c
6386
dev = __dev_get_by_index(net, ifsm->ifindex);
net/core/rtnetlink.c
639
static void __rtnl_kill_links(struct net *net, struct rtnl_link_ops *ops)
net/core/rtnetlink.c
6415
err = rtnl_unicast(nskb, net, NETLINK_CB(skb).portid);
net/core/rtnetlink.c
6425
struct net *net = sock_net(skb->sk);
net/core/rtnetlink.c
6436
cb->seq = net->dev_base_seq;
net/core/rtnetlink.c
644
for_each_netdev(net, dev) {
net/core/rtnetlink.c
6453
for_each_netdev_dump(net, dev, ctx->ifindex) {
net/core/rtnetlink.c
6478
struct net *net = dev_net(dev);
net/core/rtnetlink.c
6502
rtnl_notify(skb, net, 0, RTNLGRP_STATS, NULL, GFP_KERNEL);
net/core/rtnetlink.c
6506
rtnl_set_sk_err(net, RTNLGRP_STATS, err);
net/core/rtnetlink.c
6516
struct net *net = sock_net(skb->sk);
net/core/rtnetlink.c
6534
dev = __dev_get_by_index(net, ifsm->ifindex);
net/core/rtnetlink.c
6606
struct net *net = sock_net(skb->sk);
net/core/rtnetlink.c
6622
for_each_netdev(net, dev) {
net/core/rtnetlink.c
6697
struct net *net = sock_net(in_skb->sk);
net/core/rtnetlink.c
6713
dev = __dev_get_by_index(net, bpm->ifindex);
net/core/rtnetlink.c
679
struct net *net;
net/core/rtnetlink.c
6800
struct net *net = sock_net(skb->sk);
net/core/rtnetlink.c
6816
dev = __dev_get_by_index(net, bpm->ifindex);
net/core/rtnetlink.c
6881
struct net *net = sock_net(skb->sk);
net/core/rtnetlink.c
6902
dev = __dev_get_by_index(net, bpm->ifindex);
net/core/rtnetlink.c
692
for_each_net(net)
net/core/rtnetlink.c
693
__rtnl_kill_links(net, ops);
net/core/rtnetlink.c
6980
struct net *net = sock_net(skb->sk);
net/core/rtnetlink.c
7033
rtnl = net->rtnl;
net/core/rtnetlink.c
7106
static int rtnetlink_bind(struct net *net, int group)
net/core/rtnetlink.c
7111
if (!ns_capable(net->user_ns, CAP_NET_ADMIN))
net/core/rtnetlink.c
7150
static int __net_init rtnetlink_net_init(struct net *net)
net/core/rtnetlink.c
7160
sk = netlink_kernel_create(net, NETLINK_ROUTE, &cfg);
net/core/rtnetlink.c
7163
net->rtnl = sk;
net/core/rtnetlink.c
7167
static void __net_exit rtnetlink_net_exit(struct net *net)
net/core/rtnetlink.c
7169
netlink_kernel_release(net->rtnl);
net/core/rtnetlink.c
7170
net->rtnl = NULL;
net/core/rtnetlink.c
943
int rtnetlink_send(struct sk_buff *skb, struct net *net, u32 pid, unsigned int group, int echo)
net/core/rtnetlink.c
945
struct sock *rtnl = net->rtnl;
net/core/rtnetlink.c
950
int rtnl_unicast(struct sk_buff *skb, struct net *net, u32 pid)
net/core/rtnetlink.c
952
struct sock *rtnl = net->rtnl;
net/core/rtnetlink.c
958
void rtnl_notify(struct sk_buff *skb, struct net *net, u32 pid, u32 group,
net/core/rtnetlink.c
961
struct sock *rtnl = net->rtnl;
net/core/rtnetlink.c
967
void rtnl_set_sk_err(struct net *net, u32 group, int error)
net/core/rtnetlink.c
969
struct sock *rtnl = net->rtnl;
net/core/secure_seq.c
108
secure_tcp_seq_and_ts_off(const struct net *net, __be32 saddr, __be32 daddr,
net/core/secure_seq.c
119
if (READ_ONCE(net->ipv4.sysctl_tcp_timestamps) != 1)
net/core/secure_seq.c
51
secure_tcpv6_seq_and_ts_off(const struct net *net, const __be32 *saddr,
net/core/secure_seq.c
72
if (READ_ONCE(net->ipv4.sysctl_tcp_timestamps) != 1)
net/core/skb_fault_injection.c
19
struct net_device *net = skb->dev;
net/core/skb_fault_injection.c
22
strncmp(net->name, skb_realloc.devname, IFNAMSIZ))
net/core/sock.c
2303
struct sock *sk_alloc(struct net *net, int family, gfp_t priority,
net/core/sock.c
2317
if (READ_ONCE(net->core.sysctl_bypass_prot_mem))
net/core/sock.c
2325
get_net_track(net, &sk->ns_tracker, priority);
net/core/sock.c
2326
sock_inuse_add(net, 1);
net/core/sock.c
2328
net_passive_inc(net);
net/core/sock.c
2329
__netns_tracker_alloc(net, &sk->ns_tracker,
net/core/sock.c
2333
sock_net_set(sk, net);
net/core/sock.c
2353
struct net *net = sock_net(sk);
net/core/sock.c
2386
put_net_track(net, &sk->ns_tracker);
net/core/sock.c
2388
__netns_tracker_free(net, &sk->ns_tracker, false);
net/core/sock.c
2389
net_passive_dec(net);
net/core/sock.c
2396
struct net *net = sock_net(sk);
net/core/sock.c
2399
__netns_tracker_free(net, &sk->ns_tracker, false);
net/core/sock.c
2400
net_passive_dec(net);
net/core/sock.c
2402
get_net_track(net, &sk->ns_tracker, GFP_KERNEL);
net/core/sock.c
2403
sock_inuse_add(net, 1);
net/core/sock.c
4091
int sock_prot_inuse_get(struct net *net, struct proto *prot)
net/core/sock.c
4097
res += per_cpu_ptr(net->core.prot_inuse, cpu)->val[idx];
net/core/sock.c
4103
int sock_inuse_get(struct net *net)
net/core/sock.c
4108
res += per_cpu_ptr(net->core.prot_inuse, cpu)->all;
net/core/sock.c
4115
static int __net_init sock_inuse_init_net(struct net *net)
net/core/sock.c
4117
net->core.prot_inuse = alloc_percpu(struct prot_inuse);
net/core/sock.c
4118
if (net->core.prot_inuse == NULL)
net/core/sock.c
4123
static void __net_exit sock_inuse_exit_net(struct net *net)
net/core/sock.c
4125
free_percpu(net->core.prot_inuse);
net/core/sock.c
4436
static __net_init int proto_init_net(struct net *net)
net/core/sock.c
4438
if (!proc_create_net("protocols", 0444, net->proc_net, &proto_seq_ops,
net/core/sock.c
4445
static __net_exit void proto_exit_net(struct net *net)
net/core/sock.c
4447
remove_proc_entry("protocols", net->proc_net);
net/core/sock.c
638
struct net *net = sock_net(sk);
net/core/sock.c
642
if (sk->sk_bound_dev_if && !ns_capable(net->user_ns, CAP_NET_RAW))
net/core/sock.c
682
struct net *net = sock_net(sk);
net/core/sock.c
708
dev = dev_get_by_name_rcu(net, devname);
net/core/sock.c
732
struct net *net = sock_net(sk);
net/core/sock.c
744
ret = netdev_get_name(net, devname, bound_dev_if);
net/core/sock.c
857
struct net *net = sock_net(sk);
net/core/sock.c
864
dev = dev_get_by_index(net, sk->sk_bound_dev_if);
net/core/sock_diag.c
295
static int sock_diag_bind(struct net *net, int group)
net/core/sock_diag.c
324
static int __net_init diag_net_init(struct net *net)
net/core/sock_diag.c
333
net->diag_nlsk = netlink_kernel_create(net, NETLINK_SOCK_DIAG, &cfg);
net/core/sock_diag.c
334
return net->diag_nlsk == NULL ? -ENOMEM : 0;
net/core/sock_diag.c
337
static void __net_exit diag_net_exit(struct net *net)
net/core/sock_diag.c
339
netlink_kernel_release(net->diag_nlsk);
net/core/sock_diag.c
340
net->diag_nlsk = NULL;
net/core/sysctl_net_core.c
106
struct net *net = (struct net *)table->data;
net/core/sysctl_net_core.c
111
mask = net->core.rps_default_mask;
net/core/sysctl_net_core.c
115
net->core.rps_default_mask = mask;
net/core/sysctl_net_core.c
790
static __net_init int sysctl_core_net_init(struct net *net)
net/core/sysctl_net_core.c
796
if (!net_eq(net, &init_net)) {
net/core/sysctl_net_core.c
806
tbl[i].data += (char *)net - (char *)&init_net;
net/core/sysctl_net_core.c
812
net->core.sysctl_hdr = register_net_sysctl_sz(net, "net/core", tbl, table_size);
net/core/sysctl_net_core.c
813
if (net->core.sysctl_hdr == NULL)
net/core/sysctl_net_core.c
825
static __net_exit void sysctl_core_net_exit(struct net *net)
net/core/sysctl_net_core.c
829
tbl = net->core.sysctl_hdr->ctl_table_arg;
net/core/sysctl_net_core.c
830
unregister_net_sysctl_table(net->core.sysctl_hdr);
net/core/sysctl_net_core.c
833
kfree(net->core.rps_default_mask);
net/core/utils.c
321
static int inet6_pton(struct net *net, const char *src, u16 port_num,
net/core/utils.c
345
dev = dev_get_by_name(net, scope_id);
net/core/utils.c
370
int inet_pton_with_scope(struct net *net, __kernel_sa_family_t af,
net/core/utils.c
388
ret = inet6_pton(net, src, port_num, addr);
net/core/utils.c
393
ret = inet6_pton(net, src, port_num, addr);
net/dcb/dcbnl.c
1508
struct net *net = dev_net(dev);
net/dcb/dcbnl.c
1529
rtnl_set_sk_err(net, RTNLGRP_DCB, err);
net/dcb/dcbnl.c
1533
rtnl_notify(skb, net, 0, RTNLGRP_DCB, NULL, GFP_KERNEL);
net/dcb/dcbnl.c
1913
struct net *net = sock_net(skb->sk);
net/dcb/dcbnl.c
1944
netdev = __dev_get_by_name(net, nla_data(tb[DCB_ATTR_IFNAME]));
net/dcb/dcbnl.c
1964
ret = rtnl_unicast(reply_skb, net, portid);
net/devlink/core.c
219
struct net *net = devlink_net(devlink);
net/devlink/core.c
226
err = devlink_nl_put_nested_handle(msg, net, rel_devlink, attrtype);
net/devlink/core.c
269
struct net *devlink_net(const struct devlink *devlink)
net/devlink/core.c
345
static struct devlink *__devlinks_xa_find_get(struct net *net,
net/devlink/core.c
359
if (!net_eq(devlink_net(devlink), net)) {
net/devlink/core.c
372
struct devlink *devlinks_xa_find_get(struct net *net, unsigned long *indexp)
net/devlink/core.c
374
return __devlinks_xa_find_get(net, indexp, ULONG_MAX);
net/devlink/core.c
377
struct devlink *devlinks_xa_lookup_get(struct net *net, unsigned long index)
net/devlink/core.c
379
return __devlinks_xa_find_get(net, &index, index);
net/devlink/core.c
431
struct net *net, struct device *dev,
net/devlink/core.c
465
write_pnet(&devlink->_net, net);
net/devlink/core.c
504
size_t priv_size, struct net *net,
net/devlink/core.c
508
return __devlink_alloc(ops, priv_size, net, dev, dev->driver);
net/devlink/core.c
546
static void __net_exit devlink_pernet_pre_exit(struct net *net)
net/devlink/core.c
556
devlinks_xa_for_each_registered_get(net, index, devlink) {
net/devlink/dev.c
378
static struct net *devlink_netns_get(struct sk_buff *skb,
net/devlink/dev.c
384
struct net *net;
net/devlink/dev.c
392
net = get_net_ns_by_pid(nla_get_u32(netns_pid_attr));
net/devlink/dev.c
394
net = get_net_ns_by_fd(nla_get_u32(netns_fd_attr));
net/devlink/dev.c
396
net = get_net_ns_by_id(sock_net(skb->sk),
net/devlink/dev.c
398
if (!net)
net/devlink/dev.c
399
net = ERR_PTR(-EINVAL);
net/devlink/dev.c
402
net = ERR_PTR(-EINVAL);
net/devlink/dev.c
404
if (IS_ERR(net)) {
net/devlink/dev.c
408
if (!netlink_ns_capable(skb, net->user_ns, CAP_NET_ADMIN)) {
net/devlink/dev.c
409
put_net(net);
net/devlink/dev.c
412
return net;
net/devlink/dev.c
416
struct net *curr_net,
net/devlink/dev.c
417
struct net *dest_net)
net/devlink/dev.c
442
int devlink_reload(struct devlink *devlink, struct net *dest_net,
net/devlink/dev.c
448
struct net *curr_net;
net/devlink/dev.c
525
struct net *dest_net = NULL;
net/devlink/devl_internal.h
104
#define devlinks_xa_for_each_registered_get(net, index, devlink) \
net/devlink/devl_internal.h
105
for (index = 0; (devlink = devlinks_xa_find_get(net, &index)); index++)
net/devlink/devl_internal.h
107
struct devlink *devlinks_xa_find_get(struct net *net, unsigned long *indexp);
net/devlink/devl_internal.h
108
struct devlink *devlinks_xa_lookup_get(struct net *net, unsigned long index);
net/devlink/devl_internal.h
181
devlink_get_from_attrs_lock(struct net *net, struct nlattr **attrs,
net/devlink/devl_internal.h
212
int devlink_nl_put_nested_handle(struct sk_buff *msg, struct net *net,
net/devlink/devl_internal.h
307
int devlink_reload(struct devlink *devlink, struct net *dest_net,
net/devlink/devl_internal.h
72
struct net *net, struct device *dev,
net/devlink/netlink.c
142
int devlink_nl_put_nested_handle(struct sk_buff *msg, struct net *net,
net/devlink/netlink.c
146
struct net *devl_net;
net/devlink/netlink.c
156
if (!net_eq(net, devl_net)) {
net/devlink/netlink.c
157
int id = peernet2id_alloc(net, devl_net, GFP_ATOMIC);
net/devlink/netlink.c
190
devlink_get_from_attrs_lock(struct net *net, struct nlattr **attrs,
net/devlink/netlink.c
203
devlink = devlinks_xa_lookup_get(net, index);
net/devlink/netlink.c
218
devlink = devlinks_xa_lookup_get(net, index);
net/devlink/netlink.c
224
devlinks_xa_for_each_registered_get(net, index, devlink) {
net/dns_resolver/dns_query.c
62
int dns_query(struct net *net,
net/dns_resolver/dns_query.c
96
rkey = request_key_net(&key_type_dns_resolver, desc, net, options);
net/ethtool/ioctl.c
3272
dev_ethtool_locked(struct net *net, struct net_device *dev,
net/ethtool/ioctl.c
3327
if (!ns_capable(net->user_ns, CAP_NET_ADMIN))
net/ethtool/ioctl.c
3610
__dev_ethtool(struct net *net, struct ifreq *ifr, void __user *useraddr,
net/ethtool/ioctl.c
3618
dev = netdev_get_by_name(net, ifr->ifr_name, &dev_tracker, GFP_KERNEL);
net/ethtool/ioctl.c
3629
dev->moving_ns || !net_eq(dev_net(dev), net)) {
net/ethtool/ioctl.c
3634
rc = dev_ethtool_locked(net, dev, useraddr, ethcmd, devlink_state,
net/ethtool/ioctl.c
3646
int dev_ethtool(struct net *net, struct ifreq *ifr, void __user *useraddr)
net/ethtool/ioctl.c
3669
rc = __dev_ethtool(net, ifr, useraddr, ethcmd, state);
net/ethtool/module.c
297
dev_net(work->fw_update.dev) == sk_priv->net)
net/ethtool/netlink.c
150
const struct nlattr *header, struct net *net,
net/ethtool/netlink.c
179
dev = netdev_get_by_index(net, ifindex, &req_info->dev_tracker,
net/ethtool/netlink.c
196
dev = netdev_get_by_name(net, nla_data(devname_attr),
net/ethtool/netlink.c
63
int ethnl_sock_priv_set(struct sk_buff *skb, struct net *net, u32 portid,
net/ethtool/netlink.c
642
struct net *net = sock_net(skb->sk);
net/ethtool/netlink.c
648
for_each_netdev_dump(net, dev, ctx->pos_ifindex) {
net/ethtool/netlink.c
72
sk_priv->net = net;
net/ethtool/netlink.c
812
struct net *net = sock_net(skb->sk);
net/ethtool/netlink.c
818
for_each_netdev_dump(net, dev, ethnl_ctx->pos_ifindex) {
net/ethtool/netlink.h
14
const struct nlattr *nest, struct net *net,
net/ethtool/netlink.h
349
struct net *net;
net/ethtool/netlink.h
354
int ethnl_sock_priv_set(struct sk_buff *skb, struct net *net, u32 portid,
net/ethtool/rss.c
471
struct net *net = sock_net(skb->sk);
net/ethtool/rss.c
474
for_each_netdev_lock_ops_compat_scoped(net, dev, ctx->ifindex) {
net/ethtool/tsinfo.c
476
struct net *net = sock_net(skb->sk);
net/ethtool/tsinfo.c
488
for_each_netdev_lock_ops_compat_scoped(net, dev, ctx->pos_ifindex) {
net/ethtool/tunnels.c
244
struct net *net = sock_net(skb->sk);
net/ethtool/tunnels.c
250
for_each_netdev_dump(net, dev, ctx->ifindex) {
net/handshake/handshake-test.c
252
struct net *net;
net/handshake/handshake-test.c
267
net = sock_net(sock->sk);
net/handshake/handshake-test.c
268
hn = handshake_pernet(net);
net/handshake/handshake-test.c
369
struct net *net;
net/handshake/handshake-test.c
390
net = sock_net(sock->sk);
net/handshake/handshake-test.c
391
hn = handshake_pernet(net);
net/handshake/handshake-test.c
419
struct net *net;
net/handshake/handshake-test.c
440
net = sock_net(sock->sk);
net/handshake/handshake-test.c
441
hn = handshake_pernet(net);
net/handshake/handshake.h
75
int handshake_genl_notify(struct net *net, const struct handshake_proto *proto,
net/handshake/handshake.h
79
struct handshake_net *handshake_pernet(struct net *net);
net/handshake/netlink.c
120
trace_handshake_cmd_accept(net, req, req->hr_sk, fd_prepare_fd(fdf));
net/handshake/netlink.c
129
trace_handshake_cmd_accept_err(net, req, NULL, err);
net/handshake/netlink.c
135
struct net *net = sock_net(skb->sk);
net/handshake/netlink.c
151
trace_handshake_cmd_done_err(net, req, sock->sk, err);
net/handshake/netlink.c
156
trace_handshake_cmd_done(net, req, sock->sk, fd);
net/handshake/netlink.c
169
static int __net_init handshake_net_init(struct net *net)
net/handshake/netlink.c
171
struct handshake_net *hn = net_generic(net, handshake_net_id);
net/handshake/netlink.c
191
static void __net_exit handshake_net_exit(struct net *net)
net/handshake/netlink.c
193
struct handshake_net *hn = net_generic(net, handshake_net_id);
net/handshake/netlink.c
234
struct handshake_net *handshake_pernet(struct net *net)
net/handshake/netlink.c
237
net_generic(net, handshake_net_id) : NULL;
net/handshake/netlink.c
37
int handshake_genl_notify(struct net *net, const struct handshake_proto *proto,
net/handshake/netlink.c
47
if (!genl_has_listeners(&handshake_nl_family, net,
net/handshake/netlink.c
67
return genlmsg_multicast_netns(&handshake_nl_family, net, msg,
net/handshake/netlink.c
92
struct net *net = sock_net(skb->sk);
net/handshake/netlink.c
93
struct handshake_net *hn = handshake_pernet(net);
net/handshake/request.c
255
struct net *net;
net/handshake/request.c
280
net = sock_net(req->hr_sk);
net/handshake/request.c
281
hn = handshake_pernet(net);
net/handshake/request.c
300
ret = handshake_genl_notify(net, req->hr_proto, flags);
net/handshake/request.c
302
trace_handshake_notify_err(net, req, req->hr_sk, ret);
net/handshake/request.c
307
trace_handshake_submit(net, req, req->hr_sk);
net/handshake/request.c
313
trace_handshake_submit_err(net, req, req->hr_sk, ret);
net/handshake/request.c
328
struct net *net = sock_net(sk);
net/handshake/request.c
333
trace_handshake_complete(net, req, sk, status);
net/handshake/request.c
356
struct net *net;
net/handshake/request.c
358
net = sock_net(sk);
net/handshake/request.c
361
trace_handshake_cancel_none(net, req, sk);
net/handshake/request.c
365
hn = handshake_pernet(net);
net/handshake/request.c
369
trace_handshake_cancel_busy(net, req, sk);
net/handshake/request.c
376
trace_handshake_cancel_busy(net, req, sk);
net/handshake/request.c
381
trace_handshake_cancel(net, req, sk);
net/hsr/hsr_netlink.c
36
struct net *link_net = rtnl_newlink_link_net(params);
net/ieee802154/6lowpan/reassembly.c
284
struct net *net = dev_net(skb->dev);
net/ieee802154/6lowpan/reassembly.c
308
fq = fq_find(net, cb, &hdr.source, &hdr.dest);
net/ieee802154/6lowpan/reassembly.c
362
static int __net_init lowpan_frags_ns_sysctl_register(struct net *net)
net/ieee802154/6lowpan/reassembly.c
367
net_ieee802154_lowpan(net);
net/ieee802154/6lowpan/reassembly.c
371
if (!net_eq(net, &init_net)) {
net/ieee802154/6lowpan/reassembly.c
378
if (net->user_ns != &init_user_ns)
net/ieee802154/6lowpan/reassembly.c
388
hdr = register_net_sysctl_sz(net, "net/ieee802154/6lowpan", table,
net/ieee802154/6lowpan/reassembly.c
397
if (!net_eq(net, &init_net))
net/ieee802154/6lowpan/reassembly.c
403
static void __net_exit lowpan_frags_ns_sysctl_unregister(struct net *net)
net/ieee802154/6lowpan/reassembly.c
407
net_ieee802154_lowpan(net);
net/ieee802154/6lowpan/reassembly.c
411
if (!net_eq(net, &init_net))
net/ieee802154/6lowpan/reassembly.c
430
static inline int lowpan_frags_ns_sysctl_register(struct net *net)
net/ieee802154/6lowpan/reassembly.c
435
static inline void lowpan_frags_ns_sysctl_unregister(struct net *net)
net/ieee802154/6lowpan/reassembly.c
449
static int __net_init lowpan_frags_init_net(struct net *net)
net/ieee802154/6lowpan/reassembly.c
452
net_ieee802154_lowpan(net);
net/ieee802154/6lowpan/reassembly.c
456
res = fqdir_init(&ieee802154_lowpan->fqdir, &lowpan_frags, net);
net/ieee802154/6lowpan/reassembly.c
464
res = lowpan_frags_ns_sysctl_register(net);
net/ieee802154/6lowpan/reassembly.c
470
static void __net_exit lowpan_frags_pre_exit_net(struct net *net)
net/ieee802154/6lowpan/reassembly.c
473
net_ieee802154_lowpan(net);
net/ieee802154/6lowpan/reassembly.c
478
static void __net_exit lowpan_frags_exit_net(struct net *net)
net/ieee802154/6lowpan/reassembly.c
481
net_ieee802154_lowpan(net);
net/ieee802154/6lowpan/reassembly.c
483
lowpan_frags_ns_sysctl_unregister(net);
net/ieee802154/6lowpan/reassembly.c
65
fq_find(struct net *net, const struct lowpan_802154_cb *cb,
net/ieee802154/6lowpan/reassembly.c
70
net_ieee802154_lowpan(net);
net/ieee802154/core.c
221
struct net *net)
net/ieee802154/core.c
230
err = dev_change_net_namespace(wpan_dev->netdev, net, "wpan%d");
net/ieee802154/core.c
247
wpan_phy_net_set(&rdev->wpan_phy, net);
net/ieee802154/core.c
253
net = wpan_phy_net(&rdev->wpan_phy);
net/ieee802154/core.c
261
err = dev_change_net_namespace(wpan_dev->netdev, net,
net/ieee802154/core.c
354
static void __net_exit cfg802154_pernet_exit(struct net *net)
net/ieee802154/core.c
360
if (net_eq(wpan_phy_net(&rdev->wpan_phy), net))
net/ieee802154/core.h
43
struct net *net);
net/ieee802154/nl-mac.c
431
struct net *net = sock_net(skb->sk);
net/ieee802154/nl-mac.c
439
for_each_netdev(net, dev) {
net/ieee802154/nl-mac.c
766
struct net *net = sock_net(skb->sk);
net/ieee802154/nl-mac.c
773
for_each_netdev(net, dev) {
net/ieee802154/nl802154.c
1270
struct net *net;
net/ieee802154/nl802154.c
1276
net = get_net_ns_by_pid(pid);
net/ieee802154/nl802154.c
1280
net = get_net_ns_by_fd(fd);
net/ieee802154/nl802154.c
1285
if (IS_ERR(net))
net/ieee802154/nl802154.c
1286
return PTR_ERR(net);
net/ieee802154/nl802154.c
1291
if (!net_eq(wpan_phy_net(&rdev->wpan_phy), net))
net/ieee802154/nl802154.c
1292
err = cfg802154_switch_netns(rdev, net);
net/ieee802154/nl802154.c
1294
put_net(net);
net/ieee802154/nl802154.c
173
cfg802154_get_dev_from_info(struct net *netns, struct genl_info *info)
net/ieee802154/nl802154.c
39
__cfg802154_wpan_dev_from_attrs(struct net *netns, struct nlattr **attrs)
net/ieee802154/nl802154.c
94
__cfg802154_rdev_from_attrs(struct net *netns, struct nlattr **attrs)
net/ieee802154/socket.c
1001
static int ieee802154_create(struct net *net, struct socket *sock,
net/ieee802154/socket.c
1009
if (!net_eq(net, &init_net))
net/ieee802154/socket.c
1030
sk = sk_alloc(net, PF_IEEE802154, GFP_KERNEL, proto, kern);
net/ieee802154/socket.c
32
ieee802154_get_dev(struct net *net, const struct ieee802154_addr *addr)
net/ieee802154/socket.c
43
dev = dev_getbyhwaddr_rcu(net, ARPHRD_IEEE802154, hwaddr);
net/ieee802154/socket.c
55
for_each_netdev(net, tmp) {
net/ieee802154/socket.c
885
struct net *net = sock_net(sk);
net/ieee802154/socket.c
905
if (!ns_capable(net->user_ns, CAP_NET_ADMIN) &&
net/ieee802154/socket.c
906
!ns_capable(net->user_ns, CAP_NET_RAW)) {
net/ieee802154/socket.c
929
if (!ns_capable(net->user_ns, CAP_NET_ADMIN) &&
net/ieee802154/socket.c
930
!ns_capable(net->user_ns, CAP_NET_RAW)) {
net/ipv4/af_inet.c
1009
err = devinet_ioctl(net, cmd, &ifr);
net/ipv4/af_inet.c
1636
struct net *net)
net/ipv4/af_inet.c
1639
int rc = sock_create_kern(net, family, type, protocol, &sock);
net/ipv4/af_inet.c
1709
static __net_init int ipv4_mib_init_net(struct net *net)
net/ipv4/af_inet.c
1713
net->mib.tcp_statistics = alloc_percpu(struct tcp_mib);
net/ipv4/af_inet.c
1714
if (!net->mib.tcp_statistics)
net/ipv4/af_inet.c
1716
net->mib.ip_statistics = alloc_percpu(struct ipstats_mib);
net/ipv4/af_inet.c
1717
if (!net->mib.ip_statistics)
net/ipv4/af_inet.c
1722
af_inet_stats = per_cpu_ptr(net->mib.ip_statistics, i);
net/ipv4/af_inet.c
1726
net->mib.net_statistics = alloc_percpu(struct linux_mib);
net/ipv4/af_inet.c
1727
if (!net->mib.net_statistics)
net/ipv4/af_inet.c
1729
net->mib.udp_statistics = alloc_percpu(struct udp_mib);
net/ipv4/af_inet.c
1730
if (!net->mib.udp_statistics)
net/ipv4/af_inet.c
1732
net->mib.icmp_statistics = alloc_percpu(struct icmp_mib);
net/ipv4/af_inet.c
1733
if (!net->mib.icmp_statistics)
net/ipv4/af_inet.c
1735
net->mib.icmpmsg_statistics = kzalloc_obj(struct icmpmsg_mib);
net/ipv4/af_inet.c
1736
if (!net->mib.icmpmsg_statistics)
net/ipv4/af_inet.c
1739
tcp_mib_init(net);
net/ipv4/af_inet.c
1743
free_percpu(net->mib.icmp_statistics);
net/ipv4/af_inet.c
1745
free_percpu(net->mib.udp_statistics);
net/ipv4/af_inet.c
1747
free_percpu(net->mib.net_statistics);
net/ipv4/af_inet.c
1749
free_percpu(net->mib.ip_statistics);
net/ipv4/af_inet.c
1751
free_percpu(net->mib.tcp_statistics);
net/ipv4/af_inet.c
1756
static __net_exit void ipv4_mib_exit_net(struct net *net)
net/ipv4/af_inet.c
1758
kfree(net->mib.icmpmsg_statistics);
net/ipv4/af_inet.c
1759
free_percpu(net->mib.icmp_statistics);
net/ipv4/af_inet.c
1760
free_percpu(net->mib.udp_statistics);
net/ipv4/af_inet.c
1761
free_percpu(net->mib.net_statistics);
net/ipv4/af_inet.c
1762
free_percpu(net->mib.ip_statistics);
net/ipv4/af_inet.c
1763
free_percpu(net->mib.tcp_statistics);
net/ipv4/af_inet.c
1766
free_percpu(net->mib.mptcp_statistics);
net/ipv4/af_inet.c
1780
static __net_init int inet_init_net(struct net *net)
net/ipv4/af_inet.c
1785
net->ipv4.ip_local_ports.range = 60999u << 16 | 32768u;
net/ipv4/af_inet.c
1787
seqlock_init(&net->ipv4.ping_group_range.lock);
net/ipv4/af_inet.c
1792
net->ipv4.ping_group_range.range[0] = make_kgid(&init_user_ns, 1);
net/ipv4/af_inet.c
1793
net->ipv4.ping_group_range.range[1] = make_kgid(&init_user_ns, 0);
net/ipv4/af_inet.c
1798
net->ipv4.sysctl_ip_default_ttl = IPDEFTTL;
net/ipv4/af_inet.c
1799
net->ipv4.sysctl_ip_fwd_update_priority = 1;
net/ipv4/af_inet.c
1800
net->ipv4.sysctl_ip_dynaddr = 0;
net/ipv4/af_inet.c
1801
net->ipv4.sysctl_ip_early_demux = 1;
net/ipv4/af_inet.c
1802
net->ipv4.sysctl_udp_early_demux = 1;
net/ipv4/af_inet.c
1803
net->ipv4.sysctl_tcp_early_demux = 1;
net/ipv4/af_inet.c
1804
net->ipv4.sysctl_nexthop_compat_mode = 1;
net/ipv4/af_inet.c
1806
net->ipv4.sysctl_ip_prot_sock = PROT_SOCK;
net/ipv4/af_inet.c
1810
net->ipv4.sysctl_igmp_max_memberships = 20;
net/ipv4/af_inet.c
1811
net->ipv4.sysctl_igmp_max_msf = 10;
net/ipv4/af_inet.c
1813
net->ipv4.sysctl_igmp_llm_reports = 1;
net/ipv4/af_inet.c
1814
net->ipv4.sysctl_igmp_qrv = 2;
net/ipv4/af_inet.c
1816
net->ipv4.sysctl_fib_notify_on_flag_change = 0;
net/ipv4/af_inet.c
259
static int inet_create(struct net *net, struct socket *sock, int protocol,
net/ipv4/af_inet.c
322
!ns_capable(net->user_ns, CAP_NET_RAW))
net/ipv4/af_inet.c
333
sk = sk_alloc(net, PF_INET, GFP_KERNEL, answer_prot, kern);
net/ipv4/af_inet.c
355
if (READ_ONCE(net->ipv4.sysctl_ip_no_pmtu_disc))
net/ipv4/af_inet.c
367
sk->sk_txrehash = READ_ONCE(net->core.sysctl_txrehash);
net/ipv4/af_inet.c
483
struct net *net = sock_net(sk);
net/ipv4/af_inet.c
499
tb_id = l3mdev_fib_table_by_index(net, sk->sk_bound_dev_if) ? : tb_id;
net/ipv4/af_inet.c
500
chk_addr_ret = inet_addr_type_table(net, addr->sin_addr.s_addr, tb_id);
net/ipv4/af_inet.c
510
if (!inet_addr_valid_or_nonlocal(net, inet, addr->sin_addr.s_addr,
net/ipv4/af_inet.c
517
snum && inet_port_requires_bind_service(net, snum) &&
net/ipv4/af_inet.c
518
!ns_capable(net->user_ns, CAP_NET_BIND_SERVICE))
net/ipv4/af_inet.c
969
struct net *net = sock_net(sk);
net/ipv4/af_inet.c
979
err = ip_rt_ioctl(net, cmd, &rt);
net/ipv4/af_inet.c
987
err = arp_ioctl(net, cmd, (void __user *)arg);
net/ipv4/af_inet.c
996
err = devinet_ioctl(net, cmd, &ifr);
net/ipv4/ah4.c
451
struct net *net = dev_net(skb->dev);
net/ipv4/ah4.c
467
x = xfrm_state_lookup(net, skb->mark, (const xfrm_address_t *)&iph->daddr,
net/ipv4/ah4.c
473
ipv4_update_pmtu(skb, net, info, 0, IPPROTO_AH);
net/ipv4/ah4.c
475
ipv4_redirect(skb, net, 0, IPPROTO_AH);
net/ipv4/arp.c
1013
static struct net_device *arp_req_dev_by_name(struct net *net, struct arpreq *r,
net/ipv4/arp.c
1019
dev = dev_get_by_name_rcu(net, r->arp_dev);
net/ipv4/arp.c
1021
dev = __dev_get_by_name(net, r->arp_dev);
net/ipv4/arp.c
1035
static struct net_device *arp_req_dev(struct net *net, struct arpreq *r)
net/ipv4/arp.c
1042
return arp_req_dev_by_name(net, r, false);
net/ipv4/arp.c
1049
rt = ip_route_output(net, ip, 0, 0, 0, RT_SCOPE_LINK);
net/ipv4/arp.c
1066
static int arp_req_set_proxy(struct net *net, struct net_device *dev, int on)
net/ipv4/arp.c
1069
IPV4_DEVCONF_ALL(net, PROXY_ARP) = on;
net/ipv4/arp.c
1079
static int arp_req_set_public(struct net *net, struct arpreq *r,
net/ipv4/arp.c
1085
dev = dev_getbyhwaddr(net, r->arp_ha.sa_family,
net/ipv4/arp.c
1093
return pneigh_create(&arp_tbl, net, &ip, dev, 0, 0, false);
net/ipv4/arp.c
1096
return arp_req_set_proxy(net, dev, 1);
net/ipv4/arp.c
1099
static int arp_req_set(struct net *net, struct arpreq *r)
net/ipv4/arp.c
1106
dev = arp_req_dev(net, r);
net/ipv4/arp.c
1111
return arp_req_set_public(net, r, dev);
net/ipv4/arp.c
1169
static int arp_req_get(struct net *net, struct arpreq *r)
net/ipv4/arp.c
1178
dev = arp_req_dev_by_name(net, r, true);
net/ipv4/arp.c
1230
static int arp_req_delete_public(struct net *net, struct arpreq *r,
net/ipv4/arp.c
1238
return pneigh_delete(&arp_tbl, net, &ip, dev);
net/ipv4/arp.c
1241
return arp_req_set_proxy(net, dev, 0);
net/ipv4/arp.c
1244
static int arp_req_delete(struct net *net, struct arpreq *r)
net/ipv4/arp.c
1249
dev = arp_req_dev(net, r);
net/ipv4/arp.c
1254
return arp_req_delete_public(net, r, dev);
net/ipv4/arp.c
1265
int arp_ioctl(struct net *net, unsigned int cmd, void __user *arg)
net/ipv4/arp.c
1274
if (!ns_capable(net->user_ns, CAP_NET_ADMIN))
net/ipv4/arp.c
1301
rtnl_net_lock(net);
net/ipv4/arp.c
1302
err = arp_req_delete(net, &r);
net/ipv4/arp.c
1303
rtnl_net_unlock(net);
net/ipv4/arp.c
1306
rtnl_net_lock(net);
net/ipv4/arp.c
1307
err = arp_req_set(net, &r);
net/ipv4/arp.c
1308
rtnl_net_unlock(net);
net/ipv4/arp.c
1312
err = arp_req_get(net, &r);
net/ipv4/arp.c
1496
static int __net_init arp_net_init(struct net *net)
net/ipv4/arp.c
1498
if (!proc_create_net("arp", 0444, net->proc_net, &arp_seq_ops,
net/ipv4/arp.c
1504
static void __net_exit arp_net_exit(struct net *net)
net/ipv4/arp.c
1506
remove_proc_entry("arp", net->proc_net);
net/ipv4/arp.c
398
struct net *net = dev_net(in_dev->dev);
net/ipv4/arp.c
429
return !inet_confirm_addr(net, in_dev, sip, tip, scope);
net/ipv4/arp.c
434
struct net *net = dev_net(in_dev->dev);
net/ipv4/arp.c
446
return !!inet_confirm_addr(net, in_dev, sip, 0, scope);
net/ipv4/arp.c
457
struct net *net = dev_net(dev);
net/ipv4/arp.c
459
rt = ip_route_output(net, sip, tip, 0, l3mdev_master_ifindex_rcu(dev),
net/ipv4/arp.c
464
__NET_INC_STATS(net, LINUX_MIB_ARPFILTER);
net/ipv4/arp.c
653
static int arp_xmit_finish(struct net *net, struct sock *sk, struct sk_buff *skb)
net/ipv4/arp.c
672
static bool arp_is_garp(struct net *net, struct net_device *dev,
net/ipv4/arp.c
691
*addr_type = inet_addr_type_dev_table(net, dev, sip);
net/ipv4/arp.c
702
static int arp_process(struct net *net, struct sock *sk, struct sk_buff *skb)
net/ipv4/arp.c
833
inet_addr_type_dev_table(net, dev, tip) == RTN_LOCAL &&
net/ipv4/arp.c
868
pneigh_lookup(&arp_tbl, net, &tip, dev)))) {
net/ipv4/arp.c
896
is_garp = arp_is_garp(net, dev, &addr_type, arp->ar_op,
net/ipv4/arp.c
911
inet_addr_type_dev_table(net, dev, sip) ==
net/ipv4/devinet.c
1024
cancel_delayed_work(&net->ipv4.addr_chk_work);
net/ipv4/devinet.c
1026
&net->ipv4.addr_chk_work, 0);
net/ipv4/devinet.c
1031
rtnl_net_unlock(net);
net/ipv4/devinet.c
1062
int devinet_ioctl(struct net *net, unsigned int cmd, struct ifreq *ifr)
net/ipv4/devinet.c
1083
dev_load(net, ifr->ifr_name);
net/ipv4/devinet.c
1101
if (!ns_capable(net->user_ns, CAP_NET_ADMIN))
net/ipv4/devinet.c
1109
if (!ns_capable(net->user_ns, CAP_NET_ADMIN))
net/ipv4/devinet.c
1120
rtnl_net_lock(net);
net/ipv4/devinet.c
1123
dev = __dev_get_by_name(net, ifr->ifr_name);
net/ipv4/devinet.c
114
static u32 inet_addr_hash(const struct net *net, __be32 addr)
net/ipv4/devinet.c
1140
(ifa = rtnl_net_dereference(net, *ifap)) != NULL;
net/ipv4/devinet.c
1154
(ifa = rtnl_net_dereference(net, *ifap)) != NULL;
net/ipv4/devinet.c
116
u32 val = __ipv4_addr_hash(addr, net_hash_mix(net));
net/ipv4/devinet.c
121
static void inet_hash_insert(struct net *net, struct in_ifaddr *ifa)
net/ipv4/devinet.c
123
u32 hash = inet_addr_hash(net, ifa->ifa_local);
net/ipv4/devinet.c
126
hlist_add_head_rcu(&ifa->addr_lst, &net->ipv4.inet_addr_lst[hash]);
net/ipv4/devinet.c
1300
rtnl_net_unlock(net);
net/ipv4/devinet.c
1365
struct net *net;
net/ipv4/devinet.c
1369
net = dev_net_rcu(dev);
net/ipv4/devinet.c
1401
(dev = dev_get_by_index_rcu(net, master_idx)) &&
net/ipv4/devinet.c
1412
for_each_netdev_rcu(net, dev) {
net/ipv4/devinet.c
143
struct net_device *__ip_dev_find(struct net *net, __be32 addr, bool devref)
net/ipv4/devinet.c
1482
__be32 inet_confirm_addr(struct net *net, struct in_device *in_dev,
net/ipv4/devinet.c
149
ifa = inet_lookup_ifaddr_rcu(net, addr);
net/ipv4/devinet.c
1492
for_each_netdev_rcu(net, dev) {
net/ipv4/devinet.c
158
local = fib_get_table(net, RT_TABLE_LOCAL);
net/ipv4/devinet.c
174
struct in_ifaddr *inet_lookup_ifaddr_rcu(struct net *net, __be32 addr)
net/ipv4/devinet.c
176
u32 hash = inet_addr_hash(net, addr);
net/ipv4/devinet.c
1786
struct net **tgt_net, struct sock *sk,
net/ipv4/devinet.c
179
hlist_for_each_entry_rcu(ifa, &net->ipv4.inet_addr_lst[hash], addr_lst)
net/ipv4/devinet.c
1821
struct net *net;
net/ipv4/devinet.c
1825
net = rtnl_get_net_ns_capable(sk, fillargs->netnsid);
net/ipv4/devinet.c
1826
if (IS_ERR(net)) {
net/ipv4/devinet.c
1829
return PTR_ERR(net);
net/ipv4/devinet.c
1831
*tgt_net = net;
net/ipv4/devinet.c
1915
static u32 inet_base_seq(const struct net *net)
net/ipv4/devinet.c
1917
u32 res = atomic_read(&net->ipv4.dev_addr_genid) +
net/ipv4/devinet.c
1918
READ_ONCE(net->dev_base_seq);
net/ipv4/devinet.c
1939
struct net *net = sock_net(skb->sk);
net/ipv4/devinet.c
1940
struct net *tgt_net = net;
net/ipv4/devinet.c
2011
struct net *net;
net/ipv4/devinet.c
2013
net = dev_net(ifa->ifa_dev->dev);
net/ipv4/devinet.c
2025
rtnl_notify(skb, net, portid, RTNLGRP_IPV4_IFADDR, nlh, GFP_KERNEL);
net/ipv4/devinet.c
2028
rtnl_set_sk_err(net, RTNLGRP_IPV4_IFADDR, err);
net/ipv4/devinet.c
2131
static bool devinet_conf_post_set(struct net *net, struct ipv4_devconf *cnf,
net/ipv4/devinet.c
2150
inet_netconf_notify_devconf(net, RTM_NEWNETCONF,
net/ipv4/devinet.c
2155
inet_netconf_notify_devconf(net, RTM_NEWNETCONF,
net/ipv4/devinet.c
2160
inet_netconf_notify_devconf(net, RTM_NEWNETCONF,
net/ipv4/devinet.c
2174
inet_netconf_notify_devconf(net, RTM_NEWNETCONF,
net/ipv4/devinet.c
2190
struct net *net = dev_net(dev);
net/ipv4/devinet.c
2206
if (devinet_conf_post_set(net, &in_dev->cnf, nla_type(a), new_value,
net/ipv4/devinet.c
2211
rt_cache_flush(net);
net/ipv4/devinet.c
2303
void inet_netconf_notify_devconf(struct net *net, int event, int type,
net/ipv4/devinet.c
2321
rtnl_notify(skb, net, 0, RTNLGRP_IPV4_NETCONF, NULL, GFP_KERNEL);
net/ipv4/devinet.c
2324
rtnl_set_sk_err(net, RTNLGRP_IPV4_NETCONF, err);
net/ipv4/devinet.c
2378
struct net *net = sock_net(in_skb->sk);
net/ipv4/devinet.c
2397
devconf = net->ipv4.devconf_all;
net/ipv4/devinet.c
2400
devconf = net->ipv4.devconf_dflt;
net/ipv4/devinet.c
2404
dev = dev_get_by_index(net, ifindex);
net/ipv4/devinet.c
2428
err = rtnl_unicast(skb, net, NETLINK_CB(in_skb).portid);
net/ipv4/devinet.c
2440
struct net *net = sock_net(skb->sk);
net/ipv4/devinet.c
2465
for_each_netdev_dump(net, dev, ctx->ifindex) {
net/ipv4/devinet.c
2480
net->ipv4.devconf_all,
net/ipv4/devinet.c
2491
net->ipv4.devconf_dflt,
net/ipv4/devinet.c
2507
static void devinet_copy_dflt_conf(struct net *net, int i)
net/ipv4/devinet.c
2512
for_each_netdev_rcu(net, dev) {
net/ipv4/devinet.c
2517
in_dev->cnf.data[i] = net->ipv4.devconf_dflt->data[i];
net/ipv4/devinet.c
2523
static void inet_forward_change(struct net *net)
net/ipv4/devinet.c
2526
int on = IPV4_DEVCONF_ALL(net, FORWARDING);
net/ipv4/devinet.c
2528
IPV4_DEVCONF_ALL(net, ACCEPT_REDIRECTS) = !on;
net/ipv4/devinet.c
2529
IPV4_DEVCONF_DFLT(net, FORWARDING) = on;
net/ipv4/devinet.c
2530
inet_netconf_notify_devconf(net, RTM_NEWNETCONF,
net/ipv4/devinet.c
2533
net->ipv4.devconf_all);
net/ipv4/devinet.c
2534
inet_netconf_notify_devconf(net, RTM_NEWNETCONF,
net/ipv4/devinet.c
2537
net->ipv4.devconf_dflt);
net/ipv4/devinet.c
2539
for_each_netdev(net, dev) {
net/ipv4/devinet.c
2548
inet_netconf_notify_devconf(net, RTM_NEWNETCONF,
net/ipv4/devinet.c
2555
static int devinet_conf_ifindex(struct net *net, struct ipv4_devconf *cnf)
net/ipv4/devinet.c
2557
if (cnf == net->ipv4.devconf_dflt)
net/ipv4/devinet.c
2559
else if (cnf == net->ipv4.devconf_all)
net/ipv4/devinet.c
2578
struct net *net = ctl->extra2;
net/ipv4/devinet.c
2593
if (cnf == net->ipv4.devconf_dflt)
net/ipv4/devinet.c
2594
devinet_copy_dflt_conf(net, i);
net/ipv4/devinet.c
2598
ifindex = devinet_conf_ifindex(net, cnf);
net/ipv4/devinet.c
2599
if (devinet_conf_post_set(net, cnf, i + 1, new_value,
net/ipv4/devinet.c
2601
rt_cache_flush(net);
net/ipv4/devinet.c
2613
struct net *net = ctl->extra2;
net/ipv4/devinet.c
2616
if (write && !ns_capable(net->user_ns, CAP_NET_ADMIN))
net/ipv4/devinet.c
2622
if (valp != &IPV4_DEVCONF_DFLT(net, FORWARDING)) {
net/ipv4/devinet.c
2623
if (!rtnl_net_trylock(net)) {
net/ipv4/devinet.c
2629
if (valp == &IPV4_DEVCONF_ALL(net, FORWARDING)) {
net/ipv4/devinet.c
2630
inet_forward_change(net);
net/ipv4/devinet.c
2637
inet_netconf_notify_devconf(net, RTM_NEWNETCONF,
net/ipv4/devinet.c
2642
rtnl_net_unlock(net);
net/ipv4/devinet.c
2643
rt_cache_flush(net);
net/ipv4/devinet.c
2645
inet_netconf_notify_devconf(net, RTM_NEWNETCONF,
net/ipv4/devinet.c
2648
net->ipv4.devconf_dflt);
net/ipv4/devinet.c
2727
static int __devinet_sysctl_register(struct net *net, char *dev_name,
net/ipv4/devinet.c
2741
t->devinet_vars[i].extra2 = net;
net/ipv4/devinet.c
2746
t->sysctl_header = register_net_sysctl(net, path, t->devinet_vars);
net/ipv4/devinet.c
2752
inet_netconf_notify_devconf(net, RTM_NEWNETCONF, NETCONFA_ALL,
net/ipv4/devinet.c
2762
static void __devinet_sysctl_unregister(struct net *net,
net/ipv4/devinet.c
2773
inet_netconf_notify_devconf(net, RTM_DELNETCONF, 0, ifindex, NULL);
net/ipv4/devinet.c
2795
struct net *net = dev_net(idev->dev);
net/ipv4/devinet.c
2797
__devinet_sysctl_unregister(net, &idev->cnf, idev->dev->ifindex);
net/ipv4/devinet.c
2815
static __net_init int devinet_init_net(struct net *net)
net/ipv4/devinet.c
2826
net->ipv4.inet_addr_lst = kmalloc_objs(struct hlist_head,
net/ipv4/devinet.c
2828
if (!net->ipv4.inet_addr_lst)
net/ipv4/devinet.c
2846
tbl[0].extra2 = net;
net/ipv4/devinet.c
2849
if (!net_eq(net, &init_net)) {
net/ipv4/devinet.c
2874
err = __devinet_sysctl_register(net, "all", NETCONFA_IFINDEX_ALL, all);
net/ipv4/devinet.c
2878
err = __devinet_sysctl_register(net, "default",
net/ipv4/devinet.c
2884
forw_hdr = register_net_sysctl_sz(net, "net/ipv4", tbl,
net/ipv4/devinet.c
2888
net->ipv4.forw_hdr = forw_hdr;
net/ipv4/devinet.c
2892
INIT_HLIST_HEAD(&net->ipv4.inet_addr_lst[i]);
net/ipv4/devinet.c
2894
INIT_DEFERRABLE_WORK(&net->ipv4.addr_chk_work, check_lifetime);
net/ipv4/devinet.c
2896
net->ipv4.devconf_all = all;
net/ipv4/devinet.c
2897
net->ipv4.devconf_dflt = dflt;
net/ipv4/devinet.c
2902
__devinet_sysctl_unregister(net, dflt, NETCONFA_IFINDEX_DEFAULT);
net/ipv4/devinet.c
2904
__devinet_sysctl_unregister(net, all, NETCONFA_IFINDEX_ALL);
net/ipv4/devinet.c
2913
kfree(net->ipv4.inet_addr_lst);
net/ipv4/devinet.c
2918
static __net_exit void devinet_exit_net(struct net *net)
net/ipv4/devinet.c
2924
cancel_delayed_work_sync(&net->ipv4.addr_chk_work);
net/ipv4/devinet.c
2927
tbl = net->ipv4.forw_hdr->ctl_table_arg;
net/ipv4/devinet.c
2928
unregister_net_sysctl_table(net->ipv4.forw_hdr);
net/ipv4/devinet.c
2929
__devinet_sysctl_unregister(net, net->ipv4.devconf_dflt,
net/ipv4/devinet.c
2931
__devinet_sysctl_unregister(net, net->ipv4.devconf_all,
net/ipv4/devinet.c
2935
kfree(net->ipv4.devconf_dflt);
net/ipv4/devinet.c
2936
kfree(net->ipv4.devconf_all);
net/ipv4/devinet.c
2937
kfree(net->ipv4.inet_addr_lst);
net/ipv4/devinet.c
495
struct net *net = dev_net(in_dev->dev);
net/ipv4/devinet.c
559
cancel_delayed_work(&net->ipv4.addr_chk_work);
net/ipv4/devinet.c
560
queue_delayed_work(system_power_efficient_wq, &net->ipv4.addr_chk_work, 0);
net/ipv4/devinet.c
596
struct in_device *inetdev_by_index(struct net *net, int ifindex)
net/ipv4/devinet.c
602
dev = dev_get_by_index_rcu(net, ifindex);
net/ipv4/devinet.c
626
static int ip_mc_autojoin_config(struct net *net, bool join,
net/ipv4/devinet.c
634
struct sock *sk = net->ipv4.mc_autojoin_sk;
net/ipv4/devinet.c
637
ASSERT_RTNL_NET(net);
net/ipv4/devinet.c
655
struct net *net = sock_net(skb->sk);
net/ipv4/devinet.c
670
rtnl_net_lock(net);
net/ipv4/devinet.c
672
in_dev = inetdev_by_index(net, ifm->ifa_index);
net/ipv4/devinet.c
680
(ifa = rtnl_net_dereference(net, *ifap)) != NULL;
net/ipv4/devinet.c
695
ip_mc_autojoin_config(net, false, ifa);
net/ipv4/devinet.c
704
rtnl_net_unlock(net);
net/ipv4/devinet.c
714
struct net *net;
net/ipv4/devinet.c
717
net = container_of(to_delayed_work(work), struct net, ipv4.addr_chk_work);
net/ipv4/devinet.c
722
struct hlist_head *head = &net->ipv4.inet_addr_lst[i];
net/ipv4/devinet.c
764
rtnl_net_lock(net);
net/ipv4/devinet.c
781
tmp = rtnl_net_dereference(net, *ifap);
net/ipv4/devinet.c
789
tmp = rtnl_net_dereference(net, *ifap);
net/ipv4/devinet.c
799
rtnl_net_unlock(net);
net/ipv4/devinet.c
814
queue_delayed_work(system_power_efficient_wq, &net->ipv4.addr_chk_work,
net/ipv4/devinet.c
882
static struct in_ifaddr *inet_rtm_to_ifa(struct net *net, struct nlmsghdr *nlh,
net/ipv4/devinet.c
892
dev = __dev_get_by_index(net, ifm->ifa_index);
net/ipv4/devinet.c
945
static struct in_ifaddr *find_matching_ifa(struct net *net, struct in_ifaddr *ifa)
net/ipv4/devinet.c
950
in_dev_for_each_ifa_rtnl_net(net, ifa1, in_dev) {
net/ipv4/devinet.c
96
#define IPV4_DEVCONF_DFLT(net, attr) \
net/ipv4/devinet.c
965
struct net *net = sock_net(skb->sk);
net/ipv4/devinet.c
97
IPV4_DEVCONF((*net->ipv4.devconf_dflt), attr)
net/ipv4/devinet.c
978
rtnl_net_lock(net);
net/ipv4/devinet.c
980
ifa = inet_rtm_to_ifa(net, nlh, tb, extack);
net/ipv4/devinet.c
986
ifa_existing = find_matching_ifa(net, ifa);
net/ipv4/devinet.c
993
ret = ip_mc_autojoin_config(net, true, ifa);
net/ipv4/esp4.c
129
struct net *net = xs_net(x);
net/ipv4/esp4.c
138
sk = inet_lookup_established(net, x->id.daddr.a4, dport,
net/ipv4/esp4.c
179
static int esp_output_tcp_encap_cb(struct net *net, struct sock *sk,
net/ipv4/esp4.c
942
struct net *net = dev_net(skb->dev);
net/ipv4/esp4.c
958
x = xfrm_state_lookup(net, skb->mark, (const xfrm_address_t *)&iph->daddr,
net/ipv4/esp4.c
964
ipv4_update_pmtu(skb, net, info, 0, IPPROTO_ESP);
net/ipv4/esp4.c
966
ipv4_redirect(skb, net, 0, IPPROTO_ESP);
net/ipv4/fib_frontend.c
101
rcu_assign_pointer(net->ipv4.fib_default, tb);
net/ipv4/fib_frontend.c
1017
struct net *net = sock_net(skb->sk);
net/ipv4/fib_frontend.c
1029
err = ip_valid_fib_dump_req(net, nlh, &filter, cb);
net/ipv4/fib_frontend.c
1043
tb = fib_get_table(net, filter.table_id);
net/ipv4/fib_frontend.c
1062
head = &net->ipv4.fib_table_hash[h];
net/ipv4/fib_frontend.c
108
hlist_add_head_rcu(&tb->tb_hlist, &net->ipv4.fib_table_hash[h]);
net/ipv4/fib_frontend.c
1096
struct net *net = dev_net(ifa->ifa_dev->dev);
net/ipv4/fib_frontend.c
1109
.nl_net = net,
net/ipv4/fib_frontend.c
1116
tb = fib_new_table(net, tb_id);
net/ipv4/fib_frontend.c
1128
fib_table_insert(net, tb, &cfg, NULL);
net/ipv4/fib_frontend.c
1130
fib_table_delete(net, tb, &cfg, NULL);
net/ipv4/fib_frontend.c
114
struct fib_table *fib_get_table(struct net *net, u32 id)
net/ipv4/fib_frontend.c
124
head = &net->ipv4.fib_table_hash[h];
net/ipv4/fib_frontend.c
134
static void fib_replace_table(struct net *net, struct fib_table *old,
net/ipv4/fib_frontend.c
1363
static void nl_fib_lookup(struct net *net, struct fib_result_nl *frn)
net/ipv4/fib_frontend.c
1377
tb = fib_get_table(net, frn->tb_id_in);
net/ipv4/fib_frontend.c
140
rcu_assign_pointer(net->ipv4.fib_main, new);
net/ipv4/fib_frontend.c
1400
struct net *net;
net/ipv4/fib_frontend.c
1405
net = sock_net(skb->sk);
net/ipv4/fib_frontend.c
1418
nl_fib_lookup(net, frn);
net/ipv4/fib_frontend.c
1423
nlmsg_unicast(net->ipv4.fibnl, skb, portid);
net/ipv4/fib_frontend.c
1426
static int __net_init nl_fib_lookup_init(struct net *net)
net/ipv4/fib_frontend.c
143
rcu_assign_pointer(net->ipv4.fib_default, new);
net/ipv4/fib_frontend.c
1433
sk = netlink_kernel_create(net, NETLINK_FIB_LOOKUP, &cfg);
net/ipv4/fib_frontend.c
1436
net->ipv4.fibnl = sk;
net/ipv4/fib_frontend.c
1440
static void nl_fib_lookup_exit(struct net *net)
net/ipv4/fib_frontend.c
1442
netlink_kernel_release(net->ipv4.fibnl);
net/ipv4/fib_frontend.c
1443
net->ipv4.fibnl = NULL;
net/ipv4/fib_frontend.c
1460
struct net *net = dev_net(dev);
net/ipv4/fib_frontend.c
1468
atomic_inc(&net->ipv4.dev_addr_genid);
net/ipv4/fib_frontend.c
1469
rt_cache_flush(net);
net/ipv4/fib_frontend.c
1473
atomic_inc(&net->ipv4.dev_addr_genid);
net/ipv4/fib_frontend.c
1480
rt_cache_flush(net);
net/ipv4/fib_frontend.c
1493
struct net *net = dev_net(dev);
net/ipv4/fib_frontend.c
1515
atomic_inc(&net->ipv4.dev_addr_genid);
net/ipv4/fib_frontend.c
1516
rt_cache_flush(net);
net/ipv4/fib_frontend.c
1527
rt_cache_flush(net);
net/ipv4/fib_frontend.c
1531
rt_cache_flush(net);
net/ipv4/fib_frontend.c
154
int fib_unmerge(struct net *net)
net/ipv4/fib_frontend.c
1554
static int __net_init ip_fib_net_init(struct net *net)
net/ipv4/fib_frontend.c
1559
err = fib4_notifier_init(net);
net/ipv4/fib_frontend.c
1565
net->ipv4.sysctl_fib_multipath_hash_fields =
net/ipv4/fib_frontend.c
1572
net->ipv4.fib_table_hash = kzalloc(size, GFP_KERNEL);
net/ipv4/fib_frontend.c
1573
if (!net->ipv4.fib_table_hash) {
net/ipv4/fib_frontend.c
1578
err = fib4_rules_init(net);
net/ipv4/fib_frontend.c
1584
kfree(net->ipv4.fib_table_hash);
net/ipv4/fib_frontend.c
1586
fib4_notifier_exit(net);
net/ipv4/fib_frontend.c
159
old = fib_get_table(net, RT_TABLE_LOCAL);
net/ipv4/fib_frontend.c
1590
static void ip_fib_net_exit(struct net *net)
net/ipv4/fib_frontend.c
1594
ASSERT_RTNL_NET(net);
net/ipv4/fib_frontend.c
1596
RCU_INIT_POINTER(net->ipv4.fib_main, NULL);
net/ipv4/fib_frontend.c
1597
RCU_INIT_POINTER(net->ipv4.fib_default, NULL);
net/ipv4/fib_frontend.c
1605
struct hlist_head *head = &net->ipv4.fib_table_hash[i];
net/ipv4/fib_frontend.c
1611
fib_table_flush(net, tb, true);
net/ipv4/fib_frontend.c
1617
static int __net_init fib_net_init(struct net *net)
net/ipv4/fib_frontend.c
1622
atomic_set(&net->ipv4.fib_num_tclassid_users, 0);
net/ipv4/fib_frontend.c
1624
error = ip_fib_net_init(net);
net/ipv4/fib_frontend.c
1628
error = fib4_semantics_init(net);
net/ipv4/fib_frontend.c
1632
error = nl_fib_lookup_init(net);
net/ipv4/fib_frontend.c
1636
error = fib_proc_init(net);
net/ipv4/fib_frontend.c
1643
nl_fib_lookup_exit(net);
net/ipv4/fib_frontend.c
1645
fib4_semantics_exit(net);
net/ipv4/fib_frontend.c
1647
rtnl_net_lock(net);
net/ipv4/fib_frontend.c
1648
ip_fib_net_exit(net);
net/ipv4/fib_frontend.c
1649
rtnl_net_unlock(net);
net/ipv4/fib_frontend.c
1652
fib4_rules_exit(net);
net/ipv4/fib_frontend.c
1654
kfree(net->ipv4.fib_table_hash);
net/ipv4/fib_frontend.c
1655
fib4_notifier_exit(net);
net/ipv4/fib_frontend.c
1659
static void __net_exit fib_net_pre_exit(struct net *net)
net/ipv4/fib_frontend.c
1661
fib_proc_exit(net);
net/ipv4/fib_frontend.c
1662
nl_fib_lookup_exit(net);
net/ipv4/fib_frontend.c
1665
static void __net_exit fib_net_exit_rtnl(struct net *net,
net/ipv4/fib_frontend.c
1668
ip_fib_net_exit(net);
net/ipv4/fib_frontend.c
1671
static void __net_exit fib_net_exit(struct net *net)
net/ipv4/fib_frontend.c
1674
fib4_rules_exit(net);
net/ipv4/fib_frontend.c
1676
kfree(net->ipv4.fib_table_hash);
net/ipv4/fib_frontend.c
1677
fib4_notifier_exit(net);
net/ipv4/fib_frontend.c
1678
fib4_semantics_exit(net);
net/ipv4/fib_frontend.c
172
fib_replace_table(net, old, new);
net/ipv4/fib_frontend.c
176
main_table = fib_get_table(net, RT_TABLE_MAIN);
net/ipv4/fib_frontend.c
186
void fib_flush(struct net *net)
net/ipv4/fib_frontend.c
192
struct hlist_head *head = &net->ipv4.fib_table_hash[h];
net/ipv4/fib_frontend.c
197
flushed += fib_table_flush(net, tb, false);
net/ipv4/fib_frontend.c
201
rt_cache_flush(net);
net/ipv4/fib_frontend.c
208
static inline unsigned int __inet_dev_addr_type(struct net *net,
net/ipv4/fib_frontend.c
224
table = fib_get_table(net, tb_id);
net/ipv4/fib_frontend.c
239
unsigned int inet_addr_type_table(struct net *net, __be32 addr, u32 tb_id)
net/ipv4/fib_frontend.c
241
return __inet_dev_addr_type(net, NULL, addr, tb_id);
net/ipv4/fib_frontend.c
245
unsigned int inet_addr_type(struct net *net, __be32 addr)
net/ipv4/fib_frontend.c
247
return __inet_dev_addr_type(net, NULL, addr, RT_TABLE_LOCAL);
net/ipv4/fib_frontend.c
251
unsigned int inet_dev_addr_type(struct net *net, const struct net_device *dev,
net/ipv4/fib_frontend.c
256
return __inet_dev_addr_type(net, dev, addr, rt_table);
net/ipv4/fib_frontend.c
263
unsigned int inet_addr_type_dev_table(struct net *net,
net/ipv4/fib_frontend.c
269
return __inet_dev_addr_type(net, NULL, addr, rt_table);
net/ipv4/fib_frontend.c
279
struct net *net;
net/ipv4/fib_frontend.c
289
net = dev_net(dev);
net/ipv4/fib_frontend.c
302
if (!fib_lookup(net, &fl4, &res, 0))
net/ipv4/fib_frontend.c
303
return fib_result_prefsrc(net, &res);
net/ipv4/fib_frontend.c
350
struct net *net = dev_net(dev);
net/ipv4/fib_frontend.c
367
fl4.flowi4_uid = sock_net_uid(net, NULL);
net/ipv4/fib_frontend.c
373
if (!fib4_rules_early_flow_dissect(net, skb, &fl4, &flkeys)) {
net/ipv4/fib_frontend.c
381
if (fib_lookup(net, &fl4, &res, 0))
net/ipv4/fib_frontend.c
399
dev == net->loopback_dev);
net/ipv4/fib_frontend.c
411
if (fib_lookup(net, &fl4, &res, FIB_LOOKUP_IGNORE_LINKSTATE) == 0) {
net/ipv4/fib_frontend.c
435
struct net *net = dev_net(dev);
net/ipv4/fib_frontend.c
437
if (!r && !fib_num_tclassid_users(net) &&
net/ipv4/fib_frontend.c
445
if (net->ipv4.fib_has_custom_local_routes ||
net/ipv4/fib_frontend.c
446
fib4_has_custom_rules(net))
net/ipv4/fib_frontend.c
451
if (inet_lookup_ifaddr_rcu(net, src))
net/ipv4/fib_frontend.c
481
static int rtentry_to_fib_config(struct net *net, int cmd, struct rtentry *rt,
net/ipv4/fib_frontend.c
488
cfg->fc_nlinfo.nl_net = net;
net/ipv4/fib_frontend.c
53
static int __net_init fib4_rules_init(struct net *net)
net/ipv4/fib_frontend.c
549
dev = __dev_get_by_name(net, devname);
net/ipv4/fib_frontend.c
564
in_dev_for_each_ifa_rtnl_net(net, ifa, in_dev) {
net/ipv4/fib_frontend.c
581
addr_type = inet_addr_type_table(net, addr, cfg->fc_table);
net/ipv4/fib_frontend.c
627
int ip_rt_ioctl(struct net *net, unsigned int cmd, struct rtentry *rt)
net/ipv4/fib_frontend.c
635
if (!ns_capable(net->user_ns, CAP_NET_ADMIN))
net/ipv4/fib_frontend.c
638
rtnl_net_lock(net);
net/ipv4/fib_frontend.c
639
err = rtentry_to_fib_config(net, cmd, rt, &cfg);
net/ipv4/fib_frontend.c
644
tb = fib_get_table(net, cfg.fc_table);
net/ipv4/fib_frontend.c
646
err = fib_table_delete(net, tb, &cfg,
net/ipv4/fib_frontend.c
651
tb = fib_new_table(net, cfg.fc_table);
net/ipv4/fib_frontend.c
653
err = fib_table_insert(net, tb,
net/ipv4/fib_frontend.c
66
&net->ipv4.fib_table_hash[TABLE_LOCAL_INDEX]);
net/ipv4/fib_frontend.c
662
rtnl_net_unlock(net);
net/ipv4/fib_frontend.c
68
&net->ipv4.fib_table_hash[TABLE_MAIN_INDEX]);
net/ipv4/fib_frontend.c
735
static int rtm_to_fib_config(struct net *net, struct sk_buff *skb,
net/ipv4/fib_frontend.c
77
struct fib_table *fib_new_table(struct net *net, u32 id)
net/ipv4/fib_frontend.c
771
cfg->fc_nlinfo.nl_net = net;
net/ipv4/fib_frontend.c
84
tb = fib_get_table(net, id);
net/ipv4/fib_frontend.c
88
if (id == RT_TABLE_LOCAL && !net->ipv4.fib_has_custom_rules)
net/ipv4/fib_frontend.c
880
struct net *net = sock_net(skb->sk);
net/ipv4/fib_frontend.c
885
err = rtm_to_fib_config(net, skb, nlh, &cfg, extack);
net/ipv4/fib_frontend.c
889
rtnl_net_lock(net);
net/ipv4/fib_frontend.c
89
alias = fib_new_table(net, RT_TABLE_MAIN);
net/ipv4/fib_frontend.c
891
if (cfg.fc_nh_id && !nexthop_find_by_id(net, cfg.fc_nh_id)) {
net/ipv4/fib_frontend.c
897
tb = fib_get_table(net, cfg.fc_table);
net/ipv4/fib_frontend.c
904
err = fib_table_delete(net, tb, &cfg, extack);
net/ipv4/fib_frontend.c
906
rtnl_net_unlock(net);
net/ipv4/fib_frontend.c
91
if (check_net(net))
net/ipv4/fib_frontend.c
914
struct net *net = sock_net(skb->sk);
net/ipv4/fib_frontend.c
919
err = rtm_to_fib_config(net, skb, nlh, &cfg, extack);
net/ipv4/fib_frontend.c
923
rtnl_net_lock(net);
net/ipv4/fib_frontend.c
925
tb = fib_new_table(net, cfg.fc_table);
net/ipv4/fib_frontend.c
931
err = fib_table_insert(net, tb, &cfg, extack);
net/ipv4/fib_frontend.c
933
net->ipv4.fib_has_custom_local_routes = true;
net/ipv4/fib_frontend.c
936
rtnl_net_unlock(net);
net/ipv4/fib_frontend.c
941
int ip_valid_fib_dump_req(struct net *net, const struct nlmsghdr *nlh,
net/ipv4/fib_frontend.c
98
rcu_assign_pointer(net->ipv4.fib_main, tb);
net/ipv4/fib_frontend.c
994
filter->dev = dev_get_by_index_rcu(net, ifindex);
net/ipv4/fib_lookup.h
41
int fib_nh_match(struct net *net, struct fib_config *cfg, struct fib_info *fi,
net/ipv4/fib_notifier.c
19
int call_fib4_notifiers(struct net *net, enum fib_event_type event_type,
net/ipv4/fib_notifier.c
26
WRITE_ONCE(net->ipv4.fib_seq, net->ipv4.fib_seq + 1);
net/ipv4/fib_notifier.c
27
return call_fib_notifiers(net, event_type, info);
net/ipv4/fib_notifier.c
30
static unsigned int fib4_seq_read(const struct net *net)
net/ipv4/fib_notifier.c
33
return READ_ONCE(net->ipv4.fib_seq) + fib4_rules_seq_read(net);
net/ipv4/fib_notifier.c
36
static int fib4_dump(struct net *net, struct notifier_block *nb,
net/ipv4/fib_notifier.c
41
err = fib4_rules_dump(net, nb, extack);
net/ipv4/fib_notifier.c
45
return fib_notify(net, nb, extack);
net/ipv4/fib_notifier.c
55
int __net_init fib4_notifier_init(struct net *net)
net/ipv4/fib_notifier.c
59
net->ipv4.fib_seq = 0;
net/ipv4/fib_notifier.c
61
ops = fib_notifier_ops_register(&fib4_notifier_ops_template, net);
net/ipv4/fib_notifier.c
64
net->ipv4.notifier_ops = ops;
net/ipv4/fib_notifier.c
69
void __net_exit fib4_notifier_exit(struct net *net)
net/ipv4/fib_notifier.c
71
fib_notifier_ops_unregister(net->ipv4.notifier_ops);
net/ipv4/fib_rules.c
217
static struct fib_table *fib_empty_table(struct net *net)
net/ipv4/fib_rules.c
222
if (!fib_get_table(net, id))
net/ipv4/fib_rules.c
223
return fib_new_table(net, id);
net/ipv4/fib_rules.c
275
struct net *net = rule->fr_net;
net/ipv4/fib_rules.c
305
err = fib_unmerge(net);
net/ipv4/fib_rules.c
313
table = fib_empty_table(net);
net/ipv4/fib_rules.c
333
atomic_inc(&net->ipv4.fib_num_tclassid_users);
net/ipv4/fib_rules.c
338
net->ipv4.fib_rules_require_fldissect++;
net/ipv4/fib_rules.c
345
net->ipv4.fib_has_custom_rules = true;
net/ipv4/fib_rules.c
354
struct net *net = rule->fr_net;
net/ipv4/fib_rules.c
358
atomic_dec(&net->ipv4.fib_num_tclassid_users);
net/ipv4/fib_rules.c
361
if (net->ipv4.fib_rules_require_fldissect &&
net/ipv4/fib_rules.c
363
net->ipv4.fib_rules_require_fldissect--;
net/ipv4/fib_rules.c
496
int __net_init fib4_rules_init(struct net *net)
net/ipv4/fib_rules.c
501
ops = fib_rules_register(&fib4_rules_ops_template, net);
net/ipv4/fib_rules.c
508
net->ipv4.rules_ops = ops;
net/ipv4/fib_rules.c
509
net->ipv4.fib_has_custom_rules = false;
net/ipv4/fib_rules.c
510
net->ipv4.fib_rules_require_fldissect = 0;
net/ipv4/fib_rules.c
519
void __net_exit fib4_rules_exit(struct net *net)
net/ipv4/fib_rules.c
521
fib_rules_unregister(net->ipv4.rules_ops);
net/ipv4/fib_rules.c
73
int fib4_rules_dump(struct net *net, struct notifier_block *nb,
net/ipv4/fib_rules.c
76
return fib_rules_dump(net, nb, AF_INET, extack);
net/ipv4/fib_rules.c
79
unsigned int fib4_rules_seq_read(const struct net *net)
net/ipv4/fib_rules.c
81
return fib_rules_seq_read(net, AF_INET);
net/ipv4/fib_rules.c
84
int __fib_lookup(struct net *net, struct flowi4 *flp,
net/ipv4/fib_rules.c
94
l3mdev_update_flow(net, flowi4_to_flowi(flp));
net/ipv4/fib_rules.c
96
err = fib_rules_lookup(net->ipv4.rules_ops, flowi4_to_flowi(flp), 0, &arg);
net/ipv4/fib_semantics.c
1071
static int fib_check_nh_v6_gw(struct net *net, struct fib_nh *nh,
net/ipv4/fib_semantics.c
1083
err = fib6_nh_init(net, &fib6_nh, &cfg, GFP_KERNEL, extack);
net/ipv4/fib_semantics.c
1140
static int fib_check_nh_v4_gw(struct net *net, struct fib_nh *nh, u32 table,
net/ipv4/fib_semantics.c
1154
dev = __dev_get_by_index(net, nh->fib_nh_oif);
net/ipv4/fib_semantics.c
1163
addr_type = inet_addr_type_dev_table(net, dev, nh->fib_nh_gw4);
net/ipv4/fib_semantics.c
1190
tbl = fib_get_table(net, table);
net/ipv4/fib_semantics.c
1202
err = fib_lookup(net, &fl4, &res,
net/ipv4/fib_semantics.c
1234
static int fib_check_nh_nongw(struct net *net, struct fib_nh *nh,
net/ipv4/fib_semantics.c
1249
in_dev = inetdev_by_index(net, nh->fib_nh_oif);
net/ipv4/fib_semantics.c
1269
int fib_check_nh(struct net *net, struct fib_nh *nh, u32 table, u8 scope,
net/ipv4/fib_semantics.c
1275
err = fib_check_nh_v4_gw(net, nh, table, scope, extack);
net/ipv4/fib_semantics.c
1277
err = fib_check_nh_v6_gw(net, nh, table, extack);
net/ipv4/fib_semantics.c
1279
err = fib_check_nh_nongw(net, nh, extack);
net/ipv4/fib_semantics.c
1284
__be32 fib_info_update_nhc_saddr(struct net *net, struct fib_nh_common *nhc,
net/ipv4/fib_semantics.c
1297
WRITE_ONCE(nh->nh_saddr_genid, atomic_read(&net->ipv4.dev_addr_genid));
net/ipv4/fib_semantics.c
1302
__be32 fib_result_prefsrc(struct net *net, struct fib_result *res)
net/ipv4/fib_semantics.c
1314
atomic_read(&net->ipv4.dev_addr_genid))
net/ipv4/fib_semantics.c
1318
return fib_info_update_nhc_saddr(net, nhc, res->fi->fib_scope);
net/ipv4/fib_semantics.c
1353
struct net *net = cfg->fc_nlinfo.nl_net;
net/ipv4/fib_semantics.c
1373
fi = fib_find_info_nh(net, cfg);
net/ipv4/fib_semantics.c
1380
nh = nexthop_find_by_id(net, cfg->fc_nh_id);
net/ipv4/fib_semantics.c
1396
fib_info_hash_grow(net);
net/ipv4/fib_semantics.c
1411
fi->fib_net = net;
net/ipv4/fib_semantics.c
1438
err = fib_nh_init(net, fi->fib_nh, cfg, 1, extack);
net/ipv4/fib_semantics.c
1489
nh->fib_nh_dev = dev_get_by_index(net, nh->fib_nh_oif);
net/ipv4/fib_semantics.c
1518
fib_info_update_nhc_saddr(net, &nexthop_nh->nh_common,
net/ipv4/fib_semantics.c
1540
net->ipv4.fib_info_cnt++;
net/ipv4/fib_semantics.c
1546
head = fib_info_laddrhash_bucket(net, fi->fib_prefsrc);
net/ipv4/fib_semantics.c
1816
struct net *net = dev_net(dev);
net/ipv4/fib_semantics.c
1824
head = fib_info_laddrhash_bucket(net, local);
net/ipv4/fib_semantics.c
1826
if (!net_eq(fi->fib_net, net) ||
net/ipv4/fib_semantics.c
211
void fib_nh_release(struct net *net, struct fib_nh *fib_nh)
net/ipv4/fib_semantics.c
215
atomic_dec(&net->ipv4.fib_num_tclassid_users);
net/ipv4/fib_semantics.c
2164
struct net *net = fi->fib_net;
net/ipv4/fib_semantics.c
2174
use_neigh = READ_ONCE(net->ipv4.sysctl_fib_multipath_use_neigh);
net/ipv4/fib_semantics.c
2204
void fib_select_path(struct net *net, struct fib_result *res,
net/ipv4/fib_semantics.c
2212
int h = fib_multipath_hash(net, fl4, skb, NULL);
net/ipv4/fib_semantics.c
2227
l3mdev = dev_get_by_index_rcu(net, fl4->flowi4_l3mdev);
net/ipv4/fib_semantics.c
2231
fl4->saddr = fib_result_prefsrc(net, res);
net/ipv4/fib_semantics.c
2237
int __net_init fib4_semantics_init(struct net *net)
net/ipv4/fib_semantics.c
2241
net->ipv4.fib_info_hash = fib_info_hash_alloc(hash_bits);
net/ipv4/fib_semantics.c
2242
if (!net->ipv4.fib_info_hash)
net/ipv4/fib_semantics.c
2245
net->ipv4.fib_info_hash_bits = hash_bits;
net/ipv4/fib_semantics.c
2246
net->ipv4.fib_info_cnt = 0;
net/ipv4/fib_semantics.c
2251
void __net_exit fib4_semantics_exit(struct net *net)
net/ipv4/fib_semantics.c
2253
fib_info_hash_free(net->ipv4.fib_info_hash);
net/ipv4/fib_semantics.c
327
static unsigned int fib_info_hashfn_result(const struct net *net,
net/ipv4/fib_semantics.c
330
return hash_32(val ^ net_hash_mix(net), net->ipv4.fib_info_hash_bits);
net/ipv4/fib_semantics.c
335
struct net *net = fi->fib_net;
net/ipv4/fib_semantics.c
350
return &net->ipv4.fib_info_hash[fib_info_hashfn_result(net, val)];
net/ipv4/fib_semantics.c
353
static struct hlist_head *fib_info_laddrhash_bucket(const struct net *net,
net/ipv4/fib_semantics.c
356
unsigned int hash_bits = net->ipv4.fib_info_hash_bits;
net/ipv4/fib_semantics.c
359
slot = hash_32(net_hash_mix(net) ^ (__force u32)val, hash_bits);
net/ipv4/fib_semantics.c
361
return &net->ipv4.fib_info_hash[(1 << hash_bits) + slot];
net/ipv4/fib_semantics.c
375
static void fib_info_hash_grow(struct net *net)
net/ipv4/fib_semantics.c
377
unsigned int old_size = 1 << net->ipv4.fib_info_hash_bits;
net/ipv4/fib_semantics.c
381
if (net->ipv4.fib_info_cnt < old_size)
net/ipv4/fib_semantics.c
384
new_info_hash = fib_info_hash_alloc(net->ipv4.fib_info_hash_bits + 1);
net/ipv4/fib_semantics.c
388
old_info_hash = net->ipv4.fib_info_hash;
net/ipv4/fib_semantics.c
389
net->ipv4.fib_info_hash = new_info_hash;
net/ipv4/fib_semantics.c
390
net->ipv4.fib_info_hash_bits += 1;
net/ipv4/fib_semantics.c
416
static struct fib_info *fib_find_info_nh(struct net *net,
net/ipv4/fib_semantics.c
427
hash = fib_info_hashfn_result(net, hash);
net/ipv4/fib_semantics.c
428
head = &net->ipv4.fib_info_hash[hash];
net/ipv4/fib_semantics.c
610
int fib_nh_common_init(struct net *net, struct fib_nh_common *nhc,
net/ipv4/fib_semantics.c
625
err = lwtunnel_build_state(net, encap_type, encap,
net/ipv4/fib_semantics.c
642
int fib_nh_init(struct net *net, struct fib_nh *nh,
net/ipv4/fib_semantics.c
650
err = fib_nh_common_init(net, &nh->nh_common, cfg->fc_encap,
net/ipv4/fib_semantics.c
667
atomic_inc(&net->ipv4.fib_num_tclassid_users);
net/ipv4/fib_semantics.c
715
struct net *net = fi->fib_net;
net/ipv4/fib_semantics.c
783
ret = fib_nh_init(net, nexthop_nh, &fib_cfg,
net/ipv4/fib_semantics.c
875
static int fib_encap_match(struct net *net, u16 encap_type,
net/ipv4/fib_semantics.c
887
ret = lwtunnel_build_state(net, encap_type, encap, AF_INET,
net/ipv4/fib_semantics.c
897
int fib_nh_match(struct net *net, struct fib_config *cfg, struct fib_info *fi,
net/ipv4/fib_semantics.c
925
if (fib_encap_match(net, cfg->fc_encap_type,
net/ipv4/fib_trie.c
1011
fib_find_matching_alias(struct net *net, const struct fib_rt_info *fri)
net/ipv4/fib_trie.c
1019
tb = fib_get_table(net, fri->tb_id);
net/ipv4/fib_trie.c
1038
void fib_alias_hw_flags_set(struct net *net, const struct fib_rt_info *fri)
net/ipv4/fib_trie.c
1047
fa_match = fib_find_matching_alias(net, fri);
net/ipv4/fib_trie.c
1062
fib_notify_on_flag_change = READ_ONCE(net->ipv4.sysctl_fib_notify_on_flag_change);
net/ipv4/fib_trie.c
107
return call_fib4_notifiers(net, event_type, &info.info);
net/ipv4/fib_trie.c
1088
rtnl_notify(skb, net, 0, RTNLGRP_IPV4_ROUTE, NULL, GFP_ATOMIC);
net/ipv4/fib_trie.c
1092
rtnl_set_sk_err(net, RTNLGRP_IPV4_ROUTE, err);
net/ipv4/fib_trie.c
1194
int fib_table_insert(struct net *net, struct fib_table *tb,
net/ipv4/fib_trie.c
1299
err = call_fib_entry_notifiers(net, fib_event,
net/ipv4/fib_trie.c
1370
err = call_fib_entry_notifiers(net, fib_event, key, plen,
net/ipv4/fib_trie.c
1657
static void fib_notify_alias_delete(struct net *net, u32 key,
net/ipv4/fib_trie.c
1683
call_fib_entry_notifiers(net, fib_event, key, KEYLENGTH - slen,
net/ipv4/fib_trie.c
1688
int fib_table_delete(struct net *net, struct fib_table *tb,
net/ipv4/fib_trie.c
1729
fib_nh_match(net, cfg, fi, extack) == 0 &&
net/ipv4/fib_trie.c
1739
fib_notify_alias_delete(net, key, &l->leaf, fa_to_delete, extack);
net/ipv4/fib_trie.c
2000
int fib_table_flush(struct net *net, struct fib_table *tb, bool flush_all)
net/ipv4/fib_trie.c
2003
struct nl_info info = { .nl_net = net };
net/ipv4/fib_trie.c
2059
fib_notify_alias_delete(net, n->key, &n->leaf, fa,
net/ipv4/fib_trie.c
2084
static void __fib_info_notify_update(struct net *net, struct fib_table *tb,
net/ipv4/fib_trie.c
2132
void fib_info_notify_update(struct net *net, struct nl_info *info)
net/ipv4/fib_trie.c
2137
struct hlist_head *head = &net->ipv4.fib_table_hash[h];
net/ipv4/fib_trie.c
2142
__fib_info_notify_update(net, tb, info);
net/ipv4/fib_trie.c
2204
int fib_notify(struct net *net, struct notifier_block *nb,
net/ipv4/fib_trie.c
2211
struct hlist_head *head = &net->ipv4.fib_table_hash[h];
net/ipv4/fib_trie.c
2610
struct net *net = seq->private;
net/ipv4/fib_trie.c
2620
struct hlist_head *head = &net->ipv4.fib_table_hash[h];
net/ipv4/fib_trie.c
2648
struct net *net = seq_file_net(seq);
net/ipv4/fib_trie.c
2653
struct hlist_head *head = &net->ipv4.fib_table_hash[h];
net/ipv4/fib_trie.c
2682
struct net *net = seq_file_net(seq);
net/ipv4/fib_trie.c
2705
struct hlist_head *head = &net->ipv4.fib_table_hash[h];
net/ipv4/fib_trie.c
3008
int __net_init fib_proc_init(struct net *net)
net/ipv4/fib_trie.c
3010
if (!proc_create_net("fib_trie", 0444, net->proc_net, &fib_trie_seq_ops,
net/ipv4/fib_trie.c
3014
if (!proc_create_net_single("fib_triestat", 0444, net->proc_net,
net/ipv4/fib_trie.c
3018
if (!proc_create_net("route", 0444, net->proc_net, &fib_route_seq_ops,
net/ipv4/fib_trie.c
3025
remove_proc_entry("fib_triestat", net->proc_net);
net/ipv4/fib_trie.c
3027
remove_proc_entry("fib_trie", net->proc_net);
net/ipv4/fib_trie.c
3032
void __net_exit fib_proc_exit(struct net *net)
net/ipv4/fib_trie.c
3034
remove_proc_entry("fib_trie", net->proc_net);
net/ipv4/fib_trie.c
3035
remove_proc_entry("fib_triestat", net->proc_net);
net/ipv4/fib_trie.c
3036
remove_proc_entry("route", net->proc_net);
net/ipv4/fib_trie.c
93
static int call_fib_entry_notifiers(struct net *net,
net/ipv4/fou_core.c
1213
static __net_init int fou_init_net(struct net *net)
net/ipv4/fou_core.c
1215
struct fou_net *fn = net_generic(net, fou_net_id);
net/ipv4/fou_core.c
1222
static __net_exit void fou_exit_net(struct net *net)
net/ipv4/fou_core.c
1224
struct fou_net *fn = net_generic(net, fou_net_id);
net/ipv4/fou_core.c
539
static int fou_add_to_port_list(struct net *net, struct fou *fou,
net/ipv4/fou_core.c
542
struct fou_net *fn = net_generic(net, fou_net_id);
net/ipv4/fou_core.c
566
static int fou_create(struct net *net, struct fou_cfg *cfg,
net/ipv4/fou_core.c
576
err = udp_sock_create(net, &cfg->udp_config, &sock);
net/ipv4/fou_core.c
618
setup_udp_tunnel_sock(net, sk, &tunnel_cfg);
net/ipv4/fou_core.c
622
err = fou_add_to_port_list(net, fou, cfg);
net/ipv4/fou_core.c
639
static int fou_destroy(struct net *net, struct fou_cfg *cfg)
net/ipv4/fou_core.c
641
struct fou_net *fn = net_generic(net, fou_net_id);
net/ipv4/fou_core.c
753
struct net *net = genl_info_net(info);
net/ipv4/fou_core.c
761
return fou_create(net, &cfg, NULL);
net/ipv4/fou_core.c
766
struct net *net = genl_info_net(info);
net/ipv4/fou_core.c
774
return fou_destroy(net, &cfg);
net/ipv4/fou_core.c
835
struct net *net = genl_info_net(info);
net/ipv4/fou_core.c
836
struct fou_net *fn = net_generic(net, fou_net_id);
net/ipv4/fou_core.c
882
struct net *net = sock_net(skb->sk);
net/ipv4/fou_core.c
883
struct fou_net *fn = net_generic(net, fou_net_id);
net/ipv4/icmp.c
1117
struct net *net;
net/ipv4/icmp.c
1120
net = skb_dst_dev_net_rcu(skb);
net/ipv4/icmp.c
1152
switch (READ_ONCE(net->ipv4.sysctl_ip_no_pmtu_disc)) {
net/ipv4/icmp.c
1181
__ICMP_INC_STATS(net, ICMP_MIB_INTIMEEXCDS);
net/ipv4/icmp.c
1205
if (!READ_ONCE(net->ipv4.sysctl_icmp_ignore_bogus_error_responses) &&
net/ipv4/icmp.c
1206
inet_addr_type_dev_table(net, skb->dev, iph->daddr) == RTN_BROADCAST) {
net/ipv4/icmp.c
1219
__ICMP_INC_STATS(net, ICMP_MIB_INERRORS);
net/ipv4/icmp.c
1262
struct net *net;
net/ipv4/icmp.c
1264
net = skb_dst_dev_net_rcu(skb);
net/ipv4/icmp.c
1266
if (READ_ONCE(net->ipv4.sysctl_icmp_echo_ignore_all))
net/ipv4/icmp.c
1293
struct net *net = dev_net_rcu(skb->dev);
net/ipv4/icmp.c
1303
if (!READ_ONCE(net->ipv4.sysctl_icmp_echo_enable_probe))
net/ipv4/icmp.c
1341
dev = dev_get_by_name(net, buff);
net/ipv4/icmp.c
1346
dev = dev_get_by_index(net, ntohl(iio->ident.ifindex));
net/ipv4/icmp.c
1357
dev = ip_dev_find(net, iio->ident.addr.ip_addr.ipv4_addr);
net/ipv4/icmp.c
1363
dev = ipv6_dev_find(net, &iio->ident.addr.ip_addr.ipv6_addr, dev);
net/ipv4/icmp.c
1451
struct net *net = dev_net_rcu(rt->dst.dev);
net/ipv4/icmp.c
1479
__ICMP_INC_STATS(net, ICMP_MIB_INMSGS);
net/ipv4/icmp.c
1489
ICMPMSGIN_INC_STATS(net, icmph->type);
net/ipv4/icmp.c
1513
READ_ONCE(net->ipv4.sysctl_icmp_echo_ignore_broadcasts)) {
net/ipv4/icmp.c
1555
__ICMP_INC_STATS(net, ICMP_MIB_CSUMERRORS);
net/ipv4/icmp.c
1557
__ICMP_INC_STATS(net, ICMP_MIB_INERRORS);
net/ipv4/icmp.c
1624
struct net *net = dev_net_rcu(skb->dev);
net/ipv4/icmp.c
1638
ipv4_update_pmtu(skb, net, info, 0, IPPROTO_ICMP);
net/ipv4/icmp.c
1640
ipv4_redirect(skb, net, 0, IPPROTO_ICMP);
net/ipv4/icmp.c
1719
static int __net_init icmp_sk_init(struct net *net)
net/ipv4/icmp.c
1722
net->ipv4.sysctl_icmp_echo_ignore_all = 0;
net/ipv4/icmp.c
1723
net->ipv4.sysctl_icmp_echo_enable_probe = 0;
net/ipv4/icmp.c
1724
net->ipv4.sysctl_icmp_echo_ignore_broadcasts = 1;
net/ipv4/icmp.c
1727
net->ipv4.sysctl_icmp_ignore_bogus_error_responses = 1;
net/ipv4/icmp.c
1741
net->ipv4.sysctl_icmp_ratelimit = 1 * HZ;
net/ipv4/icmp.c
1742
net->ipv4.sysctl_icmp_ratemask = 0x1818;
net/ipv4/icmp.c
1743
net->ipv4.sysctl_icmp_errors_use_inbound_ifaddr = 0;
net/ipv4/icmp.c
1744
net->ipv4.sysctl_icmp_errors_extension_mask = 0;
net/ipv4/icmp.c
1745
net->ipv4.sysctl_icmp_msgs_per_sec = 10000;
net/ipv4/icmp.c
1746
net->ipv4.sysctl_icmp_msgs_burst = 10000;
net/ipv4/icmp.c
206
static inline struct sock *icmp_xmit_lock(struct net *net)
net/ipv4/icmp.c
218
sock_net_set(sk, net);
net/ipv4/icmp.c
236
bool icmp_global_allow(struct net *net)
net/ipv4/icmp.c
245
if (atomic_read(&net->ipv4.icmp_global_credit) > 0)
net/ipv4/icmp.c
249
oldstamp = READ_ONCE(net->ipv4.icmp_global_stamp);
net/ipv4/icmp.c
254
incr = READ_ONCE(net->ipv4.sysctl_icmp_msgs_per_sec);
net/ipv4/icmp.c
259
if (cmpxchg(&net->ipv4.icmp_global_stamp, oldstamp, now) == oldstamp) {
net/ipv4/icmp.c
260
old = atomic_read(&net->ipv4.icmp_global_credit);
net/ipv4/icmp.c
262
new = min(old + incr, READ_ONCE(net->ipv4.sysctl_icmp_msgs_burst));
net/ipv4/icmp.c
263
} while (!atomic_try_cmpxchg(&net->ipv4.icmp_global_credit, &old, new));
net/ipv4/icmp.c
268
void icmp_global_consume(struct net *net)
net/ipv4/icmp.c
274
atomic_sub(credits, &net->ipv4.icmp_global_credit);
net/ipv4/icmp.c
277
static bool icmpv4_mask_allow(struct net *net, int type, int code)
net/ipv4/icmp.c
287
if (!((1 << type) & READ_ONCE(net->ipv4.sysctl_icmp_ratemask)))
net/ipv4/icmp.c
293
static bool icmpv4_global_allow(struct net *net, int type, int code,
net/ipv4/icmp.c
296
if (icmpv4_mask_allow(net, type, code))
net/ipv4/icmp.c
299
if (icmp_global_allow(net)) {
net/ipv4/icmp.c
303
__ICMP_INC_STATS(net, ICMP_MIB_RATELIMITGLOBAL);
net/ipv4/icmp.c
311
static bool icmpv4_xrlim_allow(struct net *net, struct rtable *rt,
net/ipv4/icmp.c
324
peer_timeout = READ_ONCE(net->ipv4.sysctl_icmp_ratelimit);
net/ipv4/icmp.c
334
peer = inet_getpeer_v4(net->ipv4.peers, fl4->daddr,
net/ipv4/icmp.c
342
__ICMP_INC_STATS(net, ICMP_MIB_RATELIMITHOST);
net/ipv4/icmp.c
344
icmp_global_consume(net);
net/ipv4/icmp.c
351
void icmp_out_count(struct net *net, unsigned char type)
net/ipv4/icmp.c
353
ICMPMSGOUT_INC_STATS(net, type);
net/ipv4/icmp.c
354
ICMP_INC_STATS(net, ICMP_MIB_OUTMSGS);
net/ipv4/icmp.c
419
struct net *net = dev_net_rcu(rt->dst.dev);
net/ipv4/icmp.c
425
u32 mark = IP4_REPLY_MARK(net, skb->mark);
net/ipv4/icmp.c
429
if (ip_options_echo(net, &icmp_param->replyopts.opt, skb))
net/ipv4/icmp.c
436
if (!icmpv4_global_allow(net, type, code, &apply_ratelimit))
net/ipv4/icmp.c
439
sk = icmp_xmit_lock(net);
net/ipv4/icmp.c
460
fl4.flowi4_uid = sock_net_uid(net, NULL);
net/ipv4/icmp.c
465
rt = ip_route_output_key(net, &fl4);
net/ipv4/icmp.c
468
if (icmpv4_xrlim_allow(net, rt, &fl4, type, code, apply_ratelimit))
net/ipv4/icmp.c
494
static struct rtable *icmp_route_lookup(struct net *net, struct flowi4 *fl4,
net/ipv4/icmp.c
511
fl4->flowi4_uid = sock_net_uid(net, NULL);
net/ipv4/icmp.c
520
rt = ip_route_output_key_hash(net, fl4, skb_in);
net/ipv4/icmp.c
527
dst = xfrm_lookup(net, &rt->dst,
net/ipv4/icmp.c
533
if (inet_addr_type_dev_table(net, route_lookup_dev,
net/ipv4/icmp.c
541
err = xfrm_decode_session_reverse(net, skb_in, flowi4_to_flowi(&fl4_dec), AF_INET);
net/ipv4/icmp.c
545
if (inet_addr_type_dev_table(net, route_lookup_dev,
net/ipv4/icmp.c
547
rt2 = __ip_route_output_key(net, &fl4_dec);
net/ipv4/icmp.c
567
rt2 = __ip_route_output_key(net, &fl4_2);
net/ipv4/icmp.c
602
dst2 = xfrm_lookup(net, &rt2->dst, flowi4_to_flowi(&fl4_dec), NULL,
net/ipv4/icmp.c
681
static void icmp_ext_iio_iif_append(struct net *net, struct sk_buff *skb,
net/ipv4/icmp.c
703
dev = dev_get_by_index_rcu(net, iif);
net/ipv4/icmp.c
731
static void icmp_ext_objs_append(struct net *net, struct sk_buff *skb,
net/ipv4/icmp.c
735
icmp_ext_iio_iif_append(net, skb, iif);
net/ipv4/icmp.c
739
icmp_ext_append(struct net *net, struct sk_buff *skb_in, struct icmphdr *icmph,
net/ipv4/icmp.c
757
ext_objs = READ_ONCE(net->ipv4.sysctl_icmp_errors_extension_mask);
net/ipv4/icmp.c
785
icmp_ext_objs_append(net, skb, ext_objs, iif);
net/ipv4/icmp.c
829
struct net *net;
net/ipv4/icmp.c
838
net = dev_net_rcu(rt->dst.dev);
net/ipv4/icmp.c
840
net = dev_net_rcu(skb_in->dev);
net/ipv4/icmp.c
915
!icmpv4_global_allow(net, type, code, &apply_ratelimit))
net/ipv4/icmp.c
918
sk = icmp_xmit_lock(net);
net/ipv4/icmp.c
932
READ_ONCE(net->ipv4.sysctl_icmp_errors_use_inbound_ifaddr))
net/ipv4/icmp.c
933
dev = dev_get_by_index_rcu(net, parm->iif ? parm->iif :
net/ipv4/icmp.c
947
mark = IP4_REPLY_MARK(net, skb_in->mark);
net/ipv4/icmp.c
949
if (__ip_options_echo(net, &icmp_param->replyopts.opt, skb_in,
net/ipv4/icmp.c
970
rt = icmp_route_lookup(net, &fl4, skb_in, iph, saddr,
net/ipv4/icmp.c
980
if (!icmpv4_xrlim_allow(net, rt, &fl4, type, code, apply_ratelimit))
net/ipv4/icmp.c
996
ext_skb = icmp_ext_append(net, skb_in, &icmp_param->data.icmph, room,
net/ipv4/igmp.c
1046
ih3->qrv ?: READ_ONCE(net->ipv4.sysctl_igmp_qrv));
net/ipv4/igmp.c
1085
!READ_ONCE(net->ipv4.sysctl_igmp_llm_reports))
net/ipv4/igmp.c
1210
struct net *net = dev_net(in_dev->dev);
net/ipv4/igmp.c
1226
pmc->crcount = in_dev->mr_qrv ?: READ_ONCE(net->ipv4.sysctl_igmp_qrv);
net/ipv4/igmp.c
1252
struct net *net = dev_net(in_dev->dev);
net/ipv4/igmp.c
1278
READ_ONCE(net->ipv4.sysctl_igmp_qrv);
net/ipv4/igmp.c
1281
READ_ONCE(net->ipv4.sysctl_igmp_qrv);
net/ipv4/igmp.c
1326
struct net *net = dev_net(in_dev->dev);
net/ipv4/igmp.c
1339
!READ_ONCE(net->ipv4.sysctl_igmp_llm_reports))
net/ipv4/igmp.c
1370
struct net *net = dev_net(in_dev->dev);
net/ipv4/igmp.c
1382
!READ_ONCE(net->ipv4.sysctl_igmp_llm_reports))
net/ipv4/igmp.c
1388
im->unsolicit_count = READ_ONCE(net->ipv4.sysctl_igmp_qrv);
net/ipv4/igmp.c
1402
im->crcount = in_dev->mr_qrv ?: READ_ONCE(net->ipv4.sysctl_igmp_qrv);
net/ipv4/igmp.c
1505
struct net *net = dev_net(dev);
net/ipv4/igmp.c
1523
rtnl_notify(skb, net, 0, RTNLGRP_IPV4_MCADDR, NULL, GFP_KERNEL);
net/ipv4/igmp.c
1526
rtnl_set_sk_err(net, RTNLGRP_IPV4_MCADDR, err);
net/ipv4/igmp.c
1761
struct net *net = dev_net(in_dev->dev);
net/ipv4/igmp.c
1769
!READ_ONCE(net->ipv4.sysctl_igmp_llm_reports))
net/ipv4/igmp.c
1878
struct net *net = dev_net(in_dev->dev);
net/ipv4/igmp.c
1882
in_dev->mr_qrv = READ_ONCE(net->ipv4.sysctl_igmp_qrv);
net/ipv4/igmp.c
1948
static struct in_device *ip_mc_find_dev(struct net *net, struct ip_mreqn *imr)
net/ipv4/igmp.c
1954
idev = inetdev_by_index(net, imr->imr_ifindex);
net/ipv4/igmp.c
1958
dev = __ip_dev_find(net, imr->imr_address.s_addr, false);
net/ipv4/igmp.c
1964
struct rtable *rt = ip_route_output(net,
net/ipv4/igmp.c
2007
struct net *net = dev_net(in_dev->dev);
net/ipv4/igmp.c
2018
psf->sf_crcount = in_dev->mr_qrv ?: READ_ONCE(net->ipv4.sysctl_igmp_qrv);
net/ipv4/igmp.c
2076
struct net *net = dev_net(in_dev->dev);
net/ipv4/igmp.c
2082
pmc->crcount = in_dev->mr_qrv ?: READ_ONCE(net->ipv4.sysctl_igmp_qrv);
net/ipv4/igmp.c
2249
struct net *net = dev_net(pmc->interface->dev);
net/ipv4/igmp.c
2261
pmc->crcount = in_dev->mr_qrv ?: READ_ONCE(net->ipv4.sysctl_igmp_qrv);
net/ipv4/igmp.c
2301
struct net *net = sock_net(sk);
net/ipv4/igmp.c
2311
in_dev = ip_mc_find_dev(net, imr);
net/ipv4/igmp.c
2327
if (count >= READ_ONCE(net->ipv4.sysctl_igmp_max_memberships))
net/ipv4/igmp.c
2386
struct net *net = sock_net(sk);
net/ipv4/igmp.c
2393
in_dev = ip_mc_find_dev(net, imr);
net/ipv4/igmp.c
2438
struct net *net = sock_net(sk);
net/ipv4/igmp.c
2450
in_dev = ip_mc_find_dev(net, &imr);
net/ipv4/igmp.c
2514
if (psl && psl->sl_count >= READ_ONCE(net->ipv4.sysctl_igmp_max_msf)) {
net/ipv4/igmp.c
2576
struct net *net = sock_net(sk);
net/ipv4/igmp.c
2590
in_dev = ip_mc_find_dev(net, &imr);
net/ipv4/igmp.c
2667
struct net *net = sock_net(sk);
net/ipv4/igmp.c
2677
in_dev = ip_mc_find_dev(net, &imr);
net/ipv4/igmp.c
2818
struct net *net = sock_net(sk);
net/ipv4/igmp.c
2828
in_dev = inetdev_by_index(net, iml->multi.imr_ifindex);
net/ipv4/igmp.c
2896
struct net *net = seq_file_net(seq);
net/ipv4/igmp.c
2901
for_each_netdev_rcu(net, state->dev) {
net/ipv4/igmp.c
3029
struct net *net = seq_file_net(seq);
net/ipv4/igmp.c
3036
for_each_netdev_rcu(net, state->dev) {
net/ipv4/igmp.c
3149
static int __net_init igmp_net_init(struct net *net)
net/ipv4/igmp.c
3154
pde = proc_create_net("igmp", 0444, net->proc_net, &igmp_mc_seq_ops,
net/ipv4/igmp.c
3158
pde = proc_create_net("mcfilter", 0444, net->proc_net,
net/ipv4/igmp.c
3162
err = inet_ctl_sock_create(&net->ipv4.mc_autojoin_sk, AF_INET,
net/ipv4/igmp.c
3163
SOCK_DGRAM, 0, net);
net/ipv4/igmp.c
3173
remove_proc_entry("mcfilter", net->proc_net);
net/ipv4/igmp.c
3175
remove_proc_entry("igmp", net->proc_net);
net/ipv4/igmp.c
3180
static void __net_exit igmp_net_exit(struct net *net)
net/ipv4/igmp.c
3182
remove_proc_entry("mcfilter", net->proc_net);
net/ipv4/igmp.c
3183
remove_proc_entry("igmp", net->proc_net);
net/ipv4/igmp.c
3184
inet_ctl_sock_destroy(net->ipv4.mc_autojoin_sk);
net/ipv4/igmp.c
384
struct net *net = dev_net(dev);
net/ipv4/igmp.c
402
rt = ip_route_output_ports(net, &fl4, NULL, IGMPV3_ALL_MCR, 0,
net/ipv4/igmp.c
433
ip_select_ident(net, skb, NULL);
net/ipv4/igmp.c
494
struct net *net = dev_net(dev);
net/ipv4/igmp.c
504
!READ_ONCE(net->ipv4.sysctl_igmp_llm_reports))
net/ipv4/igmp.c
621
struct net *net = dev_net(in_dev->dev);
net/ipv4/igmp.c
630
!READ_ONCE(net->ipv4.sysctl_igmp_llm_reports))
net/ipv4/igmp.c
764
struct net *net = dev_net(dev);
net/ipv4/igmp.c
774
!READ_ONCE(net->ipv4.sysctl_igmp_llm_reports))
net/ipv4/igmp.c
782
rt = ip_route_output_ports(net, &fl4, NULL, dst, 0,
net/ipv4/igmp.c
813
ip_select_ident(net, skb, NULL);
net/ipv4/igmp.c
826
return ip_local_out(net, skb->sk, skb);
net/ipv4/igmp.c
860
struct net *net = dev_net(in_dev->dev);
net/ipv4/igmp.c
863
WRITE_ONCE(in_dev->mr_ifc_count, in_dev->mr_qrv ?: READ_ONCE(net->ipv4.sysctl_igmp_qrv));
net/ipv4/igmp.c
952
struct net *net = dev_net(in_dev->dev);
net/ipv4/igmp.c
959
!READ_ONCE(net->ipv4.sysctl_igmp_llm_reports))
net/ipv4/igmp.c
983
struct net *net = dev_net(in_dev->dev);
net/ipv4/inet_connection_sock.c
1028
struct net *net;
net/ipv4/inet_connection_sock.c
1056
net = sock_net(sk_listener);
net/ipv4/inet_connection_sock.c
1058
READ_ONCE(net->ipv4.sysctl_tcp_synack_retries);
net/ipv4/inet_connection_sock.c
1112
__NET_INC_STATS(net, LINUX_MIB_TCPMIGRATEREQSUCCESS);
net/ipv4/inet_connection_sock.c
1126
__NET_INC_STATS(net, LINUX_MIB_TCPMIGRATEREQFAILURE);
net/ipv4/inet_connection_sock.c
276
const struct net *net = sock_net(sk);
net/ipv4/inet_connection_sock.c
290
head2 = inet_bhash2_addr_any_hashbucket(sk, net, port);
net/ipv4/inet_connection_sock.c
295
if (!inet_bind2_bucket_match_addr_any(tb2, net, port, l3mdev, sk))
net/ipv4/inet_connection_sock.c
322
struct net *net = sock_net(sk);
net/ipv4/inet_connection_sock.c
359
if (inet_is_local_reserved_port(net, port))
net/ipv4/inet_connection_sock.c
361
head = &hinfo->bhash[inet_bhashfn(net, port,
net/ipv4/inet_connection_sock.c
369
head2 = inet_bhashfn_portaddr(hinfo, sk, net, port);
net/ipv4/inet_connection_sock.c
371
tb2 = inet_bind2_bucket_find(head2, net, port, l3mdev, sk);
net/ipv4/inet_connection_sock.c
373
if (inet_bind_bucket_match(tb, net, port, l3mdev)) {
net/ipv4/inet_connection_sock.c
397
if (READ_ONCE(net->ipv4.sysctl_ip_autobind_reuse) && !relax) {
net/ipv4/inet_connection_sock.c
511
struct net *net = sock_net(sk);
net/ipv4/inet_connection_sock.c
526
head = &hinfo->bhash[inet_bhashfn(net, port,
net/ipv4/inet_connection_sock.c
530
if (inet_bind_bucket_match(tb, net, port, l3mdev))
net/ipv4/inet_connection_sock.c
535
tb = inet_bind_bucket_create(hinfo->bind_bucket_cachep, net,
net/ipv4/inet_connection_sock.c
555
head2 = inet_bhashfn_portaddr(hinfo, sk, net, port);
net/ipv4/inet_connection_sock.c
558
tb2 = inet_bind2_bucket_find(head2, net, port, l3mdev, sk);
net/ipv4/inet_connection_sock.c
563
net, head2, tb, sk);
net/ipv4/inet_connection_sock.c
763
struct net *net = read_pnet(&ireq->ireq_net);
net/ipv4/inet_connection_sock.c
777
rt = ip_route_output_flow(net, fl4, sk);
net/ipv4/inet_connection_sock.c
789
__IP_INC_STATS(net, IPSTATS_MIB_OUTNOROUTES);
net/ipv4/inet_connection_sock.c
798
struct net *net = read_pnet(&ireq->ireq_net);
net/ipv4/inet_connection_sock.c
814
rt = ip_route_output_flow(net, fl4, sk);
net/ipv4/inet_connection_sock.c
824
__IP_INC_STATS(net, IPSTATS_MIB_OUTNOROUTES);
net/ipv4/inet_diag.c
950
struct net *net = sock_net(skb->sk);
net/ipv4/inet_diag.c
962
return netlink_dump_start(net->diag_nlsk, skb, nlh, &c);
net/ipv4/inet_diag.c
971
struct net *net = sock_net(skb->sk);
net/ipv4/inet_diag.c
983
return netlink_dump_start(net->diag_nlsk, skb, h, &c);
net/ipv4/inet_fragment.c
187
int fqdir_init(struct fqdir **fqdirp, struct inet_frags *f, struct net *net)
net/ipv4/inet_fragment.c
195
fqdir->net = net;
net/ipv4/inet_hashtables.c
1051
struct net *net = sock_net(sk);
net/ipv4/inet_hashtables.c
1074
max_rand_step = READ_ONCE(net->ipv4.sysctl_ip_local_port_step_width);
net/ipv4/inet_hashtables.c
1117
if (inet_is_local_reserved_port(net, port))
net/ipv4/inet_hashtables.c
1119
head = &hinfo->bhash[inet_bhashfn(net, port,
net/ipv4/inet_hashtables.c
1123
if (!inet_bind_bucket_match(tb, net, port, l3mdev))
net/ipv4/inet_hashtables.c
1143
if (inet_bind_bucket_match(tb, net, port, l3mdev)) {
net/ipv4/inet_hashtables.c
1157
net, head, port, l3mdev);
net/ipv4/inet_hashtables.c
1183
head2 = inet_bhashfn_portaddr(hinfo, sk, net, port);
net/ipv4/inet_hashtables.c
1186
tb2 = inet_bind2_bucket_find(head2, net, port, l3mdev, sk);
net/ipv4/inet_hashtables.c
1188
tb2 = inet_bind2_bucket_create(hinfo->bind2_bucket_cachep, net,
net/ipv4/inet_hashtables.c
121
bool inet_bind_bucket_match(const struct inet_bind_bucket *tb, const struct net *net,
net/ipv4/inet_hashtables.c
1227
sock_prot_inuse_add(net, sk->sk_prot, -1);
net/ipv4/inet_hashtables.c
124
return net_eq(ib_net(tb), net) && tb->port == port &&
net/ipv4/inet_hashtables.c
1261
const struct net *net = sock_net(sk);
net/ipv4/inet_hashtables.c
1270
hash_port0 = inet_ehashfn(net, inet->inet_rcv_saddr, 0,
net/ipv4/inet_hashtables.c
129
struct net *net,
net/ipv4/inet_hashtables.c
134
write_pnet(&tb2->ib_net, net);
net/ipv4/inet_hashtables.c
157
struct net *net,
net/ipv4/inet_hashtables.c
165
inet_bind2_bucket_init(tb2, net, head, tb, sk);
net/ipv4/inet_hashtables.c
221
struct net *net = sock_net(sk);
net/ipv4/inet_hashtables.c
225
bhash = inet_bhashfn(net, inet_sk(sk)->inet_num, hashinfo->bhash_size);
net/ipv4/inet_hashtables.c
227
head2 = inet_bhashfn_portaddr(hashinfo, sk, net, inet_sk(sk)->inet_num);
net/ipv4/inet_hashtables.c
262
struct net *net = sock_net(sk);
net/ipv4/inet_hashtables.c
268
bhash = inet_bhashfn(net, port, table->bhash_size);
net/ipv4/inet_hashtables.c
270
head2 = inet_bhashfn_portaddr(table, child, net, port);
net/ipv4/inet_hashtables.c
290
if (inet_bind_bucket_match(tb, net, port, l3mdev))
net/ipv4/inet_hashtables.c
295
net, head, port, l3mdev);
net/ipv4/inet_hashtables.c
310
tb2 = inet_bind2_bucket_find(head2, net, port, l3mdev, child);
net/ipv4/inet_hashtables.c
313
net, head2, tb, child);
net/ipv4/inet_hashtables.c
352
static inline int compute_score(struct sock *sk, const struct net *net,
net/ipv4/inet_hashtables.c
358
if (net_eq(sock_net(sk), net) && READ_ONCE(sk->sk_num) == hnum &&
net/ipv4/inet_hashtables.c
363
if (!inet_sk_bound_dev_eq(net, sk->sk_bound_dev_if, dif, sdif))
net/ipv4/inet_hashtables.c
390
struct sock *inet_lookup_reuseport(const struct net *net, struct sock *sk,
net/ipv4/inet_hashtables.c
40
u32 inet_ehashfn(const struct net *net, const __be32 laddr,
net/ipv4/inet_hashtables.c
401
net, daddr, hnum, saddr, sport);
net/ipv4/inet_hashtables.c
416
static struct sock *inet_lhash2_lookup(const struct net *net,
net/ipv4/inet_hashtables.c
428
score = compute_score(sk, net, hnum, daddr, dif, sdif);
net/ipv4/inet_hashtables.c
430
result = inet_lookup_reuseport(net, sk, skb, doff,
net/ipv4/inet_hashtables.c
443
struct sock *inet_lookup_run_sk_lookup(const struct net *net,
net/ipv4/inet_hashtables.c
45
inet_ehash_secret + net_hash_mix(net));
net/ipv4/inet_hashtables.c
453
no_reuseport = bpf_sk_lookup_run_v4(net, protocol, saddr, sport,
net/ipv4/inet_hashtables.c
458
reuse_sk = inet_lookup_reuseport(net, sk, skb, doff, saddr, sport, daddr, hnum,
net/ipv4/inet_hashtables.c
465
struct sock *__inet_lookup_listener(const struct net *net,
net/ipv4/inet_hashtables.c
478
result = inet_lookup_run_sk_lookup(net, IPPROTO_TCP, skb, doff,
net/ipv4/inet_hashtables.c
485
hashinfo = net->ipv4.tcp_death_row.hashinfo;
net/ipv4/inet_hashtables.c
486
hash2 = ipv4_portaddr_hash(net, daddr, hnum);
net/ipv4/inet_hashtables.c
489
result = inet_lhash2_lookup(net, ilb2, skb, doff,
net/ipv4/inet_hashtables.c
496
hash2 = ipv4_portaddr_hash(net, htonl(INADDR_ANY), hnum);
net/ipv4/inet_hashtables.c
499
result = inet_lhash2_lookup(net, ilb2, skb, doff,
net/ipv4/inet_hashtables.c
530
struct sock *__inet_lookup_established(const struct net *net,
net/ipv4/inet_hashtables.c
543
hashinfo = net->ipv4.tcp_death_row.hashinfo;
net/ipv4/inet_hashtables.c
544
hash = inet_ehashfn(net, daddr, hnum, saddr, sport);
net/ipv4/inet_hashtables.c
552
if (likely(inet_match(net, sk, acookie, ports, dif, sdif))) {
net/ipv4/inet_hashtables.c
555
if (unlikely(!inet_match(net, sk, acookie,
net/ipv4/inet_hashtables.c
589
struct net *net = sock_net(sk);
net/ipv4/inet_hashtables.c
590
int sdif = l3mdev_master_ifindex_by_index(net, dif);
net/ipv4/inet_hashtables.c
602
!inet_match(net, sk2, acookie, ports, dif, sdif))
net/ipv4/inet_hashtables.c
618
if (likely(inet_match(net, sk2, acookie, ports, dif, sdif))) {
net/ipv4/inet_hashtables.c
638
__NET_INC_STATS(net, LINUX_MIB_TIMEWAITRECYCLED);
net/ipv4/inet_hashtables.c
675
struct net *net = sock_net(sk);
net/ipv4/inet_hashtables.c
684
if (unlikely(inet_match(net, esk, acookie,
net/ipv4/inet_hashtables.c
691
if (unlikely(inet6_match(net, esk,
net/ipv4/inet_hashtables.c
79
struct net *net,
net/ipv4/inet_hashtables.c
860
const struct net *net, unsigned short port,
net/ipv4/inet_hashtables.c
863
if (!net_eq(ib2_net(tb), net) || tb->port != port ||
net/ipv4/inet_hashtables.c
87
write_pnet(&tb->ib_net, net);
net/ipv4/inet_hashtables.c
870
bool inet_bind2_bucket_match_addr_any(const struct inet_bind2_bucket *tb, const struct net *net,
net/ipv4/inet_hashtables.c
873
if (!net_eq(ib2_net(tb), net) || tb->port != port ||
net/ipv4/inet_hashtables.c
893
inet_bind2_bucket_find(const struct inet_bind_hashbucket *head, const struct net *net,
net/ipv4/inet_hashtables.c
899
if (inet_bind2_bucket_match(bhash2, net, port, l3mdev, sk))
net/ipv4/inet_hashtables.c
906
inet_bhash2_addr_any_hashbucket(const struct sock *sk, const struct net *net, int port)
net/ipv4/inet_hashtables.c
913
hash = ipv6_portaddr_hash(net, &in6addr_any, port);
net/ipv4/inet_hashtables.c
916
hash = ipv4_portaddr_hash(net, 0, port);
net/ipv4/inet_hashtables.c
941
struct net *net = sock_net(sk);
net/ipv4/inet_hashtables.c
973
bhash = inet_bhashfn(net, port, hinfo->bhash_size);
net/ipv4/inet_hashtables.c
975
head2 = inet_bhashfn_portaddr(hinfo, sk, net, port);
net/ipv4/inet_hashtables.c
992
head2 = inet_bhashfn_portaddr(hinfo, sk, net, port);
net/ipv4/inet_hashtables.c
995
tb2 = inet_bind2_bucket_find(head2, net, port, l3mdev, sk);
net/ipv4/inet_hashtables.c
998
inet_bind2_bucket_init(tb2, net, head2, inet_csk(sk)->icsk_bind_hash, sk);
net/ipv4/ip_forward.c
111
net = dev_net(skb->dev);
net/ipv4/ip_forward.c
131
__IP_INC_STATS(net, IPSTATS_MIB_OUTFORWDATAGRAMS);
net/ipv4/ip_forward.c
136
IP_INC_STATS(net, IPSTATS_MIB_FRAGFAILS);
net/ipv4/ip_forward.c
159
if (READ_ONCE(net->ipv4.sysctl_ip_fwd_update_priority))
net/ipv4/ip_forward.c
163
net, NULL, skb, skb->dev, rt->dst.dev,
net/ipv4/ip_forward.c
175
__IP_INC_STATS(net, IPSTATS_MIB_INHDRERRORS);
net/ipv4/ip_forward.c
65
static int ip_forward_finish(struct net *net, struct sock *sk, struct sk_buff *skb)
net/ipv4/ip_forward.c
80
return dst_output(net, sk, skb);
net/ipv4/ip_forward.c
89
struct net *net;
net/ipv4/ip_fragment.c
129
struct net *net;
net/ipv4/ip_fragment.c
134
net = qp->q.fqdir->net;
net/ipv4/ip_fragment.c
151
__IP_INC_STATS(net, IPSTATS_MIB_REASMFAILS);
net/ipv4/ip_fragment.c
152
__IP_INC_STATS(net, IPSTATS_MIB_REASMTIMEOUT);
net/ipv4/ip_fragment.c
164
head->dev = dev_get_by_index_rcu(net, qp->iif);
net/ipv4/ip_fragment.c
199
static struct ipq *ip_find(struct net *net, struct iphdr *iph,
net/ipv4/ip_fragment.c
212
q = inet_frag_find(net->ipv4.fqdir, &key);
net/ipv4/ip_fragment.c
238
__IP_INC_STATS(qp->q.fqdir->net, IPSTATS_MIB_REASMFAILS);
net/ipv4/ip_fragment.c
262
struct net *net = qp->q.fqdir->net;
net/ipv4/ip_fragment.c
382
__IP_INC_STATS(net, IPSTATS_MIB_REASM_OVERLAPS);
net/ipv4/ip_fragment.c
385
__IP_INC_STATS(net, IPSTATS_MIB_REASMFAILS);
net/ipv4/ip_fragment.c
401
struct net *net = qp->q.fqdir->net;
net/ipv4/ip_fragment.c
452
__IP_INC_STATS(net, IPSTATS_MIB_REASMOKS);
net/ipv4/ip_fragment.c
465
__IP_INC_STATS(net, IPSTATS_MIB_REASMFAILS);
net/ipv4/ip_fragment.c
470
int ip_defrag(struct net *net, struct sk_buff *skb, u32 user)
net/ipv4/ip_fragment.c
476
__IP_INC_STATS(net, IPSTATS_MIB_REASMREQDS);
net/ipv4/ip_fragment.c
482
qp = ip_find(net, ip_hdr(skb), user, vif);
net/ipv4/ip_fragment.c
497
__IP_INC_STATS(net, IPSTATS_MIB_REASMFAILS);
net/ipv4/ip_fragment.c
503
struct sk_buff *ip_check_defrag(struct net *net, struct sk_buff *skb, u32 user)
net/ipv4/ip_fragment.c
536
if (ip_defrag(net, skb, user))
net/ipv4/ip_fragment.c
588
static int __net_init ip4_frags_ns_ctl_register(struct net *net)
net/ipv4/ip_fragment.c
594
if (!net_eq(net, &init_net)) {
net/ipv4/ip_fragment.c
600
table[0].data = &net->ipv4.fqdir->high_thresh;
net/ipv4/ip_fragment.c
601
table[0].extra1 = &net->ipv4.fqdir->low_thresh;
net/ipv4/ip_fragment.c
602
table[1].data = &net->ipv4.fqdir->low_thresh;
net/ipv4/ip_fragment.c
603
table[1].extra2 = &net->ipv4.fqdir->high_thresh;
net/ipv4/ip_fragment.c
604
table[2].data = &net->ipv4.fqdir->timeout;
net/ipv4/ip_fragment.c
605
table[3].data = &net->ipv4.fqdir->max_dist;
net/ipv4/ip_fragment.c
607
hdr = register_net_sysctl_sz(net, "net/ipv4", table,
net/ipv4/ip_fragment.c
612
net->ipv4.frags_hdr = hdr;
net/ipv4/ip_fragment.c
616
if (!net_eq(net, &init_net))
net/ipv4/ip_fragment.c
622
static void __net_exit ip4_frags_ns_ctl_unregister(struct net *net)
net/ipv4/ip_fragment.c
626
table = net->ipv4.frags_hdr->ctl_table_arg;
net/ipv4/ip_fragment.c
627
unregister_net_sysctl_table(net->ipv4.frags_hdr);
net/ipv4/ip_fragment.c
636
static int ip4_frags_ns_ctl_register(struct net *net)
net/ipv4/ip_fragment.c
641
static void ip4_frags_ns_ctl_unregister(struct net *net)
net/ipv4/ip_fragment.c
650
static int __net_init ipv4_frags_init_net(struct net *net)
net/ipv4/ip_fragment.c
654
res = fqdir_init(&net->ipv4.fqdir, &ip4_frags, net);
net/ipv4/ip_fragment.c
671
net->ipv4.fqdir->high_thresh = 4 * 1024 * 1024;
net/ipv4/ip_fragment.c
672
net->ipv4.fqdir->low_thresh = 3 * 1024 * 1024;
net/ipv4/ip_fragment.c
678
net->ipv4.fqdir->timeout = IP_FRAG_TIME;
net/ipv4/ip_fragment.c
680
net->ipv4.fqdir->max_dist = 64;
net/ipv4/ip_fragment.c
682
res = ip4_frags_ns_ctl_register(net);
net/ipv4/ip_fragment.c
684
fqdir_exit(net->ipv4.fqdir);
net/ipv4/ip_fragment.c
688
static void __net_exit ipv4_frags_pre_exit_net(struct net *net)
net/ipv4/ip_fragment.c
690
fqdir_pre_exit(net->ipv4.fqdir);
net/ipv4/ip_fragment.c
693
static void __net_exit ipv4_frags_exit_net(struct net *net)
net/ipv4/ip_fragment.c
695
ip4_frags_ns_ctl_unregister(net);
net/ipv4/ip_fragment.c
696
fqdir_exit(net->ipv4.fqdir);
net/ipv4/ip_fragment.c
87
struct net *net = q->fqdir->net;
net/ipv4/ip_fragment.c
94
p = inet_getpeer_v4(net->ipv4.peers, key->saddr, key->vif);
net/ipv4/ip_gre.c
1075
static int __net_init ipgre_init_net(struct net *net)
net/ipv4/ip_gre.c
1077
return ip_tunnel_init_net(net, ipgre_net_id, &ipgre_link_ops, NULL);
net/ipv4/ip_gre.c
1080
static void __net_exit ipgre_exit_rtnl(struct net *net,
net/ipv4/ip_gre.c
1083
ip_tunnel_delete_net(net, ipgre_net_id, &ipgre_link_ops, dev_to_kill);
net/ipv4/ip_gre.c
139
struct net *net = dev_net(skb->dev);
net/ipv4/ip_gre.c
1460
if (!rtnl_dev_link_net_capable(dev, t->net))
net/ipv4/ip_gre.c
147
itn = net_generic(net, gre_tap_net_id);
net/ipv4/ip_gre.c
1492
if (!rtnl_dev_link_net_capable(dev, t->net))
net/ipv4/ip_gre.c
150
itn = net_generic(net, erspan_net_id);
net/ipv4/ip_gre.c
152
itn = net_generic(net, ipgre_net_id);
net/ipv4/ip_gre.c
1719
struct net_device *gretap_fb_dev_create(struct net *net, const char *name,
net/ipv4/ip_gre.c
1722
struct rtnl_newlink_params params = { .src_net = net };
net/ipv4/ip_gre.c
1732
dev = rtnl_create_link(net, name, name_assign_type,
net/ipv4/ip_gre.c
1766
static int __net_init ipgre_tap_init_net(struct net *net)
net/ipv4/ip_gre.c
1768
return ip_tunnel_init_net(net, gre_tap_net_id, &ipgre_tap_ops, "gretap0");
net/ipv4/ip_gre.c
1771
static void __net_exit ipgre_tap_exit_rtnl(struct net *net,
net/ipv4/ip_gre.c
1774
ip_tunnel_delete_net(net, gre_tap_net_id, &ipgre_tap_ops, dev_to_kill);
net/ipv4/ip_gre.c
1784
static int __net_init erspan_init_net(struct net *net)
net/ipv4/ip_gre.c
1786
return ip_tunnel_init_net(net, erspan_net_id,
net/ipv4/ip_gre.c
1790
static void __net_exit erspan_exit_rtnl(struct net *net,
net/ipv4/ip_gre.c
1793
ip_tunnel_delete_net(net, erspan_net_id, &erspan_link_ops, dev_to_kill);
net/ipv4/ip_gre.c
270
struct net *net = dev_net(skb->dev);
net/ipv4/ip_gre.c
283
itn = net_generic(net, erspan_net_id);
net/ipv4/ip_gre.c
420
struct net *net = dev_net(skb->dev);
net/ipv4/ip_gre.c
425
itn = net_generic(net, gre_tap_net_id);
net/ipv4/ip_gre.c
427
itn = net_generic(net, ipgre_net_id);
net/ipv4/ip_gre.c
434
itn = net_generic(net, ipgre_net_id);
net/ipv4/ip_gre.c
953
rt = ip_route_output_key(t->net, &fl4);
net/ipv4/ip_gre.c
972
in_dev = inetdev_by_index(t->net, t->mlink);
net/ipv4/ip_input.c
156
struct net *net = dev_net(dev);
net/ipv4/ip_input.c
158
for (ra = rcu_dereference(net->ipv4.ra_chain); ra; ra = rcu_dereference(ra->next)) {
net/ipv4/ip_input.c
168
if (ip_defrag(net, skb, IP_DEFRAG_CALL_RA_CHAIN))
net/ipv4/ip_input.c
189
void ip_protocol_deliver_rcu(struct net *net, struct sk_buff *skb, int protocol)
net/ipv4/ip_input.c
213
__IP_INC_STATS(net, IPSTATS_MIB_INDELIVERS);
net/ipv4/ip_input.c
217
__IP_INC_STATS(net, IPSTATS_MIB_INUNKNOWNPROTOS);
net/ipv4/ip_input.c
223
__IP_INC_STATS(net, IPSTATS_MIB_INDELIVERS);
net/ipv4/ip_input.c
229
static int ip_local_deliver_finish(struct net *net, struct sock *sk, struct sk_buff *skb)
net/ipv4/ip_input.c
232
__IP_INC_STATS(net, IPSTATS_MIB_INDISCARDS);
net/ipv4/ip_input.c
241
ip_protocol_deliver_rcu(net, skb, ip_hdr(skb)->protocol);
net/ipv4/ip_input.c
255
struct net *net = dev_net(skb->dev);
net/ipv4/ip_input.c
258
if (ip_defrag(net, skb, IP_DEFRAG_LOCAL_DELIVER))
net/ipv4/ip_input.c
263
net, NULL, skb, skb->dev, NULL,
net/ipv4/ip_input.c
324
struct net *net = dev_net_rcu(skb->dev);
net/ipv4/ip_input.c
342
sk = __inet_lookup_established(net, iph->saddr, th->source,
net/ipv4/ip_input.c
361
static int ip_rcv_finish_core(struct net *net,
net/ipv4/ip_input.c
376
if (READ_ONCE(net->ipv4.sysctl_ip_early_demux) &&
net/ipv4/ip_input.c
382
if (READ_ONCE(net->ipv4.sysctl_tcp_early_demux)) {
net/ipv4/ip_input.c
390
if (READ_ONCE(net->ipv4.sysctl_udp_early_demux)) {
net/ipv4/ip_input.c
437
__IP_UPD_PO_STATS(net, IPSTATS_MIB_INMCAST, skb->len);
net/ipv4/ip_input.c
439
__IP_UPD_PO_STATS(net, IPSTATS_MIB_INBCAST, skb->len);
net/ipv4/ip_input.c
474
__NET_INC_STATS(net, LINUX_MIB_IPRPFILTER);
net/ipv4/ip_input.c
478
static int ip_rcv_finish(struct net *net, struct sock *sk, struct sk_buff *skb)
net/ipv4/ip_input.c
490
ret = ip_rcv_finish_core(net, skb, dev, NULL);
net/ipv4/ip_input.c
499
static struct sk_buff *ip_rcv_core(struct sk_buff *skb, struct net *net)
net/ipv4/ip_input.c
514
__IP_UPD_PO_STATS(net, IPSTATS_MIB_IN, skb->len);
net/ipv4/ip_input.c
518
__IP_INC_STATS(net, IPSTATS_MIB_INDISCARDS);
net/ipv4/ip_input.c
545
__IP_ADD_STATS(net,
net/ipv4/ip_input.c
560
__IP_INC_STATS(net, IPSTATS_MIB_INTRUNCATEDPKTS);
net/ipv4/ip_input.c
570
__IP_INC_STATS(net, IPSTATS_MIB_INDISCARDS);
net/ipv4/ip_input.c
589
__IP_INC_STATS(net, IPSTATS_MIB_CSUMERRORS);
net/ipv4/ip_input.c
593
__IP_INC_STATS(net, IPSTATS_MIB_INHDRERRORS);
net/ipv4/ip_input.c
606
struct net *net = dev_net(dev);
net/ipv4/ip_input.c
608
skb = ip_rcv_core(skb, net);
net/ipv4/ip_input.c
613
net, NULL, skb, dev, NULL,
net/ipv4/ip_input.c
627
static struct sk_buff *ip_extract_route_hint(const struct net *net,
net/ipv4/ip_input.c
632
if (fib4_has_custom_rules(net) ||
net/ipv4/ip_input.c
641
static void ip_list_rcv_finish(struct net *net, struct list_head *head)
net/ipv4/ip_input.c
658
if (ip_rcv_finish_core(net, skb, dev, hint) == NET_RX_DROP)
net/ipv4/ip_input.c
663
hint = ip_extract_route_hint(net, skb);
net/ipv4/ip_input.c
679
struct net *net)
net/ipv4/ip_input.c
681
NF_HOOK_LIST(NFPROTO_IPV4, NF_INET_PRE_ROUTING, net, NULL,
net/ipv4/ip_input.c
683
ip_list_rcv_finish(net, head);
net/ipv4/ip_input.c
691
struct net *curr_net = NULL;
net/ipv4/ip_input.c
697
struct net *net = dev_net(dev);
net/ipv4/ip_input.c
700
skb = ip_rcv_core(skb, net);
net/ipv4/ip_input.c
704
if (curr_dev != dev || curr_net != net) {
net/ipv4/ip_input.c
711
curr_net = net;
net/ipv4/ip_options.c
131
if (inet_addr_type(net, addr) != RTN_UNICAST) {
net/ipv4/ip_options.c
241
int __ip_options_compile(struct net *net,
net/ipv4/ip_options.c
387
if (inet_addr_type(net, addr) == RTN_UNICAST)
net/ipv4/ip_options.c
396
if (!skb && !ns_capable(net->user_ns, CAP_NET_RAW)) {
net/ipv4/ip_options.c
431
if ((!skb && !ns_capable(net->user_ns, CAP_NET_RAW)) || opt->cipso) {
net/ipv4/ip_options.c
444
if (!skb && !ns_capable(net->user_ns, CAP_NET_RAW)) {
net/ipv4/ip_options.c
465
int ip_options_compile(struct net *net,
net/ipv4/ip_options.c
471
ret = __ip_options_compile(net, opt, skb, &info);
net/ipv4/ip_options.c
512
int ip_options_get(struct net *net, struct ip_options_rcu **optp,
net/ipv4/ip_options.c
529
if (optlen && ip_options_compile(net, &opt->opt, NULL)) {
net/ipv4/ip_options.c
533
if (opt->opt.srr && !ns_capable(net->user_ns, CAP_NET_RAW)) {
net/ipv4/ip_options.c
77
int __ip_options_echo(struct net *net, struct ip_options *dopt,
net/ipv4/ip_output.c
102
int __ip_local_out(struct net *net, struct sock *sk, struct sk_buff *skb)
net/ipv4/ip_output.c
106
IP_INC_STATS(net, IPSTATS_MIB_OUTREQUESTS);
net/ipv4/ip_output.c
121
net, sk, skb, NULL, skb_dst_dev(skb),
net/ipv4/ip_output.c
125
int ip_local_out(struct net *net, struct sock *sk, struct sk_buff *skb)
net/ipv4/ip_output.c
129
err = __ip_local_out(net, sk, skb);
net/ipv4/ip_output.c
131
err = dst_output(net, sk, skb);
net/ipv4/ip_output.c
1402
struct net *net = sock_net(sk);
net/ipv4/ip_output.c
1462
ip_select_ident(net, skb, sk);
net/ipv4/ip_output.c
1494
icmp_out_count(net, icmp_type);
net/ipv4/ip_output.c
1502
int ip_send_skb(struct net *net, struct sk_buff *skb)
net/ipv4/ip_output.c
1506
err = ip_local_out(net, skb->sk, skb);
net/ipv4/ip_output.c
1511
IP_INC_STATS(net, IPSTATS_MIB_OUTDISCARDS);
net/ipv4/ip_output.c
157
struct net *net = sock_net(sk);
net/ipv4/ip_output.c
1612
struct net *net = sock_net(sk);
net/ipv4/ip_output.c
1617
if (__ip_options_echo(net, &replyopts->opt, skb, sopt))
net/ipv4/ip_output.c
1632
if (!oif && netif_index_is_l3_master(net, skb->skb_iif))
net/ipv4/ip_output.c
1636
IP4_REPLY_MARK(net, skb->mark) ?: sk->sk_mark,
net/ipv4/ip_output.c
1644
rt = ip_route_output_flow(net, &fl4, sk);
net/ipv4/ip_output.c
183
__ip_select_ident(net, iph, 1);
net/ipv4/ip_output.c
196
return ip_local_out(net, skb->sk, skb);
net/ipv4/ip_output.c
199
static int ip_finish_output2(struct net *net, struct sock *sk, struct sk_buff *skb)
net/ipv4/ip_output.c
209
IP_UPD_PO_STATS(net, IPSTATS_MIB_OUTMCAST, skb->len);
net/ipv4/ip_output.c
211
IP_UPD_PO_STATS(net, IPSTATS_MIB_OUTBCAST, skb->len);
net/ipv4/ip_output.c
214
IP_UPD_PO_STATS(net, IPSTATS_MIB_OUT, skb->len);
net/ipv4/ip_output.c
248
static int ip_finish_output_gso(struct net *net, struct sock *sk,
net/ipv4/ip_output.c
258
return ip_finish_output2(net, sk, skb);
net/ipv4/ip_output.c
287
err = ip_fragment(net, sk, segs, mtu, ip_finish_output2);
net/ipv4/ip_output.c
296
static int __ip_finish_output(struct net *net, struct sock *sk, struct sk_buff *skb)
net/ipv4/ip_output.c
304
return dst_output(net, sk, skb);
net/ipv4/ip_output.c
309
return ip_finish_output_gso(net, sk, skb, mtu);
net/ipv4/ip_output.c
312
return ip_fragment(net, sk, skb, mtu, ip_finish_output2);
net/ipv4/ip_output.c
314
return ip_finish_output2(net, sk, skb);
net/ipv4/ip_output.c
317
static int ip_finish_output(struct net *net, struct sock *sk, struct sk_buff *skb)
net/ipv4/ip_output.c
324
return __ip_finish_output(net, sk, skb);
net/ipv4/ip_output.c
326
return __ip_finish_output(net, sk, skb) ? : ret;
net/ipv4/ip_output.c
333
static int ip_mc_finish_output(struct net *net, struct sock *sk,
net/ipv4/ip_output.c
356
new_rt = rt_dst_clone(net->loopback_dev, skb_rtable(skb));
net/ipv4/ip_output.c
363
err = dev_loopback_xmit(net, sk, skb);
net/ipv4/ip_output.c
367
int ip_mc_output(struct net *net, struct sock *sk, struct sk_buff *skb)
net/ipv4/ip_output.c
401
net, sk, newskb, NULL, newskb->dev,
net/ipv4/ip_output.c
417
net, sk, newskb, NULL, newskb->dev,
net/ipv4/ip_output.c
422
net, sk, skb, NULL, skb->dev,
net/ipv4/ip_output.c
427
int ip_output(struct net *net, struct sock *sk, struct sk_buff *skb)
net/ipv4/ip_output.c
438
net, sk, skb, indev, dev,
net/ipv4/ip_output.c
466
struct net *net = sock_net(sk);
net/ipv4/ip_output.c
495
rt = ip_route_output_flow(net, fl4, sk);
net/ipv4/ip_output.c
526
ip_select_ident_segs(net, skb, sk,
net/ipv4/ip_output.c
533
res = ip_local_out(net, sk, skb);
net/ipv4/ip_output.c
539
IP_INC_STATS(net, IPSTATS_MIB_OUTNOROUTES);
net/ipv4/ip_output.c
575
static int ip_fragment(struct net *net, struct sock *sk, struct sk_buff *skb,
net/ipv4/ip_output.c
577
int (*output)(struct net *, struct sock *, struct sk_buff *))
net/ipv4/ip_output.c
582
return ip_do_fragment(net, sk, skb, output);
net/ipv4/ip_output.c
587
IP_INC_STATS(net, IPSTATS_MIB_FRAGFAILS);
net/ipv4/ip_output.c
594
return ip_do_fragment(net, sk, skb, output);
net/ipv4/ip_output.c
760
int ip_do_fragment(struct net *net, struct sock *sk, struct sk_buff *skb,
net/ipv4/ip_output.c
761
int (*output)(struct net *, struct sock *, struct sk_buff *))
net/ipv4/ip_output.c
858
err = output(net, sk, skb);
net/ipv4/ip_output.c
861
IP_INC_STATS(net, IPSTATS_MIB_FRAGCREATES);
net/ipv4/ip_output.c
869
IP_INC_STATS(net, IPSTATS_MIB_FRAGOKS);
net/ipv4/ip_output.c
875
IP_INC_STATS(net, IPSTATS_MIB_FRAGFAILS);
net/ipv4/ip_output.c
90
ip_fragment(struct net *net, struct sock *sk, struct sk_buff *skb,
net/ipv4/ip_output.c
914
err = output(net, sk, skb2);
net/ipv4/ip_output.c
918
IP_INC_STATS(net, IPSTATS_MIB_FRAGCREATES);
net/ipv4/ip_output.c
92
int (*output)(struct net *, struct sock *, struct sk_buff *));
net/ipv4/ip_output.c
921
IP_INC_STATS(net, IPSTATS_MIB_FRAGOKS);
net/ipv4/ip_output.c
926
IP_INC_STATS(net, IPSTATS_MIB_FRAGFAILS);
net/ipv4/ip_sockglue.c
1259
if (optlen > READ_ONCE(net->core.sysctl_optmem_max)) {
net/ipv4/ip_sockglue.c
1270
msf->imsf_numsrc > READ_ONCE(net->ipv4.sysctl_igmp_max_msf)) {
net/ipv4/ip_sockglue.c
247
struct net *net = sock_net(sk);
net/ipv4/ip_sockglue.c
283
err = ip_options_get(net, &ipc->opt,
net/ipv4/ip_sockglue.c
348
struct net *net = sock_net(sk);
net/ipv4/ip_sockglue.c
357
mutex_lock(&net->ipv4.ra_mutex);
net/ipv4/ip_sockglue.c
358
for (rap = &net->ipv4.ra_chain;
net/ipv4/ip_sockglue.c
360
lockdep_is_held(&net->ipv4.ra_mutex))) != NULL;
net/ipv4/ip_sockglue.c
364
mutex_unlock(&net->ipv4.ra_mutex);
net/ipv4/ip_sockglue.c
371
mutex_unlock(&net->ipv4.ra_mutex);
net/ipv4/ip_sockglue.c
386
mutex_unlock(&net->ipv4.ra_mutex);
net/ipv4/ip_sockglue.c
395
mutex_unlock(&net->ipv4.ra_mutex);
net/ipv4/ip_sockglue.c
84
static void ip_cmsg_recv_retopts(struct net *net, struct msghdr *msg,
net/ipv4/ip_sockglue.c
896
struct net *net = sock_net(sk);
net/ipv4/ip_sockglue.c
93
if (ip_options_echo(net, opt, skb)) {
net/ipv4/ip_tunnel.c
1100
itn = net_generic(tunnel->net, tunnel->ip_tnl_net_id);
net/ipv4/ip_tunnel.c
1109
struct net *ip_tunnel_get_link_net(const struct net_device *dev)
net/ipv4/ip_tunnel.c
1113
return READ_ONCE(tunnel->net);
net/ipv4/ip_tunnel.c
1125
int ip_tunnel_init_net(struct net *net, unsigned int ip_tnl_net_id,
net/ipv4/ip_tunnel.c
1128
struct ip_tunnel_net *itn = net_generic(net, ip_tnl_net_id);
net/ipv4/ip_tunnel.c
1136
if (!ops || !net_has_fallback_tunnels(net)) {
net/ipv4/ip_tunnel.c
1150
itn->fb_tunnel_dev = __ip_tunnel_create(net, ops, &parms);
net/ipv4/ip_tunnel.c
1166
void ip_tunnel_delete_net(struct net *net, unsigned int id,
net/ipv4/ip_tunnel.c
1170
struct ip_tunnel_net *itn = net_generic(net, id);
net/ipv4/ip_tunnel.c
1174
ASSERT_RTNL_NET(net);
net/ipv4/ip_tunnel.c
1176
for_each_netdev_safe(net, dev, aux)
net/ipv4/ip_tunnel.c
1189
if (!net_eq(dev_net(t->dev), net))
net/ipv4/ip_tunnel.c
1195
int ip_tunnel_newlink(struct net *net, struct net_device *dev,
net/ipv4/ip_tunnel.c
1205
itn = net_generic(net, nt->ip_tnl_net_id);
net/ipv4/ip_tunnel.c
1215
nt->net = net;
net/ipv4/ip_tunnel.c
1254
struct net *net = tunnel->net;
net/ipv4/ip_tunnel.c
1255
struct ip_tunnel_net *itn = net_generic(net, tunnel->ip_tnl_net_id);
net/ipv4/ip_tunnel.c
1321
struct net *net = tunnel->net;
net/ipv4/ip_tunnel.c
1324
itn = net_generic(net, tunnel->ip_tnl_net_id);
net/ipv4/ip_tunnel.c
233
static struct net_device *__ip_tunnel_create(struct net *net,
net/ipv4/ip_tunnel.c
260
dev_net_set(dev, net);
net/ipv4/ip_tunnel.c
266
tunnel->net = net;
net/ipv4/ip_tunnel.c
298
iph->tos & INET_DSCP_MASK, tunnel->net,
net/ipv4/ip_tunnel.c
300
rt = ip_route_output_key(tunnel->net, &fl4);
net/ipv4/ip_tunnel.c
313
tdev = __dev_get_by_index(tunnel->net, tunnel->parms.link);
net/ipv4/ip_tunnel.c
329
static struct ip_tunnel *ip_tunnel_create(struct net *net,
net/ipv4/ip_tunnel.c
339
dev = __ip_tunnel_create(net, itn->rtnl_link_ops, parms);
net/ipv4/ip_tunnel.c
436
skb_scrub_packet(skb, !net_eq(tunnel->net, dev_net(tunnel->dev)));
net/ipv4/ip_tunnel.c
601
tos & INET_DSCP_MASK, tunnel->net, 0, skb->mark,
net/ipv4/ip_tunnel.c
614
rt = ip_route_output_key(tunnel->net, &fl4);
net/ipv4/ip_tunnel.c
657
df, !net_eq(tunnel->net, dev_net(dev)), 0);
net/ipv4/ip_tunnel.c
765
tunnel->net, READ_ONCE(tunnel->parms.link),
net/ipv4/ip_tunnel.c
782
rt = ip_route_output_key(tunnel->net, &fl4);
net/ipv4/ip_tunnel.c
849
df, !net_eq(tunnel->net, dev_net(dev)), 0);
net/ipv4/ip_tunnel.c
902
struct net *net = t->net;
net/ipv4/ip_tunnel.c
903
struct ip_tunnel_net *itn = net_generic(net, t->ip_tnl_net_id);
net/ipv4/ip_tunnel.c
918
if (!ns_capable(net->user_ns, CAP_NET_ADMIN))
net/ipv4/ip_tunnel.c
933
t = ip_tunnel_create(net, itn, p);
net/ipv4/ip_tunnel.c
974
if (!ns_capable(net->user_ns, CAP_NET_ADMIN))
net/ipv4/ip_tunnel_core.c
56
struct net *net = dev_net(rt->dst.dev);
net/ipv4/ip_tunnel_core.c
682
static int ip_tun_build_state(struct net *net, struct nlattr *attr,
net/ipv4/ip_tunnel_core.c
95
__ip_select_ident(net, iph, skb_shinfo(skb)->gso_segs ?: 1);
net/ipv4/ip_tunnel_core.c
97
err = ip_local_out(net, sk, skb);
net/ipv4/ip_tunnel_core.c
976
static int ip6_tun_build_state(struct net *net, struct nlattr *attr,
net/ipv4/ip_vti.c
141
skb_scrub_packet(skb, !net_eq(tunnel->net, dev_net(skb->dev)));
net/ipv4/ip_vti.c
217
dst = xfrm_lookup_route(tunnel->net, dst, fl, NULL, 0);
net/ipv4/ip_vti.c
260
skb_scrub_packet(skb, !net_eq(tunnel->net, dev_net(dev)));
net/ipv4/ip_vti.c
264
err = dst_output(tunnel->net, skb->sk, skb);
net/ipv4/ip_vti.c
324
struct net *net = dev_net(skb->dev);
net/ipv4/ip_vti.c
327
struct ip_tunnel_net *itn = net_generic(net, vti_net_id);
net/ipv4/ip_vti.c
367
x = xfrm_state_lookup(net, mark, (const xfrm_address_t *)&iph->daddr,
net/ipv4/ip_vti.c
373
ipv4_update_pmtu(skb, net, info, 0, protocol);
net/ipv4/ip_vti.c
375
ipv4_redirect(skb, net, 0, protocol);
net/ipv4/ip_vti.c
512
static int __net_init vti_init_net(struct net *net)
net/ipv4/ip_vti.c
517
err = ip_tunnel_init_net(net, vti_net_id, &vti_link_ops, "ip_vti0");
net/ipv4/ip_vti.c
52
struct net *net = dev_net(skb->dev);
net/ipv4/ip_vti.c
520
itn = net_generic(net, vti_net_id);
net/ipv4/ip_vti.c
526
static void __net_exit vti_exit_rtnl(struct net *net,
net/ipv4/ip_vti.c
529
ip_tunnel_delete_net(net, vti_net_id, &vti_link_ops, dev_to_kill);
net/ipv4/ip_vti.c
53
struct ip_tunnel_net *itn = net_generic(net, vti_net_id);
net/ipv4/ip_vti.c
599
if (!rtnl_dev_link_net_capable(dev, t->net))
net/ipv4/ipcomp.c
100
struct net *net = xs_net(x);
net/ipv4/ipcomp.c
105
t = xfrm_state_lookup(net, mark, (xfrm_address_t *)&x->id.daddr.a4,
net/ipv4/ipcomp.c
24
struct net *net = dev_net(skb->dev);
net/ipv4/ipcomp.c
42
x = xfrm_state_lookup(net, skb->mark, (const xfrm_address_t *)&iph->daddr,
net/ipv4/ipcomp.c
48
ipv4_update_pmtu(skb, net, info, 0, IPPROTO_COMP);
net/ipv4/ipcomp.c
50
ipv4_redirect(skb, net, 0, IPPROTO_COMP);
net/ipv4/ipcomp.c
60
struct net *net = xs_net(x);
net/ipv4/ipcomp.c
63
t = xfrm_state_alloc(net);
net/ipv4/ipip.c
130
struct net *net = dev_net(skb->dev);
net/ipv4/ipip.c
131
struct ip_tunnel_net *itn = net_generic(net, ipip_net_id);
net/ipv4/ipip.c
176
ipv4_update_pmtu(skb, net, info, t->parms.link, iph->protocol);
net/ipv4/ipip.c
181
ipv4_redirect(skb, net, t->parms.link, iph->protocol);
net/ipv4/ipip.c
217
struct net *net = dev_net(skb->dev);
net/ipv4/ipip.c
218
struct ip_tunnel_net *itn = net_generic(net, ipip_net_id);
net/ipv4/ipip.c
497
if (!rtnl_dev_link_net_capable(dev, t->net))
net/ipv4/ipip.c
630
static int __net_init ipip_init_net(struct net *net)
net/ipv4/ipip.c
632
return ip_tunnel_init_net(net, ipip_net_id, &ipip_link_ops, "tunl0");
net/ipv4/ipip.c
635
static void __net_exit ipip_exit_rtnl(struct net *net,
net/ipv4/ipip.c
638
ip_tunnel_delete_net(net, ipip_net_id, &ipip_link_ops, dev_to_kill);
net/ipv4/ipmr.c
1019
static void ipmr_cache_resolve(struct net *net, struct mr_table *mrt,
net/ipv4/ipmr.c
104
static struct mr_table *ipmr_new_table(struct net *net, u32 id);
net/ipv4/ipmr.c
1044
rtnl_unicast(skb, net, NETLINK_CB(skb).portid);
net/ipv4/ipmr.c
1047
ip_mr_forward(net, mrt, skb->dev, skb, c, 0);
net/ipv4/ipmr.c
108
static void ip_mr_forward(struct net *net, struct mr_table *mrt,
net/ipv4/ipmr.c
1145
struct net *net = read_pnet(&mrt->net);
net/ipv4/ipmr.c
1153
if (!check_net(net)) {
net/ipv4/ipmr.c
121
#define ipmr_for_each_table(mrt, net) \
net/ipv4/ipmr.c
122
list_for_each_entry_rcu(mrt, &net->ipv4.mr_tables, list, \
net/ipv4/ipmr.c
1223
struct net *net = read_pnet(&mrt->net);
net/ipv4/ipmr.c
1234
call_ipmr_mfc_entry_notifiers(net, FIB_EVENT_ENTRY_DEL, c, mrt->id);
net/ipv4/ipmr.c
124
list_empty(&net->ipv4.mr_tables))
net/ipv4/ipmr.c
1241
static int ipmr_mfc_add(struct net *net, struct mr_table *mrt,
net/ipv4/ipmr.c
126
static struct mr_table *ipmr_mr_table_iter(struct net *net,
net/ipv4/ipmr.c
1263
call_ipmr_mfc_entry_notifiers(net, FIB_EVENT_ENTRY_REPLACE, c,
net/ipv4/ipmr.c
1313
ipmr_cache_resolve(net, mrt, uc, c);
net/ipv4/ipmr.c
1316
call_ipmr_mfc_entry_notifiers(net, FIB_EVENT_ENTRY_ADD, c, mrt->id);
net/ipv4/ipmr.c
132
ret = list_entry_rcu(net->ipv4.mr_tables.next,
net/ipv4/ipmr.c
1325
struct net *net = read_pnet(&mrt->net);
net/ipv4/ipmr.c
1343
mutex_lock(&net->ipv4.mfc_mutex);
net/ipv4/ipmr.c
1352
call_ipmr_mfc_entry_notifiers(net, FIB_EVENT_ENTRY_DEL, cache,
net/ipv4/ipmr.c
1358
mutex_unlock(&net->ipv4.mfc_mutex);
net/ipv4/ipmr.c
1362
if (READ_ONCE(mrt->cache_resolve_queue_len) || !check_net(net)) {
net/ipv4/ipmr.c
138
if (&ret->list == &net->ipv4.mr_tables)
net/ipv4/ipmr.c
1380
struct net *net = sock_net(sk);
net/ipv4/ipmr.c
1386
ipmr_for_each_table(mrt, net) {
net/ipv4/ipmr.c
1388
IPV4_DEVCONF_ALL(net, MC_FORWARDING)--;
net/ipv4/ipmr.c
1389
inet_netconf_notify_devconf(net, RTM_NEWNETCONF,
net/ipv4/ipmr.c
1392
net->ipv4.devconf_all);
net/ipv4/ipmr.c
1413
struct net *net = sock_net(sk);
net/ipv4/ipmr.c
1429
mrt = __ipmr_get_table(net, raw_sk(sk)->ipmr_table ? : RT_TABLE_DEFAULT);
net/ipv4/ipmr.c
143
static struct mr_table *__ipmr_get_table(struct net *net, u32 id)
net/ipv4/ipmr.c
1436
!ns_capable(net->user_ns, CAP_NET_ADMIN)) {
net/ipv4/ipmr.c
1456
IPV4_DEVCONF_ALL(net, MC_FORWARDING)++;
net/ipv4/ipmr.c
1457
inet_netconf_notify_devconf(net, RTM_NEWNETCONF,
net/ipv4/ipmr.c
1460
net->ipv4.devconf_all);
net/ipv4/ipmr.c
147
ipmr_for_each_table(mrt, net) {
net/ipv4/ipmr.c
1491
ret = vif_add(net, mrt, &vif,
net/ipv4/ipmr.c
1517
mutex_lock(&net->ipv4.mfc_mutex);
net/ipv4/ipmr.c
1522
ret = ipmr_mfc_add(net, mrt, &mfc,
net/ipv4/ipmr.c
1526
mutex_unlock(&net->ipv4.mfc_mutex);
net/ipv4/ipmr.c
154
static int ipmr_fib_lookup(struct net *net, struct flowi4 *flp4,
net/ipv4/ipmr.c
1595
mrt = ipmr_new_table(net, uval);
net/ipv4/ipmr.c
1640
struct net *net = sock_net(sk);
net/ipv4/ipmr.c
1647
mrt = ipmr_get_table(net, raw_sk(sk)->ipmr_table ? : RT_TABLE_DEFAULT);
net/ipv4/ipmr.c
165
l3mdev_update_flow(net, flowi4_to_flowi(flp4));
net/ipv4/ipmr.c
167
err = fib_rules_lookup(net->ipv4.mr_rules_ops,
net/ipv4/ipmr.c
1686
struct net *net = sock_net(sk);
net/ipv4/ipmr.c
1691
mrt = ipmr_get_table(net, raw_sk(sk)->ipmr_table ? : RT_TABLE_DEFAULT);
net/ipv4/ipmr.c
1756
struct net *net = sock_net(sk);
net/ipv4/ipmr.c
1759
mrt = ipmr_get_table(net, raw_sk(sk)->ipmr_table ? : RT_TABLE_DEFAULT);
net/ipv4/ipmr.c
1812
struct net *net = dev_net(dev);
net/ipv4/ipmr.c
1820
ipmr_for_each_table(mrt, net) {
net/ipv4/ipmr.c
1838
static void ip_encap(struct net *net, struct sk_buff *skb,
net/ipv4/ipmr.c
1858
ip_select_ident(net, skb, NULL);
net/ipv4/ipmr.c
1865
static inline int ipmr_forward_finish(struct net *net, struct sock *sk,
net/ipv4/ipmr.c
1870
IP_INC_STATS(net, IPSTATS_MIB_OUTFORWDATAGRAMS);
net/ipv4/ipmr.c
1875
return dst_output(net, sk, skb);
net/ipv4/ipmr.c
1902
static int ipmr_prepare_xmit(struct net *net, struct mr_table *mrt,
net/ipv4/ipmr.c
1926
rt = ip_route_output_ports(net, &fl4, NULL,
net/ipv4/ipmr.c
1935
rt = ip_route_output_ports(net, &fl4, NULL, iph->daddr, 0,
net/ipv4/ipmr.c
1948
IP_INC_STATS(net, IPSTATS_MIB_FRAGFAILS);
net/ipv4/ipmr.c
1971
ip_encap(net, skb, vif->local, vif->remote);
net/ipv4/ipmr.c
1980
static void ipmr_queue_fwd_xmit(struct net *net, struct mr_table *mrt,
net/ipv4/ipmr.c
1988
if (ipmr_prepare_xmit(net, mrt, skb, vifi))
net/ipv4/ipmr.c
2006
net, NULL, skb, skb->dev, dst_dev_rcu(&rt->dst),
net/ipv4/ipmr.c
2014
static void ipmr_queue_output_xmit(struct net *net, struct mr_table *mrt,
net/ipv4/ipmr.c
2017
if (ipmr_prepare_xmit(net, mrt, skb, vifi))
net/ipv4/ipmr.c
2020
ip_mc_output(net, NULL, skb);
net/ipv4/ipmr.c
2041
static void ip_mr_forward(struct net *net, struct mr_table *mrt,
net/ipv4/ipmr.c
2137
ipmr_queue_fwd_xmit(net, mrt, true_vifi,
net/ipv4/ipmr.c
2149
ipmr_queue_fwd_xmit(net, mrt, true_vifi, skb2,
net/ipv4/ipmr.c
2152
ipmr_queue_fwd_xmit(net, mrt, true_vifi, skb, psend);
net/ipv4/ipmr.c
2162
static struct mr_table *ipmr_rt_fib_lookup(struct net *net, struct sk_buff *skb)
net/ipv4/ipmr.c
2180
err = ipmr_fib_lookup(net, &fl4, &mrt);
net/ipv4/ipmr.c
2192
struct net *net = dev_net(skb->dev);
net/ipv4/ipmr.c
2203
dev = dev_get_by_index_rcu(net, IPCB(skb)->iif);
net/ipv4/ipmr.c
2216
mrt = ipmr_rt_fib_lookup(net, skb);
net/ipv4/ipmr.c
2272
ip_mr_forward(net, mrt, dev, skb, cache, local);
net/ipv4/ipmr.c
2286
static void ip_mr_output_finish(struct net *net, struct mr_table *mrt,
net/ipv4/ipmr.c
2320
ipmr_queue_output_xmit(net, mrt,
net/ipv4/ipmr.c
2329
ipmr_queue_output_xmit(net, mrt, skb, psend);
net/ipv4/ipmr.c
2340
int ip_mr_output(struct net *net, struct sock *sk, struct sk_buff *skb)
net/ipv4/ipmr.c
2359
mrt = ipmr_rt_fib_lookup(net, skb);
net/ipv4/ipmr.c
2383
ip_mr_output_finish(net, mrt, dev, skb, cache);
net/ipv4/ipmr.c
2387
return ip_mc_output(net, sk, skb);
net/ipv4/ipmr.c
2395
struct net *net = dev_net(skb->dev);
net/ipv4/ipmr.c
2403
mrt = ipmr_rt_fib_lookup(net, skb);
net/ipv4/ipmr.c
242
static int __net_init ipmr_rules_init(struct net *net)
net/ipv4/ipmr.c
2422
struct net *net = dev_net(skb->dev);
net/ipv4/ipmr.c
2435
mrt = ipmr_rt_fib_lookup(net, skb);
net/ipv4/ipmr.c
2446
int ipmr_get_route(struct net *net, struct sk_buff *skb,
net/ipv4/ipmr.c
2455
mrt = __ipmr_get_table(net, RT_TABLE_DEFAULT);
net/ipv4/ipmr.c
249
ops = fib_rules_register(&ipmr_rules_ops_template, net);
net/ipv4/ipmr.c
253
INIT_LIST_HEAD(&net->ipv4.mr_tables);
net/ipv4/ipmr.c
255
mrt = ipmr_new_table(net, RT_TABLE_DEFAULT);
net/ipv4/ipmr.c
2582
struct net *net = read_pnet(&mrt->net);
net/ipv4/ipmr.c
2595
rtnl_notify(skb, net, 0, RTNLGRP_IPV4_MROUTE, NULL, GFP_ATOMIC);
net/ipv4/ipmr.c
2600
rtnl_set_sk_err(net, RTNLGRP_IPV4_MROUTE, err);
net/ipv4/ipmr.c
2621
struct net *net = read_pnet(&mrt->net);
net/ipv4/ipmr.c
265
net->ipv4.mr_rules_ops = ops;
net/ipv4/ipmr.c
2658
rtnl_notify(skb, net, 0, RTNLGRP_IPV4_MROUTE_R, NULL, GFP_ATOMIC);
net/ipv4/ipmr.c
2665
rtnl_set_sk_err(net, RTNLGRP_IPV4_MROUTE_R, -ENOBUFS);
net/ipv4/ipmr.c
2726
struct net *net = sock_net(in_skb->sk);
net/ipv4/ipmr.c
275
static void __net_exit ipmr_rules_exit(struct net *net)
net/ipv4/ipmr.c
2751
mrt = __ipmr_get_table(net, tableid ? tableid : RT_TABLE_DEFAULT);
net/ipv4/ipmr.c
277
fib_rules_unregister(net->ipv4.mr_rules_ops);
net/ipv4/ipmr.c
2771
err = rtnl_unicast(skb, net, NETLINK_CB(in_skb).portid);
net/ipv4/ipmr.c
280
static void __net_exit ipmr_rules_exit_rtnl(struct net *net,
net/ipv4/ipmr.c
285
list_for_each_entry_safe(mrt, next, &net->ipv4.mr_tables, list) {
net/ipv4/ipmr.c
2858
static int rtm_to_ipmr_mfcc(struct net *net, struct nlmsghdr *nlh,
net/ipv4/ipmr.c
291
static int ipmr_rules_dump(struct net *net, struct notifier_block *nb,
net/ipv4/ipmr.c
2914
mrt = __ipmr_get_table(net, tblid);
net/ipv4/ipmr.c
2921
dev = dev_get_by_index_rcu(net, iif);
net/ipv4/ipmr.c
294
return fib_rules_dump(net, nb, RTNL_FAMILY_IPMR, extack);
net/ipv4/ipmr.c
2943
struct net *net = sock_net(skb->sk);
net/ipv4/ipmr.c
2948
ret = rtm_to_ipmr_mfcc(net, nlh, &mfcc, &mrtsock, &tbl, extack);
net/ipv4/ipmr.c
2954
mutex_lock(&net->ipv4.mfc_mutex);
net/ipv4/ipmr.c
2957
ret = ipmr_mfc_add(net, tbl, &mfcc, mrtsock, parent);
net/ipv4/ipmr.c
2961
mutex_unlock(&net->ipv4.mfc_mutex);
net/ipv4/ipmr.c
297
static unsigned int ipmr_rules_seq_read(const struct net *net)
net/ipv4/ipmr.c
299
return fib_rules_seq_read(net, RTNL_FAMILY_IPMR);
net/ipv4/ipmr.c
3048
struct net *net = sock_net(skb->sk);
net/ipv4/ipmr.c
3066
ipmr_for_each_table(mrt, net) {
net/ipv4/ipmr.c
308
static struct mr_table *ipmr_mr_table_iter(struct net *net,
net/ipv4/ipmr.c
312
return rcu_dereference(net->ipv4.mrt);
net/ipv4/ipmr.c
3139
struct net *net = seq_file_net(seq);
net/ipv4/ipmr.c
3143
mrt = __ipmr_get_table(net, RT_TABLE_DEFAULT);
net/ipv4/ipmr.c
316
static struct mr_table *__ipmr_get_table(struct net *net, u32 id)
net/ipv4/ipmr.c
318
return rcu_dereference_check(net->ipv4.mrt,
net/ipv4/ipmr.c
3194
struct net *net = seq_file_net(seq);
net/ipv4/ipmr.c
3197
mrt = ipmr_get_table(net, RT_TABLE_DEFAULT);
net/ipv4/ipmr.c
320
!rcu_access_pointer(net->ipv4.mrt));
net/ipv4/ipmr.c
323
#define ipmr_for_each_table(mrt, net) \
net/ipv4/ipmr.c
324
for (mrt = __ipmr_get_table(net, 0); mrt; mrt = NULL)
net/ipv4/ipmr.c
3259
static unsigned int ipmr_seq_read(const struct net *net)
net/ipv4/ipmr.c
326
static int ipmr_fib_lookup(struct net *net, struct flowi4 *flp4,
net/ipv4/ipmr.c
3261
return atomic_read(&net->ipv4.ipmr_seq) + ipmr_rules_seq_read(net);
net/ipv4/ipmr.c
3264
static int ipmr_dump(struct net *net, struct notifier_block *nb,
net/ipv4/ipmr.c
3267
return mr_dump(net, nb, RTNL_FAMILY_IPMR, ipmr_rules_dump,
net/ipv4/ipmr.c
3278
static int __net_init ipmr_notifier_init(struct net *net)
net/ipv4/ipmr.c
3282
atomic_set(&net->ipv4.ipmr_seq, 0);
net/ipv4/ipmr.c
3284
ops = fib_notifier_ops_register(&ipmr_notifier_ops_template, net);
net/ipv4/ipmr.c
3287
net->ipv4.ipmr_notifier_ops = ops;
net/ipv4/ipmr.c
329
*mrt = rcu_dereference(net->ipv4.mrt);
net/ipv4/ipmr.c
3292
static void __net_exit ipmr_notifier_exit(struct net *net)
net/ipv4/ipmr.c
3294
fib_notifier_ops_unregister(net->ipv4.ipmr_notifier_ops);
net/ipv4/ipmr.c
3295
net->ipv4.ipmr_notifier_ops = NULL;
net/ipv4/ipmr.c
3299
static int __net_init ipmr_net_init(struct net *net)
net/ipv4/ipmr.c
3304
mutex_init(&net->ipv4.mfc_mutex);
net/ipv4/ipmr.c
3306
err = ipmr_notifier_init(net);
net/ipv4/ipmr.c
3310
err = ipmr_rules_init(net);
net/ipv4/ipmr.c
3316
if (!proc_create_net("ip_mr_vif", 0, net->proc_net, &ipmr_vif_seq_ops,
net/ipv4/ipmr.c
3319
if (!proc_create_net("ip_mr_cache", 0, net->proc_net, &ipmr_mfc_seq_ops,
net/ipv4/ipmr.c
3327
remove_proc_entry("ip_mr_vif", net->proc_net);
net/ipv4/ipmr.c
3329
ipmr_rules_exit_rtnl(net, &dev_kill_list);
net/ipv4/ipmr.c
3330
ipmr_rules_exit(net);
net/ipv4/ipmr.c
3333
ipmr_notifier_exit(net);
net/ipv4/ipmr.c
3338
static void __net_exit ipmr_net_exit(struct net *net)
net/ipv4/ipmr.c
3341
remove_proc_entry("ip_mr_cache", net->proc_net);
net/ipv4/ipmr.c
3342
remove_proc_entry("ip_mr_vif", net->proc_net);
net/ipv4/ipmr.c
3344
ipmr_rules_exit(net);
net/ipv4/ipmr.c
3345
ipmr_notifier_exit(net);
net/ipv4/ipmr.c
3348
static void __net_exit ipmr_net_exit_rtnl(struct net *net,
net/ipv4/ipmr.c
335
static int __net_init ipmr_rules_init(struct net *net)
net/ipv4/ipmr.c
3351
ipmr_rules_exit_rtnl(net, dev_kill_list);
net/ipv4/ipmr.c
339
mrt = ipmr_new_table(net, RT_TABLE_DEFAULT);
net/ipv4/ipmr.c
343
rcu_assign_pointer(net->ipv4.mrt, mrt);
net/ipv4/ipmr.c
347
static void __net_exit ipmr_rules_exit(struct net *net)
net/ipv4/ipmr.c
351
static void __net_exit ipmr_rules_exit_rtnl(struct net *net,
net/ipv4/ipmr.c
354
struct mr_table *mrt = rcu_dereference_protected(net->ipv4.mrt, 1);
net/ipv4/ipmr.c
356
RCU_INIT_POINTER(net->ipv4.mrt, NULL);
net/ipv4/ipmr.c
360
static int ipmr_rules_dump(struct net *net, struct notifier_block *nb,
net/ipv4/ipmr.c
366
static unsigned int ipmr_rules_seq_read(const struct net *net)
net/ipv4/ipmr.c
378
static struct mr_table *ipmr_get_table(struct net *net, u32 id)
net/ipv4/ipmr.c
383
mrt = __ipmr_get_table(net, id);
net/ipv4/ipmr.c
409
struct net *net)
net/ipv4/ipmr.c
412
list_add_tail_rcu(&mrt->list, &net->ipv4.mr_tables);
net/ipv4/ipmr.c
426
static struct mr_table *ipmr_new_table(struct net *net, u32 id)
net/ipv4/ipmr.c
434
mrt = __ipmr_get_table(net, id);
net/ipv4/ipmr.c
438
return mr_table_alloc(net, id, &ipmr_mr_table_ops,
net/ipv4/ipmr.c
444
struct net *net = read_pnet(&mrt->net);
net/ipv4/ipmr.c
447
WARN_ON_ONCE(!mr_can_free_table(net));
net/ipv4/ipmr.c
455
WARN_ON_ONCE(!net_initialized(net) && !list_empty(&ipmr_dev_kill_list));
net/ipv4/ipmr.c
478
static struct net_device *ipmr_new_tunnel(struct net *net, struct vifctl *v)
net/ipv4/ipmr.c
484
tunnel_dev = __dev_get_by_name(net, "tunl0");
net/ipv4/ipmr.c
502
new_dev = __dev_get_by_name(net, p.name);
net/ipv4/ipmr.c
531
struct net *net = dev_net(dev);
net/ipv4/ipmr.c
541
err = ipmr_fib_lookup(net, &fl4, &mrt);
net/ipv4/ipmr.c
580
static struct net_device *ipmr_reg_vif(struct net *net, struct mr_table *mrt)
net/ipv4/ipmr.c
595
dev_net_set(dev, net);
net/ipv4/ipmr.c
655
static struct net_device *ipmr_reg_vif(struct net *net, struct mr_table *mrt)
net/ipv4/ipmr.c
661
static int call_ipmr_vif_entry_notifiers(struct net *net,
net/ipv4/ipmr.c
667
return mr_call_vif_notifiers(net, RTNL_FAMILY_IPMR, event_type,
net/ipv4/ipmr.c
669
&net->ipv4.ipmr_seq);
net/ipv4/ipmr.c
672
static int call_ipmr_mfc_entry_notifiers(struct net *net,
net/ipv4/ipmr.c
676
return mr_call_mfc_notifiers(net, RTNL_FAMILY_IPMR, event_type,
net/ipv4/ipmr.c
677
&mfc->_c, tb_id, &net->ipv4.ipmr_seq);
net/ipv4/ipmr.c
690
struct net *net = read_pnet(&mrt->net);
net/ipv4/ipmr.c
705
call_ipmr_vif_entry_notifiers(net, FIB_EVENT_VIF_DEL, v, dev,
net/ipv4/ipmr.c
760
struct net *net = read_pnet(&mrt->net);
net/ipv4/ipmr.c
778
rtnl_unicast(skb, net, NETLINK_CB(skb).portid);
net/ipv4/ipmr.c
849
static int vif_add(struct net *net, struct mr_table *mrt,
net/ipv4/ipmr.c
872
dev = ipmr_reg_vif(net, mrt);
net/ipv4/ipmr.c
883
dev = ipmr_new_tunnel(net, vifc);
net/ipv4/ipmr.c
890
dev = dev_get_by_index(net, vifc->vifc_lcl_ifindex);
net/ipv4/ipmr.c
896
dev = ip_dev_find(net, vifc->vifc_lcl_addr.s_addr);
net/ipv4/ipmr.c
916
inet_netconf_notify_devconf(net, RTM_NEWNETCONF, NETCONFA_MC_FORWARDING,
net/ipv4/ipmr.c
948
call_ipmr_vif_entry_notifiers(net, FIB_EVENT_VIF_ADD, v, dev,
net/ipv4/ipmr_base.c
126
void *mr_vif_seq_idx(struct net *net, struct mr_vif_iter *iter, loff_t pos)
net/ipv4/ipmr_base.c
142
struct net *net = seq_file_net(seq);
net/ipv4/ipmr_base.c
147
return mr_vif_seq_idx(net, iter, 0);
net/ipv4/ipmr_base.c
157
void *mr_mfc_seq_idx(struct net *net,
net/ipv4/ipmr_base.c
185
struct net *net = seq_file_net(seq);
net/ipv4/ipmr_base.c
192
return mr_mfc_seq_idx(net, seq->private, 0);
net/ipv4/ipmr_base.c
358
struct mr_table *(*iter)(struct net *net,
net/ipv4/ipmr_base.c
367
struct net *net = sock_net(skb->sk);
net/ipv4/ipmr_base.c
381
for (mrt = iter(net, NULL); mrt; mrt = iter(net, mrt)) {
net/ipv4/ipmr_base.c
399
int mr_dump(struct net *net, struct notifier_block *nb, unsigned short family,
net/ipv4/ipmr_base.c
400
int (*rules_dump)(struct net *net,
net/ipv4/ipmr_base.c
403
struct mr_table *(*mr_iter)(struct net *net,
net/ipv4/ipmr_base.c
410
err = rules_dump(net, nb, extack);
net/ipv4/ipmr_base.c
414
for (mrt = mr_iter(net, NULL); mrt; mrt = mr_iter(net, mrt)) {
net/ipv4/ipmr_base.c
46
mr_table_alloc(struct net *net, u32 id,
net/ipv4/ipmr_base.c
50
struct net *net))
net/ipv4/ipmr_base.c
59
write_pnet(&mrt->net, net);
net/ipv4/ipmr_base.c
75
table_set(mrt, net);
net/ipv4/netfilter.c
22
int ip_route_me_harder(struct net *net, struct sock *sk, struct sk_buff *skb, unsigned int addr_type)
net/ipv4/netfilter.c
37
addr_type = inet_addr_type_dev_table(net, dev, saddr);
net/ipv4/netfilter.c
53
fib4_rules_early_flow_dissect(net, skb, &fl4, &flkeys);
net/ipv4/netfilter.c
54
rt = ip_route_output_key(net, &fl4);
net/ipv4/netfilter.c
67
xfrm_decode_session(net, skb, flowi4_to_flowi(&fl4), AF_INET) == 0) {
net/ipv4/netfilter.c
73
dst = xfrm_lookup(net, dst, flowi4_to_flowi(&fl4), sk, 0);
net/ipv4/netfilter.c
91
int nf_ip_route(struct net *net, struct dst_entry **dst, struct flowi *fl,
net/ipv4/netfilter.c
94
struct rtable *rt = ip_route_output_key(net, &fl->u.ip4);
net/ipv4/netfilter/arp_tables.c
1007
cleanup_entry(iter, net);
net/ipv4/netfilter/arp_tables.c
1013
static int do_add_counters(struct net *net, sockptr_t arg, unsigned int len)
net/ipv4/netfilter/arp_tables.c
1028
t = xt_find_table_lock(net, NFPROTO_ARP, tmp.name);
net/ipv4/netfilter/arp_tables.c
1169
static int translate_compat_table(struct net *net,
net/ipv4/netfilter/arp_tables.c
1240
ret = translate_table(net, newinfo, entry1, &repl);
net/ipv4/netfilter/arp_tables.c
1263
static int compat_do_replace(struct net *net, sockptr_t arg, unsigned int len)
net/ipv4/netfilter/arp_tables.c
1297
ret = translate_compat_table(net, &newinfo, &loc_cpu_entry, &tmp);
net/ipv4/netfilter/arp_tables.c
1301
ret = __do_replace(net, tmp.name, tmp.valid_hooks, newinfo,
net/ipv4/netfilter/arp_tables.c
1309
cleanup_entry(iter, net);
net/ipv4/netfilter/arp_tables.c
1382
static int compat_get_entries(struct net *net,
net/ipv4/netfilter/arp_tables.c
1400
t = xt_find_table_lock(net, NFPROTO_ARP, get.name);
net/ipv4/netfilter/arp_tables.c
1503
static void __arpt_unregister_table(struct net *net, struct xt_table *table)
net/ipv4/netfilter/arp_tables.c
1513
cleanup_entry(iter, net);
net/ipv4/netfilter/arp_tables.c
1520
int arpt_register_table(struct net *net,
net/ipv4/netfilter/arp_tables.c
1538
ret = translate_table(net, newinfo, loc_cpu_entry, repl);
net/ipv4/netfilter/arp_tables.c
1544
new_table = xt_register_table(net, table, template_ops, &bootstrap, newinfo);
net/ipv4/netfilter/arp_tables.c
1549
cleanup_entry(iter, net);
net/ipv4/netfilter/arp_tables.c
1557
void arpt_unregister_table(struct net *net, const char *name)
net/ipv4/netfilter/arp_tables.c
1559
struct xt_table *table = xt_unregister_table_exit(net, NFPROTO_ARP, name);
net/ipv4/netfilter/arp_tables.c
1562
__arpt_unregister_table(net, table);
net/ipv4/netfilter/arp_tables.c
1596
static int __net_init arp_tables_net_init(struct net *net)
net/ipv4/netfilter/arp_tables.c
1598
return xt_proto_init(net, NFPROTO_ARP);
net/ipv4/netfilter/arp_tables.c
1601
static void __net_exit arp_tables_net_exit(struct net *net)
net/ipv4/netfilter/arp_tables.c
1603
xt_proto_fini(net, NFPROTO_ARP);
net/ipv4/netfilter/arp_tables.c
400
static int check_target(struct arpt_entry *e, struct net *net, const char *name)
net/ipv4/netfilter/arp_tables.c
404
.net = net,
net/ipv4/netfilter/arp_tables.c
417
find_check_entry(struct arpt_entry *e, struct net *net, const char *name,
net/ipv4/netfilter/arp_tables.c
437
ret = check_target(e, net, name);
net/ipv4/netfilter/arp_tables.c
512
static void cleanup_entry(struct arpt_entry *e, struct net *net)
net/ipv4/netfilter/arp_tables.c
518
par.net = net;
net/ipv4/netfilter/arp_tables.c
531
static int translate_table(struct net *net,
net/ipv4/netfilter/arp_tables.c
590
ret = find_check_entry(iter, net, repl->name, repl->size,
net/ipv4/netfilter/arp_tables.c
601
cleanup_entry(iter, net);
net/ipv4/netfilter/arp_tables.c
801
static int get_info(struct net *net, void __user *user, const int *len)
net/ipv4/netfilter/arp_tables.c
818
t = xt_request_find_table_lock(net, NFPROTO_ARP, name);
net/ipv4/netfilter/arp_tables.c
856
static int get_entries(struct net *net, struct arpt_get_entries __user *uptr,
net/ipv4/netfilter/arp_tables.c
872
t = xt_find_table_lock(net, NFPROTO_ARP, get.name);
net/ipv4/netfilter/arp_tables.c
890
static int __do_replace(struct net *net, const char *name,
net/ipv4/netfilter/arp_tables.c
910
t = xt_request_find_table_lock(net, NFPROTO_ARP, name);
net/ipv4/netfilter/arp_tables.c
941
cleanup_entry(iter, net);
net/ipv4/netfilter/arp_tables.c
961
static int do_replace(struct net *net, sockptr_t arg, unsigned int len)
net/ipv4/netfilter/arp_tables.c
995
ret = translate_table(net, newinfo, loc_cpu_entry, &tmp);
net/ipv4/netfilter/arp_tables.c
999
ret = __do_replace(net, tmp.name, tmp.valid_hooks, newinfo,
net/ipv4/netfilter/arptable_filter.c
31
static int arptable_filter_table_init(struct net *net)
net/ipv4/netfilter/arptable_filter.c
39
err = arpt_register_table(net, &packet_filter, repl, arpfilter_ops);
net/ipv4/netfilter/arptable_filter.c
44
static void __net_exit arptable_filter_net_pre_exit(struct net *net)
net/ipv4/netfilter/arptable_filter.c
46
xt_unregister_table_pre_exit(net, NFPROTO_ARP, "filter");
net/ipv4/netfilter/arptable_filter.c
49
static void __net_exit arptable_filter_net_exit(struct net *net)
net/ipv4/netfilter/arptable_filter.c
51
arpt_unregister_table(net, "filter");
net/ipv4/netfilter/ip_tables.c
1001
get_entries(struct net *net, struct ipt_get_entries __user *uptr,
net/ipv4/netfilter/ip_tables.c
1016
t = xt_find_table_lock(net, AF_INET, get.name);
net/ipv4/netfilter/ip_tables.c
1034
__do_replace(struct net *net, const char *name, unsigned int valid_hooks,
net/ipv4/netfilter/ip_tables.c
1050
t = xt_request_find_table_lock(net, AF_INET, name);
net/ipv4/netfilter/ip_tables.c
1080
cleanup_entry(iter, net);
net/ipv4/netfilter/ip_tables.c
1101
do_replace(struct net *net, sockptr_t arg, unsigned int len)
net/ipv4/netfilter/ip_tables.c
1135
ret = translate_table(net, newinfo, loc_cpu_entry, &tmp);
net/ipv4/netfilter/ip_tables.c
1139
ret = __do_replace(net, tmp.name, tmp.valid_hooks, newinfo,
net/ipv4/netfilter/ip_tables.c
1147
cleanup_entry(iter, net);
net/ipv4/netfilter/ip_tables.c
1154
do_add_counters(struct net *net, sockptr_t arg, unsigned int len)
net/ipv4/netfilter/ip_tables.c
1169
t = xt_find_table_lock(net, AF_INET, tmp.name);
net/ipv4/netfilter/ip_tables.c
1388
translate_compat_table(struct net *net,
net/ipv4/netfilter/ip_tables.c
1464
ret = translate_table(net, newinfo, entry1, &repl);
net/ipv4/netfilter/ip_tables.c
1488
compat_do_replace(struct net *net, sockptr_t arg, unsigned int len)
net/ipv4/netfilter/ip_tables.c
1522
ret = translate_compat_table(net, &newinfo, &loc_cpu_entry, &tmp);
net/ipv4/netfilter/ip_tables.c
1526
ret = __do_replace(net, tmp.name, tmp.valid_hooks, newinfo,
net/ipv4/netfilter/ip_tables.c
1534
cleanup_entry(iter, net);
net/ipv4/netfilter/ip_tables.c
1576
compat_get_entries(struct net *net, struct compat_ipt_get_entries __user *uptr,
net/ipv4/netfilter/ip_tables.c
1595
t = xt_find_table_lock(net, AF_INET, get.name);
net/ipv4/netfilter/ip_tables.c
1706
static void __ipt_unregister_table(struct net *net, struct xt_table *table)
net/ipv4/netfilter/ip_tables.c
1716
cleanup_entry(iter, net);
net/ipv4/netfilter/ip_tables.c
1723
int ipt_register_table(struct net *net, const struct xt_table *table,
net/ipv4/netfilter/ip_tables.c
1740
ret = translate_table(net, newinfo, loc_cpu_entry, repl);
net/ipv4/netfilter/ip_tables.c
1746
new_table = xt_register_table(net, table, template_ops, &bootstrap, newinfo);
net/ipv4/netfilter/ip_tables.c
1751
cleanup_entry(iter, net);
net/ipv4/netfilter/ip_tables.c
1759
void ipt_unregister_table_exit(struct net *net, const char *name)
net/ipv4/netfilter/ip_tables.c
1761
struct xt_table *table = xt_unregister_table_exit(net, NFPROTO_IPV4, name);
net/ipv4/netfilter/ip_tables.c
1764
__ipt_unregister_table(net, table);
net/ipv4/netfilter/ip_tables.c
1797
static int __net_init ip_tables_net_init(struct net *net)
net/ipv4/netfilter/ip_tables.c
1799
return xt_proto_init(net, NFPROTO_IPV4);
net/ipv4/netfilter/ip_tables.c
1802
static void __net_exit ip_tables_net_exit(struct net *net)
net/ipv4/netfilter/ip_tables.c
1804
xt_proto_fini(net, NFPROTO_IPV4);
net/ipv4/netfilter/ip_tables.c
185
static void trace_packet(struct net *net,
net/ipv4/netfilter/ip_tables.c
209
nf_log_trace(net, AF_INET, hook, skb, in, out, &trace_loginfo,
net/ipv4/netfilter/ip_tables.c
306
trace_packet(state->net, skb, hook, state->in,
net/ipv4/netfilter/ip_tables.c
450
static void cleanup_match(struct xt_entry_match *m, struct net *net)
net/ipv4/netfilter/ip_tables.c
454
par.net = net;
net/ipv4/netfilter/ip_tables.c
497
static int check_target(struct ipt_entry *e, struct net *net, const char *name)
net/ipv4/netfilter/ip_tables.c
501
.net = net,
net/ipv4/netfilter/ip_tables.c
515
find_check_entry(struct ipt_entry *e, struct net *net, const char *name,
net/ipv4/netfilter/ip_tables.c
531
mtpar.net = net;
net/ipv4/netfilter/ip_tables.c
552
ret = check_target(e, net, name);
net/ipv4/netfilter/ip_tables.c
563
cleanup_match(ematch, net);
net/ipv4/netfilter/ip_tables.c
636
cleanup_entry(struct ipt_entry *e, struct net *net)
net/ipv4/netfilter/ip_tables.c
644
cleanup_match(ematch, net);
net/ipv4/netfilter/ip_tables.c
647
par.net = net;
net/ipv4/netfilter/ip_tables.c
660
translate_table(struct net *net, struct xt_table_info *newinfo, void *entry0,
net/ipv4/netfilter/ip_tables.c
716
ret = find_check_entry(iter, net, repl->name, repl->size,
net/ipv4/netfilter/ip_tables.c
727
cleanup_entry(iter, net);
net/ipv4/netfilter/ip_tables.c
944
static int get_info(struct net *net, void __user *user, const int *len)
net/ipv4/netfilter/ip_tables.c
961
t = xt_request_find_table_lock(net, AF_INET, name);
net/ipv4/netfilter/ipt_SYNPROXY.c
16
struct net *net = xt_net(par);
net/ipv4/netfilter/ipt_SYNPROXY.c
17
struct synproxy_net *snet = synproxy_pernet(net);
net/ipv4/netfilter/ipt_SYNPROXY.c
48
synproxy_send_client_synack(net, skb, th, &opts);
net/ipv4/netfilter/ipt_SYNPROXY.c
53
if (synproxy_recv_client_ack(net, skb, th, &opts, ntohl(th->seq))) {
net/ipv4/netfilter/ipt_SYNPROXY.c
66
struct synproxy_net *snet = synproxy_pernet(par->net);
net/ipv4/netfilter/ipt_SYNPROXY.c
74
err = nf_ct_netns_get(par->net, par->family);
net/ipv4/netfilter/ipt_SYNPROXY.c
78
err = nf_synproxy_ipv4_init(snet, par->net);
net/ipv4/netfilter/ipt_SYNPROXY.c
80
nf_ct_netns_put(par->net, par->family);
net/ipv4/netfilter/ipt_SYNPROXY.c
89
struct synproxy_net *snet = synproxy_pernet(par->net);
net/ipv4/netfilter/ipt_SYNPROXY.c
91
nf_synproxy_ipv4_fini(snet, par->net);
net/ipv4/netfilter/ipt_SYNPROXY.c
92
nf_ct_netns_put(par->net, par->family);
net/ipv4/netfilter/ipt_rpfilter.c
33
static bool rpfilter_lookup_reverse(struct net *net, struct flowi4 *fl4,
net/ipv4/netfilter/ipt_rpfilter.c
38
if (fib_lookup(net, fl4, &res, FIB_LOOKUP_IGNORE_LINKSTATE))
net/ipv4/netfilter/iptable_filter.c
37
static int iptable_filter_table_init(struct net *net)
net/ipv4/netfilter/iptable_filter.c
49
err = ipt_register_table(net, &packet_filter, repl, filter_ops);
net/ipv4/netfilter/iptable_filter.c
54
static int __net_init iptable_filter_net_init(struct net *net)
net/ipv4/netfilter/iptable_filter.c
57
return iptable_filter_table_init(net);
net/ipv4/netfilter/iptable_filter.c
62
static void __net_exit iptable_filter_net_pre_exit(struct net *net)
net/ipv4/netfilter/iptable_filter.c
64
xt_unregister_table_pre_exit(net, NFPROTO_IPV4, "filter");
net/ipv4/netfilter/iptable_filter.c
67
static void __net_exit iptable_filter_net_exit(struct net *net)
net/ipv4/netfilter/iptable_filter.c
69
ipt_unregister_table_exit(net, "filter");
net/ipv4/netfilter/iptable_mangle.c
102
static void __net_exit iptable_mangle_net_exit(struct net *net)
net/ipv4/netfilter/iptable_mangle.c
104
ipt_unregister_table_exit(net, "mangle");
net/ipv4/netfilter/iptable_mangle.c
63
err = ip_route_me_harder(state->net, state->sk, skb, RTN_UNSPEC);
net/ipv4/netfilter/iptable_mangle.c
84
static int iptable_mangle_table_init(struct net *net)
net/ipv4/netfilter/iptable_mangle.c
92
ret = ipt_register_table(net, &packet_mangler, repl, mangle_ops);
net/ipv4/netfilter/iptable_mangle.c
97
static void __net_exit iptable_mangle_net_pre_exit(struct net *net)
net/ipv4/netfilter/iptable_mangle.c
99
xt_unregister_table_pre_exit(net, NFPROTO_IPV4, "mangle");
net/ipv4/netfilter/iptable_nat.c
101
nf_nat_ipv4_unregister_fn(net, &ops[i]);
net/ipv4/netfilter/iptable_nat.c
106
static int iptable_nat_table_init(struct net *net)
net/ipv4/netfilter/iptable_nat.c
115
ret = ipt_register_table(net, &nf_nat_ipv4_table, repl, NULL);
net/ipv4/netfilter/iptable_nat.c
121
ret = ipt_nat_register_lookups(net);
net/ipv4/netfilter/iptable_nat.c
123
xt_unregister_table_pre_exit(net, NFPROTO_IPV4, "nat");
net/ipv4/netfilter/iptable_nat.c
125
ipt_unregister_table_exit(net, "nat");
net/ipv4/netfilter/iptable_nat.c
132
static void __net_exit iptable_nat_net_pre_exit(struct net *net)
net/ipv4/netfilter/iptable_nat.c
134
ipt_nat_unregister_lookups(net);
net/ipv4/netfilter/iptable_nat.c
135
xt_unregister_table_pre_exit(net, NFPROTO_IPV4, "nat");
net/ipv4/netfilter/iptable_nat.c
138
static void __net_exit iptable_nat_net_exit(struct net *net)
net/ipv4/netfilter/iptable_nat.c
140
ipt_unregister_table_exit(net, "nat");
net/ipv4/netfilter/iptable_nat.c
59
static int ipt_nat_register_lookups(struct net *net)
net/ipv4/netfilter/iptable_nat.c
66
xt_nat_net = net_generic(net, iptable_nat_net_id);
net/ipv4/netfilter/iptable_nat.c
67
table = xt_find_table(net, NFPROTO_IPV4, "nat");
net/ipv4/netfilter/iptable_nat.c
77
ret = nf_nat_ipv4_register_fn(net, &ops[i]);
net/ipv4/netfilter/iptable_nat.c
80
nf_nat_ipv4_unregister_fn(net, &ops[--i]);
net/ipv4/netfilter/iptable_nat.c
91
static void ipt_nat_unregister_lookups(struct net *net)
net/ipv4/netfilter/iptable_nat.c
93
struct iptable_nat_pernet *xt_nat_net = net_generic(net, iptable_nat_net_id);
net/ipv4/netfilter/iptable_raw.c
37
static int iptable_raw_table_init(struct net *net)
net/ipv4/netfilter/iptable_raw.c
49
ret = ipt_register_table(net, table, repl, rawtable_ops);
net/ipv4/netfilter/iptable_raw.c
54
static void __net_exit iptable_raw_net_pre_exit(struct net *net)
net/ipv4/netfilter/iptable_raw.c
56
xt_unregister_table_pre_exit(net, NFPROTO_IPV4, "raw");
net/ipv4/netfilter/iptable_raw.c
59
static void __net_exit iptable_raw_net_exit(struct net *net)
net/ipv4/netfilter/iptable_raw.c
61
ipt_unregister_table_exit(net, "raw");
net/ipv4/netfilter/iptable_security.c
38
static int iptable_security_table_init(struct net *net)
net/ipv4/netfilter/iptable_security.c
46
ret = ipt_register_table(net, &security_table, repl, sectbl_ops);
net/ipv4/netfilter/iptable_security.c
51
static void __net_exit iptable_security_net_pre_exit(struct net *net)
net/ipv4/netfilter/iptable_security.c
53
xt_unregister_table_pre_exit(net, NFPROTO_IPV4, "security");
net/ipv4/netfilter/iptable_security.c
56
static void __net_exit iptable_security_net_exit(struct net *net)
net/ipv4/netfilter/iptable_security.c
58
ipt_unregister_table_exit(net, "security");
net/ipv4/netfilter/nf_defrag_ipv4.c
108
static void __net_exit defrag4_net_exit(struct net *net)
net/ipv4/netfilter/nf_defrag_ipv4.c
110
if (net->nf.defrag_ipv4_users) {
net/ipv4/netfilter/nf_defrag_ipv4.c
111
nf_unregister_net_hooks(net, ipv4_defrag_ops,
net/ipv4/netfilter/nf_defrag_ipv4.c
113
net->nf.defrag_ipv4_users = 0;
net/ipv4/netfilter/nf_defrag_ipv4.c
145
int nf_defrag_ipv4_enable(struct net *net)
net/ipv4/netfilter/nf_defrag_ipv4.c
150
if (net->nf.defrag_ipv4_users == UINT_MAX) {
net/ipv4/netfilter/nf_defrag_ipv4.c
155
if (net->nf.defrag_ipv4_users) {
net/ipv4/netfilter/nf_defrag_ipv4.c
156
net->nf.defrag_ipv4_users++;
net/ipv4/netfilter/nf_defrag_ipv4.c
160
err = nf_register_net_hooks(net, ipv4_defrag_ops,
net/ipv4/netfilter/nf_defrag_ipv4.c
163
net->nf.defrag_ipv4_users = 1;
net/ipv4/netfilter/nf_defrag_ipv4.c
171
void nf_defrag_ipv4_disable(struct net *net)
net/ipv4/netfilter/nf_defrag_ipv4.c
174
if (net->nf.defrag_ipv4_users) {
net/ipv4/netfilter/nf_defrag_ipv4.c
175
net->nf.defrag_ipv4_users--;
net/ipv4/netfilter/nf_defrag_ipv4.c
176
if (net->nf.defrag_ipv4_users == 0)
net/ipv4/netfilter/nf_defrag_ipv4.c
177
nf_unregister_net_hooks(net, ipv4_defrag_ops,
net/ipv4/netfilter/nf_defrag_ipv4.c
26
static int nf_ct_ipv4_gather_frags(struct net *net, struct sk_buff *skb,
net/ipv4/netfilter/nf_defrag_ipv4.c
32
err = ip_defrag(net, skb, user);
net/ipv4/netfilter/nf_defrag_ipv4.c
87
if (nf_ct_ipv4_gather_frags(state->net, skb, user))
net/ipv4/netfilter/nf_dup_ipv4.c
24
static bool nf_dup_ipv4_route(struct net *net, struct sk_buff *skb,
net/ipv4/netfilter/nf_dup_ipv4.c
39
rt = ip_route_output_key(net, &fl4);
net/ipv4/netfilter/nf_dup_ipv4.c
51
void nf_dup_ipv4(struct net *net, struct sk_buff *skb, unsigned int hooknum,
net/ipv4/netfilter/nf_dup_ipv4.c
88
if (nf_dup_ipv4_route(net, skb, gw, oif)) {
net/ipv4/netfilter/nf_dup_ipv4.c
90
ip_local_out(net, skb->sk, skb);
net/ipv4/netfilter/nf_nat_pptp.c
46
struct net *net = nf_ct_net(ct);
net/ipv4/netfilter/nf_nat_pptp.c
87
other_exp = nf_ct_expect_find_get(net, nf_ct_zone(ct), &t);
net/ipv4/netfilter/nf_reject_ipv4.c
104
struct sk_buff *nf_reject_skb_v4_unreach(struct net *net,
net/ipv4/netfilter/nf_reject_ipv4.c
154
READ_ONCE(net->ipv4.sysctl_ip_default_ttl));
net/ipv4/netfilter/nf_reject_ipv4.c
271
void nf_send_reset(struct net *net, struct sock *sk, struct sk_buff *oldskb,
net/ipv4/netfilter/nf_reject_ipv4.c
296
nskb->mark = IP4_REPLY_MARK(net, oldskb->mark);
net/ipv4/netfilter/nf_reject_ipv4.c
302
if (ip_route_me_harder(net, sk, nskb, RTN_UNSPEC))
net/ipv4/netfilter/nf_reject_ipv4.c
324
br_indev = nf_bridge_get_physindev(oldskb, net);
net/ipv4/netfilter/nf_reject_ipv4.c
337
ip_local_out(net, nskb->sk, nskb);
net/ipv4/netfilter/nf_reject_ipv4.c
48
struct sk_buff *nf_reject_skb_v4_tcp_reset(struct net *net,
net/ipv4/netfilter/nf_reject_ipv4.c
74
READ_ONCE(net->ipv4.sysctl_ip_default_ttl));
net/ipv4/netfilter/nf_socket_ipv4.c
148
return nf_socket_get_sock_v4(net, data_skb, doff, protocol, saddr,
net/ipv4/netfilter/nf_socket_ipv4.c
66
nf_socket_get_sock_v4(struct net *net, struct sk_buff *skb, const int doff,
net/ipv4/netfilter/nf_socket_ipv4.c
74
return inet_lookup(net, skb, doff, saddr, sport, daddr, dport,
net/ipv4/netfilter/nf_socket_ipv4.c
77
return udp4_lib_lookup(net, saddr, sport, daddr, dport,
net/ipv4/netfilter/nf_socket_ipv4.c
83
struct sock *nf_sk_lookup_slow_v4(struct net *net, const struct sk_buff *skb,
net/ipv4/netfilter/nf_tproxy_ipv4.c
111
sk = inet_lookup_established(net, saddr, sport,
net/ipv4/netfilter/nf_tproxy_ipv4.c
120
sk = udp4_lib_lookup(net, saddr, sport, daddr, dport,
net/ipv4/netfilter/nf_tproxy_ipv4.c
19
nf_tproxy_handle_time_wait4(struct net *net, struct sk_buff *skb,
net/ipv4/netfilter/nf_tproxy_ipv4.c
36
sk2 = nf_tproxy_get_sock_v4(net, skb, iph->protocol,
net/ipv4/netfilter/nf_tproxy_ipv4.c
77
nf_tproxy_get_sock_v4(struct net *net, struct sk_buff *skb,
net/ipv4/netfilter/nf_tproxy_ipv4.c
97
sk = inet_lookup_listener(net, skb,
net/ipv4/nexthop.c
1222
rtnl_notify(skb, nh->net, 0, RTNLGRP_NEXTHOP, NULL, GFP_KERNEL);
net/ipv4/nexthop.c
1225
rtnl_set_sk_err(nh->net, RTNLGRP_NEXTHOP, err);
net/ipv4/nexthop.c
1282
static int nh_check_attr_group(struct net *net,
net/ipv4/nexthop.c
1341
static int nh_check_attr_group_rtnl(struct net *net, struct nlattr *tb[],
net/ipv4/nexthop.c
1358
nh = nexthop_find_by_id(net, nhg[i].id);
net/ipv4/nexthop.c
1810
err = call_nexthop_res_bucket_notifiers(res_table->net,
net/ipv4/nexthop.c
2020
remove_nh_grp_entry(struct net *net, struct nh_grp_entry *nhge,
net/ipv4/nexthop.c
2037
return remove_nexthop(net, nhp, nlinfo);
net/ipv4/nexthop.c
2086
err = call_nexthop_notifiers(net, NEXTHOP_EVENT_REPLACE, nhp,
net/ipv4/nexthop.c
2099
remove_nexthop_from_groups(struct net *net, struct nexthop *nh,
net/ipv4/nexthop.c
2113
need_flush |= remove_nh_grp_entry(net, nhge, nlinfo,
net/ipv4/nexthop.c
2150
static bool __must_check __remove_nexthop_fib(struct net *net,
net/ipv4/nexthop.c
2171
ip6_del_rt(net, f6i,
net/ipv4/nexthop.c
2172
!READ_ONCE(net->ipv4.sysctl_nexthop_compat_mode));
net/ipv4/nexthop.c
2182
static bool __must_check __remove_nexthop(struct net *net, struct nexthop *nh,
net/ipv4/nexthop.c
2185
bool need_flush = __remove_nexthop_fib(net, nh);
net/ipv4/nexthop.c
2196
need_flush |= remove_nexthop_from_groups(net, nh, nlinfo);
net/ipv4/nexthop.c
2202
static bool __must_check remove_nexthop(struct net *net, struct nexthop *nh,
net/ipv4/nexthop.c
2207
call_nexthop_notifiers(net, NEXTHOP_EVENT_DEL, nh, NULL);
net/ipv4/nexthop.c
2210
rb_erase(&nh->rb_node, &net->nexthop.rb_root);
net/ipv4/nexthop.c
2215
need_flush = __remove_nexthop(net, nh, nlinfo);
net/ipv4/nexthop.c
2216
nh_base_seq_inc(net);
net/ipv4/nexthop.c
2223
static void remove_one_nexthop(struct net *net, struct nexthop *nh,
net/ipv4/nexthop.c
2226
if (remove_nexthop(net, nh, nlinfo))
net/ipv4/nexthop.c
2227
fib_flush(net);
net/ipv4/nexthop.c
2233
static void nh_rt_cache_flush(struct net *net, struct nexthop *nh,
net/ipv4/nexthop.c
2241
rt_cache_flush(net);
net/ipv4/nexthop.c
2245
fib6_update_sernum_upto_root(net, f6i);
net/ipv4/nexthop.c
2265
static int replace_nexthop_grp(struct net *net, struct nexthop *old,
net/ipv4/nexthop.c
2289
err = call_nexthop_notifiers(net, NEXTHOP_EVENT_REPLACE, new,
net/ipv4/nexthop.c
23
static bool __must_check remove_nexthop(struct net *net, struct nexthop *nh,
net/ipv4/nexthop.c
2313
err = call_nexthop_res_table_notifiers(net, new, extack);
net/ipv4/nexthop.c
236
static int call_nexthop_notifiers(struct net *net,
net/ipv4/nexthop.c
2369
static int replace_nexthop_single_notify_res(struct net *net,
net/ipv4/nexthop.c
2386
err = __call_nexthop_res_bucket_notifiers(net, nhg_id,
net/ipv4/nexthop.c
2404
__call_nexthop_res_bucket_notifiers(net, nhg_id, i,
net/ipv4/nexthop.c
2411
static int replace_nexthop_single_notify(struct net *net,
net/ipv4/nexthop.c
242
.net = net,
net/ipv4/nexthop.c
2422
return call_nexthop_notifiers(net, NEXTHOP_EVENT_REPLACE,
net/ipv4/nexthop.c
2426
return replace_nexthop_single_notify_res(net, res_table,
net/ipv4/nexthop.c
2434
static int replace_nexthop_single(struct net *net, struct nexthop *old,
net/ipv4/nexthop.c
2455
err = call_nexthop_notifiers(net, NEXTHOP_EVENT_REPLACE, new, extack);
net/ipv4/nexthop.c
2483
err = replace_nexthop_single_notify(net, nhp, old, oldi, newi,
net/ipv4/nexthop.c
249
if (nexthop_notifiers_is_empty(net))
net/ipv4/nexthop.c
2514
replace_nexthop_single_notify(net, nhp, old, newi, oldi, NULL);
net/ipv4/nexthop.c
2516
call_nexthop_notifiers(net, NEXTHOP_EVENT_REPLACE, old, extack);
net/ipv4/nexthop.c
2520
static void __nexthop_replace_notify(struct net *net, struct nexthop *nh,
net/ipv4/nexthop.c
2535
fib_info_notify_update(net, info);
net/ipv4/nexthop.c
2542
fib6_rt_update(net, f6i, info);
net/ipv4/nexthop.c
2549
static void nexthop_replace_notify(struct net *net, struct nexthop *nh,
net/ipv4/nexthop.c
2554
__nexthop_replace_notify(net, nh, info);
net/ipv4/nexthop.c
2557
__nexthop_replace_notify(net, nhge->nh_parent, info);
net/ipv4/nexthop.c
2560
static int replace_nexthop(struct net *net, struct nexthop *old,
net/ipv4/nexthop.c
258
err = blocking_notifier_call_chain(&net->nexthop.notifier_chain,
net/ipv4/nexthop.c
2605
err = replace_nexthop_grp(net, old, new, cfg, extack);
net/ipv4/nexthop.c
2607
err = replace_nexthop_single(net, old, new, extack);
net/ipv4/nexthop.c
2610
nh_rt_cache_flush(net, old, new);
net/ipv4/nexthop.c
2612
WARN_ON_ONCE(__remove_nexthop(net, new, NULL));
net/ipv4/nexthop.c
2620
static int insert_nexthop(struct net *net, struct nexthop *new_nh,
net/ipv4/nexthop.c
2624
struct rb_root *root = &net->nexthop.rb_root;
net/ipv4/nexthop.c
2647
rc = replace_nexthop(net, nh, new_nh, cfg, extack);
net/ipv4/nexthop.c
2696
rc = call_nexthop_notifiers(net, NEXTHOP_EVENT_REPLACE, new_nh, extack);
net/ipv4/nexthop.c
2698
rb_erase(&new_nh->rb_node, &net->nexthop.rb_root);
net/ipv4/nexthop.c
2702
nh_base_seq_inc(net);
net/ipv4/nexthop.c
2705
READ_ONCE(net->ipv4.sysctl_nexthop_compat_mode))
net/ipv4/nexthop.c
2706
nexthop_replace_notify(net, new_nh, &cfg->nlinfo);
net/ipv4/nexthop.c
2717
struct net *net = dev_net(dev);
net/ipv4/nexthop.c
2718
struct hlist_head *head = &net->nexthop.devhash[hash];
net/ipv4/nexthop.c
2731
need_flush |= remove_nexthop(net, nhi->nh_parent, NULL);
net/ipv4/nexthop.c
2735
fib_flush(net);
net/ipv4/nexthop.c
2739
static void flush_all_nexthops(struct net *net)
net/ipv4/nexthop.c
2741
struct rb_root *root = &net->nexthop.rb_root;
net/ipv4/nexthop.c
2748
need_flush |= remove_nexthop(net, nh, NULL);
net/ipv4/nexthop.c
2752
fib_flush(net);
net/ipv4/nexthop.c
2755
static struct nexthop *nexthop_create_group(struct net *net,
net/ipv4/nexthop.c
2791
nhe = nexthop_find_by_id(net, entry[i].id);
net/ipv4/nexthop.c
2821
res_table = nexthop_res_table_alloc(net, cfg->nh_id, cfg);
net/ipv4/nexthop.c
2862
static int nh_create_ipv4(struct net *net, struct nexthop *nh,
net/ipv4/nexthop.c
2879
err = fib_nh_init(net, fib_nh, &fib_cfg, 1, extack);
net/ipv4/nexthop.c
2881
fib_nh_release(net, fib_nh);
net/ipv4/nexthop.c
2889
err = fib_check_nh(net, fib_nh, tb_id, 0, extack);
net/ipv4/nexthop.c
2892
fib_info_update_nhc_saddr(net, &fib_nh->nh_common,
net/ipv4/nexthop.c
2895
fib_nh_release(net, fib_nh);
net/ipv4/nexthop.c
290
nh = nexthop_find_by_id(info->net, info->id);
net/ipv4/nexthop.c
2901
static int nh_create_ipv6(struct net *net, struct nexthop *nh,
net/ipv4/nexthop.c
2922
err = fib6_nh_init(net, fib6_nh, &fib6_cfg, GFP_KERNEL, extack);
net/ipv4/nexthop.c
2935
static struct nexthop *nexthop_create(struct net *net, struct nh_config *cfg,
net/ipv4/nexthop.c
2953
nh->net = net;
net/ipv4/nexthop.c
2964
cfg->nh_ifindex = net->loopback_dev->ifindex;
net/ipv4/nexthop.c
2969
err = nh_create_ipv4(net, nh, nhi, cfg, extack);
net/ipv4/nexthop.c
2972
err = nh_create_ipv6(net, nh, nhi, cfg, extack);
net/ipv4/nexthop.c
2984
nexthop_devhash_add(net, nhi);
net/ipv4/nexthop.c
2992
static struct nexthop *nexthop_add(struct net *net, struct nh_config *cfg,
net/ipv4/nexthop.c
2999
cfg->nh_id = nh_find_unused_id(net);
net/ipv4/nexthop.c
3007
nh = nexthop_create_group(net, cfg);
net/ipv4/nexthop.c
3009
nh = nexthop_create(net, cfg, extack);
net/ipv4/nexthop.c
3017
nh->net = net;
net/ipv4/nexthop.c
3019
err = insert_nexthop(net, nh, cfg, extack);
net/ipv4/nexthop.c
3021
WARN_ON_ONCE(__remove_nexthop(net, nh, NULL));
net/ipv4/nexthop.c
3093
static int rtm_to_nh_config(struct net *net, struct sk_buff *skb,
net/ipv4/nexthop.c
3128
cfg->nlinfo.nl_net = net;
net/ipv4/nexthop.c
3166
err = nh_check_attr_group(net, tb, ARRAY_SIZE(rtm_nh_policy_new),
net/ipv4/nexthop.c
3260
static int rtm_to_nh_config_rtnl(struct net *net, struct nlattr **tb,
net/ipv4/nexthop.c
3265
return nh_check_attr_group_rtnl(net, tb, extack);
net/ipv4/nexthop.c
3270
cfg->dev = __dev_get_by_index(net, cfg->nh_ifindex);
net/ipv4/nexthop.c
3296
struct net *net = sock_net(skb->sk);
net/ipv4/nexthop.c
3307
err = rtm_to_nh_config(net, skb, nlh, tb, &cfg, extack);
net/ipv4/nexthop.c
3317
rtnl_net_lock(net);
net/ipv4/nexthop.c
3319
err = rtm_to_nh_config_rtnl(net, tb, &cfg, extack);
net/ipv4/nexthop.c
3323
nh = nexthop_add(net, &cfg, extack);
net/ipv4/nexthop.c
3328
rtnl_net_unlock(net);
net/ipv4/nexthop.c
3366
struct net *net = sock_net(skb->sk);
net/ipv4/nexthop.c
3369
.nl_net = net,
net/ipv4/nexthop.c
337
static int __call_nexthop_res_bucket_notifiers(struct net *net, u32 nhg_id,
net/ipv4/nexthop.c
3386
rtnl_net_lock(net);
net/ipv4/nexthop.c
3388
nh = nexthop_find_by_id(net, id);
net/ipv4/nexthop.c
3390
remove_one_nexthop(net, nh, &nlinfo);
net/ipv4/nexthop.c
3394
rtnl_net_unlock(net);
net/ipv4/nexthop.c
3404
struct net *net = sock_net(in_skb->sk);
net/ipv4/nexthop.c
3422
nh = nexthop_find_by_id(net, id);
net/ipv4/nexthop.c
3438
err = rtnl_unicast(skb, net, NETLINK_CB(in_skb).portid);
net/ipv4/nexthop.c
344
.net = net,
net/ipv4/nexthop.c
350
if (nexthop_notifiers_is_empty(net))
net/ipv4/nexthop.c
358
err = blocking_notifier_call_chain(&net->nexthop.notifier_chain,
net/ipv4/nexthop.c
3637
struct net *net = sock_net(skb->sk);
net/ipv4/nexthop.c
3638
struct rb_root *root = &net->nexthop.rb_root;
net/ipv4/nexthop.c
3649
cb->seq = net->nexthop.seq;
net/ipv4/nexthop.c
3655
nexthop_find_group_resilient(struct net *net, u32 id,
net/ipv4/nexthop.c
3661
nh = nexthop_find_by_id(net, id);
net/ipv4/nexthop.c
3821
struct net *net = sock_net(skb->sk);
net/ipv4/nexthop.c
3830
nh = nexthop_find_group_resilient(net, dd.filter.nh_id,
net/ipv4/nexthop.c
3836
struct rb_root *root = &net->nexthop.rb_root;
net/ipv4/nexthop.c
3842
cb->seq = net->nexthop.seq;
net/ipv4/nexthop.c
389
static int call_nexthop_res_bucket_notifiers(struct net *net, u32 nhg_id,
net/ipv4/nexthop.c
3902
struct net *net = sock_net(in_skb->sk);
net/ipv4/nexthop.c
3915
nh = nexthop_find_group_resilient(net, id, extack);
net/ipv4/nexthop.c
3939
return rtnl_unicast(skb, net, NETLINK_CB(in_skb).portid);
net/ipv4/nexthop.c
3949
struct net *net = dev_net(dev);
net/ipv4/nexthop.c
3950
struct hlist_head *head = &net->nexthop.devhash[hash];
net/ipv4/nexthop.c
398
return __call_nexthop_res_bucket_notifiers(net, nhg_id, bucket_index,
net/ipv4/nexthop.c
3992
static int nexthops_dump(struct net *net, struct notifier_block *nb,
net/ipv4/nexthop.c
3996
struct rb_root *root = &net->nexthop.rb_root;
net/ipv4/nexthop.c
4004
err = call_nexthop_notifier(nb, net, event_type, nh, extack);
net/ipv4/nexthop.c
4012
int register_nexthop_notifier(struct net *net, struct notifier_block *nb,
net/ipv4/nexthop.c
4018
err = nexthops_dump(net, nb, NEXTHOP_EVENT_REPLACE, extack);
net/ipv4/nexthop.c
402
static int call_nexthop_res_table_notifiers(struct net *net, struct nexthop *nh,
net/ipv4/nexthop.c
4021
err = blocking_notifier_chain_register(&net->nexthop.notifier_chain,
net/ipv4/nexthop.c
4029
int __unregister_nexthop_notifier(struct net *net, struct notifier_block *nb)
net/ipv4/nexthop.c
4033
err = blocking_notifier_chain_unregister(&net->nexthop.notifier_chain,
net/ipv4/nexthop.c
4036
nexthops_dump(net, nb, NEXTHOP_EVENT_DEL, NULL);
net/ipv4/nexthop.c
4041
int unregister_nexthop_notifier(struct net *net, struct notifier_block *nb)
net/ipv4/nexthop.c
4046
err = __unregister_nexthop_notifier(net, nb);
net/ipv4/nexthop.c
4052
void nexthop_set_hw_flags(struct net *net, u32 id, bool offload, bool trap)
net/ipv4/nexthop.c
4058
nexthop = nexthop_find_by_id(net, id);
net/ipv4/nexthop.c
406
.net = net,
net/ipv4/nexthop.c
4073
void nexthop_bucket_set_hw_flags(struct net *net, u32 id, u16 bucket_index,
net/ipv4/nexthop.c
4083
nexthop = nexthop_find_by_id(net, id);
net/ipv4/nexthop.c
4107
void nexthop_res_grp_activity_update(struct net *net, u32 id, u16 num_buckets,
net/ipv4/nexthop.c
4117
nexthop = nexthop_find_by_id(net, id);
net/ipv4/nexthop.c
4142
static void __net_exit nexthop_net_exit_rtnl(struct net *net,
net/ipv4/nexthop.c
4145
ASSERT_RTNL_NET(net);
net/ipv4/nexthop.c
4146
flush_all_nexthops(net);
net/ipv4/nexthop.c
4149
static void __net_exit nexthop_net_exit(struct net *net)
net/ipv4/nexthop.c
415
if (nexthop_notifiers_is_empty(net))
net/ipv4/nexthop.c
4151
kfree(net->nexthop.devhash);
net/ipv4/nexthop.c
4152
net->nexthop.devhash = NULL;
net/ipv4/nexthop.c
4155
static int __net_init nexthop_net_init(struct net *net)
net/ipv4/nexthop.c
4159
net->nexthop.rb_root = RB_ROOT;
net/ipv4/nexthop.c
4160
net->nexthop.devhash = kzalloc(sz, GFP_KERNEL);
net/ipv4/nexthop.c
4161
if (!net->nexthop.devhash)
net/ipv4/nexthop.c
4163
BLOCKING_INIT_NOTIFIER_HEAD(&net->nexthop.notifier_chain);
net/ipv4/nexthop.c
429
err = blocking_notifier_call_chain(&net->nexthop.notifier_chain,
net/ipv4/nexthop.c
437
static int call_nexthop_notifier(struct notifier_block *nb, struct net *net,
net/ipv4/nexthop.c
443
.net = net,
net/ipv4/nexthop.c
467
static void nexthop_devhash_add(struct net *net, struct nh_info *nhi)
net/ipv4/nexthop.c
476
head = &net->nexthop.devhash[hash];
net/ipv4/nexthop.c
510
fib_nh_release(nh->net, &nhi->fib_nh);
net/ipv4/nexthop.c
561
nexthop_res_table_alloc(struct net *net, u32 nhg_id, struct nh_config *cfg)
net/ipv4/nexthop.c
572
res_table->net = net;
net/ipv4/nexthop.c
582
static void nh_base_seq_inc(struct net *net)
net/ipv4/nexthop.c
584
while (++net->nexthop.seq == 0)
net/ipv4/nexthop.c
589
struct nexthop *nexthop_find_by_id(struct net *net, u32 id)
net/ipv4/nexthop.c
593
pp = &net->nexthop.rb_root.rb_node;
net/ipv4/nexthop.c
615
static u32 nh_find_unused_id(struct net *net)
net/ipv4/nexthop.c
617
u32 id_start = net->nexthop.last_id_allocated;
net/ipv4/nexthop.c
620
net->nexthop.last_id_allocated++;
net/ipv4/nexthop.c
621
if (net->nexthop.last_id_allocated == id_start)
net/ipv4/nexthop.c
624
if (!nexthop_find_by_id(net, net->nexthop.last_id_allocated))
net/ipv4/nexthop.c
625
return net->nexthop.last_id_allocated;
net/ipv4/nexthop.c
764
.net = nh->net,
net/ipv4/nexthop.c
766
struct net *net = nh->net;
net/ipv4/nexthop.c
769
if (nexthop_notifiers_is_empty(net)) {
net/ipv4/nexthop.c
778
err = blocking_notifier_call_chain(&net->nexthop.notifier_chain,
net/ipv4/nexthop.c
91
static bool nexthop_notifiers_is_empty(struct net *net)
net/ipv4/nexthop.c
93
return !net->nexthop.notifier_chain.head;
net/ipv4/ping.c
1006
struct net *net = seq_file_net(seq);
net/ipv4/ping.c
101
net->ipv4.ping_port_rover = ident = result;
net/ipv4/ping.c
1018
if (net_eq(sock_net(sk), net) &&
net/ipv4/ping.c
1031
struct net *net = seq_file_net(seq);
net/ipv4/ping.c
1035
} while (sk && (!net_eq(sock_net(sk), net)));
net/ipv4/ping.c
109
hlist = ping_hashslot(&ping_table, net, ident);
net/ipv4/ping.c
111
if (!net_eq(sock_net(sk2), net))
net/ipv4/ping.c
1132
static int __net_init ping_v4_proc_init_net(struct net *net)
net/ipv4/ping.c
1134
if (!proc_create_net("icmp", 0444, net->proc_net, &ping_v4_seq_ops,
net/ipv4/ping.c
1138
net->ipv4.ping_port_rover = get_random_u16();
net/ipv4/ping.c
1142
static void __net_exit ping_v4_proc_exit_net(struct net *net)
net/ipv4/ping.c
1144
remove_proc_entry("icmp", net->proc_net);
net/ipv4/ping.c
132
sock_prot_inuse_add(net, sk->sk_prot, 1);
net/ipv4/ping.c
157
static struct sock *ping_lookup(struct net *net, struct sk_buff *skb, u16 ident)
net/ipv4/ping.c
159
struct hlist_head *hslot = ping_hashslot(&ping_table, net, ident);
net/ipv4/ping.c
183
if (!net_eq(sock_net(sk), net))
net/ipv4/ping.c
233
static void inet_get_ping_group_range_net(struct net *net, kgid_t *low,
net/ipv4/ping.c
236
kgid_t *data = net->ipv4.ping_group_range.range;
net/ipv4/ping.c
240
seq = read_seqbegin(&net->ipv4.ping_group_range.lock);
net/ipv4/ping.c
244
} while (read_seqretry(&net->ipv4.ping_group_range.lock, seq));
net/ipv4/ping.c
250
struct net *net = sock_net(sk);
net/ipv4/ping.c
260
inet_get_ping_group_range_net(net, &low, &high);
net/ipv4/ping.c
305
struct net *net = sock_net(sk);
net/ipv4/ping.c
325
tb_id = l3mdev_fib_table_by_index(net, sk->sk_bound_dev_if) ? : tb_id;
net/ipv4/ping.c
326
chk_addr_ret = inet_addr_type_table(net, addr->sin_addr.s_addr, tb_id);
net/ipv4/ping.c
331
!inet_can_nonlocal_bind(net, isk)))
net/ipv4/ping.c
358
dev = dev_get_by_index_rcu(net, addr->sin6_scope_id);
net/ipv4/ping.c
366
dev = dev_get_by_index_rcu(net, sk->sk_bound_dev_if);
net/ipv4/ping.c
372
has_addr = pingv6_ops.ipv6_chk_addr(net, &addr->sin6_addr, dev,
net/ipv4/ping.c
376
if (!(ipv6_can_nonlocal_bind(net, isk) || has_addr ||
net/ipv4/ping.c
491
struct net *net = dev_net(skb->dev);
net/ipv4/ping.c
519
sk = ping_lookup(net, skb, ntohs(icmph->un.echo.id));
net/ipv4/ping.c
60
static inline u32 ping_hashfn(const struct net *net, u32 num, u32 mask)
net/ipv4/ping.c
62
u32 res = (num + net_hash_mix(net)) & mask;
net/ipv4/ping.c
69
struct net *net, unsigned int num)
net/ipv4/ping.c
692
struct net *net = sock_net(sk);
net/ipv4/ping.c
71
return &table->hash[ping_hashfn(net, num, PING_HTABLE_MASK)];
net/ipv4/ping.c
76
struct net *net = sock_net(sk);
net/ipv4/ping.c
783
rt = ip_route_output_flow(net, &fl4, sk);
net/ipv4/ping.c
788
IP_INC_STATS(net, IPSTATS_MIB_OUTNOROUTES);
net/ipv4/ping.c
84
u16 result = net->ipv4.ping_port_rover + 1;
net/ipv4/ping.c
90
hlist = ping_hashslot(&ping_table, net, result);
net/ipv4/ping.c
92
if (!net_eq(sock_net(sk2), net))
net/ipv4/ping.c
959
struct net *net = dev_net(skb->dev);
net/ipv4/ping.c
971
sk = ping_lookup(net, skb, ntohs(icmph->un.echo.id));
net/ipv4/proc.c
331
struct net *net = seq->private;
net/ipv4/proc.c
335
val = atomic_long_read(&net->mib.icmpmsg_statistics->mibs[i]);
net/ipv4/proc.c
353
struct net *net = seq->private;
net/ipv4/proc.c
354
atomic_long_t *ptr = net->mib.icmpmsg_statistics->mibs;
net/ipv4/proc.c
363
snmp_fold_field(net->mib.icmp_statistics, ICMP_MIB_INMSGS),
net/ipv4/proc.c
364
snmp_fold_field(net->mib.icmp_statistics, ICMP_MIB_INERRORS),
net/ipv4/proc.c
365
snmp_fold_field(net->mib.icmp_statistics, ICMP_MIB_CSUMERRORS));
net/ipv4/proc.c
370
snmp_fold_field(net->mib.icmp_statistics, ICMP_MIB_OUTMSGS),
net/ipv4/proc.c
371
snmp_fold_field(net->mib.icmp_statistics, ICMP_MIB_OUTERRORS),
net/ipv4/proc.c
372
snmp_fold_field(net->mib.icmp_statistics, ICMP_MIB_RATELIMITGLOBAL),
net/ipv4/proc.c
373
snmp_fold_field(net->mib.icmp_statistics, ICMP_MIB_RATELIMITHOST));
net/ipv4/proc.c
386
struct net *net = seq->private;
net/ipv4/proc.c
396
IPV4_DEVCONF_ALL_RO(net, FORWARDING) ? 1 : 2,
net/ipv4/proc.c
397
READ_ONCE(net->ipv4.sysctl_ip_default_ttl));
net/ipv4/proc.c
401
net->mib.ip_statistics,
net/ipv4/proc.c
414
struct net *net = seq->private;
net/ipv4/proc.c
426
net->mib.tcp_statistics);
net/ipv4/proc.c
439
net->mib.udp_statistics);
net/ipv4/proc.c
470
struct net *net = seq->private;
net/ipv4/proc.c
483
net->mib.net_statistics);
net/ipv4/proc.c
489
snmp_fold_field(net->mib.net_statistics,
net/ipv4/proc.c
502
net->mib.ip_statistics,
net/ipv4/proc.c
509
snmp_fold_field64(net->mib.ip_statistics,
net/ipv4/proc.c
519
static __net_init int ip_proc_init_net(struct net *net)
net/ipv4/proc.c
521
if (!proc_create_net_single("sockstat", 0444, net->proc_net,
net/ipv4/proc.c
524
if (!proc_create_net_single("netstat", 0444, net->proc_net,
net/ipv4/proc.c
527
if (!proc_create_net_single("snmp", 0444, net->proc_net, snmp_seq_show,
net/ipv4/proc.c
53
struct net *net = seq->private;
net/ipv4/proc.c
534
remove_proc_entry("netstat", net->proc_net);
net/ipv4/proc.c
536
remove_proc_entry("sockstat", net->proc_net);
net/ipv4/proc.c
541
static __net_exit void ip_proc_exit_net(struct net *net)
net/ipv4/proc.c
543
remove_proc_entry("snmp", net->proc_net);
net/ipv4/proc.c
544
remove_proc_entry("netstat", net->proc_net);
net/ipv4/proc.c
545
remove_proc_entry("sockstat", net->proc_net);
net/ipv4/proc.c
61
sock_prot_inuse_get(net, &tcp_prot), orphans,
net/ipv4/proc.c
62
refcount_read(&net->ipv4.tcp_death_row.tw_refcount) - 1,
net/ipv4/proc.c
65
sock_prot_inuse_get(net, &udp_prot),
net/ipv4/proc.c
68
sock_prot_inuse_get(net, &raw_prot));
net/ipv4/proc.c
70
atomic_read(&net->ipv4.fqdir->rhashtable.nelems),
net/ipv4/proc.c
71
frag_mem_limit(net->ipv4.fqdir));
net/ipv4/raw.c
1076
static __net_init int raw_init_net(struct net *net)
net/ipv4/raw.c
1078
if (!proc_create_net_data("raw", 0444, net->proc_net, &raw_seq_ops,
net/ipv4/raw.c
1085
static __net_exit void raw_exit_net(struct net *net)
net/ipv4/raw.c
1087
remove_proc_entry("raw", net->proc_net);
net/ipv4/raw.c
1107
static void raw_sysctl_init_net(struct net *net)
net/ipv4/raw.c
1110
net->ipv4.sysctl_raw_l3mdev_accept = 1;
net/ipv4/raw.c
1114
static int __net_init raw_sysctl_init(struct net *net)
net/ipv4/raw.c
1116
raw_sysctl_init_net(net);
net/ipv4/raw.c
117
bool raw_v4_match(struct net *net, const struct sock *sk, unsigned short num,
net/ipv4/raw.c
123
if (!net_eq(sock_net(sk), net) || inet->inet_num != num)
net/ipv4/raw.c
134
return raw_sk_bound_dev_eq(net, READ_ONCE(sk->sk_bound_dev_if),
net/ipv4/raw.c
169
static int raw_v4_input(struct net *net, struct sk_buff *skb,
net/ipv4/raw.c
181
if (!raw_v4_match(net, sk, iph->protocol,
net/ipv4/raw.c
208
struct net *net = dev_net(skb->dev);
net/ipv4/raw.c
210
return raw_v4_input(net, skb, ip_hdr(skb),
net/ipv4/raw.c
211
raw_hashfunc(net, protocol));
net/ipv4/raw.c
280
struct net *net = dev_net(skb->dev);
net/ipv4/raw.c
288
hash = raw_hashfunc(net, protocol);
net/ipv4/raw.c
294
if (!raw_v4_match(net, sk, iph->protocol,
net/ipv4/raw.c
339
struct net *net = sock_net(sk);
net/ipv4/raw.c
409
ip_select_ident(net, skb, NULL);
net/ipv4/raw.c
415
icmp_out_count(net, ((struct icmphdr *)
net/ipv4/raw.c
420
net, sk, skb, NULL, rt->dst.dev,
net/ipv4/raw.c
432
IP_INC_STATS(net, IPSTATS_MIB_OUTDISCARDS);
net/ipv4/raw.c
494
struct net *net = sock_net(sk);
net/ipv4/raw.c
636
rt = ip_route_output_flow(net, &fl4, sk);
net/ipv4/raw.c
713
struct net *net = sock_net(sk);
net/ipv4/raw.c
723
tb_id = l3mdev_fib_table_by_index(net,
net/ipv4/raw.c
726
chk_addr_ret = inet_addr_type_table(net, addr->sin_addr.s_addr, tb_id);
net/ipv4/raw.c
729
if (!inet_addr_valid_or_nonlocal(net, inet, addr->sin_addr.s_addr,
net/ipv4/raw_diag.c
121
err = nlmsg_unicast(net->diag_nlsk, rep, NETLINK_CB(in_skb).portid);
net/ipv4/raw_diag.c
142
struct net *net = sock_net(skb->sk);
net/ipv4/raw_diag.c
161
if (!net_eq(sock_net(sk), net))
net/ipv4/raw_diag.c
198
struct net *net = sock_net(in_skb->sk);
net/ipv4/raw_diag.c
202
sk = raw_sock_get(net, r);
net/ipv4/raw_diag.c
37
static bool raw_lookup(struct net *net, const struct sock *sk,
net/ipv4/raw_diag.c
43
return raw_v4_match(net, sk, r->sdiag_raw_protocol,
net/ipv4/raw_diag.c
49
return raw_v6_match(net, sk, r->sdiag_raw_protocol,
net/ipv4/raw_diag.c
57
static struct sock *raw_sock_get(struct net *net, const struct inet_diag_req_v2 *r)
net/ipv4/raw_diag.c
71
if (raw_lookup(net, sk, r)) {
net/ipv4/raw_diag.c
95
struct net *net;
net/ipv4/raw_diag.c
98
net = sock_net(in_skb->sk);
net/ipv4/raw_diag.c
99
sk = raw_sock_get(net, r);
net/ipv4/route.c
1024
struct net *net;
net/ipv4/route.c
1035
net = dst_dev_net_rcu(dst);
net/ipv4/route.c
1036
if (mtu < net->ipv4.ip_rt_min_pmtu) {
net/ipv4/route.c
1038
mtu = min(old_mtu, net->ipv4.ip_rt_min_pmtu);
net/ipv4/route.c
1043
net->ipv4.ip_rt_mtu_expires / 2))
net/ipv4/route.c
1046
if (fib_lookup(net, fl4, &res, 0) == 0) {
net/ipv4/route.c
1049
fib_select_path(net, &res, fl4, NULL);
net/ipv4/route.c
1057
jiffies + net->ipv4.ip_rt_mtu_expires);
net/ipv4/route.c
1064
jiffies + net->ipv4.ip_rt_mtu_expires);
net/ipv4/route.c
1086
void ipv4_update_pmtu(struct sk_buff *skb, struct net *net, u32 mtu,
net/ipv4/route.c
1092
u32 mark = IP4_REPLY_MARK(net, skb->mark);
net/ipv4/route.c
1094
__build_flow_key(net, &fl4, NULL, iph, oif, iph->tos, protocol, mark,
net/ipv4/route.c
1096
rt = __ip_route_output_key(net, &fl4);
net/ipv4/route.c
1129
struct net *net = sock_net(sk);
net/ipv4/route.c
1143
__build_flow_key(net, &fl4, sk, iph, 0, 0, 0, 0, 0);
net/ipv4/route.c
1175
void ipv4_redirect(struct sk_buff *skb, struct net *net,
net/ipv4/route.c
1182
__build_flow_key(net, &fl4, NULL, iph, oif, iph->tos, protocol, 0, 0);
net/ipv4/route.c
1183
rt = __ip_route_output_key(net, &fl4);
net/ipv4/route.c
1196
struct net *net = sock_net(sk);
net/ipv4/route.c
1198
__build_flow_key(net, &fl4, sk, iph, 0, 0, 0, 0, 0);
net/ipv4/route.c
1199
rt = __ip_route_output_key(net, &fl4);
net/ipv4/route.c
1267
static int ip_rt_bug(struct net *net, struct sock *sk, struct sk_buff *skb)
net/ipv4/route.c
1330
struct net *net;
net/ipv4/route.c
1333
net = dst_dev_net_rcu(dst);
net/ipv4/route.c
1335
net->ipv4.ip_rt_min_advmss);
net/ipv4/route.c
1943
static u32 fib_multipath_custom_hash_outer(const struct net *net,
net/ipv4/route.c
1947
u32 hash_fields = READ_ONCE(net->ipv4.sysctl_fib_multipath_hash_fields);
net/ipv4/route.c
1969
return fib_multipath_hash_from_keys(net, &hash_keys);
net/ipv4/route.c
1972
static u32 fib_multipath_custom_hash_inner(const struct net *net,
net/ipv4/route.c
1976
u32 hash_fields = READ_ONCE(net->ipv4.sysctl_fib_multipath_hash_fields);
net/ipv4/route.c
2018
return fib_multipath_hash_from_keys(net, &hash_keys);
net/ipv4/route.c
2021
static u32 fib_multipath_custom_hash_skb(const struct net *net,
net/ipv4/route.c
2027
mhash = fib_multipath_custom_hash_outer(net, skb, &has_inner);
net/ipv4/route.c
2028
mhash_inner = fib_multipath_custom_hash_inner(net, skb, has_inner);
net/ipv4/route.c
2033
static u32 fib_multipath_custom_hash_fl4(const struct net *net,
net/ipv4/route.c
2036
u32 hash_fields = READ_ONCE(net->ipv4.sysctl_fib_multipath_hash_fields);
net/ipv4/route.c
2059
return fib_multipath_hash_from_keys(net, &hash_keys);
net/ipv4/route.c
2063
int fib_multipath_hash(const struct net *net, const struct flowi4 *fl4,
net/ipv4/route.c
2070
switch (READ_ONCE(net->ipv4.sysctl_fib_multipath_hash_policy)) {
net/ipv4/route.c
2080
mhash = fib_multipath_hash_from_keys(net, &hash_keys);
net/ipv4/route.c
2117
mhash = fib_multipath_hash_from_keys(net, &hash_keys);
net/ipv4/route.c
2148
mhash = fib_multipath_hash_from_keys(net, &hash_keys);
net/ipv4/route.c
2152
mhash = fib_multipath_custom_hash_skb(net, skb);
net/ipv4/route.c
2154
mhash = fib_multipath_custom_hash_fl4(net, fl4);
net/ipv4/route.c
2195
struct net *net = dev_net(dev);
net/ipv4/route.c
2211
if (ipv4_is_loopback(saddr) && !IN_DEV_NET_ROUTE_LOCALNET(in_dev, net)) {
net/ipv4/route.c
2234
static struct net_device *ip_rt_get_dev(struct net *net,
net/ipv4/route.c
2243
return dev ? : net->loopback_dev;
net/ipv4/route.c
2267
struct net *net = dev_net(dev);
net/ipv4/route.c
2319
if (!IN_DEV_NET_ROUTE_LOCALNET(in_dev, net)) {
net/ipv4/route.c
2324
if (!IN_DEV_NET_ROUTE_LOCALNET(in_dev, net)) {
net/ipv4/route.c
2342
fl4.flowi4_uid = sock_net_uid(net, NULL);
net/ipv4/route.c
2345
if (fib4_rules_early_flow_dissect(net, skb, &fl4, &_flkeys)) {
net/ipv4/route.c
2353
err = fib_lookup(net, &fl4, res, 0);
net/ipv4/route.c
2364
if (IPV4_DEVCONF_ALL_RO(net, BC_FORWARDING))
net/ipv4/route.c
2426
rth = rt_dst_alloc(ip_rt_get_dev(net, res),
net/ipv4/route.c
2688
struct rtable *ip_route_output_key_hash(struct net *net, struct flowi4 *fl4,
net/ipv4/route.c
2702
rth = ip_route_output_key_hash_rcu(net, fl4, &res, skb);
net/ipv4/route.c
2709
struct rtable *ip_route_output_key_hash_rcu(struct net *net, struct flowi4 *fl4,
net/ipv4/route.c
2740
dev_out = __ip_dev_find(net, fl4->saddr, false);
net/ipv4/route.c
2765
if (!__ip_dev_find(net, fl4->saddr, false))
net/ipv4/route.c
2772
dev_out = dev_get_by_index_rcu(net, fl4->flowi4_oif);
net/ipv4/route.c
2804
dev_out = net->loopback_dev;
net/ipv4/route.c
2811
err = fib_lookup(net, fl4, res, 0);
net/ipv4/route.c
2855
net->loopback_dev;
net/ipv4/route.c
2867
fib_select_path(net, res, fl4, skb);
net/ipv4/route.c
2889
struct dst_entry *ipv4_blackhole_route(struct net *net, struct dst_entry *dst_orig)
net/ipv4/route.c
2902
new->dev = net->loopback_dev;
net/ipv4/route.c
2910
rt->rt_genid = rt_genid_ipv4(net);
net/ipv4/route.c
2926
struct rtable *ip_route_output_flow(struct net *net, struct flowi4 *flp4,
net/ipv4/route.c
2929
struct rtable *rt = __ip_route_output_key(net, flp4);
net/ipv4/route.c
2936
rt = dst_rtable(xfrm_lookup_route(net, &rt->dst,
net/ipv4/route.c
2946
static int rt_fill_info(struct net *net, __be32 dst, __be32 src,
net/ipv4/route.c
3052
IPV4_DEVCONF_ALL_RO(net, MC_FORWARDING)) {
net/ipv4/route.c
3053
int err = ipmr_get_route(net, skb,
net/ipv4/route.c
3082
static int fnhe_dump_bucket(struct net *net, struct sk_buff *skb,
net/ipv4/route.c
3113
err = rt_fill_info(net, fnhe->fnhe_daddr, 0, rt,
net/ipv4/route.c
3131
struct net *net = sock_net(cb->skb->sk);
net/ipv4/route.c
3132
int nhsel, genid = fnhe_genid(net);
net/ipv4/route.c
3146
err = fnhe_dump_bucket(net, skb, cb, table_id, bucket,
net/ipv4/route.c
3290
struct net *net = sock_net(in_skb->sk);
net/ipv4/route.c
3357
dev = dev_get_by_index_rcu(net, iif);
net/ipv4/route.c
3374
skb->dev = net->loopback_dev;
net/ipv4/route.c
3375
rt = ip_route_output_key_hash_rcu(net, &fl4, &res, skb);
net/ipv4/route.c
338
static int __net_init ip_rt_do_proc_init(struct net *net)
net/ipv4/route.c
342
pde = proc_create_seq("rt_cache", 0444, net->proc_net,
net/ipv4/route.c
3438
err = rt_fill_info(net, dst, src, rt, table_id, res.dscp, &fl4,
net/ipv4/route.c
3447
err = rtnl_unicast(skb, net, NETLINK_CB(in_skb).portid);
net/ipv4/route.c
347
pde = proc_create_seq("rt_cache", 0444, net->proc_net_stat,
net/ipv4/route.c
3471
struct net *net = (struct net *)__ctl->extra1;
net/ipv4/route.c
3474
rt_cache_flush(net);
net/ipv4/route.c
3475
fnhe_genid_bump(net);
net/ipv4/route.c
353
pde = proc_create_single("rt_acct", 0, net->proc_net,
net/ipv4/route.c
3604
static __net_init int sysctl_route_net_init(struct net *net)
net/ipv4/route.c
3610
if (!net_eq(net, &init_net)) {
net/ipv4/route.c
3618
if (net->user_ns != &init_user_ns) {
net/ipv4/route.c
362
remove_proc_entry("rt_cache", net->proc_net_stat);
net/ipv4/route.c
3627
tbl[i].data += (void *)net - (void *)&init_net;
net/ipv4/route.c
3629
tbl[0].extra1 = net;
net/ipv4/route.c
3631
net->ipv4.route_hdr = register_net_sysctl_sz(net, "net/ipv4/route",
net/ipv4/route.c
3633
if (!net->ipv4.route_hdr)
net/ipv4/route.c
3644
static __net_exit void sysctl_route_net_exit(struct net *net)
net/ipv4/route.c
3648
tbl = net->ipv4.route_hdr->ctl_table_arg;
net/ipv4/route.c
3649
unregister_net_sysctl_table(net->ipv4.route_hdr);
net/ipv4/route.c
365
remove_proc_entry("rt_cache", net->proc_net);
net/ipv4/route.c
3660
static __net_init int netns_ip_rt_init(struct net *net)
net/ipv4/route.c
3663
net->ipv4.ip_rt_min_pmtu = DEFAULT_MIN_PMTU;
net/ipv4/route.c
3664
net->ipv4.ip_rt_mtu_expires = DEFAULT_MTU_EXPIRES;
net/ipv4/route.c
3665
net->ipv4.ip_rt_min_advmss = DEFAULT_MIN_ADVMSS;
net/ipv4/route.c
3673
static __net_init int rt_genid_init(struct net *net)
net/ipv4/route.c
3675
atomic_set(&net->ipv4.rt_genid, 0);
net/ipv4/route.c
3676
atomic_set(&net->fnhe_genid, 0);
net/ipv4/route.c
3677
atomic_set(&net->ipv4.dev_addr_genid, get_random_u32());
net/ipv4/route.c
3685
static int __net_init ipv4_inetpeer_init(struct net *net)
net/ipv4/route.c
3692
net->ipv4.peers = bp;
net/ipv4/route.c
3696
static void __net_exit ipv4_inetpeer_exit(struct net *net)
net/ipv4/route.c
3698
struct inet_peer_base *bp = net->ipv4.peers;
net/ipv4/route.c
370
static void __net_exit ip_rt_do_proc_exit(struct net *net)
net/ipv4/route.c
3700
net->ipv4.peers = NULL;
net/ipv4/route.c
372
remove_proc_entry("rt_cache", net->proc_net_stat);
net/ipv4/route.c
373
remove_proc_entry("rt_cache", net->proc_net);
net/ipv4/route.c
375
remove_proc_entry("rt_acct", net->proc_net);
net/ipv4/route.c
407
void rt_cache_flush(struct net *net)
net/ipv4/route.c
409
rt_genid_bump_ipv4(net);
net/ipv4/route.c
492
void __ip_select_ident(struct net *net, struct iphdr *iph, int segs)
net/ipv4/route.c
497
if (unlikely(siphash_key_is_zero(&net->ipv4.ip_id_key)))
net/ipv4/route.c
498
get_random_bytes(&net->ipv4.ip_id_key,
net/ipv4/route.c
499
sizeof(net->ipv4.ip_id_key));
net/ipv4/route.c
504
&net->ipv4.ip_id_key);
net/ipv4/route.c
510
static void __build_flow_key(const struct net *net, struct flowi4 *fl4,
net/ipv4/route.c
528
sock_net_uid(net, sk));
net/ipv4/route.c
534
const struct net *net = dev_net(skb->dev);
net/ipv4/route.c
541
__build_flow_key(net, fl4, sk, iph, oif, tos, prot, mark, 0);
net/ipv4/route.c
753
struct net *net;
net/ipv4/route.c
773
net = dev_net(dev);
net/ipv4/route.c
785
if (inet_addr_type(net, new_gw) != RTN_UNICAST)
net/ipv4/route.c
796
if (fib_lookup(net, fl4, &res, 0) == 0) {
net/ipv4/route.c
799
fib_select_path(net, &res, fl4, skb);
net/ipv4/route.c
834
struct net *net = dev_net(skb->dev);
net/ipv4/route.c
842
__build_flow_key(net, &fl4, sk, iph, oif, tos, prot, mark, 0);
net/ipv4/route.c
878
struct net *net;
net/ipv4/route.c
891
net = dev_net(rt->dst.dev);
net/ipv4/route.c
892
peer = inet_getpeer_v4(net->ipv4.peers, ip_hdr(skb)->saddr, vif);
net/ipv4/route.c
945
struct net *net;
net/ipv4/route.c
962
net = dev_net(rt->dst.dev);
net/ipv4/route.c
967
__IP_INC_STATS(net, IPSTATS_MIB_INADDRERRORS);
net/ipv4/route.c
972
__IP_INC_STATS(net, IPSTATS_MIB_INNOROUTES);
net/ipv4/route.c
988
__IP_INC_STATS(net, IPSTATS_MIB_INNOROUTES);
net/ipv4/route.c
996
peer = inet_getpeer_v4(net->ipv4.peers, ip_hdr(skb)->saddr,
net/ipv4/syncookies.c
235
bool cookie_timestamp_decode(const struct net *net,
net/ipv4/syncookies.c
246
if (!READ_ONCE(net->ipv4.sysctl_tcp_timestamps))
net/ipv4/syncookies.c
251
if (tcp_opt->sack_ok && !READ_ONCE(net->ipv4.sysctl_tcp_sack))
net/ipv4/syncookies.c
260
return READ_ONCE(net->ipv4.sysctl_tcp_window_scaling) != 0;
net/ipv4/syncookies.c
358
static struct request_sock *cookie_tcp_check(struct net *net, struct sock *sk,
net/ipv4/syncookies.c
370
__NET_INC_STATS(net, LINUX_MIB_SYNCOOKIESFAILED);
net/ipv4/syncookies.c
374
__NET_INC_STATS(net, LINUX_MIB_SYNCOOKIESRECV);
net/ipv4/syncookies.c
378
tcp_parse_options(net, skb, &tcp_opt, 0, NULL);
net/ipv4/syncookies.c
383
st = secure_tcp_seq_and_ts_off(net,
net/ipv4/syncookies.c
392
if (!cookie_timestamp_decode(net, &tcp_opt))
net/ipv4/syncookies.c
411
struct net *net = sock_net(sk);
net/ipv4/syncookies.c
421
if (!READ_ONCE(net->ipv4.sysctl_tcp_syncookies) ||
net/ipv4/syncookies.c
428
req = cookie_tcp_check(net, sk, skb);
net/ipv4/syncookies.c
446
RCU_INIT_POINTER(ireq->ireq_opt, tcp_v4_save_options(net, skb));
net/ipv4/syncookies.c
468
rt = ip_route_output_key(net, &fl4);
net/ipv4/syncookies.c
493
ireq->ecn_ok &= cookie_ecn_ok(net, &rt->dst);
net/ipv4/sysctl_net_ipv4.c
107
struct net *net = container_of(table->data, struct net,
net/ipv4/sysctl_net_ipv4.c
120
pports = READ_ONCE(net->ipv4.sysctl_ip_prot_sock);
net/ipv4/sysctl_net_ipv4.c
125
inet_get_local_port_range(net, &range[0], &range[1]);
net/ipv4/sysctl_net_ipv4.c
132
WRITE_ONCE(net->ipv4.sysctl_ip_prot_sock, pports);
net/ipv4/sysctl_net_ipv4.c
142
struct net *net =
net/ipv4/sysctl_net_ipv4.c
143
container_of(table->data, struct net, ipv4.ping_group_range.range);
net/ipv4/sysctl_net_ipv4.c
146
seq = read_seqbegin(&net->ipv4.ping_group_range.lock);
net/ipv4/sysctl_net_ipv4.c
150
} while (read_seqretry(&net->ipv4.ping_group_range.lock, seq));
net/ipv4/sysctl_net_ipv4.c
158
struct net *net =
net/ipv4/sysctl_net_ipv4.c
159
container_of(table->data, struct net, ipv4.ping_group_range.range);
net/ipv4/sysctl_net_ipv4.c
160
write_seqlock(&net->ipv4.ping_group_range.lock);
net/ipv4/sysctl_net_ipv4.c
163
write_sequnlock(&net->ipv4.ping_group_range.lock);
net/ipv4/sysctl_net_ipv4.c
1657
static __net_init int ipv4_sysctl_init_net(struct net *net)
net/ipv4/sysctl_net_ipv4.c
1663
if (!net_eq(net, &init_net)) {
net/ipv4/sysctl_net_ipv4.c
1675
table[i].data += (void *)net - (void *)&init_net;
net/ipv4/sysctl_net_ipv4.c
1684
table[i].extra2 += (void *)net - (void *)&init_net;
net/ipv4/sysctl_net_ipv4.c
1688
net->ipv4.ipv4_hdr = register_net_sysctl_sz(net, "net/ipv4", table,
net/ipv4/sysctl_net_ipv4.c
1690
if (!net->ipv4.ipv4_hdr)
net/ipv4/sysctl_net_ipv4.c
1693
net->ipv4.sysctl_local_reserved_ports = kzalloc(65536 / 8, GFP_KERNEL);
net/ipv4/sysctl_net_ipv4.c
1694
if (!net->ipv4.sysctl_local_reserved_ports)
net/ipv4/sysctl_net_ipv4.c
1697
proc_fib_multipath_hash_set_seed(net, 0);
net/ipv4/sysctl_net_ipv4.c
1702
unregister_net_sysctl_table(net->ipv4.ipv4_hdr);
net/ipv4/sysctl_net_ipv4.c
1704
if (!net_eq(net, &init_net))
net/ipv4/sysctl_net_ipv4.c
1710
static __net_exit void ipv4_sysctl_exit_net(struct net *net)
net/ipv4/sysctl_net_ipv4.c
1714
table = net->ipv4.ipv4_hdr->ctl_table_arg;
net/ipv4/sysctl_net_ipv4.c
1715
unregister_net_sysctl_table(net->ipv4.ipv4_hdr);
net/ipv4/sysctl_net_ipv4.c
1717
kfree(net->ipv4.sysctl_local_reserved_ports);
net/ipv4/sysctl_net_ipv4.c
205
struct net *net;
net/ipv4/sysctl_net_ipv4.c
208
net = container_of(table->data, struct net,
net/ipv4/sysctl_net_ipv4.c
213
net);
net/ipv4/sysctl_net_ipv4.c
221
struct net *net = container_of(ctl->data, struct net,
net/ipv4/sysctl_net_ipv4.c
230
tcp_get_default_congestion_control(net, val);
net/ipv4/sysctl_net_ipv4.c
234
ret = tcp_set_default_congestion_control(net, val);
net/ipv4/sysctl_net_ipv4.c
294
struct net *net = container_of(table->data, struct net,
net/ipv4/sysctl_net_ipv4.c
311
n_keys = tcp_fastopen_get_cipher(net, NULL, (u64 *)key);
net/ipv4/sysctl_net_ipv4.c
353
tcp_fastopen_reset_cipher(net, NULL, key,
net/ipv4/sysctl_net_ipv4.c
366
struct net *net = container_of(table->data, struct net,
net/ipv4/sysctl_net_ipv4.c
372
atomic_set(&net->ipv4.tfo_active_disable_times, 0);
net/ipv4/sysctl_net_ipv4.c
397
struct net *net = container_of(table->data, struct net,
net/ipv4/sysctl_net_ipv4.c
399
struct inet_hashinfo *hinfo = net->ipv4.tcp_death_row.hashinfo;
net/ipv4/sysctl_net_ipv4.c
408
if (!net_eq(net, &init_net) && !hinfo->pernet)
net/ipv4/sysctl_net_ipv4.c
421
struct net *net = container_of(table->data, struct net,
net/ipv4/sysctl_net_ipv4.c
426
udp_hash_entries = net->ipv4.udp_table->mask + 1;
net/ipv4/sysctl_net_ipv4.c
431
if (!net_eq(net, &init_net) && net->ipv4.udp_table == &udp_table)
net/ipv4/sysctl_net_ipv4.c
446
struct net *net = container_of(table->data, struct net,
net/ipv4/sysctl_net_ipv4.c
452
call_netevent_notifiers(NETEVENT_IPV4_MPATH_HASH_UPDATE, net);
net/ipv4/sysctl_net_ipv4.c
461
struct net *net;
net/ipv4/sysctl_net_ipv4.c
464
net = container_of(table->data, struct net,
net/ipv4/sysctl_net_ipv4.c
468
call_netevent_notifiers(NETEVENT_IPV4_MPATH_HASH_UPDATE, net);
net/ipv4/sysctl_net_ipv4.c
481
static void proc_fib_multipath_hash_set_seed(struct net *net, u32 user_seed)
net/ipv4/sysctl_net_ipv4.c
489
WRITE_ONCE(net->ipv4.sysctl_fib_multipath_hash_seed.user_seed, new.user_seed);
net/ipv4/sysctl_net_ipv4.c
490
WRITE_ONCE(net->ipv4.sysctl_fib_multipath_hash_seed.mp_seed, new.mp_seed);
net/ipv4/sysctl_net_ipv4.c
498
struct net *net = table->data;
net/ipv4/sysctl_net_ipv4.c
503
mphs = &net->ipv4.sysctl_fib_multipath_hash_seed;
net/ipv4/sysctl_net_ipv4.c
512
proc_fib_multipath_hash_set_seed(net, user_seed);
net/ipv4/sysctl_net_ipv4.c
513
call_netevent_notifiers(NETEVENT_IPV4_MPATH_HASH_UPDATE, net);
net/ipv4/sysctl_net_ipv4.c
524
static void proc_fib_multipath_hash_set_seed(struct net *net, u32 user_seed)
net/ipv4/sysctl_net_ipv4.c
58
static void set_local_port_range(struct net *net, unsigned int low, unsigned int high)
net/ipv4/sysctl_net_ipv4.c
62
if (same_parity && !net->ipv4.ip_local_ports.warned) {
net/ipv4/sysctl_net_ipv4.c
63
net->ipv4.ip_local_ports.warned = true;
net/ipv4/sysctl_net_ipv4.c
66
WRITE_ONCE(net->ipv4.ip_local_ports.range, high << 16 | low);
net/ipv4/sysctl_net_ipv4.c
73
struct net *net = table->data;
net/ipv4/sysctl_net_ipv4.c
84
inet_get_local_port_range(net, &range[0], &range[1]);
net/ipv4/sysctl_net_ipv4.c
94
(range[0] < READ_ONCE(net->ipv4.sysctl_ip_prot_sock)))
net/ipv4/sysctl_net_ipv4.c
97
set_local_port_range(net, range[0], range[1]);
net/ipv4/tcp.c
3842
struct net *net = sock_net(sk);
net/ipv4/tcp.c
3902
return tcp_fastopen_reset_cipher(net, sk, key, backup_key);
net/ipv4/tcp.c
4101
tcp_fastopen_init_key_once(net);
net/ipv4/tcp.c
4111
} else if (READ_ONCE(net->ipv4.sysctl_tcp_fastopen) &
net/ipv4/tcp.c
4486
struct net *net = sock_net(sk);
net/ipv4/tcp.c
4525
READ_ONCE(net->ipv4.sysctl_tcp_syn_retries);
net/ipv4/tcp.c
4530
val = (val ? : READ_ONCE(net->ipv4.sysctl_tcp_fin_timeout)) / HZ;
net/ipv4/tcp.c
4612
key_len = tcp_fastopen_get_cipher(net, icsk, key) *
net/ipv4/tcp_cong.c
218
struct net *net = sock_net(sk);
net/ipv4/tcp_cong.c
223
ca = rcu_dereference(net->ipv4.tcp_congestion_control);
net/ipv4/tcp_cong.c
281
int tcp_set_default_congestion_control(struct net *net, const char *name)
net/ipv4/tcp_cong.c
293
} else if (!net_eq(net, &init_net) &&
net/ipv4/tcp_cong.c
298
prev = xchg(&net->ipv4.tcp_congestion_control, ca);
net/ipv4/tcp_cong.c
337
void tcp_get_default_congestion_control(struct net *net, char *name)
net/ipv4/tcp_cong.c
342
ca = rcu_dereference(net->ipv4.tcp_congestion_control);
net/ipv4/tcp_diag.c
319
struct net *net = sock_net(skb->sk);
net/ipv4/tcp_diag.c
325
hashinfo = net->ipv4.tcp_death_row.hashinfo;
net/ipv4/tcp_diag.c
350
if (!net_eq(sock_net(sk), net))
net/ipv4/tcp_diag.c
416
if (!net_eq(ib2_net(tb2), net))
net/ipv4/tcp_diag.c
501
if (!net_eq(sock_net(sk), net))
net/ipv4/tcp_diag.c
563
static struct sock *tcp_diag_find_one_icsk(struct net *net,
net/ipv4/tcp_diag.c
570
sk = inet_lookup(net, NULL, 0, req->id.idiag_dst[0],
net/ipv4/tcp_diag.c
577
sk = inet_lookup(net, NULL, 0, req->id.idiag_dst[3],
net/ipv4/tcp_diag.c
581
sk = inet6_lookup(net, NULL, 0,
net/ipv4/tcp_diag.c
610
struct net *net;
net/ipv4/tcp_diag.c
614
net = sock_net(in_skb->sk);
net/ipv4/tcp_diag.c
615
sk = tcp_diag_find_one_icsk(net, req);
net/ipv4/tcp_diag.c
632
err = nlmsg_unicast(net->diag_nlsk, rep, NETLINK_CB(in_skb).portid);
net/ipv4/tcp_diag.c
645
struct net *net = sock_net(in_skb->sk);
net/ipv4/tcp_diag.c
649
sk = tcp_diag_find_one_icsk(net, req);
net/ipv4/tcp_fastopen.c
100
ctxt = rcu_dereference(net->ipv4.tcp_fastopen_ctx);
net/ipv4/tcp_fastopen.c
114
tcp_fastopen_reset_cipher(net, NULL, key, NULL);
net/ipv4/tcp_fastopen.c
135
void tcp_fastopen_ctx_destroy(struct net *net)
net/ipv4/tcp_fastopen.c
139
ctxt = unrcu_pointer(xchg(&net->ipv4.tcp_fastopen_ctx, NULL));
net/ipv4/tcp_fastopen.c
145
int tcp_fastopen_reset_cipher(struct net *net, struct sock *sk,
net/ipv4/tcp_fastopen.c
172
octx = unrcu_pointer(xchg(&net->ipv4.tcp_fastopen_ctx,
net/ipv4/tcp_fastopen.c
182
int tcp_fastopen_get_cipher(struct net *net, struct inet_connection_sock *icsk,
net/ipv4/tcp_fastopen.c
192
ctx = rcu_dereference(net->ipv4.tcp_fastopen_ctx);
net/ipv4/tcp_fastopen.c
584
struct net *net = sock_net(sk);
net/ipv4/tcp_fastopen.c
590
WRITE_ONCE(net->ipv4.tfo_active_disable_stamp, jiffies);
net/ipv4/tcp_fastopen.c
596
atomic_inc(&net->ipv4.tfo_active_disable_times);
net/ipv4/tcp_fastopen.c
598
NET_INC_STATS(net, LINUX_MIB_TCPFASTOPENBLACKHOLE);
net/ipv4/tcp_fastopen.c
94
void tcp_fastopen_init_key_once(struct net *net)
net/ipv4/tcp_input.c
2558
struct net *net = sock_net(sk);
net/ipv4/tcp_input.c
2581
reordering = READ_ONCE(net->ipv4.sysctl_tcp_reordering);
net/ipv4/tcp_input.c
2596
tp->frto = READ_ONCE(net->ipv4.sysctl_tcp_frto) &&
net/ipv4/tcp_input.c
3989
static bool __tcp_oow_rate_limited(struct net *net, int mib_idx,
net/ipv4/tcp_input.c
3999
elapsed < READ_ONCE(net->ipv4.sysctl_tcp_invalid_ratelimit)) {
net/ipv4/tcp_input.c
4000
NET_INC_STATS(net, mib_idx);
net/ipv4/tcp_input.c
4020
bool tcp_oow_rate_limited(struct net *net, const struct sk_buff *skb,
net/ipv4/tcp_input.c
4028
return __tcp_oow_rate_limited(net, mib_idx, last_oow_ack_time);
net/ipv4/tcp_input.c
4044
static bool tcp_challenge_ack_allowed(struct net *net)
net/ipv4/tcp_input.c
4048
ack_limit = READ_ONCE(net->ipv4.sysctl_tcp_challenge_ack_limit);
net/ipv4/tcp_input.c
4053
if (now != READ_ONCE(net->ipv4.tcp_challenge_timestamp)) {
net/ipv4/tcp_input.c
4056
WRITE_ONCE(net->ipv4.tcp_challenge_timestamp, now);
net/ipv4/tcp_input.c
4057
WRITE_ONCE(net->ipv4.tcp_challenge_count,
net/ipv4/tcp_input.c
4060
count = READ_ONCE(net->ipv4.tcp_challenge_count);
net/ipv4/tcp_input.c
4062
WRITE_ONCE(net->ipv4.tcp_challenge_count, count - 1);
net/ipv4/tcp_input.c
4072
struct net *net = sock_net(sk);
net/ipv4/tcp_input.c
4075
if (__tcp_oow_rate_limited(net,
net/ipv4/tcp_input.c
4081
if (tcp_challenge_ack_allowed(net)) {
net/ipv4/tcp_input.c
4082
NET_INC_STATS(net, LINUX_MIB_TCPCHALLENGEACK);
net/ipv4/tcp_input.c
4094
struct net *net = sock_net(sk);
net/ipv4/tcp_input.c
4096
if (__tcp_oow_rate_limited(net, LINUX_MIB_TCPACKSKIPPEDCHALLENGE,
net/ipv4/tcp_input.c
4100
if (tcp_challenge_ack_allowed(net)) {
net/ipv4/tcp_input.c
4101
NET_INC_STATS(net, LINUX_MIB_TCPCHALLENGEACK);
net/ipv4/tcp_input.c
4216
const struct net *net = sock_net(sk);
net/ipv4/tcp_input.c
4221
NET_ADD_STATS(net, LINUX_MIB_TCPDELIVERED, delivered);
net/ipv4/tcp_input.c
4226
NET_ADD_STATS(net, LINUX_MIB_TCPDELIVEREDCE, ecn_count);
net/ipv4/tcp_input.c
4565
void tcp_parse_options(const struct net *net,
net/ipv4/tcp_input.c
4611
!estab && READ_ONCE(net->ipv4.sysctl_tcp_window_scaling)) {
net/ipv4/tcp_input.c
4627
(!estab && READ_ONCE(net->ipv4.sysctl_tcp_timestamps)))) {
net/ipv4/tcp_input.c
4635
!estab && READ_ONCE(net->ipv4.sysctl_tcp_sack)) {
net/ipv4/tcp_input.c
4725
static bool tcp_fast_parse_options(const struct net *net,
net/ipv4/tcp_input.c
4744
tcp_parse_options(net, skb, &tp->rx_opt, 1, NULL);
net/ipv4/tcp_input.c
6118
struct net *net = sock_net(sk);
net/ipv4/tcp_input.c
6139
READ_ONCE(net->ipv4.sysctl_tcp_backlog_ack_defer)) {
net/ipv4/tcp_input.c
6154
tp->compressed_ack >= READ_ONCE(net->ipv4.sysctl_tcp_comp_sack_nr))
net/ipv4/tcp_input.c
6182
READ_ONCE(net->ipv4.sysctl_tcp_comp_sack_rtt_percent);
net/ipv4/tcp_input.c
6184
delay = min(delay, READ_ONCE(net->ipv4.sysctl_tcp_comp_sack_delay_ns));
net/ipv4/tcp_input.c
6188
READ_ONCE(net->ipv4.sysctl_tcp_comp_sack_slack_ns),
net/ipv4/tcp_input.c
7460
const struct net *net = sock_net(listen_sk);
net/ipv4/tcp_input.c
7466
(READ_ONCE(net->ipv4.sysctl_tcp_ecn) >= 3 ||
net/ipv4/tcp_input.c
7480
ecn_ok = READ_ONCE(net->ipv4.sysctl_tcp_ecn) || ecn_ok_dst;
net/ipv4/tcp_input.c
7530
struct net *net = sock_net(sk);
net/ipv4/tcp_input.c
7534
syncookies = READ_ONCE(net->ipv4.sysctl_tcp_syncookies);
net/ipv4/tcp_input.c
7628
struct net *net = sock_net(sk);
net/ipv4/tcp_input.c
7646
syncookies = READ_ONCE(net->ipv4.sysctl_tcp_syncookies);
net/ipv4/tcp_input.c
7709
net, skb);
net/ipv4/tcp_input.c
7716
int max_syn_backlog = READ_ONCE(net->ipv4.sysctl_max_syn_backlog);
net/ipv4/tcp_input.c
782
struct net *net = sock_net(sk);
net/ipv4/tcp_input.c
786
rmem2 = READ_ONCE(net->ipv4.sysctl_tcp_rmem[2]);
net/ipv4/tcp_input.c
913
const struct net *net = sock_net(sk);
net/ipv4/tcp_input.c
922
if (!READ_ONCE(net->ipv4.sysctl_tcp_moderate_rcvbuf) ||
net/ipv4/tcp_input.c
930
rtt_threshold = READ_ONCE(net->ipv4.sysctl_tcp_rcvbuf_low_rtt);
net/ipv4/tcp_input.c
946
cap = READ_ONCE(net->ipv4.sysctl_tcp_rmem[2]);
net/ipv4/tcp_ipv4.c
1010
__TCP_INC_STATS(net, TCP_MIB_OUTSEGS);
net/ipv4/tcp_ipv4.c
109
tcp_v4_init_seq_and_ts_off(const struct net *net, const struct sk_buff *skb)
net/ipv4/tcp_ipv4.c
111
return secure_tcp_seq_and_ts_off(net,
net/ipv4/tcp_ipv4.c
1607
struct net *net = sock_net(sk_listener);
net/ipv4/tcp_ipv4.c
1611
RCU_INIT_POINTER(ireq->ireq_opt, tcp_v4_save_options(net, skb));
net/ipv4/tcp_ipv4.c
2072
struct net *net = dev_net_rcu(skb->dev);
net/ipv4/tcp_ipv4.c
2089
__TCP_INC_STATS(net, TCP_MIB_INSEGS);
net/ipv4/tcp_ipv4.c
2208
__NET_INC_STATS(net, LINUX_MIB_TCPMINTTLDROP);
net/ipv4/tcp_ipv4.c
2273
__TCP_INC_STATS(net, TCP_MIB_CSUMERRORS);
net/ipv4/tcp_ipv4.c
2275
__TCP_INC_STATS(net, TCP_MIB_INERRS);
net/ipv4/tcp_ipv4.c
228
struct net *net = sock_net(sk);
net/ipv4/tcp_ipv4.c
2310
struct sock *sk2 = inet_lookup_listener(net, skb, __tcp_hdrlen(th),
net/ipv4/tcp_ipv4.c
259
IP_INC_STATS(net, IPSTATS_MIB_OUTNOROUTES);
net/ipv4/tcp_ipv4.c
328
st = secure_tcp_seq_and_ts_off(net,
net/ipv4/tcp_ipv4.c
3314
static int __net_init tcp4_proc_init_net(struct net *net)
net/ipv4/tcp_ipv4.c
3316
if (!proc_create_net_data("tcp", 0444, net->proc_net, &tcp4_seq_ops,
net/ipv4/tcp_ipv4.c
3322
static void __net_exit tcp4_proc_exit_net(struct net *net)
net/ipv4/tcp_ipv4.c
3324
remove_proc_entry("tcp", net->proc_net);
net/ipv4/tcp_ipv4.c
3381
.sysctl_wmem_offset = offsetof(struct net, ipv4.sysctl_tcp_wmem),
net/ipv4/tcp_ipv4.c
3382
.sysctl_rmem_offset = offsetof(struct net, ipv4.sysctl_tcp_rmem),
net/ipv4/tcp_ipv4.c
3396
static void __net_exit tcp_sk_exit(struct net *net)
net/ipv4/tcp_ipv4.c
3398
if (net->ipv4.tcp_congestion_control)
net/ipv4/tcp_ipv4.c
3399
bpf_module_put(net->ipv4.tcp_congestion_control,
net/ipv4/tcp_ipv4.c
3400
net->ipv4.tcp_congestion_control->owner);
net/ipv4/tcp_ipv4.c
3403
static void __net_init tcp_set_hashinfo(struct net *net)
net/ipv4/tcp_ipv4.c
3407
struct net *old_net;
net/ipv4/tcp_ipv4.c
3409
if (net_eq(net, &init_net))
net/ipv4/tcp_ipv4.c
3428
net->ipv4.tcp_death_row.hashinfo = hinfo;
net/ipv4/tcp_ipv4.c
3429
net->ipv4.tcp_death_row.sysctl_max_tw_buckets = ehash_entries / 2;
net/ipv4/tcp_ipv4.c
3430
net->ipv4.sysctl_max_syn_backlog = max(128U, ehash_entries / 128);
net/ipv4/tcp_ipv4.c
3433
static int __net_init tcp_sk_init(struct net *net)
net/ipv4/tcp_ipv4.c
3435
net->ipv4.sysctl_tcp_ecn = TCP_ECN_IN_ECN_OUT_NOECN;
net/ipv4/tcp_ipv4.c
3436
net->ipv4.sysctl_tcp_ecn_option = TCP_ACCECN_OPTION_FULL;
net/ipv4/tcp_ipv4.c
3437
net->ipv4.sysctl_tcp_ecn_option_beacon = TCP_ACCECN_OPTION_BEACON;
net/ipv4/tcp_ipv4.c
3438
net->ipv4.sysctl_tcp_ecn_fallback = 1;
net/ipv4/tcp_ipv4.c
3440
net->ipv4.sysctl_tcp_base_mss = TCP_BASE_MSS;
net/ipv4/tcp_ipv4.c
3441
net->ipv4.sysctl_tcp_min_snd_mss = TCP_MIN_SND_MSS;
net/ipv4/tcp_ipv4.c
3442
net->ipv4.sysctl_tcp_probe_threshold = TCP_PROBE_THRESHOLD;
net/ipv4/tcp_ipv4.c
3443
net->ipv4.sysctl_tcp_probe_interval = TCP_PROBE_INTERVAL;
net/ipv4/tcp_ipv4.c
3444
net->ipv4.sysctl_tcp_mtu_probe_floor = TCP_MIN_SND_MSS;
net/ipv4/tcp_ipv4.c
3446
net->ipv4.sysctl_tcp_keepalive_time = TCP_KEEPALIVE_TIME;
net/ipv4/tcp_ipv4.c
3447
net->ipv4.sysctl_tcp_keepalive_probes = TCP_KEEPALIVE_PROBES;
net/ipv4/tcp_ipv4.c
3448
net->ipv4.sysctl_tcp_keepalive_intvl = TCP_KEEPALIVE_INTVL;
net/ipv4/tcp_ipv4.c
3450
net->ipv4.sysctl_tcp_syn_retries = TCP_SYN_RETRIES;
net/ipv4/tcp_ipv4.c
3451
net->ipv4.sysctl_tcp_synack_retries = TCP_SYNACK_RETRIES;
net/ipv4/tcp_ipv4.c
3452
net->ipv4.sysctl_tcp_syncookies = 1;
net/ipv4/tcp_ipv4.c
3453
net->ipv4.sysctl_tcp_reordering = TCP_FASTRETRANS_THRESH;
net/ipv4/tcp_ipv4.c
3454
net->ipv4.sysctl_tcp_retries1 = TCP_RETR1;
net/ipv4/tcp_ipv4.c
3455
net->ipv4.sysctl_tcp_retries2 = TCP_RETR2;
net/ipv4/tcp_ipv4.c
3456
net->ipv4.sysctl_tcp_orphan_retries = 0;
net/ipv4/tcp_ipv4.c
3457
net->ipv4.sysctl_tcp_fin_timeout = TCP_FIN_TIMEOUT;
net/ipv4/tcp_ipv4.c
3458
net->ipv4.sysctl_tcp_notsent_lowat = UINT_MAX;
net/ipv4/tcp_ipv4.c
3459
net->ipv4.sysctl_tcp_tw_reuse = 2;
net/ipv4/tcp_ipv4.c
3460
net->ipv4.sysctl_tcp_tw_reuse_delay = 1 * MSEC_PER_SEC;
net/ipv4/tcp_ipv4.c
3461
net->ipv4.sysctl_tcp_no_ssthresh_metrics_save = 1;
net/ipv4/tcp_ipv4.c
3463
refcount_set(&net->ipv4.tcp_death_row.tw_refcount, 1);
net/ipv4/tcp_ipv4.c
3464
tcp_set_hashinfo(net);
net/ipv4/tcp_ipv4.c
3466
net->ipv4.sysctl_tcp_sack = 1;
net/ipv4/tcp_ipv4.c
3467
net->ipv4.sysctl_tcp_window_scaling = 1;
net/ipv4/tcp_ipv4.c
3468
net->ipv4.sysctl_tcp_timestamps = 1;
net/ipv4/tcp_ipv4.c
3469
net->ipv4.sysctl_tcp_early_retrans = 3;
net/ipv4/tcp_ipv4.c
3470
net->ipv4.sysctl_tcp_recovery = TCP_RACK_LOSS_DETECTION;
net/ipv4/tcp_ipv4.c
3471
net->ipv4.sysctl_tcp_slow_start_after_idle = 1; /* By default, RFC2861 behavior. */
net/ipv4/tcp_ipv4.c
3472
net->ipv4.sysctl_tcp_retrans_collapse = 1;
net/ipv4/tcp_ipv4.c
3473
net->ipv4.sysctl_tcp_max_reordering = 300;
net/ipv4/tcp_ipv4.c
3474
net->ipv4.sysctl_tcp_dsack = 1;
net/ipv4/tcp_ipv4.c
3475
net->ipv4.sysctl_tcp_app_win = 31;
net/ipv4/tcp_ipv4.c
3476
net->ipv4.sysctl_tcp_adv_win_scale = 1;
net/ipv4/tcp_ipv4.c
3477
net->ipv4.sysctl_tcp_frto = 2;
net/ipv4/tcp_ipv4.c
3478
net->ipv4.sysctl_tcp_moderate_rcvbuf = 1;
net/ipv4/tcp_ipv4.c
3479
net->ipv4.sysctl_tcp_rcvbuf_low_rtt = USEC_PER_MSEC;
net/ipv4/tcp_ipv4.c
3484
net->ipv4.sysctl_tcp_tso_win_divisor = 3;
net/ipv4/tcp_ipv4.c
3486
net->ipv4.sysctl_tcp_limit_output_bytes = 4 << 20;
net/ipv4/tcp_ipv4.c
3489
net->ipv4.sysctl_tcp_challenge_ack_limit = INT_MAX;
net/ipv4/tcp_ipv4.c
3491
net->ipv4.sysctl_tcp_min_tso_segs = 2;
net/ipv4/tcp_ipv4.c
3492
net->ipv4.sysctl_tcp_tso_rtt_log = 9; /* 2^9 = 512 usec */
net/ipv4/tcp_ipv4.c
3493
net->ipv4.sysctl_tcp_min_rtt_wlen = 300;
net/ipv4/tcp_ipv4.c
3494
net->ipv4.sysctl_tcp_autocorking = 1;
net/ipv4/tcp_ipv4.c
3495
net->ipv4.sysctl_tcp_invalid_ratelimit = HZ/2;
net/ipv4/tcp_ipv4.c
3496
net->ipv4.sysctl_tcp_pacing_ss_ratio = 200;
net/ipv4/tcp_ipv4.c
3497
net->ipv4.sysctl_tcp_pacing_ca_ratio = 120;
net/ipv4/tcp_ipv4.c
3498
if (net != &init_net) {
net/ipv4/tcp_ipv4.c
3499
memcpy(net->ipv4.sysctl_tcp_rmem,
net/ipv4/tcp_ipv4.c
3502
memcpy(net->ipv4.sysctl_tcp_wmem,
net/ipv4/tcp_ipv4.c
3506
net->ipv4.sysctl_tcp_comp_sack_delay_ns = NSEC_PER_MSEC;
net/ipv4/tcp_ipv4.c
3507
net->ipv4.sysctl_tcp_comp_sack_slack_ns = 10 * NSEC_PER_USEC;
net/ipv4/tcp_ipv4.c
3508
net->ipv4.sysctl_tcp_comp_sack_nr = 44;
net/ipv4/tcp_ipv4.c
3509
net->ipv4.sysctl_tcp_comp_sack_rtt_percent = 33;
net/ipv4/tcp_ipv4.c
3510
net->ipv4.sysctl_tcp_backlog_ack_defer = 1;
net/ipv4/tcp_ipv4.c
3511
net->ipv4.sysctl_tcp_fastopen = TFO_CLIENT_ENABLE;
net/ipv4/tcp_ipv4.c
3512
net->ipv4.sysctl_tcp_fastopen_blackhole_timeout = 0;
net/ipv4/tcp_ipv4.c
3513
atomic_set(&net->ipv4.tfo_active_disable_times, 0);
net/ipv4/tcp_ipv4.c
3516
net->ipv4.sysctl_tcp_plb_enabled = 0; /* Disabled by default */
net/ipv4/tcp_ipv4.c
3517
net->ipv4.sysctl_tcp_plb_idle_rehash_rounds = 3;
net/ipv4/tcp_ipv4.c
3518
net->ipv4.sysctl_tcp_plb_rehash_rounds = 12;
net/ipv4/tcp_ipv4.c
3519
net->ipv4.sysctl_tcp_plb_suspend_rto_sec = 60;
net/ipv4/tcp_ipv4.c
3521
net->ipv4.sysctl_tcp_plb_cong_thresh = (1 << TCP_PLB_SCALE) / 2;
net/ipv4/tcp_ipv4.c
3524
if (!net_eq(net, &init_net) &&
net/ipv4/tcp_ipv4.c
3527
net->ipv4.tcp_congestion_control = init_net.ipv4.tcp_congestion_control;
net/ipv4/tcp_ipv4.c
3529
net->ipv4.tcp_congestion_control = &tcp_reno;
net/ipv4/tcp_ipv4.c
3531
net->ipv4.sysctl_tcp_syn_linear_timeouts = 4;
net/ipv4/tcp_ipv4.c
3532
net->ipv4.sysctl_tcp_shrink_window = 0;
net/ipv4/tcp_ipv4.c
3534
net->ipv4.sysctl_tcp_pingpong_thresh = 1;
net/ipv4/tcp_ipv4.c
3535
net->ipv4.sysctl_tcp_rto_min_us = jiffies_to_usecs(TCP_RTO_MIN);
net/ipv4/tcp_ipv4.c
3536
net->ipv4.sysctl_tcp_rto_max_ms = TCP_RTO_MAX_SEC * MSEC_PER_SEC;
net/ipv4/tcp_ipv4.c
3543
struct net *net;
net/ipv4/tcp_ipv4.c
3557
list_for_each_entry(net, net_exit_list, exit_list) {
net/ipv4/tcp_ipv4.c
3558
inet_pernet_hashinfo_free(net->ipv4.tcp_death_row.hashinfo);
net/ipv4/tcp_ipv4.c
3559
WARN_ON_ONCE(!refcount_dec_and_test(&net->ipv4.tcp_death_row.tw_refcount));
net/ipv4/tcp_ipv4.c
3560
tcp_fastopen_ctx_destroy(net);
net/ipv4/tcp_ipv4.c
417
struct net *net = sock_net(sk);
net/ipv4/tcp_ipv4.c
423
__NET_INC_STATS(net, LINUX_MIB_OUTOFWINDOWICMPS);
net/ipv4/tcp_ipv4.c
495
struct net *net = dev_net_rcu(skb->dev);
net/ipv4/tcp_ipv4.c
504
sk = __inet_lookup_established(net, iph->daddr, th->dest, iph->saddr,
net/ipv4/tcp_ipv4.c
507
__ICMP_INC_STATS(net, ICMP_MIB_INERRORS);
net/ipv4/tcp_ipv4.c
539
__NET_INC_STATS(net, LINUX_MIB_LOCKDROPPEDICMPS);
net/ipv4/tcp_ipv4.c
547
__NET_INC_STATS(net, LINUX_MIB_TCPMINTTLDROP);
net/ipv4/tcp_ipv4.c
558
__NET_INC_STATS(net, LINUX_MIB_OUTOFWINDOWICMPS);
net/ipv4/tcp_ipv4.c
735
struct net *net;
net/ipv4/tcp_ipv4.c
767
net = sk ? sock_net(sk) : skb_dst_dev_net_rcu(skb);
net/ipv4/tcp_ipv4.c
801
sk1 = __inet_lookup_listener(net, NULL, 0, ip_hdr(skb)->saddr,
net/ipv4/tcp_ipv4.c
867
arg.uid = sock_net_uid(net, sk && sk_fullsock(sk) ? sk : NULL);
net/ipv4/tcp_ipv4.c
872
sock_net_set(ctl_sk, net);
net/ipv4/tcp_ipv4.c
894
__TCP_INC_STATS(net, TCP_MIB_OUTSEGS);
net/ipv4/tcp_ipv4.c
895
__TCP_INC_STATS(net, TCP_MIB_OUTRSTS);
net/ipv4/tcp_ipv4.c
920
struct net *net = sock_net(sk);
net/ipv4/tcp_ipv4.c
993
arg.uid = sock_net_uid(net, sk_fullsock(sk) ? sk : NULL);
net/ipv4/tcp_ipv4.c
997
sock_net_set(ctl_sk, net);
net/ipv4/tcp_metrics.c
170
struct net *net;
net/ipv4/tcp_metrics.c
173
net = dst_dev_net_rcu(dst);
net/ipv4/tcp_metrics.c
178
tm = __tcp_get_metrics(saddr, daddr, net, hash);
net/ipv4/tcp_metrics.c
205
WRITE_ONCE(tm->tcpm_net, net);
net/ipv4/tcp_metrics.c
233
struct net *net, unsigned int hash)
net/ipv4/tcp_metrics.c
242
net_eq(tm_net(tm), net))
net/ipv4/tcp_metrics.c
255
struct net *net;
net/ipv4/tcp_metrics.c
26
struct net *net, unsigned int hash);
net/ipv4/tcp_metrics.c
276
net = dst_dev_net_rcu(dst);
net/ipv4/tcp_metrics.c
277
hash ^= net_hash_mix(net);
net/ipv4/tcp_metrics.c
284
net_eq(tm_net(tm), net))
net/ipv4/tcp_metrics.c
298
struct net *net;
net/ipv4/tcp_metrics.c
321
net = dst_dev_net_rcu(dst);
net/ipv4/tcp_metrics.c
322
hash ^= net_hash_mix(net);
net/ipv4/tcp_metrics.c
325
tm = __tcp_get_metrics(&saddr, &daddr, net, hash);
net/ipv4/tcp_metrics.c
345
struct net *net = sock_net(sk);
net/ipv4/tcp_metrics.c
352
if (READ_ONCE(net->ipv4.sysctl_tcp_nometrics_save) || !dst)
net/ipv4/tcp_metrics.c
408
if (!READ_ONCE(net->ipv4.sysctl_tcp_no_ssthresh_metrics_save) &&
net/ipv4/tcp_metrics.c
424
if (!READ_ONCE(net->ipv4.sysctl_tcp_no_ssthresh_metrics_save) &&
net/ipv4/tcp_metrics.c
43
struct net *tcpm_net;
net/ipv4/tcp_metrics.c
441
if (!READ_ONCE(net->ipv4.sysctl_tcp_no_ssthresh_metrics_save) &&
net/ipv4/tcp_metrics.c
452
READ_ONCE(net->ipv4.sysctl_tcp_reordering))
net/ipv4/tcp_metrics.c
468
struct net *net = sock_net(sk);
net/ipv4/tcp_metrics.c
490
val = READ_ONCE(net->ipv4.sysctl_tcp_no_ssthresh_metrics_save) ?
net/ipv4/tcp_metrics.c
54
static inline struct net *tm_net(const struct tcp_metrics_block *tm)
net/ipv4/tcp_metrics.c
770
struct net *net = sock_net(skb->sk);
net/ipv4/tcp_metrics.c
783
if (!net_eq(tm_net(tm), net))
net/ipv4/tcp_metrics.c
848
struct net *net = genl_info_net(info);
net/ipv4/tcp_metrics.c
870
hash ^= net_hash_mix(net);
net/ipv4/tcp_metrics.c
878
net_eq(tm_net(tm), net)) {
net/ipv4/tcp_metrics.c
898
static void tcp_metrics_flush_all(struct net *net)
net/ipv4/tcp_metrics.c
914
match = net ? net_eq(tm_net(tm), net) :
net/ipv4/tcp_metrics.c
935
struct net *net = genl_info_net(info);
net/ipv4/tcp_metrics.c
943
tcp_metrics_flush_all(net);
net/ipv4/tcp_metrics.c
950
hash ^= net_hash_mix(net);
net/ipv4/tcp_metrics.c
958
net_eq(tm_net(tm), net)) {
net/ipv4/tcp_minisocks.c
330
struct net *net = sock_net(sk);
net/ipv4/tcp_minisocks.c
333
tw = inet_twsk_alloc(sk, &net->ipv4.tcp_death_row, state);
net/ipv4/tcp_minisocks.c
383
inet_twsk_hashdance_schedule(tw, sk, net->ipv4.tcp_death_row.hashinfo, timeo);
net/ipv4/tcp_minisocks.c
389
NET_INC_STATS(net, LINUX_MIB_TCPTIMEWAITOVERFLOW);
net/ipv4/tcp_minisocks.c
415
struct net *net;
net/ipv4/tcp_minisocks.c
417
list_for_each_entry(net, net_exit_list, exit_list) {
net/ipv4/tcp_minisocks.c
418
if (net->ipv4.tcp_death_row.hashinfo->pernet) {
net/ipv4/tcp_minisocks.c
420
inet_twsk_purge(net->ipv4.tcp_death_row.hashinfo);
net/ipv4/tcp_offload.c
395
struct net *net;
net/ipv4/tcp_offload.c
409
net = dev_net_rcu(skb->dev);
net/ipv4/tcp_offload.c
410
sk = __inet_lookup_established(net, iph->saddr, th->source,
net/ipv4/tcp_output.c
2046
struct net *net = sock_net(sk);
net/ipv4/tcp_output.c
2048
icsk->icsk_mtup.enabled = READ_ONCE(net->ipv4.sysctl_tcp_mtu_probing) > 1;
net/ipv4/tcp_output.c
2051
icsk->icsk_mtup.search_low = tcp_mss_to_mtu(sk, READ_ONCE(net->ipv4.sysctl_tcp_base_mss));
net/ipv4/tcp_output.c
2569
struct net *net = sock_net(sk);
net/ipv4/tcp_output.c
2573
interval = READ_ONCE(net->ipv4.sysctl_tcp_probe_interval);
net/ipv4/tcp_output.c
2689
struct net *net = sock_net(sk);
net/ipv4/tcp_output.c
2722
interval < READ_ONCE(net->ipv4.sysctl_tcp_probe_threshold)) {
net/ipv4/tcp_output.c
278
struct net *net = sock_net(sk);
net/ipv4/tcp_output.c
303
if (!READ_ONCE(net->ipv4.sysctl_tcp_shrink_window) || !tp->rx_opt.rcv_wscale) {
net/ipv4/tcp_output.c
306
NET_INC_STATS(net, LINUX_MIB_TCPWANTZEROWINDOWADV);
net/ipv4/tcp_output.c
319
READ_ONCE(net->ipv4.sysctl_tcp_workaround_signed_windows))
net/ipv4/tcp_output.c
331
NET_INC_STATS(net, LINUX_MIB_TCPTOZEROWINDOWADV);
net/ipv4/tcp_output.c
3318
struct net *net = sock_net(sk);
net/ipv4/tcp_output.c
333
NET_INC_STATS(net, LINUX_MIB_TCPFROMZEROWINDOWADV);
net/ipv4/tcp_output.c
3344
if (READ_ONCE(net->ipv4.sysctl_tcp_shrink_window) && tp->rx_opt.rcv_wscale)
net/ipv4/tcp_output.c
4608
struct net *net = sock_net(sk);
net/ipv4/tcp_output.c
4624
if (icsk->icsk_backoff < READ_ONCE(net->ipv4.sysctl_tcp_retries2))
net/ipv4/tcp_plb.c
100
pause = READ_ONCE(net->ipv4.sysctl_tcp_plb_suspend_rto_sec) * HZ;
net/ipv4/tcp_plb.c
29
struct net *net = sock_net(sk);
net/ipv4/tcp_plb.c
31
if (!READ_ONCE(net->ipv4.sysctl_tcp_plb_enabled))
net/ipv4/tcp_plb.c
35
if (cong_ratio < READ_ONCE(net->ipv4.sysctl_tcp_plb_cong_thresh))
net/ipv4/tcp_plb.c
38
READ_ONCE(net->ipv4.sysctl_tcp_plb_rehash_rounds))
net/ipv4/tcp_plb.c
49
struct net *net = sock_net(sk);
net/ipv4/tcp_plb.c
53
if (!READ_ONCE(net->ipv4.sysctl_tcp_plb_enabled))
net/ipv4/tcp_plb.c
57
READ_ONCE(net->ipv4.sysctl_tcp_plb_rehash_rounds);
net/ipv4/tcp_plb.c
59
idle_rehash = READ_ONCE(net->ipv4.sysctl_tcp_plb_idle_rehash_rounds) &&
net/ipv4/tcp_plb.c
62
READ_ONCE(net->ipv4.sysctl_tcp_plb_idle_rehash_rounds);
net/ipv4/tcp_plb.c
72
max_suspend = 2 * READ_ONCE(net->ipv4.sysctl_tcp_plb_suspend_rto_sec) * HZ;
net/ipv4/tcp_plb.c
94
struct net *net = sock_net(sk);
net/ipv4/tcp_plb.c
97
if (!READ_ONCE(net->ipv4.sysctl_tcp_plb_enabled))
net/ipv4/tcp_timer.c
168
const struct net *net = sock_net(sk);
net/ipv4/tcp_timer.c
172
if (!READ_ONCE(net->ipv4.sysctl_tcp_mtu_probing))
net/ipv4/tcp_timer.c
180
mss = min(READ_ONCE(net->ipv4.sysctl_tcp_base_mss), mss);
net/ipv4/tcp_timer.c
181
mss = max(mss, READ_ONCE(net->ipv4.sysctl_tcp_mtu_probe_floor));
net/ipv4/tcp_timer.c
182
mss = max(mss, READ_ONCE(net->ipv4.sysctl_tcp_min_snd_mss));
net/ipv4/tcp_timer.c
247
struct net *net = sock_net(sk);
net/ipv4/tcp_timer.c
256
READ_ONCE(net->ipv4.sysctl_tcp_syn_retries);
net/ipv4/tcp_timer.c
260
max_retransmits += READ_ONCE(net->ipv4.sysctl_tcp_syn_linear_timeouts);
net/ipv4/tcp_timer.c
264
if (retransmits_timed_out(sk, READ_ONCE(net->ipv4.sysctl_tcp_retries1), 0)) {
net/ipv4/tcp_timer.c
271
retry_until = READ_ONCE(net->ipv4.sysctl_tcp_retries2);
net/ipv4/tcp_timer.c
538
struct net *net = sock_net(sk);
net/ipv4/tcp_timer.c
668
(tp->thin_lto || READ_ONCE(net->ipv4.sysctl_tcp_thin_linear_timeouts)) &&
net/ipv4/tcp_timer.c
677
READ_ONCE(net->ipv4.sysctl_tcp_syn_linear_timeouts)) {
net/ipv4/tcp_timer.c
686
if (retransmits_timed_out(sk, READ_ONCE(net->ipv4.sysctl_tcp_retries1) + 1, 0))
net/ipv4/tcp_timer.c
753
struct net *net = read_pnet(&inet_rsk(req)->ireq_net);
net/ipv4/tcp_timer.c
755
__NET_INC_STATS(net, LINUX_MIB_TCPTIMEOUTS);
net/ipv4/udp.c
133
static int udp_lib_lport_inuse(struct net *net, __u16 num,
net/ipv4/udp.c
1397
struct net *net = sock_net(sk);
net/ipv4/udp.c
1409
rt = ip_route_output_flow(net, fl4, sk);
net/ipv4/udp.c
1414
IP_INC_STATS(net, IPSTATS_MIB_OUTNOROUTES);
net/ipv4/udp.c
142
if (net_eq(sock_net(sk2), net) &&
net/ipv4/udp.c
169
static int udp_lib_lport_inuse2(struct net *net, __u16 num,
net/ipv4/udp.c
179
if (net_eq(sock_net(sk2), net) &&
net/ipv4/udp.c
1850
struct net *net = sock_net(sk);
net/ipv4/udp.c
1852
__UDP_INC_STATS(net, UDP_MIB_CSUMERRORS);
net/ipv4/udp.c
1853
__UDP_INC_STATS(net, UDP_MIB_INERRORS);
net/ipv4/udp.c
2004
struct net *net = sock_net(sk);
net/ipv4/udp.c
2006
__UDP_INC_STATS(net, UDP_MIB_CSUMERRORS);
net/ipv4/udp.c
2007
__UDP_INC_STATS(net, UDP_MIB_INERRORS);
net/ipv4/udp.c
202
struct net *net = sock_net(sk);
net/ipv4/udp.c
2036
struct net *net = sock_net(sk);
net/ipv4/udp.c
207
if (net_eq(sock_net(sk2), net) &&
net/ipv4/udp.c
2082
UDP_INC_STATS(net, UDP_MIB_INERRORS);
net/ipv4/udp.c
2089
UDP_INC_STATS(net, UDP_MIB_INDATAGRAMS);
net/ipv4/udp.c
2122
UDP_INC_STATS(net, UDP_MIB_CSUMERRORS);
net/ipv4/udp.c
2123
UDP_INC_STATS(net, UDP_MIB_INERRORS);
net/ipv4/udp.c
2199
struct net *net = sock_net(sk);
net/ipv4/udp.c
2203
udptable = net->ipv4.udp_table;
net/ipv4/udp.c
2204
hslot = udp_hashslot(udptable, net, udp_sk(sk)->udp_port_hash);
net/ipv4/udp.c
2213
sock_prot_inuse_add(net, sk->sk_prot, -1);
net/ipv4/udp.c
2233
struct net *net = sock_net(sk);
net/ipv4/udp.c
2236
udptable = net->ipv4.udp_table;
net/ipv4/udp.c
2237
hslot = udp_hashslot(udptable, net, udp_sk(sk)->udp_port_hash);
net/ipv4/udp.c
2321
struct net *net = sock_net(sk);
net/ipv4/udp.c
2326
UDP_INC_STATS(net, UDP_MIB_RCVBUFERRORS);
net/ipv4/udp.c
2329
UDP_INC_STATS(net, UDP_MIB_MEMERRORS);
net/ipv4/udp.c
2332
UDP_INC_STATS(net, UDP_MIB_INERRORS);
net/ipv4/udp.c
235
struct net *net = sock_net(sk);
net/ipv4/udp.c
2353
struct net *net = sock_net(sk);
net/ipv4/udp.c
239
udptable = net->ipv4.udp_table;
net/ipv4/udp.c
2390
__UDP_INC_STATS(net, UDP_MIB_INDATAGRAMS);
net/ipv4/udp.c
2414
__UDP_INC_STATS(net, UDP_MIB_CSUMERRORS);
net/ipv4/udp.c
2416
__UDP_INC_STATS(net, UDP_MIB_INERRORS);
net/ipv4/udp.c
2464
static int __udp4_lib_mcast_deliver(struct net *net, struct sk_buff *skb,
net/ipv4/udp.c
2468
struct udp_table *udptable = net->ipv4.udp_table;
net/ipv4/udp.c
2481
hslot = udp_hashslot(udptable, net, hnum);
net/ipv4/udp.c
2486
hash2_any = ipv4_portaddr_hash(net, htonl(INADDR_ANY), hnum) &
net/ipv4/udp.c
2488
hash2 = ipv4_portaddr_hash(net, daddr, hnum) & udptable->mask;
net/ipv4/udp.c
2495
if (!__udp_is_mcast_sock(net, sk, uh->dest, daddr,
net/ipv4/udp.c
2507
__UDP_INC_STATS(net, UDP_MIB_RCVBUFERRORS);
net/ipv4/udp.c
2508
__UDP_INC_STATS(net, UDP_MIB_INERRORS);
net/ipv4/udp.c
2526
__UDP_INC_STATS(net, UDP_MIB_IGNOREDMULTI);
net/ipv4/udp.c
258
hslot = udp_hashslot(udptable, net, first);
net/ipv4/udp.c
2591
struct net *net = dev_net(skb->dev);
net/ipv4/udp.c
261
udp_lib_lport_inuse(net, snum, hslot, bitmap, sk,
net/ipv4/udp.c
2628
sk = inet_steal_sock(net, skb, sizeof(struct udphdr), saddr, uh->source, daddr, uh->dest,
net/ipv4/udp.c
2647
return __udp4_lib_mcast_deliver(net, skb, uh, saddr, daddr);
net/ipv4/udp.c
2662
__UDP_INC_STATS(net, UDP_MIB_NOPORTS);
net/ipv4/udp.c
2689
__UDP_INC_STATS(net, UDP_MIB_CSUMERRORS);
net/ipv4/udp.c
2691
__UDP_INC_STATS(net, UDP_MIB_INERRORS);
net/ipv4/udp.c
2699
static struct sock *__udp4_lib_mcast_demux_lookup(struct net *net,
net/ipv4/udp.c
2704
struct udp_table *udptable = net->ipv4.udp_table;
net/ipv4/udp.c
2710
slot = udp_hashfn(net, hnum, udptable->mask);
net/ipv4/udp.c
2719
if (__udp_is_mcast_sock(net, sk, loc_port, loc_addr,
net/ipv4/udp.c
273
!inet_is_local_reserved_port(net, snum))
net/ipv4/udp.c
2734
static struct sock *__udp4_lib_demux_lookup(struct net *net,
net/ipv4/udp.c
2739
struct udp_table *udptable = net->ipv4.udp_table;
net/ipv4/udp.c
2747
hash2 = ipv4_portaddr_hash(net, loc_addr, hnum);
net/ipv4/udp.c
2752
if (inet_match(net, sk, acookie, ports, dif, sdif))
net/ipv4/udp.c
2762
struct net *net = dev_net(skb->dev);
net/ipv4/udp.c
2790
sk = __udp4_lib_mcast_demux_lookup(net, uh->dest, iph->daddr,
net/ipv4/udp.c
2794
sk = __udp4_lib_demux_lookup(net, uh->dest, iph->daddr,
net/ipv4/udp.c
282
hslot = udp_hashslot(udptable, net, snum);
net/ipv4/udp.c
295
exist = udp_lib_lport_inuse2(net, snum, hslot2, sk);
net/ipv4/udp.c
298
exist = udp_lib_lport_inuse2(net, snum, hslot2,
net/ipv4/udp.c
307
if (udp_lib_lport_inuse(net, snum, hslot, NULL, sk, 0))
net/ipv4/udp.c
3138
.sysctl_wmem_offset = offsetof(struct net, ipv4.sysctl_udp_wmem_min),
net/ipv4/udp.c
3139
.sysctl_rmem_offset = offsetof(struct net, ipv4.sysctl_udp_rmem_min),
net/ipv4/udp.c
3165
struct net *net = seq_file_net(seq);
net/ipv4/udp.c
3169
udptable = net->ipv4.udp_table;
net/ipv4/udp.c
3193
struct net *net = seq_file_net(seq);
net/ipv4/udp.c
3201
udptable = net->ipv4.udp_table;
net/ipv4/udp.c
3336
struct net *net = seq_file_net(seq);
net/ipv4/udp.c
3350
udptable = net->ipv4.udp_table;
net/ipv4/udp.c
3590
static int __net_init udp4_proc_init_net(struct net *net)
net/ipv4/udp.c
3592
if (!proc_create_net_data("udp", 0444, net->proc_net, &udp_seq_ops,
net/ipv4/udp.c
3598
static void __net_exit udp4_proc_exit_net(struct net *net)
net/ipv4/udp.c
3600
remove_proc_entry("udp", net->proc_net);
net/ipv4/udp.c
362
compute_score(struct sock *sk, const struct net *net,
net/ipv4/udp.c
3677
static void __net_init udp_sysctl_init(struct net *net)
net/ipv4/udp.c
3679
net->ipv4.sysctl_udp_rmem_min = PAGE_SIZE;
net/ipv4/udp.c
3680
net->ipv4.sysctl_udp_wmem_min = PAGE_SIZE;
net/ipv4/udp.c
3683
net->ipv4.sysctl_udp_l3mdev_accept = 0;
net/ipv4/udp.c
370
if (!net_eq(sock_net(sk), net) ||
net/ipv4/udp.c
3727
static void __net_exit udp_pernet_table_free(struct net *net)
net/ipv4/udp.c
3729
struct udp_table *udptable = net->ipv4.udp_table;
net/ipv4/udp.c
3738
static void __net_init udp_set_table(struct net *net)
net/ipv4/udp.c
3742
struct net *old_net;
net/ipv4/udp.c
3744
if (net_eq(net, &init_net))
net/ipv4/udp.c
3760
net->ipv4.udp_table = udptable;
net/ipv4/udp.c
3766
net->ipv4.udp_table = &udp_table;
net/ipv4/udp.c
3770
static int __net_init udp_pernet_init(struct net *net)
net/ipv4/udp.c
3776
for (i = 0; i < ARRAY_SIZE(net->ipv4.udp_tunnel_gro); ++i) {
net/ipv4/udp.c
3777
INIT_HLIST_HEAD(&net->ipv4.udp_tunnel_gro[i].list);
net/ipv4/udp.c
3778
RCU_INIT_POINTER(net->ipv4.udp_tunnel_gro[i].sk, NULL);
net/ipv4/udp.c
3781
udp_sysctl_init(net);
net/ipv4/udp.c
3782
udp_set_table(net);
net/ipv4/udp.c
3787
static void __net_exit udp_pernet_exit(struct net *net)
net/ipv4/udp.c
3789
udp_pernet_table_free(net);
net/ipv4/udp.c
393
dev_match = udp_sk_bound_dev_eq(net, sk->sk_bound_dev_if,
net/ipv4/udp.c
405
u32 udp_ehashfn(const struct net *net, const __be32 laddr, const __u16 lport,
net/ipv4/udp.c
411
udp_ehash_secret + net_hash_mix(net));
net/ipv4/udp.c
434
static struct sock *udp4_lib_lookup1(const struct net *net,
net/ipv4/udp.c
440
unsigned int slot = udp_hashfn(net, hnum, udptable->mask);
net/ipv4/udp.c
446
score = compute_score(sk, net,
net/ipv4/udp.c
458
static struct sock *udp4_lib_lookup2(const struct net *net,
net/ipv4/udp.c
474
score = compute_score(need_rescore ? result : sk, net, saddr,
net/ipv4/udp.c
487
result = inet_lookup_reuseport(net, sk, skb, sizeof(struct udphdr),
net/ipv4/udp.c
516
static struct sock *udp4_lib_lookup4(const struct net *net,
net/ipv4/udp.c
534
static struct sock *udp4_lib_lookup4(const struct net *net,
net/ipv4/udp.c
547
hash4 = udp_ehashfn(net, daddr, hnum, saddr, sport);
net/ipv4/udp.c
556
if (inet_match(net, sk, acookie, ports, dif, sdif))
net/ipv4/udp.c
616
struct net *net = sock_net(sk);
net/ipv4/udp.c
625
udptable = net->ipv4.udp_table;
net/ipv4/udp.c
626
hslot = udp_hashslot(udptable, net, udp_sk(sk)->udp_port_hash);
net/ipv4/udp.c
651
struct net *net = sock_net(sk);
net/ipv4/udp.c
657
hash = udp_ehashfn(net, sk->sk_rcv_saddr, sk->sk_num,
net/ipv4/udp.c
667
struct sock *__udp4_lib_lookup(const struct net *net, __be32 saddr,
net/ipv4/udp.c
671
struct udp_table *udptable = net->ipv4.udp_table;
net/ipv4/udp.c
677
hash2 = ipv4_portaddr_hash(net, daddr, hnum);
net/ipv4/udp.c
681
result = udp4_lib_lookup4(net, saddr, sport, daddr, hnum,
net/ipv4/udp.c
688
result = udp4_lib_lookup2(net, saddr, sport,
net/ipv4/udp.c
696
sk = inet_lookup_run_sk_lookup(net, IPPROTO_UDP, skb, sizeof(struct udphdr),
net/ipv4/udp.c
710
hash2 = ipv4_portaddr_hash(net, htonl(INADDR_ANY), hnum);
net/ipv4/udp.c
713
result = udp4_lib_lookup2(net, saddr, sport,
net/ipv4/udp.c
726
result = udp4_lib_lookup1(net, saddr, sport, daddr, hnum, dif, sdif,
net/ipv4/udp.c
763
struct sock *udp4_lib_lookup(const struct net *net, __be32 saddr, __be16 sport,
net/ipv4/udp.c
768
sk = __udp4_lib_lookup(net, saddr, sport, daddr, dport, dif, 0, NULL);
net/ipv4/udp.c
776
static inline bool __udp_is_mcast_sock(struct net *net, const struct sock *sk,
net/ipv4/udp.c
783
if (!net_eq(sock_net(sk), net) ||
net/ipv4/udp.c
789
!udp_sk_bound_dev_eq(net, sk->sk_bound_dev_if, dif, sdif))
net/ipv4/udp.c
853
static struct sock *__udp4_lib_err_encap(struct net *net,
net/ipv4/udp.c
882
sk = __udp4_lib_lookup(net, iph->daddr, uh->source,
net/ipv4/udp.c
917
struct net *net = dev_net(skb->dev);
net/ipv4/udp.c
926
sk = __udp4_lib_lookup(net, iph->daddr, uh->dest,
net/ipv4/udp.c
933
sk = __udp4_lib_err_encap(net, iph, uh, sk, skb, info);
net/ipv4/udp.c
940
__ICMP_INC_STATS(net, ICMP_MIB_INERRORS);
net/ipv4/udp_diag.c
114
if (!net_eq(sock_net(sk), net))
net/ipv4/udp_diag.c
155
struct net *net = sock_net(in_skb->sk);
net/ipv4/udp_diag.c
162
sk = __udp4_lib_lookup(net,
net/ipv4/udp_diag.c
170
sk = __udp4_lib_lookup(net,
net/ipv4/udp_diag.c
175
sk = __udp6_lib_lookup(net,
net/ipv4/udp_diag.c
33
struct net *net;
net/ipv4/udp_diag.c
36
net = sock_net(in_skb->sk);
net/ipv4/udp_diag.c
41
sk = __udp4_lib_lookup(net,
net/ipv4/udp_diag.c
47
sk = __udp6_lib_lookup(net,
net/ipv4/udp_diag.c
80
err = nlmsg_unicast(net->diag_nlsk, rep, NETLINK_CB(in_skb).portid);
net/ipv4/udp_diag.c
93
struct net *net = sock_net(skb->sk);
net/ipv4/udp_diag.c
97
table = net->ipv4.udp_table;
net/ipv4/udp_offload.c
52
void udp_tunnel_update_gro_lookup(struct net *net, struct sock *sk, bool add)
net/ipv4/udp_offload.c
59
udp_tunnel_gro = &net->ipv4.udp_tunnel_gro[is_ipv6];
net/ipv4/udp_offload.c
852
struct net *net = dev_net_rcu(skb->dev);
net/ipv4/udp_offload.c
856
sk = udp_tunnel_sk(net, false);
net/ipv4/udp_offload.c
862
return __udp4_lib_lookup(net, iph->saddr, sport,
net/ipv4/udp_tunnel_core.c
12
int udp_sock_create4(struct net *net, struct udp_port_cfg *cfg,
net/ipv4/udp_tunnel_core.c
129
struct net *net = sock_net(sk);
net/ipv4/udp_tunnel_core.c
139
for_each_netdev(net, dev) {
net/ipv4/udp_tunnel_core.c
150
struct net *net = sock_net(sk);
net/ipv4/udp_tunnel_core.c
160
for_each_netdev(net, dev) {
net/ipv4/udp_tunnel_core.c
19
err = sock_create_kern(net, AF_INET, SOCK_DGRAM, 0, &sock);
net/ipv4/udp_tunnel_core.c
227
struct net *net, int oif,
net/ipv4/udp_tunnel_core.c
255
rt = ip_route_output_key(net, &fl4);
net/ipv4/udp_tunnel_core.c
71
void setup_udp_tunnel_sock(struct net *net, struct sock *sk,
net/ipv4/udp_tunnel_core.c
96
udp_tunnel_update_gro_lookup(net, sk, true);
net/ipv4/xfrm4_input.c
23
static int xfrm4_rcv_encap_finish2(struct net *net, struct sock *sk,
net/ipv4/xfrm4_input.c
29
static inline int xfrm4_rcv_encap_finish(struct net *net, struct sock *sk,
net/ipv4/xfrm4_output.c
17
static int __xfrm4_output(struct net *net, struct sock *sk, struct sk_buff *skb)
net/ipv4/xfrm4_output.c
24
return dst_output(net, sk, skb);
net/ipv4/xfrm4_output.c
31
int xfrm4_output(struct net *net, struct sock *sk, struct sk_buff *skb)
net/ipv4/xfrm4_output.c
34
net, sk, skb, skb->dev, skb_dst_dev(skb),
net/ipv4/xfrm4_policy.c
154
static __net_init int xfrm4_net_sysctl_init(struct net *net)
net/ipv4/xfrm4_policy.c
160
if (!net_eq(net, &init_net)) {
net/ipv4/xfrm4_policy.c
165
table[0].data = &net->xfrm.xfrm4_dst_ops.gc_thresh;
net/ipv4/xfrm4_policy.c
168
hdr = register_net_sysctl_sz(net, "net/ipv4", table,
net/ipv4/xfrm4_policy.c
173
net->ipv4.xfrm4_hdr = hdr;
net/ipv4/xfrm4_policy.c
177
if (!net_eq(net, &init_net))
net/ipv4/xfrm4_policy.c
183
static __net_exit void xfrm4_net_sysctl_exit(struct net *net)
net/ipv4/xfrm4_policy.c
187
if (!net->ipv4.xfrm4_hdr)
net/ipv4/xfrm4_policy.c
190
table = net->ipv4.xfrm4_hdr->ctl_table_arg;
net/ipv4/xfrm4_policy.c
191
unregister_net_sysctl_table(net->ipv4.xfrm4_hdr);
net/ipv4/xfrm4_policy.c
192
if (!net_eq(net, &init_net))
net/ipv4/xfrm4_policy.c
196
static inline int xfrm4_net_sysctl_init(struct net *net)
net/ipv4/xfrm4_policy.c
201
static inline void xfrm4_net_sysctl_exit(struct net *net)
net/ipv4/xfrm4_policy.c
206
static int __net_init xfrm4_net_init(struct net *net)
net/ipv4/xfrm4_policy.c
210
memcpy(&net->xfrm.xfrm4_dst_ops, &xfrm4_dst_ops_template,
net/ipv4/xfrm4_policy.c
212
ret = dst_entries_init(&net->xfrm.xfrm4_dst_ops);
net/ipv4/xfrm4_policy.c
216
ret = xfrm4_net_sysctl_init(net);
net/ipv4/xfrm4_policy.c
218
dst_entries_destroy(&net->xfrm.xfrm4_dst_ops);
net/ipv4/xfrm4_policy.c
223
static void __net_exit xfrm4_net_exit(struct net *net)
net/ipv4/xfrm4_policy.c
225
xfrm4_net_sysctl_exit(net);
net/ipv4/xfrm4_policy.c
226
dst_entries_destroy(&net->xfrm.xfrm4_dst_ops);
net/ipv4/xfrm4_policy.c
29
fl4->flowi4_l3mdev = l3mdev_master_ifindex_by_index(params->net,
net/ipv4/xfrm4_policy.c
37
rt = __ip_route_output_key(params->net, fl4);
net/ipv6/addrconf.c
1029
static u32 inet6_addr_hash(const struct net *net, const struct in6_addr *addr)
net/ipv6/addrconf.c
1031
u32 val = __ipv6_addr_jhash(addr, net_hash_mix(net));
net/ipv6/addrconf.c
1036
static bool ipv6_chk_same_addr(struct net *net, const struct in6_addr *addr,
net/ipv6/addrconf.c
1041
hlist_for_each_entry(ifp, &net->ipv6.inet6_addr_lst[hash], addr_lst) {
net/ipv6/addrconf.c
1052
struct net *net = dev_net(dev);
net/ipv6/addrconf.c
1053
unsigned int hash = inet6_addr_hash(net, &ifa->addr);
net/ipv6/addrconf.c
1056
spin_lock_bh(&net->ipv6.addrconf_hash_lock);
net/ipv6/addrconf.c
1059
if (ipv6_chk_same_addr(net, &ifa->addr, dev, hash)) {
net/ipv6/addrconf.c
1063
hlist_add_head_rcu(&ifa->addr_lst, &net->ipv6.inet6_addr_lst[hash]);
net/ipv6/addrconf.c
1066
spin_unlock_bh(&net->ipv6.addrconf_hash_lock);
net/ipv6/addrconf.c
1079
struct net *net = dev_net(idev->dev);
net/ipv6/addrconf.c
1132
f6i = addrconf_f6i_alloc(net, idev, cfg->pfx, false, gfp_flags, extack);
net/ipv6/addrconf.c
1275
struct net *net = dev_net(ifp->idev->dev);
net/ipv6/addrconf.c
1284
ip6_del_rt(net, f6i, false);
net/ipv6/addrconf.c
1286
if (f6i != net->ipv6.fib6_null_entry &&
net/ipv6/addrconf.c
1307
struct net *net = dev_net(ifp->idev->dev);
net/ipv6/addrconf.c
1321
spin_lock_bh(&net->ipv6.addrconf_hash_lock);
net/ipv6/addrconf.c
1323
spin_unlock_bh(&net->ipv6.addrconf_hash_lock);
net/ipv6/addrconf.c
151
static void addrconf_verify(struct net *net);
net/ipv6/addrconf.c
152
static void addrconf_verify_rtnl(struct net *net);
net/ipv6/addrconf.c
1559
static bool ipv6_use_optimistic_addr(const struct net *net,
net/ipv6/addrconf.c
1565
if (!READ_ONCE(net->ipv6.devconf_all->optimistic_dad) &&
net/ipv6/addrconf.c
1568
if (!READ_ONCE(net->ipv6.devconf_all->use_optimistic) &&
net/ipv6/addrconf.c
1578
static bool ipv6_allow_optimistic_dad(const struct net *net,
net/ipv6/addrconf.c
1584
if (!READ_ONCE(net->ipv6.devconf_all->optimistic_dad) &&
net/ipv6/addrconf.c
1594
static int ipv6_get_saddr_eval(struct net *net,
net/ipv6/addrconf.c
1658
if (!ipv6_use_optimistic_addr(net, score->ifa->idev))
net/ipv6/addrconf.c
1680
ret = ipv6_addr_label(net,
net/ipv6/addrconf.c
1728
static int __ipv6_dev_get_saddr(struct net *net,
net/ipv6/addrconf.c
1768
minihiscore = ipv6_get_saddr_eval(net, hiscore, dst, i);
net/ipv6/addrconf.c
1769
miniscore = ipv6_get_saddr_eval(net, score, dst, i);
net/ipv6/addrconf.c
1800
static int ipv6_get_saddr_master(struct net *net,
net/ipv6/addrconf.c
1811
hiscore_idx = __ipv6_dev_get_saddr(net, dst, idev,
net/ipv6/addrconf.c
1816
hiscore_idx = __ipv6_dev_get_saddr(net, dst, idev,
net/ipv6/addrconf.c
1822
int ipv6_dev_get_saddr(struct net *net, const struct net_device *dst_dev,
net/ipv6/addrconf.c
1839
dst.label = ipv6_addr_label(net, daddr, dst_type, dst.ifindex);
net/ipv6/addrconf.c
1874
hiscore_idx = __ipv6_dev_get_saddr(net, &dst, idev, scores, hiscore_idx);
net/ipv6/addrconf.c
1887
hiscore_idx = ipv6_get_saddr_master(net, dst_dev,
net/ipv6/addrconf.c
1896
for_each_netdev_rcu(net, dev) {
net/ipv6/addrconf.c
1905
hiscore_idx = __ipv6_dev_get_saddr(net, &dst, idev, scores, hiscore_idx);
net/ipv6/addrconf.c
1969
int ipv6_chk_addr(struct net *net, const struct in6_addr *addr,
net/ipv6/addrconf.c
1972
return ipv6_chk_addr_and_flags(net, addr, dev, !dev,
net/ipv6/addrconf.c
1987
__ipv6_chk_addr_and_flags(struct net *net, const struct in6_addr *addr,
net/ipv6/addrconf.c
1991
unsigned int hash = inet6_addr_hash(net, addr);
net/ipv6/addrconf.c
2002
hlist_for_each_entry_rcu(ifp, &net->ipv6.inet6_addr_lst[hash], addr_lst) {
net/ipv6/addrconf.c
2027
int ipv6_chk_addr_and_flags(struct net *net, const struct in6_addr *addr,
net/ipv6/addrconf.c
2031
return __ipv6_chk_addr_and_flags(net, addr, dev, skip_dev_check,
net/ipv6/addrconf.c
2092
struct net_device *ipv6_dev_find(struct net *net, const struct in6_addr *addr,
net/ipv6/addrconf.c
2095
return __ipv6_chk_addr_and_flags(net, addr, dev, !dev, 1,
net/ipv6/addrconf.c
2100
struct inet6_ifaddr *ipv6_get_ifaddr(struct net *net, const struct in6_addr *addr,
net/ipv6/addrconf.c
2103
unsigned int hash = inet6_addr_hash(net, addr);
net/ipv6/addrconf.c
2107
hlist_for_each_entry_rcu(ifp, &net->ipv6.inet6_addr_lst[hash], addr_lst) {
net/ipv6/addrconf.c
2175
struct net *net = dev_net(idev->dev);
net/ipv6/addrconf.c
2203
if (retries > net->ipv6.sysctl.idgen_retries) {
net/ipv6/addrconf.c
2233
addrconf_mod_dad_work(ifp2, net->ipv6.sysctl.idgen_delay);
net/ipv6/addrconf.c
2695
int addrconf_prefix_rcv_add_addr(struct net *net, struct net_device *dev,
net/ipv6/addrconf.c
2702
struct inet6_ifaddr *ifp = ipv6_get_ifaddr(net, addr, dev, 1);
net/ipv6/addrconf.c
2718
if ((READ_ONCE(net->ipv6.devconf_all->optimistic_dad) ||
net/ipv6/addrconf.c
2720
!net->ipv6.devconf_all->forwarding && sllao)
net/ipv6/addrconf.c
2791
addrconf_verify(net);
net/ipv6/addrconf.c
2807
struct net *net = dev_net(dev);
net/ipv6/addrconf.c
2877
ip6_del_rt(net, rt, false);
net/ipv6/addrconf.c
2889
fib6_may_remove_gc_list(net, rt);
net/ipv6/addrconf.c
2943
err = addrconf_prefix_rcv_add_addr(net, dev, pinfo, in6_dev,
net/ipv6/addrconf.c
2954
ndisc_ops_prefix_rcv_add_addr(net, dev, pinfo, in6_dev, &addr,
net/ipv6/addrconf.c
2965
static int addrconf_set_sit_dstaddr(struct net *net, struct net_device *dev,
net/ipv6/addrconf.c
2986
dev = __dev_get_by_name(net, p.name);
net/ipv6/addrconf.c
2997
int addrconf_set_dstaddr(struct net *net, void __user *arg)
net/ipv6/addrconf.c
3008
rtnl_net_lock(net);
net/ipv6/addrconf.c
3009
dev = __dev_get_by_index(net, ireq.ifr6_ifindex);
net/ipv6/addrconf.c
3011
err = addrconf_set_sit_dstaddr(net, dev, &ireq);
net/ipv6/addrconf.c
3012
rtnl_net_unlock(net);
net/ipv6/addrconf.c
3036
static int inet6_addr_add(struct net *net, struct net_device *dev,
net/ipv6/addrconf.c
3043
ASSERT_RTNL_NET(net);
net/ipv6/addrconf.c
3062
int ret = ipv6_mc_config(net->ipv6.mc_autojoin_sk,
net/ipv6/addrconf.c
3096
addrconf_verify_rtnl(net);
net/ipv6/addrconf.c
3099
ipv6_mc_config(net->ipv6.mc_autojoin_sk, false,
net/ipv6/addrconf.c
3106
static int inet6_addr_del(struct net *net, int ifindex, u32 ifa_flags,
net/ipv6/addrconf.c
3119
dev = __dev_get_by_index(net, ifindex);
net/ipv6/addrconf.c
3144
addrconf_verify_rtnl(net);
net/ipv6/addrconf.c
3146
ipv6_mc_config(net->ipv6.mc_autojoin_sk,
net/ipv6/addrconf.c
3159
int addrconf_add_ifaddr(struct net *net, void __user *arg)
net/ipv6/addrconf.c
3170
if (!ns_capable(net->user_ns, CAP_NET_ADMIN))
net/ipv6/addrconf.c
3179
rtnl_net_lock(net);
net/ipv6/addrconf.c
3180
dev = __dev_get_by_index(net, ireq.ifr6_ifindex);
net/ipv6/addrconf.c
3183
err = inet6_addr_add(net, dev, &cfg, 0, 0, NULL);
net/ipv6/addrconf.c
3188
rtnl_net_unlock(net);
net/ipv6/addrconf.c
3192
int addrconf_del_ifaddr(struct net *net, void __user *arg)
net/ipv6/addrconf.c
3197
if (!ns_capable(net->user_ns, CAP_NET_ADMIN))
net/ipv6/addrconf.c
3203
rtnl_net_lock(net);
net/ipv6/addrconf.c
3204
err = inet6_addr_del(net, ireq.ifr6_ifindex, 0, &ireq.ifr6_addr,
net/ipv6/addrconf.c
3206
rtnl_net_unlock(net);
net/ipv6/addrconf.c
3240
struct net *net = dev_net(idev->dev);
net/ipv6/addrconf.c
3269
for_each_netdev(net, dev) {
net/ipv6/addrconf.c
3379
struct net *net = dev_net(idev->dev);
net/ipv6/addrconf.c
3385
else if (net->ipv6.devconf_dflt->stable_secret.initialized)
net/ipv6/addrconf.c
3386
secret = net->ipv6.devconf_dflt->stable_secret.secret;
net/ipv6/addrconf.c
3600
static int fixup_permanent_addr(struct net *net,
net/ipv6/addrconf.c
3611
f6i = addrconf_f6i_alloc(net, idev, &ifp->addr, false,
net/ipv6/addrconf.c
3637
static void addrconf_permanent_addr(struct net *net, struct net_device *dev)
net/ipv6/addrconf.c
3662
if (fixup_permanent_addr(net, idev, ifp) < 0) {
net/ipv6/addrconf.c
3678
struct net *net = dev_net(dev);
net/ipv6/addrconf.c
3694
addrconf_ifdown(dev, dev != net->loopback_dev);
net/ipv6/addrconf.c
3729
addrconf_permanent_addr(net, dev);
net/ipv6/addrconf.c
3802
addrconf_ifdown(dev, dev != net->loopback_dev);
net/ipv6/addrconf.c
3878
struct net *net = dev_net(dev);
net/ipv6/addrconf.c
3914
int _keep_addr = READ_ONCE(net->ipv6.devconf_all->keep_addr_on_down);
net/ipv6/addrconf.c
3924
struct hlist_head *h = &net->ipv6.inet6_addr_lst[i];
net/ipv6/addrconf.c
3926
spin_lock_bh(&net->ipv6.addrconf_hash_lock);
net/ipv6/addrconf.c
3942
spin_unlock_bh(&net->ipv6.addrconf_hash_lock);
net/ipv6/addrconf.c
4009
ip6_del_rt(net, rt, false);
net/ipv6/addrconf.c
4132
struct net *net;
net/ipv6/addrconf.c
4141
net = dev_net(dev);
net/ipv6/addrconf.c
4143
(READ_ONCE(net->ipv6.devconf_all->accept_dad) < 1 &&
net/ipv6/addrconf.c
4179
ip6_ins_rt(net, ifp->rt);
net/ipv6/addrconf.c
4180
if (ipv6_use_optimistic_addr(net, idev)) {
net/ipv6/addrconf.c
4219
struct net *net;
net/ipv6/addrconf.c
4227
net = dev_net(idev->dev);
net/ipv6/addrconf.c
4229
rtnl_net_lock(net);
net/ipv6/addrconf.c
4239
if ((READ_ONCE(net->ipv6.devconf_all->accept_dad) > 1 ||
net/ipv6/addrconf.c
4321
rtnl_net_unlock(net);
net/ipv6/addrconf.c
4446
struct net *net = seq_file_net(seq);
net/ipv6/addrconf.c
4457
hlist_for_each_entry_rcu(ifa, &net->ipv6.inet6_addr_lst[state->bucket],
net/ipv6/addrconf.c
4478
struct net *net = seq_file_net(seq);
net/ipv6/addrconf.c
4488
&net->ipv6.inet6_addr_lst[state->bucket], addr_lst) {
net/ipv6/addrconf.c
4538
static int __net_init if6_proc_net_init(struct net *net)
net/ipv6/addrconf.c
4540
if (!proc_create_net("if_inet6", 0444, net->proc_net, &if6_seq_ops,
net/ipv6/addrconf.c
4546
static void __net_exit if6_proc_net_exit(struct net *net)
net/ipv6/addrconf.c
4548
remove_proc_entry("if_inet6", net->proc_net);
net/ipv6/addrconf.c
4569
int ipv6_chk_home_addr(struct net *net, const struct in6_addr *addr)
net/ipv6/addrconf.c
4571
unsigned int hash = inet6_addr_hash(net, addr);
net/ipv6/addrconf.c
4576
hlist_for_each_entry_rcu(ifp, &net->ipv6.inet6_addr_lst[hash], addr_lst) {
net/ipv6/addrconf.c
4598
int ipv6_chk_rpl_srh_loop(struct net *net, const struct in6_addr *segs,
net/ipv6/addrconf.c
4611
hash = inet6_addr_hash(net, addr);
net/ipv6/addrconf.c
4614
hlist_for_each_entry_rcu(ifp, &net->ipv6.inet6_addr_lst[hash], addr_lst) {
net/ipv6/addrconf.c
4643
static void addrconf_verify_rtnl(struct net *net)
net/ipv6/addrconf.c
4655
cancel_delayed_work(&net->ipv6.addr_chk_work);
net/ipv6/addrconf.c
4659
hlist_for_each_entry_rcu_bh(ifp, &net->ipv6.inet6_addr_lst[i], addr_lst) {
net/ipv6/addrconf.c
4760
mod_delayed_work(addrconf_wq, &net->ipv6.addr_chk_work, next_sched - now);
net/ipv6/addrconf.c
4766
struct net *net = container_of(to_delayed_work(w), struct net,
net/ipv6/addrconf.c
4769
rtnl_net_lock(net);
net/ipv6/addrconf.c
4770
addrconf_verify_rtnl(net);
net/ipv6/addrconf.c
4771
rtnl_net_unlock(net);
net/ipv6/addrconf.c
4774
static void addrconf_verify(struct net *net)
net/ipv6/addrconf.c
4776
mod_delayed_work(addrconf_wq, &net->ipv6.addr_chk_work, 0);
net/ipv6/addrconf.c
4812
struct net *net = sock_net(skb->sk);
net/ipv6/addrconf.c
4834
rtnl_net_lock(net);
net/ipv6/addrconf.c
4835
err = inet6_addr_del(net, ifm->ifa_index, ifa_flags, pfx,
net/ipv6/addrconf.c
4837
rtnl_net_unlock(net);
net/ipv6/addrconf.c
4842
static int modify_prefix_route(struct net *net, struct inet6_ifaddr *ifp,
net/ipv6/addrconf.c
4868
if (f6i != net->ipv6.fib6_null_entry) {
net/ipv6/addrconf.c
4874
fib6_may_remove_gc_list(net, f6i);
net/ipv6/addrconf.c
4887
static int inet6_addr_modify(struct net *net, struct inet6_ifaddr *ifp,
net/ipv6/addrconf.c
4895
ASSERT_RTNL_NET(net);
net/ipv6/addrconf.c
4938
rc = modify_prefix_route(net, ifp, expires, flags, false);
net/ipv6/addrconf.c
4948
rc = modify_prefix_route(net, ifp, expires, flags, true);
net/ipv6/addrconf.c
4978
addrconf_verify_rtnl(net);
net/ipv6/addrconf.c
4987
struct net *net = sock_net(skb->sk);
net/ipv6/addrconf.c
5062
rtnl_net_lock(net);
net/ipv6/addrconf.c
5064
dev = __dev_get_by_index(net, ifm->ifa_index);
net/ipv6/addrconf.c
5078
if (!ipv6_allow_optimistic_dad(net, idev))
net/ipv6/addrconf.c
5088
ifa = ipv6_get_ifaddr(net, cfg.pfx, dev, 1);
net/ipv6/addrconf.c
5094
err = inet6_addr_add(net, dev, &cfg, expires, flags, extack);
net/ipv6/addrconf.c
5103
err = inet6_addr_modify(net, ifa, &cfg, expires, flags);
net/ipv6/addrconf.c
5110
rtnl_net_unlock(net);
net/ipv6/addrconf.c
5375
struct net **tgt_net, struct sock *sk,
net/ipv6/addrconf.c
5410
struct net *net;
net/ipv6/addrconf.c
5413
net = rtnl_get_net_ns_capable(sk, fillargs->netnsid);
net/ipv6/addrconf.c
5414
if (IS_ERR(net)) {
net/ipv6/addrconf.c
5417
return PTR_ERR(net);
net/ipv6/addrconf.c
5419
*tgt_net = net;
net/ipv6/addrconf.c
5432
struct net *tgt_net = sock_net(skb->sk);
net/ipv6/addrconf.c
5562
struct net *tgt_net = sock_net(in_skb->sk);
net/ipv6/addrconf.c
5634
struct net *net = dev_net(ifa->idev->dev);
net/ipv6/addrconf.c
5656
rtnl_notify(skb, net, 0, RTNLGRP_IPV6_IFADDR, NULL, GFP_ATOMIC);
net/ipv6/addrconf.c
5659
rtnl_set_sk_err(net, RTNLGRP_IPV6_IFADDR, err);
net/ipv6/addrconf.c
587
void inet6_netconf_notify_devconf(struct net *net, int event, int type,
net/ipv6/addrconf.c
6024
static int check_stable_privacy(struct inet6_dev *idev, struct net *net,
net/ipv6/addrconf.c
6029
!net->ipv6.devconf_dflt->stable_secret.initialized)
net/ipv6/addrconf.c
605
rtnl_notify(skb, net, 0, RTNLGRP_IPV6_NETCONF, NULL, GFP_KERNEL);
net/ipv6/addrconf.c
608
rtnl_set_sk_err(net, RTNLGRP_IPV6_NETCONF, err);
net/ipv6/addrconf.c
6172
struct net *net = sock_net(skb->sk);
net/ipv6/addrconf.c
6192
for_each_netdev_dump(net, dev, ctx->ifindex) {
net/ipv6/addrconf.c
6211
struct net *net = dev_net(idev->dev);
net/ipv6/addrconf.c
6225
rtnl_notify(skb, net, 0, RTNLGRP_IPV6_IFINFO, NULL, GFP_ATOMIC);
net/ipv6/addrconf.c
6228
rtnl_set_sk_err(net, RTNLGRP_IPV6_IFINFO, err);
net/ipv6/addrconf.c
6278
struct net *net = dev_net(idev->dev);
net/ipv6/addrconf.c
6292
rtnl_notify(skb, net, 0, RTNLGRP_IPV6_PREFIX, NULL, GFP_ATOMIC);
net/ipv6/addrconf.c
6295
rtnl_set_sk_err(net, RTNLGRP_IPV6_PREFIX, err);
net/ipv6/addrconf.c
6300
struct net *net = dev_net(ifp->idev->dev);
net/ipv6/addrconf.c
6318
ip6_ins_rt(net, ifp->rt);
net/ipv6/addrconf.c
6342
ip6_del_rt(net, rt, false);
net/ipv6/addrconf.c
6345
ip6_del_rt(net, ifp->rt, false);
net/ipv6/addrconf.c
6348
rt_genid_bump_ipv6(net);
net/ipv6/addrconf.c
6351
atomic_inc(&net->ipv6.dev_addr_genid);
net/ipv6/addrconf.c
6417
static void addrconf_disable_change(struct net *net, __s32 newf)
net/ipv6/addrconf.c
6422
for_each_netdev(net, dev) {
net/ipv6/addrconf.c
6436
struct net *net = (struct net *)table->extra2;
net/ipv6/addrconf.c
6439
if (p == &net->ipv6.devconf_dflt->disable_ipv6) {
net/ipv6/addrconf.c
6444
if (!rtnl_net_trylock(net))
net/ipv6/addrconf.c
6450
if (p == &net->ipv6.devconf_all->disable_ipv6) {
net/ipv6/addrconf.c
6451
WRITE_ONCE(net->ipv6.devconf_dflt->disable_ipv6, newf);
net/ipv6/addrconf.c
6452
addrconf_disable_change(net, newf);
net/ipv6/addrconf.c
6457
rtnl_net_unlock(net);
net/ipv6/addrconf.c
6491
struct net *net = ctl->extra2;
net/ipv6/addrconf.c
6496
if (write && !rtnl_net_trylock(net))
net/ipv6/addrconf.c
6504
if (valp == &net->ipv6.devconf_dflt->proxy_ndp) {
net/ipv6/addrconf.c
6505
inet6_netconf_notify_devconf(net, RTM_NEWNETCONF,
net/ipv6/addrconf.c
6508
net->ipv6.devconf_dflt);
net/ipv6/addrconf.c
6509
} else if (valp == &net->ipv6.devconf_all->proxy_ndp) {
net/ipv6/addrconf.c
6510
inet6_netconf_notify_devconf(net, RTM_NEWNETCONF,
net/ipv6/addrconf.c
6513
net->ipv6.devconf_all);
net/ipv6/addrconf.c
6517
inet6_netconf_notify_devconf(net, RTM_NEWNETCONF,
net/ipv6/addrconf.c
6524
rtnl_net_unlock(net);
net/ipv6/addrconf.c
6536
struct net *net = (struct net *)ctl->extra2;
net/ipv6/addrconf.c
6543
if (!rtnl_net_trylock(net))
net/ipv6/addrconf.c
6559
if (check_stable_privacy(idev, net, new_val) < 0) {
net/ipv6/addrconf.c
6570
} else if (&net->ipv6.devconf_all->addr_gen_mode == ctl->data) {
net/ipv6/addrconf.c
6573
WRITE_ONCE(net->ipv6.devconf_dflt->addr_gen_mode, new_val);
net/ipv6/addrconf.c
6574
for_each_netdev(net, dev) {
net/ipv6/addrconf.c
6591
rtnl_net_unlock(net);
net/ipv6/addrconf.c
6604
struct net *net = ctl->extra2;
net/ipv6/addrconf.c
6607
if (&net->ipv6.devconf_all->stable_secret == ctl->data)
net/ipv6/addrconf.c
661
struct net *net = sock_net(in_skb->sk);
net/ipv6/addrconf.c
6613
if (!rtnl_net_trylock(net))
net/ipv6/addrconf.c
6639
if (&net->ipv6.devconf_dflt->stable_secret == ctl->data) {
net/ipv6/addrconf.c
6642
for_each_netdev(net, dev) {
net/ipv6/addrconf.c
6658
rtnl_net_unlock(net);
net/ipv6/addrconf.c
6736
struct net *net = (struct net *)ctl->extra2;
net/ipv6/addrconf.c
6739
if (valp == &net->ipv6.devconf_dflt->disable_policy) {
net/ipv6/addrconf.c
6744
if (!rtnl_net_trylock(net))
net/ipv6/addrconf.c
6749
if (valp == &net->ipv6.devconf_all->disable_policy) {
net/ipv6/addrconf.c
6752
for_each_netdev(net, dev) {
net/ipv6/addrconf.c
6762
rtnl_net_unlock(net);
net/ipv6/addrconf.c
6790
static void addrconf_force_forward_change(struct net *net, __s32 newf)
net/ipv6/addrconf.c
6795
for_each_netdev(net, dev) {
net/ipv6/addrconf.c
681
devconf = net->ipv6.devconf_all;
net/ipv6/addrconf.c
6814
struct net *net = ctl->extra2;
net/ipv6/addrconf.c
6828
if (!rtnl_net_trylock(net))
net/ipv6/addrconf.c
6833
if (valp == &net->ipv6.devconf_dflt->force_forwarding) {
net/ipv6/addrconf.c
6834
inet6_netconf_notify_devconf(net, RTM_NEWNETCONF,
net/ipv6/addrconf.c
6837
net->ipv6.devconf_dflt);
net/ipv6/addrconf.c
6838
} else if (valp == &net->ipv6.devconf_all->force_forwarding) {
net/ipv6/addrconf.c
6839
inet6_netconf_notify_devconf(net, RTM_NEWNETCONF,
net/ipv6/addrconf.c
684
devconf = net->ipv6.devconf_dflt;
net/ipv6/addrconf.c
6842
net->ipv6.devconf_all);
net/ipv6/addrconf.c
6844
addrconf_force_forward_change(net, new_val);
net/ipv6/addrconf.c
6846
inet6_netconf_notify_devconf(net, RTM_NEWNETCONF,
net/ipv6/addrconf.c
6851
rtnl_net_unlock(net);
net/ipv6/addrconf.c
687
dev = dev_get_by_index(net, ifindex);
net/ipv6/addrconf.c
712
err = rtnl_unicast(skb, net, NETLINK_CB(in_skb).portid);
net/ipv6/addrconf.c
722
static u32 inet6_base_seq(const struct net *net)
net/ipv6/addrconf.c
724
u32 res = atomic_read(&net->ipv6.dev_addr_genid) +
net/ipv6/addrconf.c
725
READ_ONCE(net->dev_base_seq);
net/ipv6/addrconf.c
7340
static int __addrconf_sysctl_register(struct net *net, char *dev_name,
net/ipv6/addrconf.c
7360
table[i].extra2 = net;
net/ipv6/addrconf.c
7366
p->sysctl_header = register_net_sysctl_sz(net, path, table,
net/ipv6/addrconf.c
7377
inet6_netconf_notify_devconf(net, RTM_NEWNETCONF, NETCONFA_ALL,
net/ipv6/addrconf.c
7387
static void __addrconf_sysctl_unregister(struct net *net,
net/ipv6/addrconf.c
739
struct net *net = sock_net(skb->sk);
net/ipv6/addrconf.c
7400
inet6_netconf_notify_devconf(net, RTM_DELNETCONF, 0, ifindex, NULL);
net/ipv6/addrconf.c
7432
static int __net_init addrconf_init_net(struct net *net)
net/ipv6/addrconf.c
7437
spin_lock_init(&net->ipv6.addrconf_hash_lock);
net/ipv6/addrconf.c
7438
INIT_DEFERRABLE_WORK(&net->ipv6.addr_chk_work, addrconf_verify_work);
net/ipv6/addrconf.c
7439
net->ipv6.inet6_addr_lst = kzalloc_objs(struct hlist_head,
net/ipv6/addrconf.c
7441
if (!net->ipv6.inet6_addr_lst)
net/ipv6/addrconf.c
7452
if (!net_eq(net, &init_net)) {
net/ipv6/addrconf.c
7481
net->ipv6.devconf_all = all;
net/ipv6/addrconf.c
7482
net->ipv6.devconf_dflt = dflt;
net/ipv6/addrconf.c
7485
err = __addrconf_sysctl_register(net, "all", NULL, all);
net/ipv6/addrconf.c
7489
err = __addrconf_sysctl_register(net, "default", NULL, dflt);
net/ipv6/addrconf.c
7497
__addrconf_sysctl_unregister(net, all, NETCONFA_IFINDEX_ALL);
net/ipv6/addrconf.c
7500
net->ipv6.devconf_dflt = NULL;
net/ipv6/addrconf.c
7504
net->ipv6.devconf_all = NULL;
net/ipv6/addrconf.c
7506
kfree(net->ipv6.inet6_addr_lst);
net/ipv6/addrconf.c
7511
static void __net_exit addrconf_exit_net(struct net *net)
net/ipv6/addrconf.c
7516
__addrconf_sysctl_unregister(net, net->ipv6.devconf_dflt,
net/ipv6/addrconf.c
7518
__addrconf_sysctl_unregister(net, net->ipv6.devconf_all,
net/ipv6/addrconf.c
7521
kfree(net->ipv6.devconf_dflt);
net/ipv6/addrconf.c
7522
net->ipv6.devconf_dflt = NULL;
net/ipv6/addrconf.c
7523
kfree(net->ipv6.devconf_all);
net/ipv6/addrconf.c
7524
net->ipv6.devconf_all = NULL;
net/ipv6/addrconf.c
7526
cancel_delayed_work_sync(&net->ipv6.addr_chk_work);
net/ipv6/addrconf.c
7531
WARN_ON_ONCE(!hlist_empty(&net->ipv6.inet6_addr_lst[i]));
net/ipv6/addrconf.c
7533
kfree(net->ipv6.inet6_addr_lst);
net/ipv6/addrconf.c
7534
net->ipv6.inet6_addr_lst = NULL;
net/ipv6/addrconf.c
764
for_each_netdev_dump(net, dev, ctx->ifindex) {
net/ipv6/addrconf.c
780
net->ipv6.devconf_all,
net/ipv6/addrconf.c
791
net->ipv6.devconf_dflt,
net/ipv6/addrconf.c
853
static void addrconf_forward_change(struct net *net, __s32 newf)
net/ipv6/addrconf.c
858
for_each_netdev(net, dev) {
net/ipv6/addrconf.c
875
struct net *net = (struct net *)table->extra2;
net/ipv6/addrconf.c
878
if (!rtnl_net_trylock(net))
net/ipv6/addrconf.c
884
if (p == &net->ipv6.devconf_dflt->forwarding) {
net/ipv6/addrconf.c
886
inet6_netconf_notify_devconf(net, RTM_NEWNETCONF,
net/ipv6/addrconf.c
889
net->ipv6.devconf_dflt);
net/ipv6/addrconf.c
890
rtnl_net_unlock(net);
net/ipv6/addrconf.c
894
if (p == &net->ipv6.devconf_all->forwarding) {
net/ipv6/addrconf.c
895
int old_dflt = net->ipv6.devconf_dflt->forwarding;
net/ipv6/addrconf.c
897
WRITE_ONCE(net->ipv6.devconf_dflt->forwarding, newf);
net/ipv6/addrconf.c
899
inet6_netconf_notify_devconf(net, RTM_NEWNETCONF,
net/ipv6/addrconf.c
902
net->ipv6.devconf_dflt);
net/ipv6/addrconf.c
904
addrconf_forward_change(net, newf);
net/ipv6/addrconf.c
906
inet6_netconf_notify_devconf(net, RTM_NEWNETCONF,
net/ipv6/addrconf.c
909
net->ipv6.devconf_all);
net/ipv6/addrconf.c
912
rtnl_net_unlock(net);
net/ipv6/addrconf.c
915
rt6_purge_dflt_routers(net);
net/ipv6/addrconf.c
919
static void addrconf_linkdown_change(struct net *net, __s32 newf)
net/ipv6/addrconf.c
924
for_each_netdev(net, dev) {
net/ipv6/addrconf.c
942
struct net *net = (struct net *)table->extra2;
net/ipv6/addrconf.c
945
if (!rtnl_net_trylock(net))
net/ipv6/addrconf.c
951
if (p == &net->ipv6.devconf_dflt->ignore_routes_with_linkdown) {
net/ipv6/addrconf.c
953
inet6_netconf_notify_devconf(net,
net/ipv6/addrconf.c
957
net->ipv6.devconf_dflt);
net/ipv6/addrconf.c
958
} else if (p == &net->ipv6.devconf_all->ignore_routes_with_linkdown) {
net/ipv6/addrconf.c
959
WRITE_ONCE(net->ipv6.devconf_dflt->ignore_routes_with_linkdown, newf);
net/ipv6/addrconf.c
960
addrconf_linkdown_change(net, newf);
net/ipv6/addrconf.c
962
inet6_netconf_notify_devconf(net,
net/ipv6/addrconf.c
966
net->ipv6.devconf_all);
net/ipv6/addrconf.c
971
inet6_netconf_notify_devconf(net,
net/ipv6/addrconf.c
979
rtnl_net_unlock(net);
net/ipv6/addrconf_core.c
16
void (*__fib6_flush_trees)(struct net *);
net/ipv6/addrlabel.c
121
static struct ip6addrlbl_entry *__ipv6_addr_label(struct net *net,
net/ipv6/addrlabel.c
127
hlist_for_each_entry_rcu(p, &net->ipv6.ip6addrlbl_table.head, list) {
net/ipv6/addrlabel.c
134
u32 ipv6_addr_label(struct net *net,
net/ipv6/addrlabel.c
143
p = __ipv6_addr_label(net, addr, type, ifindex);
net/ipv6/addrlabel.c
197
static int __ip6addrlbl_add(struct net *net, struct ip6addrlbl_entry *newp,
net/ipv6/addrlabel.c
206
hlist_for_each_entry_safe(p, n, &net->ipv6.ip6addrlbl_table.head, list) {
net/ipv6/addrlabel.c
227
hlist_add_head_rcu(&newp->list, &net->ipv6.ip6addrlbl_table.head);
net/ipv6/addrlabel.c
230
WRITE_ONCE(net->ipv6.ip6addrlbl_table.seq,
net/ipv6/addrlabel.c
231
net->ipv6.ip6addrlbl_table.seq + 1);
net/ipv6/addrlabel.c
236
static int ip6addrlbl_add(struct net *net,
net/ipv6/addrlabel.c
249
spin_lock(&net->ipv6.ip6addrlbl_table.lock);
net/ipv6/addrlabel.c
250
ret = __ip6addrlbl_add(net, newp, replace);
net/ipv6/addrlabel.c
251
spin_unlock(&net->ipv6.ip6addrlbl_table.lock);
net/ipv6/addrlabel.c
258
static int __ip6addrlbl_del(struct net *net,
net/ipv6/addrlabel.c
269
hlist_for_each_entry_safe(p, n, &net->ipv6.ip6addrlbl_table.head, list) {
net/ipv6/addrlabel.c
282
static int ip6addrlbl_del(struct net *net,
net/ipv6/addrlabel.c
293
spin_lock(&net->ipv6.ip6addrlbl_table.lock);
net/ipv6/addrlabel.c
294
ret = __ip6addrlbl_del(net, &prefix_buf, prefixlen, ifindex);
net/ipv6/addrlabel.c
295
spin_unlock(&net->ipv6.ip6addrlbl_table.lock);
net/ipv6/addrlabel.c
300
static int __net_init ip6addrlbl_net_init(struct net *net)
net/ipv6/addrlabel.c
307
spin_lock_init(&net->ipv6.ip6addrlbl_table.lock);
net/ipv6/addrlabel.c
308
INIT_HLIST_HEAD(&net->ipv6.ip6addrlbl_table.head);
net/ipv6/addrlabel.c
311
err = ip6addrlbl_add(net,
net/ipv6/addrlabel.c
322
hlist_for_each_entry_safe(p, n, &net->ipv6.ip6addrlbl_table.head, list) {
net/ipv6/addrlabel.c
329
static void __net_exit ip6addrlbl_net_exit(struct net *net)
net/ipv6/addrlabel.c
335
spin_lock(&net->ipv6.ip6addrlbl_table.lock);
net/ipv6/addrlabel.c
336
hlist_for_each_entry_safe(p, n, &net->ipv6.ip6addrlbl_table.head, list) {
net/ipv6/addrlabel.c
340
spin_unlock(&net->ipv6.ip6addrlbl_table.lock);
net/ipv6/addrlabel.c
363
static bool addrlbl_ifindex_exists(struct net *net, int ifindex)
net/ipv6/addrlabel.c
369
dev = dev_get_by_index_rcu(net, ifindex);
net/ipv6/addrlabel.c
378
struct net *net = sock_net(skb->sk);
net/ipv6/addrlabel.c
409
!addrlbl_ifindex_exists(net, ifal->ifal_index))
net/ipv6/addrlabel.c
412
err = ip6addrlbl_add(net, pfx, ifal->ifal_prefixlen,
net/ipv6/addrlabel.c
417
err = ip6addrlbl_del(net, pfx, ifal->ifal_prefixlen,
net/ipv6/addrlabel.c
489
struct net *net = sock_net(skb->sk);
net/ipv6/addrlabel.c
502
lseq = READ_ONCE(net->ipv6.ip6addrlbl_table.seq);
net/ipv6/addrlabel.c
503
hlist_for_each_entry_rcu(p, &net->ipv6.ip6addrlbl_table.head, list) {
net/ipv6/addrlabel.c
575
struct net *net = sock_net(in_skb->sk);
net/ipv6/addrlabel.c
595
!addrlbl_ifindex_exists(net, ifal->ifal_index))
net/ipv6/addrlabel.c
609
p = __ipv6_addr_label(net, addr, ipv6_addr_type(addr), ifal->ifal_index);
net/ipv6/addrlabel.c
610
lseq = READ_ONCE(net->ipv6.ip6addrlbl_table.seq);
net/ipv6/addrlabel.c
622
err = rtnl_unicast(skb, net, NETLINK_CB(in_skb).portid);
net/ipv6/af_inet6.c
105
static int inet6_create(struct net *net, struct socket *sock, int protocol,
net/ipv6/af_inet6.c
167
!ns_capable(net->user_ns, CAP_NET_RAW))
net/ipv6/af_inet6.c
178
sk = sk_alloc(net, PF_INET6, GFP_KERNEL, answer_prot, kern);
net/ipv6/af_inet6.c
212
inet6_assign_bit(REPFLOW, sk, READ_ONCE(net->ipv6.sysctl.flowlabel_reflect) &
net/ipv6/af_inet6.c
214
sk->sk_ipv6only = READ_ONCE(net->ipv6.sysctl.bindv6only);
net/ipv6/af_inet6.c
215
sk->sk_txrehash = READ_ONCE(net->core.sysctl_txrehash);
net/ipv6/af_inet6.c
228
if (READ_ONCE(net->ipv4.sysctl_ip_no_pmtu_disc))
net/ipv6/af_inet6.c
271
struct net *net = sock_net(sk);
net/ipv6/af_inet6.c
287
snum && inet_port_requires_bind_service(net, snum) &&
net/ipv6/af_inet6.c
288
!ns_capable(net->user_ns, CAP_NET_BIND_SERVICE))
net/ipv6/af_inet6.c
315
dev = dev_get_by_index_rcu(net, sk->sk_bound_dev_if);
net/ipv6/af_inet6.c
324
chk_addr_ret = inet_addr_type_dev_table(net, dev, v4addr);
net/ipv6/af_inet6.c
327
if (!inet_addr_valid_or_nonlocal(net, inet, v4addr,
net/ipv6/af_inet6.c
354
dev = dev_get_by_index_rcu(net, sk->sk_bound_dev_if);
net/ipv6/af_inet6.c
366
if (!ipv6_can_nonlocal_bind(net, inet) &&
net/ipv6/af_inet6.c
367
!ipv6_chk_addr(net, &addr->sin6_addr,
net/ipv6/af_inet6.c
551
struct net *net = sock_net(sk);
net/ipv6/af_inet6.c
561
return ipv6_route_ioctl(net, cmd, &rtmsg);
net/ipv6/af_inet6.c
564
return addrconf_add_ifaddr(net, argp);
net/ipv6/af_inet6.c
566
return addrconf_del_ifaddr(net, argp);
net/ipv6/af_inet6.c
568
return addrconf_set_dstaddr(net, argp);
net/ipv6/af_inet6.c
878
static int __net_init ipv6_init_mibs(struct net *net)
net/ipv6/af_inet6.c
882
net->mib.udp_stats_in6 = alloc_percpu(struct udp_mib);
net/ipv6/af_inet6.c
883
if (!net->mib.udp_stats_in6)
net/ipv6/af_inet6.c
886
net->mib.ipv6_statistics = alloc_percpu(struct ipstats_mib);
net/ipv6/af_inet6.c
887
if (!net->mib.ipv6_statistics)
net/ipv6/af_inet6.c
892
af_inet6_stats = per_cpu_ptr(net->mib.ipv6_statistics, i);
net/ipv6/af_inet6.c
896
net->mib.icmpv6_statistics = alloc_percpu(struct icmpv6_mib);
net/ipv6/af_inet6.c
897
if (!net->mib.icmpv6_statistics)
net/ipv6/af_inet6.c
900
net->mib.icmpv6msg_statistics = kzalloc_obj(struct icmpv6msg_mib);
net/ipv6/af_inet6.c
901
if (!net->mib.icmpv6msg_statistics)
net/ipv6/af_inet6.c
906
free_percpu(net->mib.icmpv6_statistics);
net/ipv6/af_inet6.c
908
free_percpu(net->mib.ipv6_statistics);
net/ipv6/af_inet6.c
910
free_percpu(net->mib.udp_stats_in6);
net/ipv6/af_inet6.c
914
static void ipv6_cleanup_mibs(struct net *net)
net/ipv6/af_inet6.c
916
free_percpu(net->mib.udp_stats_in6);
net/ipv6/af_inet6.c
917
free_percpu(net->mib.ipv6_statistics);
net/ipv6/af_inet6.c
918
free_percpu(net->mib.icmpv6_statistics);
net/ipv6/af_inet6.c
919
kfree(net->mib.icmpv6msg_statistics);
net/ipv6/af_inet6.c
922
static int __net_init inet6_net_init(struct net *net)
net/ipv6/af_inet6.c
926
net->ipv6.sysctl.bindv6only = 0;
net/ipv6/af_inet6.c
927
net->ipv6.sysctl.icmpv6_time = HZ / 10;
net/ipv6/af_inet6.c
928
net->ipv6.sysctl.icmpv6_echo_ignore_all = 0;
net/ipv6/af_inet6.c
929
net->ipv6.sysctl.icmpv6_echo_ignore_multicast = 0;
net/ipv6/af_inet6.c
930
net->ipv6.sysctl.icmpv6_echo_ignore_anycast = 0;
net/ipv6/af_inet6.c
931
net->ipv6.sysctl.icmpv6_error_anycast_as_unicast = 0;
net/ipv6/af_inet6.c
932
net->ipv6.sysctl.icmpv6_errors_extension_mask = 0;
net/ipv6/af_inet6.c
938
bitmap_set(net->ipv6.sysctl.icmpv6_ratemask, 0, ICMPV6_ERRMSG_MAX + 1);
net/ipv6/af_inet6.c
939
bitmap_clear(net->ipv6.sysctl.icmpv6_ratemask, ICMPV6_PKT_TOOBIG, 1);
net/ipv6/af_inet6.c
940
net->ipv6.sysctl.icmpv6_ratemask_ptr = net->ipv6.sysctl.icmpv6_ratemask;
net/ipv6/af_inet6.c
942
net->ipv6.sysctl.flowlabel_consistency = 1;
net/ipv6/af_inet6.c
943
net->ipv6.sysctl.auto_flowlabels = IP6_DEFAULT_AUTO_FLOW_LABELS;
net/ipv6/af_inet6.c
944
net->ipv6.sysctl.idgen_retries = 3;
net/ipv6/af_inet6.c
945
net->ipv6.sysctl.idgen_delay = 1 * HZ;
net/ipv6/af_inet6.c
946
net->ipv6.sysctl.flowlabel_state_ranges = 0;
net/ipv6/af_inet6.c
947
net->ipv6.sysctl.max_dst_opts_cnt = IP6_DEFAULT_MAX_DST_OPTS_CNT;
net/ipv6/af_inet6.c
948
net->ipv6.sysctl.max_hbh_opts_cnt = IP6_DEFAULT_MAX_HBH_OPTS_CNT;
net/ipv6/af_inet6.c
949
net->ipv6.sysctl.max_dst_opts_len = IP6_DEFAULT_MAX_DST_OPTS_LEN;
net/ipv6/af_inet6.c
950
net->ipv6.sysctl.max_hbh_opts_len = IP6_DEFAULT_MAX_HBH_OPTS_LEN;
net/ipv6/af_inet6.c
951
net->ipv6.sysctl.fib_notify_on_flag_change = 0;
net/ipv6/af_inet6.c
952
atomic_set(&net->ipv6.fib6_sernum, 1);
net/ipv6/af_inet6.c
954
net->ipv6.sysctl.ioam6_id = IOAM6_DEFAULT_ID;
net/ipv6/af_inet6.c
955
net->ipv6.sysctl.ioam6_id_wide = IOAM6_DEFAULT_ID_WIDE;
net/ipv6/af_inet6.c
957
err = ipv6_init_mibs(net);
net/ipv6/af_inet6.c
961
err = udp6_proc_init(net);
net/ipv6/af_inet6.c
964
err = tcp6_proc_init(net);
net/ipv6/af_inet6.c
967
err = ac6_proc_init(net);
net/ipv6/af_inet6.c
975
tcp6_proc_exit(net);
net/ipv6/af_inet6.c
977
udp6_proc_exit(net);
net/ipv6/af_inet6.c
979
ipv6_cleanup_mibs(net);
net/ipv6/af_inet6.c
984
static void __net_exit inet6_net_exit(struct net *net)
net/ipv6/af_inet6.c
987
udp6_proc_exit(net);
net/ipv6/af_inet6.c
988
tcp6_proc_exit(net);
net/ipv6/af_inet6.c
989
ac6_proc_exit(net);
net/ipv6/af_inet6.c
991
ipv6_cleanup_mibs(net);
net/ipv6/ah6.c
665
struct net *net = dev_net(skb->dev);
net/ipv6/ah6.c
674
x = xfrm_state_lookup(net, skb->mark, (xfrm_address_t *)&iph->daddr, ah->spi, IPPROTO_AH, AF_INET6);
net/ipv6/ah6.c
679
ip6_redirect(skb, net, skb->dev->ifindex, 0,
net/ipv6/ah6.c
680
sock_net_uid(net, NULL));
net/ipv6/ah6.c
682
ip6_update_pmtu(skb, net, info, 0, 0, sock_net_uid(net, NULL));
net/ipv6/anycast.c
105
rt = rt6_lookup(net, addr, NULL, 0, NULL, 0);
net/ipv6/anycast.c
116
dev = netdev_get_by_flags_rcu(net, &dev_tracker, IFF_UP,
net/ipv6/anycast.c
177
struct net *net = sock_net(sk);
net/ipv6/anycast.c
194
dev = dev_get_by_index(net, pac->acl_ifindex);
net/ipv6/anycast.c
207
struct net *net = sock_net(sk);
net/ipv6/anycast.c
220
dev = dev_get_by_index(net, pac->acl_ifindex);
net/ipv6/anycast.c
242
static void ipv6_add_acaddr_hash(struct net *net, struct ifacaddr6 *aca)
net/ipv6/anycast.c
244
unsigned int hash = inet6_acaddr_hash(net, &aca->aca_addr);
net/ipv6/anycast.c
305
struct net *net = dev_net(dev);
net/ipv6/anycast.c
323
rtnl_notify(skb, net, 0, RTNLGRP_IPV6_ACADDR, NULL, GFP_KERNEL);
net/ipv6/anycast.c
326
rtnl_set_sk_err(net, RTNLGRP_IPV6_ACADDR, err);
net/ipv6/anycast.c
336
struct net *net;
net/ipv6/anycast.c
354
net = dev_net(idev->dev);
net/ipv6/anycast.c
355
f6i = addrconf_f6i_alloc(net, idev, addr, true, GFP_ATOMIC, NULL);
net/ipv6/anycast.c
374
ipv6_add_acaddr_hash(net, aca);
net/ipv6/anycast.c
378
ip6_ins_rt(net, f6i);
net/ipv6/anycast.c
489
bool ipv6_chk_acast_addr(struct net *net, struct net_device *dev,
net/ipv6/anycast.c
500
unsigned int hash = inet6_acaddr_hash(net, addr);
net/ipv6/anycast.c
505
if (!nh_dev || !net_eq(dev_net(nh_dev), net))
net/ipv6/anycast.c
520
bool ipv6_chk_acast_addr_src(struct net *net, struct net_device *dev,
net/ipv6/anycast.c
523
return ipv6_chk_acast_addr(net,
net/ipv6/anycast.c
540
struct net *net = seq_file_net(seq);
net/ipv6/anycast.c
543
for_each_netdev_rcu(net, state->dev) {
net/ipv6/anycast.c
55
static u32 inet6_acaddr_hash(const struct net *net,
net/ipv6/anycast.c
58
u32 val = __ipv6_addr_jhash(addr, net_hash_mix(net));
net/ipv6/anycast.c
622
int __net_init ac6_proc_init(struct net *net)
net/ipv6/anycast.c
624
if (!proc_create_net("anycast6", 0444, net->proc_net, &ac6_seq_ops,
net/ipv6/anycast.c
631
void ac6_proc_exit(struct net *net)
net/ipv6/anycast.c
633
remove_proc_entry("anycast6", net->proc_net);
net/ipv6/anycast.c
71
struct net *net = sock_net(sk);
net/ipv6/anycast.c
77
if (!ns_capable(net->user_ns, CAP_NET_ADMIN))
net/ipv6/anycast.c
83
dev = netdev_get_by_index(net, ifindex, &dev_tracker, GFP_KERNEL);
net/ipv6/anycast.c
85
if (ipv6_chk_addr_and_flags(net, addr, dev, true, 0, IFA_F_TENTATIVE)) {
net/ipv6/anycast.c
99
ishost = !READ_ONCE(net->ipv6.devconf_all->forwarding);
net/ipv6/datagram.c
797
int ip6_datagram_send_ctl(struct net *net, struct sock *sk,
net/ipv6/datagram.c
856
dev = dev_get_by_index_rcu(net, fl6->flowi6_oif);
net/ipv6/datagram.c
868
if (!ipv6_can_nonlocal_bind(net, inet_sk(sk)) &&
net/ipv6/datagram.c
869
!ipv6_chk_addr_and_flags(net, &src_info->ipi6_addr,
net/ipv6/datagram.c
872
!ipv6_chk_acast_addr_src(net, dev,
net/ipv6/datagram.c
915
if (!ns_capable(net->user_ns, CAP_NET_RAW)) {
net/ipv6/datagram.c
935
if (!ns_capable(net->user_ns, CAP_NET_RAW)) {
net/ipv6/datagram.c
960
if (!ns_capable(net->user_ns, CAP_NET_RAW)) {
net/ipv6/esp6.c
1000
ip6_redirect(skb, net, skb->dev->ifindex, 0,
net/ipv6/esp6.c
1001
sock_net_uid(net, NULL));
net/ipv6/esp6.c
1003
ip6_update_pmtu(skb, net, info, 0, 0, sock_net_uid(net, NULL));
net/ipv6/esp6.c
146
struct net *net = xs_net(x);
net/ipv6/esp6.c
155
sk = __inet6_lookup_established(net, &x->id.daddr.in6, dport,
net/ipv6/esp6.c
196
static int esp_output_tcp_encap_cb(struct net *net, struct sock *sk,
net/ipv6/esp6.c
985
struct net *net = dev_net(skb->dev);
net/ipv6/esp6.c
994
x = xfrm_state_lookup(net, skb->mark, (const xfrm_address_t *)&iph->daddr,
net/ipv6/exthdrs.c
1059
struct net *net = dev_net(skb->dev);
net/ipv6/exthdrs.c
1077
if (extlen > READ_ONCE(net->ipv6.sysctl.max_hbh_opts_len))
net/ipv6/exthdrs.c
1082
READ_ONCE(net->ipv6.sysctl.max_hbh_opts_cnt))) {
net/ipv6/exthdrs.c
1157
struct net *net = NULL;
net/ipv6/exthdrs.c
1160
net = dev_net(skb->dev);
net/ipv6/exthdrs.c
1162
net = sock_net(skb->sk);
net/ipv6/exthdrs.c
1164
WARN_ON(!net);
net/ipv6/exthdrs.c
1166
if (net)
net/ipv6/exthdrs.c
1167
seg6_push_hmac(net, saddr, sr_phdr);
net/ipv6/exthdrs.c
304
struct net *net = dev_net(skb->dev);
net/ipv6/exthdrs.c
318
if (extlen > READ_ONCE(net->ipv6.sysctl.max_dst_opts_len))
net/ipv6/exthdrs.c
327
READ_ONCE(net->ipv6.sysctl.max_dst_opts_cnt))) {
net/ipv6/exthdrs.c
338
__IP6_INC_STATS(net, idev, IPSTATS_MIB_INHDRERRORS);
net/ipv6/exthdrs.c
374
struct net *net = dev_net(skb->dev);
net/ipv6/exthdrs.c
388
accept_seg6 = min(READ_ONCE(net->ipv6.devconf_all->seg6_enabled),
net/ipv6/exthdrs.c
419
__skb_tunnel_rx(skb, skb->dev, net);
net/ipv6/exthdrs.c
434
__IP6_INC_STATS(net, idev, IPSTATS_MIB_INHDRERRORS);
net/ipv6/exthdrs.c
443
__IP6_INC_STATS(net, ip6_dst_idev(skb_dst(skb)),
net/ipv6/exthdrs.c
471
__IP6_INC_STATS(net, idev, IPSTATS_MIB_INHDRERRORS);
net/ipv6/exthdrs.c
492
struct net *net = dev_net(skb->dev);
net/ipv6/exthdrs.c
504
accept_rpl_seg = min(READ_ONCE(net->ipv6.devconf_all->rpl_seg_enabled),
net/ipv6/exthdrs.c
528
__skb_tunnel_rx(skb, skb->dev, net);
net/ipv6/exthdrs.c
554
__IP6_INC_STATS(net, idev, IPSTATS_MIB_INHDRERRORS);
net/ipv6/exthdrs.c
580
err = ipv6_chk_rpl_srh_loop(net, ohdr->rpl_segaddr, n + 1);
net/ipv6/exthdrs.c
602
__IP6_INC_STATS(net, ip6_dst_idev(skb_dst(skb)), IPSTATS_MIB_OUTDISCARDS);
net/ipv6/exthdrs.c
633
__IP6_INC_STATS(net, idev, IPSTATS_MIB_INHDRERRORS);
net/ipv6/exthdrs.c
663
struct net *net = dev_net(skb->dev);
net/ipv6/exthdrs.c
666
accept_source_route = READ_ONCE(net->ipv6.devconf_all->accept_source_route);
net/ipv6/exthdrs.c
675
__IP6_INC_STATS(net, idev, IPSTATS_MIB_INHDRERRORS);
net/ipv6/exthdrs.c
684
__IP6_INC_STATS(net, idev, IPSTATS_MIB_INADDRERRORS);
net/ipv6/exthdrs.c
709
__IP6_INC_STATS(net, idev,
net/ipv6/exthdrs.c
735
__IP6_INC_STATS(net, idev, IPSTATS_MIB_INHDRERRORS);
net/ipv6/exthdrs.c
753
__IP6_INC_STATS(net, idev, IPSTATS_MIB_INHDRERRORS);
net/ipv6/exthdrs.c
766
__IP6_INC_STATS(net, ip6_dst_idev(skb_dst(skb)),
net/ipv6/exthdrs.c
789
__IP6_INC_STATS(net, idev, IPSTATS_MIB_INADDRERRORS);
net/ipv6/exthdrs.c
794
__IP6_INC_STATS(net, idev, IPSTATS_MIB_INADDRERRORS);
net/ipv6/exthdrs.c
805
__IP6_INC_STATS(net, idev, IPSTATS_MIB_INADDRERRORS);
net/ipv6/exthdrs.c
821
__IP6_INC_STATS(net, idev, IPSTATS_MIB_INHDRERRORS);
net/ipv6/exthdrs.c
836
__IP6_INC_STATS(net, idev, IPSTATS_MIB_INHDRERRORS);
net/ipv6/fib6_notifier.c
19
int call_fib6_notifiers(struct net *net, enum fib_event_type event_type,
net/ipv6/fib6_notifier.c
23
return call_fib_notifiers(net, event_type, info);
net/ipv6/fib6_notifier.c
26
static unsigned int fib6_seq_read(const struct net *net)
net/ipv6/fib6_notifier.c
28
return fib6_tables_seq_read(net) + fib6_rules_seq_read(net);
net/ipv6/fib6_notifier.c
31
static int fib6_dump(struct net *net, struct notifier_block *nb,
net/ipv6/fib6_notifier.c
36
err = fib6_rules_dump(net, nb, extack);
net/ipv6/fib6_notifier.c
40
return fib6_tables_dump(net, nb, extack);
net/ipv6/fib6_notifier.c
50
int __net_init fib6_notifier_init(struct net *net)
net/ipv6/fib6_notifier.c
54
ops = fib_notifier_ops_register(&fib6_notifier_ops_template, net);
net/ipv6/fib6_notifier.c
57
net->ipv6.notifier_ops = ops;
net/ipv6/fib6_notifier.c
62
void __net_exit fib6_notifier_exit(struct net *net)
net/ipv6/fib6_notifier.c
64
fib_notifier_ops_unregister(net->ipv6.notifier_ops);
net/ipv6/fib6_rules.c
103
if (net->ipv6.fib6_has_custom_rules) {
net/ipv6/fib6_rules.c
113
l3mdev_update_flow(net, flowi6_to_flowi(fl6));
net/ipv6/fib6_rules.c
115
fib_rules_lookup(net->ipv6.fib6_rules_ops,
net/ipv6/fib6_rules.c
124
net, net->ipv6.fib6_local_tbl, fl6, skb, flags);
net/ipv6/fib6_rules.c
125
if (rt != net->ipv6.ip6_null_entry && rt->dst.error != -EAGAIN)
net/ipv6/fib6_rules.c
129
net, net->ipv6.fib6_main_tbl, fl6, skb, flags);
net/ipv6/fib6_rules.c
136
dst_hold(&net->ipv6.ip6_null_entry->dst);
net/ipv6/fib6_rules.c
137
return &net->ipv6.ip6_null_entry->dst;
net/ipv6/fib6_rules.c
140
static int fib6_rule_saddr(struct net *net, struct fib_rule *rule, int flags,
net/ipv6/fib6_rules.c
152
if (ipv6_dev_get_saddr(net, dev, &flp6->daddr,
net/ipv6/fib6_rules.c
170
struct net *net = rule->fr_net;
net/ipv6/fib6_rules.c
188
table = fib6_get_table(net, tb_id);
net/ipv6/fib6_rules.c
193
err = fib6_table_lookup(net, table, *oif, flp6, res, flags);
net/ipv6/fib6_rules.c
194
if (!err && res->f6i != net->ipv6.fib6_null_entry)
net/ipv6/fib6_rules.c
195
err = fib6_rule_saddr(net, rule, flags, flp6,
net/ipv6/fib6_rules.c
210
struct net *net = rule->fr_net;
net/ipv6/fib6_rules.c
220
rt = net->ipv6.ip6_null_entry;
net/ipv6/fib6_rules.c
225
rt = net->ipv6.ip6_blk_hole_entry;
net/ipv6/fib6_rules.c
229
rt = net->ipv6.ip6_prohibit_entry;
net/ipv6/fib6_rules.c
234
table = fib6_get_table(net, tb_id);
net/ipv6/fib6_rules.c
241
net, table, flp6, arg->lookup_data, flags);
net/ipv6/fib6_rules.c
242
if (rt != net->ipv6.ip6_null_entry) {
net/ipv6/fib6_rules.c
247
err = fib6_rule_saddr(net, rule, flags, flp6,
net/ipv6/fib6_rules.c
431
struct net *net = rule->fr_net;
net/ipv6/fib6_rules.c
459
if (fib6_new_table(net, rule->table) == NULL) {
net/ipv6/fib6_rules.c
475
net->ipv6.fib6_rules_require_fldissect++;
net/ipv6/fib6_rules.c
477
net->ipv6.fib6_has_custom_rules = true;
net/ipv6/fib6_rules.c
485
struct net *net = rule->fr_net;
net/ipv6/fib6_rules.c
487
if (net->ipv6.fib6_rules_require_fldissect &&
net/ipv6/fib6_rules.c
489
net->ipv6.fib6_rules_require_fldissect--;
net/ipv6/fib6_rules.c
56
int fib6_rules_dump(struct net *net, struct notifier_block *nb,
net/ipv6/fib6_rules.c
59
return fib_rules_dump(net, nb, AF_INET6, extack);
net/ipv6/fib6_rules.c
613
static int __net_init fib6_rules_net_init(struct net *net)
net/ipv6/fib6_rules.c
618
ops = fib_rules_register(&fib6_rules_ops_template, net);
net/ipv6/fib6_rules.c
62
unsigned int fib6_rules_seq_read(const struct net *net)
net/ipv6/fib6_rules.c
630
net->ipv6.fib6_rules_ops = ops;
net/ipv6/fib6_rules.c
631
net->ipv6.fib6_rules_require_fldissect = 0;
net/ipv6/fib6_rules.c
64
return fib_rules_seq_read(net, AF_INET6);
net/ipv6/fib6_rules.c
642
struct net *net;
net/ipv6/fib6_rules.c
645
list_for_each_entry(net, net_list, exit_list) {
net/ipv6/fib6_rules.c
646
fib_rules_unregister(net->ipv6.fib6_rules_ops);
net/ipv6/fib6_rules.c
68
int fib6_lookup(struct net *net, int oif, struct flowi6 *fl6,
net/ipv6/fib6_rules.c
73
if (net->ipv6.fib6_has_custom_rules) {
net/ipv6/fib6_rules.c
81
l3mdev_update_flow(net, flowi6_to_flowi(fl6));
net/ipv6/fib6_rules.c
83
err = fib_rules_lookup(net->ipv6.fib6_rules_ops,
net/ipv6/fib6_rules.c
86
err = fib6_table_lookup(net, net->ipv6.fib6_local_tbl, oif,
net/ipv6/fib6_rules.c
88
if (err || res->f6i == net->ipv6.fib6_null_entry)
net/ipv6/fib6_rules.c
89
err = fib6_table_lookup(net, net->ipv6.fib6_main_tbl,
net/ipv6/fib6_rules.c
99
struct dst_entry *fib6_rule_lookup(struct net *net, struct flowi6 *fl6,
net/ipv6/icmp.c
1021
__ICMP6_INC_STATS(net, idev, ICMP6_MIB_OUTERRORS);
net/ipv6/icmp.c
103
static struct sock *icmpv6_xmit_lock(struct net *net)
net/ipv6/icmp.c
1041
struct net *net = dev_net_rcu(skb->dev);
net/ipv6/icmp.c
1093
__ICMP6_INC_STATS(net, __in6_dev_get(skb->dev), ICMP6_MIB_INERRORS);
net/ipv6/icmp.c
1104
struct net *net = dev_net_rcu(skb->dev);
net/ipv6/icmp.c
115
sock_net_set(sk, net);
net/ipv6/icmp.c
1155
if (!net->ipv6.sysctl.icmpv6_echo_ignore_all)
net/ipv6/icmp.c
1159
if (!net->ipv6.sysctl.icmpv6_echo_ignore_all &&
net/ipv6/icmp.c
1160
READ_ONCE(net->ipv4.sysctl_icmp_echo_enable_probe))
net/ipv6/icmp.c
1433
struct ctl_table * __net_init ipv6_icmp_sysctl_init(struct net *net)
net/ipv6/icmp.c
1442
table[0].data = &net->ipv6.sysctl.icmpv6_time;
net/ipv6/icmp.c
1443
table[1].data = &net->ipv6.sysctl.icmpv6_echo_ignore_all;
net/ipv6/icmp.c
1444
table[2].data = &net->ipv6.sysctl.icmpv6_echo_ignore_multicast;
net/ipv6/icmp.c
1445
table[3].data = &net->ipv6.sysctl.icmpv6_echo_ignore_anycast;
net/ipv6/icmp.c
1446
table[4].data = &net->ipv6.sysctl.icmpv6_ratemask_ptr;
net/ipv6/icmp.c
1447
table[5].data = &net->ipv6.sysctl.icmpv6_error_anycast_as_unicast;
net/ipv6/icmp.c
1448
table[6].data = &net->ipv6.sysctl.icmpv6_errors_extension_mask;
net/ipv6/icmp.c
166
static bool icmpv6_mask_allow(struct net *net, int type)
net/ipv6/icmp.c
172
if (!test_bit(type, net->ipv6.sysctl.icmpv6_ratemask))
net/ipv6/icmp.c
178
static bool icmpv6_global_allow(struct net *net, int type,
net/ipv6/icmp.c
181
if (icmpv6_mask_allow(net, type))
net/ipv6/icmp.c
184
if (icmp_global_allow(net)) {
net/ipv6/icmp.c
188
__ICMP_INC_STATS(net, ICMP_MIB_RATELIMITGLOBAL);
net/ipv6/icmp.c
198
struct net *net = sock_net(sk);
net/ipv6/icmp.c
211
dst = ip6_route_output(net, sk, fl6);
net/ipv6/icmp.c
215
IP6_INC_STATS(net, ip6_dst_idev(dst),
net/ipv6/icmp.c
220
int tmo = READ_ONCE(net->ipv6.sysctl.icmpv6_time);
net/ipv6/icmp.c
226
peer = inet_getpeer_v6(net->ipv6.peers, &fl6->daddr);
net/ipv6/icmp.c
232
__ICMP6_INC_STATS(net, NULL, ICMP6_MIB_RATELIMITHOST);
net/ipv6/icmp.c
234
icmp_global_consume(net);
net/ipv6/icmp.c
242
struct net *net = sock_net(sk);
net/ipv6/icmp.c
246
dst = ip6_route_output(net, sk, fl6);
net/ipv6/icmp.c
354
static struct dst_entry *icmpv6_route_lookup(struct net *net,
net/ipv6/icmp.c
363
err = ip6_dst_lookup(net, sk, &dst, fl6);
net/ipv6/icmp.c
371
if (!READ_ONCE(net->ipv6.sysctl.icmpv6_error_anycast_as_unicast) &&
net/ipv6/icmp.c
381
dst = xfrm_lookup(net, dst, flowi6_to_flowi(fl6), sk, 0);
net/ipv6/icmp.c
392
err = xfrm_decode_session_reverse(net, skb, flowi6_to_flowi(&fl2), AF_INET6);
net/ipv6/icmp.c
396
err = ip6_dst_lookup(net, sk, &dst2, &fl2);
net/ipv6/icmp.c
400
dst2 = xfrm_lookup(net, dst2, flowi6_to_flowi(&fl2), sk, XFRM_LOOKUP_ICMP);
net/ipv6/icmp.c
503
static void icmp6_ext_iio_iif_append(struct net *net, struct sk_buff *skb,
net/ipv6/icmp.c
526
dev = dev_get_by_index_rcu(net, iif);
net/ipv6/icmp.c
554
static void icmp6_ext_objs_append(struct net *net, struct sk_buff *skb,
net/ipv6/icmp.c
558
icmp6_ext_iio_iif_append(net, skb, iif);
net/ipv6/icmp.c
562
icmp6_ext_append(struct net *net, struct sk_buff *skb_in,
net/ipv6/icmp.c
587
ext_objs = READ_ONCE(net->ipv6.sysctl.icmpv6_errors_extension_mask);
net/ipv6/icmp.c
615
icmp6_ext_objs_append(net, skb, ext_objs, iif);
net/ipv6/icmp.c
643
struct net *net;
net/ipv6/icmp.c
668
net = dev_net_rcu(skb->dev);
net/ipv6/icmp.c
669
mark = IP6_REPLY_MARK(net, skb->mark);
net/ipv6/icmp.c
678
if (ipv6_chk_addr(net, &hdr->daddr, skb->dev, 0) ||
net/ipv6/icmp.c
679
ipv6_chk_acast_addr_src(net, skb->dev, &hdr->daddr))
net/ipv6/icmp.c
738
!icmpv6_global_allow(net, type, &apply_ratelimit))
net/ipv6/icmp.c
743
sk = icmpv6_xmit_lock(net);
net/ipv6/icmp.c
758
in_netdev = dev_get_by_index(net, parm->iif);
net/ipv6/icmp.c
760
ipv6_dev_get_saddr(net, in_netdev, &fl6.daddr,
net/ipv6/icmp.c
770
fl6.flowi6_uid = sock_net_uid(net, NULL);
net/ipv6/icmp.c
771
fl6.mp_hash = rt6_multipath_hash(net, &fl6, skb, NULL);
net/ipv6/icmp.c
79
struct net *net = dev_net_rcu(skb->dev);
net/ipv6/icmp.c
793
dst = icmpv6_route_lookup(net, skb, sk, &fl6);
net/ipv6/icmp.c
804
ext_skb = icmp6_ext_append(net, skb, &tmp_hdr, room, parm->iif);
net/ipv6/icmp.c
82
ip6_update_pmtu(skb, net, info, skb->dev->ifindex, 0, sock_net_uid(net, NULL));
net/ipv6/icmp.c
823
ICMP6_INC_STATS(net, idev, ICMP6_MIB_OUTERRORS);
net/ipv6/icmp.c
84
ip6_redirect(skb, net, skb->dev->ifindex, 0,
net/ipv6/icmp.c
85
sock_net_uid(net, NULL));
net/ipv6/icmp.c
923
struct net *net = dev_net_rcu(skb->dev);
net/ipv6/icmp.c
935
u32 mark = IP6_REPLY_MARK(net, skb->mark);
net/ipv6/icmp.c
941
net->ipv6.sysctl.icmpv6_echo_ignore_multicast)
net/ipv6/icmp.c
947
if (acast && net->ipv6.sysctl.icmpv6_echo_ignore_anycast)
net/ipv6/icmp.c
951
!(net->ipv6.sysctl.anycast_src_echo_reply && acast))
net/ipv6/icmp.c
963
if (READ_ONCE(net->ipv6.sysctl.flowlabel_reflect) &
net/ipv6/icmp.c
976
fl6.flowi6_uid = sock_net_uid(net, NULL);
net/ipv6/icmp.c
980
sk = icmpv6_xmit_lock(net);
net/ipv6/icmp.c
990
if (ip6_dst_lookup(net, sk, &dst, &fl6))
net/ipv6/icmp.c
992
dst = xfrm_lookup(net, dst, flowi6_to_flowi(&fl6), sk, 0);
net/ipv6/icmp.c
998
!icmpv6_global_allow(net, ICMPV6_ECHO_REPLY, &apply_ratelimit)) ||
net/ipv6/ila/ila.h
110
int ila_xlat_init_net(struct net *net);
net/ipv6/ila/ila.h
111
void ila_xlat_pre_exit_net(struct net *net);
net/ipv6/ila/ila.h
112
void ila_xlat_exit_net(struct net *net);
net/ipv6/ila/ila_lwt.c
101
return dst_output(net, sk, skb);
net/ipv6/ila/ila_lwt.c
135
static int ila_build_state(struct net *net, struct nlattr *nla,
net/ipv6/ila/ila_lwt.c
38
static int ila_output(struct net *net, struct sock *sk, struct sk_buff *skb)
net/ipv6/ila/ila_lwt.c
58
return orig_dst->lwtstate->orig_output(net, sk, skb);
net/ipv6/ila/ila_lwt.c
78
dst = ip6_route_output(net, NULL, &fl6);
net/ipv6/ila/ila_lwt.c
85
dst = xfrm_lookup(net, dst, flowi6_to_flowi(&fl6), NULL, 0);
net/ipv6/ila/ila_main.c
60
static __net_init int ila_init_net(struct net *net)
net/ipv6/ila/ila_main.c
64
err = ila_xlat_init_net(net);
net/ipv6/ila/ila_main.c
74
static __net_exit void ila_pre_exit_net(struct net *net)
net/ipv6/ila/ila_main.c
76
ila_xlat_pre_exit_net(net);
net/ipv6/ila/ila_main.c
79
static __net_exit void ila_exit_net(struct net *net)
net/ipv6/ila/ila_main.c
81
ila_xlat_exit_net(net);
net/ipv6/ila/ila_xlat.c
200
static int ila_add_mapping(struct net *net, struct ila_xlat_params *xp)
net/ipv6/ila/ila_xlat.c
202
struct ila_net *ilan = net_generic(net, ila_net_id);
net/ipv6/ila/ila_xlat.c
213
err = nf_register_net_hooks(net, ila_nf_hook_ops,
net/ipv6/ila/ila_xlat.c
283
static int ila_del_mapping(struct net *net, struct ila_xlat_params *xp)
net/ipv6/ila/ila_xlat.c
285
struct ila_net *ilan = net_generic(net, ila_net_id);
net/ipv6/ila/ila_xlat.c
347
struct net *net = genl_info_net(info);
net/ipv6/ila/ila_xlat.c
355
return ila_add_mapping(net, &p);
net/ipv6/ila/ila_xlat.c
360
struct net *net = genl_info_net(info);
net/ipv6/ila/ila_xlat.c
368
ila_del_mapping(net, &xp);
net/ipv6/ila/ila_xlat.c
381
struct net *net = genl_info_net(info);
net/ipv6/ila/ila_xlat.c
382
struct ila_net *ilan = net_generic(net, ila_net_id);
net/ipv6/ila/ila_xlat.c
463
struct net *net = genl_info_net(info);
net/ipv6/ila/ila_xlat.c
464
struct ila_net *ilan = net_generic(net, ila_net_id);
net/ipv6/ila/ila_xlat.c
508
struct net *net = sock_net(cb->skb->sk);
net/ipv6/ila/ila_xlat.c
509
struct ila_net *ilan = net_generic(net, ila_net_id);
net/ipv6/ila/ila_xlat.c
605
int ila_xlat_init_net(struct net *net)
net/ipv6/ila/ila_xlat.c
607
struct ila_net *ilan = net_generic(net, ila_net_id);
net/ipv6/ila/ila_xlat.c
623
void ila_xlat_pre_exit_net(struct net *net)
net/ipv6/ila/ila_xlat.c
625
struct ila_net *ilan = net_generic(net, ila_net_id);
net/ipv6/ila/ila_xlat.c
628
nf_unregister_net_hooks(net, ila_nf_hook_ops,
net/ipv6/ila/ila_xlat.c
632
void ila_xlat_exit_net(struct net *net)
net/ipv6/ila/ila_xlat.c
634
struct ila_net *ilan = net_generic(net, ila_net_id);
net/ipv6/ila/ila_xlat.c
645
struct net *net = dev_net(skb->dev);
net/ipv6/ila/ila_xlat.c
646
struct ila_net *ilan = net_generic(net, ila_net_id);
net/ipv6/inet6_hashtables.c
106
if (!inet6_match(net, sk, saddr, daddr, ports, dif, sdif))
net/ipv6/inet6_hashtables.c
111
if (unlikely(!inet6_match(net, sk, saddr, daddr, ports, dif, sdif))) {
net/ipv6/inet6_hashtables.c
126
static inline int compute_score(struct sock *sk, const struct net *net,
net/ipv6/inet6_hashtables.c
133
if (net_eq(sock_net(sk), net) &&
net/ipv6/inet6_hashtables.c
139
if (!inet_sk_bound_dev_eq(net, sk->sk_bound_dev_if, dif, sdif))
net/ipv6/inet6_hashtables.c
164
struct sock *inet6_lookup_reuseport(const struct net *net, struct sock *sk,
net/ipv6/inet6_hashtables.c
177
net, daddr, hnum, saddr, sport);
net/ipv6/inet6_hashtables.c
185
static struct sock *inet6_lhash2_lookup(const struct net *net,
net/ipv6/inet6_hashtables.c
197
score = compute_score(sk, net, hnum, daddr, dif, sdif);
net/ipv6/inet6_hashtables.c
199
result = inet6_lookup_reuseport(net, sk, skb, doff,
net/ipv6/inet6_hashtables.c
212
struct sock *inet6_lookup_run_sk_lookup(const struct net *net,
net/ipv6/inet6_hashtables.c
224
no_reuseport = bpf_sk_lookup_run_v6(net, protocol, saddr, sport,
net/ipv6/inet6_hashtables.c
229
reuse_sk = inet6_lookup_reuseport(net, sk, skb, doff,
net/ipv6/inet6_hashtables.c
237
struct sock *inet6_lookup_listener(const struct net *net,
net/ipv6/inet6_hashtables.c
252
result = inet6_lookup_run_sk_lookup(net, IPPROTO_TCP, skb, doff,
net/ipv6/inet6_hashtables.c
259
hashinfo = net->ipv4.tcp_death_row.hashinfo;
net/ipv6/inet6_hashtables.c
260
hash2 = ipv6_portaddr_hash(net, daddr, hnum);
net/ipv6/inet6_hashtables.c
263
result = inet6_lhash2_lookup(net, ilb2, skb, doff,
net/ipv6/inet6_hashtables.c
270
hash2 = ipv6_portaddr_hash(net, &in6addr_any, hnum);
net/ipv6/inet6_hashtables.c
273
result = inet6_lhash2_lookup(net, ilb2, skb, doff,
net/ipv6/inet6_hashtables.c
283
struct sock *inet6_lookup(const struct net *net,
net/ipv6/inet6_hashtables.c
292
sk = __inet6_lookup(net, skb, doff, saddr, sport, daddr,
net/ipv6/inet6_hashtables.c
311
struct net *net = sock_net(sk);
net/ipv6/inet6_hashtables.c
312
const int sdif = l3mdev_master_ifindex_by_index(net, dif);
net/ipv6/inet6_hashtables.c
323
!inet6_match(net, sk2, saddr, daddr,
net/ipv6/inet6_hashtables.c
34
u32 inet6_ehashfn(const struct net *net,
net/ipv6/inet6_hashtables.c
340
if (likely(inet6_match(net, sk2, saddr, daddr, ports,
net/ipv6/inet6_hashtables.c
361
__NET_INC_STATS(net, LINUX_MIB_TIMEWAITRECYCLED);
net/ipv6/inet6_hashtables.c
394
const struct net *net = sock_net(sk);
net/ipv6/inet6_hashtables.c
403
hash_port0 = inet6_ehashfn(net, daddr, 0, saddr, inet->inet_dport);
net/ipv6/inet6_hashtables.c
53
a += (__force u32)laddr->s6_addr32[0] ^ net_hash_mix(net);
net/ipv6/inet6_hashtables.c
84
struct sock *__inet6_lookup_established(const struct net *net,
net/ipv6/inet6_hashtables.c
98
hashinfo = net->ipv4.tcp_death_row.hashinfo;
net/ipv6/inet6_hashtables.c
99
hash = inet6_ehashfn(net, daddr, hnum, saddr, sport);
net/ipv6/ioam6.c
1006
net->ipv6.ioam6_data = NULL;
net/ipv6/ioam6.c
1010
static void __net_exit ioam6_net_exit(struct net *net)
net/ipv6/ioam6.c
1012
struct ioam6_pernet_data *nsdata = ioam6_pernet(net);
net/ipv6/ioam6.c
635
void ioam6_event(enum ioam6_event_type type, struct net *net, gfp_t gfp,
net/ipv6/ioam6.c
641
if (!genl_has_listeners(&ioam6_genl_family, net,
net/ipv6/ioam6.c
665
genlmsg_multicast_netns(&ioam6_genl_family, net, skb, 0,
net/ipv6/ioam6.c
686
struct ioam6_namespace *ioam6_namespace(struct net *net, __be16 id)
net/ipv6/ioam6.c
688
struct ioam6_pernet_data *nsdata = ioam6_pernet(net);
net/ipv6/ioam6.c
980
static int __net_init ioam6_net_init(struct net *net)
net/ipv6/ioam6.c
990
net->ipv6.ioam6_data = nsdata;
net/ipv6/ioam6_iptunnel.c
240
static int ioam6_do_fill(struct net *net, struct sk_buff *skb)
net/ipv6/ioam6_iptunnel.c
249
ns = ioam6_namespace(net, trace->namespace_id);
net/ipv6/ioam6_iptunnel.c
256
static int ioam6_do_inline(struct net *net, struct sk_buff *skb,
net/ipv6/ioam6_iptunnel.c
289
return ioam6_do_fill(net, skb);
net/ipv6/ioam6_iptunnel.c
292
static int ioam6_do_encap(struct net *net, struct sk_buff *skb,
net/ipv6/ioam6_iptunnel.c
330
ipv6_dev_get_saddr(net, dst_dev(dst), &hdr->daddr,
net/ipv6/ioam6_iptunnel.c
335
return ioam6_do_fill(net, skb);
net/ipv6/ioam6_iptunnel.c
338
static int ioam6_output(struct net *net, struct sock *sk, struct sk_buff *skb)
net/ipv6/ioam6_iptunnel.c
378
err = ioam6_do_inline(net, skb, &ilwt->tuninfo, dst);
net/ipv6/ioam6_iptunnel.c
386
err = ioam6_do_encap(net, skb, &ilwt->tuninfo,
net/ipv6/ioam6_iptunnel.c
417
dst = ip6_route_output(net, NULL, &fl6);
net/ipv6/ioam6_iptunnel.c
448
return dst_output(net, sk, skb);
net/ipv6/ioam6_iptunnel.c
452
return orig_dst->lwtstate->orig_output(net, sk, skb);
net/ipv6/ioam6_iptunnel.c
99
static int ioam6_build_state(struct net *net, struct nlattr *nla,
net/ipv6/ip6_fib.c
1041
struct net *net)
net/ipv6/ip6_fib.c
107
void fib6_update_sernum(struct net *net, struct fib6_info *f6i)
net/ipv6/ip6_fib.c
1070
new_leaf = fib6_find_prefix(net, table, fn);
net/ipv6/ip6_fib.c
114
WRITE_ONCE(fn->fn_sernum, fib6_new_sernum(net));
net/ipv6/ip6_fib.c
1382
static void fib6_start_gc(struct net *net, struct fib6_info *rt)
net/ipv6/ip6_fib.c
1384
if (!timer_pending(&net->ipv6.ip6_fib_timer) &&
net/ipv6/ip6_fib.c
1386
mod_timer(&net->ipv6.ip6_fib_timer,
net/ipv6/ip6_fib.c
1387
jiffies + READ_ONCE(net->ipv6.sysctl.ip6_rt_gc_interval));
net/ipv6/ip6_fib.c
1390
void fib6_force_start_gc(struct net *net)
net/ipv6/ip6_fib.c
1392
if (!timer_pending(&net->ipv6.ip6_fib_timer))
net/ipv6/ip6_fib.c
1393
mod_timer(&net->ipv6.ip6_fib_timer,
net/ipv6/ip6_fib.c
1394
jiffies + READ_ONCE(net->ipv6.sysctl.ip6_rt_gc_interval));
net/ipv6/ip6_fib.c
1412
void fib6_update_sernum_upto_root(struct net *net, struct fib6_info *rt)
net/ipv6/ip6_fib.c
1414
__fib6_update_sernum_upto_root(rt, fib6_new_sernum(net));
net/ipv6/ip6_fib.c
1808
static struct fib6_info *fib6_find_prefix(struct net *net,
net/ipv6/ip6_fib.c
1815
return net->ipv6.fib6_null_entry;
net/ipv6/ip6_fib.c
184
static struct fib6_node *node_alloc(struct net *net)
net/ipv6/ip6_fib.c
1840
static struct fib6_node *fib6_repair_tree(struct net *net,
net/ipv6/ip6_fib.c
1852
rcu_assign_pointer(fn->leaf, net->ipv6.fib6_null_entry);
net/ipv6/ip6_fib.c
1897
new_fn_leaf = fib6_find_prefix(net, table, fn);
net/ipv6/ip6_fib.c
190
net->ipv6.rt6_stats->fib_nodes++;
net/ipv6/ip6_fib.c
1901
new_fn_leaf = net->ipv6.fib6_null_entry;
net/ipv6/ip6_fib.c
1932
read_lock(&net->ipv6.fib6_walker_lock);
net/ipv6/ip6_fib.c
1933
FOR_WALKERS(net, w) {
net/ipv6/ip6_fib.c
195
static void node_free_immediate(struct net *net, struct fib6_node *fn)
net/ipv6/ip6_fib.c
1956
read_unlock(&net->ipv6.fib6_walker_lock);
net/ipv6/ip6_fib.c
1958
node_free(net, fn);
net/ipv6/ip6_fib.c
1975
struct net *net = info->nl_net;
net/ipv6/ip6_fib.c
198
net->ipv6.rt6_stats->fib_nodes--;
net/ipv6/ip6_fib.c
1995
net->ipv6.rt6_stats->fib_rt_entries--;
net/ipv6/ip6_fib.c
1996
net->ipv6.rt6_stats->fib_discarded_routes++;
net/ipv6/ip6_fib.c
201
static void node_free(struct net *net, struct fib6_node *fn)
net/ipv6/ip6_fib.c
2024
read_lock(&net->ipv6.fib6_walker_lock);
net/ipv6/ip6_fib.c
2025
FOR_WALKERS(net, w) {
net/ipv6/ip6_fib.c
2034
read_unlock(&net->ipv6.fib6_walker_lock);
net/ipv6/ip6_fib.c
204
net->ipv6.rt6_stats->fib_nodes--;
net/ipv6/ip6_fib.c
2043
net->ipv6.rt6_stats->fib_route_nodes--;
net/ipv6/ip6_fib.c
2045
fn = fib6_repair_tree(net, table, fn);
net/ipv6/ip6_fib.c
2048
fib6_purge_rt(rt, fn, net);
net/ipv6/ip6_fib.c
2052
call_fib6_entry_notifiers(net, FIB_EVENT_ENTRY_DEL,
net/ipv6/ip6_fib.c
2055
call_fib6_entry_notifiers_replace(net, replace_rt);
net/ipv6/ip6_fib.c
2066
struct net *net = info->nl_net;
net/ipv6/ip6_fib.c
2072
if (rt == net->ipv6.fib6_null_entry)
net/ipv6/ip6_fib.c
213
static void fib6_link_table(struct net *net, struct fib6_table *tb)
net/ipv6/ip6_fib.c
2217
static int fib6_walk(struct net *net, struct fib6_walker *w)
net/ipv6/ip6_fib.c
2224
fib6_walker_link(net, w);
net/ipv6/ip6_fib.c
2227
fib6_walker_unlink(net, w);
net/ipv6/ip6_fib.c
2237
.nl_net = c->net,
net/ipv6/ip6_fib.c
228
hlist_add_head_rcu(&tb->tb6_hlist, &net->ipv6.fib_table_hash[h]);
net/ipv6/ip6_fib.c
2288
static void fib6_clean_tree(struct net *net, struct fib6_node *root,
net/ipv6/ip6_fib.c
2302
c.net = net;
net/ipv6/ip6_fib.c
2305
fib6_walk(net, &c.w);
net/ipv6/ip6_fib.c
2308
static void __fib6_clean_all(struct net *net,
net/ipv6/ip6_fib.c
2318
head = &net->ipv6.fib_table_hash[h];
net/ipv6/ip6_fib.c
2321
fib6_clean_tree(net, &table->tb6_root,
net/ipv6/ip6_fib.c
2329
void fib6_clean_all(struct net *net, int (*func)(struct fib6_info *, void *),
net/ipv6/ip6_fib.c
233
static struct fib6_table *fib6_alloc_table(struct net *net, u32 id)
net/ipv6/ip6_fib.c
2332
__fib6_clean_all(net, func, FIB6_NO_SERNUM_CHANGE, arg, false);
net/ipv6/ip6_fib.c
2335
void fib6_clean_all_skip_notify(struct net *net,
net/ipv6/ip6_fib.c
2339
__fib6_clean_all(net, func, FIB6_NO_SERNUM_CHANGE, arg, true);
net/ipv6/ip6_fib.c
2342
static void fib6_flush_trees(struct net *net)
net/ipv6/ip6_fib.c
2344
int new_sernum = fib6_new_sernum(net);
net/ipv6/ip6_fib.c
2346
__fib6_clean_all(net, NULL, new_sernum, NULL, false);
net/ipv6/ip6_fib.c
2390
static void fib6_gc_table(struct net *net,
net/ipv6/ip6_fib.c
2397
.nl_net = net,
net/ipv6/ip6_fib.c
2406
static void fib6_gc_all(struct net *net, struct fib6_gc_args *gc_args)
net/ipv6/ip6_fib.c
241
net->ipv6.fib6_null_entry);
net/ipv6/ip6_fib.c
2414
head = &net->ipv6.fib_table_hash[h];
net/ipv6/ip6_fib.c
2418
fib6_gc_table(net, table, gc_args);
net/ipv6/ip6_fib.c
2426
void fib6_run_gc(unsigned long expires, struct net *net, bool force)
net/ipv6/ip6_fib.c
2433
spin_lock_bh(&net->ipv6.fib6_gc_lock);
net/ipv6/ip6_fib.c
2434
} else if (!spin_trylock_bh(&net->ipv6.fib6_gc_lock)) {
net/ipv6/ip6_fib.c
2435
mod_timer(&net->ipv6.ip6_fib_timer, jiffies + HZ);
net/ipv6/ip6_fib.c
2438
ip6_rt_gc_interval = READ_ONCE(net->ipv6.sysctl.ip6_rt_gc_interval);
net/ipv6/ip6_fib.c
2442
fib6_gc_all(net, &gc_args);
net/ipv6/ip6_fib.c
2444
net->ipv6.ip6_rt_last_gc = now;
net/ipv6/ip6_fib.c
2447
mod_timer(&net->ipv6.ip6_fib_timer,
net/ipv6/ip6_fib.c
2450
timer_delete(&net->ipv6.ip6_fib_timer);
net/ipv6/ip6_fib.c
2451
spin_unlock_bh(&net->ipv6.fib6_gc_lock);
net/ipv6/ip6_fib.c
2456
struct net *arg = timer_container_of(arg, t, ipv6.ip6_fib_timer);
net/ipv6/ip6_fib.c
2461
static int __net_init fib6_net_init(struct net *net)
net/ipv6/ip6_fib.c
2466
err = fib6_notifier_init(net);
net/ipv6/ip6_fib.c
2471
net->ipv6.sysctl.multipath_hash_fields =
net/ipv6/ip6_fib.c
2474
spin_lock_init(&net->ipv6.fib6_gc_lock);
net/ipv6/ip6_fib.c
2475
rwlock_init(&net->ipv6.fib6_walker_lock);
net/ipv6/ip6_fib.c
2476
INIT_LIST_HEAD(&net->ipv6.fib6_walkers);
net/ipv6/ip6_fib.c
2477
timer_setup(&net->ipv6.ip6_fib_timer, fib6_gc_timer_cb, 0);
net/ipv6/ip6_fib.c
2479
net->ipv6.rt6_stats = kzalloc_obj(*net->ipv6.rt6_stats);
net/ipv6/ip6_fib.c
2480
if (!net->ipv6.rt6_stats)
net/ipv6/ip6_fib.c
2486
net->ipv6.fib_table_hash = kzalloc(size, GFP_KERNEL);
net/ipv6/ip6_fib.c
2487
if (!net->ipv6.fib_table_hash)
net/ipv6/ip6_fib.c
2490
spin_lock_init(&net->ipv6.fib_table_hash_lock);
net/ipv6/ip6_fib.c
2492
net->ipv6.fib6_main_tbl = kzalloc_obj(*net->ipv6.fib6_main_tbl);
net/ipv6/ip6_fib.c
2493
if (!net->ipv6.fib6_main_tbl)
net/ipv6/ip6_fib.c
2496
net->ipv6.fib6_main_tbl->tb6_id = RT6_TABLE_MAIN;
net/ipv6/ip6_fib.c
2497
rcu_assign_pointer(net->ipv6.fib6_main_tbl->tb6_root.leaf,
net/ipv6/ip6_fib.c
2498
net->ipv6.fib6_null_entry);
net/ipv6/ip6_fib.c
2499
net->ipv6.fib6_main_tbl->tb6_root.fn_flags =
net/ipv6/ip6_fib.c
250
struct fib6_table *fib6_new_table(struct net *net, u32 id)
net/ipv6/ip6_fib.c
2501
inet_peer_base_init(&net->ipv6.fib6_main_tbl->tb6_peers);
net/ipv6/ip6_fib.c
2502
INIT_HLIST_HEAD(&net->ipv6.fib6_main_tbl->tb6_gc_hlist);
net/ipv6/ip6_fib.c
2505
net->ipv6.fib6_local_tbl = kzalloc_obj(*net->ipv6.fib6_local_tbl);
net/ipv6/ip6_fib.c
2506
if (!net->ipv6.fib6_local_tbl)
net/ipv6/ip6_fib.c
2508
net->ipv6.fib6_local_tbl->tb6_id = RT6_TABLE_LOCAL;
net/ipv6/ip6_fib.c
2509
rcu_assign_pointer(net->ipv6.fib6_local_tbl->tb6_root.leaf,
net/ipv6/ip6_fib.c
2510
net->ipv6.fib6_null_entry);
net/ipv6/ip6_fib.c
2511
net->ipv6.fib6_local_tbl->tb6_root.fn_flags =
net/ipv6/ip6_fib.c
2513
inet_peer_base_init(&net->ipv6.fib6_local_tbl->tb6_peers);
net/ipv6/ip6_fib.c
2514
INIT_HLIST_HEAD(&net->ipv6.fib6_local_tbl->tb6_gc_hlist);
net/ipv6/ip6_fib.c
2516
fib6_tables_init(net);
net/ipv6/ip6_fib.c
2522
kfree(net->ipv6.fib6_main_tbl);
net/ipv6/ip6_fib.c
2525
kfree(net->ipv6.fib_table_hash);
net/ipv6/ip6_fib.c
2527
kfree(net->ipv6.rt6_stats);
net/ipv6/ip6_fib.c
2529
fib6_notifier_exit(net);
net/ipv6/ip6_fib.c
2533
static void fib6_net_exit(struct net *net)
net/ipv6/ip6_fib.c
2537
timer_delete_sync(&net->ipv6.ip6_fib_timer);
net/ipv6/ip6_fib.c
2540
struct hlist_head *head = &net->ipv6.fib_table_hash[i];
net/ipv6/ip6_fib.c
2550
kfree(net->ipv6.fib_table_hash);
net/ipv6/ip6_fib.c
2551
kfree(net->ipv6.rt6_stats);
net/ipv6/ip6_fib.c
2552
fib6_notifier_exit(net);
net/ipv6/ip6_fib.c
257
tb = fib6_get_table(net, id);
net/ipv6/ip6_fib.c
261
new_tb = fib6_alloc_table(net, id);
net/ipv6/ip6_fib.c
265
spin_lock_bh(&net->ipv6.fib_table_hash_lock);
net/ipv6/ip6_fib.c
2654
struct net *net)
net/ipv6/ip6_fib.c
2664
fib6_walker_link(net, &iter->w);
net/ipv6/ip6_fib.c
2668
struct net *net)
net/ipv6/ip6_fib.c
267
tb = fib6_get_table(net, id);
net/ipv6/ip6_fib.c
2683
hlist_first_rcu(&net->ipv6.fib_table_hash[h++]));
net/ipv6/ip6_fib.c
269
spin_unlock_bh(&net->ipv6.fib_table_hash_lock);
net/ipv6/ip6_fib.c
2705
struct net *net = seq_file_net(seq);
net/ipv6/ip6_fib.c
2724
fib6_walker_unlink(net, &iter->w);
net/ipv6/ip6_fib.c
2727
fib6_walker_unlink(net, &iter->w);
net/ipv6/ip6_fib.c
2729
iter->tbl = ipv6_route_seq_next_table(iter->tbl, net);
net/ipv6/ip6_fib.c
2733
ipv6_route_seq_setup_walk(iter, net);
net/ipv6/ip6_fib.c
274
fib6_link_table(net, new_tb);
net/ipv6/ip6_fib.c
2740
struct net *net = seq_file_net(seq);
net/ipv6/ip6_fib.c
2744
iter->tbl = ipv6_route_seq_next_table(NULL, net);
net/ipv6/ip6_fib.c
2750
ipv6_route_seq_setup_walk(iter, net);
net/ipv6/ip6_fib.c
276
spin_unlock_bh(&net->ipv6.fib_table_hash_lock);
net/ipv6/ip6_fib.c
2766
struct net *net = seq_file_net(seq);
net/ipv6/ip6_fib.c
2770
fib6_walker_unlink(net, &iter->w);
net/ipv6/ip6_fib.c
282
struct fib6_table *fib6_get_table(struct net *net, u32 id)
net/ipv6/ip6_fib.c
290
head = &net->ipv6.fib_table_hash[id & (FIB6_TABLE_HASHSZ - 1)];
net/ipv6/ip6_fib.c
303
static void __net_init fib6_tables_init(struct net *net)
net/ipv6/ip6_fib.c
305
fib6_link_table(net, net->ipv6.fib6_main_tbl);
net/ipv6/ip6_fib.c
306
fib6_link_table(net, net->ipv6.fib6_local_tbl);
net/ipv6/ip6_fib.c
310
struct fib6_table *fib6_new_table(struct net *net, u32 id)
net/ipv6/ip6_fib.c
312
return fib6_get_table(net, id);
net/ipv6/ip6_fib.c
315
struct fib6_table *fib6_get_table(struct net *net, u32 id)
net/ipv6/ip6_fib.c
317
return net->ipv6.fib6_main_tbl;
net/ipv6/ip6_fib.c
320
struct dst_entry *fib6_rule_lookup(struct net *net, struct flowi6 *fl6,
net/ipv6/ip6_fib.c
327
net, net->ipv6.fib6_main_tbl, fl6, skb, flags);
net/ipv6/ip6_fib.c
330
rt = net->ipv6.ip6_null_entry;
net/ipv6/ip6_fib.c
339
int fib6_lookup(struct net *net, int oif, struct flowi6 *fl6,
net/ipv6/ip6_fib.c
342
return fib6_table_lookup(net, net->ipv6.fib6_main_tbl, oif, fl6,
net/ipv6/ip6_fib.c
349
static void __net_init fib6_tables_init(struct net *net)
net/ipv6/ip6_fib.c
351
fib6_link_table(net, net->ipv6.fib6_main_tbl);
net/ipv6/ip6_fib.c
356
unsigned int fib6_tables_seq_read(const struct net *net)
net/ipv6/ip6_fib.c
362
const struct hlist_head *head = &net->ipv6.fib_table_hash[h];
net/ipv6/ip6_fib.c
401
int call_fib6_entry_notifiers(struct net *net,
net/ipv6/ip6_fib.c
412
return call_fib6_notifiers(net, event_type, &info.info);
net/ipv6/ip6_fib.c
415
int call_fib6_multipath_entry_notifiers(struct net *net,
net/ipv6/ip6_fib.c
428
return call_fib6_notifiers(net, event_type, &info.info);
net/ipv6/ip6_fib.c
431
int call_fib6_entry_notifiers_replace(struct net *net, struct fib6_info *rt)
net/ipv6/ip6_fib.c
439
return call_fib6_notifiers(net, FIB_EVENT_ENTRY_REPLACE, &info.info);
net/ipv6/ip6_fib.c
44
struct net *net;
net/ipv6/ip6_fib.c
443
struct net *net;
net/ipv6/ip6_fib.c
454
if (!rt || rt == arg->net->ipv6.fib6_null_entry)
net/ipv6/ip6_fib.c
479
static int fib6_table_dump(struct net *net, struct fib6_table *tb,
net/ipv6/ip6_fib.c
486
err = fib6_walk(net, w);
net/ipv6/ip6_fib.c
492
int fib6_tables_dump(struct net *net, struct notifier_block *nb,
net/ipv6/ip6_fib.c
505
arg.net = net;
net/ipv6/ip6_fib.c
511
struct hlist_head *head = &net->ipv6.fib_table_hash[h];
net/ipv6/ip6_fib.c
515
err = fib6_table_dump(net, tb, w);
net/ipv6/ip6_fib.c
564
struct net *net = sock_net(cb->skb->sk);
net/ipv6/ip6_fib.c
57
static struct fib6_info *fib6_find_prefix(struct net *net,
net/ipv6/ip6_fib.c
570
fib6_walker_unlink(net, w);
net/ipv6/ip6_fib.c
588
struct net *net = sock_net(skb->sk);
net/ipv6/ip6_fib.c
60
static struct fib6_node *fib6_repair_tree(struct net *net,
net/ipv6/ip6_fib.c
601
res = fib6_walk(net, w);
net/ipv6/ip6_fib.c
623
fib6_walker_unlink(net, w);
net/ipv6/ip6_fib.c
63
static int fib6_walk(struct net *net, struct fib6_walker *w);
net/ipv6/ip6_fib.c
638
struct net *net = sock_net(skb->sk);
net/ipv6/ip6_fib.c
648
err = ip_valid_fib_dump_req(net, nlh, &arg.filter, cb);
net/ipv6/ip6_fib.c
681
arg.net = net;
net/ipv6/ip6_fib.c
685
tb = fib6_get_table(net, arg.filter.table_id);
net/ipv6/ip6_fib.c
707
head = &net->ipv6.fib_table_hash[h];
net/ipv6/ip6_fib.c
75
#define FOR_WALKERS(net, w) \
net/ipv6/ip6_fib.c
76
list_for_each_entry(w, &(net)->ipv6.fib6_walkers, lh)
net/ipv6/ip6_fib.c
763
static struct fib6_node *fib6_add_1(struct net *net,
net/ipv6/ip6_fib.c
78
static void fib6_walker_link(struct net *net, struct fib6_walker *w)
net/ipv6/ip6_fib.c
80
write_lock_bh(&net->ipv6.fib6_walker_lock);
net/ipv6/ip6_fib.c
81
list_add(&w->lh, &net->ipv6.fib6_walkers);
net/ipv6/ip6_fib.c
815
net->ipv6.fib6_null_entry) {
net/ipv6/ip6_fib.c
82
write_unlock_bh(&net->ipv6.fib6_walker_lock);
net/ipv6/ip6_fib.c
85
static void fib6_walker_unlink(struct net *net, struct fib6_walker *w)
net/ipv6/ip6_fib.c
859
ln = node_alloc(net);
net/ipv6/ip6_fib.c
87
write_lock_bh(&net->ipv6.fib6_walker_lock);
net/ipv6/ip6_fib.c
89
write_unlock_bh(&net->ipv6.fib6_walker_lock);
net/ipv6/ip6_fib.c
900
in = node_alloc(net);
net/ipv6/ip6_fib.c
901
ln = node_alloc(net);
net/ipv6/ip6_fib.c
905
node_free_immediate(net, in);
net/ipv6/ip6_fib.c
907
node_free_immediate(net, ln);
net/ipv6/ip6_fib.c
92
static int fib6_new_sernum(struct net *net)
net/ipv6/ip6_fib.c
94
int new, old = atomic_read(&net->ipv6.fib6_sernum);
net/ipv6/ip6_fib.c
952
ln = node_alloc(net);
net/ipv6/ip6_fib.c
98
} while (!atomic_try_cmpxchg(&net->ipv6.fib6_sernum, &old, new));
net/ipv6/ip6_flowlabel.c
184
static void __net_exit ip6_fl_purge(struct net *net)
net/ipv6/ip6_flowlabel.c
196
if (net_eq(fl->fl_net, net) &&
net/ipv6/ip6_flowlabel.c
201
net->ipv6.flowlabel_count--;
net/ipv6/ip6_flowlabel.c
210
static struct ip6_flowlabel *fl_intern(struct net *net,
net/ipv6/ip6_flowlabel.c
223
lfl = __fl_lookup(net, fl->label);
net/ipv6/ip6_flowlabel.c
237
lfl = __fl_lookup(net, fl->label);
net/ipv6/ip6_flowlabel.c
248
net->ipv6.flowlabel_count++;
net/ipv6/ip6_flowlabel.c
369
fl_create(struct net *net, struct sock *sk, struct in6_flowlabel_req *freq,
net/ipv6/ip6_flowlabel.c
409
err = ip6_datagram_send_ctl(net, sk, &msg, &flowi6, &ipc6);
net/ipv6/ip6_flowlabel.c
421
fl->fl_net = net;
net/ipv6/ip6_flowlabel.c
468
struct net *net = sock_net(sk);
net/ipv6/ip6_flowlabel.c
489
net->ipv6.flowlabel_count >= unpriv_user_limit) &&
net/ipv6/ip6_flowlabel.c
585
struct net *net = sock_net(sk);
net/ipv6/ip6_flowlabel.c
601
ns_capable(net->user_ns, CAP_NET_ADMIN)) {
net/ipv6/ip6_flowlabel.c
602
struct ip6_flowlabel *fl = fl_lookup(net, freq->flr_label);
net/ipv6/ip6_flowlabel.c
619
struct net *net = sock_net(sk);
net/ipv6/ip6_flowlabel.c
623
if (READ_ONCE(net->ipv6.sysctl.flowlabel_consistency)) {
net/ipv6/ip6_flowlabel.c
636
if (READ_ONCE(net->ipv6.sysctl.flowlabel_state_ranges) &&
net/ipv6/ip6_flowlabel.c
640
fl = fl_create(net, sk, freq, optval, optlen, &err);
net/ipv6/ip6_flowlabel.c
664
fl1 = fl_lookup(net, freq->flr_label);
net/ipv6/ip6_flowlabel.c
707
fl1 = fl_intern(net, fl, freq->flr_label);
net/ipv6/ip6_flowlabel.c
74
static inline struct ip6_flowlabel *__fl_lookup(struct net *net, __be32 label)
net/ipv6/ip6_flowlabel.c
771
struct net *net = seq_file_net(seq);
net/ipv6/ip6_flowlabel.c
775
if (net_eq(fl->fl_net, net))
net/ipv6/ip6_flowlabel.c
787
struct net *net = seq_file_net(seq);
net/ipv6/ip6_flowlabel.c
79
if (fl->label == label && net_eq(fl->fl_net, net))
net/ipv6/ip6_flowlabel.c
790
if (net_eq(fl->fl_net, net))
net/ipv6/ip6_flowlabel.c
797
if (net_eq(fl->fl_net, net))
net/ipv6/ip6_flowlabel.c
85
static struct ip6_flowlabel *fl_lookup(struct net *net, __be32 label)
net/ipv6/ip6_flowlabel.c
878
static int __net_init ip6_flowlabel_proc_init(struct net *net)
net/ipv6/ip6_flowlabel.c
880
if (!proc_create_net("ip6_flowlabel", 0444, net->proc_net,
net/ipv6/ip6_flowlabel.c
886
static void __net_exit ip6_flowlabel_proc_fini(struct net *net)
net/ipv6/ip6_flowlabel.c
888
remove_proc_entry("ip6_flowlabel", net->proc_net);
net/ipv6/ip6_flowlabel.c
891
static inline int ip6_flowlabel_proc_init(struct net *net)
net/ipv6/ip6_flowlabel.c
895
static inline void ip6_flowlabel_proc_fini(struct net *net)
net/ipv6/ip6_flowlabel.c
90
fl = __fl_lookup(net, label);
net/ipv6/ip6_flowlabel.c
900
static void __net_exit ip6_flowlabel_net_exit(struct net *net)
net/ipv6/ip6_flowlabel.c
902
ip6_fl_purge(net);
net/ipv6/ip6_flowlabel.c
903
ip6_flowlabel_proc_fini(net);
net/ipv6/ip6_gre.c
1132
struct rt6_info *rt = rt6_lookup(t->net,
net/ipv6/ip6_gre.c
1262
struct net *net = t->net;
net/ipv6/ip6_gre.c
1263
struct ip6gre_net *ign = net_generic(net, ip6gre_net_id);
net/ipv6/ip6_gre.c
1275
t = ip6gre_tunnel_locate(net, &p1, 0);
net/ipv6/ip6_gre.c
1288
if (!ns_capable(net->user_ns, CAP_NET_ADMIN))
net/ipv6/ip6_gre.c
1305
t = ip6gre_tunnel_locate(net, &p1, cmd == SIOCADDTUNNEL);
net/ipv6/ip6_gre.c
1337
if (!ns_capable(net->user_ns, CAP_NET_ADMIN))
net/ipv6/ip6_gre.c
1346
t = ip6gre_tunnel_locate(net, &p1, 0);
net/ipv6/ip6_gre.c
144
struct net *net = dev_net(dev);
net/ipv6/ip6_gre.c
149
struct ip6gre_net *ign = net_generic(net, ip6gre_net_id);
net/ipv6/ip6_gre.c
1541
tunnel->net = dev_net(dev);
net/ipv6/ip6_gre.c
1553
static void __net_exit ip6gre_exit_rtnl_net(struct net *net, struct list_head *head)
net/ipv6/ip6_gre.c
1555
struct ip6gre_net *ign = net_generic(net, ip6gre_net_id);
net/ipv6/ip6_gre.c
1559
for_each_netdev_safe(net, dev, aux)
net/ipv6/ip6_gre.c
1570
t = rtnl_net_dereference(net, ign->tunnels[prio][h]);
net/ipv6/ip6_gre.c
1576
if (!net_eq(dev_net(t->dev), net))
net/ipv6/ip6_gre.c
1579
t = rtnl_net_dereference(net, t->next);
net/ipv6/ip6_gre.c
1585
static int __net_init ip6gre_init_net(struct net *net)
net/ipv6/ip6_gre.c
1587
struct ip6gre_net *ign = net_generic(net, ip6gre_net_id);
net/ipv6/ip6_gre.c
1591
if (!net_has_fallback_tunnels(net))
net/ipv6/ip6_gre.c
1600
dev_net_set(ign->fb_tunnel_dev, net);
net/ipv6/ip6_gre.c
1943
static int ip6gre_newlink_common(struct net *link_net, struct net_device *dev,
net/ipv6/ip6_gre.c
1964
nt->net = link_net;
net/ipv6/ip6_gre.c
1981
struct net *net = params->link_net ? : dev_net(dev);
net/ipv6/ip6_gre.c
1989
ign = net_generic(net, ip6gre_net_id);
net/ipv6/ip6_gre.c
1995
if (ip6gre_tunnel_find(net, &nt->parms, dev->type))
net/ipv6/ip6_gre.c
1999
err = ip6gre_newlink_common(net, dev, tb, data, extack);
net/ipv6/ip6_gre.c
2003
ip6gre_tunnel_link(net_generic(net, ip6gre_net_id), nt);
net/ipv6/ip6_gre.c
2014
struct net *net = nt->net;
net/ipv6/ip6_gre.c
2015
struct ip6gre_net *ign = net_generic(net, ip6gre_net_id);
net/ipv6/ip6_gre.c
2030
t = ip6gre_tunnel_locate(net, p_p, 0);
net/ipv6/ip6_gre.c
2047
struct ip6gre_net *ign = net_generic(t->net, ip6gre_net_id);
net/ipv6/ip6_gre.c
2050
if (!rtnl_dev_link_net_capable(dev, t->net))
net/ipv6/ip6_gre.c
2067
struct net *net = dev_net(dev);
net/ipv6/ip6_gre.c
2068
struct ip6gre_net *ign = net_generic(net, ip6gre_net_id);
net/ipv6/ip6_gre.c
2222
struct net *net = params->link_net ? : dev_net(dev);
net/ipv6/ip6_gre.c
2231
ign = net_generic(net, ip6gre_net_id);
net/ipv6/ip6_gre.c
2237
if (ip6gre_tunnel_find(net, &nt->parms, dev->type))
net/ipv6/ip6_gre.c
2241
err = ip6gre_newlink_common(net, dev, tb, data, extack);
net/ipv6/ip6_gre.c
2245
ip6gre_tunnel_link(net_generic(net, ip6gre_net_id), nt);
net/ipv6/ip6_gre.c
2272
if (!rtnl_dev_link_net_capable(dev, t->net))
net/ipv6/ip6_gre.c
2275
ign = net_generic(t->net, ip6gre_net_id);
net/ipv6/ip6_gre.c
290
static struct ip6_tnl *ip6gre_tunnel_find(struct net *net,
net/ipv6/ip6_gre.c
300
struct ip6gre_net *ign = net_generic(net, ip6gre_net_id);
net/ipv6/ip6_gre.c
315
static struct ip6_tnl *ip6gre_tunnel_locate(struct net *net,
net/ipv6/ip6_gre.c
321
struct ip6gre_net *ign = net_generic(net, ip6gre_net_id);
net/ipv6/ip6_gre.c
323
t = ip6gre_tunnel_find(net, parms, ARPHRD_IP6GRE);
net/ipv6/ip6_gre.c
341
dev_net_set(dev, net);
net/ipv6/ip6_gre.c
348
nt->net = dev_net(dev);
net/ipv6/ip6_gre.c
365
struct ip6gre_net *ign = net_generic(t->net, ip6gre_net_id);
net/ipv6/ip6_gre.c
376
struct ip6gre_net *ign = net_generic(t->net, ip6gre_net_id);
net/ipv6/ip6_gre.c
390
struct net *net = dev_net(skb->dev);
net/ipv6/ip6_gre.c
440
ip6_update_pmtu(skb, net, info, 0, 0, sock_net_uid(net, NULL));
net/ipv6/ip6_gre.c
443
ip6_redirect(skb, net, skb->dev->ifindex, 0,
net/ipv6/ip6_gre.c
444
sock_net_uid(net, NULL));
net/ipv6/ip6_input.c
109
int ip6_rcv_finish(struct net *net, struct sock *sk, struct sk_buff *skb)
net/ipv6/ip6_input.c
117
ip6_rcv_finish_core(net, sk, skb);
net/ipv6/ip6_input.c
139
static struct sk_buff *ip6_extract_route_hint(const struct net *net,
net/ipv6/ip6_input.c
142
if (fib6_routes_require_src(net) || fib6_has_custom_rules(net) ||
net/ipv6/ip6_input.c
149
static void ip6_list_rcv_finish(struct net *net, struct sock *sk,
net/ipv6/ip6_input.c
170
ip6_rcv_finish_core(net, sk, skb);
net/ipv6/ip6_input.c
173
hint = ip6_extract_route_hint(net, skb);
net/ipv6/ip6_input.c
189
struct net *net)
net/ipv6/ip6_input.c
206
__IP6_UPD_PO_STATS(net, idev, IPSTATS_MIB_IN, skb->len);
net/ipv6/ip6_input.c
211
__IP6_INC_STATS(net, idev, IPSTATS_MIB_INDISCARDS);
net/ipv6/ip6_input.c
244
__IP6_ADD_STATS(net, idev,
net/ipv6/ip6_input.c
310
__IP6_INC_STATS(net,
net/ipv6/ip6_input.c
322
__IP6_INC_STATS(net, idev, IPSTATS_MIB_INHDRERRORS);
net/ipv6/ip6_input.c
336
__IP6_INC_STATS(net, idev, IPSTATS_MIB_INHDRERRORS);
net/ipv6/ip6_input.c
346
struct net *net = dev_net(skb->dev);
net/ipv6/ip6_input.c
348
skb = ip6_rcv_core(skb, dev, net);
net/ipv6/ip6_input.c
352
net, NULL, skb, dev, NULL,
net/ipv6/ip6_input.c
357
struct net *net)
net/ipv6/ip6_input.c
359
NF_HOOK_LIST(NFPROTO_IPV6, NF_INET_PRE_ROUTING, net, NULL,
net/ipv6/ip6_input.c
361
ip6_list_rcv_finish(net, NULL, head);
net/ipv6/ip6_input.c
369
struct net *curr_net = NULL;
net/ipv6/ip6_input.c
375
struct net *net = dev_net(dev);
net/ipv6/ip6_input.c
378
skb = ip6_rcv_core(skb, dev, net);
net/ipv6/ip6_input.c
382
if (curr_dev != dev || curr_net != net) {
net/ipv6/ip6_input.c
389
curr_net = net;
net/ipv6/ip6_input.c
403
void ip6_protocol_deliver_rcu(struct net *net, struct sk_buff *skb, int nexthdr,
net/ipv6/ip6_input.c
456
dev = dev_get_by_index_rcu(net, sdif);
net/ipv6/ip6_input.c
498
__IP6_INC_STATS(net, idev, IPSTATS_MIB_INDELIVERS);
net/ipv6/ip6_input.c
503
__IP6_INC_STATS(net, idev,
net/ipv6/ip6_input.c
51
struct net *net = dev_net_rcu(skb->dev);
net/ipv6/ip6_input.c
513
__IP6_INC_STATS(net, idev, IPSTATS_MIB_INDELIVERS);
net/ipv6/ip6_input.c
520
__IP6_INC_STATS(net, idev, IPSTATS_MIB_INDISCARDS);
net/ipv6/ip6_input.c
524
static int ip6_input_finish(struct net *net, struct sock *sk, struct sk_buff *skb)
net/ipv6/ip6_input.c
527
__IP6_INC_STATS(net, ip6_dst_idev(skb_dst(skb)),
net/ipv6/ip6_input.c
534
ip6_protocol_deliver_rcu(net, skb, 0, false);
net/ipv6/ip6_input.c
70
sk = __inet6_lookup_established(net, &hdr->saddr, th->source,
net/ipv6/ip6_input.c
88
static void ip6_rcv_finish_core(struct net *net, struct sock *sk,
net/ipv6/ip6_input.c
91
if (READ_ONCE(net->ipv4.sysctl_ip_early_demux) &&
net/ipv6/ip6_input.c
95
if (READ_ONCE(net->ipv4.sysctl_tcp_early_demux))
net/ipv6/ip6_input.c
99
if (READ_ONCE(net->ipv4.sysctl_udp_early_demux))
net/ipv6/ip6_output.c
1008
IP6_INC_STATS(net, ip6_dst_idev(&rt->dst),
net/ipv6/ip6_output.c
1016
IP6_INC_STATS(net, ip6_dst_idev(&rt->dst),
net/ipv6/ip6_output.c
1055
err = output(net, sk, frag);
net/ipv6/ip6_output.c
1059
IP6_INC_STATS(net, ip6_dst_idev(skb_dst(skb)),
net/ipv6/ip6_output.c
106
IP6_UPD_PO_STATS(net, idev, IPSTATS_MIB_OUTMCAST, skb->len);
net/ipv6/ip6_output.c
1062
IP6_INC_STATS(net, ip6_dst_idev(skb_dst(skb)),
net/ipv6/ip6_output.c
1072
IP6_INC_STATS(net, ip6_dst_idev(skb_dst(skb)),
net/ipv6/ip6_output.c
1135
static int ip6_dst_lookup_tail(struct net *net, const struct sock *sk,
net/ipv6/ip6_output.c
1158
*dst = ip6_route_output(net, sk, fl6);
net/ipv6/ip6_output.c
1163
err = ip6_route_get_saddr(net, from, &fl6->daddr,
net/ipv6/ip6_output.c
1186
*dst = ip6_route_output_flags(net, sk, fl6, flags);
net/ipv6/ip6_output.c
121
IP6_UPD_PO_STATS(net, idev, IPSTATS_MIB_OUT, skb->len);
net/ipv6/ip6_output.c
1213
ifp = ipv6_get_ifaddr(net, &fl6->saddr,
net/ipv6/ip6_output.c
1228
*dst = ip6_route_output(net, sk, &fl_gw6);
net/ipv6/ip6_output.c
1248
IP6_INC_STATS(net, NULL, IPSTATS_MIB_OUTNOROUTES);
net/ipv6/ip6_output.c
1263
int ip6_dst_lookup(struct net *net, struct sock *sk, struct dst_entry **dst,
net/ipv6/ip6_output.c
1267
return ip6_dst_lookup_tail(net, sk, dst, fl6);
net/ipv6/ip6_output.c
1283
struct dst_entry *ip6_dst_lookup_flow(struct net *net, const struct sock *sk, struct flowi6 *fl6,
net/ipv6/ip6_output.c
1291
err = ip6_dst_lookup_tail(net, sk, &dst, fl6);
net/ipv6/ip6_output.c
1297
return xfrm_lookup_route(net, dst, flowi6_to_flowi(fl6), sk, 0);
net/ipv6/ip6_output.c
130
IP6_INC_STATS(net, idev, IPSTATS_MIB_OUTNOROUTES);
net/ipv6/ip6_output.c
141
ip6_finish_output_gso_slowpath_drop(struct net *net, struct sock *sk,
net/ipv6/ip6_output.c
170
ip6_fragment(net, sk, segs, ip6_finish_output2) :
net/ipv6/ip6_output.c
171
ip6_finish_output2(net, sk, segs);
net/ipv6/ip6_output.c
179
static int ip6_finish_output_gso(struct net *net, struct sock *sk,
net/ipv6/ip6_output.c
183
return ip6_finish_output_gso_slowpath_drop(net, sk, skb, mtu);
net/ipv6/ip6_output.c
185
return ip6_finish_output2(net, sk, skb);
net/ipv6/ip6_output.c
188
static int __ip6_finish_output(struct net *net, struct sock *sk, struct sk_buff *skb)
net/ipv6/ip6_output.c
1929
struct net *net = sock_net(sk);
net/ipv6/ip6_output.c
196
return dst_output(net, sk, skb);
net/ipv6/ip6_output.c
1973
ip6_make_flowlabel(net, skb, fl6->flowlabel,
net/ipv6/ip6_output.c
1974
ip6_autoflowlabel(net, sk), fl6));
net/ipv6/ip6_output.c
1988
IP6_INC_STATS(net, rt->rt6i_idev, IPSTATS_MIB_OUTREQUESTS);
net/ipv6/ip6_output.c
1998
ICMP6MSGOUT_INC_STATS(net, idev, icmp6_type);
net/ipv6/ip6_output.c
1999
ICMP6_INC_STATS(net, idev, ICMP6_MIB_OUTMSGS);
net/ipv6/ip6_output.c
2009
struct net *net = sock_net(skb->sk);
net/ipv6/ip6_output.c
2014
err = ip6_local_out(net, skb->sk, skb);
net/ipv6/ip6_output.c
2019
IP6_INC_STATS(net, rt->rt6i_idev,
net/ipv6/ip6_output.c
202
return ip6_finish_output_gso(net, sk, skb, mtu);
net/ipv6/ip6_output.c
206
return ip6_fragment(net, sk, skb, ip6_finish_output2);
net/ipv6/ip6_output.c
208
return ip6_finish_output2(net, sk, skb);
net/ipv6/ip6_output.c
211
static int ip6_finish_output(struct net *net, struct sock *sk, struct sk_buff *skb)
net/ipv6/ip6_output.c
219
return __ip6_finish_output(net, sk, skb) ? : ret;
net/ipv6/ip6_output.c
226
int ip6_output(struct net *net, struct sock *sk, struct sk_buff *skb)
net/ipv6/ip6_output.c
240
IP6_INC_STATS(net, idev, IPSTATS_MIB_OUTDISCARDS);
net/ipv6/ip6_output.c
247
net, sk, skb, indev, dev,
net/ipv6/ip6_output.c
255
bool ip6_autoflowlabel(struct net *net, const struct sock *sk)
net/ipv6/ip6_output.c
258
return ip6_default_np_autolabel(net);
net/ipv6/ip6_output.c
296
struct net *net = sock_net(sk);
net/ipv6/ip6_output.c
316
IP6_INC_STATS(net, idev, IPSTATS_MIB_OUTDISCARDS);
net/ipv6/ip6_output.c
349
ip6_flow_hdr(hdr, tclass, ip6_make_flowlabel(net, skb, fl6->flowlabel,
net/ipv6/ip6_output.c
350
ip6_autoflowlabel(net, sk), fl6));
net/ipv6/ip6_output.c
365
IP6_INC_STATS(net, idev, IPSTATS_MIB_OUTREQUESTS);
net/ipv6/ip6_output.c
380
net, (struct sock *)sk, skb, NULL, dev,
net/ipv6/ip6_output.c
392
IP6_INC_STATS(net, idev, IPSTATS_MIB_FRAGFAILS);
net/ipv6/ip6_output.c
487
static inline int ip6_forward_finish(struct net *net, struct sock *sk,
net/ipv6/ip6_output.c
498
return dst_output(net, sk, skb);
net/ipv6/ip6_output.c
524
struct net *net = dev_net(dst_dev(dst));
net/ipv6/ip6_output.c
530
idev = __in6_dev_get_safely(dev_get_by_index_rcu(net, IP6CB(skb)->iif));
net/ipv6/ip6_output.c
531
if (!READ_ONCE(net->ipv6.devconf_all->forwarding) &&
net/ipv6/ip6_output.c
544
if (!READ_ONCE(net->ipv6.devconf_all->disable_policy) &&
net/ipv6/ip6_output.c
547
__IP6_INC_STATS(net, idev, IPSTATS_MIB_INDISCARDS);
net/ipv6/ip6_output.c
576
__IP6_INC_STATS(net, idev, IPSTATS_MIB_INHDRERRORS);
net/ipv6/ip6_output.c
583
if (READ_ONCE(net->ipv6.devconf_all->proxy_ndp) &&
net/ipv6/ip6_output.c
584
pneigh_lookup(&nd_tbl, net, &hdr->daddr, skb->dev)) {
net/ipv6/ip6_output.c
60
static int ip6_finish_output2(struct net *net, struct sock *sk, struct sk_buff *skb)
net/ipv6/ip6_output.c
605
__IP6_INC_STATS(net, idev, IPSTATS_MIB_INDISCARDS);
net/ipv6/ip6_output.c
611
__IP6_INC_STATS(net, idev, IPSTATS_MIB_INDISCARDS);
net/ipv6/ip6_output.c
639
peer = inet_getpeer_v6(net->ipv6.peers, &hdr->daddr);
net/ipv6/ip6_output.c
661
__IP6_INC_STATS(net, ip6_dst_idev(dst), IPSTATS_MIB_OUTFORWDATAGRAMS);
net/ipv6/ip6_output.c
671
__IP6_INC_STATS(net, idev, IPSTATS_MIB_INTOOBIGERRORS);
net/ipv6/ip6_output.c
672
__IP6_INC_STATS(net, ip6_dst_idev(dst),
net/ipv6/ip6_output.c
679
__IP6_INC_STATS(net, ip6_dst_idev(dst),
net/ipv6/ip6_output.c
691
net, NULL, skb, skb->dev, dev,
net/ipv6/ip6_output.c
695
__IP6_INC_STATS(net, idev, IPSTATS_MIB_INADDRERRORS);
net/ipv6/ip6_output.c
76
IP6_INC_STATS(net, idev, IPSTATS_MIB_OUTDISCARDS);
net/ipv6/ip6_output.c
85
((mroute6_is_socket(net, skb) &&
net/ipv6/ip6_output.c
885
int ip6_fragment(struct net *net, struct sock *sk, struct sk_buff *skb,
net/ipv6/ip6_output.c
886
int (*output)(struct net *, struct sock *, struct sk_buff *))
net/ipv6/ip6_output.c
940
frag_id = ipv6_select_ident(net, &ipv6_hdr(skb)->daddr,
net/ipv6/ip6_output.c
95
net, sk, newskb, NULL, newskb->dev,
net/ipv6/ip6_output.c
99
IP6_INC_STATS(net, idev,
net/ipv6/ip6_output.c
994
err = output(net, sk, skb);
net/ipv6/ip6_output.c
996
IP6_INC_STATS(net, ip6_dst_idev(&rt->dst),
net/ipv6/ip6_tunnel.c
1045
struct net *net = t->net;
net/ipv6/ip6_tunnel.c
1057
ldev = dev_get_by_index_rcu(net, p->link);
net/ipv6/ip6_tunnel.c
1059
if (unlikely(!ipv6_chk_addr_and_flags(net, laddr, ldev, false,
net/ipv6/ip6_tunnel.c
1065
unlikely(ipv6_chk_addr_and_flags(net, raddr, ldev,
net/ipv6/ip6_tunnel.c
1102
struct net *net = t->net;
net/ipv6/ip6_tunnel.c
115
ip6_tnl_lookup(struct net *net, int link,
net/ipv6/ip6_tunnel.c
1177
dst = ip6_route_output(net, NULL, fl6);
net/ipv6/ip6_tunnel.c
1181
dst = xfrm_lookup(net, dst, flowi6_to_flowi(fl6), NULL, 0);
net/ipv6/ip6_tunnel.c
1188
ipv6_dev_get_saddr(net, ip6_dst_idev(dst)->dev,
net/ipv6/ip6_tunnel.c
120
struct ip6_tnl_net *ip6n = net_generic(net, ip6_tnl_net_id);
net/ipv6/ip6_tunnel.c
1229
skb_scrub_packet(skb, !net_eq(t->net, dev_net(dev)));
net/ipv6/ip6_tunnel.c
1288
ip6_make_flowlabel(net, skb, fl6->flowlabel, true, fl6));
net/ipv6/ip6_tunnel.c
1513
struct rt6_info *rt = rt6_lookup(t->net,
net/ipv6/ip6_tunnel.c
1522
tdev = __dev_get_by_index(t->net, p->link);
net/ipv6/ip6_tunnel.c
1567
struct net *net = t->net;
net/ipv6/ip6_tunnel.c
1568
struct ip6_tnl_net *ip6n = net_generic(net, ip6_tnl_net_id);
net/ipv6/ip6_tunnel.c
1660
struct net *net = t->net;
net/ipv6/ip6_tunnel.c
1661
struct ip6_tnl_net *ip6n = net_generic(net, ip6_tnl_net_id);
net/ipv6/ip6_tunnel.c
1673
t = ip6_tnl_locate(net, &p1, 0);
net/ipv6/ip6_tunnel.c
1686
if (!ns_capable(net->user_ns, CAP_NET_ADMIN))
net/ipv6/ip6_tunnel.c
1696
t = ip6_tnl_locate(net, &p1, cmd == SIOCADDTUNNEL);
net/ipv6/ip6_tunnel.c
1722
if (!ns_capable(net->user_ns, CAP_NET_ADMIN))
net/ipv6/ip6_tunnel.c
1731
t = ip6_tnl_locate(net, &p1, 0);
net/ipv6/ip6_tunnel.c
1996
struct net *net = dev_net(dev);
net/ipv6/ip6_tunnel.c
1997
struct ip6_tnl_net *ip6n = net_generic(net, ip6_tnl_net_id);
net/ipv6/ip6_tunnel.c
1999
t->net = net;
net/ipv6/ip6_tunnel.c
2071
struct net *net;
net/ipv6/ip6_tunnel.c
2074
net = params->link_net ? : dev_net(dev);
net/ipv6/ip6_tunnel.c
2075
ip6n = net_generic(net, ip6_tnl_net_id);
net/ipv6/ip6_tunnel.c
2077
nt->net = net;
net/ipv6/ip6_tunnel.c
2091
t = ip6_tnl_locate(net, &nt->parms, 0);
net/ipv6/ip6_tunnel.c
2109
struct net *net = t->net;
net/ipv6/ip6_tunnel.c
2110
struct ip6_tnl_net *ip6n = net_generic(net, ip6_tnl_net_id);
net/ipv6/ip6_tunnel.c
2113
if (!rtnl_dev_link_net_capable(dev, net))
net/ipv6/ip6_tunnel.c
2149
t = ip6_tnl_locate(net, &p, 0);
net/ipv6/ip6_tunnel.c
2162
struct net *net = dev_net(dev);
net/ipv6/ip6_tunnel.c
2163
struct ip6_tnl_net *ip6n = net_generic(net, ip6_tnl_net_id);
net/ipv6/ip6_tunnel.c
2235
struct net *ip6_tnl_get_link_net(const struct net_device *dev)
net/ipv6/ip6_tunnel.c
2239
return READ_ONCE(tunnel->net);
net/ipv6/ip6_tunnel.c
2293
static void __net_exit ip6_tnl_exit_rtnl_net(struct net *net, struct list_head *list)
net/ipv6/ip6_tunnel.c
2295
struct ip6_tnl_net *ip6n = net_generic(net, ip6_tnl_net_id);
net/ipv6/ip6_tunnel.c
2300
for_each_netdev_safe(net, dev, aux)
net/ipv6/ip6_tunnel.c
2305
t = rtnl_net_dereference(net, ip6n->tnls_r_l[h]);
net/ipv6/ip6_tunnel.c
2310
if (!net_eq(dev_net(t->dev), net))
net/ipv6/ip6_tunnel.c
2313
t = rtnl_net_dereference(net, t->next);
net/ipv6/ip6_tunnel.c
2317
t = rtnl_net_dereference(net, ip6n->tnls_wc[0]);
net/ipv6/ip6_tunnel.c
2322
if (!net_eq(dev_net(t->dev), net))
net/ipv6/ip6_tunnel.c
2325
t = rtnl_net_dereference(net, t->next);
net/ipv6/ip6_tunnel.c
2329
static int __net_init ip6_tnl_init_net(struct net *net)
net/ipv6/ip6_tunnel.c
2331
struct ip6_tnl_net *ip6n = net_generic(net, ip6_tnl_net_id);
net/ipv6/ip6_tunnel.c
2338
if (!net_has_fallback_tunnels(net))
net/ipv6/ip6_tunnel.c
2346
dev_net_set(ip6n->fb_tnl_dev, net);
net/ipv6/ip6_tunnel.c
256
struct ip6_tnl_net *ip6n = net_generic(t->net, ip6_tnl_net_id);
net/ipv6/ip6_tunnel.c
285
static struct ip6_tnl *ip6_tnl_create(struct net *net, struct __ip6_tnl_parm *p)
net/ipv6/ip6_tunnel.c
305
dev_net_set(dev, net);
net/ipv6/ip6_tunnel.c
309
t->net = dev_net(dev);
net/ipv6/ip6_tunnel.c
337
static struct ip6_tnl *ip6_tnl_locate(struct net *net,
net/ipv6/ip6_tunnel.c
344
struct ip6_tnl_net *ip6n = net_generic(net, ip6_tnl_net_id);
net/ipv6/ip6_tunnel.c
360
return ip6_tnl_create(net, p);
net/ipv6/ip6_tunnel.c
375
struct net *net = t->net;
net/ipv6/ip6_tunnel.c
376
struct ip6_tnl_net *ip6n = net_generic(net, ip6_tnl_net_id);
net/ipv6/ip6_tunnel.c
474
struct net *net = dev_net(skb->dev);
net/ipv6/ip6_tunnel.c
536
ip6_update_pmtu(skb, net, htonl(*info), 0, 0,
net/ipv6/ip6_tunnel.c
537
sock_net_uid(net, NULL));
net/ipv6/ip6_tunnel.c
551
ip6_redirect(skb, net, skb->dev->ifindex, 0,
net/ipv6/ip6_tunnel.c
552
sock_net_uid(net, NULL));
net/ipv6/ip6_tunnel.c
783
struct net *net = t->net;
net/ipv6/ip6_tunnel.c
791
ldev = dev_get_by_index_rcu(net, p->link);
net/ipv6/ip6_tunnel.c
794
likely(ipv6_chk_addr_and_flags(net, laddr, ldev, false,
net/ipv6/ip6_tunnel.c
797
likely(!ipv6_chk_addr_and_flags(net, raddr, ldev, true,
net/ipv6/ip6_tunnel.c
870
__skb_tunnel_rx(skb, tunnel->dev, tunnel->net);
net/ipv6/ip6_tunnel.c
887
skb_scrub_packet(skb, !net_eq(tunnel->net, dev_net(tunnel->dev)));
net/ipv6/ip6_udp_tunnel.c
137
struct net *net,
net/ipv6/ip6_udp_tunnel.c
165
dst = ip6_dst_lookup_flow(net, sk, &fl6, NULL);
net/ipv6/ip6_udp_tunnel.c
17
int udp_sock_create6(struct net *net, struct udp_port_cfg *cfg,
net/ipv6/ip6_udp_tunnel.c
24
err = sock_create_kern(net, AF_INET6, SOCK_DGRAM, 0, &sock);
net/ipv6/ip6_vti.c
1016
struct net *net;
net/ipv6/ip6_vti.c
1018
net = params->link_net ? : dev_net(dev);
net/ipv6/ip6_vti.c
1023
nt->net = net;
net/ipv6/ip6_vti.c
1025
if (vti6_locate(net, &nt->parms, 0))
net/ipv6/ip6_vti.c
1033
struct net *net = dev_net(dev);
net/ipv6/ip6_vti.c
1034
struct vti6_net *ip6n = net_generic(net, vti6_net_id);
net/ipv6/ip6_vti.c
1045
struct net *net = t->net;
net/ipv6/ip6_vti.c
1049
if (!rtnl_dev_link_net_capable(dev, net))
net/ipv6/ip6_vti.c
1052
ip6n = net_generic(net, vti6_net_id);
net/ipv6/ip6_vti.c
1058
t = vti6_locate(net, &p, 0);
net/ipv6/ip6_vti.c
1129
static void __net_exit vti6_exit_rtnl_net(struct net *net, struct list_head *list)
net/ipv6/ip6_vti.c
1131
struct vti6_net *ip6n = net_generic(net, vti6_net_id);
net/ipv6/ip6_vti.c
1136
t = rtnl_net_dereference(net, ip6n->tnls_r_l[h]);
net/ipv6/ip6_vti.c
1139
t = rtnl_net_dereference(net, t->next);
net/ipv6/ip6_vti.c
1143
t = rtnl_net_dereference(net, ip6n->tnls_wc[0]);
net/ipv6/ip6_vti.c
1148
static int __net_init vti6_init_net(struct net *net)
net/ipv6/ip6_vti.c
1150
struct vti6_net *ip6n = net_generic(net, vti6_net_id);
net/ipv6/ip6_vti.c
1157
if (!net_has_fallback_tunnels(net))
net/ipv6/ip6_vti.c
1165
dev_net_set(ip6n->fb_tnl_dev, net);
net/ipv6/ip6_vti.c
183
struct vti6_net *ip6n = net_generic(t->net, vti6_net_id);
net/ipv6/ip6_vti.c
201
static struct ip6_tnl *vti6_tnl_create(struct net *net, struct __ip6_tnl_parm *p)
net/ipv6/ip6_vti.c
220
dev_net_set(dev, net);
net/ipv6/ip6_vti.c
224
t->net = dev_net(dev);
net/ipv6/ip6_vti.c
252
static struct ip6_tnl *vti6_locate(struct net *net, struct __ip6_tnl_parm *p,
net/ipv6/ip6_vti.c
259
struct vti6_net *ip6n = net_generic(net, vti6_net_id);
net/ipv6/ip6_vti.c
274
return vti6_tnl_create(net, p);
net/ipv6/ip6_vti.c
287
struct vti6_net *ip6n = net_generic(t->net, vti6_net_id);
net/ipv6/ip6_vti.c
387
skb_scrub_packet(skb, !net_eq(t->net, dev_net(skb->dev)));
net/ipv6/ip6_vti.c
484
dst = xfrm_lookup_route(t->net, dst, fl, NULL, 0);
net/ipv6/ip6_vti.c
532
skb_scrub_packet(skb, !net_eq(t->net, dev_net(dev)));
net/ipv6/ip6_vti.c
536
err = dst_output(t->net, skb->sk, skb);
net/ipv6/ip6_vti.c
605
struct net *net = dev_net(skb->dev);
net/ipv6/ip6_vti.c
636
x = xfrm_state_lookup(net, mark, (const xfrm_address_t *)&iph->daddr,
net/ipv6/ip6_vti.c
642
ip6_redirect(skb, net, skb->dev->ifindex, 0,
net/ipv6/ip6_vti.c
643
sock_net_uid(net, NULL));
net/ipv6/ip6_vti.c
645
ip6_update_pmtu(skb, net, info, 0, 0, sock_net_uid(net, NULL));
net/ipv6/ip6_vti.c
679
struct rt6_info *rt = rt6_lookup(t->net,
net/ipv6/ip6_vti.c
689
tdev = __dev_get_by_index(t->net, p->link);
net/ipv6/ip6_vti.c
727
struct net *net = t->net;
net/ipv6/ip6_vti.c
731
ip6n = net_generic(net, vti6_net_id);
net/ipv6/ip6_vti.c
805
struct net *net = dev_net(dev);
net/ipv6/ip6_vti.c
806
struct vti6_net *ip6n = net_generic(net, vti6_net_id);
net/ipv6/ip6_vti.c
818
t = vti6_locate(net, &p1, 0);
net/ipv6/ip6_vti.c
831
if (!ns_capable(net->user_ns, CAP_NET_ADMIN))
net/ipv6/ip6_vti.c
844
if (!ns_capable(self->net->user_ns, CAP_NET_ADMIN))
net/ipv6/ip6_vti.c
846
t = vti6_locate(self->net, &p1, false);
net/ipv6/ip6_vti.c
857
t = vti6_locate(net, &p1, cmd == SIOCADDTUNNEL);
net/ipv6/ip6_vti.c
870
if (!ns_capable(net->user_ns, CAP_NET_ADMIN))
net/ipv6/ip6_vti.c
879
t = vti6_locate(net, &p1, 0);
net/ipv6/ip6_vti.c
90
vti6_tnl_lookup(struct net *net, const struct in6_addr *remote,
net/ipv6/ip6_vti.c
95
struct vti6_net *ip6n = net_generic(net, vti6_net_id);
net/ipv6/ip6_vti.c
967
struct net *net = dev_net(dev);
net/ipv6/ip6_vti.c
968
struct vti6_net *ip6n = net_generic(net, vti6_net_id);
net/ipv6/ip6_vti.c
970
t->net = net;
net/ipv6/ip6mr.c
1051
static void ip6mr_cache_resolve(struct net *net, struct mr_table *mrt,
net/ipv6/ip6mr.c
1074
rtnl_unicast(skb, net, NETLINK_CB(skb).portid);
net/ipv6/ip6mr.c
1077
ip6_mr_forward(net, mrt, skb->dev, skb, c);
net/ipv6/ip6mr.c
108
#define ip6mr_for_each_table(mrt, net) \
net/ipv6/ip6mr.c
109
list_for_each_entry_rcu(mrt, &net->ipv6.mr6_tables, list, \
net/ipv6/ip6mr.c
111
list_empty(&net->ipv6.mr6_tables))
net/ipv6/ip6mr.c
113
static struct mr_table *ip6mr_mr_table_iter(struct net *net,
net/ipv6/ip6mr.c
1186
struct net *net = read_pnet(&mrt->net);
net/ipv6/ip6mr.c
119
ret = list_entry_rcu(net->ipv6.mr6_tables.next,
net/ipv6/ip6mr.c
1193
if (!check_net(net)) {
net/ipv6/ip6mr.c
125
if (&ret->list == &net->ipv6.mr6_tables)
net/ipv6/ip6mr.c
1280
call_ip6mr_mfc_entry_notifiers(read_pnet(&mrt->net),
net/ipv6/ip6mr.c
1291
struct net *net = dev_net(dev);
net/ipv6/ip6mr.c
1299
ip6mr_for_each_table(mrt, net) {
net/ipv6/ip6mr.c
130
static struct mr_table *__ip6mr_get_table(struct net *net, u32 id)
net/ipv6/ip6mr.c
1310
static unsigned int ip6mr_seq_read(const struct net *net)
net/ipv6/ip6mr.c
1312
return atomic_read(&net->ipv6.ipmr_seq) + ip6mr_rules_seq_read(net);
net/ipv6/ip6mr.c
1315
static int ip6mr_dump(struct net *net, struct notifier_block *nb,
net/ipv6/ip6mr.c
1318
return mr_dump(net, nb, RTNL_FAMILY_IP6MR, ip6mr_rules_dump,
net/ipv6/ip6mr.c
1333
static int __net_init ip6mr_notifier_init(struct net *net)
net/ipv6/ip6mr.c
1337
atomic_set(&net->ipv6.ipmr_seq, 0);
net/ipv6/ip6mr.c
1339
ops = fib_notifier_ops_register(&ip6mr_notifier_ops_template, net);
net/ipv6/ip6mr.c
134
ip6mr_for_each_table(mrt, net) {
net/ipv6/ip6mr.c
1343
net->ipv6.ip6mr_notifier_ops = ops;
net/ipv6/ip6mr.c
1348
static void __net_exit ip6mr_notifier_exit(struct net *net)
net/ipv6/ip6mr.c
1350
fib_notifier_ops_unregister(net->ipv6.ip6mr_notifier_ops);
net/ipv6/ip6mr.c
1351
net->ipv6.ip6mr_notifier_ops = NULL;
net/ipv6/ip6mr.c
1355
static int __net_init ip6mr_net_init(struct net *net)
net/ipv6/ip6mr.c
1362
mutex_init(&net->ipv6.mfc_mutex);
net/ipv6/ip6mr.c
1364
err = ip6mr_notifier_init(net);
net/ipv6/ip6mr.c
1368
err = ip6mr_rules_init(net);
net/ipv6/ip6mr.c
1374
if (!proc_create_net("ip6_mr_vif", 0, net->proc_net, &ip6mr_vif_seq_ops,
net/ipv6/ip6mr.c
1377
if (!proc_create_net("ip6_mr_cache", 0, net->proc_net, &ipmr_mfc_seq_ops,
net/ipv6/ip6mr.c
1386
remove_proc_entry("ip6_mr_vif", net->proc_net);
net/ipv6/ip6mr.c
1388
ip6mr_rules_exit_rtnl(net, &dev_kill_list);
net/ipv6/ip6mr.c
1389
ip6mr_rules_exit(net);
net/ipv6/ip6mr.c
1392
ip6mr_notifier_exit(net);
net/ipv6/ip6mr.c
1396
static void __net_exit ip6mr_net_exit(struct net *net)
net/ipv6/ip6mr.c
1399
remove_proc_entry("ip6_mr_cache", net->proc_net);
net/ipv6/ip6mr.c
1400
remove_proc_entry("ip6_mr_vif", net->proc_net);
net/ipv6/ip6mr.c
1402
ip6mr_rules_exit(net);
net/ipv6/ip6mr.c
1403
ip6mr_notifier_exit(net);
net/ipv6/ip6mr.c
1406
static void __net_exit ip6mr_net_exit_rtnl(struct net *net,
net/ipv6/ip6mr.c
1409
ip6mr_rules_exit_rtnl(net, dev_kill_list);
net/ipv6/ip6mr.c
141
static int ip6mr_fib_lookup(struct net *net, struct flowi6 *flp6,
net/ipv6/ip6mr.c
1474
static int ip6mr_mfc_add(struct net *net, struct mr_table *mrt,
net/ipv6/ip6mr.c
1503
call_ip6mr_mfc_entry_notifiers(net, FIB_EVENT_ENTRY_REPLACE,
net/ipv6/ip6mr.c
152
l3mdev_update_flow(net, flowi6_to_flowi(flp6));
net/ipv6/ip6mr.c
154
err = fib_rules_lookup(net->ipv6.mr6_rules_ops,
net/ipv6/ip6mr.c
1554
ip6mr_cache_resolve(net, mrt, uc, c);
net/ipv6/ip6mr.c
1557
call_ip6mr_mfc_entry_notifiers(net, FIB_EVENT_ENTRY_ADD,
net/ipv6/ip6mr.c
1570
struct net *net = read_pnet(&mrt->net);
net/ipv6/ip6mr.c
1587
mutex_lock(&net->ipv6.mfc_mutex);
net/ipv6/ip6mr.c
1595
call_ip6mr_mfc_entry_notifiers(net, FIB_EVENT_ENTRY_DEL,
net/ipv6/ip6mr.c
1601
mutex_unlock(&net->ipv6.mfc_mutex);
net/ipv6/ip6mr.c
1605
if (READ_ONCE(mrt->cache_resolve_queue_len) || !check_net(net)) {
net/ipv6/ip6mr.c
1621
struct net *net = sock_net(sk);
net/ipv6/ip6mr.c
1630
atomic_inc(&net->ipv6.devconf_all->mc_forwarding);
net/ipv6/ip6mr.c
1635
inet6_netconf_notify_devconf(net, RTM_NEWNETCONF,
net/ipv6/ip6mr.c
1638
net->ipv6.devconf_all);
net/ipv6/ip6mr.c
1646
struct net *net = sock_net(sk);
net/ipv6/ip6mr.c
1656
devconf = net->ipv6.devconf_all;
net/ipv6/ip6mr.c
1661
ip6mr_for_each_table(mrt, net) {
net/ipv6/ip6mr.c
1671
inet6_netconf_notify_devconf(net, RTM_NEWNETCONF,
net/ipv6/ip6mr.c
1674
net->ipv6.devconf_all);
net/ipv6/ip6mr.c
1688
bool mroute6_is_socket(struct net *net, struct sk_buff *skb)
net/ipv6/ip6mr.c
1697
if (ip6mr_fib_lookup(net, &fl6, &mrt) < 0)
net/ipv6/ip6mr.c
1718
struct net *net = sock_net(sk);
net/ipv6/ip6mr.c
1725
mrt = ip6mr_get_table(net, raw6_sk(sk)->ip6mr_table ? : RT6_TABLE_DFLT);
net/ipv6/ip6mr.c
1731
!ns_capable(net->user_ns, CAP_NET_ADMIN))
net/ipv6/ip6mr.c
1753
ret = mif6_add(net, mrt, &vif,
net/ipv6/ip6mr.c
1785
mutex_lock(&net->ipv6.mfc_mutex);
net/ipv6/ip6mr.c
1790
ret = ip6mr_mfc_add(net, mrt, &mfc,
net/ipv6/ip6mr.c
1795
mutex_unlock(&net->ipv6.mfc_mutex);
net/ipv6/ip6mr.c
1872
mrt = ip6mr_new_table(net, v);
net/ipv6/ip6mr.c
1899
struct net *net = sock_net(sk);
net/ipv6/ip6mr.c
1906
mrt = ip6mr_get_table(net, raw6_sk(sk)->ip6mr_table ? : RT6_TABLE_DFLT);
net/ipv6/ip6mr.c
1949
struct net *net = sock_net(sk);
net/ipv6/ip6mr.c
1952
mrt = ip6mr_get_table(net, raw6_sk(sk)->ip6mr_table ? : RT6_TABLE_DFLT);
net/ipv6/ip6mr.c
2017
struct net *net = sock_net(sk);
net/ipv6/ip6mr.c
2020
mrt = ip6mr_get_table(net, raw6_sk(sk)->ip6mr_table ? : RT6_TABLE_DFLT);
net/ipv6/ip6mr.c
2070
static inline int ip6mr_forward2_finish(struct net *net, struct sock *sk, struct sk_buff *skb)
net/ipv6/ip6mr.c
2072
IP6_INC_STATS(net, ip6_dst_idev(skb_dst(skb)),
net/ipv6/ip6mr.c
2074
return dst_output(net, sk, skb);
net/ipv6/ip6mr.c
2081
static int ip6mr_prepare_xmit(struct net *net, struct mr_table *mrt,
net/ipv6/ip6mr.c
2112
dst = ip6_route_output(net, NULL, &fl6);
net/ipv6/ip6mr.c
2146
static void ip6mr_forward2(struct net *net, struct mr_table *mrt,
net/ipv6/ip6mr.c
2151
if (ip6mr_prepare_xmit(net, mrt, skb, vifi))
net/ipv6/ip6mr.c
2157
net, NULL, skb, indev, skb->dev,
net/ipv6/ip6mr.c
2165
static void ip6mr_output2(struct net *net, struct mr_table *mrt,
net/ipv6/ip6mr.c
2168
if (ip6mr_prepare_xmit(net, mrt, skb, vifi))
net/ipv6/ip6mr.c
2171
ip6_output(net, NULL, skb);
net/ipv6/ip6mr.c
2192
static void ip6_mr_forward(struct net *net, struct mr_table *mrt,
net/ipv6/ip6mr.c
2275
ip6mr_forward2(net, mrt, skb2, psend);
net/ipv6/ip6mr.c
2282
ip6mr_forward2(net, mrt, skb, psend);
net/ipv6/ip6mr.c
229
static int __net_init ip6mr_rules_init(struct net *net)
net/ipv6/ip6mr.c
2291
static void ip6_mr_output_finish(struct net *net, struct mr_table *mrt,
net/ipv6/ip6mr.c
2326
ip6mr_output2(net, mrt, skb2, psend);
net/ipv6/ip6mr.c
2333
ip6mr_output2(net, mrt, skb, psend);
net/ipv6/ip6mr.c
2348
struct net *net = dev_net_rcu(dev);
net/ipv6/ip6mr.c
236
ops = fib_rules_register(&ip6mr_rules_ops_template, net);
net/ipv6/ip6mr.c
2361
dev = dev_get_by_index_rcu(net, IPCB(skb)->iif);
net/ipv6/ip6mr.c
2368
err = ip6mr_fib_lookup(net, &fl6, &mrt);
net/ipv6/ip6mr.c
240
INIT_LIST_HEAD(&net->ipv6.mr6_tables);
net/ipv6/ip6mr.c
2401
ip6_mr_forward(net, mrt, dev, skb, cache);
net/ipv6/ip6mr.c
2406
int ip6_mr_output(struct net *net, struct sock *sk, struct sk_buff *skb)
net/ipv6/ip6mr.c
242
mrt = ip6mr_new_table(net, RT6_TABLE_DFLT);
net/ipv6/ip6mr.c
2425
err = ip6mr_fib_lookup(net, &fl6, &mrt);
net/ipv6/ip6mr.c
2454
ip6_mr_output_finish(net, mrt, dev, skb, cache);
net/ipv6/ip6mr.c
2458
return ip6_output(net, sk, skb);
net/ipv6/ip6mr.c
2461
int ip6mr_get_route(struct net *net, struct sk_buff *skb, struct rtmsg *rtm,
net/ipv6/ip6mr.c
2470
mrt = __ip6mr_get_table(net, RT6_TABLE_DFLT);
net/ipv6/ip6mr.c
252
net->ipv6.mr6_rules_ops = ops;
net/ipv6/ip6mr.c
2609
struct net *net = read_pnet(&mrt->net);
net/ipv6/ip6mr.c
262
static void __net_exit ip6mr_rules_exit(struct net *net)
net/ipv6/ip6mr.c
2621
rtnl_notify(skb, net, 0, RTNLGRP_IPV6_MROUTE, NULL, GFP_ATOMIC);
net/ipv6/ip6mr.c
2626
rtnl_set_sk_err(net, RTNLGRP_IPV6_MROUTE, err);
net/ipv6/ip6mr.c
264
fib_rules_unregister(net->ipv6.mr6_rules_ops);
net/ipv6/ip6mr.c
2648
struct net *net = read_pnet(&mrt->net);
net/ipv6/ip6mr.c
267
static void __net_exit ip6mr_rules_exit_rtnl(struct net *net,
net/ipv6/ip6mr.c
2684
rtnl_notify(skb, net, 0, RTNLGRP_IPV6_MROUTE_R, NULL, GFP_ATOMIC);
net/ipv6/ip6mr.c
2691
rtnl_set_sk_err(net, RTNLGRP_IPV6_MROUTE_R, -ENOBUFS);
net/ipv6/ip6mr.c
272
list_for_each_entry_safe(mrt, next, &net->ipv6.mr6_tables, list) {
net/ipv6/ip6mr.c
2735
struct net *net = sock_net(in_skb->sk);
net/ipv6/ip6mr.c
2760
mrt = __ip6mr_get_table(net, tableid ?: RT_TABLE_DEFAULT);
net/ipv6/ip6mr.c
278
static int ip6mr_rules_dump(struct net *net, struct notifier_block *nb,
net/ipv6/ip6mr.c
2781
return rtnl_unicast(skb, net, NETLINK_CB(in_skb).portid);
net/ipv6/ip6mr.c
281
return fib_rules_dump(net, nb, RTNL_FAMILY_IP6MR, extack);
net/ipv6/ip6mr.c
284
static unsigned int ip6mr_rules_seq_read(const struct net *net)
net/ipv6/ip6mr.c
286
return fib_rules_seq_read(net, RTNL_FAMILY_IP6MR);
net/ipv6/ip6mr.c
296
static struct mr_table *ip6mr_mr_table_iter(struct net *net,
net/ipv6/ip6mr.c
300
return rcu_dereference(net->ipv6.mrt6);
net/ipv6/ip6mr.c
304
static struct mr_table *__ip6mr_get_table(struct net *net, u32 id)
net/ipv6/ip6mr.c
306
return rcu_dereference_check(net->ipv6.mrt6,
net/ipv6/ip6mr.c
308
!rcu_access_pointer(net->ipv6.mrt6));
net/ipv6/ip6mr.c
311
#define ip6mr_for_each_table(mrt, net) \
net/ipv6/ip6mr.c
312
for (mrt = __ip6mr_get_table(net, 0); mrt; mrt = NULL)
net/ipv6/ip6mr.c
314
static int ip6mr_fib_lookup(struct net *net, struct flowi6 *flp6,
net/ipv6/ip6mr.c
317
*mrt = rcu_dereference(net->ipv6.mrt6);
net/ipv6/ip6mr.c
323
static int __net_init ip6mr_rules_init(struct net *net)
net/ipv6/ip6mr.c
327
mrt = ip6mr_new_table(net, RT6_TABLE_DFLT);
net/ipv6/ip6mr.c
331
rcu_assign_pointer(net->ipv6.mrt6, mrt);
net/ipv6/ip6mr.c
335
static void __net_exit ip6mr_rules_exit(struct net *net)
net/ipv6/ip6mr.c
339
static void __net_exit ip6mr_rules_exit_rtnl(struct net *net,
net/ipv6/ip6mr.c
342
struct mr_table *mrt = rcu_dereference_protected(net->ipv6.mrt6, 1);
net/ipv6/ip6mr.c
344
RCU_INIT_POINTER(net->ipv6.mrt6, NULL);
net/ipv6/ip6mr.c
348
static int ip6mr_rules_dump(struct net *net, struct notifier_block *nb,
net/ipv6/ip6mr.c
354
static unsigned int ip6mr_rules_seq_read(const struct net *net)
net/ipv6/ip6mr.c
360
static struct mr_table *ip6mr_get_table(struct net *net, u32 id)
net/ipv6/ip6mr.c
365
mrt = __ip6mr_get_table(net, id);
net/ipv6/ip6mr.c
391
struct net *net)
net/ipv6/ip6mr.c
394
list_add_tail_rcu(&mrt->list, &net->ipv6.mr6_tables);
net/ipv6/ip6mr.c
408
static struct mr_table *ip6mr_new_table(struct net *net, u32 id)
net/ipv6/ip6mr.c
412
mrt = __ip6mr_get_table(net, id);
net/ipv6/ip6mr.c
416
return mr_table_alloc(net, id, &ip6mr_mr_table_ops,
net/ipv6/ip6mr.c
423
struct net *net = read_pnet(&mrt->net);
net/ipv6/ip6mr.c
426
WARN_ON_ONCE(!mr_can_free_table(net));
net/ipv6/ip6mr.c
435
WARN_ON_ONCE(!net_initialized(net) && !list_empty(&ip6mr_dev_kill_list));
net/ipv6/ip6mr.c
448
struct net *net = seq_file_net(seq);
net/ipv6/ip6mr.c
452
mrt = __ip6mr_get_table(net, RT6_TABLE_DFLT);
net/ipv6/ip6mr.c
504
struct net *net = seq_file_net(seq);
net/ipv6/ip6mr.c
507
mrt = ip6mr_get_table(net, RT6_TABLE_DFLT);
net/ipv6/ip6mr.c
571
struct net *net = dev_net(skb->dev);
net/ipv6/ip6mr.c
600
if (ip6mr_fib_lookup(net, &fl6, &mrt) < 0)
net/ipv6/ip6mr.c
636
struct net *net = dev_net(dev);
net/ipv6/ip6mr.c
649
if (ip6mr_fib_lookup(net, &fl6, &mrt) < 0)
net/ipv6/ip6mr.c
689
static struct net_device *ip6mr_reg_vif(struct net *net, struct mr_table *mrt)
net/ipv6/ip6mr.c
703
dev_net_set(dev, net);
net/ipv6/ip6mr.c
722
static int call_ip6mr_vif_entry_notifiers(struct net *net,
net/ipv6/ip6mr.c
728
return mr_call_vif_notifiers(net, RTNL_FAMILY_IP6MR, event_type,
net/ipv6/ip6mr.c
730
&net->ipv6.ipmr_seq);
net/ipv6/ip6mr.c
733
static int call_ip6mr_mfc_entry_notifiers(struct net *net,
net/ipv6/ip6mr.c
737
return mr_call_mfc_notifiers(net, RTNL_FAMILY_IP6MR, event_type,
net/ipv6/ip6mr.c
738
&mfc->_c, tb_id, &net->ipv6.ipmr_seq);
net/ipv6/ip6mr.c
758
call_ip6mr_vif_entry_notifiers(read_pnet(&mrt->net),
net/ipv6/ip6mr.c
817
struct net *net = read_pnet(&mrt->net);
net/ipv6/ip6mr.c
831
rtnl_unicast(skb, net, NETLINK_CB(skb).portid);
net/ipv6/ip6mr.c
87
static struct mr_table *ip6mr_new_table(struct net *net, u32 id);
net/ipv6/ip6mr.c
906
static int mif6_add(struct net *net, struct mr_table *mrt,
net/ipv6/ip6mr.c
91
static void ip6_mr_forward(struct net *net, struct mr_table *mrt,
net/ipv6/ip6mr.c
928
dev = ip6mr_reg_vif(net, mrt);
net/ipv6/ip6mr.c
940
dev = dev_get_by_index(net, vifc->mif6c_pifi);
net/ipv6/ip6mr.c
977
call_ip6mr_vif_entry_notifiers(net, FIB_EVENT_VIF_ADD,
net/ipv6/ipcomp6.c
115
struct net *net = xs_net(x);
net/ipv6/ipcomp6.c
121
spi = xfrm6_tunnel_spi_lookup(net, (xfrm_address_t *)&x->props.saddr);
net/ipv6/ipcomp6.c
123
t = xfrm_state_lookup(net, mark, (xfrm_address_t *)&x->id.daddr,
net/ipv6/ipcomp6.c
47
struct net *net = dev_net(skb->dev);
net/ipv6/ipcomp6.c
59
x = xfrm_state_lookup(net, skb->mark, (const xfrm_address_t *)&iph->daddr,
net/ipv6/ipcomp6.c
65
ip6_redirect(skb, net, skb->dev->ifindex, 0,
net/ipv6/ipcomp6.c
66
sock_net_uid(net, NULL));
net/ipv6/ipcomp6.c
68
ip6_update_pmtu(skb, net, info, 0, 0, sock_net_uid(net, NULL));
net/ipv6/ipcomp6.c
77
struct net *net = xs_net(x);
net/ipv6/ipcomp6.c
80
t = xfrm_state_alloc(net);
net/ipv6/ipcomp6.c
86
t->id.spi = xfrm6_tunnel_alloc_spi(net, (xfrm_address_t *)&x->props.saddr);
net/ipv6/ipv6_sockglue.c
307
struct net *net = sock_net(sk);
net/ipv6/ipv6_sockglue.c
312
if (optname != IPV6_RTHDR && !sockopt_ns_capable(net->user_ns, CAP_NET_RAW))
net/ipv6/ipv6_sockglue.c
380
struct net *net = sock_net(sk);
net/ipv6/ipv6_sockglue.c
504
dev = dev_get_by_index_rcu(net, val);
net/ipv6/ipv6_sockglue.c
535
dev = dev_get_by_index(net, ifindex);
net/ipv6/ipv6_sockglue.c
596
sock_prot_inuse_add(net, sk->sk_prot, -1);
net/ipv6/ipv6_sockglue.c
597
sock_prot_inuse_add(net, &tcp_prot, 1);
net/ipv6/ipv6_sockglue.c
607
sock_prot_inuse_add(net, sk->sk_prot, -1);
net/ipv6/ipv6_sockglue.c
608
sock_prot_inuse_add(net, &udp_prot, 1);
net/ipv6/ipv6_sockglue.c
749
if (valbool && !sockopt_ns_capable(net->user_ns, CAP_NET_RAW) &&
net/ipv6/ipv6_sockglue.c
750
!sockopt_ns_capable(net->user_ns, CAP_NET_ADMIN)) {
net/ipv6/ipv6_sockglue.c
844
retv = ip6_datagram_send_ctl(net, sk, &msg, &fl6, &ipc6);
net/ipv6/ipv6_sockglue.c
933
if (!sockopt_ns_capable(net->user_ns, CAP_NET_ADMIN))
net/ipv6/mcast.c
1245
const struct net *net = dev_net(idev->dev);
net/ipv6/mcast.c
1248
all_force = READ_ONCE(net->ipv6.devconf_all->force_mld_version);
net/ipv6/mcast.c
172
static struct net_device *ip6_mc_find_dev(struct net *net,
net/ipv6/mcast.c
1783
struct net *net;
net/ipv6/mcast.c
1799
net = dev_net_rcu(dev);
net/ipv6/mcast.c
1800
sk = net->ipv6.igmp_sk;
net/ipv6/mcast.c
181
rt = rt6_lookup(net, group, NULL, 0, NULL, 0);
net/ipv6/mcast.c
1836
struct net *net = dev_net(skb->dev);
net/ipv6/mcast.c
1843
IP6_INC_STATS(net, idev, IPSTATS_MIB_OUTREQUESTS);
net/ipv6/mcast.c
1855
icmpv6_flow_init(net->ipv6.igmp_sk, &fl6, ICMPV6_MLD2_REPORT,
net/ipv6/mcast.c
1870
net, net->ipv6.igmp_sk, skb, NULL, skb->dev,
net/ipv6/mcast.c
1874
ICMP6MSGOUT_INC_STATS(net, idev, ICMPV6_MLD2_REPORT);
net/ipv6/mcast.c
1875
ICMP6_INC_STATS(net, idev, ICMP6_MIB_OUTMSGS);
net/ipv6/mcast.c
1877
IP6_INC_STATS(net, idev, IPSTATS_MIB_OUTDISCARDS);
net/ipv6/mcast.c
189
dev = dev_get_by_index(net, ifindex);
net/ipv6/mcast.c
203
struct net *net = sock_net(sk);
net/ipv6/mcast.c
2188
struct net *net;
net/ipv6/mcast.c
2204
net = dev_net_rcu(dev);
net/ipv6/mcast.c
2206
IP6_INC_STATS(net, idev, IPSTATS_MIB_OUTREQUESTS);
net/ipv6/mcast.c
2208
IP6_INC_STATS(net, idev, IPSTATS_MIB_OUTDISCARDS);
net/ipv6/mcast.c
2212
sk = net->ipv6.igmp_sk;
net/ipv6/mcast.c
223
dev = ip6_mc_find_dev(net, addr, ifindex);
net/ipv6/mcast.c
2250
net, sk, skb, NULL, skb->dev,
net/ipv6/mcast.c
2254
ICMP6MSGOUT_INC_STATS(net, idev, type);
net/ipv6/mcast.c
2255
ICMP6_INC_STATS(net, idev, ICMP6_MIB_OUTMSGS);
net/ipv6/mcast.c
2257
IP6_INC_STATS(net, idev, IPSTATS_MIB_OUTDISCARDS);
net/ipv6/mcast.c
266
struct net *net = sock_net(sk);
net/ipv6/mcast.c
269
dev = dev_get_by_index(net, mc_lst->ifindex);
net/ipv6/mcast.c
2926
struct net *net = seq_file_net(seq);
net/ipv6/mcast.c
2929
for_each_netdev_rcu(net, state->dev) {
net/ipv6/mcast.c
3036
struct net *net = seq_file_net(seq);
net/ipv6/mcast.c
3040
for_each_netdev_rcu(net, state->dev) {
net/ipv6/mcast.c
313
static struct inet6_dev *ip6_mc_find_idev(struct net *net,
net/ipv6/mcast.c
3150
static int __net_init igmp6_proc_init(struct net *net)
net/ipv6/mcast.c
3155
if (!proc_create_net("igmp6", 0444, net->proc_net, &igmp6_mc_seq_ops,
net/ipv6/mcast.c
3158
if (!proc_create_net("mcfilter6", 0444, net->proc_net,
net/ipv6/mcast.c
3168
remove_proc_entry("igmp6", net->proc_net);
net/ipv6/mcast.c
3172
static void __net_exit igmp6_proc_exit(struct net *net)
net/ipv6/mcast.c
3174
remove_proc_entry("mcfilter6", net->proc_net);
net/ipv6/mcast.c
3175
remove_proc_entry("igmp6", net->proc_net);
net/ipv6/mcast.c
3178
static inline int igmp6_proc_init(struct net *net)
net/ipv6/mcast.c
3182
static inline void igmp6_proc_exit(struct net *net)
net/ipv6/mcast.c
3187
static int __net_init igmp6_net_init(struct net *net)
net/ipv6/mcast.c
3191
err = inet_ctl_sock_create(&net->ipv6.igmp_sk, PF_INET6,
net/ipv6/mcast.c
3192
SOCK_RAW, IPPROTO_ICMPV6, net);
net/ipv6/mcast.c
3199
inet6_sk(net->ipv6.igmp_sk)->hop_limit = 1;
net/ipv6/mcast.c
320
dev = ip6_mc_find_dev(net, group, ifindex);
net/ipv6/mcast.c
3200
net->ipv6.igmp_sk->sk_allocation = GFP_KERNEL;
net/ipv6/mcast.c
3202
err = inet_ctl_sock_create(&net->ipv6.mc_autojoin_sk, PF_INET6,
net/ipv6/mcast.c
3203
SOCK_RAW, IPPROTO_ICMPV6, net);
net/ipv6/mcast.c
3210
err = igmp6_proc_init(net);
net/ipv6/mcast.c
3217
inet_ctl_sock_destroy(net->ipv6.mc_autojoin_sk);
net/ipv6/mcast.c
3219
inet_ctl_sock_destroy(net->ipv6.igmp_sk);
net/ipv6/mcast.c
3224
static void __net_exit igmp6_net_exit(struct net *net)
net/ipv6/mcast.c
3226
inet_ctl_sock_destroy(net->ipv6.igmp_sk);
net/ipv6/mcast.c
3227
inet_ctl_sock_destroy(net->ipv6.mc_autojoin_sk);
net/ipv6/mcast.c
3228
igmp6_proc_exit(net);
net/ipv6/mcast.c
358
struct net *net = sock_net(sk);
net/ipv6/mcast.c
372
idev = ip6_mc_find_idev(net, group, pgsr->gsr_interface);
net/ipv6/mcast.c
492
struct net *net = sock_net(sk);
net/ipv6/mcast.c
507
idev = ip6_mc_find_idev(net, group, gsf->gf_interface);
net/ipv6/mcast.c
905
struct net *net = dev_net(dev);
net/ipv6/mcast.c
923
rtnl_notify(skb, net, 0, RTNLGRP_IPV6_MCADDR, NULL, GFP_KERNEL);
net/ipv6/mcast.c
926
rtnl_set_sk_err(net, RTNLGRP_IPV6_MCADDR, err);
net/ipv6/mip6.c
199
struct net *net = xs_net(x);
net/ipv6/mip6.c
243
err = km_report(net, IPPROTO_DSTOPTS, &sel,
net/ipv6/ndisc.c
1087
struct net *net = dev_net(dev);
net/ipv6/ndisc.c
1098
READ_ONCE(net->ipv6.devconf_all->forwarding) &&
net/ipv6/ndisc.c
1099
READ_ONCE(net->ipv6.devconf_all->proxy_ndp) &&
net/ipv6/ndisc.c
1100
pneigh_lookup(&nd_tbl, net, &msg->target, dev)) {
net/ipv6/ndisc.c
1188
struct net *net = dev_net(ra->dev);
net/ipv6/ndisc.c
1221
rtnl_notify(skb, net, 0, RTNLGRP_ND_USEROPT, NULL, GFP_ATOMIC);
net/ipv6/ndisc.c
1228
rtnl_set_sk_err(net, RTNLGRP_ND_USEROPT, err);
net/ipv6/ndisc.c
1243
struct net *net;
net/ipv6/ndisc.c
1332
net = dev_net(in6_dev->dev);
net/ipv6/ndisc.c
1334
ipv6_chk_addr(net, &ipv6_hdr(skb)->saddr, in6_dev->dev, 0)) {
net/ipv6/ndisc.c
1348
rt = rt6_get_dflt_router(net, &ipv6_hdr(skb)->saddr, skb->dev);
net/ipv6/ndisc.c
1364
ip6_del_rt(net, rt, false);
net/ipv6/ndisc.c
1376
rt = rt6_add_dflt_router(net, &ipv6_hdr(skb)->saddr,
net/ipv6/ndisc.c
1396
.nl_net = net,
net/ipv6/ndisc.c
1658
struct net *net = dev_net_rcu(dev);
net/ipv6/ndisc.c
1659
struct sock *sk = net->ipv6.ndisc_sk;
net/ipv6/ndisc.c
1674
dev = dev_get_by_index_rcu(net, IPCB(skb)->iif);
net/ipv6/ndisc.c
1693
dst = ip6_route_output(net, NULL, &fl6);
net/ipv6/ndisc.c
1698
dst = xfrm_lookup(net, dst, flowi6_to_flowi(&fl6), NULL, 0);
net/ipv6/ndisc.c
1709
peer = inet_getpeer_v6(net->ipv6.peers, &ipv6_hdr(skb)->saddr);
net/ipv6/ndisc.c
1858
struct net *net = dev_net(dev);
net/ipv6/ndisc.c
1865
fib6_run_gc(0, net, false);
net/ipv6/ndisc.c
1872
READ_ONCE(net->ipv6.devconf_all->ndisc_notify))
net/ipv6/ndisc.c
1882
READ_ONCE(net->ipv6.devconf_all->ndisc_evict_nocarrier);
net/ipv6/ndisc.c
1894
fib6_run_gc(0, net, false);
net/ipv6/ndisc.c
1966
static int __net_init ndisc_net_init(struct net *net)
net/ipv6/ndisc.c
1973
SOCK_RAW, IPPROTO_ICMPV6, net);
net/ipv6/ndisc.c
1980
net->ipv6.ndisc_sk = sk;
net/ipv6/ndisc.c
1990
static void __net_exit ndisc_net_exit(struct net *net)
net/ipv6/ndisc.c
1992
inet_ctl_sock_destroy(net->ipv6.ndisc_sk);
net/ipv6/ndisc.c
475
struct net *net;
net/ipv6/ndisc.c
484
net = dev_net_rcu(skb->dev);
net/ipv6/ndisc.c
485
sk = net->ipv6.ndisc_sk;
net/ipv6/ndisc.c
510
IP6_INC_STATS(net, idev, IPSTATS_MIB_OUTREQUESTS);
net/ipv6/ndisc.c
513
net, sk, skb, NULL, dev,
net/ipv6/ndisc.c
516
ICMP6MSGOUT_INC_STATS(net, idev, type);
net/ipv6/ndisc.c
517
ICMP6_INC_STATS(net, idev, ICMP6_MIB_OUTMSGS);
net/ipv6/ndisc.c
882
struct net *net = dev_net(dev);
net/ipv6/ndisc.c
890
ifp = ipv6_get_ifaddr(net, &msg->target, mdev, 1);
net/ipv6/ndisc.c
902
if (ipv6_chk_acast_addr(net, dev, &msg->target) ||
net/ipv6/ndisc.c
904
(READ_ONCE(net->ipv6.devconf_all->proxy_ndp) ||
net/ipv6/netfilter.c
102
result = ip6_route_output(net, sk, &fl->u.ip6);
net/ipv6/netfilter.c
112
int br_ip6_fragment(struct net *net, struct sock *sk, struct sk_buff *skb,
net/ipv6/netfilter.c
114
int (*output)(struct net *, struct sock *sk,
net/ipv6/netfilter.c
144
frag_id = ipv6_select_ident(net, &ipv6_hdr(skb)->daddr,
net/ipv6/netfilter.c
188
err = output(net, sk, data, skb);
net/ipv6/netfilter.c
221
err = output(net, sk, data, skb2);
net/ipv6/netfilter.c
24
int ip6_route_me_harder(struct net *net, struct sock *sk_partial, struct sk_buff *skb)
net/ipv6/netfilter.c
37
.flowi6_uid = sock_net_uid(net, sk),
net/ipv6/netfilter.c
49
fib6_rules_early_flow_dissect(net, skb, &fl6, &flkeys);
net/ipv6/netfilter.c
50
dst = ip6_route_output(net, sk, &fl6);
net/ipv6/netfilter.c
53
IP6_INC_STATS(net, ip6_dst_idev(dst), IPSTATS_MIB_OUTNOROUTES);
net/ipv6/netfilter.c
66
xfrm_decode_session(net, skb, flowi6_to_flowi(&fl6), AF_INET6) == 0) {
net/ipv6/netfilter.c
71
dst = xfrm_lookup(net, dst, flowi6_to_flowi(&fl6), sk, 0);
net/ipv6/netfilter.c
89
int __nf_ip6_route(struct net *net, struct dst_entry **dst,
net/ipv6/netfilter/ip6_tables.c
1017
get_entries(struct net *net, struct ip6t_get_entries __user *uptr,
net/ipv6/netfilter/ip6_tables.c
1033
t = xt_find_table_lock(net, AF_INET6, get.name);
net/ipv6/netfilter/ip6_tables.c
1051
__do_replace(struct net *net, const char *name, unsigned int valid_hooks,
net/ipv6/netfilter/ip6_tables.c
1067
t = xt_request_find_table_lock(net, AF_INET6, name);
net/ipv6/netfilter/ip6_tables.c
1097
cleanup_entry(iter, net);
net/ipv6/netfilter/ip6_tables.c
1118
do_replace(struct net *net, sockptr_t arg, unsigned int len)
net/ipv6/netfilter/ip6_tables.c
1152
ret = translate_table(net, newinfo, loc_cpu_entry, &tmp);
net/ipv6/netfilter/ip6_tables.c
1156
ret = __do_replace(net, tmp.name, tmp.valid_hooks, newinfo,
net/ipv6/netfilter/ip6_tables.c
1164
cleanup_entry(iter, net);
net/ipv6/netfilter/ip6_tables.c
1171
do_add_counters(struct net *net, sockptr_t arg, unsigned int len)
net/ipv6/netfilter/ip6_tables.c
1185
t = xt_find_table_lock(net, AF_INET6, tmp.name);
net/ipv6/netfilter/ip6_tables.c
1403
translate_compat_table(struct net *net,
net/ipv6/netfilter/ip6_tables.c
1473
ret = translate_table(net, newinfo, entry1, &repl);
net/ipv6/netfilter/ip6_tables.c
1497
compat_do_replace(struct net *net, sockptr_t arg, unsigned int len)
net/ipv6/netfilter/ip6_tables.c
1531
ret = translate_compat_table(net, &newinfo, &loc_cpu_entry, &tmp);
net/ipv6/netfilter/ip6_tables.c
1535
ret = __do_replace(net, tmp.name, tmp.valid_hooks, newinfo,
net/ipv6/netfilter/ip6_tables.c
1543
cleanup_entry(iter, net);
net/ipv6/netfilter/ip6_tables.c
1585
compat_get_entries(struct net *net, struct compat_ip6t_get_entries __user *uptr,
net/ipv6/netfilter/ip6_tables.c
1604
t = xt_find_table_lock(net, AF_INET6, get.name);
net/ipv6/netfilter/ip6_tables.c
1715
static void __ip6t_unregister_table(struct net *net, struct xt_table *table)
net/ipv6/netfilter/ip6_tables.c
1725
cleanup_entry(iter, net);
net/ipv6/netfilter/ip6_tables.c
1732
int ip6t_register_table(struct net *net, const struct xt_table *table,
net/ipv6/netfilter/ip6_tables.c
1749
ret = translate_table(net, newinfo, loc_cpu_entry, repl);
net/ipv6/netfilter/ip6_tables.c
1755
new_table = xt_register_table(net, table, template_ops, &bootstrap, newinfo);
net/ipv6/netfilter/ip6_tables.c
1760
cleanup_entry(iter, net);
net/ipv6/netfilter/ip6_tables.c
1768
void ip6t_unregister_table_exit(struct net *net, const char *name)
net/ipv6/netfilter/ip6_tables.c
1770
struct xt_table *table = xt_unregister_table_exit(net, NFPROTO_IPV6, name);
net/ipv6/netfilter/ip6_tables.c
1773
__ip6t_unregister_table(net, table);
net/ipv6/netfilter/ip6_tables.c
1807
static int __net_init ip6_tables_net_init(struct net *net)
net/ipv6/netfilter/ip6_tables.c
1809
return xt_proto_init(net, NFPROTO_IPV6);
net/ipv6/netfilter/ip6_tables.c
1812
static void __net_exit ip6_tables_net_exit(struct net *net)
net/ipv6/netfilter/ip6_tables.c
1814
xt_proto_fini(net, NFPROTO_IPV6);
net/ipv6/netfilter/ip6_tables.c
210
static void trace_packet(struct net *net,
net/ipv6/netfilter/ip6_tables.c
234
nf_log_trace(net, AF_INET6, hook, skb, in, out, &trace_loginfo,
net/ipv6/netfilter/ip6_tables.c
329
trace_packet(state->net, skb, hook, state->in,
net/ipv6/netfilter/ip6_tables.c
468
static void cleanup_match(struct xt_entry_match *m, struct net *net)
net/ipv6/netfilter/ip6_tables.c
472
par.net = net;
net/ipv6/netfilter/ip6_tables.c
515
static int check_target(struct ip6t_entry *e, struct net *net, const char *name)
net/ipv6/netfilter/ip6_tables.c
519
.net = net,
net/ipv6/netfilter/ip6_tables.c
534
find_check_entry(struct ip6t_entry *e, struct net *net, const char *name,
net/ipv6/netfilter/ip6_tables.c
550
mtpar.net = net;
net/ipv6/netfilter/ip6_tables.c
571
ret = check_target(e, net, name);
net/ipv6/netfilter/ip6_tables.c
581
cleanup_match(ematch, net);
net/ipv6/netfilter/ip6_tables.c
653
static void cleanup_entry(struct ip6t_entry *e, struct net *net)
net/ipv6/netfilter/ip6_tables.c
661
cleanup_match(ematch, net);
net/ipv6/netfilter/ip6_tables.c
664
par.net = net;
net/ipv6/netfilter/ip6_tables.c
677
translate_table(struct net *net, struct xt_table_info *newinfo, void *entry0,
net/ipv6/netfilter/ip6_tables.c
733
ret = find_check_entry(iter, net, repl->name, repl->size,
net/ipv6/netfilter/ip6_tables.c
744
cleanup_entry(iter, net);
net/ipv6/netfilter/ip6_tables.c
960
static int get_info(struct net *net, void __user *user, const int *len)
net/ipv6/netfilter/ip6_tables.c
977
t = xt_request_find_table_lock(net, AF_INET6, name);
net/ipv6/netfilter/ip6t_REJECT.c
38
struct net *net = xt_net(par);
net/ipv6/netfilter/ip6t_REJECT.c
42
nf_send_unreach6(net, skb, ICMPV6_NOROUTE, xt_hooknum(par));
net/ipv6/netfilter/ip6t_REJECT.c
45
nf_send_unreach6(net, skb, ICMPV6_ADM_PROHIBITED,
net/ipv6/netfilter/ip6t_REJECT.c
49
nf_send_unreach6(net, skb, ICMPV6_NOT_NEIGHBOUR,
net/ipv6/netfilter/ip6t_REJECT.c
53
nf_send_unreach6(net, skb, ICMPV6_ADDR_UNREACH,
net/ipv6/netfilter/ip6t_REJECT.c
57
nf_send_unreach6(net, skb, ICMPV6_PORT_UNREACH,
net/ipv6/netfilter/ip6t_REJECT.c
64
nf_send_reset6(net, par->state->sk, skb, xt_hooknum(par));
net/ipv6/netfilter/ip6t_REJECT.c
67
nf_send_unreach6(net, skb, ICMPV6_POLICY_FAIL, xt_hooknum(par));
net/ipv6/netfilter/ip6t_REJECT.c
70
nf_send_unreach6(net, skb, ICMPV6_REJECT_ROUTE,
net/ipv6/netfilter/ip6t_SYNPROXY.c
16
struct net *net = xt_net(par);
net/ipv6/netfilter/ip6t_SYNPROXY.c
17
struct synproxy_net *snet = synproxy_pernet(net);
net/ipv6/netfilter/ip6t_SYNPROXY.c
48
synproxy_send_client_synack_ipv6(net, skb, th, &opts);
net/ipv6/netfilter/ip6t_SYNPROXY.c
54
if (synproxy_recv_client_ack_ipv6(net, skb, th, &opts,
net/ipv6/netfilter/ip6t_SYNPROXY.c
68
struct synproxy_net *snet = synproxy_pernet(par->net);
net/ipv6/netfilter/ip6t_SYNPROXY.c
77
err = nf_ct_netns_get(par->net, par->family);
net/ipv6/netfilter/ip6t_SYNPROXY.c
81
err = nf_synproxy_ipv6_init(snet, par->net);
net/ipv6/netfilter/ip6t_SYNPROXY.c
83
nf_ct_netns_put(par->net, par->family);
net/ipv6/netfilter/ip6t_SYNPROXY.c
92
struct synproxy_net *snet = synproxy_pernet(par->net);
net/ipv6/netfilter/ip6t_SYNPROXY.c
94
nf_synproxy_ipv6_fini(snet, par->net);
net/ipv6/netfilter/ip6t_SYNPROXY.c
95
nf_ct_netns_put(par->net, par->family);
net/ipv6/netfilter/ip6t_rpfilter.c
32
static bool rpfilter_lookup_reverse6(struct net *net, const struct sk_buff *skb,
net/ipv6/netfilter/ip6t_rpfilter.c
43
.flowi6_uid = sock_net_uid(net, NULL),
net/ipv6/netfilter/ip6t_rpfilter.c
63
rt = (void *)ip6_route_lookup(net, &fl6, skb, lookup_flags);
net/ipv6/netfilter/ip6table_filter.c
36
static int ip6table_filter_table_init(struct net *net)
net/ipv6/netfilter/ip6table_filter.c
48
err = ip6t_register_table(net, &packet_filter, repl, filter_ops);
net/ipv6/netfilter/ip6table_filter.c
53
static int __net_init ip6table_filter_net_init(struct net *net)
net/ipv6/netfilter/ip6table_filter.c
56
return ip6table_filter_table_init(net);
net/ipv6/netfilter/ip6table_filter.c
61
static void __net_exit ip6table_filter_net_pre_exit(struct net *net)
net/ipv6/netfilter/ip6table_filter.c
63
xt_unregister_table_pre_exit(net, NFPROTO_IPV6, "filter");
net/ipv6/netfilter/ip6table_filter.c
66
static void __net_exit ip6table_filter_net_exit(struct net *net)
net/ipv6/netfilter/ip6table_filter.c
68
ip6t_unregister_table_exit(net, "filter");
net/ipv6/netfilter/ip6table_mangle.c
58
err = ip6_route_me_harder(state->net, state->sk, skb);
net/ipv6/netfilter/ip6table_mangle.c
77
static int ip6table_mangle_table_init(struct net *net)
net/ipv6/netfilter/ip6table_mangle.c
85
ret = ip6t_register_table(net, &packet_mangler, repl, mangle_ops);
net/ipv6/netfilter/ip6table_mangle.c
90
static void __net_exit ip6table_mangle_net_pre_exit(struct net *net)
net/ipv6/netfilter/ip6table_mangle.c
92
xt_unregister_table_pre_exit(net, NFPROTO_IPV6, "mangle");
net/ipv6/netfilter/ip6table_mangle.c
95
static void __net_exit ip6table_mangle_net_exit(struct net *net)
net/ipv6/netfilter/ip6table_mangle.c
97
ip6t_unregister_table_exit(net, "mangle");
net/ipv6/netfilter/ip6table_nat.c
103
nf_nat_ipv6_unregister_fn(net, &ops[i]);
net/ipv6/netfilter/ip6table_nat.c
108
static int ip6table_nat_table_init(struct net *net)
net/ipv6/netfilter/ip6table_nat.c
116
ret = ip6t_register_table(net, &nf_nat_ipv6_table, repl,
net/ipv6/netfilter/ip6table_nat.c
123
ret = ip6t_nat_register_lookups(net);
net/ipv6/netfilter/ip6table_nat.c
125
xt_unregister_table_pre_exit(net, NFPROTO_IPV6, "nat");
net/ipv6/netfilter/ip6table_nat.c
127
ip6t_unregister_table_exit(net, "nat");
net/ipv6/netfilter/ip6table_nat.c
134
static void __net_exit ip6table_nat_net_pre_exit(struct net *net)
net/ipv6/netfilter/ip6table_nat.c
136
ip6t_nat_unregister_lookups(net);
net/ipv6/netfilter/ip6table_nat.c
137
xt_unregister_table_pre_exit(net, NFPROTO_IPV6, "nat");
net/ipv6/netfilter/ip6table_nat.c
140
static void __net_exit ip6table_nat_net_exit(struct net *net)
net/ipv6/netfilter/ip6table_nat.c
142
ip6t_unregister_table_exit(net, "nat");
net/ipv6/netfilter/ip6table_nat.c
61
static int ip6t_nat_register_lookups(struct net *net)
net/ipv6/netfilter/ip6table_nat.c
68
table = xt_find_table(net, NFPROTO_IPV6, "nat");
net/ipv6/netfilter/ip6table_nat.c
72
xt_nat_net = net_generic(net, ip6table_nat_net_id);
net/ipv6/netfilter/ip6table_nat.c
79
ret = nf_nat_ipv6_register_fn(net, &ops[i]);
net/ipv6/netfilter/ip6table_nat.c
82
nf_nat_ipv6_unregister_fn(net, &ops[--i]);
net/ipv6/netfilter/ip6table_nat.c
93
static void ip6t_nat_unregister_lookups(struct net *net)
net/ipv6/netfilter/ip6table_nat.c
95
struct ip6table_nat_pernet *xt_nat_net = net_generic(net, ip6table_nat_net_id);
net/ipv6/netfilter/ip6table_raw.c
36
static int ip6table_raw_table_init(struct net *net)
net/ipv6/netfilter/ip6table_raw.c
48
ret = ip6t_register_table(net, table, repl, rawtable_ops);
net/ipv6/netfilter/ip6table_raw.c
53
static void __net_exit ip6table_raw_net_pre_exit(struct net *net)
net/ipv6/netfilter/ip6table_raw.c
55
xt_unregister_table_pre_exit(net, NFPROTO_IPV6, "raw");
net/ipv6/netfilter/ip6table_raw.c
58
static void __net_exit ip6table_raw_net_exit(struct net *net)
net/ipv6/netfilter/ip6table_raw.c
60
ip6t_unregister_table_exit(net, "raw");
net/ipv6/netfilter/ip6table_security.c
37
static int ip6table_security_table_init(struct net *net)
net/ipv6/netfilter/ip6table_security.c
45
ret = ip6t_register_table(net, &security_table, repl, sectbl_ops);
net/ipv6/netfilter/ip6table_security.c
50
static void __net_exit ip6table_security_net_pre_exit(struct net *net)
net/ipv6/netfilter/ip6table_security.c
52
xt_unregister_table_pre_exit(net, NFPROTO_IPV6, "security");
net/ipv6/netfilter/ip6table_security.c
55
static void __net_exit ip6table_security_net_exit(struct net *net)
net/ipv6/netfilter/ip6table_security.c
57
ip6t_unregister_table_exit(net, "security");
net/ipv6/netfilter/nf_conntrack_reasm.c
104
static void __net_exit nf_ct_frags6_sysctl_unregister(struct net *net)
net/ipv6/netfilter/nf_conntrack_reasm.c
106
struct nft_ct_frag6_pernet *nf_frag = nf_frag_pernet(net);
net/ipv6/netfilter/nf_conntrack_reasm.c
111
if (!net_eq(net, &init_net))
net/ipv6/netfilter/nf_conntrack_reasm.c
116
static int nf_ct_frag6_sysctl_register(struct net *net)
net/ipv6/netfilter/nf_conntrack_reasm.c
120
static void __net_exit nf_ct_frags6_sysctl_unregister(struct net *net)
net/ipv6/netfilter/nf_conntrack_reasm.c
141
ip6frag_expire_frag_queue(fq->q.fqdir->net, fq);
net/ipv6/netfilter/nf_conntrack_reasm.c
145
static struct frag_queue *fq_find(struct net *net, __be32 id, u32 user,
net/ipv6/netfilter/nf_conntrack_reasm.c
148
struct nft_ct_frag6_pernet *nf_frag = nf_frag_pernet(net);
net/ipv6/netfilter/nf_conntrack_reasm.c
39
static struct nft_ct_frag6_pernet *nf_frag_pernet(struct net *net)
net/ipv6/netfilter/nf_conntrack_reasm.c
41
return net_generic(net, nf_frag_pernet_id);
net/ipv6/netfilter/nf_conntrack_reasm.c
446
int nf_ct_frag6_gather(struct net *net, struct sk_buff *skb, u32 user)
net/ipv6/netfilter/nf_conntrack_reasm.c
482
fq = fq_find(net, fhdr->identification, user, hdr,
net/ipv6/netfilter/nf_conntrack_reasm.c
505
static int nf_ct_net_init(struct net *net)
net/ipv6/netfilter/nf_conntrack_reasm.c
507
struct nft_ct_frag6_pernet *nf_frag = nf_frag_pernet(net);
net/ipv6/netfilter/nf_conntrack_reasm.c
510
res = fqdir_init(&nf_frag->fqdir, &nf_frags, net);
net/ipv6/netfilter/nf_conntrack_reasm.c
518
res = nf_ct_frag6_sysctl_register(net);
net/ipv6/netfilter/nf_conntrack_reasm.c
524
static void nf_ct_net_pre_exit(struct net *net)
net/ipv6/netfilter/nf_conntrack_reasm.c
526
struct nft_ct_frag6_pernet *nf_frag = nf_frag_pernet(net);
net/ipv6/netfilter/nf_conntrack_reasm.c
531
static void nf_ct_net_exit(struct net *net)
net/ipv6/netfilter/nf_conntrack_reasm.c
533
struct nft_ct_frag6_pernet *nf_frag = nf_frag_pernet(net);
net/ipv6/netfilter/nf_conntrack_reasm.c
535
nf_ct_frags6_sysctl_unregister(net);
net/ipv6/netfilter/nf_conntrack_reasm.c
67
static int nf_ct_frag6_sysctl_register(struct net *net)
net/ipv6/netfilter/nf_conntrack_reasm.c
74
if (!net_eq(net, &init_net)) {
net/ipv6/netfilter/nf_conntrack_reasm.c
81
nf_frag = nf_frag_pernet(net);
net/ipv6/netfilter/nf_conntrack_reasm.c
89
hdr = register_net_sysctl_sz(net, "net/netfilter", table,
net/ipv6/netfilter/nf_conntrack_reasm.c
98
if (!net_eq(net, &init_net))
net/ipv6/netfilter/nf_defrag_ipv6_hooks.c
142
int nf_defrag_ipv6_enable(struct net *net)
net/ipv6/netfilter/nf_defrag_ipv6_hooks.c
147
if (net->nf.defrag_ipv6_users == UINT_MAX) {
net/ipv6/netfilter/nf_defrag_ipv6_hooks.c
152
if (net->nf.defrag_ipv6_users) {
net/ipv6/netfilter/nf_defrag_ipv6_hooks.c
153
net->nf.defrag_ipv6_users++;
net/ipv6/netfilter/nf_defrag_ipv6_hooks.c
157
err = nf_register_net_hooks(net, ipv6_defrag_ops,
net/ipv6/netfilter/nf_defrag_ipv6_hooks.c
160
net->nf.defrag_ipv6_users = 1;
net/ipv6/netfilter/nf_defrag_ipv6_hooks.c
168
void nf_defrag_ipv6_disable(struct net *net)
net/ipv6/netfilter/nf_defrag_ipv6_hooks.c
171
if (net->nf.defrag_ipv6_users) {
net/ipv6/netfilter/nf_defrag_ipv6_hooks.c
172
net->nf.defrag_ipv6_users--;
net/ipv6/netfilter/nf_defrag_ipv6_hooks.c
173
if (net->nf.defrag_ipv6_users == 0)
net/ipv6/netfilter/nf_defrag_ipv6_hooks.c
174
nf_unregister_net_hooks(net, ipv6_defrag_ops,
net/ipv6/netfilter/nf_defrag_ipv6_hooks.c
67
err = nf_ct_frag6_gather(state->net, skb,
net/ipv6/netfilter/nf_defrag_ipv6_hooks.c
91
static void __net_exit defrag6_net_exit(struct net *net)
net/ipv6/netfilter/nf_defrag_ipv6_hooks.c
93
if (net->nf.defrag_ipv6_users) {
net/ipv6/netfilter/nf_defrag_ipv6_hooks.c
94
nf_unregister_net_hooks(net, ipv6_defrag_ops,
net/ipv6/netfilter/nf_defrag_ipv6_hooks.c
96
net->nf.defrag_ipv6_users = 0;
net/ipv6/netfilter/nf_dup_ipv6.c
19
static bool nf_dup_ipv6_route(struct net *net, struct sk_buff *skb,
net/ipv6/netfilter/nf_dup_ipv6.c
34
dst = ip6_route_output(net, NULL, &fl6);
net/ipv6/netfilter/nf_dup_ipv6.c
47
void nf_dup_ipv6(struct net *net, struct sk_buff *skb, unsigned int hooknum,
net/ipv6/netfilter/nf_dup_ipv6.c
66
if (nf_dup_ipv6_route(net, skb, gw, oif)) {
net/ipv6/netfilter/nf_dup_ipv6.c
68
ip6_local_out(net, skb->sk, skb);
net/ipv6/netfilter/nf_reject_ipv6.c
133
struct sk_buff *nf_reject_skb_v6_unreach(struct net *net,
net/ipv6/netfilter/nf_reject_ipv6.c
170
READ_ONCE(net->ipv6.devconf_all->hop_limit));
net/ipv6/netfilter/nf_reject_ipv6.c
311
void nf_send_reset6(struct net *net, struct sock *sk, struct sk_buff *oldskb,
net/ipv6/netfilter/nf_reject_ipv6.c
340
nf_ip6_route(net, &dst, flowi6_to_flowi(&fl6), false);
net/ipv6/netfilter/nf_reject_ipv6.c
347
fl6.flowi6_mark = IP6_REPLY_MARK(net, oldskb->mark);
net/ipv6/netfilter/nf_reject_ipv6.c
349
dst = ip6_route_output(net, NULL, &fl6);
net/ipv6/netfilter/nf_reject_ipv6.c
354
dst = xfrm_lookup(net, dst, flowi6_to_flowi(&fl6), NULL, 0);
net/ipv6/netfilter/nf_reject_ipv6.c
391
br_indev = nf_bridge_get_physindev(oldskb, net);
net/ipv6/netfilter/nf_reject_ipv6.c
408
ip6_local_out(net, sk, nskb);
net/ipv6/netfilter/nf_reject_ipv6.c
434
void nf_send_unreach6(struct net *net, struct sk_buff *skb_in,
net/ipv6/netfilter/nf_reject_ipv6.c
441
skb_in->dev = net->loopback_dev;
net/ipv6/netfilter/nf_reject_ipv6.c
72
struct sk_buff *nf_reject_skb_v6_tcp_reset(struct net *net,
net/ipv6/netfilter/nf_reject_ipv6.c
99
READ_ONCE(net->ipv6.devconf_all->hop_limit));
net/ipv6/netfilter/nf_socket_ipv6.c
162
return nf_socket_get_sock_v6(net, data_skb, doff, tproto, saddr, daddr,
net/ipv6/netfilter/nf_socket_ipv6.c
78
nf_socket_get_sock_v6(struct net *net, struct sk_buff *skb, int doff,
net/ipv6/netfilter/nf_socket_ipv6.c
86
return inet6_lookup(net, skb, doff, saddr, sport, daddr, dport,
net/ipv6/netfilter/nf_socket_ipv6.c
89
return udp6_lib_lookup(net, saddr, sport, daddr, dport,
net/ipv6/netfilter/nf_socket_ipv6.c
96
struct sock *nf_sk_lookup_slow_v6(struct net *net, const struct sk_buff *skb,
net/ipv6/netfilter/nf_tproxy_ipv6.c
111
sk = __inet6_lookup_established(net, saddr, sport, daddr,
net/ipv6/netfilter/nf_tproxy_ipv6.c
120
sk = udp6_lib_lookup(net, saddr, sport, daddr, dport,
net/ipv6/netfilter/nf_tproxy_ipv6.c
40
struct net *net,
net/ipv6/netfilter/nf_tproxy_ipv6.c
59
sk2 = nf_tproxy_get_sock_v6(net, skb, thoff, tproto,
net/ipv6/netfilter/nf_tproxy_ipv6.c
76
nf_tproxy_get_sock_v6(struct net *net, struct sk_buff *skb, int thoff,
net/ipv6/netfilter/nf_tproxy_ipv6.c
96
sk = inet6_lookup_listener(net, skb,
net/ipv6/netfilter/nft_fib_ipv6.c
58
static int nft_fib6_lookup(struct net *net, struct flowi6 *fl6,
net/ipv6/netfilter/nft_fib_ipv6.c
61
return fib6_lookup(net, fl6->flowi6_oif, fl6, res, flags);
net/ipv6/output_core.c
102
int __ip6_local_out(struct net *net, struct sock *sk, struct sk_buff *skb)
net/ipv6/output_core.c
117
net, sk, skb, NULL, skb_dst_dev(skb),
net/ipv6/output_core.c
122
int ip6_local_out(struct net *net, struct sock *sk, struct sk_buff *skb)
net/ipv6/output_core.c
126
err = __ip6_local_out(net, sk, skb);
net/ipv6/output_core.c
128
err = dst_output(net, sk, skb);
net/ipv6/output_core.c
14
static u32 __ipv6_select_ident(struct net *net,
net/ipv6/output_core.c
29
__be32 ipv6_proxy_select_ident(struct net *net, struct sk_buff *skb)
net/ipv6/output_core.c
42
id = __ipv6_select_ident(net, &addrs[1], &addrs[0]);
net/ipv6/output_core.c
46
__be32 ipv6_select_ident(struct net *net,
net/ipv6/output_core.c
52
id = __ipv6_select_ident(net, daddr, saddr);
net/ipv6/ping.c
253
static int __net_init ping_v6_proc_init_net(struct net *net)
net/ipv6/ping.c
255
if (!proc_create_net("icmp6", 0444, net->proc_net, &ping_v6_seq_ops,
net/ipv6/ping.c
261
static void __net_exit ping_v6_proc_exit_net(struct net *net)
net/ipv6/ping.c
263
remove_proc_entry("icmp6", net->proc_net);
net/ipv6/ping.c
41
static int dummy_ipv6_chk_addr(struct net *net, const struct in6_addr *addr,
net/ipv6/proc.c
205
struct net *net = (struct net *)seq->private;
net/ipv6/proc.c
207
snmp6_seq_show_item64(seq, net->mib.ipv6_statistics,
net/ipv6/proc.c
211
snmp6_seq_show_item(seq, net->mib.icmpv6_statistics,
net/ipv6/proc.c
214
snmp6_seq_show_icmpv6msg(seq, net->mib.icmpv6msg_statistics->mibs);
net/ipv6/proc.c
215
snmp6_seq_show_item(seq, net->mib.udp_stats_in6,
net/ipv6/proc.c
242
struct net *net;
net/ipv6/proc.c
247
net = dev_net(idev->dev);
net/ipv6/proc.c
248
if (!net->mib.proc_net_devsnmp6)
net/ipv6/proc.c
252
net->mib.proc_net_devsnmp6, snmp6_dev_seq_show, idev);
net/ipv6/proc.c
262
struct net *net = dev_net(idev->dev);
net/ipv6/proc.c
263
if (!net->mib.proc_net_devsnmp6)
net/ipv6/proc.c
272
static int __net_init ipv6_proc_init_net(struct net *net)
net/ipv6/proc.c
274
if (!proc_create_net_single("sockstat6", 0444, net->proc_net,
net/ipv6/proc.c
278
if (!proc_create_net_single("snmp6", 0444, net->proc_net,
net/ipv6/proc.c
282
net->mib.proc_net_devsnmp6 = proc_mkdir("dev_snmp6", net->proc_net);
net/ipv6/proc.c
283
if (!net->mib.proc_net_devsnmp6)
net/ipv6/proc.c
288
remove_proc_entry("snmp6", net->proc_net);
net/ipv6/proc.c
290
remove_proc_entry("sockstat6", net->proc_net);
net/ipv6/proc.c
294
static void __net_exit ipv6_proc_exit_net(struct net *net)
net/ipv6/proc.c
296
remove_proc_entry("sockstat6", net->proc_net);
net/ipv6/proc.c
297
remove_proc_entry("dev_snmp6", net->proc_net);
net/ipv6/proc.c
298
remove_proc_entry("snmp6", net->proc_net);
net/ipv6/proc.c
36
struct net *net = seq->private;
net/ipv6/proc.c
39
sock_prot_inuse_get(net, &tcpv6_prot));
net/ipv6/proc.c
41
sock_prot_inuse_get(net, &udpv6_prot));
net/ipv6/proc.c
43
sock_prot_inuse_get(net, &rawv6_prot));
net/ipv6/proc.c
45
atomic_read(&net->ipv6.fqdir->rhashtable.nelems),
net/ipv6/proc.c
46
frag_mem_limit(net->ipv6.fqdir));
net/ipv6/raw.c
1245
static int __net_init raw6_init_net(struct net *net)
net/ipv6/raw.c
1247
if (!proc_create_net_data("raw6", 0444, net->proc_net, &raw6_seq_ops,
net/ipv6/raw.c
1254
static void __net_exit raw6_exit_net(struct net *net)
net/ipv6/raw.c
1256
remove_proc_entry("raw6", net->proc_net);
net/ipv6/raw.c
144
struct net *net = dev_net(skb->dev);
net/ipv6/raw.c
153
hash = raw_hashfunc(net, nexthdr);
net/ipv6/raw.c
159
if (!raw_v6_match(net, sk, nexthdr, &ip6h->daddr, &ip6h->saddr,
net/ipv6/raw.c
339
struct net *net = dev_net(skb->dev);
net/ipv6/raw.c
344
hash = raw_hashfunc(net, nexthdr);
net/ipv6/raw.c
351
if (!raw_v6_match(net, sk, nexthdr, &ip6h->saddr, &ip6h->daddr,
net/ipv6/raw.c
599
struct net *net = sock_net(sk);
net/ipv6/raw.c
662
IP6_INC_STATS(net, rt->rt6i_idev, IPSTATS_MIB_OUTREQUESTS);
net/ipv6/raw.c
663
err = NF_HOOK(NFPROTO_IPV6, NF_INET_LOCAL_OUT, net, sk, skb,
net/ipv6/raw.c
668
IP6_INC_STATS(net, rt->rt6i_idev, IPSTATS_MIB_OUTDISCARDS);
net/ipv6/raw.c
67
bool raw_v6_match(struct net *net, const struct sock *sk, unsigned short num,
net/ipv6/raw.c
677
IP6_INC_STATS(net, rt->rt6i_idev, IPSTATS_MIB_OUTDISCARDS);
net/ipv6/raw.c
72
!net_eq(sock_net(sk), net) ||
net/ipv6/raw.c
75
!raw_sk_bound_dev_eq(net, sk->sk_bound_dev_if,
net/ipv6/reassembly.c
100
q = inet_frag_find(net->ipv6.fqdir, &key);
net/ipv6/reassembly.c
107
static int ip6_frag_queue(struct net *net,
net/ipv6/reassembly.c
137
__IP6_INC_STATS(net, idev, IPSTATS_MIB_REASMFAILS);
net/ipv6/reassembly.c
170
__IP6_INC_STATS(net, idev, IPSTATS_MIB_REASMFAILS);
net/ipv6/reassembly.c
244
__IP6_INC_STATS(net, idev, IPSTATS_MIB_REASM_OVERLAPS);
net/ipv6/reassembly.c
247
__IP6_INC_STATS(net, idev, IPSTATS_MIB_REASMFAILS);
net/ipv6/reassembly.c
264
struct net *net = fq->q.fqdir->net;
net/ipv6/reassembly.c
311
__IP6_INC_STATS(net, idev, IPSTATS_MIB_REASMOKS);
net/ipv6/reassembly.c
323
__IP6_INC_STATS(net, idev, IPSTATS_MIB_REASMFAILS);
net/ipv6/reassembly.c
331
struct net *net = skb_dst_dev_net(skb);
net/ipv6/reassembly.c
343
__IP6_INC_STATS(net, idev, IPSTATS_MIB_REASMREQDS);
net/ipv6/reassembly.c
359
__IP6_INC_STATS(net, idev, IPSTATS_MIB_REASMOKS);
net/ipv6/reassembly.c
376
__IP6_INC_STATS(net, idev, IPSTATS_MIB_INHDRERRORS);
net/ipv6/reassembly.c
383
fq = fq_find(net, fhdr->identification, hdr, iif);
net/ipv6/reassembly.c
391
ret = ip6_frag_queue(net, fq, skb, fhdr, IP6CB(skb)->nhoff,
net/ipv6/reassembly.c
398
__IP6_INC_STATS(net, idev, IPSTATS_MIB_INHDRERRORS);
net/ipv6/reassembly.c
406
__IP6_INC_STATS(net, idev, IPSTATS_MIB_REASMFAILS);
net/ipv6/reassembly.c
411
__IP6_INC_STATS(net, idev, IPSTATS_MIB_INHDRERRORS);
net/ipv6/reassembly.c
456
static int __net_init ip6_frags_ns_sysctl_register(struct net *net)
net/ipv6/reassembly.c
462
if (!net_eq(net, &init_net)) {
net/ipv6/reassembly.c
468
table[0].data = &net->ipv6.fqdir->high_thresh;
net/ipv6/reassembly.c
469
table[0].extra1 = &net->ipv6.fqdir->low_thresh;
net/ipv6/reassembly.c
470
table[1].data = &net->ipv6.fqdir->low_thresh;
net/ipv6/reassembly.c
471
table[1].extra2 = &net->ipv6.fqdir->high_thresh;
net/ipv6/reassembly.c
472
table[2].data = &net->ipv6.fqdir->timeout;
net/ipv6/reassembly.c
474
hdr = register_net_sysctl_sz(net, "net/ipv6", table,
net/ipv6/reassembly.c
479
net->ipv6.sysctl.frags_hdr = hdr;
net/ipv6/reassembly.c
483
if (!net_eq(net, &init_net))
net/ipv6/reassembly.c
489
static void __net_exit ip6_frags_ns_sysctl_unregister(struct net *net)
net/ipv6/reassembly.c
493
table = net->ipv6.sysctl.frags_hdr->ctl_table_arg;
net/ipv6/reassembly.c
494
unregister_net_sysctl_table(net->ipv6.sysctl.frags_hdr);
net/ipv6/reassembly.c
495
if (!net_eq(net, &init_net))
net/ipv6/reassembly.c
513
static int ip6_frags_ns_sysctl_register(struct net *net)
net/ipv6/reassembly.c
518
static void ip6_frags_ns_sysctl_unregister(struct net *net)
net/ipv6/reassembly.c
532
static int __net_init ipv6_frags_init_net(struct net *net)
net/ipv6/reassembly.c
536
res = fqdir_init(&net->ipv6.fqdir, &ip6_frags, net);
net/ipv6/reassembly.c
540
net->ipv6.fqdir->high_thresh = IPV6_FRAG_HIGH_THRESH;
net/ipv6/reassembly.c
541
net->ipv6.fqdir->low_thresh = IPV6_FRAG_LOW_THRESH;
net/ipv6/reassembly.c
542
net->ipv6.fqdir->timeout = IPV6_FRAG_TIMEOUT;
net/ipv6/reassembly.c
544
res = ip6_frags_ns_sysctl_register(net);
net/ipv6/reassembly.c
546
fqdir_exit(net->ipv6.fqdir);
net/ipv6/reassembly.c
550
static void __net_exit ipv6_frags_pre_exit_net(struct net *net)
net/ipv6/reassembly.c
552
fqdir_pre_exit(net->ipv6.fqdir);
net/ipv6/reassembly.c
555
static void __net_exit ipv6_frags_exit_net(struct net *net)
net/ipv6/reassembly.c
557
ip6_frags_ns_sysctl_unregister(net);
net/ipv6/reassembly.c
558
fqdir_exit(net->ipv6.fqdir);
net/ipv6/reassembly.c
81
ip6frag_expire_frag_queue(fq->q.fqdir->net, fq);
net/ipv6/reassembly.c
85
fq_find(struct net *net, __be32 id, const struct ipv6hdr *hdr, int iif)
net/ipv6/route.c
100
static int ip6_pkt_prohibit_out(struct net *net, struct sock *sk, struct sk_buff *skb);
net/ipv6/route.c
1017
rt = rt6_get_dflt_router(net, gwaddr, dev);
net/ipv6/route.c
1019
rt = rt6_get_route_info(net, prefix, rinfo->prefix_len,
net/ipv6/route.c
1023
ip6_del_rt(net, rt, false);
net/ipv6/route.c
1028
rt = rt6_add_route_info(net, prefix, rinfo->prefix_len, gwaddr,
net/ipv6/route.c
1040
fib6_may_remove_gc_list(net, rt);
net/ipv6/route.c
110
static int rt6_fill_node(struct net *net, struct sk_buff *skb,
net/ipv6/route.c
120
static struct fib6_info *rt6_add_route_info(struct net *net,
net/ipv6/route.c
1213
static bool ip6_hold_safe(struct net *net, struct rt6_info **prt)
net/ipv6/route.c
1219
if (net) {
net/ipv6/route.c
1220
rt = net->ipv6.ip6_null_entry;
net/ipv6/route.c
125
static struct fib6_info *rt6_get_route_info(struct net *net,
net/ipv6/route.c
1256
INDIRECT_CALLABLE_SCOPE struct rt6_info *ip6_pol_route_lookup(struct net *net,
net/ipv6/route.c
1271
res.f6i = net->ipv6.fib6_null_entry;
net/ipv6/route.c
1273
rt6_device_match(net, &res, &fl6->saddr, fl6->flowi6_oif,
net/ipv6/route.c
1276
if (res.f6i == net->ipv6.fib6_null_entry) {
net/ipv6/route.c
1281
rt = net->ipv6.ip6_null_entry;
net/ipv6/route.c
1288
fib6_select_path(net, &res, fl6, fl6->flowi6_oif,
net/ipv6/route.c
1294
if (ip6_hold_safe(net, &rt))
net/ipv6/route.c
1302
trace_fib6_table_lookup(net, &res, table, fl6);
net/ipv6/route.c
1309
struct dst_entry *ip6_route_lookup(struct net *net, struct flowi6 *fl6,
net/ipv6/route.c
1312
return fib6_rule_lookup(net, fl6, skb, flags, ip6_pol_route_lookup);
net/ipv6/route.c
1316
struct rt6_info *rt6_lookup(struct net *net, const struct in6_addr *daddr,
net/ipv6/route.c
1332
dst = fib6_rule_lookup(net, &fl6, skb, flags, ip6_pol_route_lookup);
net/ipv6/route.c
1362
int ip6_ins_rt(struct net *net, struct fib6_info *rt)
net/ipv6/route.c
1364
struct nl_info info = { .nl_net = net, };
net/ipv6/route.c
1467
static struct rt6_info *rt6_make_pcpu_route(struct net *net,
net/ipv6/route.c
1511
struct net *net;
net/ipv6/route.c
1516
net = dev_net(rt6_ex->rt6i->dst.dev);
net/ipv6/route.c
1517
net->ipv6.rt6_stats->fib_rt_cache--;
net/ipv6/route.c
1721
struct net *net = dev_net(nrt->dst.dev);
net/ipv6/route.c
1780
net->ipv6.rt6_stats->fib_rt_cache++;
net/ipv6/route.c
1793
fib6_update_sernum(net, f6i);
net/ipv6/route.c
1796
fib6_force_start_gc(net);
net/ipv6/route.c
2246
int fib6_table_lookup(struct net *net, struct fib6_table *table, int oif,
net/ipv6/route.c
2255
rt6_select(net, fn, oif, res, strict);
net/ipv6/route.c
2256
if (res->f6i == net->ipv6.fib6_null_entry) {
net/ipv6/route.c
2268
trace_fib6_table_lookup(net, res, table, fl6);
net/ipv6/route.c
2273
struct rt6_info *ip6_pol_route(struct net *net, struct fib6_table *table,
net/ipv6/route.c
2287
if (READ_ONCE(net->ipv6.devconf_all->forwarding) == 0)
net/ipv6/route.c
2292
fib6_table_lookup(net, table, oif, fl6, &res, strict);
net/ipv6/route.c
2293
if (res.f6i == net->ipv6.fib6_null_entry)
net/ipv6/route.c
2298
fib6_select_path(net, &res, fl6, oif, have_oif_match, skb, strict);
net/ipv6/route.c
2330
rt = rt6_make_pcpu_route(net, &res);
net/ipv6/route.c
2336
rt = net->ipv6.ip6_null_entry;
net/ipv6/route.c
2338
ip6_hold_safe(net, &rt);
net/ipv6/route.c
2345
INDIRECT_CALLABLE_SCOPE struct rt6_info *ip6_pol_route_input(struct net *net,
net/ipv6/route.c
2351
return ip6_pol_route(net, table, fl6->flowi6_iif, fl6, skb, flags);
net/ipv6/route.c
2354
struct dst_entry *ip6_route_input_lookup(struct net *net,
net/ipv6/route.c
2363
return fib6_rule_lookup(net, fl6, skb, flags, ip6_pol_route_input);
net/ipv6/route.c
2412
static u32 rt6_multipath_custom_hash_outer(const struct net *net,
net/ipv6/route.c
2416
u32 hash_fields = ip6_multipath_hash_fields(net);
net/ipv6/route.c
2440
return fib_multipath_hash_from_keys(net, &hash_keys);
net/ipv6/route.c
2443
static u32 rt6_multipath_custom_hash_inner(const struct net *net,
net/ipv6/route.c
2447
u32 hash_fields = ip6_multipath_hash_fields(net);
net/ipv6/route.c
2489
return fib_multipath_hash_from_keys(net, &hash_keys);
net/ipv6/route.c
2492
static u32 rt6_multipath_custom_hash_skb(const struct net *net,
net/ipv6/route.c
2498
mhash = rt6_multipath_custom_hash_outer(net, skb, &has_inner);
net/ipv6/route.c
2499
mhash_inner = rt6_multipath_custom_hash_inner(net, skb, has_inner);
net/ipv6/route.c
2504
static u32 rt6_multipath_custom_hash_fl6(const struct net *net,
net/ipv6/route.c
2507
u32 hash_fields = ip6_multipath_hash_fields(net);
net/ipv6/route.c
2532
return fib_multipath_hash_from_keys(net, &hash_keys);
net/ipv6/route.c
2536
u32 rt6_multipath_hash(const struct net *net, const struct flowi6 *fl6,
net/ipv6/route.c
2542
switch (ip6_multipath_hash_policy(net)) {
net/ipv6/route.c
2554
mhash = fib_multipath_hash_from_keys(net, &hash_keys);
net/ipv6/route.c
2589
mhash = fib_multipath_hash_from_keys(net, &hash_keys);
net/ipv6/route.c
2626
mhash = fib_multipath_hash_from_keys(net, &hash_keys);
net/ipv6/route.c
2630
mhash = rt6_multipath_custom_hash_skb(net, skb);
net/ipv6/route.c
2632
mhash = rt6_multipath_custom_hash_fl6(net, fl6);
net/ipv6/route.c
2643
struct net *net = dev_net(skb->dev);
net/ipv6/route.c
2660
if (fib6_rules_early_flow_dissect(net, skb, &fl6, &_flkeys))
net/ipv6/route.c
2664
fl6.mp_hash = rt6_multipath_hash(net, &fl6, skb, flkeys);
net/ipv6/route.c
2666
skb_dst_set_noref(skb, ip6_route_input_lookup(net, skb->dev,
net/ipv6/route.c
2671
INDIRECT_CALLABLE_SCOPE struct rt6_info *ip6_pol_route_output(struct net *net,
net/ipv6/route.c
2677
return ip6_pol_route(net, table, fl6->flowi6_oif, fl6, skb, flags);
net/ipv6/route.c
2680
static struct dst_entry *ip6_route_output_flags_noref(struct net *net,
net/ipv6/route.c
2692
dst = l3mdev_link_scope_lookup(net, fl6);
net/ipv6/route.c
2710
return fib6_rule_lookup(net, fl6, NULL, flags, ip6_pol_route_output);
net/ipv6/route.c
2713
struct dst_entry *ip6_route_output_flags(struct net *net,
net/ipv6/route.c
2722
dst = ip6_route_output_flags_noref(net, sk, fl6, flags);
net/ipv6/route.c
2726
dst = &net->ipv6.ip6_null_entry->dst;
net/ipv6/route.c
2735
struct dst_entry *ip6_blackhole_route(struct net *net, struct dst_entry *dst_orig)
net/ipv6/route.c
2738
struct net_device *loopback_dev = net->loopback_dev;
net/ipv6/route.c
2745
atomic_inc(&net->ipv6.rt6_stats->fib_rt_alloc);
net/ipv6/route.c
2909
struct net *net = dev_net(rt->dst.dev);
net/ipv6/route.c
2913
rt6_update_expires(rt, READ_ONCE(net->ipv6.sysctl.ip6_rt_mtu_expires));
net/ipv6/route.c
3009
void ip6_update_pmtu(struct sk_buff *skb, struct net *net, __be32 mtu,
net/ipv6/route.c
3016
.flowi6_mark = mark ? mark : IP6_REPLY_MARK(net, skb->mark),
net/ipv6/route.c
3023
dst = ip6_route_output(net, NULL, &fl6);
net/ipv6/route.c
3119
INDIRECT_CALLABLE_SCOPE struct rt6_info *__ip6_route_redirect(struct net *net,
net/ipv6/route.c
3173
rt = net->ipv6.fib6_null_entry;
net/ipv6/route.c
3175
ret = net->ipv6.ip6_null_entry;
net/ipv6/route.c
3179
if (rt == net->ipv6.fib6_null_entry) {
net/ipv6/route.c
3189
ip6_hold_safe(net, &ret);
net/ipv6/route.c
3198
trace_fib6_table_lookup(net, &res, table, fl6);
net/ipv6/route.c
3202
static struct dst_entry *ip6_route_redirect(struct net *net,
net/ipv6/route.c
3213
return fib6_rule_lookup(net, &rdfl.fl6, skb,
net/ipv6/route.c
3217
void ip6_redirect(struct sk_buff *skb, struct net *net, int oif, u32 mark,
net/ipv6/route.c
3232
dst = ip6_route_redirect(net, &fl6, skb, &ipv6_hdr(skb)->saddr);
net/ipv6/route.c
3238
void ip6_redirect_no_header(struct sk_buff *skb, struct net *net, int oif)
net/ipv6/route.c
3248
.flowi6_uid = sock_net_uid(net, NULL),
net/ipv6/route.c
3251
dst = ip6_route_redirect(net, &fl6, skb, &iph->saddr);
net/ipv6/route.c
3265
struct net *net;
net/ipv6/route.c
3271
net = dst_dev_net_rcu(dst);
net/ipv6/route.c
3273
READ_ONCE(net->ipv6.sysctl.ip6_rt_min_advmss));
net/ipv6/route.c
3341
struct net *net = dev_net(dev);
net/ipv6/route.c
3346
rt = ip6_dst_alloc(net, dev, 0);
net/ipv6/route.c
3366
dst = xfrm_lookup(net, &rt->dst, flowi6_to_flowi(fl6), NULL, 0);
net/ipv6/route.c
3374
struct net *net = container_of(ops, struct net, ipv6.ip6_dst_ops);
net/ipv6/route.c
3375
int rt_min_interval = READ_ONCE(net->ipv6.sysctl.ip6_rt_gc_min_interval);
net/ipv6/route.c
3376
int rt_elasticity = READ_ONCE(net->ipv6.sysctl.ip6_rt_gc_elasticity);
net/ipv6/route.c
3377
int rt_gc_timeout = READ_ONCE(net->ipv6.sysctl.ip6_rt_gc_timeout);
net/ipv6/route.c
3378
unsigned long rt_last_gc = READ_ONCE(net->ipv6.ip6_rt_last_gc);
net/ipv6/route.c
3385
fib6_run_gc(atomic_inc_return(&net->ipv6.ip6_rt_gc_expire), net, true);
net/ipv6/route.c
3388
atomic_set(&net->ipv6.ip6_rt_gc_expire, rt_gc_timeout >> 1);
net/ipv6/route.c
339
struct rt6_info *ip6_dst_alloc(struct net *net, struct net_device *dev,
net/ipv6/route.c
3390
val = atomic_read(&net->ipv6.ip6_rt_gc_expire);
net/ipv6/route.c
3391
atomic_set(&net->ipv6.ip6_rt_gc_expire, val - (val >> rt_elasticity));
net/ipv6/route.c
3394
static int ip6_nh_lookup_table(struct net *net, struct fib6_config *cfg,
net/ipv6/route.c
3406
table = fib6_get_table(net, tbid);
net/ipv6/route.c
3415
err = fib6_table_lookup(net, table, cfg->fc_ifindex, &fl6, res, flags);
net/ipv6/route.c
3416
if (!err && res->f6i != net->ipv6.fib6_null_entry)
net/ipv6/route.c
3417
fib6_select_path(net, res, &fl6, cfg->fc_ifindex,
net/ipv6/route.c
342
struct rt6_info *rt = dst_alloc(&net->ipv6.ip6_dst_ops, dev,
net/ipv6/route.c
3423
static int ip6_route_check_nh_onlink(struct net *net,
net/ipv6/route.c
3433
err = ip6_nh_lookup_table(net, cfg, gw_addr, tbid, 0, &res);
net/ipv6/route.c
3443
static int ip6_route_check_nh(struct net *net,
net/ipv6/route.c
3456
err = ip6_nh_lookup_table(net, cfg, gw_addr,
net/ipv6/route.c
347
atomic_inc(&net->ipv6.rt6_stats->fib_rt_alloc);
net/ipv6/route.c
3473
err = fib6_lookup(net, cfg->fc_ifindex, &fl6, &res, flags);
net/ipv6/route.c
3481
fib6_select_path(net, &res, &fl6, cfg->fc_ifindex,
net/ipv6/route.c
3498
static int ip6_validate_gw(struct net *net, struct fib6_config *cfg,
net/ipv6/route.c
3517
ipv6_chk_addr_and_flags(net, gw_addr, dev, skip_dev, 0, 0)) {
net/ipv6/route.c
3540
err = ip6_route_check_nh_onlink(net, cfg, dev, extack);
net/ipv6/route.c
3542
err = ip6_route_check_nh(net, cfg, _dev, dev_tracker,
net/ipv6/route.c
3568
ipv6_chk_addr_and_flags(net, gw_addr, dev, skip_dev, 0, 0)) {
net/ipv6/route.c
3589
int fib6_nh_init(struct net *net, struct fib6_nh *fib6_nh,
net/ipv6/route.c
3615
dev = netdev_get_by_index(net, cfg->fc_ifindex,
net/ipv6/route.c
3647
if (dev != net->loopback_dev) {
net/ipv6/route.c
3652
dev = net->loopback_dev;
net/ipv6/route.c
3664
err = ip6_validate_gw(net, cfg, &dev, dev_tracker,
net/ipv6/route.c
3693
err = fib_nh_common_init(net, &fib6_nh->nh_common, cfg->fc_encap,
net/ipv6/route.c
3813
struct net *net = cfg->fc_nlinfo.nl_net;
net/ipv6/route.c
3820
table = fib6_get_table(net, cfg->fc_table);
net/ipv6/route.c
3823
table = fib6_new_table(net, cfg->fc_table);
net/ipv6/route.c
3826
table = fib6_new_table(net, cfg->fc_table);
net/ipv6/route.c
3881
struct net *net = cfg->fc_nlinfo.nl_net;
net/ipv6/route.c
3890
nh = nexthop_find_by_id(net, cfg->fc_nh_id);
net/ipv6/route.c
3914
err = fib6_nh_init(net, rt->fib6_nh, cfg, gfp_flags, extack);
net/ipv6/route.c
3932
if (!ipv6_chk_addr(net, &cfg->fc_prefsrc, dev, 0)) {
net/ipv6/route.c
3978
struct net *net = info->nl_net;
net/ipv6/route.c
3982
if (rt == net->ipv6.fib6_null_entry) {
net/ipv6/route.c
3997
int ip6_del_rt(struct net *net, struct fib6_info *rt, bool skip_notify)
net/ipv6/route.c
4000
.nl_net = net,
net/ipv6/route.c
4010
struct net *net = info->nl_net;
net/ipv6/route.c
4015
if (rt == net->ipv6.fib6_null_entry)
net/ipv6/route.c
4029
if (rt6_fill_node(net, skb, rt, NULL,
net/ipv6/route.c
4056
call_fib6_entry_notifiers_replace(net,
net/ipv6/route.c
4059
call_fib6_multipath_entry_notifiers(net,
net/ipv6/route.c
4080
rtnl_notify(skb, net, info->portid, RTNLGRP_IPV6_ROUTE,
net/ipv6/route.c
4373
static struct fib6_info *rt6_get_route_info(struct net *net,
net/ipv6/route.c
438
void fib6_select_path(const struct net *net, struct fib6_result *res,
net/ipv6/route.c
4384
table = fib6_get_table(net, tb_id);
net/ipv6/route.c
4413
static struct fib6_info *rt6_add_route_info(struct net *net,
net/ipv6/route.c
4429
.fc_nlinfo.nl_net = net,
net/ipv6/route.c
4442
return rt6_get_route_info(net, prefix, prefixlen, gwaddr, dev);
net/ipv6/route.c
4446
struct fib6_info *rt6_get_dflt_router(struct net *net,
net/ipv6/route.c
4454
table = fib6_get_table(net, tb_id);
net/ipv6/route.c
4478
struct fib6_info *rt6_add_dflt_router(struct net *net,
net/ipv6/route.c
4495
.fc_nlinfo.nl_net = net,
net/ipv6/route.c
4509
return rt6_get_dflt_router(net, gwaddr, dev);
net/ipv6/route.c
4512
static void __rt6_purge_dflt_routers(struct net *net,
net/ipv6/route.c
4527
ip6_del_rt(net, rt, false);
net/ipv6/route.c
4536
void rt6_purge_dflt_routers(struct net *net)
net/ipv6/route.c
4545
head = &net->ipv6.fib_table_hash[h];
net/ipv6/route.c
4548
__rt6_purge_dflt_routers(net, table);
net/ipv6/route.c
4555
static void rtmsg_to_fib6_config(struct net *net,
net/ipv6/route.c
4560
.fc_table = l3mdev_fib_table_by_index(net, rtmsg->rtmsg_ifindex) ?
net/ipv6/route.c
4570
.fc_nlinfo.nl_net = net,
net/ipv6/route.c
4578
int ipv6_route_ioctl(struct net *net, unsigned int cmd, struct in6_rtmsg *rtmsg)
net/ipv6/route.c
4585
if (!ns_capable(net->user_ns, CAP_NET_ADMIN))
net/ipv6/route.c
4588
rtmsg_to_fib6_config(net, rtmsg, &cfg);
net/ipv6/route.c
460
fl6->mp_hash = rt6_multipath_hash(net, fl6, skb, NULL);
net/ipv6/route.c
4613
struct net *net = dev_net(dev);
net/ipv6/route.c
4619
dev == net->loopback_dev)
net/ipv6/route.c
4620
idev = __in6_dev_get_safely(dev_get_by_index_rcu(net, IP6CB(skb)->iif));
net/ipv6/route.c
4629
IP6_INC_STATS(net, idev, IPSTATS_MIB_INADDRERRORS);
net/ipv6/route.c
4636
IP6_INC_STATS(net, idev, ipstats_mib_noroutes);
net/ipv6/route.c
4654
static int ip6_pkt_discard_out(struct net *net, struct sock *sk, struct sk_buff *skb)
net/ipv6/route.c
4665
static int ip6_pkt_prohibit_out(struct net *net, struct sock *sk, struct sk_buff *skb)
net/ipv6/route.c
4675
struct fib6_info *addrconf_f6i_alloc(struct net *net,
net/ipv6/route.c
4688
.fc_nlinfo.nl_net = net,
net/ipv6/route.c
4713
(READ_ONCE(net->ipv6.devconf_all->disable_policy) ||
net/ipv6/route.c
4722
struct net *net;
net/ipv6/route.c
4728
struct net *net = ((struct arg_dev_net_ip *)arg)->net;
net/ipv6/route.c
4732
rt != net->ipv6.fib6_null_entry &&
net/ipv6/route.c
4734
!ipv6_chk_addr(net, addr, rt->fib6_nh->fib_nh_dev, 0)) {
net/ipv6/route.c
4745
struct net *net = dev_net(ifp->idev->dev);
net/ipv6/route.c
4747
.net = net,
net/ipv6/route.c
4750
fib6_clean_all(net, fib6_remove_prefsrc, &adni);
net/ipv6/route.c
4779
void rt6_clean_tohost(struct net *net, struct in6_addr *gateway)
net/ipv6/route.c
4781
fib6_clean_all(net, fib6_clean_tohost, gateway);
net/ipv6/route.c
4889
struct net *net = dev_net(arg->dev);
net/ipv6/route.c
4891
if (rt != net->ipv6.fib6_null_entry && !rt->nh &&
net/ipv6/route.c
4894
fib6_update_sernum_upto_root(net, rt);
net/ipv6/route.c
4975
struct net *net = dev_net(dev);
net/ipv6/route.c
4977
if (rt == net->ipv6.fib6_null_entry || rt->nh)
net/ipv6/route.c
4998
fib6_update_sernum(net, rt);
net/ipv6/route.c
5007
fib6_update_sernum(net, rt);
net/ipv6/route.c
5023
struct net *net = dev_net(dev);
net/ipv6/route.c
5025
if (READ_ONCE(net->ipv6.sysctl.skip_notify_on_dev_down))
net/ipv6/route.c
5026
fib6_clean_all_skip_notify(net, fib6_ifdown, &arg);
net/ipv6/route.c
5028
fib6_clean_all(net, fib6_ifdown, &arg);
net/ipv6/route.c
505
static bool __rt6_device_match(struct net *net, const struct fib6_nh *nh,
net/ipv6/route.c
518
if (ipv6_chk_addr(net, saddr, dev,
net/ipv6/route.c
527
struct net *net;
net/ipv6/route.c
539
return __rt6_device_match(arg->net, nh, arg->saddr, arg->oif,
net/ipv6/route.c
544
static struct fib6_nh *rt6_nh_dev_match(struct net *net, struct nexthop *nh,
net/ipv6/route.c
550
.net = net,
net/ipv6/route.c
565
static void rt6_device_match(struct net *net, struct fib6_result *res,
net/ipv6/route.c
5774
static int rt6_fill_node(struct net *net, struct sk_buff *skb,
net/ipv6/route.c
5842
int err = ip6mr_get_route(net, skb, rtm, portid);
net/ipv6/route.c
5854
if (ip6_route_get_saddr(net, rt, dest, 0, 0, &saddr_buf) == 0 &&
net/ipv6/route.c
588
nh = rt6_nh_dev_match(net, spf6i->nh, res, saddr,
net/ipv6/route.c
5927
if (READ_ONCE(net->ipv4.sysctl_nexthop_compat_mode) &&
net/ipv6/route.c
594
if (__rt6_device_match(net, nh, saddr, oif, flags))
net/ipv6/route.c
604
res->f6i = net->ipv6.fib6_null_entry;
net/ipv6/route.c
6054
err = rt6_fill_node(dump->net, dump->skb, w->rt,
net/ipv6/route.c
6076
struct net *net = arg->net;
net/ipv6/route.c
6079
if (rt == net->ipv6.fib6_null_entry)
net/ipv6/route.c
6103
if (rt6_fill_node(net, arg->skb, rt, NULL, NULL, NULL,
net/ipv6/route.c
618
res->f6i = net->ipv6.fib6_null_entry;
net/ipv6/route.c
6216
struct net *net = sock_net(in_skb->sk);
net/ipv6/route.c
6288
dev = dev_get_by_index_rcu(net, iif);
net/ipv6/route.c
6300
dst = ip6_route_input_lookup(net, dev, &fl6, NULL, flags);
net/ipv6/route.c
6306
dst = ip6_route_output(net, NULL, &fl6);
net/ipv6/route.c
6317
if (rt == net->ipv6.ip6_null_entry) {
net/ipv6/route.c
6336
err = rt6_fill_node(net, skb, from, NULL, NULL, NULL,
net/ipv6/route.c
6341
err = rt6_fill_node(net, skb, from, dst, &fl6.daddr,
net/ipv6/route.c
6355
err = rtnl_unicast(skb, net, NETLINK_CB(in_skb).portid);
net/ipv6/route.c
6363
struct net *net = info->nl_net;
net/ipv6/route.c
6379
err = rt6_fill_node(net, skb, rt, NULL, NULL, NULL, 0,
net/ipv6/route.c
6393
rtnl_notify(skb, net, info->portid, RTNLGRP_IPV6_ROUTE,
net/ipv6/route.c
6398
rtnl_set_sk_err(net, RTNLGRP_IPV6_ROUTE, err);
net/ipv6/route.c
6401
void fib6_rt_update(struct net *net, struct fib6_info *rt,
net/ipv6/route.c
6412
err = rt6_fill_node(net, skb, rt, NULL, NULL, NULL, 0,
net/ipv6/route.c
6420
rtnl_notify(skb, net, info->portid, RTNLGRP_IPV6_ROUTE,
net/ipv6/route.c
6424
rtnl_set_sk_err(net, RTNLGRP_IPV6_ROUTE, err);
net/ipv6/route.c
6427
void fib6_info_hw_flags_set(struct net *net, struct fib6_info *f6i,
net/ipv6/route.c
6442
fib_notify_on_flag_change = READ_ONCE(net->ipv6.sysctl.fib_notify_on_flag_change);
net/ipv6/route.c
6465
err = rt6_fill_node(net, skb, f6i, NULL, NULL, NULL, 0, RTM_NEWROUTE, 0,
net/ipv6/route.c
6474
rtnl_notify(skb, net, 0, RTNLGRP_IPV6_ROUTE, NULL, GFP_KERNEL);
net/ipv6/route.c
6478
rtnl_set_sk_err(net, RTNLGRP_IPV6_ROUTE, err);
net/ipv6/route.c
6486
struct net *net = dev_net(dev);
net/ipv6/route.c
6492
net->ipv6.fib6_null_entry->fib6_nh->fib_nh_dev = dev;
net/ipv6/route.c
6493
net->ipv6.ip6_null_entry->dst.dev = dev;
net/ipv6/route.c
6494
net->ipv6.ip6_null_entry->rt6i_idev = in6_dev_get(dev);
net/ipv6/route.c
6496
net->ipv6.ip6_prohibit_entry->dst.dev = dev;
net/ipv6/route.c
6497
net->ipv6.ip6_prohibit_entry->rt6i_idev = in6_dev_get(dev);
net/ipv6/route.c
6498
net->ipv6.ip6_blk_hole_entry->dst.dev = dev;
net/ipv6/route.c
6499
net->ipv6.ip6_blk_hole_entry->rt6i_idev = in6_dev_get(dev);
net/ipv6/route.c
6506
in6_dev_put_clear(&net->ipv6.ip6_null_entry->rt6i_idev);
net/ipv6/route.c
6508
in6_dev_put_clear(&net->ipv6.ip6_prohibit_entry->rt6i_idev);
net/ipv6/route.c
6509
in6_dev_put_clear(&net->ipv6.ip6_blk_hole_entry->rt6i_idev);
net/ipv6/route.c
6523
struct net *net = (struct net *)seq->private;
net/ipv6/route.c
6525
net->ipv6.rt6_stats->fib_nodes,
net/ipv6/route.c
6526
net->ipv6.rt6_stats->fib_route_nodes,
net/ipv6/route.c
6527
atomic_read(&net->ipv6.rt6_stats->fib_rt_alloc),
net/ipv6/route.c
6528
net->ipv6.rt6_stats->fib_rt_entries,
net/ipv6/route.c
6529
net->ipv6.rt6_stats->fib_rt_cache,
net/ipv6/route.c
6530
dst_entries_get_slow(&net->ipv6.ip6_dst_ops),
net/ipv6/route.c
6531
net->ipv6.rt6_stats->fib_discarded_routes);
net/ipv6/route.c
6542
struct net *net;
net/ipv6/route.c
6552
net = (struct net *)ctl->extra1;
net/ipv6/route.c
6553
delay = READ_ONCE(net->ipv6.sysctl.flush_delay);
net/ipv6/route.c
6554
fib6_run_gc(delay <= 0 ? 0 : (unsigned long)delay, net, delay > 0);
net/ipv6/route.c
6640
struct ctl_table * __net_init ipv6_route_sysctl_init(struct net *net)
net/ipv6/route.c
6649
table[0].data = &net->ipv6.sysctl.ip6_rt_max_size;
net/ipv6/route.c
6650
table[1].data = &net->ipv6.ip6_dst_ops.gc_thresh;
net/ipv6/route.c
6651
table[2].data = &net->ipv6.sysctl.flush_delay;
net/ipv6/route.c
6652
table[2].extra1 = net;
net/ipv6/route.c
6653
table[3].data = &net->ipv6.sysctl.ip6_rt_gc_min_interval;
net/ipv6/route.c
6654
table[4].data = &net->ipv6.sysctl.ip6_rt_gc_timeout;
net/ipv6/route.c
6655
table[5].data = &net->ipv6.sysctl.ip6_rt_gc_interval;
net/ipv6/route.c
6656
table[6].data = &net->ipv6.sysctl.ip6_rt_gc_elasticity;
net/ipv6/route.c
6657
table[7].data = &net->ipv6.sysctl.ip6_rt_mtu_expires;
net/ipv6/route.c
6658
table[8].data = &net->ipv6.sysctl.ip6_rt_min_advmss;
net/ipv6/route.c
6659
table[9].data = &net->ipv6.sysctl.ip6_rt_gc_min_interval;
net/ipv6/route.c
6660
table[10].data = &net->ipv6.sysctl.skip_notify_on_dev_down;
net/ipv6/route.c
6666
size_t ipv6_route_sysctl_table_size(struct net *net)
net/ipv6/route.c
6669
if (net->user_ns != &init_user_ns)
net/ipv6/route.c
6676
static int __net_init ip6_route_net_init(struct net *net)
net/ipv6/route.c
6680
memcpy(&net->ipv6.ip6_dst_ops, &ip6_dst_ops_template,
net/ipv6/route.c
6681
sizeof(net->ipv6.ip6_dst_ops));
net/ipv6/route.c
6683
if (dst_entries_init(&net->ipv6.ip6_dst_ops) < 0)
net/ipv6/route.c
6686
net->ipv6.fib6_null_entry = fib6_info_alloc(GFP_KERNEL, true);
net/ipv6/route.c
6687
if (!net->ipv6.fib6_null_entry)
net/ipv6/route.c
6689
memcpy(net->ipv6.fib6_null_entry, &fib6_null_entry_template,
net/ipv6/route.c
6690
sizeof(*net->ipv6.fib6_null_entry));
net/ipv6/route.c
6692
net->ipv6.ip6_null_entry = kmemdup(&ip6_null_entry_template,
net/ipv6/route.c
6693
sizeof(*net->ipv6.ip6_null_entry),
net/ipv6/route.c
6695
if (!net->ipv6.ip6_null_entry)
net/ipv6/route.c
6697
net->ipv6.ip6_null_entry->dst.ops = &net->ipv6.ip6_dst_ops;
net/ipv6/route.c
6698
dst_init_metrics(&net->ipv6.ip6_null_entry->dst,
net/ipv6/route.c
6700
INIT_LIST_HEAD(&net->ipv6.ip6_null_entry->dst.rt_uncached);
net/ipv6/route.c
6703
net->ipv6.fib6_has_custom_rules = false;
net/ipv6/route.c
6704
net->ipv6.ip6_prohibit_entry = kmemdup(&ip6_prohibit_entry_template,
net/ipv6/route.c
6705
sizeof(*net->ipv6.ip6_prohibit_entry),
net/ipv6/route.c
6707
if (!net->ipv6.ip6_prohibit_entry)
net/ipv6/route.c
6709
net->ipv6.ip6_prohibit_entry->dst.ops = &net->ipv6.ip6_dst_ops;
net/ipv6/route.c
6710
dst_init_metrics(&net->ipv6.ip6_prohibit_entry->dst,
net/ipv6/route.c
6712
INIT_LIST_HEAD(&net->ipv6.ip6_prohibit_entry->dst.rt_uncached);
net/ipv6/route.c
6714
net->ipv6.ip6_blk_hole_entry = kmemdup(&ip6_blk_hole_entry_template,
net/ipv6/route.c
6715
sizeof(*net->ipv6.ip6_blk_hole_entry),
net/ipv6/route.c
6717
if (!net->ipv6.ip6_blk_hole_entry)
net/ipv6/route.c
6719
net->ipv6.ip6_blk_hole_entry->dst.ops = &net->ipv6.ip6_dst_ops;
net/ipv6/route.c
6720
dst_init_metrics(&net->ipv6.ip6_blk_hole_entry->dst,
net/ipv6/route.c
6722
INIT_LIST_HEAD(&net->ipv6.ip6_blk_hole_entry->dst.rt_uncached);
net/ipv6/route.c
6724
net->ipv6.fib6_routes_require_src = 0;
net/ipv6/route.c
6728
net->ipv6.sysctl.flush_delay = 0;
net/ipv6/route.c
6729
net->ipv6.sysctl.ip6_rt_max_size = INT_MAX;
net/ipv6/route.c
6730
net->ipv6.sysctl.ip6_rt_gc_min_interval = HZ / 2;
net/ipv6/route.c
6731
net->ipv6.sysctl.ip6_rt_gc_timeout = 60*HZ;
net/ipv6/route.c
6732
net->ipv6.sysctl.ip6_rt_gc_interval = 30*HZ;
net/ipv6/route.c
6733
net->ipv6.sysctl.ip6_rt_gc_elasticity = 9;
net/ipv6/route.c
6734
net->ipv6.sysctl.ip6_rt_mtu_expires = 10*60*HZ;
net/ipv6/route.c
6735
net->ipv6.sysctl.ip6_rt_min_advmss = IPV6_MIN_MTU - 20 - 40;
net/ipv6/route.c
6736
net->ipv6.sysctl.skip_notify_on_dev_down = 0;
net/ipv6/route.c
6738
atomic_set(&net->ipv6.ip6_rt_gc_expire, 30*HZ);
net/ipv6/route.c
6746
kfree(net->ipv6.ip6_prohibit_entry);
net/ipv6/route.c
6748
kfree(net->ipv6.ip6_null_entry);
net/ipv6/route.c
6751
kfree(net->ipv6.fib6_null_entry);
net/ipv6/route.c
6753
dst_entries_destroy(&net->ipv6.ip6_dst_ops);
net/ipv6/route.c
6758
static void __net_exit ip6_route_net_exit(struct net *net)
net/ipv6/route.c
6760
kfree(net->ipv6.fib6_null_entry);
net/ipv6/route.c
6761
kfree(net->ipv6.ip6_null_entry);
net/ipv6/route.c
6763
kfree(net->ipv6.ip6_prohibit_entry);
net/ipv6/route.c
6764
kfree(net->ipv6.ip6_blk_hole_entry);
net/ipv6/route.c
6766
dst_entries_destroy(&net->ipv6.ip6_dst_ops);
net/ipv6/route.c
6769
static int __net_init ip6_route_net_init_late(struct net *net)
net/ipv6/route.c
6772
if (!proc_create_net("ipv6_route", 0, net->proc_net,
net/ipv6/route.c
6777
if (!proc_create_net_single("rt6_stats", 0444, net->proc_net,
net/ipv6/route.c
6779
remove_proc_entry("ipv6_route", net->proc_net);
net/ipv6/route.c
6786
static void __net_exit ip6_route_net_exit_late(struct net *net)
net/ipv6/route.c
6789
remove_proc_entry("ipv6_route", net->proc_net);
net/ipv6/route.c
6790
remove_proc_entry("rt6_stats", net->proc_net);
net/ipv6/route.c
6799
static int __net_init ipv6_inetpeer_init(struct net *net)
net/ipv6/route.c
6806
net->ipv6.peers = bp;
net/ipv6/route.c
6810
static void __net_exit ipv6_inetpeer_exit(struct net *net)
net/ipv6/route.c
6812
struct inet_peer_base *bp = net->ipv6.peers;
net/ipv6/route.c
6814
net->ipv6.peers = NULL;
net/ipv6/route.c
906
static void rt6_select(struct net *net, struct fib6_node *fn, int oif,
net/ipv6/route.c
917
if (!leaf || leaf == net->ipv6.fib6_null_entry)
net/ipv6/route.c
956
res->f6i = net->ipv6.fib6_null_entry;
net/ipv6/route.c
973
struct net *net = dev_net(dev);
net/ipv6/route.c
98
static int ip6_pkt_discard_out(struct net *net, struct sock *sk, struct sk_buff *skb);
net/ipv6/rpl_iptunnel.c
204
static int rpl_output(struct net *net, struct sock *sk, struct sk_buff *skb)
net/ipv6/rpl_iptunnel.c
232
dst = ip6_route_output(net, NULL, &fl6);
net/ipv6/rpl_iptunnel.c
253
return dst_output(net, sk, skb);
net/ipv6/rpl_iptunnel.c
39
static bool rpl_validate_srh(struct net *net, struct ipv6_rpl_sr_hdr *srh,
net/ipv6/rpl_iptunnel.c
55
err = ipv6_chk_rpl_srh_loop(net, srh->rpl_segaddr,
net/ipv6/rpl_iptunnel.c
67
static int rpl_build_state(struct net *net, struct nlattr *nla,
net/ipv6/rpl_iptunnel.c
96
if (!rpl_validate_srh(net, srh, srh_len - sizeof(*srh)))
net/ipv6/seg6.c
155
struct net *net = genl_info_net(info);
net/ipv6/seg6.c
164
sdata = seg6_pernet(net);
net/ipv6/seg6.c
182
hinfo = seg6_hmac_info_lookup(net, hmackeyid);
net/ipv6/seg6.c
185
err = seg6_hmac_info_del(net, hmackeyid);
net/ipv6/seg6.c
201
err = seg6_hmac_info_del(net, hmackeyid);
net/ipv6/seg6.c
219
err = seg6_hmac_info_add(net, hmackeyid, hinfo);
net/ipv6/seg6.c
239
struct net *net = genl_info_net(info);
net/ipv6/seg6.c
243
sdata = seg6_pernet(net);
net/ipv6/seg6.c
268
struct net *net = genl_info_net(info);
net/ipv6/seg6.c
283
tun_src = rcu_dereference(seg6_pernet(net)->tun_src);
net/ipv6/seg6.c
337
struct net *net = sock_net(cb->skb->sk);
net/ipv6/seg6.c
341
sdata = seg6_pernet(net);
net/ipv6/seg6.c
423
static int __net_init seg6_net_init(struct net *net)
net/ipv6/seg6.c
439
net->ipv6.seg6_data = sdata;
net/ipv6/seg6.c
441
if (seg6_hmac_net_init(net)) {
net/ipv6/seg6.c
450
static void __net_exit seg6_net_exit(struct net *net)
net/ipv6/seg6.c
452
struct seg6_pernet_data *sdata = seg6_pernet(net);
net/ipv6/seg6.c
454
seg6_hmac_net_exit(net);
net/ipv6/seg6_hmac.c
179
struct net *net = dev_net(skb->dev);
net/ipv6/seg6_hmac.c
209
hinfo = seg6_hmac_info_lookup(net, be32_to_cpu(tlv->hmackeyid));
net/ipv6/seg6_hmac.c
224
struct seg6_hmac_info *seg6_hmac_info_lookup(struct net *net, u32 key)
net/ipv6/seg6_hmac.c
226
struct seg6_pernet_data *sdata = seg6_pernet(net);
net/ipv6/seg6_hmac.c
235
int seg6_hmac_info_add(struct net *net, u32 key, struct seg6_hmac_info *hinfo)
net/ipv6/seg6_hmac.c
237
struct seg6_pernet_data *sdata = seg6_pernet(net);
net/ipv6/seg6_hmac.c
260
int seg6_hmac_info_del(struct net *net, u32 key)
net/ipv6/seg6_hmac.c
262
struct seg6_pernet_data *sdata = seg6_pernet(net);
net/ipv6/seg6_hmac.c
282
int seg6_push_hmac(struct net *net, struct in6_addr *saddr,
net/ipv6/seg6_hmac.c
295
hinfo = seg6_hmac_info_lookup(net, be32_to_cpu(tlv->hmackeyid));
net/ipv6/seg6_hmac.c
308
int __net_init seg6_hmac_net_init(struct net *net)
net/ipv6/seg6_hmac.c
310
struct seg6_pernet_data *sdata = seg6_pernet(net);
net/ipv6/seg6_hmac.c
315
void __net_exit seg6_hmac_net_exit(struct net *net)
net/ipv6/seg6_hmac.c
317
struct seg6_pernet_data *sdata = seg6_pernet(net);
net/ipv6/seg6_iptunnel.c
113
ipv6_dev_get_saddr(net, dev, daddr,
net/ipv6/seg6_iptunnel.c
122
static __be32 seg6_make_flowlabel(struct net *net, struct sk_buff *skb,
net/ipv6/seg6_iptunnel.c
125
int do_flowlabel = net->ipv6.sysctl.seg6_flowlabel;
net/ipv6/seg6_iptunnel.c
145
struct net *net = dev_net(dev);
net/ipv6/seg6_iptunnel.c
159
flowlabel = seg6_make_flowlabel(net, skb, inner_hdr);
net/ipv6/seg6_iptunnel.c
198
set_tun_src(net, dev, &hdr->daddr, &hdr->saddr, route_tunsrc);
net/ipv6/seg6_iptunnel.c
202
err = seg6_push_hmac(net, &hdr->saddr, isrh);
net/ipv6/seg6_iptunnel.c
231
struct net *net = dev_net(dev);
net/ipv6/seg6_iptunnel.c
261
flowlabel = seg6_make_flowlabel(net, skb, inner_hdr);
net/ipv6/seg6_iptunnel.c
289
set_tun_src(net, dev, &hdr->daddr, &hdr->saddr, route_tunsrc);
net/ipv6/seg6_iptunnel.c
325
set_tun_src(net, dev, &hdr->daddr, &hdr->saddr, route_tunsrc);
net/ipv6/seg6_iptunnel.c
329
err = seg6_push_hmac(net, &hdr->saddr, isrh);
net/ipv6/seg6_iptunnel.c
381
struct net *net = skb_dst_dev_net(skb);
net/ipv6/seg6_iptunnel.c
383
err = seg6_push_hmac(net, &hdr->saddr, isrh);
net/ipv6/seg6_iptunnel.c
482
static int seg6_input_finish(struct net *net, struct sock *sk,
net/ipv6/seg6_iptunnel.c
488
static int seg6_input_core(struct net *net, struct sock *sk,
net/ipv6/seg6_iptunnel.c
559
struct net *net = dev_net(skb->dev);
net/ipv6/seg6_iptunnel.c
563
return NF_HOOK(NFPROTO_IPV4, NF_INET_POST_ROUTING, net, NULL,
net/ipv6/seg6_iptunnel.c
566
return NF_HOOK(NFPROTO_IPV6, NF_INET_POST_ROUTING, net, NULL,
net/ipv6/seg6_iptunnel.c
581
static int seg6_output_core(struct net *net, struct sock *sk,
net/ipv6/seg6_iptunnel.c
610
dst = ip6_route_output(net, NULL, &fl6);
net/ipv6/seg6_iptunnel.c
632
return NF_HOOK(NFPROTO_IPV6, NF_INET_LOCAL_OUT, net, sk, skb,
net/ipv6/seg6_iptunnel.c
635
return dst_output(net, sk, skb);
net/ipv6/seg6_iptunnel.c
642
static int seg6_output_nf(struct net *net, struct sock *sk, struct sk_buff *skb)
net/ipv6/seg6_iptunnel.c
648
return NF_HOOK(NFPROTO_IPV4, NF_INET_POST_ROUTING, net, sk, skb,
net/ipv6/seg6_iptunnel.c
651
return NF_HOOK(NFPROTO_IPV6, NF_INET_POST_ROUTING, net, sk, skb,
net/ipv6/seg6_iptunnel.c
658
static int seg6_output(struct net *net, struct sock *sk, struct sk_buff *skb)
net/ipv6/seg6_iptunnel.c
661
return seg6_output_nf(net, sk, skb);
net/ipv6/seg6_iptunnel.c
663
return seg6_output_core(net, sk, skb);
net/ipv6/seg6_iptunnel.c
666
static int seg6_build_state(struct net *net, struct nlattr *nla,
net/ipv6/seg6_iptunnel.c
92
static void set_tun_src(struct net *net, struct net_device *dev,
net/ipv6/seg6_iptunnel.c
96
struct seg6_pernet_data *sdata = seg6_pernet(net);
net/ipv6/seg6_local.c
1007
static struct net *fib6_config_get_net(const struct fib6_config *fib6_cfg)
net/ipv6/seg6_local.c
1019
struct net *net;
net/ipv6/seg6_local.c
1021
net = fib6_config_get_net(cfg);
net/ipv6/seg6_local.c
1024
vrf_ifindex = l3mdev_ifindex_lookup_by_table_id(L3MDEV_TYPE_VRF, net,
net/ipv6/seg6_local.c
1041
info->net = net;
net/ipv6/seg6_local.c
1117
struct net *net = info->net;
net/ipv6/seg6_local.c
1122
if (unlikely(!net_eq(dev_net(skb->dev), net)))
net/ipv6/seg6_local.c
1125
return dev_get_by_index_rcu(net, vrf_ifindex);
net/ipv6/seg6_local.c
145
struct net *net;
net/ipv6/seg6_local.c
1609
static int seg6_local_input_core(struct net *net, struct sock *sk,
net/ipv6/seg6_local.c
2501
static int seg6_local_build_state(struct net *net, struct nlattr *nla,
net/ipv6/seg6_local.c
275
struct net *net = dev_net(skb->dev);
net/ipv6/seg6_local.c
296
dst = ip6_route_input_lookup(net, skb->dev, &fl6, skb, flags);
net/ipv6/seg6_local.c
300
table = fib6_get_table(net, tbl_id);
net/ipv6/seg6_local.c
304
rt = ip6_pol_route(net, table, oif, &fl6, skb, flags);
net/ipv6/seg6_local.c
307
dst = ip6_route_output(net, NULL, &fl6);
net/ipv6/seg6_local.c
323
rt = net->ipv6.ip6_blk_hole_entry;
net/ipv6/seg6_local.c
852
struct net *net = dev_net(skb->dev);
net/ipv6/seg6_local.c
872
odev = dev_get_by_index_rcu(net, slwt->oif);
net/ipv6/seg6_local.c
905
static int input_action_end_dx6_finish(struct net *net, struct sock *sk,
net/ipv6/seg6_local.c
956
static int input_action_end_dx4_finish(struct net *net, struct sock *sk,
net/ipv6/sit.c
1034
df, !net_eq(tunnel->net, dev_net(dev)), 0);
net/ipv6/sit.c
107
struct sit_net *sitn = net_generic(net, sit_net_id);
net/ipv6/sit.c
1107
struct rtable *rt = ip_route_output_ports(tunnel->net, &fl4,
net/ipv6/sit.c
1123
tdev = __dev_get_by_index(tunnel->net, tunnel->parms.link);
net/ipv6/sit.c
1141
struct net *net = t->net;
net/ipv6/sit.c
1142
struct sit_net *sitn = net_generic(net, sit_net_id);
net/ipv6/sit.c
1205
t = ipip6_tunnel_locate(t->net, &p, 0);
net/ipv6/sit.c
1227
if (!ns_capable(t->net->user_ns, CAP_NET_ADMIN))
net/ipv6/sit.c
1254
__ipip6_tunnel_ioctl_validate(struct net *net, struct ip_tunnel_parm_kern *p)
net/ipv6/sit.c
1256
if (!ns_capable(net->user_ns, CAP_NET_ADMIN))
net/ipv6/sit.c
1276
t = ipip6_tunnel_locate(t->net, p, 0);
net/ipv6/sit.c
1289
err = __ipip6_tunnel_ioctl_validate(t->net, p);
net/ipv6/sit.c
1293
t = ipip6_tunnel_locate(t->net, p, 1);
net/ipv6/sit.c
1305
err = __ipip6_tunnel_ioctl_validate(t->net, p);
net/ipv6/sit.c
1309
t = ipip6_tunnel_locate(t->net, p, 0);
net/ipv6/sit.c
1335
if (!ns_capable(t->net->user_ns, CAP_NET_ADMIN))
net/ipv6/sit.c
1339
t = ipip6_tunnel_locate(t->net, p, 0);
net/ipv6/sit.c
1466
struct net *net = dev_net(dev);
net/ipv6/sit.c
1467
struct sit_net *sitn = net_generic(net, sit_net_id);
net/ipv6/sit.c
1560
struct net *net;
net/ipv6/sit.c
1563
net = params->link_net ? : dev_net(dev);
net/ipv6/sit.c
1565
nt->net = net;
net/ipv6/sit.c
1575
if (ipip6_tunnel_locate(net, &nt->parms, 0))
net/ipv6/sit.c
1608
struct net *net = t->net;
net/ipv6/sit.c
1609
struct sit_net *sitn = net_generic(net, sit_net_id);
net/ipv6/sit.c
1616
if (!rtnl_dev_link_net_capable(dev, net))
net/ipv6/sit.c
1634
t = ipip6_tunnel_locate(net, &p, 0);
net/ipv6/sit.c
1764
struct net *net = dev_net(dev);
net/ipv6/sit.c
1765
struct sit_net *sitn = net_generic(net, sit_net_id);
net/ipv6/sit.c
1806
static void __net_exit sit_exit_rtnl_net(struct net *net, struct list_head *head)
net/ipv6/sit.c
1808
struct sit_net *sitn = net_generic(net, sit_net_id);
net/ipv6/sit.c
1812
for_each_netdev_safe(net, dev, aux)
net/ipv6/sit.c
1821
t = rtnl_net_dereference(net, sitn->tunnels[prio][h]);
net/ipv6/sit.c
1826
if (!net_eq(dev_net(t->dev), net))
net/ipv6/sit.c
1829
t = rtnl_net_dereference(net, t->next);
net/ipv6/sit.c
1835
static int __net_init sit_init_net(struct net *net)
net/ipv6/sit.c
1837
struct sit_net *sitn = net_generic(net, sit_net_id);
net/ipv6/sit.c
1846
if (!net_has_fallback_tunnels(net))
net/ipv6/sit.c
1856
dev_net_set(sitn->fb_tunnel_dev, net);
net/ipv6/sit.c
1864
t->net = net;
net/ipv6/sit.c
206
struct sit_net *sitn = net_generic(t->net, sit_net_id);
net/ipv6/sit.c
230
static struct ip_tunnel *ipip6_tunnel_locate(struct net *net,
net/ipv6/sit.c
240
struct sit_net *sitn = net_generic(net, sit_net_id);
net/ipv6/sit.c
269
dev_net_set(dev, net);
net/ipv6/sit.c
273
nt->net = net;
net/ipv6/sit.c
465
if (!ns_capable(t->net->user_ns, CAP_NET_ADMIN))
net/ipv6/sit.c
517
struct sit_net *sitn = net_generic(tunnel->net, sit_net_id);
net/ipv6/sit.c
706
!net_eq(tunnel->net, dev_net(tunnel->dev))))
net/ipv6/sit.c
93
return net_generic(t->net, sit_net_id);
net/ipv6/sit.c
935
sock_net_uid(tunnel->net, NULL));
net/ipv6/sit.c
939
rt = ip_route_output_flow(tunnel->net, &fl4, NULL);
net/ipv6/sit.c
99
static struct ip_tunnel *ipip6_tunnel_lookup(struct net *net,
net/ipv6/syncookies.c
131
static struct request_sock *cookie_tcp_check(struct net *net, struct sock *sk,
net/ipv6/syncookies.c
143
__NET_INC_STATS(net, LINUX_MIB_SYNCOOKIESFAILED);
net/ipv6/syncookies.c
147
__NET_INC_STATS(net, LINUX_MIB_SYNCOOKIESRECV);
net/ipv6/syncookies.c
151
tcp_parse_options(net, skb, &tcp_opt, 0, NULL);
net/ipv6/syncookies.c
156
st = secure_tcpv6_seq_and_ts_off(net,
net/ipv6/syncookies.c
165
if (!cookie_timestamp_decode(net, &tcp_opt))
net/ipv6/syncookies.c
180
struct net *net = sock_net(sk);
net/ipv6/syncookies.c
188
if (!READ_ONCE(net->ipv4.sysctl_tcp_syncookies) ||
net/ipv6/syncookies.c
195
req = cookie_tcp_check(net, sk, skb);
net/ipv6/syncookies.c
248
ip6_ecmp_set_mp_hash(net, &fl6, tcp_rsk(req)->txhash);
net/ipv6/syncookies.c
250
dst = ip6_dst_lookup_flow(net, sk, &fl6, final_p);
net/ipv6/syncookies.c
274
ireq->ecn_ok &= cookie_ecn_ok(net, dst);
net/ipv6/sysctl_net_ipv6.c
252
static int __net_init ipv6_sysctl_net_init(struct net *net)
net/ipv6/sysctl_net_ipv6.c
267
ipv6_table[i].data += (void *)net - (void *)&init_net;
net/ipv6/sysctl_net_ipv6.c
269
ipv6_route_table = ipv6_route_sysctl_init(net);
net/ipv6/sysctl_net_ipv6.c
273
ipv6_icmp_table = ipv6_icmp_sysctl_init(net);
net/ipv6/sysctl_net_ipv6.c
277
net->ipv6.sysctl.hdr = register_net_sysctl_sz(net, "net/ipv6",
net/ipv6/sysctl_net_ipv6.c
279
if (!net->ipv6.sysctl.hdr)
net/ipv6/sysctl_net_ipv6.c
282
net->ipv6.sysctl.route_hdr = register_net_sysctl_sz(net,
net/ipv6/sysctl_net_ipv6.c
285
ipv6_route_sysctl_table_size(net));
net/ipv6/sysctl_net_ipv6.c
286
if (!net->ipv6.sysctl.route_hdr)
net/ipv6/sysctl_net_ipv6.c
289
net->ipv6.sysctl.icmp_hdr = register_net_sysctl_sz(net,
net/ipv6/sysctl_net_ipv6.c
293
if (!net->ipv6.sysctl.icmp_hdr)
net/ipv6/sysctl_net_ipv6.c
300
unregister_net_sysctl_table(net->ipv6.sysctl.route_hdr);
net/ipv6/sysctl_net_ipv6.c
302
unregister_net_sysctl_table(net->ipv6.sysctl.hdr);
net/ipv6/sysctl_net_ipv6.c
312
static void __net_exit ipv6_sysctl_net_exit(struct net *net)
net/ipv6/sysctl_net_ipv6.c
318
ipv6_table = net->ipv6.sysctl.hdr->ctl_table_arg;
net/ipv6/sysctl_net_ipv6.c
319
ipv6_route_table = net->ipv6.sysctl.route_hdr->ctl_table_arg;
net/ipv6/sysctl_net_ipv6.c
320
ipv6_icmp_table = net->ipv6.sysctl.icmp_hdr->ctl_table_arg;
net/ipv6/sysctl_net_ipv6.c
322
unregister_net_sysctl_table(net->ipv6.sysctl.icmp_hdr);
net/ipv6/sysctl_net_ipv6.c
323
unregister_net_sysctl_table(net->ipv6.sysctl.route_hdr);
net/ipv6/sysctl_net_ipv6.c
324
unregister_net_sysctl_table(net->ipv6.sysctl.hdr);
net/ipv6/sysctl_net_ipv6.c
36
struct net *net;
net/ipv6/sysctl_net_ipv6.c
39
net = container_of(table->data, struct net,
net/ipv6/sysctl_net_ipv6.c
43
call_netevent_notifiers(NETEVENT_IPV6_MPATH_HASH_UPDATE, net);
net/ipv6/sysctl_net_ipv6.c
52
struct net *net;
net/ipv6/sysctl_net_ipv6.c
55
net = container_of(table->data, struct net,
net/ipv6/sysctl_net_ipv6.c
59
call_netevent_notifiers(NETEVENT_IPV6_MPATH_HASH_UPDATE, net);
net/ipv6/tcp_ipv6.c
1019
struct net *net;
net/ipv6/tcp_ipv6.c
1036
net = sk ? sock_net(sk) : skb_dst_dev_net_rcu(skb);
net/ipv6/tcp_ipv6.c
1066
sk1 = inet6_lookup_listener(net, NULL, 0, &ipv6h->saddr, th->source,
net/ipv6/tcp_ipv6.c
109
tcp_v6_init_seq_and_ts_off(const struct net *net, const struct sk_buff *skb)
net/ipv6/tcp_ipv6.c
111
return secure_tcpv6_seq_and_ts_off(net,
net/ipv6/tcp_ipv6.c
1122
if (READ_ONCE(net->ipv6.sysctl.flowlabel_reflect) &
net/ipv6/tcp_ipv6.c
143
struct net *net = sock_net(sk);
net/ipv6/tcp_ipv6.c
1732
struct net *net = dev_net_rcu(skb->dev);
net/ipv6/tcp_ipv6.c
1751
__TCP_INC_STATS(net, TCP_MIB_INSEGS);
net/ipv6/tcp_ipv6.c
1864
__NET_INC_STATS(net, LINUX_MIB_TCPMINTTLDROP);
net/ipv6/tcp_ipv6.c
1927
__TCP_INC_STATS(net, TCP_MIB_CSUMERRORS);
net/ipv6/tcp_ipv6.c
1929
__TCP_INC_STATS(net, TCP_MIB_INERRS);
net/ipv6/tcp_ipv6.c
1966
sk2 = inet6_lookup_listener(net, skb, __tcp_hdrlen(th),
net/ipv6/tcp_ipv6.c
2262
int __net_init tcp6_proc_init(struct net *net)
net/ipv6/tcp_ipv6.c
2264
if (!proc_create_net_data("tcp6", 0444, net->proc_net, &tcp6_seq_ops,
net/ipv6/tcp_ipv6.c
2270
void tcp6_proc_exit(struct net *net)
net/ipv6/tcp_ipv6.c
2272
remove_proc_entry("tcp6", net->proc_net);
net/ipv6/tcp_ipv6.c
2314
.sysctl_wmem_offset = offsetof(struct net, ipv4.sysctl_tcp_wmem),
net/ipv6/tcp_ipv6.c
2315
.sysctl_rmem_offset = offsetof(struct net, ipv4.sysctl_tcp_rmem),
net/ipv6/tcp_ipv6.c
2340
static int __net_init tcpv6_net_init(struct net *net)
net/ipv6/tcp_ipv6.c
2344
res = inet_ctl_sock_create(&net->ipv6.tcp_sk, PF_INET6,
net/ipv6/tcp_ipv6.c
2345
SOCK_RAW, IPPROTO_TCP, net);
net/ipv6/tcp_ipv6.c
2347
net->ipv6.tcp_sk->sk_clockid = CLOCK_MONOTONIC;
net/ipv6/tcp_ipv6.c
2352
static void __net_exit tcpv6_net_exit(struct net *net)
net/ipv6/tcp_ipv6.c
2354
inet_ctl_sock_destroy(net->ipv6.tcp_sk);
net/ipv6/tcp_ipv6.c
286
ip6_ecmp_set_mp_hash(net, fl6, sk->sk_txhash);
net/ipv6/tcp_ipv6.c
288
dst = ip6_dst_lookup_flow(net, sk, fl6, final_p);
net/ipv6/tcp_ipv6.c
331
st = secure_tcpv6_seq_and_ts_off(net,
net/ipv6/tcp_ipv6.c
408
struct net *net = dev_net_rcu(skb->dev);
net/ipv6/tcp_ipv6.c
417
sk = __inet6_lookup_established(net, &hdr->daddr, th->dest,
net/ipv6/tcp_ipv6.c
422
__ICMP6_INC_STATS(net, __in6_dev_get(skb->dev),
net/ipv6/tcp_ipv6.c
447
__NET_INC_STATS(net, LINUX_MIB_LOCKDROPPEDICMPS);
net/ipv6/tcp_ipv6.c
455
__NET_INC_STATS(net, LINUX_MIB_TCPMINTTLDROP);
net/ipv6/tcp_ipv6.c
466
__NET_INC_STATS(net, LINUX_MIB_OUTOFWINDOWICMPS);
net/ipv6/tcp_ipv6.c
852
struct net *net = sk ? sock_net(sk) : skb_dst_dev_net_rcu(skb);
net/ipv6/tcp_ipv6.c
854
struct sock *ctl_sk = net->ipv6.tcp_sk;
net/ipv6/tcp_ipv6.c
950
if (!oif && netif_index_is_l3_master(net, skb->skb_iif))
net/ipv6/tcp_ipv6.c
976
ip6_ecmp_set_mp_hash(net, &fl6, txhash);
net/ipv6/tcp_ipv6.c
978
fl6.flowi6_mark = IP6_REPLY_MARK(net, skb->mark) ?: mark;
net/ipv6/tcp_ipv6.c
981
fl6.flowi6_uid = sock_net_uid(net, sk && sk_fullsock(sk) ? sk : NULL);
net/ipv6/tcp_ipv6.c
989
dst = ip6_dst_lookup_flow(net, sk, &fl6, NULL); /*sk's xfrm_policy can be referred*/
net/ipv6/tcp_ipv6.c
991
dst = ip6_dst_lookup_flow(net, ctl_sk, &fl6, NULL);
net/ipv6/tcp_ipv6.c
996
TCP_INC_STATS(net, TCP_MIB_OUTSEGS);
net/ipv6/tcp_ipv6.c
998
TCP_INC_STATS(net, TCP_MIB_OUTRSTS);
net/ipv6/tcpv6_offload.c
24
struct net *net;
net/ipv6/tcpv6_offload.c
35
net = dev_net_rcu(skb->dev);
net/ipv6/tcpv6_offload.c
36
sk = __inet6_lookup_established(net, &hdr->saddr, th->source,
net/ipv6/udp.c
1005
__UDP6_INC_STATS(net, UDP_MIB_IGNOREDMULTI);
net/ipv6/udp.c
1071
struct net *net = dev_net(skb->dev);
net/ipv6/udp.c
1108
sk = inet6_steal_sock(net, skb, sizeof(struct udphdr), saddr, uh->source, daddr, uh->dest,
net/ipv6/udp.c
1136
return __udp6_lib_mcast_deliver(net, skb, saddr, daddr);
net/ipv6/udp.c
1158
__UDP6_INC_STATS(net, UDP_MIB_NOPORTS);
net/ipv6/udp.c
1178
__UDP6_INC_STATS(net, UDP_MIB_CSUMERRORS);
net/ipv6/udp.c
1180
__UDP6_INC_STATS(net, UDP_MIB_INERRORS);
net/ipv6/udp.c
1186
static struct sock *__udp6_lib_demux_lookup(struct net *net,
net/ipv6/udp.c
1191
struct udp_table *udptable = net->ipv4.udp_table;
net/ipv6/udp.c
1198
hash2 = ipv6_portaddr_hash(net, loc_addr, hnum);
net/ipv6/udp.c
1204
inet6_match(net, sk, rmt_addr, loc_addr, ports, dif, sdif))
net/ipv6/udp.c
1214
struct net *net = dev_net(skb->dev);
net/ipv6/udp.c
1228
sk = __udp6_lib_demux_lookup(net, uh->dest,
net/ipv6/udp.c
131
compute_score(struct sock *sk, const struct net *net,
net/ipv6/udp.c
140
if (!net_eq(sock_net(sk), net) ||
net/ipv6/udp.c
164
dev_match = udp_sk_bound_dev_eq(net, bound_dev_if, dif, sdif);
net/ipv6/udp.c
1863
int __net_init udp6_proc_init(struct net *net)
net/ipv6/udp.c
1865
if (!proc_create_net_data("udp6", 0444, net->proc_net, &udp6_seq_ops,
net/ipv6/udp.c
1871
void udp6_proc_exit(struct net *net)
net/ipv6/udp.c
1873
remove_proc_entry("udp6", net->proc_net);
net/ipv6/udp.c
1908
.sysctl_wmem_offset = offsetof(struct net, ipv4.sysctl_udp_wmem_min),
net/ipv6/udp.c
1909
.sysctl_rmem_offset = offsetof(struct net, ipv4.sysctl_udp_rmem_min),
net/ipv6/udp.c
196
static struct sock *udp6_lib_lookup1(const struct net *net,
net/ipv6/udp.c
202
unsigned int slot = udp_hashfn(net, hnum, udptable->mask);
net/ipv6/udp.c
208
score = compute_score(sk, net,
net/ipv6/udp.c
220
static struct sock *udp6_lib_lookup2(const struct net *net,
net/ipv6/udp.c
235
score = compute_score(need_rescore ? result : sk, net, saddr,
net/ipv6/udp.c
248
result = inet6_lookup_reuseport(net, sk, skb, sizeof(struct udphdr),
net/ipv6/udp.c
277
static struct sock *udp6_lib_lookup4(const struct net *net,
net/ipv6/udp.c
290
static struct sock *udp6_lib_lookup4(const struct net *net,
net/ipv6/udp.c
303
hash4 = udp6_ehashfn(net, daddr, hnum, saddr, sport);
net/ipv6/udp.c
310
if (inet6_match(net, sk, saddr, daddr, ports, dif, sdif))
net/ipv6/udp.c
326
struct net *net = sock_net(sk);
net/ipv6/udp.c
337
hash = udp6_ehashfn(net, &sk->sk_v6_rcv_saddr, sk->sk_num,
net/ipv6/udp.c
345
struct sock *__udp6_lib_lookup(const struct net *net,
net/ipv6/udp.c
350
struct udp_table *udptable = net->ipv4.udp_table;
net/ipv6/udp.c
356
hash2 = ipv6_portaddr_hash(net, daddr, hnum);
net/ipv6/udp.c
360
result = udp6_lib_lookup4(net, saddr, sport, daddr, hnum,
net/ipv6/udp.c
367
result = udp6_lib_lookup2(net, saddr, sport,
net/ipv6/udp.c
375
sk = inet6_lookup_run_sk_lookup(net, IPPROTO_UDP, skb, sizeof(struct udphdr),
net/ipv6/udp.c
389
hash2 = ipv6_portaddr_hash(net, &in6addr_any, hnum);
net/ipv6/udp.c
392
result = udp6_lib_lookup2(net, saddr, sport,
net/ipv6/udp.c
399
result = udp6_lib_lookup1(net, saddr, sport, daddr, hnum, dif, sdif,
net/ipv6/udp.c
436
struct sock *udp6_lib_lookup(const struct net *net, const struct in6_addr *saddr, __be16 sport,
net/ipv6/udp.c
441
sk = __udp6_lib_lookup(net, saddr, sport, daddr, dport, dif, 0, NULL);
net/ipv6/udp.c
639
static struct sock *__udp6_lib_err_encap(struct net *net,
net/ipv6/udp.c
670
sk = __udp6_lib_lookup(net, &hdr->daddr, uh->source,
net/ipv6/udp.c
699
struct net *net = dev_net(skb->dev);
net/ipv6/udp.c
708
sk = __udp6_lib_lookup(net, daddr, uh->dest, saddr, uh->source,
net/ipv6/udp.c
714
sk = __udp6_lib_err_encap(net, hdr, offset, uh, sk, skb,
net/ipv6/udp.c
722
__ICMP6_INC_STATS(net, __in6_dev_get(skb->dev),
net/ipv6/udp.c
78
u32 udp6_ehashfn(const struct net *net,
net/ipv6/udp.c
787
struct net *net = sock_net(sk);
net/ipv6/udp.c
791
UDP6_INC_STATS(net, UDP_MIB_RCVBUFERRORS);
net/ipv6/udp.c
794
UDP6_INC_STATS(net, UDP_MIB_MEMERRORS);
net/ipv6/udp.c
797
UDP6_INC_STATS(net, UDP_MIB_INERRORS);
net/ipv6/udp.c
810
struct net *net = sock_net(sk);
net/ipv6/udp.c
844
__UDP6_INC_STATS(net, UDP_MIB_INDATAGRAMS);
net/ipv6/udp.c
869
__UDP6_INC_STATS(net, UDP_MIB_CSUMERRORS);
net/ipv6/udp.c
871
__UDP6_INC_STATS(net, UDP_MIB_INERRORS);
net/ipv6/udp.c
899
static bool __udp_v6_is_mcast_sock(struct net *net, const struct sock *sk,
net/ipv6/udp.c
906
if (!net_eq(sock_net(sk), net))
net/ipv6/udp.c
914
!udp_sk_bound_dev_eq(net, READ_ONCE(sk->sk_bound_dev_if), dif, sdif) ||
net/ipv6/udp.c
937
static int __udp6_lib_mcast_deliver(struct net *net, struct sk_buff *skb,
net/ipv6/udp.c
941
struct udp_table *udptable = net->ipv4.udp_table;
net/ipv6/udp.c
95
udp6_ehash_secret + net_hash_mix(net));
net/ipv6/udp.c
955
hslot = udp_hashslot(udptable, net, hnum);
net/ipv6/udp.c
960
hash2_any = ipv6_portaddr_hash(net, &in6addr_any, hnum) &
net/ipv6/udp.c
962
hash2 = ipv6_portaddr_hash(net, daddr, hnum) & udptable->mask;
net/ipv6/udp.c
969
if (!__udp_v6_is_mcast_sock(net, sk, uh->dest, daddr,
net/ipv6/udp.c
985
__UDP6_INC_STATS(net, UDP_MIB_RCVBUFERRORS);
net/ipv6/udp.c
986
__UDP6_INC_STATS(net, UDP_MIB_INERRORS);
net/ipv6/udp_offload.c
120
struct net *net = dev_net_rcu(skb->dev);
net/ipv6/udp_offload.c
124
sk = udp_tunnel_sk(net, true);
net/ipv6/udp_offload.c
130
return __udp6_lib_lookup(net, &iph->saddr, sport,
net/ipv6/xfrm6_input.c
239
struct net *net = dev_net(skb->dev);
net/ipv6/xfrm6_input.c
246
XFRM_INC_STATS(net, LINUX_MIB_XFRMINERROR);
net/ipv6/xfrm6_input.c
251
XFRM_INC_STATS(net, LINUX_MIB_XFRMINBUFFERERROR);
net/ipv6/xfrm6_input.c
275
x = xfrm_state_lookup_byaddr(net, skb->mark, dst, src, proto, AF_INET6);
net/ipv6/xfrm6_input.c
280
XFRM_INC_STATS(net, LINUX_MIB_XFRMINSTATEDIRERROR);
net/ipv6/xfrm6_input.c
304
XFRM_INC_STATS(net, LINUX_MIB_XFRMINNOSTATES);
net/ipv6/xfrm6_input.c
32
static int xfrm6_transport_finish2(struct net *net, struct sock *sk,
net/ipv6/xfrm6_output.c
106
int xfrm6_output(struct net *net, struct sock *sk, struct sk_buff *skb)
net/ipv6/xfrm6_output.c
109
net, sk, skb, skb->dev, skb_dst_dev(skb),
net/ipv6/xfrm6_output.c
43
static int __xfrm6_output_finish(struct net *net, struct sock *sk, struct sk_buff *skb)
net/ipv6/xfrm6_output.c
61
static int __xfrm6_output(struct net *net, struct sock *sk, struct sk_buff *skb)
net/ipv6/xfrm6_output.c
71
return dst_output(net, sk, skb);
net/ipv6/xfrm6_output.c
99
return ip6_fragment(net, sk, skb,
net/ipv6/xfrm6_policy.c
200
static int __net_init xfrm6_net_sysctl_init(struct net *net)
net/ipv6/xfrm6_policy.c
206
if (!net_eq(net, &init_net)) {
net/ipv6/xfrm6_policy.c
211
table[0].data = &net->xfrm.xfrm6_dst_ops.gc_thresh;
net/ipv6/xfrm6_policy.c
214
hdr = register_net_sysctl_sz(net, "net/ipv6", table,
net/ipv6/xfrm6_policy.c
219
net->ipv6.sysctl.xfrm6_hdr = hdr;
net/ipv6/xfrm6_policy.c
223
if (!net_eq(net, &init_net))
net/ipv6/xfrm6_policy.c
229
static void __net_exit xfrm6_net_sysctl_exit(struct net *net)
net/ipv6/xfrm6_policy.c
233
if (!net->ipv6.sysctl.xfrm6_hdr)
net/ipv6/xfrm6_policy.c
236
table = net->ipv6.sysctl.xfrm6_hdr->ctl_table_arg;
net/ipv6/xfrm6_policy.c
237
unregister_net_sysctl_table(net->ipv6.sysctl.xfrm6_hdr);
net/ipv6/xfrm6_policy.c
238
if (!net_eq(net, &init_net))
net/ipv6/xfrm6_policy.c
242
static inline int xfrm6_net_sysctl_init(struct net *net)
net/ipv6/xfrm6_policy.c
247
static inline void xfrm6_net_sysctl_exit(struct net *net)
net/ipv6/xfrm6_policy.c
252
static int __net_init xfrm6_net_init(struct net *net)
net/ipv6/xfrm6_policy.c
256
memcpy(&net->xfrm.xfrm6_dst_ops, &xfrm6_dst_ops_template,
net/ipv6/xfrm6_policy.c
258
ret = dst_entries_init(&net->xfrm.xfrm6_dst_ops);
net/ipv6/xfrm6_policy.c
262
ret = xfrm6_net_sysctl_init(net);
net/ipv6/xfrm6_policy.c
264
dst_entries_destroy(&net->xfrm.xfrm6_dst_ops);
net/ipv6/xfrm6_policy.c
269
static void __net_exit xfrm6_net_exit(struct net *net)
net/ipv6/xfrm6_policy.c
271
xfrm6_net_sysctl_exit(net);
net/ipv6/xfrm6_policy.c
272
dst_entries_destroy(&net->xfrm.xfrm6_dst_ops);
net/ipv6/xfrm6_policy.c
33
fl6.flowi6_l3mdev = l3mdev_master_ifindex_by_index(params->net,
net/ipv6/xfrm6_policy.c
43
dst = ip6_route_output(params->net, NULL, &fl6);
net/ipv6/xfrm6_tunnel.c
102
static int __xfrm6_tunnel_spi_check(struct net *net, u32 spi)
net/ipv6/xfrm6_tunnel.c
104
struct xfrm6_tunnel_net *xfrm6_tn = xfrm6_tunnel_pernet(net);
net/ipv6/xfrm6_tunnel.c
117
static u32 __xfrm6_tunnel_alloc_spi(struct net *net, xfrm_address_t *saddr)
net/ipv6/xfrm6_tunnel.c
119
struct xfrm6_tunnel_net *xfrm6_tn = xfrm6_tunnel_pernet(net);
net/ipv6/xfrm6_tunnel.c
131
index = __xfrm6_tunnel_spi_check(net, spi);
net/ipv6/xfrm6_tunnel.c
139
index = __xfrm6_tunnel_spi_check(net, spi);
net/ipv6/xfrm6_tunnel.c
163
__be32 xfrm6_tunnel_alloc_spi(struct net *net, xfrm_address_t *saddr)
net/ipv6/xfrm6_tunnel.c
169
x6spi = __xfrm6_tunnel_spi_lookup(net, saddr);
net/ipv6/xfrm6_tunnel.c
174
spi = __xfrm6_tunnel_alloc_spi(net, saddr);
net/ipv6/xfrm6_tunnel.c
187
static void xfrm6_tunnel_free_spi(struct net *net, xfrm_address_t *saddr)
net/ipv6/xfrm6_tunnel.c
189
struct xfrm6_tunnel_net *xfrm6_tn = xfrm6_tunnel_pernet(net);
net/ipv6/xfrm6_tunnel.c
224
struct net *net = dev_net(skb->dev);
net/ipv6/xfrm6_tunnel.c
228
spi = xfrm6_tunnel_spi_lookup(net, (const xfrm_address_t *)&iph->saddr);
net/ipv6/xfrm6_tunnel.c
292
struct net *net = xs_net(x);
net/ipv6/xfrm6_tunnel.c
294
xfrm6_tunnel_free_spi(net, (xfrm_address_t *)&x->props.saddr);
net/ipv6/xfrm6_tunnel.c
318
static int __net_init xfrm6_tunnel_net_init(struct net *net)
net/ipv6/xfrm6_tunnel.c
320
struct xfrm6_tunnel_net *xfrm6_tn = xfrm6_tunnel_pernet(net);
net/ipv6/xfrm6_tunnel.c
332
static void __net_exit xfrm6_tunnel_net_exit(struct net *net)
net/ipv6/xfrm6_tunnel.c
334
struct xfrm6_tunnel_net *xfrm6_tn = xfrm6_tunnel_pernet(net);
net/ipv6/xfrm6_tunnel.c
337
xfrm_state_flush(net, 0, false);
net/ipv6/xfrm6_tunnel.c
35
static inline struct xfrm6_tunnel_net *xfrm6_tunnel_pernet(struct net *net)
net/ipv6/xfrm6_tunnel.c
37
return net_generic(net, xfrm6_tunnel_net_id);
net/ipv6/xfrm6_tunnel.c
74
static struct xfrm6_tunnel_spi *__xfrm6_tunnel_spi_lookup(struct net *net, const xfrm_address_t *saddr)
net/ipv6/xfrm6_tunnel.c
76
struct xfrm6_tunnel_net *xfrm6_tn = xfrm6_tunnel_pernet(net);
net/ipv6/xfrm6_tunnel.c
89
__be32 xfrm6_tunnel_spi_lookup(struct net *net, const xfrm_address_t *saddr)
net/ipv6/xfrm6_tunnel.c
95
x6spi = __xfrm6_tunnel_spi_lookup(net, saddr);
net/iucv/af_iucv.c
2259
static int iucv_sock_create(struct net *net, struct socket *sock, int protocol,
net/kcm/kcmproc.c
20
struct net *net = seq_file_net(seq);
net/kcm/kcmproc.c
21
struct kcm_net *knet = net_generic(net, kcm_net_id);
net/kcm/kcmproc.c
249
struct net *net = seq->private;
net/kcm/kcmproc.c
250
struct kcm_net *knet = net_generic(net, kcm_net_id);
net/kcm/kcmproc.c
348
static int kcm_proc_init_net(struct net *net)
net/kcm/kcmproc.c
350
if (!proc_create_net_single("kcm_stats", 0444, net->proc_net,
net/kcm/kcmproc.c
354
if (!proc_create_net("kcm", 0444, net->proc_net, &kcm_seq_ops,
net/kcm/kcmproc.c
361
remove_proc_entry("kcm_stats", net->proc_net);
net/kcm/kcmproc.c
366
static void kcm_proc_exit_net(struct net *net)
net/kcm/kcmproc.c
368
remove_proc_entry("kcm", net->proc_net);
net/kcm/kcmproc.c
369
remove_proc_entry("kcm_stats", net->proc_net);
net/kcm/kcmproc.c
37
struct net *net = seq_file_net(seq);
net/kcm/kcmproc.c
38
struct kcm_net *knet = net_generic(net, kcm_net_id);
net/kcm/kcmproc.c
85
struct net *net = seq_file_net(seq);
net/kcm/kcmproc.c
86
struct kcm_net *knet = net_generic(net, kcm_net_id);
net/kcm/kcmsock.c
1786
static int kcm_create(struct net *net, struct socket *sock,
net/kcm/kcmsock.c
1789
struct kcm_net *knet = net_generic(net, kcm_net_id);
net/kcm/kcmsock.c
1807
sk = sk_alloc(net, PF_KCM, GFP_KERNEL, &kcm_proto, kern);
net/kcm/kcmsock.c
1851
static __net_init int kcm_init_net(struct net *net)
net/kcm/kcmsock.c
1853
struct kcm_net *knet = net_generic(net, kcm_net_id);
net/kcm/kcmsock.c
1861
static __net_exit void kcm_exit_net(struct net *net)
net/kcm/kcmsock.c
1863
struct kcm_net *knet = net_generic(net, kcm_net_id);
net/key/af_key.c
1075
static struct xfrm_state * pfkey_msg2xfrm_state(struct net *net,
net/key/af_key.c
1138
x = xfrm_state_alloc(net);
net/key/af_key.c
117
struct net *net = sock_net(sk);
net/key/af_key.c
118
struct netns_pfkey *net_pfkey = net_generic(net, pfkey_net_id);
net/key/af_key.c
1323
struct net *net = sock_net(sk);
net/key/af_key.c
1374
x = xfrm_find_acq_byseq(net, DUMMY_MARK, hdr->sadb_msg_seq, UINT_MAX);
net/key/af_key.c
138
static int pfkey_create(struct net *net, struct socket *sock, int protocol,
net/key/af_key.c
1382
x = xfrm_find_acq(net, &dummy_mark, mode, reqid, 0, UINT_MAX,
net/key/af_key.c
141
struct netns_pfkey *net_pfkey = net_generic(net, pfkey_net_id);
net/key/af_key.c
1422
pfkey_broadcast(resp_skb, GFP_KERNEL, BROADCAST_ONE, sk, net);
net/key/af_key.c
1429
struct net *net = sock_net(sk);
net/key/af_key.c
1438
x = xfrm_find_acq_byseq(net, DUMMY_MARK, hdr->sadb_msg_seq, UINT_MAX);
net/key/af_key.c
145
if (!ns_capable(net->user_ns, CAP_NET_ADMIN))
net/key/af_key.c
1516
struct net *net = sock_net(sk);
net/key/af_key.c
152
sk = sk_alloc(net, PF_KEY, GFP_KERNEL, &key_proto, kern);
net/key/af_key.c
1521
x = pfkey_msg2xfrm_state(net, hdr, ext_hdrs);
net/key/af_key.c
1553
struct net *net = sock_net(sk);
net/key/af_key.c
1563
x = pfkey_xfrm_state_lookup(net, hdr, ext_hdrs);
net/key/af_key.c
1593
struct net *net = sock_net(sk);
net/key/af_key.c
1604
x = pfkey_xfrm_state_lookup(net, hdr, ext_hdrs);
net/key/af_key.c
1770
pfkey_broadcast(skb, GFP_ATOMIC, BROADCAST_ALL, NULL, c->net);
net/key/af_key.c
1777
struct net *net = sock_net(sk);
net/key/af_key.c
1786
err = xfrm_state_flush(net, proto, true);
net/key/af_key.c
1798
c.net = net;
net/key/af_key.c
1836
struct net *net = sock_net(&pfk->sk);
net/key/af_key.c
1837
return xfrm_state_walk(net, &pfk->dump.u.state, dump_sa, (void *) pfk);
net/key/af_key.c
1842
struct net *net = sock_net(&pfk->sk);
net/key/af_key.c
1844
xfrm_state_walk_done(&pfk->dump.u.state, net);
net/key/af_key.c
1938
static u32 gen_reqid(struct net *net)
net/key/af_key.c
1951
rc = xfrm_policy_walk(net, &walk, check_reqid, (void*)&reqid);
net/key/af_key.c
1952
xfrm_policy_walk_done(&walk, net);
net/key/af_key.c
1963
struct net *net = xp_net(xp);
net/key/af_key.c
1988
if (!t->reqid && !(t->reqid = gen_reqid(net)))
net/key/af_key.c
217
struct net *net)
net/key/af_key.c
219
struct netns_pfkey *net_pfkey = net_generic(net, pfkey_net_id);
net/key/af_key.c
2265
struct net *net = sock_net(sk);
net/key/af_key.c
2285
xp = xfrm_policy_alloc(net, GFP_KERNEL);
net/key/af_key.c
2380
struct net *net = sock_net(sk);
net/key/af_key.c
2430
xp = xfrm_policy_bysel_ctx(net, &dummy_mark, 0, XFRM_POLICY_TYPE_MAIN,
net/key/af_key.c
2576
struct net *net = sock_net(sk);
net/key/af_key.c
2650
kma ? &k : NULL, net, NULL, 0, NULL, NULL);
net/key/af_key.c
2666
struct net *net = sock_net(sk);
net/key/af_key.c
2681
xp = xfrm_policy_byid(net, &dummy_mark, 0, XFRM_POLICY_TYPE_MAIN,
net/key/af_key.c
2743
struct net *net = sock_net(&pfk->sk);
net/key/af_key.c
2744
return xfrm_policy_walk(net, &pfk->dump.u.policy, dump_sp, (void *) pfk);
net/key/af_key.c
2749
struct net *net = sock_net((struct sock *)pfk);
net/key/af_key.c
2751
xfrm_policy_walk_done(&pfk->dump.u.policy, net);
net/key/af_key.c
2791
pfkey_broadcast(skb_out, GFP_ATOMIC, BROADCAST_ALL, NULL, c->net);
net/key/af_key.c
2798
struct net *net = sock_net(sk);
net/key/af_key.c
2802
err = xfrm_policy_flush(net, XFRM_POLICY_TYPE_MAIN, true);
net/key/af_key.c
2814
c.net = net;
net/key/af_key.c
3093
struct net *net = x ? xs_net(x) : c->net;
net/key/af_key.c
3094
struct netns_pfkey *net_pfkey = net_generic(net, pfkey_net_id);
net/key/af_key.c
3155
struct netns_pfkey *net_pfkey = net_generic(c->net, pfkey_net_id);
net/key/af_key.c
3286
struct net *net = sock_net(sk);
net/key/af_key.c
3319
xp = xfrm_policy_alloc(net, GFP_ATOMIC);
net/key/af_key.c
3568
const struct xfrm_kmaddress *k, struct net *net,
net/key/af_key.c
3673
pfkey_broadcast(skb, GFP_ATOMIC, BROADCAST_ALL, NULL, net);
net/key/af_key.c
3684
const struct xfrm_kmaddress *k, struct net *net,
net/key/af_key.c
3697
struct net *net = sock_net(sk);
net/key/af_key.c
3720
mutex_lock(&net->xfrm.xfrm_cfg_mutex);
net/key/af_key.c
3722
mutex_unlock(&net->xfrm.xfrm_cfg_mutex);
net/key/af_key.c
3822
struct net *net = seq_file_net(f);
net/key/af_key.c
3823
struct netns_pfkey *net_pfkey = net_generic(net, pfkey_net_id);
net/key/af_key.c
3831
struct net *net = seq_file_net(f);
net/key/af_key.c
3832
struct netns_pfkey *net_pfkey = net_generic(net, pfkey_net_id);
net/key/af_key.c
3850
static int __net_init pfkey_init_proc(struct net *net)
net/key/af_key.c
3854
e = proc_create_net("pfkey", 0, net->proc_net, &pfkey_seq_ops,
net/key/af_key.c
3862
static void __net_exit pfkey_exit_proc(struct net *net)
net/key/af_key.c
3864
remove_proc_entry("pfkey", net->proc_net);
net/key/af_key.c
3867
static inline int pfkey_init_proc(struct net *net)
net/key/af_key.c
3872
static inline void pfkey_exit_proc(struct net *net)
net/key/af_key.c
3888
static int __net_init pfkey_net_init(struct net *net)
net/key/af_key.c
3890
struct netns_pfkey *net_pfkey = net_generic(net, pfkey_net_id);
net/key/af_key.c
3896
rv = pfkey_init_proc(net);
net/key/af_key.c
3901
static void __net_exit pfkey_net_exit(struct net *net)
net/key/af_key.c
3903
struct netns_pfkey *net_pfkey = net_generic(net, pfkey_net_id);
net/key/af_key.c
3905
pfkey_exit_proc(net);
net/key/af_key.c
652
static struct xfrm_state *pfkey_xfrm_state_lookup(struct net *net, const struct sadb_msg *hdr, void * const *ext_hdrs)
net/key/af_key.c
690
return xfrm_state_lookup(net, DUMMY_MARK, xaddr, sa->sadb_sa_spi, proto, family);
net/key/af_key.c
96
struct net *net = sock_net(sk);
net/key/af_key.c
97
struct netns_pfkey *net_pfkey = net_generic(net, pfkey_net_id);
net/l2tp/l2tp_core.c
1020
struct net *net = sock_net(sk);
net/l2tp/l2tp_core.c
1068
session = l2tp_v2_session_get(net, tunnel_id, session_id);
net/l2tp/l2tp_core.c
1076
session = l2tp_v3_session_get(net, sk, session_id);
net/l2tp/l2tp_core.c
138
static struct l2tp_net *l2tp_pernet(const struct net *net)
net/l2tp/l2tp_core.c
140
return net_generic(net, l2tp_net_id);
net/l2tp/l2tp_core.c
1411
static void l2tp_tunnel_remove(struct net *net, struct l2tp_tunnel *tunnel)
net/l2tp/l2tp_core.c
1413
struct l2tp_net *pn = l2tp_pernet(net);
net/l2tp/l2tp_core.c
1457
static int l2tp_tunnel_sock_create(struct net *net,
net/l2tp/l2tp_core.c
1494
err = udp_sock_create(net, &udp_conf, &sock);
net/l2tp/l2tp_core.c
1505
err = sock_create_kern(net, AF_INET6, SOCK_DGRAM,
net/l2tp/l2tp_core.c
1533
err = sock_create_kern(net, AF_INET, SOCK_DGRAM,
net/l2tp/l2tp_core.c
1613
static int l2tp_validate_socket(const struct sock *sk, const struct net *net,
net/l2tp/l2tp_core.c
1618
if (!net_eq(sock_net(sk), net))
net/l2tp/l2tp_core.c
1643
int l2tp_tunnel_register(struct l2tp_tunnel *tunnel, struct net *net,
net/l2tp/l2tp_core.c
1646
struct l2tp_net *pn = l2tp_pernet(net);
net/l2tp/l2tp_core.c
1660
ret = l2tp_tunnel_sock_create(net, tunnel->tunnel_id,
net/l2tp/l2tp_core.c
1674
ret = l2tp_validate_socket(sk, net, tunnel->encap);
net/l2tp/l2tp_core.c
1687
setup_udp_tunnel_sock(net, sock->sk, &udp_cfg);
net/l2tp/l2tp_core.c
1695
tunnel->l2tp_net = net;
net/l2tp/l2tp_core.c
1717
l2tp_tunnel_remove(net, tunnel);
net/l2tp/l2tp_core.c
179
const struct net *net = sock_net(sk);
net/l2tp/l2tp_core.c
1842
static __net_init int l2tp_init_net(struct net *net)
net/l2tp/l2tp_core.c
1844
struct l2tp_net *pn = net_generic(net, l2tp_net_id);
net/l2tp/l2tp_core.c
185
pn = l2tp_pernet(net);
net/l2tp/l2tp_core.c
1856
static __net_exit void l2tp_pre_exit_net(struct net *net)
net/l2tp/l2tp_core.c
1858
struct l2tp_net *pn = l2tp_pernet(net);
net/l2tp/l2tp_core.c
1890
static __net_exit void l2tp_exit_net(struct net *net)
net/l2tp/l2tp_core.c
1892
struct l2tp_net *pn = l2tp_pernet(net);
net/l2tp/l2tp_core.c
215
struct l2tp_tunnel *l2tp_tunnel_get(const struct net *net, u32 tunnel_id)
net/l2tp/l2tp_core.c
217
const struct l2tp_net *pn = l2tp_pernet(net);
net/l2tp/l2tp_core.c
232
struct l2tp_tunnel *l2tp_tunnel_get_next(const struct net *net, unsigned long *key)
net/l2tp/l2tp_core.c
234
struct l2tp_net *pn = l2tp_pernet(net);
net/l2tp/l2tp_core.c
254
struct l2tp_session *l2tp_v3_session_get(const struct net *net, struct sock *sk, u32 session_id)
net/l2tp/l2tp_core.c
256
const struct l2tp_net *pn = l2tp_pernet(net);
net/l2tp/l2tp_core.c
297
struct l2tp_session *l2tp_v2_session_get(const struct net *net, u16 tunnel_id, u16 session_id)
net/l2tp/l2tp_core.c
300
const struct l2tp_net *pn = l2tp_pernet(net);
net/l2tp/l2tp_core.c
315
struct l2tp_session *l2tp_session_get(const struct net *net, struct sock *sk, int pver,
net/l2tp/l2tp_core.c
319
return l2tp_v2_session_get(net, tunnel_id, session_id);
net/l2tp/l2tp_core.c
321
return l2tp_v3_session_get(net, sk, session_id);
net/l2tp/l2tp_core.c
325
static struct l2tp_session *l2tp_v2_session_get_next(const struct net *net,
net/l2tp/l2tp_core.c
329
struct l2tp_net *pn = l2tp_pernet(net);
net/l2tp/l2tp_core.c
363
static struct l2tp_session *l2tp_v3_session_get_next(const struct net *net,
net/l2tp/l2tp_core.c
367
struct l2tp_net *pn = l2tp_pernet(net);
net/l2tp/l2tp_core.c
419
struct l2tp_session *l2tp_session_get_next(const struct net *net, struct sock *sk, int pver,
net/l2tp/l2tp_core.c
423
return l2tp_v2_session_get_next(net, tunnel_id, key);
net/l2tp/l2tp_core.c
425
return l2tp_v3_session_get_next(net, tunnel_id, sk, key);
net/l2tp/l2tp_core.c
432
struct l2tp_session *l2tp_session_get_by_ifname(const struct net *net,
net/l2tp/l2tp_core.c
435
struct l2tp_net *pn = l2tp_pernet(net);
net/l2tp/l2tp_core.h
175
struct net *l2tp_net; /* the net we belong to */
net/l2tp/l2tp_core.h
194
int (*session_create)(struct net *net, struct l2tp_tunnel *tunnel,
net/l2tp/l2tp_core.h
219
struct l2tp_tunnel *l2tp_tunnel_get(const struct net *net, u32 tunnel_id);
net/l2tp/l2tp_core.h
220
struct l2tp_tunnel *l2tp_tunnel_get_next(const struct net *net, unsigned long *key);
net/l2tp/l2tp_core.h
222
struct l2tp_session *l2tp_v3_session_get(const struct net *net, struct sock *sk, u32 session_id);
net/l2tp/l2tp_core.h
223
struct l2tp_session *l2tp_v2_session_get(const struct net *net, u16 tunnel_id, u16 session_id);
net/l2tp/l2tp_core.h
224
struct l2tp_session *l2tp_session_get(const struct net *net, struct sock *sk, int pver,
net/l2tp/l2tp_core.h
226
struct l2tp_session *l2tp_session_get_next(const struct net *net, struct sock *sk, int pver,
net/l2tp/l2tp_core.h
228
struct l2tp_session *l2tp_session_get_by_ifname(const struct net *net,
net/l2tp/l2tp_core.h
238
int l2tp_tunnel_register(struct l2tp_tunnel *tunnel, struct net *net,
net/l2tp/l2tp_debugfs.c
279
pd->net = get_net_ns_by_pid(current->pid);
net/l2tp/l2tp_debugfs.c
280
if (IS_ERR(pd->net)) {
net/l2tp/l2tp_debugfs.c
281
rc = PTR_ERR(pd->net);
net/l2tp/l2tp_debugfs.c
284
netns_tracker_alloc(pd->net, &pd->ns_tracker, GFP_KERNEL);
net/l2tp/l2tp_debugfs.c
296
put_net_track(pd->net, &pd->ns_tracker);
net/l2tp/l2tp_debugfs.c
309
if (pd->net)
net/l2tp/l2tp_debugfs.c
310
put_net_track(pd->net, &pd->ns_tracker);
net/l2tp/l2tp_debugfs.c
35
struct net *net;
net/l2tp/l2tp_debugfs.c
49
pd->tunnel = l2tp_tunnel_get_next(pd->net, &pd->tkey);
net/l2tp/l2tp_debugfs.c
59
pd->session = l2tp_session_get_next(pd->net, pd->tunnel->sock,
net/l2tp/l2tp_eth.c
226
static int l2tp_eth_create(struct net *net, struct l2tp_tunnel *tunnel,
net/l2tp/l2tp_eth.c
260
dev_net_set(dev, net);
net/l2tp/l2tp_ip.c
127
struct net *net = dev_net(skb->dev);
net/l2tp/l2tp_ip.c
137
pn = l2tp_ip_pernet(net);
net/l2tp/l2tp_ip.c
158
session = l2tp_v3_session_get(net, NULL, session_id);
net/l2tp/l2tp_ip.c
186
sk = __l2tp_ip_bind_lookup(net, iph->daddr, iph->saddr, inet_iif(skb),
net/l2tp/l2tp_ip.c
275
struct net *net = sock_net(sk);
net/l2tp/l2tp_ip.c
294
chk_addr_ret = inet_addr_type(net, addr->l2tp_addr.s_addr);
net/l2tp/l2tp_ip.c
307
pn = l2tp_ip_pernet(net);
net/l2tp/l2tp_ip.c
309
if (__l2tp_ip_bind_lookup(net, addr->l2tp_addr.s_addr, 0,
net/l2tp/l2tp_ip.c
51
static struct l2tp_ip_net *l2tp_ip_pernet(const struct net *net)
net/l2tp/l2tp_ip.c
53
return net_generic(net, l2tp_ip_net_id);
net/l2tp/l2tp_ip.c
56
static struct sock *__l2tp_ip_bind_lookup(const struct net *net, __be32 laddr,
net/l2tp/l2tp_ip.c
59
struct l2tp_ip_net *pn = l2tp_ip_pernet(net);
net/l2tp/l2tp_ip.c
660
static __net_init int l2tp_ip_init_net(struct net *net)
net/l2tp/l2tp_ip.c
662
struct l2tp_ip_net *pn = net_generic(net, l2tp_ip_net_id);
net/l2tp/l2tp_ip.c
67
if (!net_eq(sock_net(sk), net))
net/l2tp/l2tp_ip.c
670
static __net_exit void l2tp_ip_exit_net(struct net *net)
net/l2tp/l2tp_ip.c
672
struct l2tp_ip_net *pn = l2tp_ip_pernet(net);
net/l2tp/l2tp_ip6.c
137
struct net *net = dev_net(skb->dev);
net/l2tp/l2tp_ip6.c
147
pn = l2tp_ip6_pernet(net);
net/l2tp/l2tp_ip6.c
168
session = l2tp_v3_session_get(net, NULL, session_id);
net/l2tp/l2tp_ip6.c
196
sk = __l2tp_ip6_bind_lookup(net, &iph->daddr, &iph->saddr,
net/l2tp/l2tp_ip6.c
289
struct net *net = sock_net(sk);
net/l2tp/l2tp_ip6.c
296
pn = l2tp_ip6_pernet(net);
net/l2tp/l2tp_ip6.c
356
if (__l2tp_ip6_bind_lookup(net, &addr->l2tp_addr, NULL, bound_dev_if,
net/l2tp/l2tp_ip6.c
57
static struct l2tp_ip6_net *l2tp_ip6_pernet(const struct net *net)
net/l2tp/l2tp_ip6.c
59
return net_generic(net, l2tp_ip6_net_id);
net/l2tp/l2tp_ip6.c
62
static struct sock *__l2tp_ip6_bind_lookup(const struct net *net,
net/l2tp/l2tp_ip6.c
67
struct l2tp_ip6_net *pn = l2tp_ip6_pernet(net);
net/l2tp/l2tp_ip6.c
76
if (!net_eq(sock_net(sk), net))
net/l2tp/l2tp_ip6.c
792
static __net_init int l2tp_ip6_init_net(struct net *net)
net/l2tp/l2tp_ip6.c
794
struct l2tp_ip6_net *pn = net_generic(net, l2tp_ip6_net_id);
net/l2tp/l2tp_ip6.c
802
static __net_exit void l2tp_ip6_exit_net(struct net *net)
net/l2tp/l2tp_ip6.c
804
struct l2tp_ip6_net *pn = l2tp_ip6_pernet(net);
net/l2tp/l2tp_netlink.c
194
struct net *net = genl_info_net(info);
net/l2tp/l2tp_netlink.c
246
ret = l2tp_tunnel_register(tunnel, net, &cfg);
net/l2tp/l2tp_netlink.c
264
struct net *net = genl_info_net(info);
net/l2tp/l2tp_netlink.c
272
tunnel = l2tp_tunnel_get(net, tunnel_id);
net/l2tp/l2tp_netlink.c
294
struct net *net = genl_info_net(info);
net/l2tp/l2tp_netlink.c
302
tunnel = l2tp_tunnel_get(net, tunnel_id);
net/l2tp/l2tp_netlink.c
456
struct net *net = genl_info_net(info);
net/l2tp/l2tp_netlink.c
471
tunnel = l2tp_tunnel_get(net, tunnel_id);
net/l2tp/l2tp_netlink.c
484
return genlmsg_unicast(net, msg, info->snd_portid);
net/l2tp/l2tp_netlink.c
504
struct net *net = sock_net(skb->sk);
net/l2tp/l2tp_netlink.c
507
tunnel = l2tp_tunnel_get_next(net, &key);
net/l2tp/l2tp_netlink.c
53
struct net *net = genl_info_net(info);
net/l2tp/l2tp_netlink.c
537
struct net *net = genl_info_net(info);
net/l2tp/l2tp_netlink.c
545
tunnel = l2tp_tunnel_get(net, tunnel_id);
net/l2tp/l2tp_netlink.c
57
session = l2tp_session_get_by_ifname(net, ifname);
net/l2tp/l2tp_netlink.c
62
tunnel = l2tp_tunnel_get(net, tunnel_id);
net/l2tp/l2tp_netlink.c
639
ret = l2tp_nl_cmd_ops[cfg.pw_type]->session_create(net, tunnel,
net/l2tp/l2tp_netlink.c
64
session = l2tp_session_get(net, tunnel->sock, tunnel->version,
net/l2tp/l2tp_netlink.c
645
session = l2tp_session_get(net, tunnel->sock, tunnel->version,
net/l2tp/l2tp_netlink.c
842
struct net *net = sock_net(skb->sk);
net/l2tp/l2tp_netlink.c
850
tunnel = l2tp_tunnel_get_next(net, &tkey);
net/l2tp/l2tp_netlink.c
855
session = l2tp_session_get_next(net, tunnel->sock, tunnel->version,
net/l2tp/l2tp_ppp.c
1404
static void pppol2tp_next_tunnel(struct net *net, struct pppol2tp_seq_data *pd)
net/l2tp/l2tp_ppp.c
1411
pd->tunnel = l2tp_tunnel_get_next(net, &pd->tkey);
net/l2tp/l2tp_ppp.c
1422
static void pppol2tp_next_session(struct net *net, struct pppol2tp_seq_data *pd)
net/l2tp/l2tp_ppp.c
1428
pd->session = l2tp_session_get_next(net, pd->tunnel->sock,
net/l2tp/l2tp_ppp.c
1435
pppol2tp_next_tunnel(net, pd);
net/l2tp/l2tp_ppp.c
1443
struct net *net;
net/l2tp/l2tp_ppp.c
1454
net = seq_file_net(m);
net/l2tp/l2tp_ppp.c
1457
pppol2tp_next_tunnel(net, pd);
net/l2tp/l2tp_ppp.c
1459
pppol2tp_next_session(net, pd);
net/l2tp/l2tp_ppp.c
1606
static __net_init int pppol2tp_init_net(struct net *net)
net/l2tp/l2tp_ppp.c
1611
pde = proc_create_net("pppol2tp", 0444, net->proc_net,
net/l2tp/l2tp_ppp.c
1622
static __net_exit void pppol2tp_exit_net(struct net *net)
net/l2tp/l2tp_ppp.c
1624
remove_proc_entry("pppol2tp", net->proc_net);
net/l2tp/l2tp_ppp.c
470
static int pppol2tp_create(struct net *net, struct socket *sock, int kern)
net/l2tp/l2tp_ppp.c
475
sk = sk_alloc(net, PF_PPPOX, GFP_KERNEL, &pppol2tp_sk_proto, kern);
net/l2tp/l2tp_ppp.c
627
static struct l2tp_tunnel *pppol2tp_tunnel_get(struct net *net,
net/l2tp/l2tp_ppp.c
636
tunnel = l2tp_tunnel_get(net, info->tunnel_id);
net/l2tp/l2tp_ppp.c
663
error = l2tp_tunnel_register(tunnel, net, &tcfg);
net/l2tp/l2tp_ppp.c
842
static int pppol2tp_session_create(struct net *net, struct l2tp_tunnel *tunnel,
net/l3mdev/l3mdev.c
144
int l3mdev_master_upper_ifindex_by_index_rcu(struct net *net, int ifindex)
net/l3mdev/l3mdev.c
148
dev = dev_get_by_index_rcu(net, ifindex);
net/l3mdev/l3mdev.c
189
u32 l3mdev_fib_table_by_index(struct net *net, int ifindex)
net/l3mdev/l3mdev.c
199
dev = dev_get_by_index_rcu(net, ifindex);
net/l3mdev/l3mdev.c
218
struct dst_entry *l3mdev_link_scope_lookup(struct net *net,
net/l3mdev/l3mdev.c
226
dev = dev_get_by_index_rcu(net, fl6->flowi6_oif);
net/l3mdev/l3mdev.c
247
int l3mdev_fib_rule_match(struct net *net, struct flowi *fl,
net/l3mdev/l3mdev.c
259
dev = dev_get_by_index_rcu(net, fl->flowi_l3mdev);
net/l3mdev/l3mdev.c
271
void l3mdev_update_flow(struct net *net, struct flowi *fl)
net/l3mdev/l3mdev.c
278
dev = dev_get_by_index_rcu(net, fl->flowi_oif);
net/l3mdev/l3mdev.c
295
dev = dev_get_by_index_rcu(net, fl->flowi_iif);
net/l3mdev/l3mdev.c
77
struct net *net, u32 table_id)
net/l3mdev/l3mdev.c
96
ifindex = lookup(net, table_id);
net/llc/af_llc.c
166
static int llc_ui_create(struct net *net, struct socket *sock, int protocol,
net/llc/af_llc.c
172
if (!ns_capable(net->user_ns, CAP_NET_RAW))
net/llc/af_llc.c
175
if (!net_eq(net, &init_net))
net/llc/af_llc.c
180
sk = llc_sk_alloc(net, PF_LLC, GFP_KERNEL, &llc_proto, kern);
net/llc/llc_conn.c
452
const struct net *net)
net/llc/llc_conn.c
456
return net_eq(sock_net(sk), net) &&
net/llc/llc_conn.c
478
const struct net *net)
net/llc/llc_conn.c
488
if (llc_estab_match(sap, daddr, laddr, rc, net)) {
net/llc/llc_conn.c
493
!llc_estab_match(sap, daddr, laddr, rc, net))) {
net/llc/llc_conn.c
516
const struct net *net)
net/llc/llc_conn.c
521
sk = __llc_lookup_established(sap, daddr, laddr, net);
net/llc/llc_conn.c
529
const struct net *net)
net/llc/llc_conn.c
533
return net_eq(sock_net(sk), net) &&
net/llc/llc_conn.c
541
const struct net *net)
net/llc/llc_conn.c
551
if (llc_listener_match(sap, laddr, rc, net)) {
net/llc/llc_conn.c
556
!llc_listener_match(sap, laddr, rc, net))) {
net/llc/llc_conn.c
589
const struct net *net)
net/llc/llc_conn.c
591
struct sock *rc = __llc_lookup_listener(sap, laddr, net);
net/llc/llc_conn.c
595
rc = __llc_lookup_listener(sap, &null_addr, net);
net/llc/llc_conn.c
603
const struct net *net)
net/llc/llc_conn.c
605
struct sock *sk = __llc_lookup_established(sap, daddr, laddr, net);
net/llc/llc_conn.c
607
return sk ? : llc_lookup_listener(sap, laddr, net);
net/llc/llc_conn.c
923
struct sock *llc_sk_alloc(struct net *net, int family, gfp_t priority, struct proto *prot, int kern)
net/llc/llc_conn.c
925
struct sock *sk = sk_alloc(net, family, priority, prot, kern);
net/llc/llc_sap.c
292
const struct net *net)
net/llc/llc_sap.c
297
net_eq(sock_net(sk), net) &&
net/llc/llc_sap.c
313
const struct net *net)
net/llc/llc_sap.c
323
if (llc_dgram_match(sap, laddr, rc, net)) {
net/llc/llc_sap.c
328
!llc_dgram_match(sap, laddr, rc, net))) {
net/mctp/af_mctp.c
137
struct net *net = sock_net(&msk->sk);
net/mctp/af_mctp.c
179
msk->bind_peer_net = mctp_default_net(net);
net/mctp/af_mctp.c
269
cb->net = addr->smctp_network;
net/mctp/af_mctp.c
330
addr->smctp_network = cb->net;
net/mctp/af_mctp.c
362
static void __mctp_key_remove(struct mctp_sk_key *key, struct net *net,
net/mctp/af_mctp.c
365
__must_hold(&net->mctp.keys_lock)
net/mctp/af_mctp.c
457
ctl->net = MCTP_INITIAL_DEFAULT_NET;
net/mctp/af_mctp.c
505
struct net *net = sock_net(&msk->sk);
net/mctp/af_mctp.c
519
key = mctp_alloc_local_tag(msk, ctl.net, MCTP_ADDR_ANY,
net/mctp/af_mctp.c
533
spin_lock_irqsave(&net->mctp.keys_lock, flags);
net/mctp/af_mctp.c
535
__mctp_key_remove(key, net, fl2, MCTP_TRACE_KEY_DROPPED);
net/mctp/af_mctp.c
537
spin_unlock_irqrestore(&net->mctp.keys_lock, flags);
net/mctp/af_mctp.c
548
struct net *net = sock_net(&msk->sk);
net/mctp/af_mctp.c
57
struct net *net = sock_net(&msk->sk);
net/mctp/af_mctp.c
570
spin_lock_irqsave(&net->mctp.keys_lock, flags);
net/mctp/af_mctp.c
577
ctl.net == key->net &&
net/mctp/af_mctp.c
580
__mctp_key_remove(key, net, fl2,
net/mctp/af_mctp.c
587
spin_unlock_irqrestore(&net->mctp.keys_lock, flags);
net/mctp/af_mctp.c
655
struct net *net = sock_net(&msk->sk);
net/mctp/af_mctp.c
661
spin_lock_irqsave(&net->mctp.keys_lock, flags);
net/mctp/af_mctp.c
672
__mctp_key_remove(key, net, fl2,
net/mctp/af_mctp.c
687
spin_unlock_irqrestore(&net->mctp.keys_lock, flags);
net/mctp/af_mctp.c
710
struct net *net = sock_net(sk);
net/mctp/af_mctp.c
725
mutex_lock(&net->mctp.bind_lock);
net/mctp/af_mctp.c
728
sk_for_each(existing, &net->mctp.binds[hash]) {
net/mctp/af_mctp.c
747
sk_add_node_rcu(sk, &net->mctp.binds[hash]);
net/mctp/af_mctp.c
751
mutex_unlock(&net->mctp.bind_lock);
net/mctp/af_mctp.c
758
struct net *net = sock_net(sk);
net/mctp/af_mctp.c
764
mutex_lock(&net->mctp.bind_lock);
net/mctp/af_mctp.c
766
mutex_unlock(&net->mctp.bind_lock);
net/mctp/af_mctp.c
769
spin_lock_irqsave(&net->mctp.keys_lock, flags);
net/mctp/af_mctp.c
772
__mctp_key_remove(key, net, fl2, MCTP_TRACE_KEY_CLOSED);
net/mctp/af_mctp.c
775
spin_unlock_irqrestore(&net->mctp.keys_lock, flags);
net/mctp/af_mctp.c
799
static int mctp_pf_create(struct net *net, struct socket *sock,
net/mctp/af_mctp.c
820
sk = sk_alloc(net, PF_MCTP, GFP_KERNEL, proto, kern);
net/mctp/af_mctp.c
92
msk->bind_net = mctp_default_net(net);
net/mctp/device.c
117
struct net *net = sock_net(skb->sk);
net/mctp/device.c
135
for_each_netdev_dump(net, dev, mcb->ifindex) {
net/mctp/device.c
156
struct net *net = dev_net(mdev->dev);
net/mctp/device.c
171
rtnl_notify(skb, net, portid, RTNLGRP_MCTP_IFADDR, req_nlh, GFP_KERNEL);
net/mctp/device.c
175
rtnl_set_sk_err(net, RTNLGRP_MCTP_IFADDR, rc);
net/mctp/device.c
186
struct net *net = sock_net(skb->sk);
net/mctp/device.c
211
dev = __dev_get_by_index(net, ifm->ifa_index);
net/mctp/device.c
249
struct net *net = sock_net(skb->sk);
net/mctp/device.c
274
dev = __dev_get_by_index(net, ifm->ifa_index);
net/mctp/device.c
345
mdev->net = mctp_default_net(dev_net(dev));
net/mctp/device.c
365
if (nla_put_u32(skb, IFLA_MCTP_NET, mdev->net))
net/mctp/device.c
409
WRITE_ONCE(mdev->net, nla_get_u32(tb[IFLA_MCTP_NET]));
net/mctp/neigh.c
106
mutex_unlock(&net->mctp.neigh_lock);
net/mctp/neigh.c
118
struct net *net = sock_net(skb->sk);
net/mctp/neigh.c
156
dev = __dev_get_by_index(net, ndm->ndm_ifindex);
net/mctp/neigh.c
176
struct net *net = sock_net(skb->sk);
net/mctp/neigh.c
198
dev = __dev_get_by_index(net, ndm->ndm_ifindex);
net/mctp/neigh.c
246
struct net *net = sock_net(skb->sk);
net/mctp/neigh.c
262
list_for_each_entry_rcu(neigh, &net->mctp.neighbours, list) {
net/mctp/neigh.c
28
struct net *net = dev_net(mdev->dev);
net/mctp/neigh.c
285
struct net *net = dev_net(mdev->dev);
net/mctp/neigh.c
290
list_for_each_entry_rcu(neigh, &net->mctp.neighbours, list) {
net/mctp/neigh.c
304
static int __net_init mctp_neigh_net_init(struct net *net)
net/mctp/neigh.c
306
struct netns_mctp *ns = &net->mctp;
net/mctp/neigh.c
313
static void __net_exit mctp_neigh_net_exit(struct net *net)
net/mctp/neigh.c
315
struct netns_mctp *ns = &net->mctp;
net/mctp/neigh.c
32
mutex_lock(&net->mctp.neigh_lock);
net/mctp/neigh.c
55
list_add_rcu(&neigh->list, &net->mctp.neighbours);
net/mctp/neigh.c
58
mutex_unlock(&net->mctp.neigh_lock);
net/mctp/neigh.c
73
struct net *net = dev_net(mdev->dev);
net/mctp/neigh.c
76
mutex_lock(&net->mctp.neigh_lock);
net/mctp/neigh.c
77
list_for_each_entry_safe(neigh, tmp, &net->mctp.neighbours, list) {
net/mctp/neigh.c
85
mutex_unlock(&net->mctp.neigh_lock);
net/mctp/neigh.c
91
struct net *net = dev_net(mdev->dev);
net/mctp/neigh.c
95
mutex_lock(&net->mctp.neigh_lock);
net/mctp/neigh.c
96
list_for_each_entry_safe(neigh, tmp, &net->mctp.neighbours, list) {
net/mctp/route.c
1022
static int mctp_dst_input_null(struct net *net, struct net_device *dev,
net/mctp/route.c
105
msk = mctp_lookup_bind_details(net, skb, type, mh->dest, mh->src,
net/mctp/route.c
109
msk = mctp_lookup_bind_details(net, skb, type, MCTP_ADDR_ANY, mh->src,
net/mctp/route.c
113
msk = mctp_lookup_bind_details(net, skb, type, mh->dest, MCTP_ADDR_ANY,
net/mctp/route.c
1144
netid = READ_ONCE(dst->dev->net);
net/mctp/route.c
117
msk = mctp_lookup_bind_details(net, skb, type, MCTP_ADDR_ANY,
net/mctp/route.c
1196
static int mctp_route_add(struct net *net, struct mctp_route *rt)
net/mctp/route.c
121
msk = mctp_lookup_bind_details(net, skb, type, MCTP_ADDR_ANY,
net/mctp/route.c
1223
list_for_each_entry(ert, &net->mctp.routes, list) {
net/mctp/route.c
1229
list_add_rcu(&rt->list, &net->mctp.routes);
net/mctp/route.c
1234
static int mctp_route_remove(struct net *net, unsigned int netid,
net/mctp/route.c
1250
list_for_each_entry_safe(rt, tmp, &net->mctp.routes, list) {
net/mctp/route.c
1290
return mctp_route_remove(dev_net(mdev->dev), mdev->net,
net/mctp/route.c
1297
struct net *net = dev_net(mdev->dev);
net/mctp/route.c
1301
list_for_each_entry_safe(rt, tmp, &net->mctp.routes, list) {
net/mctp/route.c
1316
struct net *net = dev_net(dev);
net/mctp/route.c
1362
cb->net = READ_ONCE(mdev->net);
net/mctp/route.c
1365
rc = mctp_route_lookup(net, cb->net, mh->dest, &dst);
net/mctp/route.c
1369
rc = mctp_dst_input_null(net, dev, &dst);
net/mctp/route.c
1409
static int mctp_route_nlparse_common(struct net *net, struct nlmsghdr *nlh,
net/mctp/route.c
1446
dev = __dev_get_by_index(net, ifindex);
net/mctp/route.c
1463
gatewayp->net = gateway->net != MCTP_NET_ANY ?
net/mctp/route.c
1464
gateway->net :
net/mctp/route.c
1465
READ_ONCE(net->mctp.default_net);
net/mctp/route.c
1490
static int mctp_route_nlparse_lookup(struct net *net, struct nlmsghdr *nlh,
net/mctp/route.c
1502
rc = mctp_route_nlparse_common(net, nlh, extack, tb, &rtm,
net/mctp/route.c
1508
*netid = mdev->net;
net/mctp/route.c
1510
*netid = gw.net;
net/mctp/route.c
1526
static int mctp_route_nlparse_populate(struct net *net, struct nlmsghdr *nlh,
net/mctp/route.c
1540
rc = mctp_route_nlparse_common(net, nlh, extack, tb, &rtm,
net/mctp/route.c
1570
rt->gateway.net = gw.net;
net/mctp/route.c
1583
struct net *net = sock_net(skb->sk);
net/mctp/route.c
1591
rc = mctp_route_nlparse_populate(net, nlh, extack, rt);
net/mctp/route.c
1602
rc = mctp_route_add(net, rt);
net/mctp/route.c
1614
struct net *net = sock_net(skb->sk);
net/mctp/route.c
1620
rc = mctp_route_nlparse_lookup(net, nlh, extack, &type, &netid,
net/mctp/route.c
1629
rc = mctp_route_remove(net, netid, daddr_start, daddr_extent, type);
net/mctp/route.c
163
static bool mctp_key_match(struct mctp_sk_key *key, unsigned int net,
net/mctp/route.c
166
if (key->net != net)
net/mctp/route.c
1694
struct net *net = sock_net(skb->sk);
net/mctp/route.c
1707
list_for_each_entry_rcu(rt, &net->mctp.routes, list) {
net/mctp/route.c
1724
static int __net_init mctp_routes_net_init(struct net *net)
net/mctp/route.c
1726
struct netns_mctp *ns = &net->mctp;
net/mctp/route.c
1733
WARN_ON(mctp_default_net_set(net, MCTP_INITIAL_DEFAULT_NET));
net/mctp/route.c
1737
static void __net_exit mctp_routes_net_exit(struct net *net)
net/mctp/route.c
1742
list_for_each_entry_rcu(rt, &net->mctp.routes, list)
net/mctp/route.c
184
static struct mctp_sk_key *mctp_lookup_key(struct net *net, struct sk_buff *skb,
net/mctp/route.c
198
spin_lock_irqsave(&net->mctp.keys_lock, flags);
net/mctp/route.c
200
hlist_for_each_entry(key, &net->mctp.keys, hlist) {
net/mctp/route.c
214
spin_unlock(&net->mctp.keys_lock);
net/mctp/route.c
217
spin_unlock_irqrestore(&net->mctp.keys_lock, flags);
net/mctp/route.c
224
unsigned int net,
net/mctp/route.c
234
key->net = net;
net/mctp/route.c
267
struct net *net = sock_net(&msk->sk);
net/mctp/route.c
272
spin_lock_irqsave(&net->mctp.keys_lock, flags);
net/mctp/route.c
279
hlist_for_each_entry(tmp, &net->mctp.keys, hlist) {
net/mctp/route.c
280
if (mctp_key_match(tmp, key->net, key->local_addr,
net/mctp/route.c
296
hlist_add_head(&key->hlist, &net->mctp.keys);
net/mctp/route.c
301
spin_unlock_irqrestore(&net->mctp.keys_lock, flags);
net/mctp/route.c
312
static void __mctp_key_done_in(struct mctp_sk_key *key, struct net *net,
net/mctp/route.c
330
spin_lock_irqsave(&net->mctp.keys_lock, flags);
net/mctp/route.c
336
spin_unlock_irqrestore(&net->mctp.keys_lock, flags);
net/mctp/route.c
43
static struct mctp_sock *mctp_lookup_bind_details(struct net *net,
net/mctp/route.c
437
struct net *net = dev_net(skb->dev);
net/mctp/route.c
468
netid = mctp_cb(skb)->net;
net/mctp/route.c
483
key = mctp_lookup_key(net, skb, netid, mh->src, &f);
net/mctp/route.c
497
any_key = mctp_lookup_key(net, skb, netid,
net/mctp/route.c
507
msk = mctp_lookup_bind(net, skb);
net/mctp/route.c
525
__mctp_key_done_in(key, net, f,
net/mctp/route.c
56
sk_for_each_rcu(sk, &net->mctp.binds[hash]) {
net/mctp/route.c
568
__mctp_key_done_in(key, net, f,
net/mctp/route.c
601
__mctp_key_done_in(key, net, f, MCTP_TRACE_KEY_REPLIED);
net/mctp/route.c
62
if (msk->bind_net != MCTP_NET_ANY && msk->bind_net != cb->net)
net/mctp/route.c
694
unsigned int mctp_default_net(struct net *net)
net/mctp/route.c
696
return READ_ONCE(net->mctp.default_net);
net/mctp/route.c
699
int mctp_default_net_set(struct net *net, unsigned int index)
net/mctp/route.c
703
WRITE_ONCE(net->mctp.default_net, index);
net/mctp/route.c
708
static void mctp_reserve_tag(struct net *net, struct mctp_sk_key *key,
net/mctp/route.c
711
struct netns_mctp *mns = &net->mctp;
net/mctp/route.c
734
struct net *net = sock_net(&msk->sk);
net/mctp/route.c
735
struct netns_mctp *mns = &net->mctp;
net/mctp/route.c
763
if (tmp->net != netid)
net/mctp/route.c
796
mctp_reserve_tag(net, key, msk);
net/mctp/route.c
81
static struct mctp_sock *mctp_lookup_bind(struct net *net, struct sk_buff *skb)
net/mctp/route.c
818
struct net *net = sock_net(&msk->sk);
net/mctp/route.c
819
struct netns_mctp *mns = &net->mctp;
net/mctp/route.c
829
if (tmp->net != netid)
net/mctp/route.c
865
READ_ONCE(rt->dev->net) : rt->gateway.net;
net/mctp/route.c
869
unsigned int net, mctp_eid_t eid)
net/mctp/route.c
871
return mctp_route_netid(rt) == net &&
net/mctp/route.c
916
int mctp_dst_from_extaddr(struct mctp_dst *dst, struct net *net, int ifindex,
net/mctp/route.c
928
netdev = dev_get_by_index_rcu(net, ifindex);
net/mctp/route.c
961
static struct mctp_route *mctp_route_lookup_single(struct net *net,
net/mctp/route.c
967
list_for_each_entry_rcu(rt, &net->mctp.routes, list) {
net/mctp/route.c
976
int mctp_route_lookup(struct net *net, unsigned int dnet,
net/mctp/route.c
988
rt = mctp_route_lookup_single(net, dnet, daddr);
net/mctp/test/route-test.c
1096
WRITE_ONCE(dev->mdev->net, netid);
net/mctp/test/route-test.c
1138
KUNIT_EXPECT_EQ(test, key->net, netid);
net/mctp/test/route-test.c
1211
rt2 = mctp_test_create_route_gw(&init_net, dev->mdev->net, 10, 9, 0);
net/mctp/test/route-test.c
1214
rc = mctp_route_lookup(&init_net, dev->mdev->net, 10, &dst);
net/mctp/test/route-test.c
1239
rt1 = mctp_test_create_route_gw(&init_net, dev->mdev->net, 9, 10, 0);
net/mctp/test/route-test.c
1241
rt2 = mctp_test_create_route_gw(&init_net, dev->mdev->net, 10, 9, 0);
net/mctp/test/route-test.c
1245
rc = mctp_route_lookup(&init_net, dev->mdev->net, 10, &dst);
net/mctp/test/route-test.c
1298
netid = mdev->net;
net/mctp/test/route-test.c
1310
rc = mctp_route_lookup(&init_net, dev->mdev->net, 11, &dst);
net/mctp/test/route-test.c
1430
unsigned int net;
net/mctp/test/route-test.c
1446
{ .hdr = LK(20, 10), .ty = 1, .net = 1, .expect = "remote20" },
net/mctp/test/route-test.c
1448
{ .hdr = LK(20, 255), .ty = 1, .net = 1, .expect = "remote20" },
net/mctp/test/route-test.c
1449
{ .hdr = LK(20, 0), .ty = 1, .net = 1, .expect = "remote20" },
net/mctp/test/route-test.c
1450
{ .hdr = LK(0, 255), .ty = 1, .net = 1, .expect = "any" },
net/mctp/test/route-test.c
1451
{ .hdr = LK(0, 11), .ty = 1, .net = 1, .expect = "any" },
net/mctp/test/route-test.c
1452
{ .hdr = LK(0, 0), .ty = 1, .net = 1, .expect = "any" },
net/mctp/test/route-test.c
1453
{ .hdr = LK(0, 10), .ty = 1, .net = 1, .expect = "local10" },
net/mctp/test/route-test.c
1454
{ .hdr = LK(21, 10), .ty = 1, .net = 1, .expect = "local10" },
net/mctp/test/route-test.c
1455
{ .hdr = LK(21, 11), .ty = 1, .net = 1, .expect = "remote21local11" },
net/mctp/test/route-test.c
1460
{ .hdr = LK(99, 99), .ty = 1, .net = 1, .expect = "any" },
net/mctp/test/route-test.c
1463
{ .hdr = LK(20, 10), .ty = 3, .net = 1, .expect = NULL },
net/mctp/test/route-test.c
1467
{ .hdr = LK(0, 0), .ty = 1, .net = 7, .expect = "any" },
net/mctp/test/route-test.c
1468
{ .hdr = LK(21, 10), .ty = 1, .net = 2, .expect = "any" },
net/mctp/test/route-test.c
1473
{ .hdr = LK(20, 10), .ty = 1, .net = 3, .expect = "any" },
net/mctp/test/route-test.c
1475
{ .hdr = LK(21, 10), .ty = 1, .net = 3, .expect = "remote21net3" },
net/mctp/test/route-test.c
1476
{ .hdr = LK(21, 10), .ty = 1, .net = 4, .expect = "remote21net4" },
net/mctp/test/route-test.c
1477
{ .hdr = LK(21, 10), .ty = 1, .net = 5, .expect = "remote21net5" },
net/mctp/test/route-test.c
1479
{ .hdr = LK(21, 10), .ty = 1, .net = 5, .expect = "remote21net5" },
net/mctp/test/route-test.c
1481
{ .hdr = LK(99, 10), .ty = 1, .net = 8, .expect = "local10net8" },
net/mctp/test/route-test.c
1483
{ .hdr = LK(99, 10), .ty = 1, .net = 9, .expect = "anynet9" },
net/mctp/test/route-test.c
1484
{ .hdr = LK(0, 0), .ty = 1, .net = 9, .expect = "anynet9" },
net/mctp/test/route-test.c
1485
{ .hdr = LK(99, 99), .ty = 1, .net = 9, .expect = "anynet9" },
net/mctp/test/route-test.c
1486
{ .hdr = LK(20, 10), .ty = 1, .net = 9, .expect = "anynet9" },
net/mctp/test/route-test.c
1535
t->hdr.src, t->hdr.dest, t->ty, t->net, t->expect);
net/mctp/test/route-test.c
1553
__mctp_route_test_init(test, &dev, &dst, &sock_ty0, rx->net);
net/mctp/test/route-test.c
1625
rc = mctp_route_lookup(&init_net, dev->mdev->net, 9, &dst);
net/mctp/test/route-test.c
1667
rt2 = mctp_test_create_route_gw(&init_net, dev->mdev->net, 10, 9, 0);
net/mctp/test/route-test.c
1671
rc = mctp_route_lookup(&init_net, dev->mdev->net, 10, &dst);
net/mctp/test/route-test.c
1686
struct net *net;
net/mctp/test/route-test.c
1692
net = dev_net(dev->ndev);
net/mctp/test/route-test.c
1694
rc = mctp_dst_from_extaddr(&dst, net, dev->ndev->ifindex, 0, NULL);
net/mctp/test/route-test.c
1697
rc = sock_create_kern(net, AF_MCTP, SOCK_DGRAM, 0, &sock);
net/mctp/test/route-test.c
194
WRITE_ONCE(dev->mdev->net, netid);
net/mctp/test/route-test.c
446
unsigned int net;
net/mctp/test/route-test.c
454
net = READ_ONCE(dev->mdev->net);
net/mctp/test/route-test.c
465
key = mctp_key_alloc(msk, net, params->key_local_addr,
net/mctp/test/utils.c
140
struct mctp_test_route *mctp_test_create_route_direct(struct net *net,
net/mctp/test/utils.c
160
list_add_rcu(&rt->rt.list, &net->mctp.routes);
net/mctp/test/utils.c
165
struct mctp_test_route *mctp_test_create_route_gw(struct net *net,
net/mctp/test/utils.c
183
rt->rt.gateway.net = netid;
net/mctp/test/utils.c
185
list_add_rcu(&rt->rt.list, &net->mctp.routes);
net/mctp/test/utils.c
233
cb->net = READ_ONCE(dev->mdev->net);
net/mctp/test/utils.c
67
dev->mdev->net = mctp_default_net(dev_net(ndev));
net/mctp/test/utils.h
50
struct mctp_test_route *mctp_test_create_route_direct(struct net *net,
net/mctp/test/utils.h
54
struct mctp_test_route *mctp_test_create_route_gw(struct net *net,
net/mpls/af_mpls.c
1011
index = find_free_label(net);
net/mpls/af_mpls.c
1014
if (!mpls_label_ok(net, &index, extack))
net/mpls/af_mpls.c
1025
old = mpls_route_input(net, index);
net/mpls/af_mpls.c
104
platform_label = mpls_platform_label_rcu(net, &platform_labels);
net/mpls/af_mpls.c
1070
mpls_route_update(net, index, rt, &cfg->rc_nlinfo);
net/mpls/af_mpls.c
1083
struct net *net = cfg->rc_nlinfo.nl_net;
net/mpls/af_mpls.c
1089
if (!mpls_label_ok(net, &index, extack))
net/mpls/af_mpls.c
1092
mpls_route_update(net, index, NULL, &cfg->rc_nlinfo);
net/mpls/af_mpls.c
1213
static void mpls_netconf_notify_devconf(struct net *net, int event,
net/mpls/af_mpls.c
1231
rtnl_notify(skb, net, 0, RTNLGRP_MPLS_NETCONF, NULL, GFP_KERNEL);
net/mpls/af_mpls.c
1234
rtnl_set_sk_err(net, RTNLGRP_MPLS_NETCONF, err);
net/mpls/af_mpls.c
1285
struct net *net = sock_net(in_skb->sk);
net/mpls/af_mpls.c
1312
dev = dev_get_by_index_rcu(net, ifindex);
net/mpls/af_mpls.c
1334
err = rtnl_unicast(skb, net, NETLINK_CB(in_skb).portid);
net/mpls/af_mpls.c
1350
struct net *net = sock_net(skb->sk);
net/mpls/af_mpls.c
1374
for_each_netdev_dump(net, dev, ctx->ifindex) {
net/mpls/af_mpls.c
1404
struct net *net = ctl->extra2;
net/mpls/af_mpls.c
1409
mpls_netconf_notify_devconf(net, RTM_NEWNETCONF,
net/mpls/af_mpls.c
1432
struct net *net = dev_net(dev);
net/mpls/af_mpls.c
1446
table[i].extra2 = net;
net/mpls/af_mpls.c
1451
mdev->sysctl = register_net_sysctl_sz(net, path, table, table_size);
net/mpls/af_mpls.c
1455
mpls_netconf_notify_devconf(net, RTM_NEWNETCONF, NETCONFA_ALL, mdev);
net/mpls/af_mpls.c
1468
struct net *net = dev_net(dev);
net/mpls/af_mpls.c
1478
mpls_netconf_notify_devconf(net, RTM_DELNETCONF, 0, mdev);
net/mpls/af_mpls.c
1528
struct net *net = dev_net(dev);
net/mpls/af_mpls.c
1531
for (index = 0; index < net->mpls.platform_labels; index++) {
net/mpls/af_mpls.c
1536
rt = mpls_route_input(net, index);
net/mpls/af_mpls.c
154
void mpls_stats_inc_outucastpkts(struct net *net,
net/mpls/af_mpls.c
1552
mpls_route_update(net, index, NULL, NULL);
net/mpls/af_mpls.c
1599
mpls_route_update(net, index, rt, NULL);
net/mpls/af_mpls.c
1607
struct net *net = dev_net(dev);
net/mpls/af_mpls.c
1611
for (index = 0; index < net->mpls.platform_labels; index++) {
net/mpls/af_mpls.c
1614
rt = mpls_route_input(net, index);
net/mpls/af_mpls.c
1641
struct net *net = dev_net(dev);
net/mpls/af_mpls.c
1646
mutex_lock(&net->mpls.platform_mutex);
net/mpls/af_mpls.c
1658
mdev = mpls_dev_get(net, dev);
net/mpls/af_mpls.c
167
IP_UPD_PO_STATS(net, IPSTATS_MIB_OUT, skb->len);
net/mpls/af_mpls.c
1691
mdev = mpls_dev_get(net, dev);
net/mpls/af_mpls.c
1699
mdev = mpls_dev_get(net, dev);
net/mpls/af_mpls.c
1710
mutex_unlock(&net->mpls.platform_mutex);
net/mpls/af_mpls.c
1714
mutex_unlock(&net->mpls.platform_mutex);
net/mpls/af_mpls.c
173
IP6_UPD_PO_STATS(net, in6dev,
net/mpls/af_mpls.c
1990
struct net *net = sock_net(skb->sk);
net/mpls/af_mpls.c
2002
mutex_lock(&net->mpls.platform_mutex);
net/mpls/af_mpls.c
2004
mutex_unlock(&net->mpls.platform_mutex);
net/mpls/af_mpls.c
2015
struct net *net = sock_net(skb->sk);
net/mpls/af_mpls.c
2027
mutex_lock(&net->mpls.platform_mutex);
net/mpls/af_mpls.c
2029
mutex_unlock(&net->mpls.platform_mutex);
net/mpls/af_mpls.c
2147
static int mpls_valid_fib_dump_req(struct net *net, const struct nlmsghdr *nlh,
net/mpls/af_mpls.c
2151
return ip_valid_fib_dump_req(net, nlh, filter, cb);
net/mpls/af_mpls.c
2154
static int mpls_valid_fib_dump_req(struct net *net, const struct nlmsghdr *nlh,
net/mpls/af_mpls.c
2195
filter->dev = dev_get_by_index_rcu(net, ifindex);
net/mpls/af_mpls.c
2231
struct net *net = sock_net(skb->sk);
net/mpls/af_mpls.c
2241
err = mpls_valid_fib_dump_req(net, nlh, &filter, cb);
net/mpls/af_mpls.c
2258
platform_label = mpls_platform_label_rcu(net, &platform_labels);
net/mpls/af_mpls.c
2328
struct nlmsghdr *nlh, struct net *net, u32 portid,
net/mpls/af_mpls.c
2346
rtnl_notify(skb, net, portid, RTNLGRP_MPLS_ROUTE, nlh, GFP_KERNEL);
net/mpls/af_mpls.c
2350
rtnl_set_sk_err(net, RTNLGRP_MPLS_ROUTE, err);
net/mpls/af_mpls.c
2414
struct net *net = sock_net(in_skb->sk);
net/mpls/af_mpls.c
2430
mutex_lock(&net->mpls.platform_mutex);
net/mpls/af_mpls.c
2447
if (!mpls_label_ok(net, &in_label, extack)) {
net/mpls/af_mpls.c
2453
if (in_label < net->mpls.platform_labels)
net/mpls/af_mpls.c
2454
rt = mpls_route_input(net, in_label);
net/mpls/af_mpls.c
2475
err = rtnl_unicast(skb, net, portid);
net/mpls/af_mpls.c
2566
err = rtnl_unicast(skb, net, portid);
net/mpls/af_mpls.c
2568
mutex_unlock(&net->mpls.platform_mutex);
net/mpls/af_mpls.c
2575
mutex_unlock(&net->mpls.platform_mutex);
net/mpls/af_mpls.c
2580
static int resize_platform_label_table(struct net *net, size_t limit)
net/mpls/af_mpls.c
2597
struct net_device *lo = net->loopback_dev;
net/mpls/af_mpls.c
2614
struct net_device *lo = net->loopback_dev;
net/mpls/af_mpls.c
2631
mutex_lock(&net->mpls.platform_mutex);
net/mpls/af_mpls.c
2634
old = mpls_dereference(net, net->mpls.platform_label);
net/mpls/af_mpls.c
2635
old_limit = net->mpls.platform_labels;
net/mpls/af_mpls.c
2639
mpls_route_update(net, index, NULL, NULL);
net/mpls/af_mpls.c
2663
write_seqcount_begin(&net->mpls.platform_label_seq);
net/mpls/af_mpls.c
2664
net->mpls.platform_labels = limit;
net/mpls/af_mpls.c
2665
rcu_assign_pointer(net->mpls.platform_label, labels);
net/mpls/af_mpls.c
2666
write_seqcount_end(&net->mpls.platform_label_seq);
net/mpls/af_mpls.c
2669
mutex_unlock(&net->mpls.platform_mutex);
net/mpls/af_mpls.c
2691
struct net *net = table->data;
net/mpls/af_mpls.c
2692
int platform_labels = net->mpls.platform_labels;
net/mpls/af_mpls.c
2706
ret = resize_platform_label_table(net, platform_labels);
net/mpls/af_mpls.c
2712
(&((struct net *)0)->field)
net/mpls/af_mpls.c
2742
static __net_init int mpls_net_init(struct net *net)
net/mpls/af_mpls.c
2748
mutex_init(&net->mpls.platform_mutex);
net/mpls/af_mpls.c
2749
seqcount_mutex_init(&net->mpls.platform_label_seq, &net->mpls.platform_mutex);
net/mpls/af_mpls.c
2751
net->mpls.platform_labels = 0;
net/mpls/af_mpls.c
2752
net->mpls.platform_label = NULL;
net/mpls/af_mpls.c
2753
net->mpls.ip_ttl_propagate = 1;
net/mpls/af_mpls.c
2754
net->mpls.default_ttl = 255;
net/mpls/af_mpls.c
2764
table[i].data = (char *)net + (uintptr_t)table[i].data;
net/mpls/af_mpls.c
2766
net->mpls.ctl = register_net_sysctl_sz(net, "net/mpls", table,
net/mpls/af_mpls.c
2768
if (net->mpls.ctl == NULL) {
net/mpls/af_mpls.c
2776
static __net_exit void mpls_net_exit(struct net *net)
net/mpls/af_mpls.c
2783
table = net->mpls.ctl->ctl_table_arg;
net/mpls/af_mpls.c
2784
unregister_net_sysctl_table(net->mpls.ctl);
net/mpls/af_mpls.c
2796
mutex_lock(&net->mpls.platform_mutex);
net/mpls/af_mpls.c
2798
platform_label = mpls_dereference(net, net->mpls.platform_label);
net/mpls/af_mpls.c
2799
platform_labels = net->mpls.platform_labels;
net/mpls/af_mpls.c
2804
rt = mpls_dereference(net, platform_label[index]);
net/mpls/af_mpls.c
2805
mpls_notify_route(net, index, rt, NULL, NULL);
net/mpls/af_mpls.c
2809
mutex_unlock(&net->mpls.platform_mutex);
net/mpls/af_mpls.c
293
static bool mpls_egress(struct net *net, struct mpls_route *rt,
net/mpls/af_mpls.c
328
net->mpls.ip_ttl_propagate))
net/mpls/af_mpls.c
350
net->mpls.ip_ttl_propagate))
net/mpls/af_mpls.c
368
struct net *net = dev_net_rcu(dev);
net/mpls/af_mpls.c
410
rt = mpls_route_input_rcu(net, dec.label);
net/mpls/af_mpls.c
460
if (!mpls_egress(net, rt, skb, dec))
net/mpls/af_mpls.c
477
mpls_stats_inc_outucastpkts(net, out_dev, skb);
net/mpls/af_mpls.c
575
static void mpls_notify_route(struct net *net, unsigned index,
net/mpls/af_mpls.c
586
rtmsg_lfib(event, index, rt, nlh, net, portid, nlm_flags);
net/mpls/af_mpls.c
589
static void mpls_route_update(struct net *net, unsigned index,
net/mpls/af_mpls.c
596
platform_label = mpls_dereference(net, net->mpls.platform_label);
net/mpls/af_mpls.c
597
rt = mpls_dereference(net, platform_label[index]);
net/mpls/af_mpls.c
600
mpls_notify_route(net, index, rt, new, info);
net/mpls/af_mpls.c
606
static unsigned int find_free_label(struct net *net)
net/mpls/af_mpls.c
611
index < net->mpls.platform_labels;
net/mpls/af_mpls.c
613
if (!mpls_route_input(net, index))
net/mpls/af_mpls.c
621
static struct net_device *inet_fib_lookup_dev(struct net *net,
net/mpls/af_mpls.c
630
rt = ip_route_output(net, daddr.s_addr, 0, 0, 0, RT_SCOPE_UNIVERSE);
net/mpls/af_mpls.c
641
static struct net_device *inet_fib_lookup_dev(struct net *net,
net/mpls/af_mpls.c
650
static struct net_device *inet6_fib_lookup_dev(struct net *net,
net/mpls/af_mpls.c
660
dst = ip6_dst_lookup_flow(net, NULL, &fl6, NULL);
net/mpls/af_mpls.c
671
static struct net_device *inet6_fib_lookup_dev(struct net *net,
net/mpls/af_mpls.c
679
static struct net_device *find_outdev(struct net *net,
net/mpls/af_mpls.c
688
dev = inet_fib_lookup_dev(net, nh, mpls_nh_via(rt, nh));
net/mpls/af_mpls.c
691
dev = inet6_fib_lookup_dev(net, nh, mpls_nh_via(rt, nh));
net/mpls/af_mpls.c
697
dev = netdev_get_by_index(net, oif,
net/mpls/af_mpls.c
712
static int mpls_nh_assign_dev(struct net *net, struct mpls_route *rt,
net/mpls/af_mpls.c
718
dev = find_outdev(net, rt, nh, oif);
net/mpls/af_mpls.c
726
if (!mpls_dev_get(net, dev))
net/mpls/af_mpls.c
74
struct nlmsghdr *nlh, struct net *net, u32 portid,
net/mpls/af_mpls.c
77
static struct mpls_route *mpls_route_input(struct net *net, unsigned int index)
net/mpls/af_mpls.c
803
struct net *net = cfg->rc_nlinfo.nl_net;
net/mpls/af_mpls.c
81
platform_label = mpls_dereference(net, net->mpls.platform_label);
net/mpls/af_mpls.c
819
err = mpls_nh_assign_dev(net, rt, nh, cfg->rc_ifindex);
net/mpls/af_mpls.c
82
return mpls_dereference(net, platform_label[index]);
net/mpls/af_mpls.c
832
static int mpls_nh_build(struct net *net, struct mpls_route *rt,
net/mpls/af_mpls.c
85
static struct mpls_route __rcu **mpls_platform_label_rcu(struct net *net, size_t *platform_labels)
net/mpls/af_mpls.c
858
err = mpls_nh_assign_dev(net, rt, nh, oif);
net/mpls/af_mpls.c
91
sequence = read_seqcount_begin(&net->mpls.platform_label_seq);
net/mpls/af_mpls.c
92
platform_label = rcu_dereference(net->mpls.platform_label);
net/mpls/af_mpls.c
93
*platform_labels = net->mpls.platform_labels;
net/mpls/af_mpls.c
94
} while (read_seqcount_retry(&net->mpls.platform_label_seq, sequence));
net/mpls/af_mpls.c
973
static bool mpls_label_ok(struct net *net, unsigned int *index,
net/mpls/af_mpls.c
984
if (*index >= net->mpls.platform_labels) {
net/mpls/af_mpls.c
99
static struct mpls_route *mpls_route_input_rcu(struct net *net, unsigned int index)
net/mpls/af_mpls.c
990
*index = array_index_nospec(*index, net->mpls.platform_labels);
net/mpls/af_mpls.c
998
struct net *net = cfg->rc_nlinfo.nl_net;
net/mpls/internal.h
188
#define mpls_dereference(net, p) \
net/mpls/internal.h
191
lockdep_is_held(&(net)->mpls.platform_mutex))
net/mpls/internal.h
198
static inline struct mpls_dev *mpls_dev_get(const struct net *net,
net/mpls/internal.h
201
return mpls_dereference(net, dev->mpls_ptr);
net/mpls/internal.h
211
void mpls_stats_inc_outucastpkts(struct net *net,
net/mpls/mpls_iptunnel.c
131
mpls_stats_inc_outucastpkts(net, out_dev, skb);
net/mpls/mpls_iptunnel.c
163
static int mpls_build_state(struct net *net, struct nlattr *nla,
net/mpls/mpls_iptunnel.c
48
struct net *net;
net/mpls/mpls_iptunnel.c
56
net = dev_net_rcu(out_dev);
net/mpls/mpls_iptunnel.c
80
!net->mpls.ip_ttl_propagate)
net/mpls/mpls_iptunnel.c
81
ttl = net->mpls.default_ttl;
net/mpls/mpls_iptunnel.c
89
!net->mpls.ip_ttl_propagate)
net/mpls/mpls_iptunnel.c
90
ttl = net->mpls.default_ttl;
net/mptcp/ctrl.c
100
return READ_ONCE(mptcp_get_pernet(net)->add_addr_v6_port_drop_ts);
net/mptcp/ctrl.c
382
static int mptcp_pernet_new_table(struct net *net, struct mptcp_pernet *pernet)
net/mptcp/ctrl.c
388
if (!net_eq(net, &init_net)) {
net/mptcp/ctrl.c
409
hdr = register_net_sysctl_sz(net, MPTCP_SYSCTL_PATH, table,
net/mptcp/ctrl.c
419
if (!net_eq(net, &init_net))
net/mptcp/ctrl.c
436
static int mptcp_pernet_new_table(struct net *net, struct mptcp_pernet *pernet)
net/mptcp/ctrl.c
458
struct net *net = sock_net(sk);
net/mptcp/ctrl.c
46
static struct mptcp_pernet *mptcp_get_pernet(const struct net *net)
net/mptcp/ctrl.c
461
pernet = mptcp_get_pernet(net);
net/mptcp/ctrl.c
475
MPTCP_INC_STATS(net, MPTCP_MIB_BLACKHOLE);
net/mptcp/ctrl.c
48
return net_generic(net, mptcp_pernet_id);
net/mptcp/ctrl.c
484
struct net *net = sock_net(ssk);
net/mptcp/ctrl.c
491
pernet = mptcp_get_pernet(net);
net/mptcp/ctrl.c
51
int mptcp_is_enabled(const struct net *net)
net/mptcp/ctrl.c
53
return mptcp_get_pernet(net)->mptcp_enabled;
net/mptcp/ctrl.c
537
struct net *net;
net/mptcp/ctrl.c
552
net = sock_net(ssk);
net/mptcp/ctrl.c
554
to_max = mptcp_get_pernet(net)->syn_retrans_before_tcp_fallback;
net/mptcp/ctrl.c
56
unsigned int mptcp_get_add_addr_timeout(const struct net *net)
net/mptcp/ctrl.c
563
static int __net_init mptcp_net_init(struct net *net)
net/mptcp/ctrl.c
565
struct mptcp_pernet *pernet = mptcp_get_pernet(net);
net/mptcp/ctrl.c
569
return mptcp_pernet_new_table(net, pernet);
net/mptcp/ctrl.c
573
static void __net_exit mptcp_net_exit(struct net *net)
net/mptcp/ctrl.c
575
struct mptcp_pernet *pernet = mptcp_get_pernet(net);
net/mptcp/ctrl.c
58
return mptcp_get_pernet(net)->add_addr_timeout;
net/mptcp/ctrl.c
61
int mptcp_is_checksum_enabled(const struct net *net)
net/mptcp/ctrl.c
63
return mptcp_get_pernet(net)->checksum_enabled;
net/mptcp/ctrl.c
66
int mptcp_allow_join_id0(const struct net *net)
net/mptcp/ctrl.c
68
return mptcp_get_pernet(net)->allow_join_initial_addr_port;
net/mptcp/ctrl.c
71
unsigned int mptcp_stale_loss_cnt(const struct net *net)
net/mptcp/ctrl.c
73
return mptcp_get_pernet(net)->stale_loss_cnt;
net/mptcp/ctrl.c
83
int mptcp_get_pm_type(const struct net *net)
net/mptcp/ctrl.c
85
return mptcp_get_pernet(net)->pm_type;
net/mptcp/ctrl.c
88
const char *mptcp_get_path_manager(const struct net *net)
net/mptcp/ctrl.c
90
return mptcp_get_pernet(net)->path_manager;
net/mptcp/ctrl.c
93
const char *mptcp_get_scheduler(const struct net *net)
net/mptcp/ctrl.c
95
return mptcp_get_pernet(net)->scheduler;
net/mptcp/ctrl.c
98
unsigned int mptcp_add_addr_v6_port_drop_ts(const struct net *net)
net/mptcp/mib.c
102
if (cmpxchg(&net->mib.mptcp_statistics, NULL, mib))
net/mptcp/mib.c
112
struct net *net = seq->private;
net/mptcp/mib.c
122
if (net->mib.mptcp_statistics)
net/mptcp/mib.c
124
net->mib.mptcp_statistics);
net/mptcp/mib.c
95
bool mptcp_mib_alloc(struct net *net)
net/mptcp/mib.h
103
if (likely(net->mib.mptcp_statistics))
net/mptcp/mib.h
104
SNMP_ADD_STATS(net->mib.mptcp_statistics, field, val);
net/mptcp/mib.h
107
static inline void MPTCP_INC_STATS(struct net *net,
net/mptcp/mib.h
110
if (likely(net->mib.mptcp_statistics))
net/mptcp/mib.h
111
SNMP_INC_STATS(net->mib.mptcp_statistics, field);
net/mptcp/mib.h
114
static inline void __MPTCP_INC_STATS(struct net *net,
net/mptcp/mib.h
117
if (likely(net->mib.mptcp_statistics))
net/mptcp/mib.h
118
__SNMP_INC_STATS(net->mib.mptcp_statistics, field);
net/mptcp/mib.h
121
static inline void MPTCP_DEC_STATS(struct net *net,
net/mptcp/mib.h
124
if (likely(net->mib.mptcp_statistics))
net/mptcp/mib.h
125
SNMP_DEC_STATS(net->mib.mptcp_statistics, field);
net/mptcp/mib.h
128
bool mptcp_mib_alloc(struct net *net);
net/mptcp/mib.h
99
static inline void MPTCP_ADD_STATS(struct net *net,
net/mptcp/mptcp_diag.c
108
if (!sk || !net_eq(sock_net(sk), net))
net/mptcp/mptcp_diag.c
154
struct net *net = sock_net(skb->sk);
net/mptcp/mptcp_diag.c
159
while ((msk = mptcp_token_iter_next(net, &diag_ctx->s_slot,
net/mptcp/mptcp_diag.c
34
struct net *net;
net/mptcp/mptcp_diag.c
37
net = sock_net(in_skb->sk);
net/mptcp/mptcp_diag.c
38
msk = mptcp_token_get_sock(net, req->id.idiag_cookie[0]);
net/mptcp/mptcp_diag.c
59
err = nlmsg_unicast(net->diag_nlsk, rep, NETLINK_CB(in_skb).portid);
net/mptcp/mptcp_diag.c
80
struct net *net = sock_net(skb->sk);
net/mptcp/mptcp_diag.c
84
hinfo = net->ipv4.tcp_death_row.hashinfo;
net/mptcp/pm.c
1068
struct net *net = sock_net(sk);
net/mptcp/pm.c
1072
stale_loss_cnt = mptcp_stale_loss_cnt(net);
net/mptcp/pm.c
1086
MPTCP_INC_STATS(net, MPTCP_MIB_SUBFLOWSTALE);
net/mptcp/pm.c
344
const struct net *net = sock_net((struct sock *)msk);
net/mptcp/pm.c
345
unsigned int rto = mptcp_get_add_addr_timeout(net);
net/mptcp/pm.c
947
struct net *net = sock_net((struct sock *)msk);
net/mptcp/pm.c
949
if (*drop_ts && mptcp_add_addr_v6_port_drop_ts(net)) {
net/mptcp/pm.c
957
MPTCP_INC_STATS(net, MPTCP_MIB_ECHOADDTXDROP);
net/mptcp/pm.c
960
MPTCP_INC_STATS(net, MPTCP_MIB_ADDADDRTXDROP);
net/mptcp/pm_kernel.c
1083
static int mptcp_nl_remove_subflow_and_signal_addr(struct net *net,
net/mptcp/pm_kernel.c
1093
while ((msk = mptcp_token_iter_next(net, &s_slot, &s_num)) != NULL) {
net/mptcp/pm_kernel.c
1128
static int mptcp_nl_remove_id_zero_address(struct net *net,
net/mptcp/pm_kernel.c
1137
while ((msk = mptcp_token_iter_next(net, &s_slot, &s_num)) != NULL) {
net/mptcp/pm_kernel.c
1270
static void mptcp_nl_flush_addrs_list(struct net *net,
net/mptcp/pm_kernel.c
1279
while ((msk = mptcp_token_iter_next(net, &s_slot, &s_num)) != NULL) {
net/mptcp/pm_kernel.c
1363
struct net *net = sock_net(msg->sk);
net/mptcp/pm_kernel.c
1369
pernet = pm_nl_get_pernet(net);
net/mptcp/pm_kernel.c
1481
static void mptcp_pm_nl_set_flags_all(struct net *net,
net/mptcp/pm_kernel.c
1493
while ((msk = mptcp_token_iter_next(net, &s_slot, &s_num)) != NULL) {
net/mptcp/pm_kernel.c
1519
struct net *net = genl_info_net(info);
net/mptcp/pm_kernel.c
1524
pernet = pm_nl_get_pernet(net);
net/mptcp/pm_kernel.c
1568
mptcp_pm_nl_set_flags_all(net, local, changed);
net/mptcp/pm_kernel.c
1604
static int __net_init pm_nl_init_net(struct net *net)
net/mptcp/pm_kernel.c
1606
struct pm_nl_pernet *pernet = pm_nl_get_pernet(net);
net/mptcp/pm_kernel.c
1624
struct net *net;
net/mptcp/pm_kernel.c
1626
list_for_each_entry(net, net_list, exit_list) {
net/mptcp/pm_kernel.c
1627
struct pm_nl_pernet *pernet = pm_nl_get_pernet(net);
net/mptcp/pm_kernel.c
35
static struct pm_nl_pernet *pm_nl_get_pernet(const struct net *net)
net/mptcp/pm_kernel.c
37
return net_generic(net, pm_nl_pernet_id);
net/mptcp/pm_kernel.c
961
static int mptcp_nl_add_subflow_or_signal_addr(struct net *net,
net/mptcp/pm_kernel.c
967
while ((msk = mptcp_token_iter_next(net, &s_slot, &s_num)) != NULL) {
net/mptcp/pm_netlink.c
285
static void mptcp_nl_mcast_send(struct net *net, struct sk_buff *nlskb, gfp_t gfp)
net/mptcp/pm_netlink.c
287
genlmsg_multicast_netns(&mptcp_genl_family, net,
net/mptcp/pm_netlink.c
436
struct net *net = sock_net((const struct sock *)msk);
net/mptcp/pm_netlink.c
440
if (!genl_has_listeners(&mptcp_genl_family, net, MPTCP_PM_EV_GRP_OFFSET))
net/mptcp/pm_netlink.c
458
mptcp_nl_mcast_send(net, skb, GFP_ATOMIC);
net/mptcp/pm_netlink.c
470
struct net *net = sock_net(ssk);
net/mptcp/pm_netlink.c
474
if (!genl_has_listeners(&mptcp_genl_family, net, MPTCP_PM_EV_GRP_OFFSET))
net/mptcp/pm_netlink.c
515
mptcp_nl_mcast_send(net, skb, GFP_ATOMIC);
net/mptcp/pm_netlink.c
526
struct net *net = sock_net(ssk);
net/mptcp/pm_netlink.c
530
if (!genl_has_listeners(&mptcp_genl_family, net, MPTCP_PM_EV_GRP_OFFSET))
net/mptcp/pm_netlink.c
565
mptcp_nl_mcast_send(net, skb, GFP_KERNEL);
net/mptcp/pm_netlink.c
575
struct net *net = sock_net((const struct sock *)msk);
net/mptcp/pm_netlink.c
579
if (!genl_has_listeners(&mptcp_genl_family, net, MPTCP_PM_EV_GRP_OFFSET))
net/mptcp/pm_netlink.c
623
mptcp_nl_mcast_send(net, skb, gfp);
net/mptcp/protocol.c
211
const struct net *net = sock_net(sk);
net/mptcp/protocol.c
217
if (!READ_ONCE(net->ipv4.sysctl_tcp_moderate_rcvbuf) ||
net/mptcp/protocol.c
229
cap = READ_ONCE(net->ipv4.sysctl_tcp_rmem[2]);
net/mptcp/protocol.c
3088
struct net *net = sock_net(sk);
net/mptcp/protocol.c
3093
if (!mptcp_is_enabled(net))
net/mptcp/protocol.c
3096
if (unlikely(!net->mib.mptcp_statistics) && !mptcp_mib_alloc(net))
net/mptcp/protocol.c
3101
mptcp_sched_find(mptcp_get_scheduler(net)));
net/mptcp/protocol.c
3114
sk->sk_rcvbuf = READ_ONCE(net->ipv4.sysctl_tcp_rmem[1]);
net/mptcp/protocol.c
3115
sk->sk_sndbuf = READ_ONCE(net->ipv4.sysctl_tcp_wmem[1]);
net/mptcp/protocol.c
4097
.sysctl_wmem_offset = offsetof(struct net, ipv4.sysctl_tcp_wmem),
net/mptcp/protocol.c
4098
.sysctl_rmem_offset = offsetof(struct net, ipv4.sysctl_tcp_rmem),
net/mptcp/protocol.c
78
struct net *net = sock_net((struct sock *)msk);
net/mptcp/protocol.c
98
__MPTCP_INC_STATS(net, fb_mib);
net/mptcp/protocol.h
1082
struct mptcp_sock *mptcp_token_get_sock(struct net *net, u32 token);
net/mptcp/protocol.h
1083
struct mptcp_sock *mptcp_token_iter_next(const struct net *net, long *s_slot,
net/mptcp/protocol.h
792
int mptcp_is_enabled(const struct net *net);
net/mptcp/protocol.h
793
unsigned int mptcp_get_add_addr_timeout(const struct net *net);
net/mptcp/protocol.h
794
int mptcp_is_checksum_enabled(const struct net *net);
net/mptcp/protocol.h
795
int mptcp_allow_join_id0(const struct net *net);
net/mptcp/protocol.h
796
unsigned int mptcp_stale_loss_cnt(const struct net *net);
net/mptcp/protocol.h
798
int mptcp_get_pm_type(const struct net *net);
net/mptcp/protocol.h
799
const char *mptcp_get_path_manager(const struct net *net);
net/mptcp/protocol.h
800
const char *mptcp_get_scheduler(const struct net *net);
net/mptcp/protocol.h
801
unsigned int mptcp_add_addr_v6_port_drop_ts(const struct net *net);
net/mptcp/protocol.h
989
struct net *net = sock_net(sk);
net/mptcp/protocol.h
993
return val ?: READ_ONCE(net->ipv4.sysctl_tcp_notsent_lowat);
net/mptcp/subflow.c
1780
struct net *net = sock_net(sk);
net/mptcp/subflow.c
1790
err = sock_create_kern(net, family, SOCK_STREAM, IPPROTO_TCP, &sf);
net/mptcp/syncookies.c
111
msk = mptcp_token_get_sock(net, e->token);
net/mptcp/syncookies.c
38
static u32 mptcp_join_entry_hash(struct sk_buff *skb, struct net *net)
net/mptcp/syncookies.c
52
i = jhash_3words(seq, net_hash_mix(net),
net/mptcp/syncookies.c
74
struct net *net = read_pnet(&subflow_req->sk.req.ireq_net);
net/mptcp/syncookies.c
75
u32 i = mptcp_join_entry_hash(skb, net);
net/mptcp/syncookies.c
95
struct net *net = read_pnet(&subflow_req->sk.req.ireq_net);
net/mptcp/syncookies.c
96
u32 i = mptcp_join_entry_hash(skb, net);
net/mptcp/token.c
246
struct mptcp_sock *mptcp_token_get_sock(struct net *net, u32 token)
net/mptcp/token.c
260
!net_eq(sock_net(sk), net))
net/mptcp/token.c
267
!net_eq(sock_net(sk), net)) {
net/mptcp/token.c
299
struct mptcp_sock *mptcp_token_iter_next(const struct net *net, long *s_slot,
net/mptcp/token.c
318
if (!net_eq(sock_net(sk), net))
net/mptcp/token.c
327
if (!net_eq(sock_net(sk), net)) {
net/ncsi/ncsi-netlink.c
34
static struct ncsi_dev_priv *ndp_from_ifindex(struct net *net, u32 ifindex)
net/ncsi/ncsi-netlink.c
41
if (!net)
net/ncsi/ncsi-netlink.c
44
dev = dev_get_by_index(net, ifindex);
net/ncsi/ncsi-netlink.c
487
struct net *net;
net/ncsi/ncsi-netlink.c
491
net = dev_net(nr->rsp->dev);
net/ncsi/ncsi-netlink.c
517
return genlmsg_unicast(net, skb, nr->snd_portid);
net/ncsi/ncsi-netlink.c
529
struct net *net;
net/ncsi/ncsi-netlink.c
543
net = dev_net(nr->cmd->dev);
net/ncsi/ncsi-netlink.c
560
return genlmsg_unicast(net, skb, nr->snd_portid);
net/ncsi/ncsi-netlink.c
572
struct net *net;
net/ncsi/ncsi-netlink.c
578
net = dev_net(dev);
net/ncsi/ncsi-netlink.c
588
return nlmsg_unicast(net->genl_sock, skb, snd_portid);
net/netfilter/core.c
272
nf_hook_entry_head(struct net *net, int pf, unsigned int hooknum,
net/netfilter/core.c
280
if (WARN_ON_ONCE(ARRAY_SIZE(net->nf.hooks_arp) <= hooknum))
net/netfilter/core.c
282
return net->nf.hooks_arp + hooknum;
net/netfilter/core.c
286
if (WARN_ON_ONCE(ARRAY_SIZE(net->nf.hooks_bridge) <= hooknum))
net/netfilter/core.c
288
return net->nf.hooks_bridge + hooknum;
net/netfilter/core.c
294
if (!dev || dev_net(dev) != net) {
net/netfilter/core.c
301
if (WARN_ON_ONCE(ARRAY_SIZE(net->nf.hooks_ipv4) <= hooknum))
net/netfilter/core.c
303
return net->nf.hooks_ipv4 + hooknum;
net/netfilter/core.c
305
if (WARN_ON_ONCE(ARRAY_SIZE(net->nf.hooks_ipv6) <= hooknum))
net/netfilter/core.c
307
return net->nf.hooks_ipv6 + hooknum;
net/netfilter/core.c
315
if (dev && dev_net(dev) == net)
net/netfilter/core.c
321
if (dev && dev_net(dev) == net)
net/netfilter/core.c
329
static int nf_ingress_check(struct net *net, const struct nf_hook_ops *reg,
net/netfilter/core.c
337
!reg->dev || dev_net(reg->dev) != net)
net/netfilter/core.c
389
static int __nf_register_net_hook(struct net *net, int pf,
net/netfilter/core.c
408
!reg->dev || dev_net(reg->dev) != net)
net/netfilter/core.c
415
err = nf_ingress_check(net, reg, NF_INET_INGRESS);
net/netfilter/core.c
421
pp = nf_hook_entry_head(net, pf, reg->hooknum, reg->dev);
net/netfilter/core.c
481
static void __nf_unregister_net_hook(struct net *net, int pf,
net/netfilter/core.c
487
pp = nf_hook_entry_head(net, pf, reg->hooknum, reg->dev);
net/netfilter/core.c
518
nf_queue_nf_hook_drop(net);
net/netfilter/core.c
522
void nf_unregister_net_hook(struct net *net, const struct nf_hook_ops *reg)
net/netfilter/core.c
526
__nf_unregister_net_hook(net, NFPROTO_INET, reg);
net/netfilter/core.c
528
__nf_unregister_net_hook(net, NFPROTO_IPV4, reg);
net/netfilter/core.c
529
__nf_unregister_net_hook(net, NFPROTO_IPV6, reg);
net/netfilter/core.c
532
__nf_unregister_net_hook(net, reg->pf, reg);
net/netfilter/core.c
550
int nf_register_net_hook(struct net *net, const struct nf_hook_ops *reg)
net/netfilter/core.c
556
err = __nf_register_net_hook(net, NFPROTO_INET, reg);
net/netfilter/core.c
560
err = __nf_register_net_hook(net, NFPROTO_IPV4, reg);
net/netfilter/core.c
564
err = __nf_register_net_hook(net, NFPROTO_IPV6, reg);
net/netfilter/core.c
566
__nf_unregister_net_hook(net, NFPROTO_IPV4, reg);
net/netfilter/core.c
571
err = __nf_register_net_hook(net, reg->pf, reg);
net/netfilter/core.c
580
int nf_register_net_hooks(struct net *net, const struct nf_hook_ops *reg,
net/netfilter/core.c
587
err = nf_register_net_hook(net, &reg[i]);
net/netfilter/core.c
595
nf_unregister_net_hooks(net, reg, i);
net/netfilter/core.c
600
void nf_unregister_net_hooks(struct net *net, const struct nf_hook_ops *reg,
net/netfilter/core.c
606
nf_unregister_net_hook(net, &reg[i]);
net/netfilter/core.c
767
static int __net_init netfilter_net_init(struct net *net)
net/netfilter/core.c
769
__netfilter_net_init(net->nf.hooks_ipv4, ARRAY_SIZE(net->nf.hooks_ipv4));
net/netfilter/core.c
770
__netfilter_net_init(net->nf.hooks_ipv6, ARRAY_SIZE(net->nf.hooks_ipv6));
net/netfilter/core.c
772
__netfilter_net_init(net->nf.hooks_arp, ARRAY_SIZE(net->nf.hooks_arp));
net/netfilter/core.c
775
__netfilter_net_init(net->nf.hooks_bridge, ARRAY_SIZE(net->nf.hooks_bridge));
net/netfilter/core.c
778
net->nf.proc_netfilter = proc_net_mkdir(net, "netfilter",
net/netfilter/core.c
779
net->proc_net);
net/netfilter/core.c
780
if (!net->nf.proc_netfilter) {
net/netfilter/core.c
781
if (!net_eq(net, &init_net))
net/netfilter/core.c
791
static void __net_exit netfilter_net_exit(struct net *net)
net/netfilter/core.c
793
remove_proc_entry("netfilter", net->proc_net);
net/netfilter/ipset/ip_set_bitmap_ip.c
250
bitmap_ip_create(struct net *net, struct ip_set *set, struct nlattr *tb[],
net/netfilter/ipset/ip_set_bitmap_ipmac.c
319
bitmap_ipmac_create(struct net *net, struct ip_set *set, struct nlattr *tb[],
net/netfilter/ipset/ip_set_bitmap_port.c
249
bitmap_port_create(struct net *net, struct ip_set *set, struct nlattr *tb[],
net/netfilter/ipset/ip_set_core.c
1052
struct ip_set_net *inst = ip_set_pernet(info->net);
net/netfilter/ipset/ip_set_core.c
1109
ret = set->type->create(info->net, set, tb, flags);
net/netfilter/ipset/ip_set_core.c
1230
struct ip_set_net *inst = ip_set_pernet(info->net);
net/netfilter/ipset/ip_set_core.c
1309
struct ip_set_net *inst = ip_set_pernet(info->net);
net/netfilter/ipset/ip_set_core.c
1347
struct ip_set_net *inst = ip_set_pernet(info->net);
net/netfilter/ipset/ip_set_core.c
1395
struct ip_set_net *inst = ip_set_pernet(info->net);
net/netfilter/ipset/ip_set_core.c
1740
call_ad(struct net *net, struct sock *ctnl, struct sk_buff *skb,
net/netfilter/ipset/ip_set_core.c
1804
nfnetlink_unicast(skb2, net, NETLINK_CB(skb).portid);
net/netfilter/ipset/ip_set_core.c
1812
static int ip_set_ad(struct net *net, struct sock *ctnl,
net/netfilter/ipset/ip_set_core.c
1819
struct ip_set_net *inst = ip_set_pernet(net);
net/netfilter/ipset/ip_set_core.c
1848
ret = call_ad(net, ctnl, skb, set, tb, adt, flags,
net/netfilter/ipset/ip_set_core.c
1859
ret = call_ad(net, ctnl, skb, set, tb, adt,
net/netfilter/ipset/ip_set_core.c
1871
return ip_set_ad(info->net, info->sk, skb,
net/netfilter/ipset/ip_set_core.c
1878
return ip_set_ad(info->net, info->sk, skb,
net/netfilter/ipset/ip_set_core.c
1885
struct ip_set_net *inst = ip_set_pernet(info->net);
net/netfilter/ipset/ip_set_core.c
1920
struct ip_set_net *inst = ip_set_pernet(info->net);
net/netfilter/ipset/ip_set_core.c
1949
return nfnetlink_unicast(skb2, info->net, NETLINK_CB(skb).portid);
net/netfilter/ipset/ip_set_core.c
2004
return nfnetlink_unicast(skb2, info->net, NETLINK_CB(skb).portid);
net/netfilter/ipset/ip_set_core.c
2043
return nfnetlink_unicast(skb2, info->net, NETLINK_CB(skb).portid);
net/netfilter/ipset/ip_set_core.c
2057
struct ip_set_net *inst = ip_set_pernet(info->net);
net/netfilter/ipset/ip_set_core.c
2085
return nfnetlink_unicast(skb2, info->net, NETLINK_CB(skb).portid);
net/netfilter/ipset/ip_set_core.c
2102
struct ip_set_net *inst = ip_set_pernet(info->net);
net/netfilter/ipset/ip_set_core.c
2132
return nfnetlink_unicast(skb2, info->net, NETLINK_CB(skb).portid);
net/netfilter/ipset/ip_set_core.c
2254
struct net *net = sock_net(sk);
net/netfilter/ipset/ip_set_core.c
2255
struct ip_set_net *inst = ip_set_pernet(net);
net/netfilter/ipset/ip_set_core.c
2257
if (!ns_capable(net->user_ns, CAP_NET_ADMIN))
net/netfilter/ipset/ip_set_core.c
2378
ip_set_net_init(struct net *net)
net/netfilter/ipset/ip_set_core.c
2380
struct ip_set_net *inst = ip_set_pernet(net);
net/netfilter/ipset/ip_set_core.c
2397
ip_set_net_pre_exit(struct net *net)
net/netfilter/ipset/ip_set_core.c
2399
struct ip_set_net *inst = ip_set_pernet(net);
net/netfilter/ipset/ip_set_core.c
2405
ip_set_net_exit(struct net *net)
net/netfilter/ipset/ip_set_core.c
2407
struct ip_set_net *inst = ip_set_pernet(net);
net/netfilter/ipset/ip_set_core.c
38
static struct ip_set_net *ip_set_pernet(struct net *net)
net/netfilter/ipset/ip_set_core.c
40
return net_generic(net, ip_set_net_id);
net/netfilter/ipset/ip_set_core.c
717
ip_set_rcu_get(struct net *net, ip_set_id_t index)
net/netfilter/ipset/ip_set_core.c
719
struct ip_set_net *inst = ip_set_pernet(net);
net/netfilter/ipset/ip_set_core.c
824
ip_set_get_byname(struct net *net, const struct nlattr *name, struct ip_set **set)
net/netfilter/ipset/ip_set_core.c
828
struct ip_set_net *inst = ip_set_pernet(net);
net/netfilter/ipset/ip_set_core.c
865
ip_set_put_byindex(struct net *net, ip_set_id_t index)
net/netfilter/ipset/ip_set_core.c
867
struct ip_set_net *inst = ip_set_pernet(net);
net/netfilter/ipset/ip_set_core.c
879
ip_set_name_byindex(struct net *net, ip_set_id_t index, char *name)
net/netfilter/ipset/ip_set_core.c
881
struct ip_set *set = ip_set_rcu_get(net, index);
net/netfilter/ipset/ip_set_core.c
901
ip_set_nfnl_get_byindex(struct net *net, ip_set_id_t index)
net/netfilter/ipset/ip_set_core.c
904
struct ip_set_net *inst = ip_set_pernet(net);
net/netfilter/ipset/ip_set_core.c
928
ip_set_nfnl_put(struct net *net, ip_set_id_t index)
net/netfilter/ipset/ip_set_core.c
931
struct ip_set_net *inst = ip_set_pernet(net);
net/netfilter/ipset/ip_set_hash_gen.h
1495
IPSET_TOKEN(HTYPE, _create)(struct net *net, struct ip_set *set,
net/netfilter/ipset/ip_set_hash_netiface.c
141
static const char *get_physindev_name(const struct sk_buff *skb, struct net *net)
net/netfilter/ipset/ip_set_hash_netiface.c
143
struct net_device *dev = nf_bridge_get_physindev(skb, net);
net/netfilter/ipset/ip_set_list_set.c
159
ip_set_put_byindex(map->net, e->id);
net/netfilter/ipset/ip_set_list_set.c
169
ip_set_put_byindex(map->net, old->id);
net/netfilter/ipset/ip_set_list_set.c
274
ip_set_put_byindex(map->net, d->id);
net/netfilter/ipset/ip_set_list_set.c
370
e.id = ip_set_get_byname(map->net, tb[IPSET_ATTR_NAME], &s);
net/netfilter/ipset/ip_set_list_set.c
391
e.refid = ip_set_get_byname(map->net,
net/netfilter/ipset/ip_set_list_set.c
408
ip_set_put_byindex(map->net, e.refid);
net/netfilter/ipset/ip_set_list_set.c
410
ip_set_put_byindex(map->net, e.id);
net/netfilter/ipset/ip_set_list_set.c
44
struct net *net; /* namespace */
net/netfilter/ipset/ip_set_list_set.c
503
ip_set_name_byindex(map->net, e->id, name);
net/netfilter/ipset/ip_set_list_set.c
597
init_list_set(struct net *net, struct ip_set *set, u32 size)
net/netfilter/ipset/ip_set_list_set.c
606
map->net = net;
net/netfilter/ipset/ip_set_list_set.c
617
list_set_create(struct net *net, struct ip_set *set, struct nlattr *tb[],
net/netfilter/ipset/ip_set_list_set.c
636
if (!init_list_set(net, set, size))
net/netfilter/ipvs/ip_vs_app.c
532
struct net *net = seq_file_net(seq);
net/netfilter/ipvs/ip_vs_app.c
533
struct netns_ipvs *ipvs = net_ipvs(net);
net/netfilter/ipvs/ip_vs_app.c
544
struct net *net = seq_file_net(seq);
net/netfilter/ipvs/ip_vs_app.c
545
struct netns_ipvs *ipvs = net_ipvs(net);
net/netfilter/ipvs/ip_vs_app.c
600
if (!proc_create_net("ip_vs_app", 0, ipvs->net->proc_net,
net/netfilter/ipvs/ip_vs_app.c
612
remove_proc_entry("ip_vs_app", ipvs->net->proc_net);
net/netfilter/ipvs/ip_vs_conn.c
1484
struct net *net = seq_file_net(seq);
net/netfilter/ipvs/ip_vs_conn.c
1485
struct netns_ipvs *ipvs = net_ipvs(net);
net/netfilter/ipvs/ip_vs_conn.c
1529
struct net *net = seq_file_net(seq);
net/netfilter/ipvs/ip_vs_conn.c
1530
struct netns_ipvs *ipvs = net_ipvs(net);
net/netfilter/ipvs/ip_vs_conn.c
1984
if (!proc_create_net("ip_vs_conn", 0, ipvs->net->proc_net,
net/netfilter/ipvs/ip_vs_conn.c
1989
if (!proc_create_net("ip_vs_conn_sync", 0, ipvs->net->proc_net,
net/netfilter/ipvs/ip_vs_conn.c
1999
remove_proc_entry("ip_vs_conn", ipvs->net->proc_net);
net/netfilter/ipvs/ip_vs_conn.c
2010
remove_proc_entry("ip_vs_conn", ipvs->net->proc_net);
net/netfilter/ipvs/ip_vs_conn.c
2011
remove_proc_entry("ip_vs_conn_sync", ipvs->net->proc_net);
net/netfilter/ipvs/ip_vs_conn.c
760
if (net_eq(ipvs->net, &init_net))
net/netfilter/ipvs/ip_vs_core.c
1508
struct netns_ipvs *ipvs = net_ipvs(state->net);
net/netfilter/ipvs/ip_vs_core.c
1622
skb->dev = ipvs->net->loopback_dev;
net/netfilter/ipvs/ip_vs_core.c
1932
ipv4_update_pmtu(skb, ipvs->net, mtu, 0, 0);
net/netfilter/ipvs/ip_vs_core.c
2096
struct netns_ipvs *ipvs = net_ipvs(state->net);
net/netfilter/ipvs/ip_vs_core.c
2290
struct netns_ipvs *ipvs = net_ipvs(state->net);
net/netfilter/ipvs/ip_vs_core.c
2436
ret = nf_register_net_hooks(ipvs->net, ops, count);
net/netfilter/ipvs/ip_vs_core.c
2464
nf_unregister_net_hooks(ipvs->net, ops, count);
net/netfilter/ipvs/ip_vs_core.c
2472
static int __net_init __ip_vs_init(struct net *net)
net/netfilter/ipvs/ip_vs_core.c
2476
ipvs = net_generic(net, ip_vs_net_id);
net/netfilter/ipvs/ip_vs_core.c
2482
ipvs->net = net;
net/netfilter/ipvs/ip_vs_core.c
2486
net->ipvs = ipvs;
net/netfilter/ipvs/ip_vs_core.c
2522
net->ipvs = NULL;
net/netfilter/ipvs/ip_vs_core.c
2529
struct net *net;
net/netfilter/ipvs/ip_vs_core.c
2532
list_for_each_entry(net, net_list, exit_list) {
net/netfilter/ipvs/ip_vs_core.c
2533
ipvs = net_ipvs(net);
net/netfilter/ipvs/ip_vs_core.c
2540
net->ipvs = NULL;
net/netfilter/ipvs/ip_vs_core.c
2547
struct net *net;
net/netfilter/ipvs/ip_vs_core.c
2549
list_for_each_entry(net, net_list, exit_list) {
net/netfilter/ipvs/ip_vs_core.c
2550
ipvs = net_ipvs(net);
net/netfilter/ipvs/ip_vs_core.c
748
static inline int ip_vs_addr_is_unicast(struct net *net, int af,
net/netfilter/ipvs/ip_vs_core.c
755
return (inet_addr_type(net, addr->ip) == RTN_UNICAST);
net/netfilter/ipvs/ip_vs_core.c
768
struct net *net = ipvs->net;
net/netfilter/ipvs/ip_vs_core.c
780
ip_vs_addr_is_unicast(net, svc->af, &iph->daddr)) {
net/netfilter/ipvs/ip_vs_core.c
842
skb->dev = net->loopback_dev;
net/netfilter/ipvs/ip_vs_core.c
890
err = ip_defrag(ipvs->net, skb, user);
net/netfilter/ipvs/ip_vs_core.c
911
ip6_route_me_harder(ipvs->net, skb->sk, skb) != 0)
net/netfilter/ipvs/ip_vs_core.c
916
ip_route_me_harder(ipvs->net, skb->sk, skb, RTN_LOCAL) != 0)
net/netfilter/ipvs/ip_vs_ctl.c
1413
!__ip_vs_addr_is_local_v6(svc->ipvs->net, &udest->addr.in6))
net/netfilter/ipvs/ip_vs_ctl.c
1416
ret = nf_defrag_ipv6_enable(svc->ipvs->net);
net/netfilter/ipvs/ip_vs_ctl.c
1422
atype = inet_addr_type(svc->ipvs->net, udest->addr.ip);
net/netfilter/ipvs/ip_vs_ctl.c
1756
ret = nf_defrag_ipv6_enable(ipvs->net);
net/netfilter/ipvs/ip_vs_ctl.c
2189
struct net *net;
net/netfilter/ipvs/ip_vs_ctl.c
2192
list_for_each_entry(net, net_list, exit_list) {
net/netfilter/ipvs/ip_vs_ctl.c
2193
ipvs = net_ipvs(net);
net/netfilter/ipvs/ip_vs_ctl.c
2226
struct net *net = dev_net(dev);
net/netfilter/ipvs/ip_vs_ctl.c
2227
struct netns_ipvs *ipvs = net_ipvs(net);
net/netfilter/ipvs/ip_vs_ctl.c
2924
struct net *net = seq_file_net(seq);
net/netfilter/ipvs/ip_vs_ctl.c
2925
struct netns_ipvs *ipvs = net_ipvs(net);
net/netfilter/ipvs/ip_vs_ctl.c
2977
struct net *net = seq_file_net(seq);
net/netfilter/ipvs/ip_vs_ctl.c
2978
struct netns_ipvs *ipvs = net_ipvs(net);
net/netfilter/ipvs/ip_vs_ctl.c
3061
struct net *net = seq_file_single_net(seq);
net/netfilter/ipvs/ip_vs_ctl.c
3070
ip_vs_copy_stats(&show, &net_ipvs(net)->tot_stats->s);
net/netfilter/ipvs/ip_vs_ctl.c
3093
struct net *net = seq_file_single_net(seq);
net/netfilter/ipvs/ip_vs_ctl.c
3094
struct ip_vs_stats *tot_stats = &net_ipvs(net)->tot_stats->s;
net/netfilter/ipvs/ip_vs_ctl.c
3149
struct net *net = seq_file_single_net(seq);
net/netfilter/ipvs/ip_vs_ctl.c
3150
struct netns_ipvs *ipvs = net_ipvs(net);
net/netfilter/ipvs/ip_vs_ctl.c
3425
struct net *net = sock_net(sk);
net/netfilter/ipvs/ip_vs_ctl.c
3433
struct netns_ipvs *ipvs = net_ipvs(net);
net/netfilter/ipvs/ip_vs_ctl.c
3738
struct net *net = sock_net(sk);
net/netfilter/ipvs/ip_vs_ctl.c
3739
struct netns_ipvs *ipvs = net_ipvs(net);
net/netfilter/ipvs/ip_vs_ctl.c
3741
BUG_ON(!net);
net/netfilter/ipvs/ip_vs_ctl.c
4127
struct net *net = sock_net(skb->sk);
net/netfilter/ipvs/ip_vs_ctl.c
4128
struct netns_ipvs *ipvs = net_ipvs(net);
net/netfilter/ipvs/ip_vs_ctl.c
4335
struct net *net = sock_net(skb->sk);
net/netfilter/ipvs/ip_vs_ctl.c
4336
struct netns_ipvs *ipvs = net_ipvs(net);
net/netfilter/ipvs/ip_vs_ctl.c
4491
struct net *net = sock_net(skb->sk);
net/netfilter/ipvs/ip_vs_ctl.c
4492
struct netns_ipvs *ipvs = net_ipvs(net);
net/netfilter/ipvs/ip_vs_ctl.c
4612
struct net *net = sock_net(skb->sk);
net/netfilter/ipvs/ip_vs_ctl.c
4613
struct netns_ipvs *ipvs = net_ipvs(net);
net/netfilter/ipvs/ip_vs_ctl.c
4641
struct net *net = sock_net(skb->sk);
net/netfilter/ipvs/ip_vs_ctl.c
4642
struct netns_ipvs *ipvs = net_ipvs(net);
net/netfilter/ipvs/ip_vs_ctl.c
4771
struct net *net = sock_net(skb->sk);
net/netfilter/ipvs/ip_vs_ctl.c
4772
struct netns_ipvs *ipvs = net_ipvs(net);
net/netfilter/ipvs/ip_vs_ctl.c
4997
struct net *net = ipvs->net;
net/netfilter/ipvs/ip_vs_ctl.c
5001
bool unpriv = net->user_ns != &init_user_ns;
net/netfilter/ipvs/ip_vs_ctl.c
5012
if (!net_eq(net, &init_net)) {
net/netfilter/ipvs/ip_vs_ctl.c
5030
ipvs->conn_max_limit = net_eq(net, &init_net) ? IP_VS_CONN_MAX :
net/netfilter/ipvs/ip_vs_ctl.c
5113
if (!net_eq(net, &init_net))
net/netfilter/ipvs/ip_vs_ctl.c
5118
ipvs->sysctl_hdr = register_net_sysctl_sz(net, "net/ipv4/vs", tbl,
net/netfilter/ipvs/ip_vs_ctl.c
5136
if (!net_eq(net, &init_net))
net/netfilter/ipvs/ip_vs_ctl.c
5143
struct net *net = ipvs->net;
net/netfilter/ipvs/ip_vs_ctl.c
5161
if (!net_eq(net, &init_net))
net/netfilter/ipvs/ip_vs_ctl.c
5219
if (!proc_create_net("ip_vs", 0, ipvs->net->proc_net,
net/netfilter/ipvs/ip_vs_ctl.c
5222
if (!proc_create_net_single("ip_vs_stats", 0, ipvs->net->proc_net,
net/netfilter/ipvs/ip_vs_ctl.c
5226
ipvs->net->proc_net,
net/netfilter/ipvs/ip_vs_ctl.c
5229
if (!proc_create_net_single("ip_vs_status", 0440, ipvs->net->proc_net,
net/netfilter/ipvs/ip_vs_ctl.c
5242
remove_proc_entry("ip_vs_status", ipvs->net->proc_net);
net/netfilter/ipvs/ip_vs_ctl.c
5245
remove_proc_entry("ip_vs_stats_percpu", ipvs->net->proc_net);
net/netfilter/ipvs/ip_vs_ctl.c
5248
remove_proc_entry("ip_vs_stats", ipvs->net->proc_net);
net/netfilter/ipvs/ip_vs_ctl.c
5251
remove_proc_entry("ip_vs", ipvs->net->proc_net);
net/netfilter/ipvs/ip_vs_ctl.c
5270
remove_proc_entry("ip_vs_status", ipvs->net->proc_net);
net/netfilter/ipvs/ip_vs_ctl.c
5271
remove_proc_entry("ip_vs_stats_percpu", ipvs->net->proc_net);
net/netfilter/ipvs/ip_vs_ctl.c
5272
remove_proc_entry("ip_vs_stats", ipvs->net->proc_net);
net/netfilter/ipvs/ip_vs_ctl.c
5273
remove_proc_entry("ip_vs", ipvs->net->proc_net);
net/netfilter/ipvs/ip_vs_ctl.c
590
(vport == FTPDATA || !inet_port_requires_bind_service(ipvs->net, ntohs(vport)))) {
net/netfilter/ipvs/ip_vs_ctl.c
631
if (net_eq(ipvs->net, &init_net))
net/netfilter/ipvs/ip_vs_ctl.c
72
static bool __ip_vs_addr_is_local_v6(struct net *net,
net/netfilter/ipvs/ip_vs_ctl.c
78
struct dst_entry *dst = ip6_route_output(net, NULL, &fl6);
net/netfilter/ipvs/ip_vs_ftp.c
575
static int __net_init __ip_vs_ftp_init(struct net *net)
net/netfilter/ipvs/ip_vs_ftp.c
579
struct netns_ipvs *ipvs = net_ipvs(net);
net/netfilter/ipvs/ip_vs_ftp.c
604
static void __ip_vs_ftp_exit(struct net *net)
net/netfilter/ipvs/ip_vs_ftp.c
606
struct netns_ipvs *ipvs = net_ipvs(net);
net/netfilter/ipvs/ip_vs_lblc.c
549
static int __net_init __ip_vs_lblc_init(struct net *net)
net/netfilter/ipvs/ip_vs_lblc.c
551
struct netns_ipvs *ipvs = net_ipvs(net);
net/netfilter/ipvs/ip_vs_lblc.c
557
if (!net_eq(net, &init_net)) {
net/netfilter/ipvs/ip_vs_lblc.c
565
if (net->user_ns != &init_user_ns)
net/netfilter/ipvs/ip_vs_lblc.c
573
ipvs->lblc_ctl_header = register_net_sysctl_sz(net, "net/ipv4/vs",
net/netfilter/ipvs/ip_vs_lblc.c
577
if (!net_eq(net, &init_net))
net/netfilter/ipvs/ip_vs_lblc.c
585
static void __net_exit __ip_vs_lblc_exit(struct net *net)
net/netfilter/ipvs/ip_vs_lblc.c
587
struct netns_ipvs *ipvs = net_ipvs(net);
net/netfilter/ipvs/ip_vs_lblc.c
591
if (!net_eq(net, &init_net))
net/netfilter/ipvs/ip_vs_lblc.c
597
static int __net_init __ip_vs_lblc_init(struct net *net) { return 0; }
net/netfilter/ipvs/ip_vs_lblc.c
598
static void __net_exit __ip_vs_lblc_exit(struct net *net) { }
net/netfilter/ipvs/ip_vs_lblcr.c
735
static int __net_init __ip_vs_lblcr_init(struct net *net)
net/netfilter/ipvs/ip_vs_lblcr.c
737
struct netns_ipvs *ipvs = net_ipvs(net);
net/netfilter/ipvs/ip_vs_lblcr.c
743
if (!net_eq(net, &init_net)) {
net/netfilter/ipvs/ip_vs_lblcr.c
751
if (net->user_ns != &init_user_ns)
net/netfilter/ipvs/ip_vs_lblcr.c
758
ipvs->lblcr_ctl_header = register_net_sysctl_sz(net, "net/ipv4/vs",
net/netfilter/ipvs/ip_vs_lblcr.c
762
if (!net_eq(net, &init_net))
net/netfilter/ipvs/ip_vs_lblcr.c
770
static void __net_exit __ip_vs_lblcr_exit(struct net *net)
net/netfilter/ipvs/ip_vs_lblcr.c
772
struct netns_ipvs *ipvs = net_ipvs(net);
net/netfilter/ipvs/ip_vs_lblcr.c
776
if (!net_eq(net, &init_net))
net/netfilter/ipvs/ip_vs_lblcr.c
782
static int __net_init __ip_vs_lblcr_init(struct net *net) { return 0; }
net/netfilter/ipvs/ip_vs_lblcr.c
783
static void __net_exit __ip_vs_lblcr_exit(struct net *net) { }
net/netfilter/ipvs/ip_vs_nfct.c
145
struct net *net = nf_ct_net(ct);
net/netfilter/ipvs/ip_vs_nfct.c
157
ip_vs_conn_fill_param(net_ipvs(net), exp->tuple.src.l3num, orig->dst.protonum,
net/netfilter/ipvs/ip_vs_nfct.c
261
h = nf_conntrack_find_get(cp->ipvs->net, &nf_ct_zone_dflt, &tuple);
net/netfilter/ipvs/ip_vs_sync.c
1472
result = sock_create_kern(ipvs->net, ipvs->mcfg.mcast_af, SOCK_DGRAM,
net/netfilter/ipvs/ip_vs_sync.c
1529
result = sock_create_kern(ipvs->net, ipvs->bcfg.mcast_af, SOCK_DGRAM,
net/netfilter/ipvs/ip_vs_sync.c
1807
dev = __dev_get_by_name(ipvs->net, c->mcast_ifn);
net/netfilter/ipvs/ip_vs_xmit.c
1036
ipvs_gue_encap(struct net *net, struct sk_buff *skb,
net/netfilter/ipvs/ip_vs_xmit.c
1040
__be16 sport = udp_flow_src_port(net, skb, 0, 0, false);
net/netfilter/ipvs/ip_vs_xmit.c
1110
ipvs_gre_encap(struct net *net, struct sk_buff *skb,
net/netfilter/ipvs/ip_vs_xmit.c
1151
struct net *net = ipvs->net;
net/netfilter/ipvs/ip_vs_xmit.c
1245
if (ipvs_gue_encap(net, skb, cp, &next_protocol))
net/netfilter/ipvs/ip_vs_xmit.c
1254
ipvs_gre_encap(net, skb, cp, &next_protocol);
net/netfilter/ipvs/ip_vs_xmit.c
1272
ip_select_ident(net, skb, NULL);
net/netfilter/ipvs/ip_vs_xmit.c
1279
ip_local_out(net, skb->sk, skb);
net/netfilter/ipvs/ip_vs_xmit.c
1296
struct net *net = ipvs->net;
net/netfilter/ipvs/ip_vs_xmit.c
133
static struct rtable *do_output_route4(struct net *net, __be32 daddr,
net/netfilter/ipvs/ip_vs_xmit.c
1388
if (ipvs_gue_encap(net, skb, cp, &next_protocol))
net/netfilter/ipvs/ip_vs_xmit.c
1397
ipvs_gre_encap(net, skb, cp, &next_protocol);
net/netfilter/ipvs/ip_vs_xmit.c
1421
ip6_local_out(net, skb->sk, skb);
net/netfilter/ipvs/ip_vs_xmit.c
145
rt = ip_route_output_key(net, &fl4);
net/netfilter/ipvs/ip_vs_xmit.c
224
struct net *net = ipvs->net;
net/netfilter/ipvs/ip_vs_xmit.c
228
skb->dev = net->loopback_dev;
net/netfilter/ipvs/ip_vs_xmit.c
263
struct net *net = ipvs->net;
net/netfilter/ipvs/ip_vs_xmit.c
277
IP6_INC_STATS(net, idev, IPSTATS_MIB_INHDRERRORS);
net/netfilter/ipvs/ip_vs_xmit.c
292
IP_INC_STATS(net, IPSTATS_MIB_INHDRERRORS);
net/netfilter/ipvs/ip_vs_xmit.c
321
struct net *net = ipvs->net;
net/netfilter/ipvs/ip_vs_xmit.c
341
rt = do_output_route4(net, dest->addr.ip, rt_mode,
net/netfilter/ipvs/ip_vs_xmit.c
374
rt = do_output_route4(net, daddr, rt_mode, ret_saddr);
net/netfilter/ipvs/ip_vs_xmit.c
449
__ip_vs_route_output_v6(struct net *net, struct in6_addr *daddr,
net/netfilter/ipvs/ip_vs_xmit.c
460
dst = ip6_route_output(net, NULL, &fl6);
net/netfilter/ipvs/ip_vs_xmit.c
466
ipv6_dev_get_saddr(net, ip6_dst_idev(dst)->dev,
net/netfilter/ipvs/ip_vs_xmit.c
470
dst = xfrm_lookup(net, dst, flowi6_to_flowi(&fl6), NULL, 0);
net/netfilter/ipvs/ip_vs_xmit.c
494
struct net *net = ipvs->net;
net/netfilter/ipvs/ip_vs_xmit.c
517
dst = __ip_vs_route_output_v6(net, &dest->addr.in6,
net/netfilter/ipvs/ip_vs_xmit.c
548
dst = __ip_vs_route_output_v6(net, daddr, ret_saddr, do_xfrm,
net/netfilter/ipvs/ip_vs_xmit.c
688
NF_HOOK(pf, NF_INET_LOCAL_OUT, cp->ipvs->net, NULL, skb,
net/netfilter/ipvs/ip_vs_xmit.c
710
NF_HOOK(pf, NF_INET_LOCAL_OUT, cp->ipvs->net, NULL, skb,
net/netfilter/nf_bpf_link.c
109
hook->disable(link->net);
net/netfilter/nf_bpf_link.c
122
nf_unregister_net_hook(nf_link->net, &nf_link->hook_ops);
net/netfilter/nf_bpf_link.c
124
put_net_track(nf_link->net, &nf_link->ns_tracker);
net/netfilter/nf_bpf_link.c
212
struct net *net = current->nsproxy->net_ns;
net/netfilter/nf_bpf_link.c
239
link->net = net;
net/netfilter/nf_bpf_link.c
257
err = nf_register_net_hook(net, &link->hook_ops);
net/netfilter/nf_bpf_link.c
264
get_net_track(net, &link->ns_tracker, GFP_KERNEL);
net/netfilter/nf_bpf_link.c
27
struct net *net;
net/netfilter/nf_bpf_link.c
64
err = hook->enable(link->net);
net/netfilter/nf_conncount.c
102
find_or_evict(struct net *net, struct nf_conncount_list *list,
net/netfilter/nf_conncount.c
110
found = nf_conntrack_find_get(net, &conn->zone, &conn->tuple);
net/netfilter/nf_conncount.c
130
static bool get_ct_or_tuple_from_skb(struct net *net,
net/netfilter/nf_conncount.c
150
if (!nf_ct_get_tuplepr(skb, skb_network_offset(skb), l3num, net, tuple))
net/netfilter/nf_conncount.c
156
h = nf_conntrack_find_get(net, *zone, tuple);
net/netfilter/nf_conncount.c
167
static int __nf_conncount_add(struct net *net,
net/netfilter/nf_conncount.c
182
if (!get_ct_or_tuple_from_skb(net, skb, l3num, &ct, &tuple, &zone, &refcounted))
net/netfilter/nf_conncount.c
209
found = find_or_evict(net, list, conn);
net/netfilter/nf_conncount.c
276
int nf_conncount_add_skb(struct net *net,
net/netfilter/nf_conncount.c
285
ret = __nf_conncount_add(net, skb, l3num, list);
net/netfilter/nf_conncount.c
303
static bool __nf_conncount_gc_list(struct net *net,
net/netfilter/nf_conncount.c
317
found = find_or_evict(net, list, conn);
net/netfilter/nf_conncount.c
349
bool nf_conncount_gc_list(struct net *net,
net/netfilter/nf_conncount.c
358
ret = __nf_conncount_gc_list(net, list);
net/netfilter/nf_conncount.c
401
insert_tree(struct net *net,
net/netfilter/nf_conncount.c
436
ret = nf_conncount_add_skb(net, skb, l3num, &rbconn->list);
net/netfilter/nf_conncount.c
448
if (do_gc && nf_conncount_gc_list(net, &rbconn->list))
net/netfilter/nf_conncount.c
460
if (get_ct_or_tuple_from_skb(net, skb, l3num, &ct, &tuple, &zone, &refcounted)) {
net/netfilter/nf_conncount.c
531
count_tree(struct net *net,
net/netfilter/nf_conncount.c
557
return insert_tree(net, skb, l3num, data, hash, key);
net/netfilter/nf_conncount.c
567
nf_conncount_gc_list(net, &rbconn->list);
net/netfilter/nf_conncount.c
577
return insert_tree(net, skb, l3num, data, hash, key);
net/netfilter/nf_conncount.c
581
ret = __nf_conncount_add(net, skb, l3num, &rbconn->list);
net/netfilter/nf_conncount.c
588
nf_conncount_gc_list(net, &rbconn->list);
net/netfilter/nf_conncount.c
617
if (nf_conncount_gc_list(data->net, &rbconn->list))
net/netfilter/nf_conncount.c
664
unsigned int nf_conncount_count_skb(struct net *net,
net/netfilter/nf_conncount.c
67
struct net *net;
net/netfilter/nf_conncount.c
670
return count_tree(net, skb, l3num, data, key);
net/netfilter/nf_conncount.c
682
struct nf_conncount_data *nf_conncount_init(struct net *net, unsigned int keylen)
net/netfilter/nf_conncount.c
700
data->net = net;
net/netfilter/nf_conncount.c
733
void nf_conncount_destroy(struct net *net, struct nf_conncount_data *data)
net/netfilter/nf_conntrack_acct.c
25
void nf_conntrack_acct_pernet_init(struct net *net)
net/netfilter/nf_conntrack_acct.c
27
net->ct.sysctl_acct = nf_ct_acct;
net/netfilter/nf_conntrack_bpf.c
118
__bpf_nf_ct_alloc_entry(struct net *net, struct bpf_sock_tuple *bpf_tuple,
net/netfilter/nf_conntrack_bpf.c
151
net = get_net_ns_by_id(net, opts->netns_id);
net/netfilter/nf_conntrack_bpf.c
152
if (unlikely(!net))
net/netfilter/nf_conntrack_bpf.c
165
ct = nf_conntrack_alloc(net, &ct_zone, &otuple, &rtuple,
net/netfilter/nf_conntrack_bpf.c
175
put_net(net);
net/netfilter/nf_conntrack_bpf.c
180
static struct nf_conn *__bpf_nf_ct_lookup(struct net *net,
net/netfilter/nf_conntrack_bpf.c
213
net = get_net_ns_by_id(net, opts->netns_id);
net/netfilter/nf_conntrack_bpf.c
214
if (unlikely(!net))
net/netfilter/nf_conntrack_bpf.c
227
hash = nf_conntrack_find_get(net, &ct_zone, &tuple);
net/netfilter/nf_conntrack_bpf.c
229
put_net(net);
net/netfilter/nf_conntrack_bpf.c
333
struct net *caller_net;
net/netfilter/nf_conntrack_bpf.c
362
struct net *net;
net/netfilter/nf_conntrack_bpf.c
364
net = skb->dev ? dev_net(skb->dev) : sock_net(skb->sk);
net/netfilter/nf_conntrack_bpf.c
365
nfct = __bpf_nf_ct_alloc_entry(net, bpf_tuple, tuple__sz, opts, opts__sz, 10);
net/netfilter/nf_conntrack_bpf.c
390
struct net *caller_net;
net/netfilter/nf_conntrack_broadcast.c
24
struct net *net = read_pnet(&ct->ct_net);
net/netfilter/nf_conntrack_broadcast.c
80
write_pnet(&exp->net, net);
net/netfilter/nf_conntrack_core.c
1029
struct net *net = nf_ct_net(ct);
net/netfilter/nf_conntrack_core.c
1037
NF_CT_STAT_INC(net, clash_resolve);
net/netfilter/nf_conntrack_core.c
1065
struct net *net;
net/netfilter/nf_conntrack_core.c
1068
net = nf_ct_net(loser_ct);
net/netfilter/nf_conntrack_core.c
1076
zone, net))
net/netfilter/nf_conntrack_core.c
1107
NF_CT_STAT_INC(net, clash_resolve);
net/netfilter/nf_conntrack_core.c
1153
struct net *net;
net/netfilter/nf_conntrack_core.c
1157
net = nf_ct_net(loser_ct);
net/netfilter/nf_conntrack_core.c
1172
NF_CT_STAT_INC(net, drop);
net/netfilter/nf_conntrack_core.c
1173
NF_CT_STAT_INC(net, insert_failed);
net/netfilter/nf_conntrack_core.c
1189
struct net *net;
net/netfilter/nf_conntrack_core.c
1193
net = nf_ct_net(ct);
net/netfilter/nf_conntrack_core.c
1210
reply_hash = hash_conntrack(net,
net/netfilter/nf_conntrack_core.c
1238
NF_CT_STAT_INC(net, insert_failed);
net/netfilter/nf_conntrack_core.c
1248
zone, net))
net/netfilter/nf_conntrack_core.c
1257
zone, net))
net/netfilter/nf_conntrack_core.c
1261
NF_CT_STAT_INC(net, chaintoolong);
net/netfilter/nf_conntrack_core.c
1262
NF_CT_STAT_INC(net, insert_failed);
net/netfilter/nf_conntrack_core.c
1317
struct net *net = nf_ct_net(ignored_conntrack);
net/netfilter/nf_conntrack_core.c
1330
hash = __hash_conntrack(net, tuple, nf_ct_zone_id(zone, IP_CT_DIR_REPLY), hsize);
net/netfilter/nf_conntrack_core.c
1343
if (nf_ct_key_equal(h, tuple, zone, net)) {
net/netfilter/nf_conntrack_core.c
1361
NF_CT_STAT_INC_ATOMIC(net, found);
net/netfilter/nf_conntrack_core.c
1368
NF_CT_STAT_INC_ATOMIC(net, search_restart);
net/netfilter/nf_conntrack_core.c
1382
static unsigned int early_drop_list(struct net *net,
net/netfilter/nf_conntrack_core.c
1399
!net_eq(nf_ct_net(tmp), net) ||
net/netfilter/nf_conntrack_core.c
1416
if (net_eq(nf_ct_net(tmp), net) &&
net/netfilter/nf_conntrack_core.c
1427
static noinline int early_drop(struct net *net, unsigned int hash)
net/netfilter/nf_conntrack_core.c
1442
drops = early_drop_list(net, &ct_hash[bucket]);
net/netfilter/nf_conntrack_core.c
1446
NF_CT_STAT_ADD_ATOMIC(net, early_drop, drops);
net/netfilter/nf_conntrack_core.c
1542
struct net *net;
net/netfilter/nf_conntrack_core.c
1580
net = nf_ct_net(tmp);
net/netfilter/nf_conntrack_core.c
1581
cnet = nf_ct_pernet(net);
net/netfilter/nf_conntrack_core.c
1650
__nf_conntrack_alloc(struct net *net,
net/netfilter/nf_conntrack_core.c
1656
struct nf_conntrack_net *cnet = nf_ct_pernet(net);
net/netfilter/nf_conntrack_core.c
1664
if (!early_drop(net, hash)) {
net/netfilter/nf_conntrack_core.c
1668
if (net == &init_net)
net/netfilter/nf_conntrack_core.c
1672
net->ns.inum);
net/netfilter/nf_conntrack_core.c
1693
write_pnet(&ct->ct_net, net);
net/netfilter/nf_conntrack_core.c
1708
struct nf_conn *nf_conntrack_alloc(struct net *net,
net/netfilter/nf_conntrack_core.c
1714
return __nf_conntrack_alloc(net, zone, orig, repl, gfp, 0);
net/netfilter/nf_conntrack_core.c
1720
struct net *net = nf_ct_net(ct);
net/netfilter/nf_conntrack_core.c
1743
cnet = nf_ct_pernet(net);
net/netfilter/nf_conntrack_core.c
1754
init_conntrack(struct net *net, struct nf_conn *tmpl,
net/netfilter/nf_conntrack_core.c
1775
ct = __nf_conntrack_alloc(net, zone, tuple, &repl_tuple, GFP_ATOMIC,
net/netfilter/nf_conntrack_core.c
1798
if ((ecache || net->ct.sysctl_events) &&
net/netfilter/nf_conntrack_core.c
1807
cnet = nf_ct_pernet(net);
net/netfilter/nf_conntrack_core.c
1810
exp = nf_ct_find_expectation(net, zone, tuple, !tmpl || nf_ct_is_confirmed(tmpl));
net/netfilter/nf_conntrack_core.c
1831
NF_CT_STAT_INC(net, expect_new);
net/netfilter/nf_conntrack_core.c
1877
dataoff, state->pf, protonum, state->net,
net/netfilter/nf_conntrack_core.c
1885
hash = hash_conntrack_raw(&tuple, zone_id, state->net);
net/netfilter/nf_conntrack_core.c
1886
h = __nf_conntrack_find_get(state->net, zone, &tuple, hash);
net/netfilter/nf_conntrack_core.c
1891
u32 tmp = hash_conntrack_raw(&tuple, rid, state->net);
net/netfilter/nf_conntrack_core.c
1893
h = __nf_conntrack_find_get(state->net, zone, &tuple, tmp);
net/netfilter/nf_conntrack_core.c
1898
h = init_conntrack(state->net, tmpl, &tuple,
net/netfilter/nf_conntrack_core.c
1951
NF_CT_STAT_INC_ATOMIC(state->net, error);
net/netfilter/nf_conntrack_core.c
2023
NF_CT_STAT_INC_ATOMIC(state->net, invalid);
net/netfilter/nf_conntrack_core.c
2044
NF_CT_STAT_INC_ATOMIC(state->net, drop);
net/netfilter/nf_conntrack_core.c
2052
NF_CT_STAT_INC_ATOMIC(state->net, invalid);
net/netfilter/nf_conntrack_core.c
2070
NF_CT_STAT_INC_ATOMIC(state->net, invalid);
net/netfilter/nf_conntrack_core.c
2072
NF_CT_STAT_INC_ATOMIC(state->net, drop);
net/netfilter/nf_conntrack_core.c
212
const struct net *net)
net/netfilter/nf_conntrack_core.c
221
key.key[1] ^= net_hash_mix(net);
net/netfilter/nf_conntrack_core.c
2255
static int nf_conntrack_update(struct net *net, struct sk_buff *skb)
net/netfilter/nf_conntrack_core.c
233
static u32 __hash_conntrack(const struct net *net,
net/netfilter/nf_conntrack_core.c
2337
if (iter_data->net &&
net/netfilter/nf_conntrack_core.c
2338
!net_eq(iter_data->net, nf_ct_net(ct)))
net/netfilter/nf_conntrack_core.c
2379
struct net *net = iter_data->net;
net/netfilter/nf_conntrack_core.c
238
return reciprocal_scale(hash_conntrack_raw(tuple, zoneid, net), size);
net/netfilter/nf_conntrack_core.c
2380
struct nf_conntrack_net *cnet = nf_ct_pernet(net);
net/netfilter/nf_conntrack_core.c
2406
struct net *net;
net/netfilter/nf_conntrack_core.c
2409
for_each_net(net) {
net/netfilter/nf_conntrack_core.c
241
static u32 hash_conntrack(const struct net *net,
net/netfilter/nf_conntrack_core.c
2410
struct nf_conntrack_net *cnet = nf_ct_pernet(net);
net/netfilter/nf_conntrack_core.c
2414
nf_queue_nf_hook_drop(net);
net/netfilter/nf_conntrack_core.c
245
return scale_hash(hash_conntrack_raw(tuple, zoneid, net));
net/netfilter/nf_conntrack_core.c
2472
void nf_conntrack_cleanup_net(struct net *net)
net/netfilter/nf_conntrack_core.c
2476
list_add(&net->exit_list, &single);
net/netfilter/nf_conntrack_core.c
2484
struct net *net;
net/netfilter/nf_conntrack_core.c
2495
list_for_each_entry(net, net_exit_list, exit_list) {
net/netfilter/nf_conntrack_core.c
2496
struct nf_conntrack_net *cnet = nf_ct_pernet(net);
net/netfilter/nf_conntrack_core.c
2498
iter_data.net = net;
net/netfilter/nf_conntrack_core.c
2510
list_for_each_entry(net, net_exit_list, exit_list) {
net/netfilter/nf_conntrack_core.c
2511
warn_on_keymap_list_leak(net);
net/netfilter/nf_conntrack_core.c
2512
nf_conntrack_ecache_pernet_fini(net);
net/netfilter/nf_conntrack_core.c
2513
nf_conntrack_expect_pernet_fini(net);
net/netfilter/nf_conntrack_core.c
2514
free_percpu(net->ct.stat);
net/netfilter/nf_conntrack_core.c
272
struct net *net,
net/netfilter/nf_conntrack_core.c
2738
int nf_conntrack_init_net(struct net *net)
net/netfilter/nf_conntrack_core.c
2740
struct nf_conntrack_net *cnet = nf_ct_pernet(net);
net/netfilter/nf_conntrack_core.c
2747
net->ct.stat = alloc_percpu(struct ip_conntrack_stat);
net/netfilter/nf_conntrack_core.c
2748
if (!net->ct.stat)
net/netfilter/nf_conntrack_core.c
2751
ret = nf_conntrack_expect_pernet_init(net);
net/netfilter/nf_conntrack_core.c
2755
nf_conntrack_acct_pernet_init(net);
net/netfilter/nf_conntrack_core.c
2756
nf_conntrack_tstamp_pernet_init(net);
net/netfilter/nf_conntrack_core.c
2757
nf_conntrack_ecache_pernet_init(net);
net/netfilter/nf_conntrack_core.c
2758
nf_conntrack_proto_pernet_init(net);
net/netfilter/nf_conntrack_core.c
2763
free_percpu(net->ct.stat);
net/netfilter/nf_conntrack_core.c
316
return icmpv6_pkt_to_tuple(skb, dataoff, net, tuple);
net/netfilter/nf_conntrack_core.c
319
return icmp_pkt_to_tuple(skb, dataoff, net, tuple);
net/netfilter/nf_conntrack_core.c
322
return gre_pkt_to_tuple(skb, dataoff, net, tuple);
net/netfilter/nf_conntrack_core.c
415
struct net *net, struct nf_conntrack_tuple *tuple)
net/netfilter/nf_conntrack_core.c
424
return nf_ct_get_tuple(skb, nhoff, protoff, l3num, protonum, net, tuple);
net/netfilter/nf_conntrack_core.c
520
struct nf_conn *nf_ct_tmpl_alloc(struct net *net,
net/netfilter/nf_conntrack_core.c
542
write_pnet(&tmpl->ct_net, net);
net/netfilter/nf_conntrack_core.c
585
static void warn_on_keymap_list_leak(const struct net *net)
net/netfilter/nf_conntrack_core.c
588
WARN_ON_ONCE(!list_empty(&net->ct.nf_ct_proto.gre.keymap_list));
net/netfilter/nf_conntrack_core.c
622
struct net *net = nf_ct_net(ct);
net/netfilter/nf_conntrack_core.c
628
hash = hash_conntrack(net,
net/netfilter/nf_conntrack_core.c
631
reply_hash = hash_conntrack(net,
net/netfilter/nf_conntrack_core.c
665
struct net *net;
net/netfilter/nf_conntrack_core.c
694
net = nf_ct_net(ct);
net/netfilter/nf_conntrack_core.c
695
if (nf_conntrack_ecache_dwork_pending(net))
net/netfilter/nf_conntrack_core.c
696
nf_conntrack_ecache_work(net, NFCT_ECACHE_DESTROY_SENT);
net/netfilter/nf_conntrack_core.c
707
const struct net *net)
net/netfilter/nf_conntrack_core.c
717
net_eq(net, nf_ct_net(ct));
net/netfilter/nf_conntrack_core.c
753
____nf_conntrack_find(struct net *net, const struct nf_conntrack_zone *zone,
net/netfilter/nf_conntrack_core.c
774
if (nf_ct_key_equal(h, tuple, zone, net))
net/netfilter/nf_conntrack_core.c
783
NF_CT_STAT_INC_ATOMIC(net, search_restart);
net/netfilter/nf_conntrack_core.c
792
__nf_conntrack_find_get(struct net *net, const struct nf_conntrack_zone *zone,
net/netfilter/nf_conntrack_core.c
798
h = ____nf_conntrack_find(net, zone, tuple, hash);
net/netfilter/nf_conntrack_core.c
808
if (likely(nf_ct_key_equal(h, tuple, zone, net)))
net/netfilter/nf_conntrack_core.c
822
nf_conntrack_find_get(struct net *net, const struct nf_conntrack_zone *zone,
net/netfilter/nf_conntrack_core.c
830
thash = __nf_conntrack_find_get(net, zone, tuple,
net/netfilter/nf_conntrack_core.c
831
hash_conntrack_raw(tuple, zone_id, net));
net/netfilter/nf_conntrack_core.c
838
thash = __nf_conntrack_find_get(net, zone, tuple,
net/netfilter/nf_conntrack_core.c
839
hash_conntrack_raw(tuple, rid, net));
net/netfilter/nf_conntrack_core.c
861
struct net *net = nf_ct_net(ct);
net/netfilter/nf_conntrack_core.c
875
hash = hash_conntrack(net,
net/netfilter/nf_conntrack_core.c
878
reply_hash = hash_conntrack(net,
net/netfilter/nf_conntrack_core.c
888
zone, net))
net/netfilter/nf_conntrack_core.c
899
zone, net))
net/netfilter/nf_conntrack_core.c
910
NF_CT_STAT_INC(net, insert);
net/netfilter/nf_conntrack_core.c
915
NF_CT_STAT_INC(net, chaintoolong);
net/netfilter/nf_conntrack_ecache.c
132
struct net *net = nf_ct_net(item->ct);
net/netfilter/nf_conntrack_ecache.c
142
notify = rcu_dereference(net->ct.nf_conntrack_event_cb);
net/netfilter/nf_conntrack_ecache.c
246
struct net *net = nf_ct_exp_net(exp);
net/netfilter/nf_conntrack_ecache.c
253
notify = rcu_dereference(net->ct.nf_conntrack_event_cb);
net/netfilter/nf_conntrack_ecache.c
273
void nf_conntrack_register_notifier(struct net *net,
net/netfilter/nf_conntrack_ecache.c
279
notify = rcu_dereference_protected(net->ct.nf_conntrack_event_cb,
net/netfilter/nf_conntrack_ecache.c
282
rcu_assign_pointer(net->ct.nf_conntrack_event_cb, new);
net/netfilter/nf_conntrack_ecache.c
287
void nf_conntrack_unregister_notifier(struct net *net)
net/netfilter/nf_conntrack_ecache.c
290
RCU_INIT_POINTER(net->ct.nf_conntrack_event_cb, NULL);
net/netfilter/nf_conntrack_ecache.c
296
void nf_conntrack_ecache_work(struct net *net, enum nf_ct_ecache_state state)
net/netfilter/nf_conntrack_ecache.c
298
struct nf_conntrack_net *cnet = nf_ct_pernet(net);
net/netfilter/nf_conntrack_ecache.c
303
net->ct.ecache_dwork_pending = true;
net/netfilter/nf_conntrack_ecache.c
308
net->ct.ecache_dwork_pending = false;
net/netfilter/nf_conntrack_ecache.c
326
struct net *net = nf_ct_net(ct);
net/netfilter/nf_conntrack_ecache.c
329
switch (net->ct.sysctl_events) {
net/netfilter/nf_conntrack_ecache.c
365
void nf_conntrack_ecache_pernet_init(struct net *net)
net/netfilter/nf_conntrack_ecache.c
367
struct nf_conntrack_net *cnet = nf_ct_pernet(net);
net/netfilter/nf_conntrack_ecache.c
369
net->ct.sysctl_events = nf_ct_events;
net/netfilter/nf_conntrack_ecache.c
378
void nf_conntrack_ecache_pernet_fini(struct net *net)
net/netfilter/nf_conntrack_ecache.c
380
struct nf_conntrack_net *cnet = nf_ct_pernet(net);
net/netfilter/nf_conntrack_ecache.c
41
struct nf_conntrack_net_ecache *nf_conn_pernet_ecache(const struct net *net)
net/netfilter/nf_conntrack_ecache.c
43
struct nf_conntrack_net *cnet = nf_ct_pernet(net);
net/netfilter/nf_conntrack_expect.c
120
const struct net *net)
net/netfilter/nf_conntrack_expect.c
123
net_eq(net, read_pnet(&i->net)) &&
net/netfilter/nf_conntrack_expect.c
128
__nf_ct_expect_find(struct net *net,
net/netfilter/nf_conntrack_expect.c
132
struct nf_conntrack_net *cnet = nf_ct_pernet(net);
net/netfilter/nf_conntrack_expect.c
139
h = nf_ct_expect_dst_hash(net, tuple);
net/netfilter/nf_conntrack_expect.c
143
if (nf_ct_exp_equal(tuple, i, zone, net))
net/netfilter/nf_conntrack_expect.c
152
nf_ct_expect_find_get(struct net *net,
net/netfilter/nf_conntrack_expect.c
159
i = __nf_ct_expect_find(net, zone, tuple);
net/netfilter/nf_conntrack_expect.c
171
nf_ct_find_expectation(struct net *net,
net/netfilter/nf_conntrack_expect.c
175
struct nf_conntrack_net *cnet = nf_ct_pernet(net);
net/netfilter/nf_conntrack_expect.c
185
h = nf_ct_expect_dst_hash(net, tuple);
net/netfilter/nf_conntrack_expect.c
192
nf_ct_exp_equal(tuple, i, zone, net)) {
net/netfilter/nf_conntrack_expect.c
332
struct net *net = read_pnet(&ct->ct_net);
net/netfilter/nf_conntrack_expect.c
351
write_pnet(&exp->net, net);
net/netfilter/nf_conntrack_expect.c
419
struct net *net = nf_ct_exp_net(exp);
net/netfilter/nf_conntrack_expect.c
420
unsigned int h = nf_ct_expect_dst_hash(net, &exp->tuple);
net/netfilter/nf_conntrack_expect.c
433
cnet = nf_ct_pernet(net);
net/netfilter/nf_conntrack_expect.c
436
NF_CT_STAT_INC(net, expect_create);
net/netfilter/nf_conntrack_expect.c
469
struct net *net = nf_ct_exp_net(expect);
net/netfilter/nf_conntrack_expect.c
476
h = nf_ct_expect_dst_hash(net, &expect->tuple);
net/netfilter/nf_conntrack_expect.c
511
cnet = nf_ct_pernet(net);
net/netfilter/nf_conntrack_expect.c
571
void nf_ct_expect_iterate_net(struct net *net,
net/netfilter/nf_conntrack_expect.c
587
if (!net_eq(nf_ct_exp_net(exp), net))
net/netfilter/nf_conntrack_expect.c
665
struct net *net = seq_file_net(s);
net/netfilter/nf_conntrack_expect.c
672
if (!net_eq(nf_ct_exp_net(expect), net))
net/netfilter/nf_conntrack_expect.c
69
struct net *net = nf_ct_exp_net(exp);
net/netfilter/nf_conntrack_expect.c
717
static int exp_proc_init(struct net *net)
net/netfilter/nf_conntrack_expect.c
724
proc = proc_create_net("nf_conntrack_expect", 0440, net->proc_net,
net/netfilter/nf_conntrack_expect.c
729
root_uid = make_kuid(net->user_ns, 0);
net/netfilter/nf_conntrack_expect.c
730
root_gid = make_kgid(net->user_ns, 0);
net/netfilter/nf_conntrack_expect.c
737
static void exp_proc_remove(struct net *net)
net/netfilter/nf_conntrack_expect.c
740
remove_proc_entry("nf_conntrack_expect", net->proc_net);
net/netfilter/nf_conntrack_expect.c
746
int nf_conntrack_expect_pernet_init(struct net *net)
net/netfilter/nf_conntrack_expect.c
748
return exp_proc_init(net);
net/netfilter/nf_conntrack_expect.c
751
void nf_conntrack_expect_pernet_fini(struct net *net)
net/netfilter/nf_conntrack_expect.c
753
exp_proc_remove(net);
net/netfilter/nf_conntrack_expect.c
76
cnet = nf_ct_pernet(net);
net/netfilter/nf_conntrack_expect.c
86
NF_CT_STAT_INC(net, expect_delete);
net/netfilter/nf_conntrack_expect.c
90
static unsigned int nf_ct_expect_dst_hash(const struct net *n, const struct nf_conntrack_tuple *tuple)
net/netfilter/nf_conntrack_h323_main.c
1167
struct net *net = nf_ct_net(ct);
net/netfilter/nf_conntrack_h323_main.c
1177
exp = __nf_ct_expect_find(net, nf_ct_zone(ct), &tuple);
net/netfilter/nf_conntrack_h323_main.c
671
static int callforward_do_filter(struct net *net,
net/netfilter/nf_conntrack_h323_main.c
688
if (!nf_ip_route(net, (struct dst_entry **)&rt1,
net/netfilter/nf_conntrack_h323_main.c
690
if (!nf_ip_route(net, (struct dst_entry **)&rt2,
net/netfilter/nf_conntrack_h323_main.c
712
if (!nf_ip6_route(net, (struct dst_entry **)&rt1,
net/netfilter/nf_conntrack_h323_main.c
714
if (!nf_ip6_route(net, (struct dst_entry **)&rt2,
net/netfilter/nf_conntrack_h323_main.c
748
struct net *net = nf_ct_net(ct);
net/netfilter/nf_conntrack_h323_main.c
758
callforward_do_filter(net, &addr, &ct->tuplehash[!dir].tuple.src.u3,
net/netfilter/nf_conntrack_labels.c
59
int nf_connlabels_get(struct net *net, unsigned int bits)
net/netfilter/nf_conntrack_labels.c
68
v = atomic_inc_return_relaxed(&net->ct.labels_used);
net/netfilter/nf_conntrack_labels.c
75
void nf_connlabels_put(struct net *net)
net/netfilter/nf_conntrack_labels.c
77
int v = atomic_dec_return_relaxed(&net->ct.labels_used);
net/netfilter/nf_conntrack_netlink.c
1214
struct net *net = sock_net(skb->sk);
net/netfilter/nf_conntrack_netlink.c
1252
if (!net_eq(net, nf_ct_net(ct)))
net/netfilter/nf_conntrack_netlink.c
1588
static int ctnetlink_flush_conntrack(struct net *net,
net/netfilter/nf_conntrack_netlink.c
1594
.net = net,
net/netfilter/nf_conntrack_netlink.c
1637
return ctnetlink_flush_conntrack(info->net, cda,
net/netfilter/nf_conntrack_netlink.c
1645
h = nf_conntrack_find_get(info->net, &zone, &tuple);
net/netfilter/nf_conntrack_netlink.c
1705
h = nf_conntrack_find_get(info->net, &zone, &tuple);
net/netfilter/nf_conntrack_netlink.c
1727
return nfnetlink_unicast(skb2, info->net, NETLINK_CB(skb).portid);
net/netfilter/nf_conntrack_netlink.c
1780
const struct net *net = sock_net(skb->sk);
net/netfilter/nf_conntrack_netlink.c
1793
ecache_net = nf_conn_pernet_ecache(net);
net/netfilter/nf_conntrack_netlink.c
2222
ctnetlink_create_conntrack(struct net *net,
net/netfilter/nf_conntrack_netlink.c
2235
ct = nf_conntrack_alloc(net, zone, otuple, rtuple, GFP_ATOMIC);
net/netfilter/nf_conntrack_netlink.c
2354
master_h = nf_conntrack_find_get(net, zone, &master);
net/netfilter/nf_conntrack_netlink.c
2415
h = nf_conntrack_find_get(info->net, &zone, &otuple);
net/netfilter/nf_conntrack_netlink.c
2417
h = nf_conntrack_find_get(info->net, &zone, &rtuple);
net/netfilter/nf_conntrack_netlink.c
2429
ct = ctnetlink_create_conntrack(info->net, &zone, cda,
net/netfilter/nf_conntrack_netlink.c
2526
struct net *net = sock_net(skb->sk);
net/netfilter/nf_conntrack_netlink.c
2537
st = per_cpu_ptr(net->ct.stat, cpu);
net/netfilter/nf_conntrack_netlink.c
2565
struct net *net)
net/netfilter/nf_conntrack_netlink.c
2577
nr_conntracks = nf_conntrack_count(net);
net/netfilter/nf_conntrack_netlink.c
2612
return nfnetlink_unicast(skb2, info->net, NETLINK_CB(skb).portid);
net/netfilter/nf_conntrack_netlink.c
3095
struct net *net = nf_ct_exp_net(exp);
net/netfilter/nf_conntrack_netlink.c
3111
if (!item->report && !nfnetlink_has_listeners(net, group))
net/netfilter/nf_conntrack_netlink.c
3128
nfnetlink_send(skb, net, item->portid, group, item->report, GFP_ATOMIC);
net/netfilter/nf_conntrack_netlink.c
3136
nfnetlink_set_err(net, 0, 0, -ENOBUFS);
net/netfilter/nf_conntrack_netlink.c
3154
struct net *net = sock_net(skb->sk);
net/netfilter/nf_conntrack_netlink.c
3171
if (!net_eq(nf_ct_exp_net(exp), net))
net/netfilter/nf_conntrack_netlink.c
3262
static int ctnetlink_dump_exp_ct(struct net *net, struct sock *ctnl,
net/netfilter/nf_conntrack_netlink.c
3290
h = nf_conntrack_find_get(net, &zone, &tuple);
net/netfilter/nf_conntrack_netlink.c
3322
return ctnetlink_dump_exp_ct(info->net, info->sk, skb,
net/netfilter/nf_conntrack_netlink.c
3354
exp = nf_ct_expect_find_get(info->net, &zone, &tuple);
net/netfilter/nf_conntrack_netlink.c
3385
return nfnetlink_unicast(skb2, info->net, NETLINK_CB(skb).portid);
net/netfilter/nf_conntrack_netlink.c
3429
exp = nf_ct_expect_find_get(info->net, &zone, &tuple);
net/netfilter/nf_conntrack_netlink.c
3455
nf_ct_expect_iterate_net(info->net, expect_iter_name, name,
net/netfilter/nf_conntrack_netlink.c
3460
nf_ct_expect_iterate_net(info->net, expect_iter_all, NULL,
net/netfilter/nf_conntrack_netlink.c
3525
struct net *net = read_pnet(&ct->ct_net);
net/netfilter/nf_conntrack_netlink.c
3567
write_pnet(&exp->net, net);
net/netfilter/nf_conntrack_netlink.c
3591
ctnetlink_create_expect(struct net *net,
net/netfilter/nf_conntrack_netlink.c
3617
h = nf_conntrack_find_get(net, zone, &master_tuple);
net/netfilter/nf_conntrack_netlink.c
3663
exp = __nf_ct_expect_find(info->net, &zone, &tuple);
net/netfilter/nf_conntrack_netlink.c
3668
err = ctnetlink_create_expect(info->net, &zone, cda, u3,
net/netfilter/nf_conntrack_netlink.c
3715
struct net *net = sock_net(skb->sk);
net/netfilter/nf_conntrack_netlink.c
3726
st = per_cpu_ptr(net->ct.stat, cpu);
net/netfilter/nf_conntrack_netlink.c
3844
static int __net_init ctnetlink_net_init(struct net *net)
net/netfilter/nf_conntrack_netlink.c
3847
nf_conntrack_register_notifier(net, &ctnl_notifier);
net/netfilter/nf_conntrack_netlink.c
3852
static void ctnetlink_net_pre_exit(struct net *net)
net/netfilter/nf_conntrack_netlink.c
3855
nf_conntrack_unregister_notifier(net);
net/netfilter/nf_conntrack_netlink.c
747
struct net *net;
net/netfilter/nf_conntrack_netlink.c
769
net = nf_ct_net(ct);
net/netfilter/nf_conntrack_netlink.c
770
if (!item->report && !nfnetlink_has_listeners(net, group))
net/netfilter/nf_conntrack_netlink.c
866
err = nfnetlink_send(skb, net, item->portid, group, item->report,
net/netfilter/nf_conntrack_netlink.c
878
if (nfnetlink_set_err(net, 0, group, -ENOBUFS) > 0)
net/netfilter/nf_conntrack_ovs.c
151
int nf_ct_handle_fragments(struct net *net, struct sk_buff *skb,
net/netfilter/nf_conntrack_ovs.c
161
err = ip_defrag(net, skb, user);
net/netfilter/nf_conntrack_ovs.c
172
err = nf_ct_frag6_gather(net, skb, user);
net/netfilter/nf_conntrack_pptp.c
115
exp_other = nf_ct_expect_find_get(net, nf_ct_zone(ct), &inv_t);
net/netfilter/nf_conntrack_pptp.c
93
struct net *net = nf_ct_net(ct);
net/netfilter/nf_conntrack_proto.c
437
static int nf_ct_netns_do_get(struct net *net, u8 nfproto)
net/netfilter/nf_conntrack_proto.c
439
struct nf_conntrack_net *cnet = nf_ct_pernet(net);
net/netfilter/nf_conntrack_proto.c
450
err = nf_defrag_ipv4_enable(net);
net/netfilter/nf_conntrack_proto.c
456
err = nf_register_net_hooks(net, ipv4_conntrack_ops,
net/netfilter/nf_conntrack_proto.c
468
err = nf_defrag_ipv6_enable(net);
net/netfilter/nf_conntrack_proto.c
474
err = nf_register_net_hooks(net, ipv6_conntrack_ops,
net/netfilter/nf_conntrack_proto.c
501
err = nf_register_net_hooks(net, nf_ct_bridge_info->ops,
net/netfilter/nf_conntrack_proto.c
517
.net = net,
net/netfilter/nf_conntrack_proto.c
526
static void nf_ct_netns_do_put(struct net *net, u8 nfproto)
net/netfilter/nf_conntrack_proto.c
528
struct nf_conntrack_net *cnet = nf_ct_pernet(net);
net/netfilter/nf_conntrack_proto.c
534
nf_unregister_net_hooks(net, ipv4_conntrack_ops,
net/netfilter/nf_conntrack_proto.c
536
nf_defrag_ipv4_disable(net);
net/netfilter/nf_conntrack_proto.c
54
struct net *net = state->net;
net/netfilter/nf_conntrack_proto.c
542
nf_unregister_net_hooks(net, ipv6_conntrack_ops,
net/netfilter/nf_conntrack_proto.c
544
nf_defrag_ipv6_disable(net);
net/netfilter/nf_conntrack_proto.c
552
nf_unregister_net_hooks(net, nf_ct_bridge_info->ops,
net/netfilter/nf_conntrack_proto.c
561
static int nf_ct_netns_inet_get(struct net *net)
net/netfilter/nf_conntrack_proto.c
565
err = nf_ct_netns_do_get(net, NFPROTO_IPV4);
net/netfilter/nf_conntrack_proto.c
569
err = nf_ct_netns_do_get(net, NFPROTO_IPV6);
net/netfilter/nf_conntrack_proto.c
575
nf_ct_netns_put(net, NFPROTO_IPV4);
net/netfilter/nf_conntrack_proto.c
58
if (net->ct.sysctl_log_invalid != protonum &&
net/netfilter/nf_conntrack_proto.c
581
int nf_ct_netns_get(struct net *net, u8 nfproto)
net/netfilter/nf_conntrack_proto.c
587
err = nf_ct_netns_inet_get(net);
net/netfilter/nf_conntrack_proto.c
59
net->ct.sysctl_log_invalid != IPPROTO_RAW)
net/netfilter/nf_conntrack_proto.c
590
err = nf_ct_netns_do_get(net, NFPROTO_BRIDGE);
net/netfilter/nf_conntrack_proto.c
594
err = nf_ct_netns_inet_get(net);
net/netfilter/nf_conntrack_proto.c
596
nf_ct_netns_put(net, NFPROTO_BRIDGE);
net/netfilter/nf_conntrack_proto.c
601
err = nf_ct_netns_do_get(net, nfproto);
net/netfilter/nf_conntrack_proto.c
608
void nf_ct_netns_put(struct net *net, uint8_t nfproto)
net/netfilter/nf_conntrack_proto.c
612
nf_ct_netns_do_put(net, NFPROTO_BRIDGE);
net/netfilter/nf_conntrack_proto.c
615
nf_ct_netns_do_put(net, NFPROTO_IPV4);
net/netfilter/nf_conntrack_proto.c
616
nf_ct_netns_do_put(net, NFPROTO_IPV6);
net/netfilter/nf_conntrack_proto.c
619
nf_ct_netns_do_put(net, nfproto);
net/netfilter/nf_conntrack_proto.c
66
nf_log_packet(net, state->pf, 0, skb, state->in, state->out,
net/netfilter/nf_conntrack_proto.c
674
void nf_conntrack_proto_pernet_init(struct net *net)
net/netfilter/nf_conntrack_proto.c
676
nf_conntrack_generic_init_net(net);
net/netfilter/nf_conntrack_proto.c
677
nf_conntrack_udp_init_net(net);
net/netfilter/nf_conntrack_proto.c
678
nf_conntrack_tcp_init_net(net);
net/netfilter/nf_conntrack_proto.c
679
nf_conntrack_icmp_init_net(net);
net/netfilter/nf_conntrack_proto.c
681
nf_conntrack_icmpv6_init_net(net);
net/netfilter/nf_conntrack_proto.c
684
nf_conntrack_sctp_init_net(net);
net/netfilter/nf_conntrack_proto.c
687
nf_conntrack_gre_init_net(net);
net/netfilter/nf_conntrack_proto.c
79
struct net *net;
net/netfilter/nf_conntrack_proto.c
82
net = nf_ct_net(ct);
net/netfilter/nf_conntrack_proto.c
83
if (likely(net->ct.sysctl_log_invalid == 0))
net/netfilter/nf_conntrack_proto_generic.c
21
struct net *net, void *data)
net/netfilter/nf_conntrack_proto_generic.c
23
struct nf_generic_net *gn = nf_generic_pernet(net);
net/netfilter/nf_conntrack_proto_generic.c
60
void nf_conntrack_generic_init_net(struct net *net)
net/netfilter/nf_conntrack_proto_generic.c
62
struct nf_generic_net *gn = nf_generic_pernet(net);
net/netfilter/nf_conntrack_proto_gre.c
128
struct net *net = nf_ct_net(ct);
net/netfilter/nf_conntrack_proto_gre.c
129
struct nf_gre_net *net_gre = gre_pernet(net);
net/netfilter/nf_conntrack_proto_gre.c
216
struct net *net, struct nf_conntrack_tuple *tuple)
net/netfilter/nf_conntrack_proto_gre.c
244
srckey = gre_keymap_lookup(net, tuple);
net/netfilter/nf_conntrack_proto_gre.c
260
static unsigned int *gre_get_timeouts(struct net *net)
net/netfilter/nf_conntrack_proto_gre.c
262
return gre_pernet(net)->timeouts;
net/netfilter/nf_conntrack_proto_gre.c
313
struct net *net, void *data)
net/netfilter/nf_conntrack_proto_gre.c
316
struct nf_gre_net *net_gre = gre_pernet(net);
net/netfilter/nf_conntrack_proto_gre.c
319
timeouts = gre_get_timeouts(net);
net/netfilter/nf_conntrack_proto_gre.c
359
static int destroy_sibling_or_exp(struct net *net, struct nf_conn *ct,
net/netfilter/nf_conntrack_proto_gre.c
371
h = nf_conntrack_find_get(net, zone, t);
net/netfilter/nf_conntrack_proto_gre.c
381
exp = nf_ct_expect_find_get(net, zone, t);
net/netfilter/nf_conntrack_proto_gre.c
394
struct net *net = nf_ct_net(ct);
net/netfilter/nf_conntrack_proto_gre.c
408
if (!destroy_sibling_or_exp(net, ct, &t))
net/netfilter/nf_conntrack_proto_gre.c
416
if (!destroy_sibling_or_exp(net, ct, &t))
net/netfilter/nf_conntrack_proto_gre.c
422
void nf_conntrack_gre_init_net(struct net *net)
net/netfilter/nf_conntrack_proto_gre.c
424
struct nf_gre_net *net_gre = gre_pernet(net);
net/netfilter/nf_conntrack_proto_gre.c
55
static inline struct nf_gre_net *gre_pernet(struct net *net)
net/netfilter/nf_conntrack_proto_gre.c
57
return &net->ct.nf_ct_proto.gre;
net/netfilter/nf_conntrack_proto_gre.c
71
static __be16 gre_keymap_lookup(struct net *net, struct nf_conntrack_tuple *t)
net/netfilter/nf_conntrack_proto_gre.c
73
struct nf_gre_net *net_gre = gre_pernet(net);
net/netfilter/nf_conntrack_proto_icmp.c
125
state->pf, state->net, &origtuple))
net/netfilter/nf_conntrack_proto_icmp.c
133
h = nf_conntrack_find_get(state->net, zone, &innertuple);
net/netfilter/nf_conntrack_proto_icmp.c
220
if (state->net->ct.sysctl_checksum &&
net/netfilter/nf_conntrack_proto_icmp.c
28
struct net *net, struct nf_conntrack_tuple *tuple)
net/netfilter/nf_conntrack_proto_icmp.c
322
struct net *net, void *data)
net/netfilter/nf_conntrack_proto_icmp.c
325
struct nf_icmp_net *in = nf_icmp_pernet(net);
net/netfilter/nf_conntrack_proto_icmp.c
358
void nf_conntrack_icmp_init_net(struct net *net)
net/netfilter/nf_conntrack_proto_icmp.c
360
struct nf_icmp_net *in = nf_icmp_pernet(net);
net/netfilter/nf_conntrack_proto_icmpv6.c
201
state->net->ct.sysctl_checksum &&
net/netfilter/nf_conntrack_proto_icmpv6.c
300
struct net *net, void *data)
net/netfilter/nf_conntrack_proto_icmpv6.c
303
struct nf_icmp_net *in = nf_icmpv6_pernet(net);
net/netfilter/nf_conntrack_proto_icmpv6.c
306
timeout = icmpv6_get_timeouts(net);
net/netfilter/nf_conntrack_proto_icmpv6.c
33
struct net *net,
net/netfilter/nf_conntrack_proto_icmpv6.c
336
void nf_conntrack_icmpv6_init_net(struct net *net)
net/netfilter/nf_conntrack_proto_icmpv6.c
338
struct nf_icmp_net *in = nf_icmpv6_pernet(net);
net/netfilter/nf_conntrack_proto_icmpv6.c
83
static unsigned int *icmpv6_get_timeouts(struct net *net)
net/netfilter/nf_conntrack_proto_icmpv6.c
85
return &nf_icmpv6_pernet(net)->timeout;
net/netfilter/nf_conntrack_proto_sctp.c
307
state->net->ct.sysctl_checksum &&
net/netfilter/nf_conntrack_proto_sctp.c
638
struct net *net, void *data)
net/netfilter/nf_conntrack_proto_sctp.c
641
struct nf_sctp_net *sn = nf_sctp_pernet(net);
net/netfilter/nf_conntrack_proto_sctp.c
692
void nf_conntrack_sctp_init_net(struct net *net)
net/netfilter/nf_conntrack_proto_sctp.c
694
struct nf_sctp_net *sn = nf_sctp_pernet(net);
net/netfilter/nf_conntrack_proto_tcp.c
1467
struct net *net, void *data)
net/netfilter/nf_conntrack_proto_tcp.c
1469
struct nf_tcp_net *tn = nf_tcp_pernet(net);
net/netfilter/nf_conntrack_proto_tcp.c
1578
void nf_conntrack_tcp_init_net(struct net *net)
net/netfilter/nf_conntrack_proto_tcp.c
1580
struct nf_tcp_net *tn = nf_tcp_pernet(net);
net/netfilter/nf_conntrack_proto_tcp.c
821
if (state->net->ct.sysctl_checksum &&
net/netfilter/nf_conntrack_proto_tcp.c
844
struct net *net = nf_ct_net(ct);
net/netfilter/nf_conntrack_proto_tcp.c
845
const struct nf_tcp_net *tn = nf_tcp_pernet(net);
net/netfilter/nf_conntrack_proto_tcp.c
969
struct net *net = nf_ct_net(ct);
net/netfilter/nf_conntrack_proto_tcp.c
970
struct nf_tcp_net *tn = nf_tcp_pernet(net);
net/netfilter/nf_conntrack_proto_udp.c
138
struct net *net, void *data)
net/netfilter/nf_conntrack_proto_udp.c
141
struct nf_udp_net *un = nf_udp_pernet(net);
net/netfilter/nf_conntrack_proto_udp.c
184
void nf_conntrack_udp_init_net(struct net *net)
net/netfilter/nf_conntrack_proto_udp.c
186
struct nf_udp_net *un = nf_udp_pernet(net);
net/netfilter/nf_conntrack_proto_udp.c
32
static unsigned int *udp_get_timeouts(struct net *net)
net/netfilter/nf_conntrack_proto_udp.c
34
return nf_udp_pernet(net)->timeouts;
net/netfilter/nf_conntrack_proto_udp.c
74
state->net->ct.sysctl_checksum &&
net/netfilter/nf_conntrack_sip.c
1014
exp = __nf_ct_expect_find(net, nf_ct_zone(ct), &tuple);
net/netfilter/nf_conntrack_sip.c
939
struct net *net = nf_ct_net(ct);
net/netfilter/nf_conntrack_sip.c
967
nf_ip_route(net, &dst, &fl, false);
net/netfilter/nf_conntrack_sip.c
972
nf_ip6_route(net, &dst, &fl, false);
net/netfilter/nf_conntrack_standalone.c
1003
static int nf_conntrack_standalone_init_sysctl(struct net *net)
net/netfilter/nf_conntrack_standalone.c
1005
struct nf_conntrack_net *cnet = nf_ct_pernet(net);
net/netfilter/nf_conntrack_standalone.c
1006
struct nf_udp_net *un = nf_udp_pernet(net);
net/netfilter/nf_conntrack_standalone.c
101
static struct nf_conntrack_tuple_hash *ct_get_next(const struct net *net,
net/netfilter/nf_conntrack_standalone.c
1017
table[NF_SYSCTL_CT_CHECKSUM].data = &net->ct.sysctl_checksum;
net/netfilter/nf_conntrack_standalone.c
1018
table[NF_SYSCTL_CT_LOG_INVALID].data = &net->ct.sysctl_log_invalid;
net/netfilter/nf_conntrack_standalone.c
1019
table[NF_SYSCTL_CT_ACCT].data = &net->ct.sysctl_acct;
net/netfilter/nf_conntrack_standalone.c
1021
table[NF_SYSCTL_CT_EVENTS].data = &net->ct.sysctl_events;
net/netfilter/nf_conntrack_standalone.c
1024
table[NF_SYSCTL_CT_TIMESTAMP].data = &net->ct.sysctl_tstamp;
net/netfilter/nf_conntrack_standalone.c
1026
table[NF_SYSCTL_CT_PROTO_TIMEOUT_GENERIC].data = &nf_generic_pernet(net)->timeout;
net/netfilter/nf_conntrack_standalone.c
1027
table[NF_SYSCTL_CT_PROTO_TIMEOUT_ICMP].data = &nf_icmp_pernet(net)->timeout;
net/netfilter/nf_conntrack_standalone.c
1028
table[NF_SYSCTL_CT_PROTO_TIMEOUT_ICMPV6].data = &nf_icmpv6_pernet(net)->timeout;
net/netfilter/nf_conntrack_standalone.c
1035
nf_conntrack_standalone_init_tcp_sysctl(net, table);
net/netfilter/nf_conntrack_standalone.c
1036
nf_conntrack_standalone_init_sctp_sysctl(net, table);
net/netfilter/nf_conntrack_standalone.c
1037
nf_conntrack_standalone_init_gre_sysctl(net, table);
net/netfilter/nf_conntrack_standalone.c
1040
if (!net_eq(&init_net, net)) {
net/netfilter/nf_conntrack_standalone.c
1046
cnet->sysctl_header = register_net_sysctl_sz(net, "net/netfilter",
net/netfilter/nf_conntrack_standalone.c
1059
static void nf_conntrack_standalone_fini_sysctl(struct net *net)
net/netfilter/nf_conntrack_standalone.c
1061
struct nf_conntrack_net *cnet = nf_ct_pernet(net);
net/netfilter/nf_conntrack_standalone.c
1069
static int nf_conntrack_standalone_init_sysctl(struct net *net)
net/netfilter/nf_conntrack_standalone.c
1074
static void nf_conntrack_standalone_fini_sysctl(struct net *net)
net/netfilter/nf_conntrack_standalone.c
1079
static void nf_conntrack_fini_net(struct net *net)
net/netfilter/nf_conntrack_standalone.c
1082
nf_ct_netns_put(net, NFPROTO_INET);
net/netfilter/nf_conntrack_standalone.c
1084
nf_conntrack_standalone_fini_proc(net);
net/netfilter/nf_conntrack_standalone.c
1085
nf_conntrack_standalone_fini_sysctl(net);
net/netfilter/nf_conntrack_standalone.c
1088
static int nf_conntrack_pernet_init(struct net *net)
net/netfilter/nf_conntrack_standalone.c
1092
net->ct.sysctl_checksum = 1;
net/netfilter/nf_conntrack_standalone.c
1094
ret = nf_conntrack_standalone_init_sysctl(net);
net/netfilter/nf_conntrack_standalone.c
1098
ret = nf_conntrack_standalone_init_proc(net);
net/netfilter/nf_conntrack_standalone.c
1102
ret = nf_conntrack_init_net(net);
net/netfilter/nf_conntrack_standalone.c
1107
ret = nf_ct_netns_get(net, NFPROTO_INET);
net/netfilter/nf_conntrack_standalone.c
1115
nf_conntrack_cleanup_net(net);
net/netfilter/nf_conntrack_standalone.c
1117
nf_conntrack_standalone_fini_proc(net);
net/netfilter/nf_conntrack_standalone.c
1119
nf_conntrack_standalone_fini_sysctl(net);
net/netfilter/nf_conntrack_standalone.c
1125
struct net *net;
net/netfilter/nf_conntrack_standalone.c
1127
list_for_each_entry(net, net_exit_list, exit_list)
net/netfilter/nf_conntrack_standalone.c
1128
nf_conntrack_fini_net(net);
net/netfilter/nf_conntrack_standalone.c
116
if (!net_eq(net, nf_ct_net(ct)))
net/netfilter/nf_conntrack_standalone.c
152
struct net *net = seq_file_net(seq);
net/netfilter/nf_conntrack_standalone.c
167
return ct_get_next(net, st);
net/netfilter/nf_conntrack_standalone.c
173
struct net *net = seq_file_net(s);
net/netfilter/nf_conntrack_standalone.c
176
return ct_get_next(net, st);
net/netfilter/nf_conntrack_standalone.c
307
struct net *net = seq_file_net(s);
net/netfilter/nf_conntrack_standalone.c
329
if (!net_eq(nf_ct_net(ct), net))
net/netfilter/nf_conntrack_standalone.c
402
struct net *net = seq_file_net(seq);
net/netfilter/nf_conntrack_standalone.c
412
return per_cpu_ptr(net->ct.stat, cpu);
net/netfilter/nf_conntrack_standalone.c
420
struct net *net = seq_file_net(seq);
net/netfilter/nf_conntrack_standalone.c
427
return per_cpu_ptr(net->ct.stat, cpu);
net/netfilter/nf_conntrack_standalone.c
439
struct net *net = seq_file_net(seq);
net/netfilter/nf_conntrack_standalone.c
448
nr_conntracks = nf_conntrack_count(net);
net/netfilter/nf_conntrack_standalone.c
481
static int nf_conntrack_standalone_init_proc(struct net *net)
net/netfilter/nf_conntrack_standalone.c
487
pde = proc_create_net("nf_conntrack", 0440, net->proc_net, &ct_seq_ops,
net/netfilter/nf_conntrack_standalone.c
492
root_uid = make_kuid(net->user_ns, 0);
net/netfilter/nf_conntrack_standalone.c
493
root_gid = make_kgid(net->user_ns, 0);
net/netfilter/nf_conntrack_standalone.c
497
pde = proc_create_net("nf_conntrack", 0444, net->proc_net_stat,
net/netfilter/nf_conntrack_standalone.c
504
remove_proc_entry("nf_conntrack", net->proc_net);
net/netfilter/nf_conntrack_standalone.c
509
static void nf_conntrack_standalone_fini_proc(struct net *net)
net/netfilter/nf_conntrack_standalone.c
511
remove_proc_entry("nf_conntrack", net->proc_net_stat);
net/netfilter/nf_conntrack_standalone.c
512
remove_proc_entry("nf_conntrack", net->proc_net);
net/netfilter/nf_conntrack_standalone.c
515
static int nf_conntrack_standalone_init_proc(struct net *net)
net/netfilter/nf_conntrack_standalone.c
520
static void nf_conntrack_standalone_fini_proc(struct net *net)
net/netfilter/nf_conntrack_standalone.c
525
u32 nf_conntrack_count(const struct net *net)
net/netfilter/nf_conntrack_standalone.c
527
const struct nf_conntrack_net *cnet = nf_ct_pernet(net);
net/netfilter/nf_conntrack_standalone.c
935
static void nf_conntrack_standalone_init_tcp_sysctl(struct net *net,
net/netfilter/nf_conntrack_standalone.c
938
struct nf_tcp_net *tn = nf_tcp_pernet(net);
net/netfilter/nf_conntrack_standalone.c
970
static void nf_conntrack_standalone_init_sctp_sysctl(struct net *net,
net/netfilter/nf_conntrack_standalone.c
974
struct nf_sctp_net *sn = nf_sctp_pernet(net);
net/netfilter/nf_conntrack_standalone.c
992
static void nf_conntrack_standalone_init_gre_sysctl(struct net *net,
net/netfilter/nf_conntrack_standalone.c
996
struct nf_gre_net *gn = nf_gre_pernet(net);
net/netfilter/nf_conntrack_timeout.c
60
void nf_ct_untimeout(struct net *net, struct nf_ct_timeout *timeout)
net/netfilter/nf_conntrack_timeout.c
63
.net = net,
net/netfilter/nf_conntrack_timeout.c
79
int nf_ct_set_timeout(struct net *net, struct nf_conn *ct,
net/netfilter/nf_conntrack_timeout.c
98
timeout = h->timeout_find_get(net, timeout_name);
net/netfilter/nf_conntrack_timestamp.c
22
void nf_conntrack_tstamp_pernet_init(struct net *net)
net/netfilter/nf_conntrack_timestamp.c
24
net->ct.sysctl_tstamp = nf_ct_tstamp;
net/netfilter/nf_dup_netdev.c
78
dev = dev_get_by_index(ctx->net, oif);
net/netfilter/nf_flow_table_core.c
204
struct net *net = nf_ct_net(ct);
net/netfilter/nf_flow_table_core.c
211
const struct nf_tcp_net *tn = nf_tcp_pernet(net);
net/netfilter/nf_flow_table_core.c
232
const struct nf_udp_net *tn = nf_udp_pernet(net);
net/netfilter/nf_flow_table_core.c
312
struct net *net = nf_ct_net(flow->ct);
net/netfilter/nf_flow_table_core.c
316
struct nf_tcp_net *tn = nf_tcp_pernet(net);
net/netfilter/nf_flow_table_core.c
320
struct nf_udp_net *tn = nf_udp_pernet(net);
net/netfilter/nf_flow_table_core.c
776
static int nf_flow_table_init_net(struct net *net)
net/netfilter/nf_flow_table_core.c
778
net->ft.stat = alloc_percpu(struct nf_flow_table_stat);
net/netfilter/nf_flow_table_core.c
779
return net->ft.stat ? 0 : -ENOMEM;
net/netfilter/nf_flow_table_core.c
782
static void nf_flow_table_fini_net(struct net *net)
net/netfilter/nf_flow_table_core.c
784
free_percpu(net->ft.stat);
net/netfilter/nf_flow_table_core.c
787
static int nf_flow_table_pernet_init(struct net *net)
net/netfilter/nf_flow_table_core.c
791
ret = nf_flow_table_init_net(net);
net/netfilter/nf_flow_table_core.c
795
ret = nf_flow_table_init_proc(net);
net/netfilter/nf_flow_table_core.c
802
nf_flow_table_fini_net(net);
net/netfilter/nf_flow_table_core.c
808
struct net *net;
net/netfilter/nf_flow_table_core.c
810
list_for_each_entry(net, net_exit_list, exit_list) {
net/netfilter/nf_flow_table_core.c
811
nf_flow_table_fini_proc(net);
net/netfilter/nf_flow_table_core.c
812
nf_flow_table_fini_net(net);
net/netfilter/nf_flow_table_inet.c
45
static int nf_flow_rule_route_inet(struct net *net,
net/netfilter/nf_flow_table_inet.c
55
err = nf_flow_rule_route_ipv4(net, flow, dir, flow_rule);
net/netfilter/nf_flow_table_inet.c
58
err = nf_flow_rule_route_ipv6(net, flow, dir, flow_rule);
net/netfilter/nf_flow_table_ip.c
1162
if (nf_flow_tunnel_v6_push(state->net, skb, other_tuple,
net/netfilter/nf_flow_table_ip.c
1170
xmit.outdev = dev_get_by_index_rcu(state->net, tuplehash->tuple.ifidx);
net/netfilter/nf_flow_table_ip.c
1184
xmit.outdev = dev_get_by_index_rcu(state->net, tuplehash->tuple.out.ifidx);
net/netfilter/nf_flow_table_ip.c
1199
return nf_flow_queue_xmit(state->net, skb, &xmit);
net/netfilter/nf_flow_table_ip.c
314
dst_output(state->net, state->sk, skb);
net/netfilter/nf_flow_table_ip.c
590
static int nf_flow_tunnel_ipip_push(struct net *net, struct sk_buff *skb,
net/netfilter/nf_flow_table_ip.c
628
__ip_select_ident(net, iph, skb_shinfo(skb)->gso_segs ?: 1);
net/netfilter/nf_flow_table_ip.c
636
static int nf_flow_tunnel_v4_push(struct net *net, struct sk_buff *skb,
net/netfilter/nf_flow_table_ip.c
641
return nf_flow_tunnel_ipip_push(net, skb, tuple, dst, ip_daddr);
net/netfilter/nf_flow_table_ip.c
646
static int nf_flow_tunnel_ip6ip6_push(struct net *net, struct sk_buff *skb,
net/netfilter/nf_flow_table_ip.c
684
ip6_make_flowlabel(net, skb, fl6.flowlabel, true, &fl6));
net/netfilter/nf_flow_table_ip.c
697
static int nf_flow_tunnel_v6_push(struct net *net, struct sk_buff *skb,
net/netfilter/nf_flow_table_ip.c
703
return nf_flow_tunnel_ip6ip6_push(net, skb, tuple, dst, ip6_daddr);
net/netfilter/nf_flow_table_ip.c
743
static void __nf_flow_queue_xmit(struct net *net, struct sk_buff *skb,
net/netfilter/nf_flow_table_ip.c
761
static unsigned int nf_flow_encap_gso_xmit(struct net *net, struct sk_buff *skb,
net/netfilter/nf_flow_table_ip.c
783
__nf_flow_queue_xmit(net, segs, xmit);
net/netfilter/nf_flow_table_ip.c
789
static unsigned int nf_flow_queue_xmit(struct net *net, struct sk_buff *skb,
net/netfilter/nf_flow_table_ip.c
794
return nf_flow_encap_gso_xmit(net, skb, xmit);
net/netfilter/nf_flow_table_ip.c
800
__nf_flow_queue_xmit(net, skb, xmit);
net/netfilter/nf_flow_table_ip.c
846
if (nf_flow_tunnel_v4_push(state->net, skb, other_tuple,
net/netfilter/nf_flow_table_ip.c
853
xmit.outdev = dev_get_by_index_rcu(state->net, tuplehash->tuple.ifidx);
net/netfilter/nf_flow_table_ip.c
867
xmit.outdev = dev_get_by_index_rcu(state->net, tuplehash->tuple.out.ifidx);
net/netfilter/nf_flow_table_ip.c
882
return nf_flow_queue_xmit(state->net, skb, &xmit);
net/netfilter/nf_flow_table_offload.c
1040
struct net *net;
net/netfilter/nf_flow_table_offload.c
1043
net = read_pnet(&offload->flowtable->net);
net/netfilter/nf_flow_table_offload.c
1047
NF_FLOW_TABLE_STAT_DEC_ATOMIC(net, count_wq_add);
net/netfilter/nf_flow_table_offload.c
1051
NF_FLOW_TABLE_STAT_DEC_ATOMIC(net, count_wq_del);
net/netfilter/nf_flow_table_offload.c
1055
NF_FLOW_TABLE_STAT_DEC_ATOMIC(net, count_wq_stats);
net/netfilter/nf_flow_table_offload.c
1067
struct net *net = read_pnet(&offload->flowtable->net);
net/netfilter/nf_flow_table_offload.c
1070
NF_FLOW_TABLE_STAT_INC_ATOMIC(net, count_wq_add);
net/netfilter/nf_flow_table_offload.c
1073
NF_FLOW_TABLE_STAT_INC_ATOMIC(net, count_wq_del);
net/netfilter/nf_flow_table_offload.c
1076
NF_FLOW_TABLE_STAT_INC_ATOMIC(net, count_wq_stats);
net/netfilter/nf_flow_table_offload.c
1210
struct net *net,
net/netfilter/nf_flow_table_offload.c
1216
bo->net = net;
net/netfilter/nf_flow_table_offload.c
232
static int flow_offload_eth_src(struct net *net,
net/netfilter/nf_flow_table_offload.c
256
dev = dev_get_by_index(net, other_tuple->iifidx);
net/netfilter/nf_flow_table_offload.c
282
static int flow_offload_eth_dst(struct net *net,
net/netfilter/nf_flow_table_offload.c
342
static int flow_offload_ipv4_snat(struct net *net,
net/netfilter/nf_flow_table_offload.c
373
static int flow_offload_ipv4_dnat(struct net *net,
net/netfilter/nf_flow_table_offload.c
423
static int flow_offload_ipv6_snat(struct net *net,
net/netfilter/nf_flow_table_offload.c
448
static int flow_offload_ipv6_dnat(struct net *net,
net/netfilter/nf_flow_table_offload.c
492
static int flow_offload_port_snat(struct net *net,
net/netfilter/nf_flow_table_offload.c
526
static int flow_offload_port_dnat(struct net *net,
net/netfilter/nf_flow_table_offload.c
560
static int flow_offload_ipv4_checksum(struct net *net,
net/netfilter/nf_flow_table_offload.c
585
static int flow_offload_redirect(struct net *net,
net/netfilter/nf_flow_table_offload.c
609
dev = dev_get_by_index(net, ifindex);
net/netfilter/nf_flow_table_offload.c
683
nf_flow_rule_route_common(struct net *net, const struct flow_offload *flow,
net/netfilter/nf_flow_table_offload.c
695
if (flow_offload_eth_src(net, flow, dir, flow_rule) < 0 ||
net/netfilter/nf_flow_table_offload.c
696
flow_offload_eth_dst(net, flow, dir, flow_rule) < 0)
net/netfilter/nf_flow_table_offload.c
743
int nf_flow_rule_route_ipv4(struct net *net, struct flow_offload *flow,
net/netfilter/nf_flow_table_offload.c
747
if (nf_flow_rule_route_common(net, flow, dir, flow_rule) < 0)
net/netfilter/nf_flow_table_offload.c
751
if (flow_offload_ipv4_snat(net, flow, dir, flow_rule) < 0 ||
net/netfilter/nf_flow_table_offload.c
752
flow_offload_port_snat(net, flow, dir, flow_rule) < 0)
net/netfilter/nf_flow_table_offload.c
756
if (flow_offload_ipv4_dnat(net, flow, dir, flow_rule) < 0 ||
net/netfilter/nf_flow_table_offload.c
757
flow_offload_port_dnat(net, flow, dir, flow_rule) < 0)
net/netfilter/nf_flow_table_offload.c
762
if (flow_offload_ipv4_checksum(net, flow, flow_rule) < 0)
net/netfilter/nf_flow_table_offload.c
765
if (flow_offload_redirect(net, flow, dir, flow_rule) < 0)
net/netfilter/nf_flow_table_offload.c
772
int nf_flow_rule_route_ipv6(struct net *net, struct flow_offload *flow,
net/netfilter/nf_flow_table_offload.c
776
if (nf_flow_rule_route_common(net, flow, dir, flow_rule) < 0)
net/netfilter/nf_flow_table_offload.c
780
if (flow_offload_ipv6_snat(net, flow, dir, flow_rule) < 0 ||
net/netfilter/nf_flow_table_offload.c
781
flow_offload_port_snat(net, flow, dir, flow_rule) < 0)
net/netfilter/nf_flow_table_offload.c
785
if (flow_offload_ipv6_dnat(net, flow, dir, flow_rule) < 0 ||
net/netfilter/nf_flow_table_offload.c
786
flow_offload_port_dnat(net, flow, dir, flow_rule) < 0)
net/netfilter/nf_flow_table_offload.c
790
if (flow_offload_redirect(net, flow, dir, flow_rule) < 0)
net/netfilter/nf_flow_table_offload.c
798
nf_flow_offload_rule_alloc(struct net *net,
net/netfilter/nf_flow_table_offload.c
831
if (flowtable->type->action(net, flow, dir, flow_rule) < 0)
net/netfilter/nf_flow_table_offload.c
871
struct net *net = read_pnet(&offload->flowtable->net);
net/netfilter/nf_flow_table_offload.c
873
flow_rule[0] = nf_flow_offload_rule_alloc(net, offload,
net/netfilter/nf_flow_table_offload.c
878
flow_rule[1] = nf_flow_offload_rule_alloc(net, offload,
net/netfilter/nf_flow_table_procfs.c
18
return per_cpu_ptr(net->ft.stat, cpu);
net/netfilter/nf_flow_table_procfs.c
26
struct net *net = seq_file_net(seq);
net/netfilter/nf_flow_table_procfs.c
33
return per_cpu_ptr(net->ft.stat, cpu);
net/netfilter/nf_flow_table_procfs.c
67
int nf_flow_table_init_proc(struct net *net)
net/netfilter/nf_flow_table_procfs.c
71
pde = proc_create_net("nf_flowtable", 0444, net->proc_net_stat,
net/netfilter/nf_flow_table_procfs.c
77
void nf_flow_table_fini_proc(struct net *net)
net/netfilter/nf_flow_table_procfs.c
79
remove_proc_entry("nf_flowtable", net->proc_net_stat);
net/netfilter/nf_flow_table_procfs.c
8
struct net *net = seq_file_net(seq);
net/netfilter/nf_hooks_lwtunnel.c
100
table = net->nf.nf_lwtnl_dir_header->ctl_table_arg;
net/netfilter/nf_hooks_lwtunnel.c
101
unregister_net_sysctl_table(net->nf.nf_lwtnl_dir_header);
net/netfilter/nf_hooks_lwtunnel.c
102
if (!net_eq(net, &init_net))
net/netfilter/nf_hooks_lwtunnel.c
67
static int __net_init nf_lwtunnel_net_init(struct net *net)
net/netfilter/nf_hooks_lwtunnel.c
73
if (!net_eq(net, &init_net)) {
net/netfilter/nf_hooks_lwtunnel.c
81
hdr = register_net_sysctl_sz(net, "net/netfilter", table,
net/netfilter/nf_hooks_lwtunnel.c
86
net->nf.nf_lwtnl_dir_header = hdr;
net/netfilter/nf_hooks_lwtunnel.c
90
if (!net_eq(net, &init_net))
net/netfilter/nf_hooks_lwtunnel.c
96
static void __net_exit nf_lwtunnel_net_exit(struct net *net)
net/netfilter/nf_internals.h
27
void nf_queue_nf_hook_drop(struct net *net);
net/netfilter/nf_log.c
154
int nf_log_bind_pf(struct net *net, u_int8_t pf,
net/netfilter/nf_log.c
157
if (pf >= ARRAY_SIZE(net->nf.nf_loggers))
net/netfilter/nf_log.c
164
rcu_assign_pointer(net->nf.nf_loggers[pf], logger);
net/netfilter/nf_log.c
170
void nf_log_unbind_pf(struct net *net, u_int8_t pf)
net/netfilter/nf_log.c
172
if (pf >= ARRAY_SIZE(net->nf.nf_loggers))
net/netfilter/nf_log.c
175
RCU_INIT_POINTER(net->nf.nf_loggers[pf], NULL);
net/netfilter/nf_log.c
237
void nf_log_packet(struct net *net,
net/netfilter/nf_log.c
254
logger = rcu_dereference(net->nf.nf_loggers[pf]);
net/netfilter/nf_log.c
260
logger->logfn(net, pf, hooknum, skb, in, out, loginfo, prefix);
net/netfilter/nf_log.c
266
void nf_log_trace(struct net *net,
net/netfilter/nf_log.c
279
logger = rcu_dereference(net->nf.nf_loggers[pf]);
net/netfilter/nf_log.c
284
logger->logfn(net, pf, hooknum, skb, in, out, loginfo, prefix);
net/netfilter/nf_log.c
350
struct net *net = seq_file_net(seq);
net/netfilter/nf_log.c
354
if (*pos >= ARRAY_SIZE(net->nf.nf_loggers))
net/netfilter/nf_log.c
362
struct net *net = seq_file_net(s);
net/netfilter/nf_log.c
366
if (*pos >= ARRAY_SIZE(net->nf.nf_loggers))
net/netfilter/nf_log.c
382
struct net *net = seq_file_net(s);
net/netfilter/nf_log.c
384
logger = nft_log_dereference(net->nf.nf_loggers[*pos]);
net/netfilter/nf_log.c
444
struct net *net = table->extra2;
net/netfilter/nf_log.c
45
int nf_log_set(struct net *net, u_int8_t pf, const struct nf_logger *logger)
net/netfilter/nf_log.c
459
nf_log_unbind_pf(net, tindex);
net/netfilter/nf_log.c
468
rcu_assign_pointer(net->nf.nf_loggers[tindex], logger);
net/netfilter/nf_log.c
475
logger = nft_log_dereference(net->nf.nf_loggers[tindex]);
net/netfilter/nf_log.c
487
static int netfilter_log_sysctl_init(struct net *net)
net/netfilter/nf_log.c
49
if (pf == NFPROTO_UNSPEC || pf >= ARRAY_SIZE(net->nf.nf_loggers))
net/netfilter/nf_log.c
493
if (!net_eq(net, &init_net)) {
net/netfilter/nf_log.c
512
nf_log_sysctl_fhdr = register_net_sysctl(net, "net/netfilter",
net/netfilter/nf_log.c
519
table[i].extra2 = net;
net/netfilter/nf_log.c
521
net->nf.nf_log_dir_header = register_net_sysctl_sz(net,
net/netfilter/nf_log.c
525
if (!net->nf.nf_log_dir_header)
net/netfilter/nf_log.c
53
log = nft_log_dereference(net->nf.nf_loggers[pf]);
net/netfilter/nf_log.c
531
if (!net_eq(net, &init_net))
net/netfilter/nf_log.c
540
static void netfilter_log_sysctl_exit(struct net *net)
net/netfilter/nf_log.c
544
table = net->nf.nf_log_dir_header->ctl_table_arg;
net/netfilter/nf_log.c
545
unregister_net_sysctl_table(net->nf.nf_log_dir_header);
net/netfilter/nf_log.c
546
if (!net_eq(net, &init_net))
net/netfilter/nf_log.c
55
rcu_assign_pointer(net->nf.nf_loggers[pf], logger);
net/netfilter/nf_log.c
552
static int netfilter_log_sysctl_init(struct net *net)
net/netfilter/nf_log.c
557
static void netfilter_log_sysctl_exit(struct net *net)
net/netfilter/nf_log.c
562
static int __net_init nf_log_net_init(struct net *net)
net/netfilter/nf_log.c
567
if (!proc_create_net("nf_log", 0444, net->nf.proc_netfilter,
net/netfilter/nf_log.c
571
ret = netfilter_log_sysctl_init(net);
net/netfilter/nf_log.c
579
remove_proc_entry("nf_log", net->nf.proc_netfilter);
net/netfilter/nf_log.c
584
static void __net_exit nf_log_net_exit(struct net *net)
net/netfilter/nf_log.c
586
netfilter_log_sysctl_exit(net);
net/netfilter/nf_log.c
588
remove_proc_entry("nf_log", net->nf.proc_netfilter);
net/netfilter/nf_log.c
63
void nf_log_unset(struct net *net, const struct nf_logger *logger)
net/netfilter/nf_log.c
70
log = nft_log_dereference(net->nf.nf_loggers[i]);
net/netfilter/nf_log.c
72
RCU_INIT_POINTER(net->nf.nf_loggers[i], NULL);
net/netfilter/nf_log_syslog.c
1002
ret = nf_log_set(net, NFPROTO_BRIDGE, &nf_bridge_logger);
net/netfilter/nf_log_syslog.c
1007
nf_log_unset(net, &nf_netdev_logger);
net/netfilter/nf_log_syslog.c
1009
nf_log_unset(net, &nf_ip6_logger);
net/netfilter/nf_log_syslog.c
1011
nf_log_unset(net, &nf_arp_logger);
net/netfilter/nf_log_syslog.c
1013
nf_log_unset(net, &nf_ip_logger);
net/netfilter/nf_log_syslog.c
1017
static void __net_exit nf_log_syslog_net_exit(struct net *net)
net/netfilter/nf_log_syslog.c
1019
nf_log_unset(net, &nf_ip_logger);
net/netfilter/nf_log_syslog.c
1020
nf_log_unset(net, &nf_arp_logger);
net/netfilter/nf_log_syslog.c
1021
nf_log_unset(net, &nf_ip6_logger);
net/netfilter/nf_log_syslog.c
1022
nf_log_unset(net, &nf_netdev_logger);
net/netfilter/nf_log_syslog.c
1023
nf_log_unset(net, &nf_bridge_logger);
net/netfilter/nf_log_syslog.c
118
struct net *net)
net/netfilter/nf_log_syslog.c
128
physindev = nf_bridge_get_physindev(skb, net);
net/netfilter/nf_log_syslog.c
137
static void nf_log_arp_packet(struct net *net, u_int8_t pf,
net/netfilter/nf_log_syslog.c
146
if (!nf_log_allowed(net))
net/netfilter/nf_log_syslog.c
155
prefix, net);
net/netfilter/nf_log_syslog.c
168
static void nf_log_dump_sk_uid_gid(struct net *net, struct nf_log_buf *m,
net/netfilter/nf_log_syslog.c
174
if (!sk || !sk_fullsock(sk) || !net_eq(net, sock_net(sk)))
net/netfilter/nf_log_syslog.c
312
dump_ipv4_packet(struct net *net, struct nf_log_buf *m,
net/netfilter/nf_log_syslog.c
44
static bool nf_log_allowed(const struct net *net)
net/netfilter/nf_log_syslog.c
456
dump_ipv4_packet(net, m, info, skb,
net/netfilter/nf_log_syslog.c
46
return net_eq(net, &init_net) || sysctl_nf_log_all_netns;
net/netfilter/nf_log_syslog.c
524
nf_log_dump_sk_uid_gid(net, m, skb->sk);
net/netfilter/nf_log_syslog.c
546
dump_ipv6_packet(struct net *net, struct nf_log_buf *m,
net/netfilter/nf_log_syslog.c
761
dump_ipv6_packet(net, m, info, skb,
net/netfilter/nf_log_syslog.c
781
nf_log_dump_sk_uid_gid(net, m, skb->sk);
net/netfilter/nf_log_syslog.c
847
static void nf_log_ip_packet(struct net *net, u_int8_t pf,
net/netfilter/nf_log_syslog.c
856
if (!nf_log_allowed(net))
net/netfilter/nf_log_syslog.c
865
out, loginfo, prefix, net);
net/netfilter/nf_log_syslog.c
870
dump_ipv4_packet(net, m, loginfo, skb, skb_network_offset(skb));
net/netfilter/nf_log_syslog.c
882
static void nf_log_ip6_packet(struct net *net, u_int8_t pf,
net/netfilter/nf_log_syslog.c
891
if (!nf_log_allowed(net))
net/netfilter/nf_log_syslog.c
900
loginfo, prefix, net);
net/netfilter/nf_log_syslog.c
905
dump_ipv6_packet(net, m, loginfo, skb, skb_network_offset(skb), 1);
net/netfilter/nf_log_syslog.c
917
static void nf_log_unknown_packet(struct net *net, u_int8_t pf,
net/netfilter/nf_log_syslog.c
927
if (!nf_log_allowed(net))
net/netfilter/nf_log_syslog.c
936
prefix, net);
net/netfilter/nf_log_syslog.c
943
static void nf_log_netdev_packet(struct net *net, u_int8_t pf,
net/netfilter/nf_log_syslog.c
953
nf_log_ip_packet(net, pf, hooknum, skb, in, out, loginfo, prefix);
net/netfilter/nf_log_syslog.c
956
nf_log_ip6_packet(net, pf, hooknum, skb, in, out, loginfo, prefix);
net/netfilter/nf_log_syslog.c
960
nf_log_arp_packet(net, pf, hooknum, skb, in, out, loginfo, prefix);
net/netfilter/nf_log_syslog.c
963
nf_log_unknown_packet(net, pf, hooknum, skb,
net/netfilter/nf_log_syslog.c
983
static int __net_init nf_log_syslog_net_init(struct net *net)
net/netfilter/nf_log_syslog.c
985
int ret = nf_log_set(net, NFPROTO_IPV4, &nf_ip_logger);
net/netfilter/nf_log_syslog.c
990
ret = nf_log_set(net, NFPROTO_ARP, &nf_arp_logger);
net/netfilter/nf_log_syslog.c
994
ret = nf_log_set(net, NFPROTO_IPV6, &nf_ip6_logger);
net/netfilter/nf_log_syslog.c
998
ret = nf_log_set(net, NFPROTO_NETDEV, &nf_netdev_logger);
net/netfilter/nf_nat_core.c
1174
int nf_nat_register_fn(struct net *net, u8 pf, const struct nf_hook_ops *ops,
net/netfilter/nf_nat_core.c
1177
struct nat_net *nat_net = net_generic(net, nat_net_id);
net/netfilter/nf_nat_core.c
1232
ret = nf_register_net_hooks(net, nat_ops, ops_count);
net/netfilter/nf_nat_core.c
1261
void nf_nat_unregister_fn(struct net *net, u8 pf, const struct nf_hook_ops *ops,
net/netfilter/nf_nat_core.c
1264
struct nat_net *nat_net = net_generic(net, nat_net_id);
net/netfilter/nf_nat_core.c
1295
nf_unregister_net_hooks(net, nat_ops, ops_count);
net/netfilter/nf_nat_core.c
148
hash_by_src(const struct net *net,
net/netfilter/nf_nat_core.c
166
combined.net_mix = net_hash_mix(net);
net/netfilter/nf_nat_core.c
248
struct net *net;
net/netfilter/nf_nat_core.c
278
net = nf_ct_net(ignored_ct);
net/netfilter/nf_nat_core.c
281
thash = nf_conntrack_find_get(net, zone, tuple);
net/netfilter/nf_nat_core.c
286
thash = nf_conntrack_find_get(net, zone, &reply);
net/netfilter/nf_nat_core.c
343
struct net *net;
net/netfilter/nf_nat_core.c
357
net = nf_ct_net(ignored_conntrack);
net/netfilter/nf_nat_core.c
360
thash = nf_conntrack_find_get(net, zone, &reply);
net/netfilter/nf_nat_core.c
461
find_appropriate_src(struct net *net,
net/netfilter/nf_nat_core.c
467
unsigned int h = hash_by_src(net, zone, tuple);
net/netfilter/nf_nat_core.c
472
net_eq(net, nf_ct_net(ct)) &&
net/netfilter/nf_nat_core.c
696
struct net *net = nf_ct_net(ct);
net/netfilter/nf_nat_core.c
716
} else if (find_appropriate_src(net, zone,
net/netfilter/nf_nat_core.c
769
struct net *net = nf_ct_net(ct);
net/netfilter/nf_nat_core.c
814
srchash = hash_by_src(net, nf_ct_zone(ct),
net/netfilter/nf_nat_masquerade.c
101
static void nf_nat_masq_schedule(struct net *net, union nf_inet_addr *addr,
net/netfilter/nf_nat_masquerade.c
111
net = maybe_get_net(net);
net/netfilter/nf_nat_masquerade.c
112
if (!net)
net/netfilter/nf_nat_masquerade.c
125
w->net = net;
net/netfilter/nf_nat_masquerade.c
126
netns_tracker_alloc(net, &w->ns_tracker, gfp_flags);
net/netfilter/nf_nat_masquerade.c
136
put_net(net);
net/netfilter/nf_nat_masquerade.c
14
struct net *net;
net/netfilter/nf_nat_masquerade.c
154
struct net *net = dev_net(dev);
net/netfilter/nf_nat_masquerade.c
162
nf_nat_masq_schedule(net, NULL, dev->ifindex,
net/netfilter/nf_nat_masquerade.c
85
iter_data.net = w->net;
net/netfilter/nf_nat_masquerade.c
89
put_net_track(w->net, &w->ns_tracker);
net/netfilter/nf_nat_proto.c
1008
err = nf_ip6_route_me_harder(state->net, state->sk, skb);
net/netfilter/nf_nat_proto.c
1017
err = nf_xfrm_me_harder(state->net, skb, AF_INET6);
net/netfilter/nf_nat_proto.c
1058
int nf_nat_ipv6_register_fn(struct net *net, const struct nf_hook_ops *ops)
net/netfilter/nf_nat_proto.c
1060
return nf_nat_register_fn(net, ops->pf, ops, nf_nat_ipv6_ops,
net/netfilter/nf_nat_proto.c
1065
void nf_nat_ipv6_unregister_fn(struct net *net, const struct nf_hook_ops *ops)
net/netfilter/nf_nat_proto.c
1067
nf_nat_unregister_fn(net, ops->pf, ops, ARRAY_SIZE(nf_nat_ipv6_ops));
net/netfilter/nf_nat_proto.c
1073
int nf_nat_inet_register_fn(struct net *net, const struct nf_hook_ops *ops)
net/netfilter/nf_nat_proto.c
1080
ret = nf_nat_register_fn(net, NFPROTO_IPV6, ops, nf_nat_ipv6_ops,
net/netfilter/nf_nat_proto.c
1085
ret = nf_nat_register_fn(net, NFPROTO_IPV4, ops, nf_nat_ipv4_ops,
net/netfilter/nf_nat_proto.c
1088
nf_nat_unregister_fn(net, NFPROTO_IPV6, ops,
net/netfilter/nf_nat_proto.c
1094
void nf_nat_inet_unregister_fn(struct net *net, const struct nf_hook_ops *ops)
net/netfilter/nf_nat_proto.c
1096
nf_nat_unregister_fn(net, NFPROTO_IPV4, ops, ARRAY_SIZE(nf_nat_ipv4_ops));
net/netfilter/nf_nat_proto.c
1097
nf_nat_unregister_fn(net, NFPROTO_IPV6, ops, ARRAY_SIZE(nf_nat_ipv6_ops));
net/netfilter/nf_nat_proto.c
601
static int nf_xfrm_me_harder(struct net *net, struct sk_buff *skb, unsigned int family)
net/netfilter/nf_nat_proto.c
609
err = xfrm_decode_session(net, skb, &fl, family);
net/netfilter/nf_nat_proto.c
619
if (sk && !net_eq(net, sock_net(sk)))
net/netfilter/nf_nat_proto.c
622
dst = xfrm_lookup(net, dst, &fl, sk, 0);
net/netfilter/nf_nat_proto.c
720
err = nf_xfrm_me_harder(state->net, skb, AF_INET);
net/netfilter/nf_nat_proto.c
748
err = ip_route_me_harder(state->net, state->sk, skb, RTN_UNSPEC);
net/netfilter/nf_nat_proto.c
757
err = nf_xfrm_me_harder(state->net, skb, AF_INET);
net/netfilter/nf_nat_proto.c
797
int nf_nat_ipv4_register_fn(struct net *net, const struct nf_hook_ops *ops)
net/netfilter/nf_nat_proto.c
799
return nf_nat_register_fn(net, ops->pf, ops, nf_nat_ipv4_ops,
net/netfilter/nf_nat_proto.c
804
void nf_nat_ipv4_unregister_fn(struct net *net, const struct nf_hook_ops *ops)
net/netfilter/nf_nat_proto.c
806
nf_nat_unregister_fn(net, ops->pf, ops, ARRAY_SIZE(nf_nat_ipv4_ops));
net/netfilter/nf_nat_proto.c
979
err = nf_xfrm_me_harder(state->net, skb, AF_INET6);
net/netfilter/nf_queue.c
132
void nf_queue_nf_hook_drop(struct net *net)
net/netfilter/nf_queue.c
139
qh->nf_hook_drop(net);
net/netfilter/nf_queue.c
92
entry->physin = nf_bridge_get_physindev(skb, entry->state.net);
net/netfilter/nf_synproxy_core.c
1017
niph = synproxy_build_ip_ipv6(net, nskb, &iph->saddr, &iph->daddr);
net/netfilter/nf_synproxy_core.c
1033
synproxy_send_tcp_ipv6(net, skb, nskb, skb_nfct(skb),
net/netfilter/nf_synproxy_core.c
1039
synproxy_recv_client_ack_ipv6(struct net *net,
net/netfilter/nf_synproxy_core.c
1044
struct synproxy_net *snet = synproxy_pernet(net);
net/netfilter/nf_synproxy_core.c
1060
synproxy_send_server_syn_ipv6(net, skb, th, opts, recv_seq);
net/netfilter/nf_synproxy_core.c
1069
struct net *net = nhs->net;
net/netfilter/nf_synproxy_core.c
1070
struct synproxy_net *snet = synproxy_pernet(net);
net/netfilter/nf_synproxy_core.c
1133
if (synproxy_recv_client_ack_ipv6(net, skb, th, &opts,
net/netfilter/nf_synproxy_core.c
1166
synproxy_send_server_ack_ipv6(net, state, skb, th, &opts);
net/netfilter/nf_synproxy_core.c
1172
synproxy_send_client_ack_ipv6(net, skb, th, &opts);
net/netfilter/nf_synproxy_core.c
1203
nf_synproxy_ipv6_init(struct synproxy_net *snet, struct net *net)
net/netfilter/nf_synproxy_core.c
1209
err = nf_register_net_hooks(net, ipv6_synproxy_ops,
net/netfilter/nf_synproxy_core.c
1223
nf_synproxy_ipv6_fini(struct synproxy_net *snet, struct net *net)
net/netfilter/nf_synproxy_core.c
1228
nf_unregister_net_hooks(net, ipv6_synproxy_ops,
net/netfilter/nf_synproxy_core.c
309
static int __net_init synproxy_proc_init(struct net *net)
net/netfilter/nf_synproxy_core.c
311
if (!proc_create_net("synproxy", 0444, net->proc_net_stat,
net/netfilter/nf_synproxy_core.c
317
static void __net_exit synproxy_proc_exit(struct net *net)
net/netfilter/nf_synproxy_core.c
319
remove_proc_entry("synproxy", net->proc_net_stat);
net/netfilter/nf_synproxy_core.c
322
static int __net_init synproxy_proc_init(struct net *net)
net/netfilter/nf_synproxy_core.c
327
static void __net_exit synproxy_proc_exit(struct net *net)
net/netfilter/nf_synproxy_core.c
333
static int __net_init synproxy_net_init(struct net *net)
net/netfilter/nf_synproxy_core.c
335
struct synproxy_net *snet = synproxy_pernet(net);
net/netfilter/nf_synproxy_core.c
339
ct = nf_ct_tmpl_alloc(net, &nf_ct_zone_dflt, GFP_KERNEL);
net/netfilter/nf_synproxy_core.c
355
err = synproxy_proc_init(net);
net/netfilter/nf_synproxy_core.c
369
static void __net_exit synproxy_net_exit(struct net *net)
net/netfilter/nf_synproxy_core.c
371
struct synproxy_net *snet = synproxy_pernet(net);
net/netfilter/nf_synproxy_core.c
374
synproxy_proc_exit(net);
net/netfilter/nf_synproxy_core.c
399
synproxy_build_ip(struct net *net, struct sk_buff *skb, __be32 saddr,
net/netfilter/nf_synproxy_core.c
411
iph->ttl = READ_ONCE(net->ipv4.sysctl_ip_default_ttl);
net/netfilter/nf_synproxy_core.c
421
synproxy_send_tcp(struct net *net,
net/netfilter/nf_synproxy_core.c
434
if (ip_route_me_harder(net, nskb->sk, nskb, RTN_UNSPEC))
net/netfilter/nf_synproxy_core.c
442
ip_local_out(net, nskb->sk, nskb);
net/netfilter/nf_synproxy_core.c
450
synproxy_send_client_synack(struct net *net,
net/netfilter/nf_synproxy_core.c
469
niph = synproxy_build_ip(net, nskb, iph->daddr, iph->saddr);
net/netfilter/nf_synproxy_core.c
487
synproxy_send_tcp(net, skb, nskb, skb_nfct(skb),
net/netfilter/nf_synproxy_core.c
493
synproxy_send_server_syn(struct net *net,
net/netfilter/nf_synproxy_core.c
497
struct synproxy_net *snet = synproxy_pernet(net);
net/netfilter/nf_synproxy_core.c
512
niph = synproxy_build_ip(net, nskb, iph->saddr, iph->daddr);
net/netfilter/nf_synproxy_core.c
533
synproxy_send_tcp(net, skb, nskb, &snet->tmpl->ct_general, IP_CT_NEW,
net/netfilter/nf_synproxy_core.c
538
synproxy_send_server_ack(struct net *net,
net/netfilter/nf_synproxy_core.c
557
niph = synproxy_build_ip(net, nskb, iph->daddr, iph->saddr);
net/netfilter/nf_synproxy_core.c
573
synproxy_send_tcp(net, skb, nskb, NULL, 0, niph, nth, tcp_hdr_size);
net/netfilter/nf_synproxy_core.c
577
synproxy_send_client_ack(struct net *net,
net/netfilter/nf_synproxy_core.c
595
niph = synproxy_build_ip(net, nskb, iph->saddr, iph->daddr);
net/netfilter/nf_synproxy_core.c
611
synproxy_send_tcp(net, skb, nskb, skb_nfct(skb),
net/netfilter/nf_synproxy_core.c
616
synproxy_recv_client_ack(struct net *net,
net/netfilter/nf_synproxy_core.c
620
struct synproxy_net *snet = synproxy_pernet(net);
net/netfilter/nf_synproxy_core.c
636
synproxy_send_server_syn(net, skb, th, opts, recv_seq);
net/netfilter/nf_synproxy_core.c
645
struct net *net = nhs->net;
net/netfilter/nf_synproxy_core.c
646
struct synproxy_net *snet = synproxy_pernet(net);
net/netfilter/nf_synproxy_core.c
703
if (synproxy_recv_client_ack(net, skb, th, &opts,
net/netfilter/nf_synproxy_core.c
736
synproxy_send_server_ack(net, state, skb, th, &opts);
net/netfilter/nf_synproxy_core.c
742
synproxy_send_client_ack(net, skb, th, &opts);
net/netfilter/nf_synproxy_core.c
772
int nf_synproxy_ipv4_init(struct synproxy_net *snet, struct net *net)
net/netfilter/nf_synproxy_core.c
778
err = nf_register_net_hooks(net, ipv4_synproxy_ops,
net/netfilter/nf_synproxy_core.c
791
void nf_synproxy_ipv4_fini(struct synproxy_net *snet, struct net *net)
net/netfilter/nf_synproxy_core.c
796
nf_unregister_net_hooks(net, ipv4_synproxy_ops,
net/netfilter/nf_synproxy_core.c
804
synproxy_build_ip_ipv6(struct net *net, struct sk_buff *skb,
net/netfilter/nf_synproxy_core.c
813
iph->hop_limit = READ_ONCE(net->ipv6.devconf_all->hop_limit);
net/netfilter/nf_synproxy_core.c
822
synproxy_send_tcp_ipv6(struct net *net,
net/netfilter/nf_synproxy_core.c
845
err = nf_ip6_route(net, &dst, flowi6_to_flowi(&fl6), false);
net/netfilter/nf_synproxy_core.c
850
dst = xfrm_lookup(net, dst, flowi6_to_flowi(&fl6), NULL, 0);
net/netfilter/nf_synproxy_core.c
861
ip6_local_out(net, nskb->sk, nskb);
net/netfilter/nf_synproxy_core.c
869
synproxy_send_client_synack_ipv6(struct net *net,
net/netfilter/nf_synproxy_core.c
889
niph = synproxy_build_ip_ipv6(net, nskb, &iph->daddr, &iph->saddr);
net/netfilter/nf_synproxy_core.c
907
synproxy_send_tcp_ipv6(net, skb, nskb, skb_nfct(skb),
net/netfilter/nf_synproxy_core.c
914
synproxy_send_server_syn_ipv6(struct net *net, const struct sk_buff *skb,
net/netfilter/nf_synproxy_core.c
918
struct synproxy_net *snet = synproxy_pernet(net);
net/netfilter/nf_synproxy_core.c
933
niph = synproxy_build_ip_ipv6(net, nskb, &iph->saddr, &iph->daddr);
net/netfilter/nf_synproxy_core.c
954
synproxy_send_tcp_ipv6(net, skb, nskb, &snet->tmpl->ct_general,
net/netfilter/nf_synproxy_core.c
959
synproxy_send_server_ack_ipv6(struct net *net, const struct ip_ct_tcp *state,
net/netfilter/nf_synproxy_core.c
978
niph = synproxy_build_ip_ipv6(net, nskb, &iph->daddr, &iph->saddr);
net/netfilter/nf_synproxy_core.c
994
synproxy_send_tcp_ipv6(net, skb, nskb, NULL, 0, niph, nth,
net/netfilter/nf_synproxy_core.c
999
synproxy_send_client_ack_ipv6(struct net *net, const struct sk_buff *skb,
net/netfilter/nf_tables_api.c
1008
static struct nft_table *nft_table_lookup_byhandle(const struct net *net,
net/netfilter/nf_tables_api.c
10111
static int nf_tables_validate(struct net *net)
net/netfilter/nf_tables_api.c
10113
struct nftables_pernet *nft_net = nft_pernet(net);
net/netfilter/nf_tables_api.c
10124
if (nft_table_validate(net, table) < 0)
net/netfilter/nf_tables_api.c
1015
nft_net = nft_pernet(net);
net/netfilter/nf_tables_api.c
10206
.net = trans->net,
net/netfilter/nf_tables_api.c
10249
put_net(trans->net);
net/netfilter/nf_tables_api.c
10275
void nf_tables_trans_destroy_flush_work(struct net *net)
net/netfilter/nf_tables_api.c
10277
struct nftables_pernet *nft_net = nft_pernet(net);
net/netfilter/nf_tables_api.c
10283
static int nf_tables_commit_chain_prepare(struct net *net, struct nft_chain *chain)
net/netfilter/nf_tables_api.c
10292
if (chain->blob_next || !nft_is_active_next(net, chain))
net/netfilter/nf_tables_api.c
10297
if (nft_is_active_next(net, rule)) {
net/netfilter/nf_tables_api.c
10313
if (!nft_is_active_next(net, rule))
net/netfilter/nf_tables_api.c
10358
static void nf_tables_commit_chain_prepare_cancel(struct net *net)
net/netfilter/nf_tables_api.c
10360
struct nftables_pernet *nft_net = nft_pernet(net);
net/netfilter/nf_tables_api.c
10392
static void nf_tables_commit_chain(struct net *net, struct nft_chain *chain)
net/netfilter/nf_tables_api.c
10397
next_genbit = nft_gencursor_next(net);
net/netfilter/nf_tables_api.c
10400
lockdep_commit_lock_is_held(net));
net/netfilter/nf_tables_api.c
10402
lockdep_commit_lock_is_held(net));
net/netfilter/nf_tables_api.c
10462
nft_setelem_data_deactivate(ctx->net, trans->set, priv[i]);
net/netfilter/nf_tables_api.c
10463
nft_setelem_remove(ctx->net, trans->set, priv[i]);
net/netfilter/nf_tables_api.c
10470
put_net(trans->net);
net/netfilter/nf_tables_api.c
10482
ctx.net = read_pnet(&trans->set->net);
net/netfilter/nf_tables_api.c
10500
nft_net = nft_pernet(trans->net);
net/netfilter/nf_tables_api.c
10514
ctx.net = trans->net;
net/netfilter/nf_tables_api.c
10545
struct net *net = read_pnet(&set->net);
net/netfilter/nf_tables_api.c
10552
trans->net = maybe_get_net(net);
net/netfilter/nf_tables_api.c
10553
if (!trans->net) {
net/netfilter/nf_tables_api.c
10607
if (WARN_ON_ONCE(!lockdep_commit_lock_is_held(gc->net)))
net/netfilter/nf_tables_api.c
10621
WARN_ON_ONCE(!lockdep_commit_lock_is_held(trans->net));
net/netfilter/nf_tables_api.c
10661
u64 tstamp = nft_net_tstamp(gc->net);
net/netfilter/nf_tables_api.c
10666
WARN_ON_ONCE(!lockdep_commit_lock_is_held(gc->net));
net/netfilter/nf_tables_api.c
10679
nft_setelem_data_deactivate(gc->net, gc->set, elem_priv);
net/netfilter/nf_tables_api.c
10687
static void nf_tables_module_autoload_cleanup(struct net *net)
net/netfilter/nf_tables_api.c
10689
struct nftables_pernet *nft_net = nft_pernet(net);
net/netfilter/nf_tables_api.c
10700
static void nf_tables_commit_release(struct net *net)
net/netfilter/nf_tables_api.c
10702
struct nftables_pernet *nft_net = nft_pernet(net);
net/netfilter/nf_tables_api.c
1071
__printf(2, 3) int nft_request_module(struct net *net, const char *fmt,
net/netfilter/nf_tables_api.c
10713
nf_tables_module_autoload_cleanup(net);
net/netfilter/nf_tables_api.c
10720
get_net(trans->net);
net/netfilter/nf_tables_api.c
10728
nf_tables_module_autoload_cleanup(net);
net/netfilter/nf_tables_api.c
10734
static void nft_commit_notify(struct net *net, u32 portid)
net/netfilter/nf_tables_api.c
10736
struct nftables_pernet *nft_net = nft_pernet(net);
net/netfilter/nf_tables_api.c
10757
nfnetlink_send(batch_skb, net, portid, NFNLGRP_NFTABLES,
net/netfilter/nf_tables_api.c
10763
nfnetlink_send(batch_skb, net, portid, NFNLGRP_NFTABLES,
net/netfilter/nf_tables_api.c
1086
nft_net = nft_pernet(net);
net/netfilter/nf_tables_api.c
10876
static int nf_tables_commit(struct net *net, struct sk_buff *skb)
net/netfilter/nf_tables_api.c
10878
struct nftables_pernet *nft_net = nft_pernet(net);
net/netfilter/nf_tables_api.c
10896
nft_ctx_init(&ctx, net, skb, nlh, NFPROTO_UNSPEC, NULL, NULL, NULL);
net/netfilter/nf_tables_api.c
10924
if (nf_tables_validate(net) < 0) {
net/netfilter/nf_tables_api.c
10929
err = nft_flow_rule_offload_commit(net);
net/netfilter/nf_tables_api.c
10940
nf_tables_commit_chain_prepare_cancel(net);
net/netfilter/nf_tables_api.c
10948
ret = nf_tables_commit_chain_prepare(net, chain);
net/netfilter/nf_tables_api.c
10950
nf_tables_commit_chain_prepare_cancel(net);
net/netfilter/nf_tables_api.c
10960
nf_tables_commit_chain(net, chain);
net/netfilter/nf_tables_api.c
10967
base_seq = nft_base_seq(net);
net/netfilter/nf_tables_api.c
10972
smp_store_release(&net->nft.base_seq, base_seq);
net/netfilter/nf_tables_api.c
10977
net->nft.gencursor = nft_gencursor_next(net);
net/netfilter/nf_tables_api.c
10993
nf_tables_table_disable(net, table);
net/netfilter/nf_tables_api.c
10997
nft_clear(net, table);
net/netfilter/nf_tables_api.c
11017
nft_clear(net, nft_trans_chain(trans));
net/netfilter/nf_tables_api.c
11027
nft_netdev_unregister_trans_hook(net, table,
net/netfilter/nf_tables_api.c
11033
nf_tables_unregister_hook(ctx.net, ctx.table,
net/netfilter/nf_tables_api.c
11038
nft_clear(net, nft_trans_rule(trans));
net/netfilter/nf_tables_api.c
11068
nft_clear(net, nft_trans_set(trans));
net/netfilter/nf_tables_api.c
11118
nft_clear(net, nft_trans_obj(trans));
net/netfilter/nf_tables_api.c
11143
nft_clear(net, nft_trans_flowtable(trans));
net/netfilter/nf_tables_api.c
11160
nft_flowtable_unregister_trans_hook(net,
net/netfilter/nf_tables_api.c
11170
nft_unregister_flowtable_net_hooks(net,
net/netfilter/nf_tables_api.c
11180
nft_commit_notify(net, NETLINK_CB(skb).portid);
net/netfilter/nf_tables_api.c
11181
nf_tables_gen_notify(net, skb, NFT_MSG_NEWGEN);
net/netfilter/nf_tables_api.c
11182
nf_tables_commit_audit_log(&adl, nft_base_seq(net));
net/netfilter/nf_tables_api.c
11186
nf_tables_commit_release(net);
net/netfilter/nf_tables_api.c
1119
nf_tables_chain_type_lookup(struct net *net, const struct nlattr *nla,
net/netfilter/nf_tables_api.c
11191
static void nf_tables_module_autoload(struct net *net)
net/netfilter/nf_tables_api.c
11193
struct nftables_pernet *nft_net = nft_pernet(net);
net/netfilter/nf_tables_api.c
11259
static int __nf_tables_abort(struct net *net, enum nfnl_abort_action action)
net/netfilter/nf_tables_api.c
11261
struct nftables_pernet *nft_net = nft_pernet(net);
net/netfilter/nf_tables_api.c
11266
.net = net,
net/netfilter/nf_tables_api.c
11271
nf_tables_validate(net) < 0)
net/netfilter/nf_tables_api.c
11288
nf_tables_table_disable(net, table);
net/netfilter/nf_tables_api.c
11305
nft_clear(trans->net, table);
net/netfilter/nf_tables_api.c
1131
if (nft_request_module(net, "nft-chain-%u-%.*s", family,
net/netfilter/nf_tables_api.c
11310
nft_netdev_unregister_hooks(net, table,
net/netfilter/nf_tables_api.c
11323
nf_tables_unregister_hook(trans->net, table,
net/netfilter/nf_tables_api.c
11333
nft_clear(trans->net, nft_trans_chain(trans));
net/netfilter/nf_tables_api.c
11353
nft_clear(trans->net, nft_trans_rule(trans));
net/netfilter/nf_tables_api.c
11377
nft_clear(trans->net, nft_trans_set(trans));
net/netfilter/nf_tables_api.c
1140
static unsigned int nft_base_seq(const struct net *net)
net/netfilter/nf_tables_api.c
1142
return READ_ONCE(net->nft.base_seq);
net/netfilter/nf_tables_api.c
11425
nft_clear(trans->net, nft_trans_obj(trans));
net/netfilter/nf_tables_api.c
11430
nft_unregister_flowtable_net_hooks(net,
net/netfilter/nf_tables_api.c
11436
nft_unregister_flowtable_net_hooks(net,
net/netfilter/nf_tables_api.c
11447
nft_clear(trans->net, nft_trans_flowtable(trans));
net/netfilter/nf_tables_api.c
1145
static __be16 nft_base_seq_be16(const struct net *net)
net/netfilter/nf_tables_api.c
11469
static int nf_tables_abort(struct net *net, struct sk_buff *skb,
net/netfilter/nf_tables_api.c
1147
return htons(nft_base_seq(net) & 0xffff);
net/netfilter/nf_tables_api.c
11472
struct nftables_pernet *nft_net = nft_pernet(net);
net/netfilter/nf_tables_api.c
11477
ret = __nf_tables_abort(net, action);
net/netfilter/nf_tables_api.c
11493
nf_tables_module_autoload(net);
net/netfilter/nf_tables_api.c
11495
nf_tables_module_autoload_cleanup(net);
net/netfilter/nf_tables_api.c
11502
static bool nf_tables_valid_genid(struct net *net, u32 genid)
net/netfilter/nf_tables_api.c
11504
struct nftables_pernet *nft_net = nft_pernet(net);
net/netfilter/nf_tables_api.c
11510
genid_ok = genid == 0 || nft_base_seq(net) == genid;
net/netfilter/nf_tables_api.c
1159
static int nf_tables_fill_table_info(struct sk_buff *skb, struct net *net,
net/netfilter/nf_tables_api.c
1167
flags, family, NFNETLINK_V0, nft_base_seq_be16(net));
net/netfilter/nf_tables_api.c
11746
u8 genmask = nft_genmask_next(ctx->net);
net/netfilter/nf_tables_api.c
11773
chain = nft_chain_lookup(ctx->net, ctx->table,
net/netfilter/nf_tables_api.c
11777
chain = nft_chain_lookup_byid(ctx->net, ctx->table,
net/netfilter/nf_tables_api.c
11981
static void __nft_release_hook(struct net *net, struct nft_table *table)
net/netfilter/nf_tables_api.c
11987
__nf_tables_unregister_hook(net, table, chain, true);
net/netfilter/nf_tables_api.c
11989
__nft_unregister_flowtable_net_hooks(net, flowtable,
net/netfilter/nf_tables_api.c
11994
static void __nft_release_hooks(struct net *net)
net/netfilter/nf_tables_api.c
11996
struct nftables_pernet *nft_net = nft_pernet(net);
net/netfilter/nf_tables_api.c
12003
__nft_release_hook(net, table);
net/netfilter/nf_tables_api.c
12007
static void __nft_release_table(struct net *net, struct nft_table *table)
net/netfilter/nf_tables_api.c
12015
.net = net,
net/netfilter/nf_tables_api.c
12058
static void __nft_release_tables(struct net *net)
net/netfilter/nf_tables_api.c
12060
struct nftables_pernet *nft_net = nft_pernet(net);
net/netfilter/nf_tables_api.c
12069
__nft_release_table(net, table);
net/netfilter/nf_tables_api.c
12079
struct net *net = n->net;
net/netfilter/nf_tables_api.c
12087
nft_net = nft_pernet(net);
net/netfilter/nf_tables_api.c
12093
nf_tables_trans_destroy_flush_work(net);
net/netfilter/nf_tables_api.c
12102
__nft_release_hook(net, table);
net/netfilter/nf_tables_api.c
12113
__nft_release_table(net, to_delete[--deleted]);
net/netfilter/nf_tables_api.c
12129
static int __net_init nf_tables_init_net(struct net *net)
net/netfilter/nf_tables_api.c
12131
struct nftables_pernet *nft_net = nft_pernet(net);
net/netfilter/nf_tables_api.c
12141
net->nft.base_seq = 1;
net/netfilter/nf_tables_api.c
12149
static void __net_exit nf_tables_pre_exit_net(struct net *net)
net/netfilter/nf_tables_api.c
12151
struct nftables_pernet *nft_net = nft_pernet(net);
net/netfilter/nf_tables_api.c
12154
__nft_release_hooks(net);
net/netfilter/nf_tables_api.c
12158
static void __net_exit nf_tables_exit_net(struct net *net)
net/netfilter/nf_tables_api.c
12160
struct nftables_pernet *nft_net = nft_pernet(net);
net/netfilter/nf_tables_api.c
12171
nf_tables_module_autoload_cleanup(net);
net/netfilter/nf_tables_api.c
12174
__nft_release_tables(net);
net/netfilter/nf_tables_api.c
1224
!nfnetlink_has_listeners(ctx->net, NFNLGRP_NFTABLES))
net/netfilter/nf_tables_api.c
1234
err = nf_tables_fill_table_info(skb, ctx->net, ctx->portid, ctx->seq,
net/netfilter/nf_tables_api.c
1241
nft_net = nft_pernet(ctx->net);
net/netfilter/nf_tables_api.c
1245
nfnetlink_set_err(ctx->net, ctx->portid, NFNLGRP_NFTABLES, -ENOBUFS);
net/netfilter/nf_tables_api.c
1255
struct net *net = sock_net(skb->sk);
net/netfilter/nf_tables_api.c
1259
nft_net = nft_pernet(net);
net/netfilter/nf_tables_api.c
1260
cb->seq = nft_base_seq(net);
net/netfilter/nf_tables_api.c
1271
if (!nft_is_active(net, table))
net/netfilter/nf_tables_api.c
1273
if (nf_tables_fill_table_info(skb, net,
net/netfilter/nf_tables_api.c
1312
u8 genmask = nft_genmask_cur(info->net);
net/netfilter/nf_tables_api.c
1315
struct net *net = info->net;
net/netfilter/nf_tables_api.c
1328
table = nft_table_lookup(net, nla[NFTA_TABLE_NAME], family, genmask, 0);
net/netfilter/nf_tables_api.c
1338
err = nf_tables_fill_table_info(skb2, net, NETLINK_CB(skb).portid,
net/netfilter/nf_tables_api.c
1344
return nfnetlink_unicast(skb2, net, NETLINK_CB(skb).portid);
net/netfilter/nf_tables_api.c
1351
static void nft_table_disable(struct net *net, struct nft_table *table, u32 cnt)
net/netfilter/nf_tables_api.c
1357
if (!nft_is_active_next(net, chain))
net/netfilter/nf_tables_api.c
1365
nf_tables_unregister_hook(net, table, chain);
net/netfilter/nf_tables_api.c
1369
static int nf_tables_table_enable(struct net *net, struct nft_table *table)
net/netfilter/nf_tables_api.c
1375
if (!nft_is_active_next(net, chain))
net/netfilter/nf_tables_api.c
1380
err = nf_tables_register_hook(net, table, chain);
net/netfilter/nf_tables_api.c
1390
nft_table_disable(net, table, i);
net/netfilter/nf_tables_api.c
1394
static void nf_tables_table_disable(struct net *net, struct nft_table *table)
net/netfilter/nf_tables_api.c
1397
nft_table_disable(net, table, 0);
net/netfilter/nf_tables_api.c
1411
struct nftables_pernet *nft_net = nft_pernet(ctx->net);
net/netfilter/nf_tables_api.c
1472
ret = nf_tables_table_enable(ctx->net, ctx->table);
net/netfilter/nf_tables_api.c
1488
nft_trans_commit_list_add_tail(ctx->net, trans);
net/netfilter/nf_tables_api.c
156
struct net *net,
net/netfilter/nf_tables_api.c
1576
struct nftables_pernet *nft_net = nft_pernet(info->net);
net/netfilter/nf_tables_api.c
1578
u8 genmask = nft_genmask_next(info->net);
net/netfilter/nf_tables_api.c
1580
struct net *net = info->net;
net/netfilter/nf_tables_api.c
1592
table = nft_table_lookup(net, attr, family, genmask,
net/netfilter/nf_tables_api.c
1605
nft_ctx_init(&ctx, net, skb, info->nlh, family, table, NULL, nla);
net/netfilter/nf_tables_api.c
164
ctx->net = net;
net/netfilter/nf_tables_api.c
1648
nft_ctx_init(&ctx, net, skb, info->nlh, family, table, NULL, nla);
net/netfilter/nf_tables_api.c
1676
if (!nft_is_active_next(ctx->net, chain))
net/netfilter/nf_tables_api.c
1690
if (!nft_is_active_next(ctx->net, set))
net/netfilter/nf_tables_api.c
1702
if (!nft_is_active_next(ctx->net, flowtable))
net/netfilter/nf_tables_api.c
1711
if (!nft_is_active_next(ctx->net, obj))
net/netfilter/nf_tables_api.c
1720
if (!nft_is_active_next(ctx->net, chain))
net/netfilter/nf_tables_api.c
1740
struct nftables_pernet *nft_net = nft_pernet(ctx->net);
net/netfilter/nf_tables_api.c
1751
if (!nft_is_active_next(ctx->net, table))
net/netfilter/nf_tables_api.c
1775
u8 genmask = nft_genmask_next(info->net);
net/netfilter/nf_tables_api.c
1777
struct net *net = info->net;
net/netfilter/nf_tables_api.c
1782
nft_ctx_init(&ctx, net, skb, info->nlh, 0, NULL, NULL, nla);
net/netfilter/nf_tables_api.c
1789
table = nft_table_lookup_byhandle(net, attr, family, genmask,
net/netfilter/nf_tables_api.c
1793
table = nft_table_lookup(net, attr, family, genmask,
net/netfilter/nf_tables_api.c
1865
static bool lockdep_commit_lock_is_held(const struct net *net)
net/netfilter/nf_tables_api.c
1868
struct nftables_pernet *nft_net = nft_pernet(net);
net/netfilter/nf_tables_api.c
1876
static struct nft_chain *nft_chain_lookup(struct net *net,
net/netfilter/nf_tables_api.c
1890
!lockdep_commit_lock_is_held(net));
net/netfilter/nf_tables_api.c
190
trans->net = ctx->net;
net/netfilter/nf_tables_api.c
2004
const struct net *net,
net/netfilter/nf_tables_api.c
2012
lockdep_commit_lock_is_held(net)) {
net/netfilter/nf_tables_api.c
2038
const struct net *net, int family,
net/netfilter/nf_tables_api.c
2064
nft_dump_basechain_hook_list(skb, net, hook_list, &dump_hook_ctx)) {
net/netfilter/nf_tables_api.c
2086
static int nf_tables_fill_chain_info(struct sk_buff *skb, struct net *net,
net/netfilter/nf_tables_api.c
2097
flags, family, NFNETLINK_V0, nft_base_seq_be16(net));
net/netfilter/nf_tables_api.c
2118
if (nft_dump_basechain_hook(skb, net, family, basechain,
net/netfilter/nf_tables_api.c
2130
lockdep_commit_lock_is_held(net));
net/netfilter/nf_tables_api.c
2164
!nfnetlink_has_listeners(ctx->net, NFNLGRP_NFTABLES))
net/netfilter/nf_tables_api.c
2174
err = nf_tables_fill_chain_info(skb, ctx->net, ctx->portid, ctx->seq,
net/netfilter/nf_tables_api.c
2182
nft_net = nft_pernet(ctx->net);
net/netfilter/nf_tables_api.c
2186
nfnetlink_set_err(ctx->net, ctx->portid, NFNLGRP_NFTABLES, -ENOBUFS);
net/netfilter/nf_tables_api.c
2194
struct net *net = sock_net(skb->sk);
net/netfilter/nf_tables_api.c
2201
nft_net = nft_pernet(net);
net/netfilter/nf_tables_api.c
2202
cb->seq = nft_base_seq(net);
net/netfilter/nf_tables_api.c
2214
if (!nft_is_active(net, chain))
net/netfilter/nf_tables_api.c
2216
if (nf_tables_fill_chain_info(skb, net,
net/netfilter/nf_tables_api.c
2241
u8 genmask = nft_genmask_cur(info->net);
net/netfilter/nf_tables_api.c
2244
struct net *net = info->net;
net/netfilter/nf_tables_api.c
2258
table = nft_table_lookup(net, nla[NFTA_CHAIN_TABLE], family, genmask, 0);
net/netfilter/nf_tables_api.c
2264
chain = nft_chain_lookup(net, table, nla[NFTA_CHAIN_NAME], genmask);
net/netfilter/nf_tables_api.c
2274
err = nf_tables_fill_chain_info(skb2, net, NETLINK_CB(skb).portid,
net/netfilter/nf_tables_api.c
2280
return nfnetlink_unicast(skb2, net, NETLINK_CB(skb).portid);
net/netfilter/nf_tables_api.c
231
struct net *net = ctx->net;
net/netfilter/nf_tables_api.c
2333
lockdep_commit_lock_is_held(t->net));
net/netfilter/nf_tables_api.c
237
nft_net = nft_pernet(net);
net/netfilter/nf_tables_api.c
2387
static struct nft_hook *nft_netdev_hook_alloc(struct net *net,
net/netfilter/nf_tables_api.c
2413
for_each_netdev(net, dev) {
net/netfilter/nf_tables_api.c
2450
static int nf_tables_parse_netdev_hooks(struct net *net,
net/netfilter/nf_tables_api.c
2473
hook = nft_netdev_hook_alloc(net, tmp, prefix);
net/netfilter/nf_tables_api.c
2511
static int nft_chain_parse_netdev(struct net *net, struct nlattr *tb[],
net/netfilter/nf_tables_api.c
2519
hook = nft_netdev_hook_alloc(net, tb[NFTA_HOOK_DEV], false);
net/netfilter/nf_tables_api.c
2527
err = nf_tables_parse_netdev_hooks(net, tb[NFTA_HOOK_DEVS],
net/netfilter/nf_tables_api.c
2541
static int nft_chain_parse_hook(struct net *net,
net/netfilter/nf_tables_api.c
2547
struct nftables_pernet *nft_net = nft_pernet(net);
net/netfilter/nf_tables_api.c
2576
type = nf_tables_chain_type_lookup(net, nla[NFTA_CHAIN_TYPE],
net/netfilter/nf_tables_api.c
2623
err = nft_chain_parse_netdev(net, ha, &hook->list, extack, flags);
net/netfilter/nf_tables_api.c
266
struct net *net = ctx->net;
net/netfilter/nf_tables_api.c
272
nft_net = nft_pernet(net);
net/netfilter/nf_tables_api.c
2746
struct net *net = ctx->net;
net/netfilter/nf_tables_api.c
2763
err = nft_chain_parse_hook(net, NULL, nla, &hook, family, flags,
net/netfilter/nf_tables_api.c
2867
err = nf_tables_register_hook(net, table, chain);
net/netfilter/nf_tables_api.c
2915
err = nft_chain_parse_hook(ctx->net, basechain, nla, &hook,
net/netfilter/nf_tables_api.c
2942
nft_net = nft_pernet(ctx->net);
net/netfilter/nf_tables_api.c
2970
chain2 = nft_chain_lookup(ctx->net, table,
net/netfilter/nf_tables_api.c
2993
err = nft_netdev_register_hooks(ctx->net, &hook.list);
net/netfilter/nf_tables_api.c
3029
struct nftables_pernet *nft_net = nft_pernet(ctx->net);
net/netfilter/nf_tables_api.c
3060
nft_trans_commit_list_add_tail(ctx->net, trans);
net/netfilter/nf_tables_api.c
3072
nf_unregister_net_hook(ctx->net, ops);
net/netfilter/nf_tables_api.c
3084
static struct nft_chain *nft_chain_lookup_byid(const struct net *net,
net/netfilter/nf_tables_api.c
3088
struct nftables_pernet *nft_net = nft_pernet(net);
net/netfilter/nf_tables_api.c
3105
struct nftables_pernet *nft_net = nft_pernet(info->net);
net/netfilter/nf_tables_api.c
3107
u8 genmask = nft_genmask_next(info->net);
net/netfilter/nf_tables_api.c
3110
struct net *net = info->net;
net/netfilter/nf_tables_api.c
3120
table = nft_table_lookup(net, nla[NFTA_CHAIN_TABLE], family, genmask,
net/netfilter/nf_tables_api.c
3139
chain = nft_chain_lookup(net, table, attr, genmask);
net/netfilter/nf_tables_api.c
318
static int nft_netdev_register_hooks(struct net *net,
net/netfilter/nf_tables_api.c
3182
nft_ctx_init(&ctx, net, skb, info->nlh, family, table, chain, nla);
net/netfilter/nf_tables_api.c
3244
err = nft_chain_parse_hook(ctx->net, basechain, nla, &chain_hook,
net/netfilter/nf_tables_api.c
3273
nft_trans_commit_list_add_tail(ctx->net, trans);
net/netfilter/nf_tables_api.c
328
err = nf_register_net_hook(net, ops);
net/netfilter/nf_tables_api.c
3288
u8 genmask = nft_genmask_next(info->net);
net/netfilter/nf_tables_api.c
3290
struct net *net = info->net;
net/netfilter/nf_tables_api.c
3300
table = nft_table_lookup(net, nla[NFTA_CHAIN_TABLE], family, genmask,
net/netfilter/nf_tables_api.c
3313
chain = nft_chain_lookup(net, table, attr, genmask);
net/netfilter/nf_tables_api.c
3327
nft_ctx_init(&ctx, net, skb, info->nlh, family, table, chain, nla);
net/netfilter/nf_tables_api.c
3348
if (!nft_is_active_next(net, rule))
net/netfilter/nf_tables_api.c
3427
static int nft_expr_type_request_module(struct net *net, u8 family,
net/netfilter/nf_tables_api.c
343
nf_unregister_net_hook(net, ops);
net/netfilter/nf_tables_api.c
3430
if (nft_request_module(net, "nft-expr-%u-%.*s", family,
net/netfilter/nf_tables_api.c
3438
static const struct nft_expr_type *nft_expr_type_get(struct net *net,
net/netfilter/nf_tables_api.c
3458
if (nft_expr_type_request_module(net, family, nla) == -EAGAIN)
net/netfilter/nf_tables_api.c
3461
if (nft_request_module(net, "nft-expr-%.*s",
net/netfilter/nf_tables_api.c
3535
type = nft_expr_type_get(ctx->net, ctx->family, tb[NFTA_EXPR_NAME]);
net/netfilter/nf_tables_api.c
3555
if (nft_expr_type_request_module(ctx->net,
net/netfilter/nf_tables_api.c
3721
static struct nft_rule *__nft_rule_lookup(const struct net *net,
net/netfilter/nf_tables_api.c
3729
lockdep_commit_lock_is_held(net)) {
net/netfilter/nf_tables_api.c
3737
static struct nft_rule *nft_rule_lookup(const struct net *net,
net/netfilter/nf_tables_api.c
3744
return __nft_rule_lookup(net, chain, be64_to_cpu(nla_get_be64(nla)));
net/netfilter/nf_tables_api.c
3763
static int nf_tables_fill_rule_info(struct sk_buff *skb, struct net *net,
net/netfilter/nf_tables_api.c
3777
nft_base_seq_be16(net));
net/netfilter/nf_tables_api.c
3825
struct nftables_pernet *nft_net = nft_pernet(ctx->net);
net/netfilter/nf_tables_api.c
3833
!nfnetlink_has_listeners(ctx->net, NFNLGRP_NFTABLES))
net/netfilter/nf_tables_api.c
3851
err = nf_tables_fill_rule_info(skb, ctx->net, ctx->portid, ctx->seq,
net/netfilter/nf_tables_api.c
3862
nfnetlink_set_err(ctx->net, ctx->portid, NFNLGRP_NFTABLES, -ENOBUFS);
net/netfilter/nf_tables_api.c
389
static void nft_netdev_unregister_trans_hook(struct net *net,
net/netfilter/nf_tables_api.c
3891
struct net *net = sock_net(skb->sk);
net/netfilter/nf_tables_api.c
3899
if (!nft_is_active(net, rule))
net/netfilter/nf_tables_api.c
3908
if (nf_tables_fill_rule_info(skb, net, NETLINK_CB(cb->skb).portid,
net/netfilter/nf_tables_api.c
3939
struct net *net = sock_net(skb->sk);
net/netfilter/nf_tables_api.c
3944
nft_net = nft_pernet(net);
net/netfilter/nf_tables_api.c
3945
cb->seq = nft_base_seq(net);
net/netfilter/nf_tables_api.c
3963
if (!nft_is_active(net, chain))
net/netfilter/nf_tables_api.c
402
nf_unregister_net_hook(net, ops);
net/netfilter/nf_tables_api.c
4028
u8 genmask = nft_genmask_cur(info->net);
net/netfilter/nf_tables_api.c
4032
struct net *net = info->net;
net/netfilter/nf_tables_api.c
4037
table = nft_table_lookup(net, nla[NFTA_RULE_TABLE], family, genmask, 0);
net/netfilter/nf_tables_api.c
4043
chain = nft_chain_lookup(net, table, nla[NFTA_RULE_CHAIN], genmask);
net/netfilter/nf_tables_api.c
4049
rule = nft_rule_lookup(net, chain, nla[NFTA_RULE_HANDLE]);
net/netfilter/nf_tables_api.c
4059
err = nf_tables_fill_rule_info(skb2, net, portid,
net/netfilter/nf_tables_api.c
4074
struct net *net = info->net;
net/netfilter/nf_tables_api.c
409
static void nft_netdev_unregister_hooks(struct net *net,
net/netfilter/nf_tables_api.c
4099
return nfnetlink_unicast(skb2, net, portid);
net/netfilter/nf_tables_api.c
4104
nft_base_seq(net));
net/netfilter/nf_tables_api.c
4109
return nfnetlink_unicast(skb2, net, portid);
net/netfilter/nf_tables_api.c
4132
WARN_ON_ONCE(!lockdep_commit_lock_is_held(ctx->net));
net/netfilter/nf_tables_api.c
4193
if (!nft_is_active_next(ctx->net, rule))
net/netfilter/nf_tables_api.c
420
nf_unregister_net_hook(net, ops);
net/netfilter/nf_tables_api.c
4215
static int nft_table_validate(struct net *net, const struct nft_table *table)
net/netfilter/nf_tables_api.c
4219
.net = net,
net/netfilter/nf_tables_api.c
427
static int nf_tables_register_hook(struct net *net,
net/netfilter/nf_tables_api.c
4278
.genmask = nft_genmask_next(ctx->net),
net/netfilter/nf_tables_api.c
4286
lockdep_commit_lock_is_held(ctx->net)) {
net/netfilter/nf_tables_api.c
4299
static struct nft_rule *nft_rule_lookup_byid(const struct net *net,
net/netfilter/nf_tables_api.c
4308
struct nftables_pernet *nft_net = nft_pernet(info->net);
net/netfilter/nf_tables_api.c
4311
u8 genmask = nft_genmask_next(info->net);
net/netfilter/nf_tables_api.c
4316
struct net *net = info->net;
net/netfilter/nf_tables_api.c
4329
table = nft_table_lookup(net, nla[NFTA_RULE_TABLE], family, genmask,
net/netfilter/nf_tables_api.c
4337
chain = nft_chain_lookup(net, table, nla[NFTA_RULE_CHAIN],
net/netfilter/nf_tables_api.c
4345
chain = nft_chain_lookup_byid(net, table, nla[NFTA_RULE_CHAIN_ID],
net/netfilter/nf_tables_api.c
4360
rule = __nft_rule_lookup(net, chain, handle);
net/netfilter/nf_tables_api.c
4382
old_rule = __nft_rule_lookup(net, chain, pos_handle);
net/netfilter/nf_tables_api.c
4388
old_rule = nft_rule_lookup_byid(net, chain, nla[NFTA_RULE_POSITION_ID]);
net/netfilter/nf_tables_api.c
4396
nft_ctx_init(&ctx, net, skb, info->nlh, family, table, chain, nla);
net/netfilter/nf_tables_api.c
442
return basechain->type->ops_register(net, ops);
net/netfilter/nf_tables_api.c
4437
nft_activate_next(net, rule);
net/netfilter/nf_tables_api.c
445
return nft_netdev_register_hooks(net, &basechain->hook_list);
net/netfilter/nf_tables_api.c
4465
flow = nft_flow_rule_create(net, rule);
net/netfilter/nf_tables_api.c
447
return nf_register_net_hook(net, &basechain->ops);
net/netfilter/nf_tables_api.c
450
static void __nf_tables_unregister_hook(struct net *net,
net/netfilter/nf_tables_api.c
4518
return nft_table_validate(net, table);
net/netfilter/nf_tables_api.c
4543
static struct nft_rule *nft_rule_lookup_byid(const struct net *net,
net/netfilter/nf_tables_api.c
4547
struct nftables_pernet *nft_net = nft_pernet(net);
net/netfilter/nf_tables_api.c
4564
u8 genmask = nft_genmask_next(info->net);
net/netfilter/nf_tables_api.c
4567
struct net *net = info->net;
net/netfilter/nf_tables_api.c
4573
table = nft_table_lookup(net, nla[NFTA_RULE_TABLE], family, genmask,
net/netfilter/nf_tables_api.c
4581
chain = nft_chain_lookup(net, table, nla[NFTA_RULE_CHAIN],
net/netfilter/nf_tables_api.c
4595
nft_ctx_init(&ctx, net, skb, info->nlh, family, table, chain, nla);
net/netfilter/nf_tables_api.c
4599
rule = nft_rule_lookup(info->net, chain, nla[NFTA_RULE_HANDLE]);
net/netfilter/nf_tables_api.c
4611
rule = nft_rule_lookup_byid(net, chain, nla[NFTA_RULE_ID]);
net/netfilter/nf_tables_api.c
4623
if (!nft_is_active_next(net, chain))
net/netfilter/nf_tables_api.c
465
nft_netdev_unregister_hooks(net, table, &basechain->hook_list,
net/netfilter/nf_tables_api.c
4671
struct nftables_pernet *nft_net = nft_pernet(ctx->net);
net/netfilter/nf_tables_api.c
474
return basechain->type->ops_unregister(net, ops);
net/netfilter/nf_tables_api.c
476
nf_unregister_net_hook(net, &basechain->ops);
net/netfilter/nf_tables_api.c
4770
static struct nft_set *nft_set_lookup(const struct net *net,
net/netfilter/nf_tables_api.c
4780
lockdep_commit_lock_is_held(net)) {
net/netfilter/nf_tables_api.c
479
static void nf_tables_unregister_hook(struct net *net,
net/netfilter/nf_tables_api.c
4802
static struct nft_set *nft_set_lookup_byid(const struct net *net,
net/netfilter/nf_tables_api.c
4806
struct nftables_pernet *nft_net = nft_pernet(net);
net/netfilter/nf_tables_api.c
4822
struct nft_set *nft_set_lookup_global(const struct net *net,
net/netfilter/nf_tables_api.c
483
return __nf_tables_unregister_hook(net, table, chain, false);
net/netfilter/nf_tables_api.c
4830
set = nft_set_lookup(net, table, nla_set_name, genmask);
net/netfilter/nf_tables_api.c
4835
set = nft_set_lookup_byid(net, table, nla_set_id, genmask);
net/netfilter/nf_tables_api.c
4863
if (!nft_is_active_next(ctx->net, i))
net/netfilter/nf_tables_api.c
4887
if (!nft_is_active_next(ctx->net, i))
net/netfilter/nf_tables_api.c
4987
nft_base_seq_be16(ctx->net));
net/netfilter/nf_tables_api.c
5089
struct nftables_pernet *nft_net = nft_pernet(ctx->net);
net/netfilter/nf_tables_api.c
5096
!nfnetlink_has_listeners(ctx->net, NFNLGRP_NFTABLES))
net/netfilter/nf_tables_api.c
5115
nfnetlink_set_err(ctx->net, portid, NFNLGRP_NFTABLES, -ENOBUFS);
net/netfilter/nf_tables_api.c
5123
struct net *net = sock_net(skb->sk);
net/netfilter/nf_tables_api.c
5131
nft_net = nft_pernet(net);
net/netfilter/nf_tables_api.c
5132
cb->seq = nft_base_seq(net);
net/netfilter/nf_tables_api.c
5152
if (!nft_is_active(net, set))
net/netfilter/nf_tables_api.c
5202
u8 genmask = nft_genmask_cur(info->net);
net/netfilter/nf_tables_api.c
5205
struct net *net = info->net;
net/netfilter/nf_tables_api.c
5212
table = nft_table_lookup(net, nla[NFTA_SET_TABLE], family,
net/netfilter/nf_tables_api.c
5220
nft_ctx_init(&ctx, net, skb, info->nlh, family, table, NULL, nla);
net/netfilter/nf_tables_api.c
5240
set = nft_set_lookup(net, table, nla[NFTA_SET_NAME], genmask);
net/netfilter/nf_tables_api.c
5254
return nfnetlink_unicast(skb2, net, NETLINK_CB(skb).portid);
net/netfilter/nf_tables_api.c
5430
u8 genmask = nft_genmask_next(info->net);
net/netfilter/nf_tables_api.c
5433
struct net *net = info->net;
net/netfilter/nf_tables_api.c
5576
table = nft_table_lookup(net, nla[NFTA_SET_TABLE], family, genmask,
net/netfilter/nf_tables_api.c
5583
nft_ctx_init(&ctx, net, skb, info->nlh, family, table, NULL, nla);
net/netfilter/nf_tables_api.c
5585
set = nft_set_lookup(net, table, nla[NFTA_SET_NAME], genmask);
net/netfilter/nf_tables_api.c
567
static void nft_trans_commit_list_add_tail(struct net *net, struct nft_trans *trans)
net/netfilter/nf_tables_api.c
5677
write_pnet(&set->net, net);
net/netfilter/nf_tables_api.c
569
struct nftables_pernet *nft_net = nft_pernet(net);
net/netfilter/nf_tables_api.c
5770
u8 genmask = nft_genmask_next(info->net);
net/netfilter/nf_tables_api.c
5772
struct net *net = info->net;
net/netfilter/nf_tables_api.c
5781
table = nft_table_lookup(net, nla[NFTA_SET_TABLE], family,
net/netfilter/nf_tables_api.c
5793
set = nft_set_lookup(net, table, attr, genmask);
net/netfilter/nf_tables_api.c
5811
nft_ctx_init(&ctx, net, skb, info->nlh, family, table, NULL, nla);
net/netfilter/nf_tables_api.c
5852
u8 genmask = nft_genmask_next(ctx->net);
net/netfilter/nf_tables_api.c
5858
lockdep_commit_lock_is_held(ctx->net)) {
net/netfilter/nf_tables_api.c
5876
.genmask = nft_genmask_next(ctx->net),
net/netfilter/nf_tables_api.c
5926
static void nft_setelem_data_activate(const struct net *net,
net/netfilter/nf_tables_api.c
5941
nft_clear(ctx->net, ext);
net/netfilter/nf_tables_api.c
5942
nft_setelem_data_activate(ctx->net, set, elem_priv);
net/netfilter/nf_tables_api.c
5950
u8 genmask = nft_genmask_next(ctx->net);
net/netfilter/nf_tables_api.c
5959
nft_clear(ctx->net, ext);
net/netfilter/nf_tables_api.c
5960
nft_setelem_data_activate(ctx->net, set, catchall->elem);
net/netfilter/nf_tables_api.c
5967
.genmask = nft_genmask_next(ctx->net),
net/netfilter/nf_tables_api.c
597
static void nft_trans_commit_list_add_elem(struct net *net, struct nft_trans *trans)
net/netfilter/nf_tables_api.c
5984
nft_clear(ctx->net, set);
net/netfilter/nf_tables_api.c
599
struct nftables_pernet *nft_net = nft_pernet(net);
net/netfilter/nf_tables_api.c
5994
WARN_ON_ONCE(!lockdep_commit_lock_is_held(ctx->net));
net/netfilter/nf_tables_api.c
6000
nft_deactivate_next(ctx->net, set);
net/netfilter/nf_tables_api.c
6011
nft_deactivate_next(ctx->net, set);
net/netfilter/nf_tables_api.c
609
nft_trans_commit_list_add_tail(net, trans);
net/netfilter/nf_tables_api.c
621
nft_activate_next(ctx->net, ctx->table);
net/netfilter/nf_tables_api.c
623
nft_trans_commit_list_add_tail(ctx->net, trans);
net/netfilter/nf_tables_api.c
6262
static int nft_set_catchall_dump(struct net *net, struct sk_buff *skb,
net/netfilter/nf_tables_api.c
6267
u8 genmask = nft_genmask_cur(net);
net/netfilter/nf_tables_api.c
6289
struct net *net = sock_net(skb->sk);
net/netfilter/nf_tables_api.c
6298
.genmask = nft_genmask_cur(net),
net/netfilter/nf_tables_api.c
6311
nft_net = nft_pernet(net);
net/netfilter/nf_tables_api.c
6312
cb->seq = nft_base_seq(net);
net/netfilter/nf_tables_api.c
6341
table->family, NFNETLINK_V0, nft_base_seq_be16(net));
net/netfilter/nf_tables_api.c
635
nft_deactivate_next(ctx->net, ctx->table);
net/netfilter/nf_tables_api.c
6357
args.iter.err = nft_set_catchall_dump(net, skb, set,
net/netfilter/nf_tables_api.c
6409
NFNETLINK_V0, nft_base_seq_be16(ctx->net));
net/netfilter/nf_tables_api.c
6487
static void *nft_setelem_catchall_get(const struct net *net,
net/netfilter/nf_tables_api.c
6491
u8 genmask = nft_genmask_cur(net);
net/netfilter/nf_tables_api.c
6514
priv = set->ops->get(ctx->net, set, elem, flags);
net/netfilter/nf_tables_api.c
6518
priv = nft_setelem_catchall_get(ctx->net, set);
net/netfilter/nf_tables_api.c
6580
return nfnetlink_unicast(skb, ctx->net, ctx->portid);
net/netfilter/nf_tables_api.c
6594
u8 genmask = nft_genmask_cur(info->net);
net/netfilter/nf_tables_api.c
6596
struct net *net = info->net;
net/netfilter/nf_tables_api.c
6600
table = nft_table_lookup(net, nla[NFTA_SET_ELEM_LIST_TABLE], family,
net/netfilter/nf_tables_api.c
6607
set = nft_set_lookup(net, table, nla[NFTA_SET_ELEM_LIST_SET], genmask);
net/netfilter/nf_tables_api.c
6613
nft_ctx_init(&dump_ctx->ctx, net, skb,
net/netfilter/nf_tables_api.c
6628
struct net *net = info->net;
net/netfilter/nf_tables_api.c
665
nft_activate_next(ctx->net, ctx->chain);
net/netfilter/nf_tables_api.c
6667
audit_log_nft_set_reset(dump_ctx.ctx.table, nft_base_seq(net),
net/netfilter/nf_tables_api.c
6679
struct net *net = ctx->net;
net/netfilter/nf_tables_api.c
6685
if (!ctx->report && !nfnetlink_has_listeners(net, NFNLGRP_NFTABLES))
net/netfilter/nf_tables_api.c
6702
nft_net = nft_pernet(net);
net/netfilter/nf_tables_api.c
6706
nfnetlink_set_err(net, portid, NFNLGRP_NFTABLES, -ENOBUFS);
net/netfilter/nf_tables_api.c
672
nft_trans_commit_list_add_tail(ctx->net, trans);
net/netfilter/nf_tables_api.c
686
nft_deactivate_next(ctx->net, ctx->chain);
net/netfilter/nf_tables_api.c
6869
.net = read_pnet(&set->net),
net/netfilter/nf_tables_api.c
6984
struct nft_set_ext *nft_set_catchall_lookup(const struct net *net,
net/netfilter/nf_tables_api.c
6988
u8 genmask = nft_genmask_cur(net);
net/netfilter/nf_tables_api.c
7002
static int nft_setelem_catchall_insert(const struct net *net,
net/netfilter/nf_tables_api.c
7008
u8 genmask = nft_genmask_next(net);
net/netfilter/nf_tables_api.c
7029
static int nft_setelem_insert(const struct net *net,
net/netfilter/nf_tables_api.c
7038
ret = nft_setelem_catchall_insert(net, set, elem, elem_priv);
net/netfilter/nf_tables_api.c
7040
ret = set->ops->insert(net, set, elem, elem_priv);
net/netfilter/nf_tables_api.c
7057
static void nft_setelem_activate(struct net *net, struct nft_set *set,
net/netfilter/nf_tables_api.c
7063
nft_clear(net, ext);
net/netfilter/nf_tables_api.c
7065
set->ops->activate(net, set, elem_priv);
net/netfilter/nf_tables_api.c
7093
nft_setelem_activate(ctx->net, te->set, elem->priv);
net/netfilter/nf_tables_api.c
7101
static int nft_setelem_catchall_deactivate(const struct net *net,
net/netfilter/nf_tables_api.c
7110
if (!nft_is_active_next(net, ext))
net/netfilter/nf_tables_api.c
7115
nft_set_elem_change_active(net, set, ext);
net/netfilter/nf_tables_api.c
7122
static int __nft_setelem_deactivate(const struct net *net,
net/netfilter/nf_tables_api.c
7128
priv = set->ops->deactivate(net, set, elem);
net/netfilter/nf_tables_api.c
7139
static int nft_setelem_deactivate(const struct net *net,
net/netfilter/nf_tables_api.c
7146
ret = nft_setelem_catchall_deactivate(net, set, elem);
net/netfilter/nf_tables_api.c
7148
ret = __nft_setelem_deactivate(net, set, elem);
net/netfilter/nf_tables_api.c
7159
static void nft_setelem_catchall_remove(const struct net *net,
net/netfilter/nf_tables_api.c
7173
static void nft_setelem_remove(const struct net *net,
net/netfilter/nf_tables_api.c
7178
nft_setelem_catchall_remove(net, set, elem_priv);
net/netfilter/nf_tables_api.c
7180
set->ops->remove(net, set, elem_priv);
net/netfilter/nf_tables_api.c
7195
nft_setelem_remove(ctx->net, te->set, te->elems[i].priv);
net/netfilter/nf_tables_api.c
722
if (nft_is_active_next(ctx->net, rule)) {
net/netfilter/nf_tables_api.c
723
nft_deactivate_next(ctx->net, rule);
net/netfilter/nf_tables_api.c
7248
u8 genmask = nft_genmask_next(ctx->net);
net/netfilter/nf_tables_api.c
7448
obj = nft_obj_lookup(ctx->net, ctx->table,
net/netfilter/nf_tables_api.c
745
nft_trans_commit_list_add_tail(ctx->net, trans);
net/netfilter/nf_tables_api.c
7477
.net = ctx->net,
net/netfilter/nf_tables_api.c
7561
ext->genmask = nft_genmask_cur(ctx->net);
net/netfilter/nf_tables_api.c
7563
err = nft_setelem_insert(ctx->net, set, &elem, &elem_priv, flags);
net/netfilter/nf_tables_api.c
7609
nft_trans_commit_list_add_elem(ctx->net, trans);
net/netfilter/nf_tables_api.c
761
flow = nft_flow_rule_create(ctx->net, rule);
net/netfilter/nf_tables_api.c
7629
nft_trans_commit_list_add_elem(ctx->net, trans);
net/netfilter/nf_tables_api.c
7662
u8 genmask = nft_genmask_next(info->net);
net/netfilter/nf_tables_api.c
7664
struct net *net = info->net;
net/netfilter/nf_tables_api.c
7674
table = nft_table_lookup(net, nla[NFTA_SET_ELEM_LIST_TABLE], family,
net/netfilter/nf_tables_api.c
7681
set = nft_set_lookup_global(net, table, nla[NFTA_SET_ELEM_LIST_SET],
net/netfilter/nf_tables_api.c
7692
nft_ctx_init(&ctx, net, skb, info->nlh, family, table, NULL, nla);
net/netfilter/nf_tables_api.c
7703
return nft_table_validate(net, table);
net/netfilter/nf_tables_api.c
7734
static int nft_setelem_active_next(const struct net *net,
net/netfilter/nf_tables_api.c
7739
u8 genmask = nft_genmask_next(net);
net/netfilter/nf_tables_api.c
7744
static void nft_setelem_data_activate(const struct net *net,
net/netfilter/nf_tables_api.c
7756
void nft_setelem_data_deactivate(const struct net *net,
net/netfilter/nf_tables_api.c
7790
nft_setelem_remove(ctx->net, te->set, te->elems[i].priv);
net/netfilter/nf_tables_api.c
7808
if (!nft_setelem_active_next(ctx->net, te->set, te->elems[i].priv)) {
net/netfilter/nf_tables_api.c
7809
nft_setelem_data_activate(ctx->net, te->set, te->elems[i].priv);
net/netfilter/nf_tables_api.c
7810
nft_setelem_activate(ctx->net, te->set, te->elems[i].priv);
net/netfilter/nf_tables_api.c
786
if (!nft_is_active_next(ctx->net, rule))
net/netfilter/nf_tables_api.c
7891
err = nft_setelem_deactivate(ctx->net, set, &elem, flags);
net/netfilter/nf_tables_api.c
7895
nft_setelem_data_deactivate(ctx->net, set, elem.priv);
net/netfilter/nf_tables_api.c
7898
nft_trans_commit_list_add_elem(ctx->net, trans);
net/netfilter/nf_tables_api.c
7928
set->ops->flush(ctx->net, set, elem_priv);
net/netfilter/nf_tables_api.c
7931
nft_setelem_data_deactivate(ctx->net, set, elem_priv);
net/netfilter/nf_tables_api.c
7935
nft_trans_commit_list_add_elem(ctx->net, trans);
net/netfilter/nf_tables_api.c
7950
nft_setelem_data_deactivate(ctx->net, set, elem_priv);
net/netfilter/nf_tables_api.c
7952
nft_trans_commit_list_add_elem(ctx->net, trans);
net/netfilter/nf_tables_api.c
7960
u8 genmask = nft_genmask_next(ctx->net);
net/netfilter/nf_tables_api.c
7966
lockdep_commit_lock_is_held(ctx->net)) {
net/netfilter/nf_tables_api.c
7974
nft_set_elem_change_active(ctx->net, set, ext);
net/netfilter/nf_tables_api.c
8003
u8 genmask = nft_genmask_next(info->net);
net/netfilter/nf_tables_api.c
8005
struct net *net = info->net;
net/netfilter/nf_tables_api.c
8012
table = nft_table_lookup(net, nla[NFTA_SET_ELEM_LIST_TABLE], family,
net/netfilter/nf_tables_api.c
8019
set = nft_set_lookup(net, table, nla[NFTA_SET_ELEM_LIST_SET], genmask);
net/netfilter/nf_tables_api.c
8031
nft_ctx_init(&ctx, net, skb, info->nlh, family, table, NULL, nla);
net/netfilter/nf_tables_api.c
8088
struct nft_object *nft_obj_lookup(const struct net *net,
net/netfilter/nf_tables_api.c
8102
!lockdep_commit_lock_is_held(net));
net/netfilter/nf_tables_api.c
814
nft_activate_next(ctx->net, set);
net/netfilter/nf_tables_api.c
823
nft_trans_commit_list_add_tail(ctx->net, trans);
net/netfilter/nf_tables_api.c
8234
nft_obj_type_get(struct net *net, u32 objtype, u8 family)
net/netfilter/nf_tables_api.c
8249
if (nft_request_module(net, "nft-obj-%u", objtype) == -EAGAIN)
net/netfilter/nf_tables_api.c
8280
nft_trans_commit_list_add_tail(ctx->net, trans);
net/netfilter/nf_tables_api.c
8295
u8 genmask = nft_genmask_next(info->net);
net/netfilter/nf_tables_api.c
8298
struct net *net = info->net;
net/netfilter/nf_tables_api.c
8310
table = nft_table_lookup(net, nla[NFTA_OBJ_TABLE], family, genmask,
net/netfilter/nf_tables_api.c
8318
obj = nft_obj_lookup(net, table, nla[NFTA_OBJ_NAME], objtype, genmask);
net/netfilter/nf_tables_api.c
8336
type = nft_obj_type_get(net, objtype, family);
net/netfilter/nf_tables_api.c
8342
nft_ctx_init(&ctx, net, skb, info->nlh, family, table, NULL, nla);
net/netfilter/nf_tables_api.c
8348
nft_ctx_init(&ctx, net, skb, info->nlh, family, table, NULL, nla);
net/netfilter/nf_tables_api.c
8353
type = nft_obj_type_get(net, objtype, family);
net/netfilter/nf_tables_api.c
8413
static int nf_tables_fill_obj_info(struct sk_buff *skb, struct net *net,
net/netfilter/nf_tables_api.c
8422
flags, family, NFNETLINK_V0, nft_base_seq_be16(net));
net/netfilter/nf_tables_api.c
844
nft_set_elem_change_active(ctx->net, set, ext);
net/netfilter/nf_tables_api.c
845
nft_setelem_data_deactivate(ctx->net, set, elem_priv);
net/netfilter/nf_tables_api.c
8476
struct net *net = sock_net(skb->sk);
net/netfilter/nf_tables_api.c
8486
nft_net = nft_pernet(net);
net/netfilter/nf_tables_api.c
8487
cb->seq = nft_base_seq(net);
net/netfilter/nf_tables_api.c
8495
if (!nft_is_active(net, obj))
net/netfilter/nf_tables_api.c
8505
rc = nf_tables_fill_obj_info(skb, net,
net/netfilter/nf_tables_api.c
8521
audit_log_obj_reset(table, nft_base_seq(net), entries);
net/netfilter/nf_tables_api.c
8568
u8 genmask = nft_genmask_cur(info->net);
net/netfilter/nf_tables_api.c
8571
struct net *net = info->net;
net/netfilter/nf_tables_api.c
8581
table = nft_table_lookup(net, nla[NFTA_OBJ_TABLE], family, genmask, 0);
net/netfilter/nf_tables_api.c
8588
obj = nft_obj_lookup(net, table, nla[NFTA_OBJ_NAME], objtype, genmask);
net/netfilter/nf_tables_api.c
859
u8 genmask = nft_genmask_next(ctx->net);
net/netfilter/nf_tables_api.c
8598
err = nf_tables_fill_obj_info(skb2, net, portid,
net/netfilter/nf_tables_api.c
8613
struct net *net = info->net;
net/netfilter/nf_tables_api.c
8638
return nfnetlink_unicast(skb2, net, NETLINK_CB(skb).portid);
net/netfilter/nf_tables_api.c
8643
nft_base_seq(net));
net/netfilter/nf_tables_api.c
8648
return nfnetlink_unicast(skb2, net, portid);
net/netfilter/nf_tables_api.c
8666
u8 genmask = nft_genmask_next(info->net);
net/netfilter/nf_tables_api.c
8668
struct net *net = info->net;
net/netfilter/nf_tables_api.c
8679
table = nft_table_lookup(net, nla[NFTA_OBJ_TABLE], family, genmask,
net/netfilter/nf_tables_api.c
868
nft_set_elem_change_active(ctx->net, set, ext);
net/netfilter/nf_tables_api.c
869
nft_setelem_data_deactivate(ctx->net, set, catchall->elem);
net/netfilter/nf_tables_api.c
8692
obj = nft_obj_lookup(net, table, attr, objtype, genmask);
net/netfilter/nf_tables_api.c
8708
nft_ctx_init(&ctx, net, skb, info->nlh, family, table, NULL, nla);
net/netfilter/nf_tables_api.c
8714
__nft_obj_notify(struct net *net, const struct nft_table *table,
net/netfilter/nf_tables_api.c
8718
struct nftables_pernet *nft_net = nft_pernet(net);
net/netfilter/nf_tables_api.c
8723
!nfnetlink_has_listeners(net, NFNLGRP_NFTABLES))
net/netfilter/nf_tables_api.c
8730
err = nf_tables_fill_obj_info(skb, net, portid, seq, event,
net/netfilter/nf_tables_api.c
8741
nfnetlink_set_err(net, portid, NFNLGRP_NFTABLES, -ENOBUFS);
net/netfilter/nf_tables_api.c
8744
void nft_obj_notify(struct net *net, const struct nft_table *table,
net/netfilter/nf_tables_api.c
8749
table->name, nft_base_seq(net));
net/netfilter/nf_tables_api.c
8760
__nft_obj_notify(net, table, obj, portid, seq, event,
net/netfilter/nf_tables_api.c
8768
__nft_obj_notify(ctx->net, ctx->table, obj, ctx->portid,
net/netfilter/nf_tables_api.c
8802
struct nft_flowtable *nft_flowtable_lookup(const struct net *net,
net/netfilter/nf_tables_api.c
8809
lockdep_commit_lock_is_held(net)) {
net/netfilter/nf_tables_api.c
881
.genmask = nft_genmask_next(ctx->net),
net/netfilter/nf_tables_api.c
8914
err = nf_tables_parse_netdev_hooks(ctx->net,
net/netfilter/nf_tables_api.c
8949
nft_flowtable_type_get(struct net *net, u8 family)
net/netfilter/nf_tables_api.c
8964
if (nft_request_module(net, "nf-flowtable-%u", family) == -EAGAIN)
net/netfilter/nf_tables_api.c
8972
static void nft_unregister_flowtable_ops(struct net *net,
net/netfilter/nf_tables_api.c
8976
nf_unregister_net_hook(net, ops);
net/netfilter/nf_tables_api.c
8981
static void __nft_unregister_flowtable_net_hooks(struct net *net,
net/netfilter/nf_tables_api.c
8991
nft_unregister_flowtable_ops(net, flowtable, ops);
net/netfilter/nf_tables_api.c
8997
static void nft_unregister_flowtable_net_hooks(struct net *net,
net/netfilter/nf_tables_api.c
9001
__nft_unregister_flowtable_net_hooks(net, flowtable, hook_list, false);
net/netfilter/nf_tables_api.c
9004
static int nft_register_flowtable_ops(struct net *net,
net/netfilter/nf_tables_api.c
9015
err = nf_register_net_hook(net, ops);
net/netfilter/nf_tables_api.c
9024
static int nft_register_flowtable_net_hooks(struct net *net,
net/netfilter/nf_tables_api.c
903
nft_deactivate_next(ctx->net, set);
net/netfilter/nf_tables_api.c
9036
if (!nft_is_active_next(net, ft))
net/netfilter/nf_tables_api.c
9046
err = nft_register_flowtable_ops(net, flowtable, ops);
net/netfilter/nf_tables_api.c
9062
nft_unregister_flowtable_ops(net, flowtable, ops);
net/netfilter/nf_tables_api.c
9078
static void nft_flowtable_unregister_trans_hook(struct net *net,
net/netfilter/nf_tables_api.c
9089
nft_unregister_flowtable_ops(net, flowtable, ops);
net/netfilter/nf_tables_api.c
9122
nft_net = nft_pernet(ctx->net);
net/netfilter/nf_tables_api.c
9151
err = nft_register_flowtable_net_hooks(ctx->net, ctx->table,
net/netfilter/nf_tables_api.c
9170
nft_trans_commit_list_add_tail(ctx->net, trans);
net/netfilter/nf_tables_api.c
9178
nft_unregister_flowtable_ops(ctx->net,
net/netfilter/nf_tables_api.c
919
nft_activate_next(ctx->net, obj);
net/netfilter/nf_tables_api.c
9194
u8 genmask = nft_genmask_next(info->net);
net/netfilter/nf_tables_api.c
9198
struct net *net = info->net;
net/netfilter/nf_tables_api.c
9209
table = nft_table_lookup(net, nla[NFTA_FLOWTABLE_TABLE], family,
net/netfilter/nf_tables_api.c
9216
flowtable = nft_flowtable_lookup(net, table, nla[NFTA_FLOWTABLE_NAME],
net/netfilter/nf_tables_api.c
922
nft_trans_commit_list_add_tail(ctx->net, trans);
net/netfilter/nf_tables_api.c
9230
nft_ctx_init(&ctx, net, skb, info->nlh, family, table, NULL, nla);
net/netfilter/nf_tables_api.c
9235
nft_ctx_init(&ctx, net, skb, info->nlh, family, table, NULL, nla);
net/netfilter/nf_tables_api.c
9256
type = nft_flowtable_type_get(net, family);
net/netfilter/nf_tables_api.c
9271
write_pnet(&flowtable->data.net, net);
net/netfilter/nf_tables_api.c
9293
err = nft_register_flowtable_net_hooks(ctx.net, table,
net/netfilter/nf_tables_api.c
935
nft_deactivate_next(ctx->net, obj);
net/netfilter/nf_tables_api.c
9373
nft_trans_commit_list_add_tail(ctx->net, trans);
net/netfilter/nf_tables_api.c
9389
u8 genmask = nft_genmask_next(info->net);
net/netfilter/nf_tables_api.c
9392
struct net *net = info->net;
net/netfilter/nf_tables_api.c
9402
table = nft_table_lookup(net, nla[NFTA_FLOWTABLE_TABLE], family,
net/netfilter/nf_tables_api.c
9414
flowtable = nft_flowtable_lookup(net, table, attr, genmask);
net/netfilter/nf_tables_api.c
9426
nft_ctx_init(&ctx, net, skb, info->nlh, family, table, NULL, nla);
net/netfilter/nf_tables_api.c
9439
static int nf_tables_fill_flowtable_info(struct sk_buff *skb, struct net *net,
net/netfilter/nf_tables_api.c
9453
flags, family, NFNETLINK_V0, nft_base_seq_be16(net));
net/netfilter/nf_tables_api.c
9490
lockdep_commit_lock_is_held(net)) {
net/netfilter/nf_tables_api.c
9521
struct net *net = sock_net(skb->sk);
net/netfilter/nf_tables_api.c
9528
nft_net = nft_pernet(net);
net/netfilter/nf_tables_api.c
9529
cb->seq = nft_base_seq(net);
net/netfilter/nf_tables_api.c
953
nft_activate_next(ctx->net, flowtable);
net/netfilter/nf_tables_api.c
9536
if (!nft_is_active(net, flowtable))
net/netfilter/nf_tables_api.c
9547
if (nf_tables_fill_flowtable_info(skb, net, NETLINK_CB(cb->skb).portid,
net/netfilter/nf_tables_api.c
957
nft_trans_commit_list_add_tail(ctx->net, trans);
net/netfilter/nf_tables_api.c
9608
u8 genmask = nft_genmask_cur(info->net);
net/netfilter/nf_tables_api.c
9612
struct net *net = info->net;
net/netfilter/nf_tables_api.c
9631
table = nft_table_lookup(net, nla[NFTA_FLOWTABLE_TABLE], family,
net/netfilter/nf_tables_api.c
9638
flowtable = nft_flowtable_lookup(net, table, nla[NFTA_FLOWTABLE_NAME],
net/netfilter/nf_tables_api.c
9649
err = nf_tables_fill_flowtable_info(skb2, net, NETLINK_CB(skb).portid,
net/netfilter/nf_tables_api.c
9656
return nfnetlink_unicast(skb2, net, NETLINK_CB(skb).portid);
net/netfilter/nf_tables_api.c
9669
struct nftables_pernet *nft_net = nft_pernet(ctx->net);
net/netfilter/nf_tables_api.c
9675
!nfnetlink_has_listeners(ctx->net, NFNLGRP_NFTABLES))
net/netfilter/nf_tables_api.c
9685
err = nf_tables_fill_flowtable_info(skb, ctx->net, ctx->portid,
net/netfilter/nf_tables_api.c
9697
nfnetlink_set_err(ctx->net, ctx->portid, NFNLGRP_NFTABLES, -ENOBUFS);
net/netfilter/nf_tables_api.c
9709
static int nf_tables_fill_gen_info(struct sk_buff *skb, struct net *net,
net/netfilter/nf_tables_api.c
971
nft_deactivate_next(ctx->net, flowtable);
net/netfilter/nf_tables_api.c
9717
NFNETLINK_V0, nft_base_seq_be16(net));
net/netfilter/nf_tables_api.c
9721
if (nla_put_be32(skb, NFTA_GEN_ID, htonl(nft_base_seq(net))) ||
net/netfilter/nf_tables_api.c
981
static struct nft_table *nft_table_lookup(const struct net *net,
net/netfilter/nf_tables_api.c
9837
struct net *net;
net/netfilter/nf_tables_api.c
9844
net = dev_net(dev);
net/netfilter/nf_tables_api.c
9845
nft_net = nft_pernet(net);
net/netfilter/nf_tables_api.c
9866
static void nf_tables_gen_notify(struct net *net, struct sk_buff *skb,
net/netfilter/nf_tables_api.c
9874
!nfnetlink_has_listeners(net, NFNLGRP_NFTABLES))
net/netfilter/nf_tables_api.c
9881
err = nf_tables_fill_gen_info(skb2, net, NETLINK_CB(skb).portid,
net/netfilter/nf_tables_api.c
9888
nfnetlink_send(skb2, net, NETLINK_CB(skb).portid, NFNLGRP_NFTABLES,
net/netfilter/nf_tables_api.c
9892
nfnetlink_set_err(net, NETLINK_CB(skb).portid, NFNLGRP_NFTABLES,
net/netfilter/nf_tables_api.c
9906
err = nf_tables_fill_gen_info(skb2, info->net, NETLINK_CB(skb).portid,
net/netfilter/nf_tables_api.c
991
nft_net = nft_pernet(net);
net/netfilter/nf_tables_api.c
9911
return nfnetlink_unicast(skb2, info->net, NETLINK_CB(skb).portid);
net/netfilter/nf_tables_core.c
253
const struct net *net = nft_net(pkt);
net/netfilter/nf_tables_core.c
259
bool genbit = READ_ONCE(net->nft.gencursor);
net/netfilter/nf_tables_offload.c
119
ctx->net = net;
net/netfilter/nf_tables_offload.c
372
struct net *net,
net/netfilter/nf_tables_offload.c
378
bo->net = net;
net/netfilter/nf_tables_offload.c
410
struct net *net = dev_net(dev);
net/netfilter/nf_tables_offload.c
415
nft_net = nft_pernet(net);
net/netfilter/nf_tables_offload.c
516
static void nft_flow_rule_offload_abort(struct net *net,
net/netfilter/nf_tables_offload.c
519
struct nftables_pernet *nft_net = nft_pernet(net);
net/netfilter/nf_tables_offload.c
566
int nft_flow_rule_offload_commit(struct net *net)
net/netfilter/nf_tables_offload.c
568
struct nftables_pernet *nft_net = nft_pernet(net);
net/netfilter/nf_tables_offload.c
620
nft_flow_rule_offload_abort(net, trans);
net/netfilter/nf_tables_offload.c
669
struct net *net = dev_net(dev);
net/netfilter/nf_tables_offload.c
675
nft_net = nft_pernet(net);
net/netfilter/nf_tables_offload.c
88
struct nft_flow_rule *nft_flow_rule_create(struct net *net,
net/netfilter/nfnetlink.c
166
int nfnetlink_has_listeners(struct net *net, unsigned int group)
net/netfilter/nfnetlink.c
168
struct nfnl_net *nfnlnet = nfnl_pernet(net);
net/netfilter/nfnetlink.c
174
int nfnetlink_send(struct sk_buff *skb, struct net *net, u32 portid,
net/netfilter/nfnetlink.c
177
struct nfnl_net *nfnlnet = nfnl_pernet(net);
net/netfilter/nfnetlink.c
183
int nfnetlink_set_err(struct net *net, u32 portid, u32 group, int error)
net/netfilter/nfnetlink.c
185
struct nfnl_net *nfnlnet = nfnl_pernet(net);
net/netfilter/nfnetlink.c
191
int nfnetlink_unicast(struct sk_buff *skb, struct net *net, u32 portid)
net/netfilter/nfnetlink.c
193
struct nfnl_net *nfnlnet = nfnl_pernet(net);
net/netfilter/nfnetlink.c
204
void nfnetlink_broadcast(struct net *net, struct sk_buff *skb, __u32 portid,
net/netfilter/nfnetlink.c
207
struct nfnl_net *nfnlnet = nfnl_pernet(net);
net/netfilter/nfnetlink.c
217
struct net *net = sock_net(skb->sk);
net/netfilter/nfnetlink.c
253
struct nfnl_net *nfnlnet = nfnl_pernet(net);
net/netfilter/nfnetlink.c
260
.net = net,
net/netfilter/nfnetlink.c
373
struct net *net = sock_net(skb->sk);
net/netfilter/nfnetlink.c
421
if (!ss->valid_genid(net, genid)) {
net/netfilter/nfnetlink.c
498
struct nfnl_net *nfnlnet = nfnl_pernet(net);
net/netfilter/nfnetlink.c
504
.net = net,
net/netfilter/nfnetlink.c
568
ss->abort(net, oskb, NFNL_ABORT_AUTOLOAD);
net/netfilter/nfnetlink.c
574
err = ss->commit(net, oskb);
net/netfilter/nfnetlink.c
579
ss->abort(net, oskb, NFNL_ABORT_NONE);
net/netfilter/nfnetlink.c
593
err = ss->abort(net, oskb, abort_action);
net/netfilter/nfnetlink.c
670
static void nfnetlink_bind_event(struct net *net, unsigned int group)
net/netfilter/nfnetlink.c
708
static int nfnetlink_bind(struct net *net, int group)
net/netfilter/nfnetlink.c
724
nfnetlink_bind_event(net, group);
net/netfilter/nfnetlink.c
728
static void nfnetlink_unbind(struct net *net, int group)
net/netfilter/nfnetlink.c
754
if (!nfnetlink_has_listeners(net, group)) {
net/netfilter/nfnetlink.c
766
static int __net_init nfnetlink_net_init(struct net *net)
net/netfilter/nfnetlink.c
768
struct nfnl_net *nfnlnet = nfnl_pernet(net);
net/netfilter/nfnetlink.c
776
nfnlnet->nfnl = netlink_kernel_create(net, NETLINK_NETFILTER, &cfg);
net/netfilter/nfnetlink.c
785
struct net *net;
net/netfilter/nfnetlink.c
787
list_for_each_entry(net, net_exit_list, exit_list) {
net/netfilter/nfnetlink.c
788
nfnlnet = nfnl_pernet(net);
net/netfilter/nfnetlink.c
89
static struct nfnl_net *nfnl_pernet(struct net *net)
net/netfilter/nfnetlink.c
91
return net_generic(net, nfnetlink_pernet_id);
net/netfilter/nfnetlink_acct.c
196
struct net *net = sock_net(skb->sk);
net/netfilter/nfnetlink_acct.c
197
struct nfnl_acct_net *nfnl_acct_net = nfnl_acct_pernet(net);
net/netfilter/nfnetlink_acct.c
277
struct nfnl_acct_net *nfnl_acct_net = nfnl_acct_pernet(info->net);
net/netfilter/nfnetlink_acct.c
318
ret = nfnetlink_unicast(skb2, info->net, NETLINK_CB(skb).portid);
net/netfilter/nfnetlink_acct.c
346
struct nfnl_acct_net *nfnl_acct_net = nfnl_acct_pernet(info->net);
net/netfilter/nfnetlink_acct.c
417
struct nf_acct *nfnl_acct_find_get(struct net *net, const char *acct_name)
net/netfilter/nfnetlink_acct.c
419
struct nfnl_acct_net *nfnl_acct_net = nfnl_acct_pernet(net);
net/netfilter/nfnetlink_acct.c
460
static void nfnl_overquota_report(struct net *net, struct nf_acct *nfacct)
net/netfilter/nfnetlink_acct.c
475
nfnetlink_broadcast(net, skb, 0, NFNLGRP_ACCT_QUOTA, GFP_ATOMIC);
net/netfilter/nfnetlink_acct.c
478
int nfnl_acct_overquota(struct net *net, struct nf_acct *nfacct)
net/netfilter/nfnetlink_acct.c
496
nfnl_overquota_report(net, nfacct);
net/netfilter/nfnetlink_acct.c
503
static int __net_init nfnl_acct_net_init(struct net *net)
net/netfilter/nfnetlink_acct.c
505
INIT_LIST_HEAD(&nfnl_acct_pernet(net)->nfnl_acct_list);
net/netfilter/nfnetlink_acct.c
51
static inline struct nfnl_acct_net *nfnl_acct_pernet(struct net *net)
net/netfilter/nfnetlink_acct.c
510
static void __net_exit nfnl_acct_net_exit(struct net *net)
net/netfilter/nfnetlink_acct.c
512
struct nfnl_acct_net *nfnl_acct_net = nfnl_acct_pernet(net);
net/netfilter/nfnetlink_acct.c
53
return net_generic(net, nfnl_acct_net_id);
net/netfilter/nfnetlink_acct.c
62
struct nfnl_acct_net *nfnl_acct_net = nfnl_acct_pernet(info->net);
net/netfilter/nfnetlink_cthelper.c
687
ret = nfnetlink_unicast(skb2, info->net, NETLINK_CB(skb).portid);
net/netfilter/nfnetlink_cttimeout.c
138
info->net,
net/netfilter/nfnetlink_cttimeout.c
167
info->net, cda[CTA_TIMEOUT_DATA]);
net/netfilter/nfnetlink_cttimeout.c
235
struct net *net = sock_net(skb->sk);
net/netfilter/nfnetlink_cttimeout.c
246
pernet = nfct_timeout_pernet(net);
net/netfilter/nfnetlink_cttimeout.c
272
struct nfct_timeout_pernet *pernet = nfct_timeout_pernet(info->net);
net/netfilter/nfnetlink_cttimeout.c
309
ret = nfnetlink_unicast(skb2, info->net, NETLINK_CB(skb).portid);
net/netfilter/nfnetlink_cttimeout.c
316
static void ctnl_timeout_del(struct net *net, struct ctnl_timeout *timeout)
net/netfilter/nfnetlink_cttimeout.c
320
nf_ct_untimeout(net, timeout->timeout);
net/netfilter/nfnetlink_cttimeout.c
333
struct nfct_timeout_pernet *pernet = nfct_timeout_pernet(info->net);
net/netfilter/nfnetlink_cttimeout.c
341
ctnl_timeout_del(info->net, cur);
net/netfilter/nfnetlink_cttimeout.c
351
ctnl_timeout_del(info->net, cur);
net/netfilter/nfnetlink_cttimeout.c
379
ret = ctnl_timeout_parse_policy(NULL, l4proto, info->net,
net/netfilter/nfnetlink_cttimeout.c
390
cttimeout_default_fill_info(struct net *net, struct sk_buff *skb, u32 portid,
net/netfilter/nfnetlink_cttimeout.c
452
timeouts = &nf_icmp_pernet(info->net)->timeout;
net/netfilter/nfnetlink_cttimeout.c
455
timeouts = nf_tcp_pernet(info->net)->timeouts;
net/netfilter/nfnetlink_cttimeout.c
458
timeouts = nf_udp_pernet(info->net)->timeouts;
net/netfilter/nfnetlink_cttimeout.c
461
timeouts = &nf_icmpv6_pernet(info->net)->timeout;
net/netfilter/nfnetlink_cttimeout.c
465
timeouts = nf_sctp_pernet(info->net)->timeouts;
net/netfilter/nfnetlink_cttimeout.c
470
timeouts = nf_gre_pernet(info->net)->timeouts;
net/netfilter/nfnetlink_cttimeout.c
474
timeouts = &nf_generic_pernet(info->net)->timeout;
net/netfilter/nfnetlink_cttimeout.c
488
ret = cttimeout_default_fill_info(info->net, skb2,
net/netfilter/nfnetlink_cttimeout.c
499
return nfnetlink_unicast(skb2, info->net, NETLINK_CB(skb).portid);
net/netfilter/nfnetlink_cttimeout.c
502
static struct nf_ct_timeout *ctnl_timeout_find_get(struct net *net,
net/netfilter/nfnetlink_cttimeout.c
505
struct nfct_timeout_pernet *pernet = nfct_timeout_pernet(net);
net/netfilter/nfnetlink_cttimeout.c
572
static int __net_init cttimeout_net_init(struct net *net)
net/netfilter/nfnetlink_cttimeout.c
574
struct nfct_timeout_pernet *pernet = nfct_timeout_pernet(net);
net/netfilter/nfnetlink_cttimeout.c
582
static void __net_exit cttimeout_net_pre_exit(struct net *net)
net/netfilter/nfnetlink_cttimeout.c
584
struct nfct_timeout_pernet *pernet = nfct_timeout_pernet(net);
net/netfilter/nfnetlink_cttimeout.c
595
static void __net_exit cttimeout_net_exit(struct net *net)
net/netfilter/nfnetlink_cttimeout.c
597
struct nfct_timeout_pernet *pernet = nfct_timeout_pernet(net);
net/netfilter/nfnetlink_cttimeout.c
603
nf_ct_untimeout(net, NULL);
net/netfilter/nfnetlink_cttimeout.c
61
static struct nfct_timeout_pernet *nfct_timeout_pernet(struct net *net)
net/netfilter/nfnetlink_cttimeout.c
63
return net_generic(net, nfct_timeout_id);
net/netfilter/nfnetlink_cttimeout.c
69
struct net *net, const struct nlattr *attr)
net/netfilter/nfnetlink_cttimeout.c
87
ret = l4proto->ctnl_timeout.nlattr_to_obj(tb, net, timeout);
net/netfilter/nfnetlink_cttimeout.c
98
struct nfct_timeout_pernet *pernet = nfct_timeout_pernet(info->net);
net/netfilter/nfnetlink_hook.c
134
struct net *net = sock_net(nlskb->sk);
net/netfilter/nfnetlink_hook.c
141
if (!nft_is_active(net, chain))
net/netfilter/nfnetlink_hook.c
166
struct net *net = sock_net(nlskb->sk);
net/netfilter/nfnetlink_hook.c
173
if (!nft_is_active(net, ft))
net/netfilter/nfnetlink_hook.c
279
nfnl_hook_entries_head(u8 pf, unsigned int hook, struct net *net, const char *dev)
net/netfilter/nfnetlink_hook.c
288
if (hook >= ARRAY_SIZE(net->nf.hooks_ipv4))
net/netfilter/nfnetlink_hook.c
290
hook_head = rcu_dereference(net->nf.hooks_ipv4[hook]);
net/netfilter/nfnetlink_hook.c
293
if (hook >= ARRAY_SIZE(net->nf.hooks_ipv6))
net/netfilter/nfnetlink_hook.c
295
hook_head = rcu_dereference(net->nf.hooks_ipv6[hook]);
net/netfilter/nfnetlink_hook.c
299
if (hook >= ARRAY_SIZE(net->nf.hooks_arp))
net/netfilter/nfnetlink_hook.c
301
hook_head = rcu_dereference(net->nf.hooks_arp[hook]);
net/netfilter/nfnetlink_hook.c
306
if (hook >= ARRAY_SIZE(net->nf.hooks_bridge))
net/netfilter/nfnetlink_hook.c
308
hook_head = rcu_dereference(net->nf.hooks_bridge[hook]);
net/netfilter/nfnetlink_hook.c
319
netdev = dev_get_by_name_rcu(net, dev);
net/netfilter/nfnetlink_hook.c
346
struct net *net = sock_net(nlskb->sk);
net/netfilter/nfnetlink_hook.c
353
e = nfnl_hook_entries_head(family, ctx->hook, net, ctx->devname);
net/netfilter/nfnetlink_hook.c
386
struct net *net = sock_net(cb->skb->sk);
net/netfilter/nfnetlink_hook.c
405
head = nfnl_hook_entries_head(family, hooknum, net, name);
net/netfilter/nfnetlink_log.c
1058
static struct hlist_node *get_first(struct net *net, struct iter_state *st)
net/netfilter/nfnetlink_log.c
1064
log = nfnl_log_pernet(net);
net/netfilter/nfnetlink_log.c
1075
static struct hlist_node *get_next(struct net *net, struct iter_state *st,
net/netfilter/nfnetlink_log.c
1086
log = nfnl_log_pernet(net);
net/netfilter/nfnetlink_log.c
1093
static struct hlist_node *get_idx(struct net *net, struct iter_state *st,
net/netfilter/nfnetlink_log.c
1097
head = get_first(net, st);
net/netfilter/nfnetlink_log.c
1100
while (pos && (head = get_next(net, st, head)))
net/netfilter/nfnetlink_log.c
1145
static int __net_init nfnl_log_net_init(struct net *net)
net/netfilter/nfnetlink_log.c
1148
struct nfnl_log_net *log = nfnl_log_pernet(net);
net/netfilter/nfnetlink_log.c
1160
proc = proc_create_net("nfnetlink_log", 0440, net->nf.proc_netfilter,
net/netfilter/nfnetlink_log.c
1165
root_uid = make_kuid(net->user_ns, 0);
net/netfilter/nfnetlink_log.c
1166
root_gid = make_kgid(net->user_ns, 0);
net/netfilter/nfnetlink_log.c
1173
static void __net_exit nfnl_log_net_exit(struct net *net)
net/netfilter/nfnetlink_log.c
1175
struct nfnl_log_net *log = nfnl_log_pernet(net);
net/netfilter/nfnetlink_log.c
1179
remove_proc_entry("nfnetlink_log", net->nf.proc_netfilter);
net/netfilter/nfnetlink_log.c
1181
nf_log_unset(net, &nfulnl_logger);
net/netfilter/nfnetlink_log.c
154
put_net_track(inst->net, &inst->ns_tracker);
net/netfilter/nfnetlink_log.c
169
instance_create(struct net *net, u_int16_t group_num,
net/netfilter/nfnetlink_log.c
173
struct nfnl_log_net *log = nfnl_log_pernet(net);
net/netfilter/nfnetlink_log.c
201
inst->net = get_net_track(net, &inst->ns_tracker, GFP_ATOMIC);
net/netfilter/nfnetlink_log.c
337
nfulnl_alloc_skb(struct net *net, u32 peer_portid, unsigned int inst_size,
net/netfilter/nfnetlink_log.c
374
nfnetlink_unicast(inst->skb, inst->net, inst->peer_portid);
net/netfilter/nfnetlink_log.c
68
struct net *net;
net/netfilter/nfnetlink_log.c
718
nfulnl_log_packet(struct net *net,
net/netfilter/nfnetlink_log.c
733
struct nfnl_log_net *log = nfnl_log_pernet(net);
net/netfilter/nfnetlink_log.c
824
inst->skb = nfulnl_alloc_skb(net, inst->peer_portid,
net/netfilter/nfnetlink_log.c
861
struct nfnl_log_net *log = nfnl_log_pernet(n->net);
net/netfilter/nfnetlink_log.c
914
struct nfnl_log_net *log = nfnl_log_pernet(info->net);
net/netfilter/nfnetlink_log.c
928
return nf_log_bind_pf(info->net, pf, &nfulnl_logger);
net/netfilter/nfnetlink_log.c
930
nf_log_unbind_pf(info->net, pf);
net/netfilter/nfnetlink_log.c
95
static struct nfnl_log_net *nfnl_log_pernet(struct net *net)
net/netfilter/nfnetlink_log.c
97
return net_generic(net, nfnl_log_net_id);
net/netfilter/nfnetlink_log.c
971
inst = instance_create(info->net, group_num,
net/netfilter/nfnetlink_osf.c
184
const struct nf_osf_info *info, struct net *net,
net/netfilter/nfnetlink_osf.c
220
nf_log_packet(net, family, hooknum, skb,
net/netfilter/nfnetlink_osf.c
234
nf_log_packet(net, family, hooknum, skb, in, out, NULL,
net/netfilter/nfnetlink_queue.c
1001
err = nfnetlink_unicast(nskb, net, queue->peer_portid);
net/netfilter/nfnetlink_queue.c
101
return net_generic(net, nfnl_queue_net_id);
net/netfilter/nfnetlink_queue.c
1077
__nfqnl_enqueue_packet_gso(struct net *net, struct nfqnl_instance *queue,
net/netfilter/nfnetlink_queue.c
1088
ret = __nfqnl_enqueue_packet(net, queue, entry);
net/netfilter/nfnetlink_queue.c
1099
ret = __nfqnl_enqueue_packet(net, queue, entry_seg);
net/netfilter/nfnetlink_queue.c
1114
struct net *net = entry->state.net;
net/netfilter/nfnetlink_queue.c
1115
struct nfnl_queue_net *q = nfnl_queue_pernet(net);
net/netfilter/nfnetlink_queue.c
1146
return __nfqnl_enqueue_packet(net, queue, entry);
net/netfilter/nfnetlink_queue.c
1176
err = __nfqnl_enqueue_packet_gso(net, queue,
net/netfilter/nfnetlink_queue.c
1367
if (e->state.net->user_ns != &init_user_ns)
net/netfilter/nfnetlink_queue.c
1462
nfqnl_dev_drop(struct net *net, int ifindex)
net/netfilter/nfnetlink_queue.c
1465
struct nfnl_queue_net *q = nfnl_queue_pernet(net);
net/netfilter/nfnetlink_queue.c
1496
static void nfqnl_nf_hook_drop(struct net *net)
net/netfilter/nfnetlink_queue.c
1498
struct nfnl_queue_net *q = nfnl_queue_pernet(net);
net/netfilter/nfnetlink_queue.c
1525
struct nfnl_queue_net *q = nfnl_queue_pernet(n->net);
net/netfilter/nfnetlink_queue.c
1612
struct nfnl_queue_net *q = nfnl_queue_pernet(info->net);
net/netfilter/nfnetlink_queue.c
1722
struct nfnl_queue_net *q = nfnl_queue_pernet(info->net);
net/netfilter/nfnetlink_queue.c
1808
struct nfnl_queue_net *q = nfnl_queue_pernet(info->net);
net/netfilter/nfnetlink_queue.c
1967
struct net *net;
net/netfilter/nfnetlink_queue.c
1973
net = seq_file_net(seq);
net/netfilter/nfnetlink_queue.c
1974
q = nfnl_queue_pernet(net);
net/netfilter/nfnetlink_queue.c
1985
struct net *net = seq_file_net(seq);
net/netfilter/nfnetlink_queue.c
1994
q = nfnl_queue_pernet(net);
net/netfilter/nfnetlink_queue.c
2051
static int __net_init nfnl_queue_net_init(struct net *net)
net/netfilter/nfnetlink_queue.c
2054
struct nfnl_queue_net *q = nfnl_queue_pernet(net);
net/netfilter/nfnetlink_queue.c
2062
if (!proc_create_net("nfnetlink_queue", 0440, net->nf.proc_netfilter,
net/netfilter/nfnetlink_queue.c
2069
static void __net_exit nfnl_queue_net_exit(struct net *net)
net/netfilter/nfnetlink_queue.c
2071
struct nfnl_queue_net *q = nfnl_queue_pernet(net);
net/netfilter/nfnetlink_queue.c
2075
remove_proc_entry("nfnetlink_queue", net->nf.proc_netfilter);
net/netfilter/nfnetlink_queue.c
284
static struct nf_hook_entries *nf_hook_entries_head(const struct net *net, u8 pf, u8 hooknum)
net/netfilter/nfnetlink_queue.c
289
return rcu_dereference(net->nf.hooks_bridge[hooknum]);
net/netfilter/nfnetlink_queue.c
292
return rcu_dereference(net->nf.hooks_ipv4[hooknum]);
net/netfilter/nfnetlink_queue.c
294
return rcu_dereference(net->nf.hooks_ipv6[hooknum]);
net/netfilter/nfnetlink_queue.c
315
return ip_route_me_harder(entry->state.net, entry->state.sk,
net/netfilter/nfnetlink_queue.c
333
return nf_ip6_route_me_harder(entry->state.net,
net/netfilter/nfnetlink_queue.c
360
const struct net *net;
net/netfilter/nfnetlink_queue.c
365
net = entry->state.net;
net/netfilter/nfnetlink_queue.c
368
hooks = nf_hook_entries_head(net, pf, entry->state.hook);
net/netfilter/nfnetlink_queue.c
398
entry->state.okfn(entry->state.net, entry->state.sk, skb);
net/netfilter/nfnetlink_queue.c
492
ct_verdict = ct_hook->update(entry->state.net, entry->skb);
net/netfilter/nfnetlink_queue.c
705
nfqnl_build_packet_message(struct net *net, struct nfqnl_instance *queue,
net/netfilter/nfnetlink_queue.c
974
__nfqnl_enqueue_packet(struct net *net, struct nfqnl_instance *queue,
net/netfilter/nfnetlink_queue.c
982
nskb = nfqnl_build_packet_message(net, queue, entry, &packet_id_ptr);
net/netfilter/nfnetlink_queue.c
99
static struct nfnl_queue_net *nfnl_queue_pernet(struct net *net)
net/netfilter/nft_chain_nat.c
78
static int nft_nat_inet_reg(struct net *net, const struct nf_hook_ops *ops)
net/netfilter/nft_chain_nat.c
80
return nf_nat_inet_register_fn(net, ops);
net/netfilter/nft_chain_nat.c
83
static void nft_nat_inet_unreg(struct net *net, const struct nf_hook_ops *ops)
net/netfilter/nft_chain_nat.c
85
nf_nat_inet_unregister_fn(net, ops);
net/netfilter/nft_chain_route.c
45
err = ip_route_me_harder(state->net, state->sk, skb, RTN_UNSPEC);
net/netfilter/nft_chain_route.c
95
err = nf_ip6_route_me_harder(state->net, state->sk, skb);
net/netfilter/nft_compat.c
149
par->net = ctx->net;
net/netfilter/nft_compat.c
232
static void nft_compat_wait_for_destructors(struct net *net)
net/netfilter/nft_compat.c
240
nf_tables_trans_destroy_flush_work(net);
net/netfilter/nft_compat.c
264
nft_compat_wait_for_destructors(ctx->net);
net/netfilter/nft_compat.c
279
nft_request_module(ctx->net, "%s", modname) == -EAGAIN)
net/netfilter/nft_compat.c
307
par.net = ctx->net;
net/netfilter/nft_compat.c
474
par->net = ctx->net;
net/netfilter/nft_compat.c
542
nft_compat_wait_for_destructors(ctx->net);
net/netfilter/nft_compat.c
582
par.net = ctx->net;
net/netfilter/nft_compat.c
789
ret = nfnetlink_unicast(skb2, info->net, NETLINK_CB(skb).portid);
net/netfilter/nft_connlimit.c
243
static bool nft_connlimit_gc(struct net *net, const struct nft_expr *expr)
net/netfilter/nft_connlimit.c
247
return nf_conncount_gc_list(net, priv->list);
net/netfilter/nft_connlimit.c
82
err = nf_ct_netns_get(ctx->net, ctx->family);
net/netfilter/nft_connlimit.c
96
nf_ct_netns_put(ctx->net, ctx->family);
net/netfilter/nft_ct.c
1085
err = nf_ct_netns_get(ctx->net, ctx->family);
net/netfilter/nft_ct.c
1109
nf_ct_netns_put(ctx->net, ctx->family);
net/netfilter/nft_ct.c
1276
return nf_ct_netns_get(ctx->net, ctx->family);
net/netfilter/nft_ct.c
1282
nf_ct_netns_put(ctx->net, ctx->family);
net/netfilter/nft_ct.c
386
nf_connlabels_put(ctx->net);
net/netfilter/nft_ct.c
425
err = nf_connlabels_get(ctx->net, (len * BITS_PER_BYTE) - 1);
net/netfilter/nft_ct.c
520
err = nf_ct_netns_get(ctx->net, ctx->family);
net/netfilter/nft_ct.c
527
nf_ct_set_acct(ctx->net, true);
net/netfilter/nft_ct.c
540
nf_connlabels_put(ctx->net);
net/netfilter/nft_ct.c
545
nf_queue_nf_hook_drop(ctx->net);
net/netfilter/nft_ct.c
580
err = nf_connlabels_get(ctx->net, (len * BITS_PER_BYTE) - 1);
net/netfilter/nft_ct.c
632
err = nf_ct_netns_get(ctx->net, ctx->family);
net/netfilter/nft_ct.c
649
nf_ct_netns_put(ctx->net, ctx->family);
net/netfilter/nft_ct.c
658
nf_ct_netns_put(ctx->net, ctx->family);
net/netfilter/nft_ct.c
846
struct net *net, const struct nlattr *attr)
net/netfilter/nft_ct.c
864
ret = l4proto->ctnl_timeout.nlattr_to_obj(tb, net, timeouts);
net/netfilter/nft_ct.c
943
ret = nft_ct_timeout_parse_policy(&timeout->data, l4proto, ctx->net,
net/netfilter/nft_ct.c
952
ret = nf_ct_netns_get(ctx->net, ctx->family);
net/netfilter/nft_ct.c
971
nf_ct_untimeout(ctx->net, timeout);
net/netfilter/nft_ct.c
972
nf_ct_netns_put(ctx->net, ctx->family);
net/netfilter/nft_dynset.c
175
struct nftables_pernet *nft_net = nft_pernet(ctx->net);
net/netfilter/nft_dynset.c
177
u8 genmask = nft_genmask_next(ctx->net);
net/netfilter/nft_dynset.c
199
set = nft_set_lookup_global(ctx->net, ctx->table,
net/netfilter/nft_dynset.c
34
.net = read_pnet(&priv->set->net),
net/netfilter/nft_exthdr.c
108
if (__ip_options_compile(net, opt, NULL, &info))
net/netfilter/nft_exthdr.c
82
static int ipv4_find_option(struct net *net, struct sk_buff *skb,
net/netfilter/nft_flow_offload.c
161
u8 genmask = nft_genmask_next(ctx->net);
net/netfilter/nft_flow_offload.c
167
flowtable = nft_flowtable_lookup(ctx->net, ctx->table,
net/netfilter/nft_flow_offload.c
177
return nf_ct_netns_get(ctx->net, ctx->family);
net/netfilter/nft_flow_offload.c
200
nf_ct_netns_put(ctx->net, ctx->family);
net/netfilter/nft_immediate.c
118
nft_clear(ctx->net, chain);
net/netfilter/nft_immediate.c
161
nft_deactivate_next(ctx->net, chain);
net/netfilter/nft_immediate.c
165
nft_deactivate_next(ctx->net, chain);
net/netfilter/nft_log.c
159
if (nft_log_modprobe(ctx->net, li->type) == -EAGAIN)
net/netfilter/nft_log.c
75
static int nft_log_modprobe(struct net *net, enum nf_log_type t)
net/netfilter/nft_log.c
79
return nft_request_module(net, "%s", "nf_log_syslog");
net/netfilter/nft_log.c
81
return nft_request_module(net, "%s", "nfnetlink_log");
net/netfilter/nft_lookup.c
101
const struct net *net = nft_net(pkt);
net/netfilter/nft_lookup.c
105
ext = nft_set_do_lookup(net, set, &regs->data[priv->sreg]);
net/netfilter/nft_lookup.c
107
ext = nft_set_catchall_lookup(net, set);
net/netfilter/nft_lookup.c
139
u8 genmask = nft_genmask_next(ctx->net);
net/netfilter/nft_lookup.c
148
set = nft_set_lookup_global(ctx->net, ctx->table, tb[NFTA_LOOKUP_SET],
net/netfilter/nft_lookup.c
250
.genmask = nft_genmask_next(ctx->net),
net/netfilter/nft_lookup.c
28
__nft_set_do_lookup(const struct net *net, const struct nft_set *set,
net/netfilter/nft_lookup.c
33
return nft_hash_lookup_fast(net, set, key);
net/netfilter/nft_lookup.c
35
return nft_hash_lookup(net, set, key);
net/netfilter/nft_lookup.c
38
return nft_rhash_lookup(net, set, key);
net/netfilter/nft_lookup.c
41
return nft_bitmap_lookup(net, set, key);
net/netfilter/nft_lookup.c
44
return nft_pipapo_lookup(net, set, key);
net/netfilter/nft_lookup.c
47
return nft_pipapo_avx2_lookup(net, set, key);
net/netfilter/nft_lookup.c
51
return nft_rbtree_lookup(net, set, key);
net/netfilter/nft_lookup.c
55
return set->ops->lookup(net, set, key);
net/netfilter/nft_lookup.c
58
static unsigned int nft_base_seq(const struct net *net)
net/netfilter/nft_lookup.c
61
return smp_load_acquire(&net->nft.base_seq);
net/netfilter/nft_lookup.c
64
static bool nft_lookup_should_retry(const struct net *net, unsigned int seq)
net/netfilter/nft_lookup.c
66
return unlikely(seq != nft_base_seq(net));
net/netfilter/nft_lookup.c
70
nft_set_do_lookup(const struct net *net, const struct nft_set *set,
net/netfilter/nft_lookup.c
77
base_seq = nft_base_seq(net);
net/netfilter/nft_lookup.c
79
ext = __nft_set_do_lookup(net, set, key);
net/netfilter/nft_lookup.c
89
} while (nft_lookup_should_retry(net, base_seq));
net/netfilter/nft_masq.c
134
nf_ct_netns_put(ctx->net, NFPROTO_IPV4);
net/netfilter/nft_masq.c
161
nf_ct_netns_put(ctx->net, NFPROTO_IPV6);
net/netfilter/nft_masq.c
202
nf_ct_netns_put(ctx->net, NFPROTO_INET);
net/netfilter/nft_masq.c
70
return nf_ct_netns_get(ctx->net, ctx->family);
net/netfilter/nft_nat.c
257
return nf_ct_netns_get(ctx->net, family);
net/netfilter/nft_nat.c
311
nf_ct_netns_put(ctx->net, priv->family);
net/netfilter/nft_objref.c
140
struct net *net = nft_net(pkt);
net/netfilter/nft_objref.c
144
ext = nft_set_do_lookup(net, set, &regs->data[priv->sreg]);
net/netfilter/nft_objref.c
146
ext = nft_set_catchall_lookup(net, set);
net/netfilter/nft_objref.c
161
u8 genmask = nft_genmask_next(ctx->net);
net/netfilter/nft_objref.c
165
set = nft_set_lookup_global(ctx->net, ctx->table,
net/netfilter/nft_objref.c
59
u8 genmask = nft_genmask_next(ctx->net);
net/netfilter/nft_objref.c
67
obj = nft_obj_lookup(ctx->net, ctx->table,
net/netfilter/nft_payload.c
1178
if (ctx->net->user_ns != &init_user_ns)
net/netfilter/nft_redir.c
137
nf_ct_netns_put(ctx->net, NFPROTO_IPV4);
net/netfilter/nft_redir.c
164
nf_ct_netns_put(ctx->net, NFPROTO_IPV6);
net/netfilter/nft_redir.c
192
nf_ct_netns_put(ctx->net, NFPROTO_INET);
net/netfilter/nft_redir.c
74
return nf_ct_netns_get(ctx->net, ctx->family);
net/netfilter/nft_reject_netdev.c
27
static void nft_reject_netdev_send_v4_tcp_reset(struct net *net,
net/netfilter/nft_reject_netdev.c
34
nskb = nf_reject_skb_v4_tcp_reset(net, oldskb, dev, hook);
net/netfilter/nft_reject_netdev.c
41
static void nft_reject_netdev_send_v4_unreach(struct net *net,
net/netfilter/nft_reject_netdev.c
48
nskb = nf_reject_skb_v4_unreach(net, oldskb, dev, hook, code);
net/netfilter/nft_reject_netdev.c
55
static void nft_reject_netdev_send_v6_tcp_reset(struct net *net,
net/netfilter/nft_reject_netdev.c
62
nskb = nf_reject_skb_v6_tcp_reset(net, oldskb, dev, hook);
net/netfilter/nft_reject_netdev.c
70
static void nft_reject_netdev_send_v6_unreach(struct net *net,
net/netfilter/nft_reject_netdev.c
77
nskb = nf_reject_skb_v6_unreach(net, oldskb, dev, hook, code);
net/netfilter/nft_set_bitmap.c
104
lockdep_is_held(&nft_pernet(net)->commit_mutex)) {
net/netfilter/nft_set_bitmap.c
116
nft_bitmap_get(const struct net *net, const struct nft_set *set,
net/netfilter/nft_set_bitmap.c
120
u8 genmask = nft_genmask_cur(net);
net/netfilter/nft_set_bitmap.c
133
static int nft_bitmap_insert(const struct net *net, const struct nft_set *set,
net/netfilter/nft_set_bitmap.c
139
u8 genmask = nft_genmask_next(net);
net/netfilter/nft_set_bitmap.c
142
be = nft_bitmap_elem_find(net, set, new, genmask);
net/netfilter/nft_set_bitmap.c
156
static void nft_bitmap_remove(const struct net *net, const struct nft_set *set,
net/netfilter/nft_set_bitmap.c
161
u8 genmask = nft_genmask_next(net);
net/netfilter/nft_set_bitmap.c
170
static void nft_bitmap_activate(const struct net *net,
net/netfilter/nft_set_bitmap.c
176
u8 genmask = nft_genmask_next(net);
net/netfilter/nft_set_bitmap.c
182
nft_clear(net, &be->ext);
net/netfilter/nft_set_bitmap.c
185
static void nft_bitmap_flush(const struct net *net,
net/netfilter/nft_set_bitmap.c
191
u8 genmask = nft_genmask_next(net);
net/netfilter/nft_set_bitmap.c
197
nft_set_elem_change_active(net, set, &be->ext);
net/netfilter/nft_set_bitmap.c
201
nft_bitmap_deactivate(const struct net *net, const struct nft_set *set,
net/netfilter/nft_set_bitmap.c
206
u8 genmask = nft_genmask_next(net);
net/netfilter/nft_set_bitmap.c
211
be = nft_bitmap_elem_find(net, set, this, genmask);
net/netfilter/nft_set_bitmap.c
217
nft_set_elem_change_active(net, set, &be->ext);
net/netfilter/nft_set_bitmap.c
230
lockdep_is_held(&nft_pernet(ctx->net)->commit_mutex)) {
net/netfilter/nft_set_bitmap.c
79
nft_bitmap_lookup(const struct net *net, const struct nft_set *set,
net/netfilter/nft_set_bitmap.c
84
u8 genmask = nft_genmask_cur(net);
net/netfilter/nft_set_bitmap.c
96
nft_bitmap_elem_find(const struct net *net,
net/netfilter/nft_set_hash.c
106
nft_rhash_get(const struct net *net, const struct nft_set *set,
net/netfilter/nft_set_hash.c
112
.genmask = nft_genmask_cur(net),
net/netfilter/nft_set_hash.c
171
static int nft_rhash_insert(const struct net *net, const struct nft_set *set,
net/netfilter/nft_set_hash.c
178
.genmask = nft_genmask_next(net),
net/netfilter/nft_set_hash.c
181
.tstamp = nft_net_tstamp(net),
net/netfilter/nft_set_hash.c
197
static void nft_rhash_activate(const struct net *net, const struct nft_set *set,
net/netfilter/nft_set_hash.c
202
nft_clear(net, &he->ext);
net/netfilter/nft_set_hash.c
205
static void nft_rhash_flush(const struct net *net,
net/netfilter/nft_set_hash.c
211
nft_set_elem_change_active(net, set, &he->ext);
net/netfilter/nft_set_hash.c
215
nft_rhash_deactivate(const struct net *net, const struct nft_set *set,
net/netfilter/nft_set_hash.c
221
.genmask = nft_genmask_next(net),
net/netfilter/nft_set_hash.c
224
.tstamp = nft_net_tstamp(net),
net/netfilter/nft_set_hash.c
230
nft_set_elem_change_active(net, set, &he->ext);
net/netfilter/nft_set_hash.c
237
static void nft_rhash_remove(const struct net *net,
net/netfilter/nft_set_hash.c
311
lockdep_assert_held(&nft_pernet(ctx->net)->commit_mutex);
net/netfilter/nft_set_hash.c
402
expr->ops->gc(read_pnet(&set->net), expr) &&
net/netfilter/nft_set_hash.c
418
struct net *net;
net/netfilter/nft_set_hash.c
423
net = read_pnet(&set->net);
net/netfilter/nft_set_hash.c
424
nft_net = nft_pernet(net);
net/netfilter/nft_set_hash.c
601
nft_hash_lookup(const struct net *net, const struct nft_set *set,
net/netfilter/nft_set_hash.c
605
u8 genmask = nft_genmask_cur(net);
net/netfilter/nft_set_hash.c
620
nft_hash_get(const struct net *net, const struct nft_set *set,
net/netfilter/nft_set_hash.c
625
u8 genmask = nft_genmask_cur(net);
net/netfilter/nft_set_hash.c
645
nft_hash_lookup_fast(const struct net *net, const struct nft_set *set,
net/netfilter/nft_set_hash.c
649
u8 genmask = nft_genmask_cur(net);
net/netfilter/nft_set_hash.c
682
static int nft_hash_insert(const struct net *net, const struct nft_set *set,
net/netfilter/nft_set_hash.c
688
u8 genmask = nft_genmask_next(net);
net/netfilter/nft_set_hash.c
704
static void nft_hash_activate(const struct net *net, const struct nft_set *set,
net/netfilter/nft_set_hash.c
709
nft_clear(net, &he->ext);
net/netfilter/nft_set_hash.c
712
static void nft_hash_flush(const struct net *net,
net/netfilter/nft_set_hash.c
718
nft_set_elem_change_active(net, set, &he->ext);
net/netfilter/nft_set_hash.c
722
nft_hash_deactivate(const struct net *net, const struct nft_set *set,
net/netfilter/nft_set_hash.c
727
u8 genmask = nft_genmask_next(net);
net/netfilter/nft_set_hash.c
735
nft_set_elem_change_active(net, set, &he->ext);
net/netfilter/nft_set_hash.c
742
static void nft_hash_remove(const struct net *net,
net/netfilter/nft_set_hash.c
760
lockdep_is_held(&nft_pernet(ctx->net)->commit_mutex)) {
net/netfilter/nft_set_hash.c
86
nft_rhash_lookup(const struct net *net, const struct nft_set *set,
net/netfilter/nft_set_hash.c
92
.genmask = nft_genmask_cur(net),
net/netfilter/nft_set_pipapo.c
1246
const struct net *net = read_pnet(&set->net);
net/netfilter/nft_set_pipapo.c
1248
return lockdep_is_held(&nft_pernet(net)->commit_mutex);
net/netfilter/nft_set_pipapo.c
1286
static int nft_pipapo_insert(const struct net *net, const struct nft_set *set,
net/netfilter/nft_set_pipapo.c
1294
u8 genmask = nft_genmask_next(net);
net/netfilter/nft_set_pipapo.c
1296
u64 tstamp = nft_net_tstamp(net);
net/netfilter/nft_set_pipapo.c
1330
dup = pipapo_get(m, end, nft_genmask_next(net), tstamp);
net/netfilter/nft_set_pipapo.c
1698
static void nft_pipapo_gc_deactivate(struct net *net, struct nft_set *set,
net/netfilter/nft_set_pipapo.c
1702
nft_setelem_data_deactivate(net, set, &e->priv);
net/netfilter/nft_set_pipapo.c
1713
struct net *net = read_pnet(&set->net);
net/netfilter/nft_set_pipapo.c
1715
u64 tstamp = nft_net_tstamp(net);
net/netfilter/nft_set_pipapo.c
1760
nft_pipapo_gc_deactivate(net, set, e);
net/netfilter/nft_set_pipapo.c
1896
static void nft_pipapo_activate(const struct net *net,
net/netfilter/nft_set_pipapo.c
1902
nft_clear(net, &e->ext);
net/netfilter/nft_set_pipapo.c
1914
nft_pipapo_deactivate(const struct net *net, const struct nft_set *set,
net/netfilter/nft_set_pipapo.c
1927
nft_genmask_next(net), nft_net_tstamp(net));
net/netfilter/nft_set_pipapo.c
1931
nft_set_elem_change_active(net, set, &e->ext);
net/netfilter/nft_set_pipapo.c
1954
static void nft_pipapo_flush(const struct net *net, const struct nft_set *set,
net/netfilter/nft_set_pipapo.c
1959
nft_set_elem_change_active(net, set, &e->ext);
net/netfilter/nft_set_pipapo.c
2089
static void nft_pipapo_remove(const struct net *net, const struct nft_set *set,
net/netfilter/nft_set_pipapo.c
572
nft_pipapo_lookup(const struct net *net, const struct nft_set *set,
net/netfilter/nft_set_pipapo.c
598
nft_pipapo_get(const struct net *net, const struct nft_set *set,
net/netfilter/nft_set_pipapo.c
606
nft_genmask_cur(net), get_jiffies_64());
net/netfilter/nft_set_pipapo_avx2.c
1256
nft_pipapo_avx2_lookup(const struct net *net, const struct nft_set *set,
net/netfilter/nft_set_pipapo_avx2.c
1269
ext = nft_pipapo_lookup(net, set, key);
net/netfilter/nft_set_rbtree.c
108
nft_rbtree_lookup(const struct net *net, const struct nft_set *set,
net/netfilter/nft_set_rbtree.c
1109
lockdep_is_held(&nft_pernet(read_pnet(&set->net))->commit_mutex));
net/netfilter/nft_set_rbtree.c
166
nft_rbtree_get(const struct net *net, const struct nft_set *set,
net/netfilter/nft_set_rbtree.c
199
static void nft_rbtree_gc_elem_move(struct net *net, struct nft_set *set,
net/netfilter/nft_set_rbtree.c
204
nft_setelem_data_deactivate(net, set, &rbe->priv);
net/netfilter/nft_set_rbtree.c
217
struct net *net = read_pnet(&set->net);
net/netfilter/nft_set_rbtree.c
236
nft_rbtree_gc_elem_move(net, set, priv, rbe_prev);
net/netfilter/nft_set_rbtree.c
239
nft_rbtree_gc_elem_move(net, set, priv, rbe);
net/netfilter/nft_set_rbtree.c
317
static bool nft_rbtree_insert_same_interval(const struct net *net,
net/netfilter/nft_set_rbtree.c
321
u8 genmask = nft_genmask_next(net);
net/netfilter/nft_set_rbtree.c
342
static int __nft_rbtree_insert(const struct net *net, const struct nft_set *set,
net/netfilter/nft_set_rbtree.c
349
u8 cur_genmask = nft_genmask_cur(net);
net/netfilter/nft_set_rbtree.c
350
u8 genmask = nft_genmask_next(net);
net/netfilter/nft_set_rbtree.c
482
if (!nft_rbtree_insert_same_interval(net, priv, rbe_le))
net/netfilter/nft_set_rbtree.c
683
static int nft_rbtree_insert(const struct net *net, const struct nft_set *set,
net/netfilter/nft_set_rbtree.c
689
u64 tstamp = nft_net_tstamp(net);
net/netfilter/nft_set_rbtree.c
704
err = __nft_rbtree_insert(net, set, rbe, elem_priv, tstamp);
net/netfilter/nft_set_rbtree.c
711
static void nft_rbtree_remove(const struct net *net,
net/netfilter/nft_set_rbtree.c
723
static void nft_rbtree_activate(const struct net *net,
net/netfilter/nft_set_rbtree.c
729
nft_clear(net, &rbe->ext);
net/netfilter/nft_set_rbtree.c
749
static bool nft_rbtree_deactivate_same_interval(const struct net *net,
net/netfilter/nft_set_rbtree.c
753
u8 genmask = nft_genmask_next(net);
net/netfilter/nft_set_rbtree.c
774
static void nft_rbtree_flush(const struct net *net,
net/netfilter/nft_set_rbtree.c
780
nft_set_elem_change_active(net, set, &rbe->ext);
net/netfilter/nft_set_rbtree.c
784
nft_rbtree_deactivate(const struct net *net, const struct nft_set *set,
net/netfilter/nft_set_rbtree.c
790
u8 genmask = nft_genmask_next(net);
net/netfilter/nft_set_rbtree.c
791
u64 tstamp = nft_net_tstamp(net);
net/netfilter/nft_set_rbtree.c
830
else if (!nft_rbtree_deactivate_same_interval(net, priv, rbe))
net/netfilter/nft_set_rbtree.c
833
nft_rbtree_flush(net, set, &rbe->priv);
net/netfilter/nft_set_rbtree.c
876
lockdep_assert_held(&nft_pernet(ctx->net)->commit_mutex);
net/netfilter/nft_set_rbtree.c
896
struct net *net = read_pnet(&set->net);
net/netfilter/nft_set_rbtree.c
897
u64 tstamp = nft_net_tstamp(net);
net/netfilter/nft_set_rbtree.c
921
nft_rbtree_gc_elem_move(net, set, priv, rbe_end);
net/netfilter/nft_set_rbtree.c
925
nft_rbtree_gc_elem_move(net, set, priv, rbe);
net/netfilter/nft_synproxy.c
156
struct synproxy_net *snet = synproxy_pernet(ctx->net);
net/netfilter/nft_synproxy.c
171
err = nf_ct_netns_get(ctx->net, ctx->family);
net/netfilter/nft_synproxy.c
177
err = nf_synproxy_ipv4_init(snet, ctx->net);
net/netfilter/nft_synproxy.c
183
err = nf_synproxy_ipv6_init(snet, ctx->net);
net/netfilter/nft_synproxy.c
189
err = nf_synproxy_ipv4_init(snet, ctx->net);
net/netfilter/nft_synproxy.c
192
err = nf_synproxy_ipv6_init(snet, ctx->net);
net/netfilter/nft_synproxy.c
194
nf_synproxy_ipv4_fini(snet, ctx->net);
net/netfilter/nft_synproxy.c
203
nf_ct_netns_put(ctx->net, ctx->family);
net/netfilter/nft_synproxy.c
209
struct synproxy_net *snet = synproxy_pernet(ctx->net);
net/netfilter/nft_synproxy.c
213
nf_synproxy_ipv4_fini(snet, ctx->net);
net/netfilter/nft_synproxy.c
217
nf_synproxy_ipv6_fini(snet, ctx->net);
net/netfilter/nft_synproxy.c
221
nf_synproxy_ipv4_fini(snet, ctx->net);
net/netfilter/nft_synproxy.c
222
nf_synproxy_ipv6_fini(snet, ctx->net);
net/netfilter/nft_synproxy.c
225
nf_ct_netns_put(ctx->net, ctx->family);
net/netfilter/nft_synproxy.c
52
struct net *net = nft_net(pkt);
net/netfilter/nft_synproxy.c
53
struct synproxy_net *snet = synproxy_pernet(net);
net/netfilter/nft_synproxy.c
59
synproxy_send_client_synack(net, skb, tcp, opts);
net/netfilter/nft_synproxy.c
64
if (synproxy_recv_client_ack(net, skb, tcp, opts,
net/netfilter/nft_synproxy.c
83
struct net *net = nft_net(pkt);
net/netfilter/nft_synproxy.c
84
struct synproxy_net *snet = synproxy_pernet(net);
net/netfilter/nft_synproxy.c
90
synproxy_send_client_synack_ipv6(net, skb, tcp, opts);
net/netfilter/nft_synproxy.c
95
if (synproxy_recv_client_ack_ipv6(net, skb, tcp, opts,
net/netfilter/nft_tproxy.c
229
err = nf_defrag_ipv4_enable(ctx->net);
net/netfilter/nft_tproxy.c
236
err = nf_defrag_ipv6_enable(ctx->net);
net/netfilter/nft_tproxy.c
243
err = nf_defrag_ipv4_enable(ctx->net);
net/netfilter/nft_tproxy.c
247
err = nf_defrag_ipv6_enable(ctx->net);
net/netfilter/nft_tproxy.c
280
nf_defrag_ipv4_disable(ctx->net);
net/netfilter/nft_tproxy.c
284
nf_defrag_ipv6_disable(ctx->net);
net/netfilter/nft_tproxy.c
288
nf_defrag_ipv4_disable(ctx->net);
net/netfilter/nft_tproxy.c
290
nf_defrag_ipv6_disable(ctx->net);
net/netfilter/utils.c
163
int nf_route(struct net *net, struct dst_entry **dst, struct flowi *fl,
net/netfilter/utils.c
170
ret = nf_ip_route(net, dst, fl, strict);
net/netfilter/utils.c
173
ret = nf_ip6_route(net, dst, fl, strict);
net/netfilter/x_tables.c
1310
struct xt_table *xt_find_table(struct net *net, u8 af, const char *name)
net/netfilter/x_tables.c
1312
struct xt_pernet *xt_net = net_generic(net, xt_pernet_id);
net/netfilter/x_tables.c
1328
struct xt_table *xt_find_table_lock(struct net *net, u_int8_t af,
net/netfilter/x_tables.c
1331
struct xt_pernet *xt_net = net_generic(net, xt_pernet_id);
net/netfilter/x_tables.c
1353
err = tmpl->table_init(net);
net/netfilter/x_tables.c
1375
struct xt_table *xt_request_find_table_lock(struct net *net, u_int8_t af,
net/netfilter/x_tables.c
1378
struct xt_table *t = xt_find_table_lock(net, af, name);
net/netfilter/x_tables.c
1385
t = xt_find_table_lock(net, af, name);
net/netfilter/x_tables.c
1555
struct xt_table *xt_register_table(struct net *net,
net/netfilter/x_tables.c
1561
struct xt_pernet *xt_net = net_generic(net, xt_pernet_id);
net/netfilter/x_tables.c
1611
ret = nf_register_net_hooks(net, ops, num_ops);
net/netfilter/x_tables.c
1658
void xt_unregister_table_pre_exit(struct net *net, u8 af, const char *name)
net/netfilter/x_tables.c
1660
struct xt_pernet *xt_net = net_generic(net, xt_pernet_id);
net/netfilter/x_tables.c
1670
nf_unregister_net_hooks(net, t->ops, hweight32(t->valid_hooks));
net/netfilter/x_tables.c
1694
struct xt_table *xt_unregister_table_exit(struct net *net, u8 af, const char *name)
net/netfilter/x_tables.c
1696
struct xt_pernet *xt_net = net_generic(net, xt_pernet_id);
net/netfilter/x_tables.c
1727
struct net *net = seq_file_net(seq);
net/netfilter/x_tables.c
1730
xt_net = net_generic(net, xt_pernet_id);
net/netfilter/x_tables.c
1739
struct net *net = seq_file_net(seq);
net/netfilter/x_tables.c
1742
xt_net = net_generic(net, xt_pernet_id);
net/netfilter/x_tables.c
1968
int (*table_init)(struct net *net))
net/netfilter/x_tables.c
2019
int xt_proto_init(struct net *net, u_int8_t af)
net/netfilter/x_tables.c
2033
root_uid = make_kuid(net->user_ns, 0);
net/netfilter/x_tables.c
2034
root_gid = make_kgid(net->user_ns, 0);
net/netfilter/x_tables.c
2038
proc = proc_create_net_data(buf, 0440, net->proc_net, &xt_table_seq_ops,
net/netfilter/x_tables.c
2048
proc = proc_create_seq_private(buf, 0440, net->proc_net,
net/netfilter/x_tables.c
2058
proc = proc_create_seq_private(buf, 0440, net->proc_net,
net/netfilter/x_tables.c
2073
remove_proc_entry(buf, net->proc_net);
net/netfilter/x_tables.c
2078
remove_proc_entry(buf, net->proc_net);
net/netfilter/x_tables.c
2085
void xt_proto_fini(struct net *net, u_int8_t af)
net/netfilter/x_tables.c
2092
remove_proc_entry(buf, net->proc_net);
net/netfilter/x_tables.c
2096
remove_proc_entry(buf, net->proc_net);
net/netfilter/x_tables.c
2100
remove_proc_entry(buf, net->proc_net);
net/netfilter/x_tables.c
2162
static int __net_init xt_net_init(struct net *net)
net/netfilter/x_tables.c
2164
struct xt_pernet *xt_net = net_generic(net, xt_pernet_id);
net/netfilter/x_tables.c
2174
static void __net_exit xt_net_exit(struct net *net)
net/netfilter/x_tables.c
2176
struct xt_pernet *xt_net = net_generic(net, xt_pernet_id);
net/netfilter/x_tables.c
46
int (*table_init)(struct net *net);
net/netfilter/xt_CONNSECMARK.c
105
ret = nf_ct_netns_get(par->net, par->family);
net/netfilter/xt_CONNSECMARK.c
114
nf_ct_netns_put(par->net, par->family);
net/netfilter/xt_CT.c
119
return nf_ct_set_timeout(par->net, ct, par->family, l4proto->l4proto,
net/netfilter/xt_CT.c
175
ret = nf_ct_netns_get(par->net, par->family);
net/netfilter/xt_CT.c
185
ct = nf_ct_tmpl_alloc(par->net, &zone, GFP_KERNEL);
net/netfilter/xt_CT.c
230
nf_ct_netns_put(par->net, par->family);
net/netfilter/xt_CT.c
290
nf_ct_netns_put(par->net, par->family);
net/netfilter/xt_LOG.c
32
struct net *net = xt_net(par);
net/netfilter/xt_LOG.c
39
nf_log_packet(net, xt_family(par), xt_hooknum(par), skb, xt_in(par),
net/netfilter/xt_MASQUERADE.c
31
return nf_ct_netns_get(par->net, par->family);
net/netfilter/xt_MASQUERADE.c
51
nf_ct_netns_put(par->net, par->family);
net/netfilter/xt_MASQUERADE.c
68
return nf_ct_netns_get(par->net, par->family);
net/netfilter/xt_NETMAP.c
116
return nf_ct_netns_get(par->net, par->family);
net/netfilter/xt_NETMAP.c
60
return nf_ct_netns_get(par->net, par->family);
net/netfilter/xt_NETMAP.c
65
nf_ct_netns_put(par->net, par->family);
net/netfilter/xt_NFLOG.c
24
struct net *net = xt_net(par);
net/netfilter/xt_NFLOG.c
36
nf_log_packet(net, xt_family(par), xt_hooknum(par), skb, xt_in(par),
net/netfilter/xt_RATEEST.c
109
struct xt_rateest_net *xn = net_generic(par->net, xt_rateest_id);
net/netfilter/xt_RATEEST.c
134
xt_rateest_put(par->net, est);
net/netfilter/xt_RATEEST.c
179
xt_rateest_put(par->net, info->est);
net/netfilter/xt_RATEEST.c
209
static __net_init int xt_rateest_net_init(struct net *net)
net/netfilter/xt_RATEEST.c
211
struct xt_rateest_net *xn = net_generic(net, xt_rateest_id);
net/netfilter/xt_RATEEST.c
63
struct xt_rateest *xt_rateest_lookup(struct net *net, const char *name)
net/netfilter/xt_RATEEST.c
65
struct xt_rateest_net *xn = net_generic(net, xt_rateest_id);
net/netfilter/xt_RATEEST.c
75
void xt_rateest_put(struct net *net, struct xt_rateest *est)
net/netfilter/xt_RATEEST.c
77
struct xt_rateest_net *xn = net_generic(net, xt_rateest_id);
net/netfilter/xt_REDIRECT.c
41
return nf_ct_netns_get(par->net, par->family);
net/netfilter/xt_REDIRECT.c
46
nf_ct_netns_put(par->net, par->family);
net/netfilter/xt_REDIRECT.c
61
return nf_ct_netns_get(par->net, par->family);
net/netfilter/xt_TCPMSS.c
103
struct net *net = xt_net(par);
net/netfilter/xt_TCPMSS.c
104
unsigned int in_mtu = tcpmss_reverse_mtu(net, skb, family);
net/netfilter/xt_TCPMSS.c
43
static u_int32_t tcpmss_reverse_mtu(struct net *net,
net/netfilter/xt_TCPMSS.c
62
nf_route(net, (struct dst_entry **)&rt, &fl, false, family);
net/netfilter/xt_TEE.c
117
dev = dev_get_by_name(par->net, info->oif);
net/netfilter/xt_TEE.c
134
struct tee_net *tn = net_generic(par->net, tee_net_id);
net/netfilter/xt_TEE.c
173
static int __net_init tee_net_init(struct net *net)
net/netfilter/xt_TEE.c
175
struct tee_net *tn = net_generic(net, tee_net_id);
net/netfilter/xt_TEE.c
64
struct net *net = dev_net(dev);
net/netfilter/xt_TEE.c
65
struct tee_net *tn = net_generic(net, tee_net_id);
net/netfilter/xt_TEE.c
94
struct tee_net *tn = net_generic(par->net, tee_net_id);
net/netfilter/xt_TPROXY.c
178
err = nf_defrag_ipv6_enable(par->net);
net/netfilter/xt_TPROXY.c
192
nf_defrag_ipv6_disable(par->net);
net/netfilter/xt_TPROXY.c
201
err = nf_defrag_ipv4_enable(par->net);
net/netfilter/xt_TPROXY.c
215
nf_defrag_ipv4_disable(par->net);
net/netfilter/xt_TPROXY.c
36
tproxy_tg4(struct net *net, struct sk_buff *skb, __be32 laddr, __be16 lport,
net/netfilter/xt_TPROXY.c
51
sk = nf_tproxy_get_sock_v4(net, skb, iph->protocol,
net/netfilter/xt_TPROXY.c
63
sk = nf_tproxy_handle_time_wait4(net, skb, laddr, lport, sk);
net/netfilter/xt_TPROXY.c
67
sk = nf_tproxy_get_sock_v4(net, skb, iph->protocol,
net/netfilter/xt_addrtype.c
104
static inline bool match_type(struct net *net, const struct net_device *dev,
net/netfilter/xt_addrtype.c
107
return !!(mask & (1 << inet_dev_addr_type(net, dev, addr)));
net/netfilter/xt_addrtype.c
113
struct net *net = xt_net(par);
net/netfilter/xt_addrtype.c
119
ret &= match_type(net, NULL, iph->saddr, info->source) ^
net/netfilter/xt_addrtype.c
122
ret &= match_type(net, NULL, iph->daddr, info->dest) ^
net/netfilter/xt_addrtype.c
131
struct net *net = xt_net(par);
net/netfilter/xt_addrtype.c
144
return addrtype_mt6(net, dev, skb, info);
net/netfilter/xt_addrtype.c
148
ret &= match_type(net, dev, iph->saddr, info->source) ^
net/netfilter/xt_addrtype.c
151
ret &= match_type(net, dev, iph->daddr, info->dest) ^
net/netfilter/xt_addrtype.c
33
static u32 match_lookup_rt6(struct net *net, const struct net_device *dev,
net/netfilter/xt_addrtype.c
47
if (nf_ipv6_chk_addr(net, addr, dev, true))
net/netfilter/xt_addrtype.c
51
route_err = nf_ip6_route(net, (struct dst_entry **)&rt,
net/netfilter/xt_addrtype.c
68
static bool match_type6(struct net *net, const struct net_device *dev,
net/netfilter/xt_addrtype.c
83
return !!(mask & match_lookup_rt6(net, dev, addr, mask));
net/netfilter/xt_addrtype.c
88
addrtype_mt6(struct net *net, const struct net_device *dev,
net/netfilter/xt_addrtype.c
95
ret &= match_type6(net, dev, &iph->saddr, info->source) ^
net/netfilter/xt_addrtype.c
98
ret &= match_type6(net, dev, &iph->daddr, info->dest) ^
net/netfilter/xt_cluster.c
137
ret = nf_ct_netns_get(par->net, par->family);
net/netfilter/xt_cluster.c
146
nf_ct_netns_put(par->net, par->family);
net/netfilter/xt_connbytes.c
114
ret = nf_ct_netns_get(par->net, par->family);
net/netfilter/xt_connbytes.c
125
if (!nf_ct_acct_enabled(par->net)) {
net/netfilter/xt_connbytes.c
127
nf_ct_set_acct(par->net, true);
net/netfilter/xt_connbytes.c
135
nf_ct_netns_put(par->net, par->family);
net/netfilter/xt_connlabel.c
62
ret = nf_ct_netns_get(par->net, par->family);
net/netfilter/xt_connlabel.c
69
ret = nf_connlabels_get(par->net, info->bit);
net/netfilter/xt_connlabel.c
71
nf_ct_netns_put(par->net, par->family);
net/netfilter/xt_connlabel.c
77
nf_connlabels_put(par->net);
net/netfilter/xt_connlabel.c
78
nf_ct_netns_put(par->net, par->family);
net/netfilter/xt_connlimit.c
100
nf_ct_netns_put(par->net, par->family);
net/netfilter/xt_connlimit.c
109
nf_conncount_destroy(par->net, info->data);
net/netfilter/xt_connlimit.c
110
nf_ct_netns_put(par->net, par->family);
net/netfilter/xt_connlimit.c
33
struct net *net = xt_net(par);
net/netfilter/xt_connlimit.c
66
connections = nf_conncount_count_skb(net, skb, xt_family(par), info->data, key);
net/netfilter/xt_connlimit.c
90
ret = nf_ct_netns_get(par->net, par->family);
net/netfilter/xt_connlimit.c
98
info->data = nf_conncount_init(par->net, keylen);
net/netfilter/xt_connmark.c
108
ret = nf_ct_netns_get(par->net, par->family);
net/netfilter/xt_connmark.c
127
nf_ct_netns_put(par->net, par->family);
net/netfilter/xt_connmark.c
148
ret = nf_ct_netns_get(par->net, par->family);
net/netfilter/xt_connmark.c
157
nf_ct_netns_put(par->net, par->family);
net/netfilter/xt_conntrack.c
270
ret = nf_ct_netns_get(par->net, par->family);
net/netfilter/xt_conntrack.c
279
nf_ct_netns_put(par->net, par->family);
net/netfilter/xt_hashlimit.c
1237
static int __net_init hashlimit_proc_net_init(struct net *net)
net/netfilter/xt_hashlimit.c
1239
struct hashlimit_net *hashlimit_net = hashlimit_pernet(net);
net/netfilter/xt_hashlimit.c
1241
hashlimit_net->ipt_hashlimit = proc_mkdir("ipt_hashlimit", net->proc_net);
net/netfilter/xt_hashlimit.c
1245
hashlimit_net->ip6t_hashlimit = proc_mkdir("ip6t_hashlimit", net->proc_net);
net/netfilter/xt_hashlimit.c
1247
remove_proc_entry("ipt_hashlimit", net->proc_net);
net/netfilter/xt_hashlimit.c
1254
static void __net_exit hashlimit_proc_net_exit(struct net *net)
net/netfilter/xt_hashlimit.c
1257
struct hashlimit_net *hashlimit_net = hashlimit_pernet(net);
net/netfilter/xt_hashlimit.c
1270
remove_proc_entry("ipt_hashlimit", net->proc_net);
net/netfilter/xt_hashlimit.c
1272
remove_proc_entry("ip6t_hashlimit", net->proc_net);
net/netfilter/xt_hashlimit.c
1276
static int __net_init hashlimit_net_init(struct net *net)
net/netfilter/xt_hashlimit.c
1278
struct hashlimit_net *hashlimit_net = hashlimit_pernet(net);
net/netfilter/xt_hashlimit.c
1281
return hashlimit_proc_net_init(net);
net/netfilter/xt_hashlimit.c
1284
static void __net_exit hashlimit_net_exit(struct net *net)
net/netfilter/xt_hashlimit.c
1286
hashlimit_proc_net_exit(net);
net/netfilter/xt_hashlimit.c
132
struct net *net;
net/netfilter/xt_hashlimit.c
274
static int htable_create(struct net *net, struct hashlimit_cfg3 *cfg,
net/netfilter/xt_hashlimit.c
279
struct hashlimit_net *hashlimit_net = hashlimit_pernet(net);
net/netfilter/xt_hashlimit.c
348
hinfo->net = net;
net/netfilter/xt_hashlimit.c
395
struct hashlimit_net *hashlimit_net = hashlimit_pernet(hinfo->net);
net/netfilter/xt_hashlimit.c
407
static struct xt_hashlimit_htable *htable_find_get(struct net *net,
net/netfilter/xt_hashlimit.c
411
struct hashlimit_net *hashlimit_net = hashlimit_pernet(net);
net/netfilter/xt_hashlimit.c
60
static inline struct hashlimit_net *hashlimit_pernet(struct net *net)
net/netfilter/xt_hashlimit.c
62
return net_generic(net, hashlimit_net_id);
net/netfilter/xt_hashlimit.c
847
struct net *net = par->net;
net/netfilter/xt_hashlimit.c
900
*hinfo = htable_find_get(net, name, par->family);
net/netfilter/xt_hashlimit.c
902
ret = htable_create(net, cfg, name, par->family,
net/netfilter/xt_helper.c
59
ret = nf_ct_netns_get(par->net, par->family);
net/netfilter/xt_helper.c
71
nf_ct_netns_put(par->net, par->family);
net/netfilter/xt_nat.c
24
return nf_ct_netns_get(par->net, par->family);
net/netfilter/xt_nat.c
38
return nf_ct_netns_get(par->net, par->family);
net/netfilter/xt_nat.c
43
nf_ct_netns_put(par->net, par->family);
net/netfilter/xt_nfacct.c
39
nfacct = nfnl_acct_find_get(par->net, info->name);
net/netfilter/xt_owner.c
103
kgid_t gid_min = make_kgid(net->user_ns, info->gid_min);
net/netfilter/xt_owner.c
104
kgid_t gid_max = make_kgid(net->user_ns, info->gid_max);
net/netfilter/xt_owner.c
23
struct net *net = par->net;
net/netfilter/xt_owner.c
32
(current_user_ns() != net->user_ns))
net/netfilter/xt_owner.c
37
kuid_t uid_min = make_kuid(net->user_ns, info->uid_min);
net/netfilter/xt_owner.c
38
kuid_t uid_max = make_kuid(net->user_ns, info->uid_max);
net/netfilter/xt_owner.c
49
kgid_t gid_min = make_kgid(net->user_ns, info->gid_min);
net/netfilter/xt_owner.c
50
kgid_t gid_max = make_kgid(net->user_ns, info->gid_max);
net/netfilter/xt_owner.c
67
struct net *net = xt_net(par);
net/netfilter/xt_owner.c
71
if (!sk || !READ_ONCE(sk->sk_socket) || !net_eq(net, sock_net(sk)))
net/netfilter/xt_owner.c
92
kuid_t uid_min = make_kuid(net->user_ns, info->uid_min);
net/netfilter/xt_owner.c
93
kuid_t uid_max = make_kuid(net->user_ns, info->uid_max);
net/netfilter/xt_rateest.c
100
est1 = xt_rateest_lookup(par->net, info->name1);
net/netfilter/xt_rateest.c
106
est2 = xt_rateest_lookup(par->net, info->name2);
net/netfilter/xt_rateest.c
116
xt_rateest_put(par->net, est1);
net/netfilter/xt_rateest.c
125
xt_rateest_put(par->net, info->est1);
net/netfilter/xt_rateest.c
127
xt_rateest_put(par->net, info->est2);
net/netfilter/xt_recent.c
242
struct net *net = xt_net(par);
net/netfilter/xt_recent.c
243
struct recent_net *recent_net = recent_pernet(net);
net/netfilter/xt_recent.c
273
(!skb->sk || !net_eq(net, sock_net(skb->sk))))
net/netfilter/xt_recent.c
335
struct recent_net *recent_net = recent_pernet(par->net);
net/netfilter/xt_recent.c
453
struct recent_net *recent_net = recent_pernet(par->net);
net/netfilter/xt_recent.c
635
static int __net_init recent_proc_net_init(struct net *net)
net/netfilter/xt_recent.c
637
struct recent_net *recent_net = recent_pernet(net);
net/netfilter/xt_recent.c
639
recent_net->xt_recent = proc_mkdir("xt_recent", net->proc_net);
net/netfilter/xt_recent.c
645
static void __net_exit recent_proc_net_exit(struct net *net)
net/netfilter/xt_recent.c
647
struct recent_net *recent_net = recent_pernet(net);
net/netfilter/xt_recent.c
661
remove_proc_entry("xt_recent", net->proc_net);
net/netfilter/xt_recent.c
664
static inline int recent_proc_net_init(struct net *net)
net/netfilter/xt_recent.c
669
static inline void recent_proc_net_exit(struct net *net)
net/netfilter/xt_recent.c
674
static int __net_init recent_net_init(struct net *net)
net/netfilter/xt_recent.c
676
struct recent_net *recent_net = recent_pernet(net);
net/netfilter/xt_recent.c
679
return recent_proc_net_init(net);
net/netfilter/xt_recent.c
682
static void __net_exit recent_net_exit(struct net *net)
net/netfilter/xt_recent.c
684
recent_proc_net_exit(net);
net/netfilter/xt_recent.c
97
static inline struct recent_net *recent_pernet(struct net *net)
net/netfilter/xt_recent.c
99
return net_generic(net, recent_net_id);
net/netfilter/xt_set.c
112
ip_set_nfnl_put(par->net, info->match_set.index);
net/netfilter/xt_set.c
139
index = ip_set_nfnl_get_byindex(par->net, info->match_set.index);
net/netfilter/xt_set.c
148
ip_set_nfnl_put(par->net, info->match_set.index);
net/netfilter/xt_set.c
160
ip_set_nfnl_put(par->net, info->match_set.index);
net/netfilter/xt_set.c
238
index = ip_set_nfnl_get_byindex(par->net, info->add_set.index);
net/netfilter/xt_set.c
247
index = ip_set_nfnl_get_byindex(par->net, info->del_set.index);
net/netfilter/xt_set.c
252
ip_set_nfnl_put(par->net, info->add_set.index);
net/netfilter/xt_set.c
260
ip_set_nfnl_put(par->net, info->add_set.index);
net/netfilter/xt_set.c
262
ip_set_nfnl_put(par->net, info->del_set.index);
net/netfilter/xt_set.c
279
ip_set_nfnl_put(par->net, info->add_set.index);
net/netfilter/xt_set.c
281
ip_set_nfnl_put(par->net, info->del_set.index);
net/netfilter/xt_set.c
313
index = ip_set_nfnl_get_byindex(par->net, info->add_set.index);
net/netfilter/xt_set.c
322
index = ip_set_nfnl_get_byindex(par->net, info->del_set.index);
net/netfilter/xt_set.c
327
ip_set_nfnl_put(par->net, info->add_set.index);
net/netfilter/xt_set.c
335
ip_set_nfnl_put(par->net, info->add_set.index);
net/netfilter/xt_set.c
337
ip_set_nfnl_put(par->net, info->del_set.index);
net/netfilter/xt_set.c
350
ip_set_nfnl_put(par->net, info->add_set.index);
net/netfilter/xt_set.c
352
ip_set_nfnl_put(par->net, info->del_set.index);
net/netfilter/xt_set.c
464
index = ip_set_nfnl_get_byindex(par->net,
net/netfilter/xt_set.c
474
index = ip_set_nfnl_get_byindex(par->net,
net/netfilter/xt_set.c
485
index = ip_set_nfnl_get_byindex(par->net,
net/netfilter/xt_set.c
506
ip_set_nfnl_put(par->net, info->map_set.index);
net/netfilter/xt_set.c
509
ip_set_nfnl_put(par->net, info->del_set.index);
net/netfilter/xt_set.c
512
ip_set_nfnl_put(par->net, info->add_set.index);
net/netfilter/xt_set.c
522
ip_set_nfnl_put(par->net, info->add_set.index);
net/netfilter/xt_set.c
524
ip_set_nfnl_put(par->net, info->del_set.index);
net/netfilter/xt_set.c
526
ip_set_nfnl_put(par->net, info->map_set.index);
net/netfilter/xt_set.c
88
index = ip_set_nfnl_get_byindex(par->net, info->match_set.index);
net/netfilter/xt_set.c
97
ip_set_nfnl_put(par->net, info->match_set.index);
net/netfilter/xt_socket.c
154
static int socket_mt_enable_defrag(struct net *net, int family)
net/netfilter/xt_socket.c
158
return nf_defrag_ipv4_enable(net);
net/netfilter/xt_socket.c
161
return nf_defrag_ipv6_enable(net);
net/netfilter/xt_socket.c
178
return socket_mt_enable_defrag(par->net, par->family);
net/netfilter/xt_socket.c
191
return socket_mt_enable_defrag(par->net, par->family);
net/netfilter/xt_socket.c
205
return socket_mt_enable_defrag(par->net, par->family);
net/netfilter/xt_socket.c
211
nf_defrag_ipv4_disable(par->net);
net/netfilter/xt_socket.c
214
nf_defrag_ipv6_disable(par->net);
net/netfilter/xt_state.c
42
ret = nf_ct_netns_get(par->net, par->family);
net/netfilter/xt_state.c
51
nf_ct_netns_put(par->net, par->family);
net/netlabel/netlabel_kapi.c
208
int netlbl_cfg_unlbl_static_add(struct net *net,
net/netlabel/netlabel_kapi.c
231
return netlbl_unlhsh_add(net,
net/netlabel/netlabel_kapi.c
251
int netlbl_cfg_unlbl_static_del(struct net *net,
net/netlabel/netlabel_kapi.c
273
return netlbl_unlhsh_remove(net,
net/netlabel/netlabel_unlabeled.c
364
int netlbl_unlhsh_add(struct net *net,
net/netlabel/netlabel_unlabeled.c
385
dev = dev_get_by_name_rcu(net, dev_name);
net/netlabel/netlabel_unlabeled.c
463
static int netlbl_unlhsh_remove_addr4(struct net *net,
net/netlabel/netlabel_unlabeled.c
487
dev = dev_get_by_index(net, iface->ifindex);
net/netlabel/netlabel_unlabeled.c
522
static int netlbl_unlhsh_remove_addr6(struct net *net,
net/netlabel/netlabel_unlabeled.c
545
dev = dev_get_by_index(net, iface->ifindex);
net/netlabel/netlabel_unlabeled.c
619
int netlbl_unlhsh_remove(struct net *net,
net/netlabel/netlabel_unlabeled.c
636
dev = dev_get_by_name_rcu(net, dev_name);
net/netlabel/netlabel_unlabeled.c
650
ret_val = netlbl_unlhsh_remove_addr4(net,
net/netlabel/netlabel_unlabeled.c
656
ret_val = netlbl_unlhsh_remove_addr6(net,
net/netlabel/netlabel_unlabeled.h
209
int netlbl_unlhsh_add(struct net *net,
net/netlabel/netlabel_unlabeled.h
216
int netlbl_unlhsh_remove(struct net *net,
net/netlink/af_netlink.c
1017
err = nlk->netlink_bind(net, group + 1);
net/netlink/af_netlink.c
1410
struct net *net;
net/netlink/af_netlink.c
1436
if (!net_eq(sock_net(sk), p->net)) {
net/netlink/af_netlink.c
1440
if (!peernet_has_id(sock_net(sk), p->net))
net/netlink/af_netlink.c
1443
if (!file_ns_capable(sk->sk_socket->file, p->net->user_ns,
net/netlink/af_netlink.c
1488
if (!net_eq(sock_net(sk), p->net)) {
net/netlink/af_netlink.c
1489
NETLINK_CB(p->skb2).nsid = peernet2id(sock_net(sk), p->net);
net/netlink/af_netlink.c
1514
struct net *net = sock_net(ssk);
net/netlink/af_netlink.c
1521
info.net = net;
net/netlink/af_netlink.c
195
struct net *net = dev_net(nt->dev);
net/netlink/af_netlink.c
196
struct netlink_tap_net *nn = net_generic(net, netlink_tap_net_id);
net/netlink/af_netlink.c
2007
__netlink_kernel_create(struct net *net, int unit, struct module *module,
net/netlink/af_netlink.c
2024
if (__netlink_create(net, sock, unit, 1) < 0)
net/netlink/af_netlink.c
213
struct net *net = dev_net(nt->dev);
net/netlink/af_netlink.c
214
struct netlink_tap_net *nn = net_generic(net, netlink_tap_net_id);
net/netlink/af_netlink.c
249
static __net_init int netlink_tap_init_net(struct net *net)
net/netlink/af_netlink.c
251
struct netlink_tap_net *nn = net_generic(net, netlink_tap_net_id);
net/netlink/af_netlink.c
2834
static int __net_init netlink_net_init(struct net *net)
net/netlink/af_netlink.c
2837
if (!proc_create_net("netlink", 0, net->proc_net, &netlink_seq_ops,
net/netlink/af_netlink.c
2844
static void __net_exit netlink_net_exit(struct net *net)
net/netlink/af_netlink.c
2847
remove_proc_entry("netlink", net->proc_net);
net/netlink/af_netlink.c
332
static void netlink_deliver_tap(struct net *net, struct sk_buff *skb)
net/netlink/af_netlink.c
334
struct netlink_tap_net *nn = net_generic(net, netlink_tap_net_id);
net/netlink/af_netlink.c
486
struct net *net, u32 portid)
net/netlink/af_netlink.c
489
write_pnet(&arg->pnet, net);
net/netlink/af_netlink.c
494
struct net *net)
net/netlink/af_netlink.c
498
netlink_compare_arg_init(&arg, net, portid);
net/netlink/af_netlink.c
513
static struct sock *netlink_lookup(struct net *net, int protocol, u32 portid)
net/netlink/af_netlink.c
519
sk = __netlink_lookup(table, portid, net);
net/netlink/af_netlink.c
619
static int __netlink_create(struct net *net, struct socket *sock,
net/netlink/af_netlink.c
627
sk = sk_alloc(net, PF_NETLINK, GFP_KERNEL, &netlink_proto, kern);
net/netlink/af_netlink.c
645
static int netlink_create(struct net *net, struct socket *sock, int protocol,
net/netlink/af_netlink.c
650
int (*bind)(struct net *net, int group);
net/netlink/af_netlink.c
651
void (*unbind)(struct net *net, int group);
net/netlink/af_netlink.c
685
err = __netlink_create(net, sock, protocol, kern);
net/netlink/af_netlink.c
689
sock_prot_inuse_add(net, &netlink_proto, 1);
net/netlink/af_netlink.c
758
.net = sock_net(sk),
net/netlink/af_netlink.c
804
struct net *net = sock_net(sk);
net/netlink/af_netlink.c
814
ok = !__netlink_lookup(table, portid, net);
net/netlink/af_netlink.c
974
struct net *net = sock_net(sk);
net/netlink/af_netlink.h
44
int (*netlink_bind)(struct net *net, int group);
net/netlink/af_netlink.h
45
void (*netlink_unbind)(struct net *net, int group);
net/netlink/af_netlink.h
69
int (*bind)(struct net *net, int group);
net/netlink/af_netlink.h
70
void (*unbind)(struct net *net, int group);
net/netlink/diag.c
134
if (!net_eq(sock_net(sk), net))
net/netlink/diag.c
160
if (!net_eq(sock_net(sk), net))
net/netlink/diag.c
228
struct net *net = sock_net(skb->sk);
net/netlink/diag.c
238
return netlink_dump_start(net->diag_nlsk, skb, h, &c);
net/netlink/diag.c
94
struct net *net = sock_net(skb->sk);
net/netlink/genetlink.c
1055
int hdrlen, struct net *net)
net/netlink/genetlink.c
1075
err = __netlink_dump_start(net->genl_sock, skb, nlh, &c);
net/netlink/genetlink.c
1086
int hdrlen, struct net *net)
net/netlink/genetlink.c
1105
genl_info_net_set(&info, net);
net/netlink/genetlink.c
1160
struct net *net = sock_net(skb->sk);
net/netlink/genetlink.c
1167
if (!family->netnsok && !net_eq(net, &init_net))
net/netlink/genetlink.c
1187
!netlink_ns_capable(skb, net->user_ns, CAP_NET_ADMIN))
net/netlink/genetlink.c
1192
&op, hdrlen, net);
net/netlink/genetlink.c
1195
&op, hdrlen, net);
net/netlink/genetlink.c
1356
struct net *net = sock_net(skb->sk);
net/netlink/genetlink.c
1362
if (!rt->netnsok && !net_eq(net, &init_net))
net/netlink/genetlink.c
1811
static int genl_bind(struct net *net, int group)
net/netlink/genetlink.c
1832
!ns_capable(net->user_ns, CAP_NET_ADMIN))
net/netlink/genetlink.c
1835
!ns_capable(net->user_ns, CAP_SYS_ADMIN))
net/netlink/genetlink.c
1851
static void genl_unbind(struct net *net, int group)
net/netlink/genetlink.c
1877
static int __net_init genl_pernet_init(struct net *net)
net/netlink/genetlink.c
1888
net->genl_sock = netlink_kernel_create(net, NETLINK_GENERIC, &cfg);
net/netlink/genetlink.c
1890
if (!net->genl_sock && net_eq(net, &init_net))
net/netlink/genetlink.c
1893
if (!net->genl_sock)
net/netlink/genetlink.c
1899
static void __net_exit genl_pernet_exit(struct net *net)
net/netlink/genetlink.c
1901
netlink_kernel_release(net->genl_sock);
net/netlink/genetlink.c
1902
net->genl_sock = NULL;
net/netlink/genetlink.c
1933
struct net *net, *prev = NULL;
net/netlink/genetlink.c
1938
for_each_net_rcu(net) {
net/netlink/genetlink.c
1953
prev = net;
net/netlink/genetlink.c
1988
struct net *net = genl_info_net(info);
net/netlink/genetlink.c
1989
struct sock *sk = net->genl_sock;
net/netlink/genetlink.c
501
struct net *net;
net/netlink/genetlink.c
505
for_each_net_rcu(net) {
net/netlink/genetlink.c
506
err = __netlink_change_ngroups(net->genl_sock,
net/netlink/genetlink.c
535
struct net *net;
net/netlink/genetlink.c
540
for_each_net_rcu(net) {
net/netlink/genetlink.c
543
net->genl_sock, family->mcgrp_offset + i);
net/nfc/af_nfc.c
18
static int nfc_sock_create(struct net *net, struct socket *sock, int proto,
net/nfc/af_nfc.c
23
if (net != &init_net)
net/nfc/af_nfc.c
31
rc = proto_tab[proto]->create(net, sock, proto_tab[proto], kern);
net/nfc/llcp_sock.c
1026
static int llcp_sock_create(struct net *net, struct socket *sock,
net/nfc/nfc.h
23
int (*create)(struct net *net, struct socket *sock,
net/nfc/rawsock.c
334
static int rawsock_create(struct net *net, struct socket *sock,
net/nfc/rawsock.c
345
if (!ns_capable(net->user_ns, CAP_NET_RAW))
net/nfc/rawsock.c
352
sk = sk_alloc(net, PF_NFC, GFP_ATOMIC, nfc_proto->proto, kern);
net/openvswitch/actions.c
1231
psample_group.net = ovs_dp_get_net(dp);
net/openvswitch/actions.c
691
static int ovs_vport_output(struct net *net, struct sock *sk,
net/openvswitch/actions.c
765
static void ovs_fragment(struct net *net, struct vport *vport,
net/openvswitch/actions.c
797
ip_do_fragment(net, skb->sk, skb, ovs_vport_output);
net/openvswitch/actions.c
814
ip6_fragment(net, skb->sk, skb, ovs_vport_output);
net/openvswitch/actions.c
847
struct net *net = read_pnet(&dp->net);
net/openvswitch/actions.c
849
ovs_fragment(net, vport, skb, mru, key);
net/openvswitch/conntrack.c
1037
int ovs_ct_execute(struct net *net, struct sk_buff *skb,
net/openvswitch/conntrack.c
1055
err = ovs_ct_handle_fragments(net, key, info->zone.id,
net/openvswitch/conntrack.c
1062
err = ovs_ct_commit(net, key, info, skb);
net/openvswitch/conntrack.c
1064
err = ovs_ct_lookup(net, key, info, skb);
net/openvswitch/conntrack.c
1361
bool ovs_ct_verify(struct net *net, enum ovs_key_attr attr)
net/openvswitch/conntrack.c
1373
struct ovs_net *ovs_net = net_generic(net, ovs_net_id);
net/openvswitch/conntrack.c
1381
int ovs_ct_copy_action(struct net *net, const struct nlattr *attr,
net/openvswitch/conntrack.c
1407
ct_info.ct = nf_ct_tmpl_alloc(net, &ct_info.zone, GFP_KERNEL);
net/openvswitch/conntrack.c
1414
if (nf_ct_set_timeout(net, ct_info.ct, family, key->ip.proto,
net/openvswitch/conntrack.c
1586
static int ovs_ct_limit_init(struct net *net, struct ovs_net *ovs_net)
net/openvswitch/conntrack.c
1605
ovs_net->ct_limit_info->data = nf_conncount_init(net, sizeof(u32));
net/openvswitch/conntrack.c
1617
static void ovs_ct_limit_exit(struct net *net, struct ovs_net *ovs_net)
net/openvswitch/conntrack.c
1622
nf_conncount_destroy(net, info->data);
net/openvswitch/conntrack.c
1758
static int __ovs_ct_limit_get_zone_limit(struct net *net,
net/openvswitch/conntrack.c
1771
zone_limit.count = nf_conncount_count_skb(net, NULL, 0, data,
net/openvswitch/conntrack.c
1776
static int ovs_ct_limit_get_zone_limit(struct net *net,
net/openvswitch/conntrack.c
1803
net, info->data, zone, limit, reply);
net/openvswitch/conntrack.c
1819
static int ovs_ct_limit_get_all_zone_limit(struct net *net,
net/openvswitch/conntrack.c
1835
err = __ovs_ct_limit_get_zone_limit(net, info->data,
net/openvswitch/conntrack.c
1919
struct net *net = sock_net(skb->sk);
net/openvswitch/conntrack.c
1920
struct ovs_net *ovs_net = net_generic(net, ovs_net_id);
net/openvswitch/conntrack.c
1937
net, a[OVS_CT_LIMIT_ATTR_ZONE_LIMIT], ct_limit_info,
net/openvswitch/conntrack.c
1942
err = ovs_ct_limit_get_all_zone_limit(net, ct_limit_info,
net/openvswitch/conntrack.c
2000
int ovs_ct_init(struct net *net)
net/openvswitch/conntrack.c
2003
struct ovs_net *ovs_net = net_generic(net, ovs_net_id);
net/openvswitch/conntrack.c
2005
if (nf_connlabels_get(net, n_bits - 1)) {
net/openvswitch/conntrack.c
2013
return ovs_ct_limit_init(net, ovs_net);
net/openvswitch/conntrack.c
2019
void ovs_ct_exit(struct net *net)
net/openvswitch/conntrack.c
2021
struct ovs_net *ovs_net = net_generic(net, ovs_net_id);
net/openvswitch/conntrack.c
2024
ovs_ct_limit_exit(net, ovs_net);
net/openvswitch/conntrack.c
2028
nf_connlabels_put(net);
net/openvswitch/conntrack.c
444
static int ovs_ct_handle_fragments(struct net *net, struct sw_flow_key *key,
net/openvswitch/conntrack.c
450
err = nf_ct_handle_fragments(net, skb, zone, family, &key->ip.proto, &ovs_cb.mru);
net/openvswitch/conntrack.c
490
ovs_ct_find_existing(struct net *net, const struct nf_conntrack_zone *zone,
net/openvswitch/conntrack.c
498
net, &tuple)) {
net/openvswitch/conntrack.c
515
h = nf_conntrack_find_get(net, zone, &tuple);
net/openvswitch/conntrack.c
533
struct nf_conn *ovs_ct_executed(struct net *net,
net/openvswitch/conntrack.c
552
ct = ovs_ct_find_existing(net, &info->zone, info->family, skb,
net/openvswitch/conntrack.c
561
static bool skb_nfct_cached(struct net *net,
net/openvswitch/conntrack.c
572
ct = ovs_ct_executed(net, key, info, skb, &ct_executed);
net/openvswitch/conntrack.c
579
if (!net_eq(net, read_pnet(&ct->ct_net)))
net/openvswitch/conntrack.c
667
static int ovs_ct_nat(struct net *net, struct sw_flow_key *key,
net/openvswitch/conntrack.c
693
static int ovs_ct_nat(struct net *net, struct sw_flow_key *key,
net/openvswitch/conntrack.c
724
static int __ovs_ct_lookup(struct net *net, struct sw_flow_key *key,
net/openvswitch/conntrack.c
733
bool cached = skb_nfct_cached(net, key, info, skb);
net/openvswitch/conntrack.c
741
.net = net,
net/openvswitch/conntrack.c
784
int err = ovs_ct_nat(net, key, info, skb, ct, ctinfo);
net/openvswitch/conntrack.c
842
static int ovs_ct_lookup(struct net *net, struct sw_flow_key *key,
net/openvswitch/conntrack.c
849
err = __ovs_ct_lookup(net, key, info, skb);
net/openvswitch/conntrack.c
931
static int ovs_ct_check_limit(struct net *net,
net/openvswitch/conntrack.c
935
struct ovs_net *ovs_net = net_generic(net, ovs_net_id);
net/openvswitch/conntrack.c
946
connections = nf_conncount_count_skb(net, skb, info->family,
net/openvswitch/conntrack.c
957
static int ovs_ct_commit(struct net *net, struct sw_flow_key *key,
net/openvswitch/conntrack.c
965
err = __ovs_ct_lookup(net, key, info, skb);
net/openvswitch/conntrack.c
977
err = ovs_ct_check_limit(net, skb, info);
net/openvswitch/conntrack.h
16
int ovs_ct_init(struct net *);
net/openvswitch/conntrack.h
17
void ovs_ct_exit(struct net *);
net/openvswitch/conntrack.h
18
bool ovs_ct_verify(struct net *, enum ovs_key_attr attr);
net/openvswitch/conntrack.h
19
int ovs_ct_copy_action(struct net *, const struct nlattr *,
net/openvswitch/conntrack.h
24
int ovs_ct_execute(struct net *, struct sk_buff *, struct sw_flow_key *,
net/openvswitch/conntrack.h
41
static inline int ovs_ct_init(struct net *net) { return 0; }
net/openvswitch/conntrack.h
43
static inline void ovs_ct_exit(struct net *net) { }
net/openvswitch/conntrack.h
45
static inline bool ovs_ct_verify(struct net *net, int attr)
net/openvswitch/conntrack.h
50
static inline int ovs_ct_copy_action(struct net *net, const struct nlattr *nla,
net/openvswitch/conntrack.h
63
static inline int ovs_ct_execute(struct net *net, struct sk_buff *skb,
net/openvswitch/datapath.c
1000
struct net *net = sock_net(skb->sk);
net/openvswitch/datapath.c
1042
error = ovs_nla_get_match(net, &match, a[OVS_FLOW_ATTR_KEY],
net/openvswitch/datapath.c
1056
error = ovs_nla_copy_actions(net, a[OVS_FLOW_ATTR_ACTIONS],
net/openvswitch/datapath.c
1071
dp = get_dp(net, ovs_header->dp_ifindex);
net/openvswitch/datapath.c
1170
struct sw_flow_actions *get_flow_actions(struct net *net,
net/openvswitch/datapath.c
1181
error = ovs_nla_copy_actions(net, a, &masked_key, &acts, log);
net/openvswitch/datapath.c
1205
ovs_nla_init_match_and_action(struct net *net,
net/openvswitch/datapath.c
1217
error = ovs_nla_get_match(net, match, a[OVS_FLOW_ATTR_KEY],
net/openvswitch/datapath.c
1231
*acts = get_flow_actions(net, a[OVS_FLOW_ATTR_ACTIONS], key,
net/openvswitch/datapath.c
1247
struct net *net = sock_net(skb->sk);
net/openvswitch/datapath.c
1269
error = ovs_nla_init_match_and_action(net, &match, &key, a,
net/openvswitch/datapath.c
1285
dp = get_dp(net, ovs_header->dp_ifindex);
net/openvswitch/datapath.c
1352
struct net *net = sock_net(skb->sk);
net/openvswitch/datapath.c
1367
err = ovs_nla_get_match(net, &match, a[OVS_FLOW_ATTR_KEY], NULL,
net/openvswitch/datapath.c
1411
struct net *net = sock_net(skb->sk);
net/openvswitch/datapath.c
1426
err = ovs_nla_get_match(net, &match, a[OVS_FLOW_ATTR_KEY],
net/openvswitch/datapath.c
1656
static struct datapath *lookup_datapath(struct net *net,
net/openvswitch/datapath.c
1663
dp = get_dp(net, ovs_header->dp_ifindex);
net/openvswitch/datapath.c
1667
vport = ovs_vport_locate(net, nla_data(a[OVS_DP_ATTR_NAME]));
net/openvswitch/datapath.c
2131
struct net *net, u32 portid, u32 seq,
net/openvswitch/datapath.c
2136
struct net *net_vport;
net/openvswitch/datapath.c
2155
if (!net_eq(net, net_vport)) {
net/openvswitch/datapath.c
2156
int id = peernet2id_alloc(net, net_vport, GFP_ATOMIC);
net/openvswitch/datapath.c
2228
struct sk_buff *ovs_vport_cmd_build_info(struct vport *vport, struct net *net,
net/openvswitch/datapath.c
2238
retval = ovs_vport_cmd_fill_info(vport, skb, net, portid, seq, 0, cmd,
net/openvswitch/datapath.c
2246
static struct vport *lookup_vport(struct net *net,
net/openvswitch/datapath.c
2256
vport = ovs_vport_locate(net, nla_data(a[OVS_VPORT_ATTR_NAME]));
net/openvswitch/datapath.c
2269
dp = get_dp(net, ovs_header->dp_ifindex);
net/openvswitch/datapath.c
2695
static int __net_init ovs_init_net(struct net *net)
net/openvswitch/datapath.c
2697
struct ovs_net *ovs_net = net_generic(net, ovs_net_id);
net/openvswitch/datapath.c
2704
err = ovs_ct_init(net);
net/openvswitch/datapath.c
2713
static void __net_exit list_vports_from_net(struct net *net, struct net *dnet,
net/openvswitch/datapath.c
2716
struct ovs_net *ovs_net = net_generic(net, ovs_net_id);
net/openvswitch/datapath.c
2736
static void __net_exit ovs_exit_net(struct net *dnet)
net/openvswitch/datapath.c
2741
struct net *net;
net/openvswitch/datapath.c
2752
for_each_net(net)
net/openvswitch/datapath.c
2753
list_vports_from_net(net, dnet, &head);
net/openvswitch/datapath.c
615
struct net *net = sock_net(skb->sk);
net/openvswitch/datapath.c
668
err = ovs_flow_key_extract_userspace(net, a[OVS_PACKET_ATTR_KEY],
net/openvswitch/datapath.c
673
err = ovs_nla_copy_actions(net, a[OVS_PACKET_ATTR_ACTIONS],
net/openvswitch/datapath.c
683
dp = get_dp_rcu(net, ovs_header->dp_ifindex);
net/openvswitch/datapath.h
102
possible_net_t net;
net/openvswitch/datapath.h
257
static inline struct net *ovs_dp_get_net(const struct datapath *dp)
net/openvswitch/datapath.h
259
return read_pnet(&dp->net);
net/openvswitch/datapath.h
262
static inline void ovs_dp_set_net(struct datapath *dp, struct net *net)
net/openvswitch/datapath.h
264
write_pnet(&dp->net, net);
net/openvswitch/datapath.h
288
static inline struct datapath *get_dp_rcu(struct net *net, int dp_ifindex)
net/openvswitch/datapath.h
290
struct net_device *dev = dev_get_by_index_rcu(net, dp_ifindex);
net/openvswitch/datapath.h
305
static inline struct datapath *get_dp(struct net *net, int dp_ifindex)
net/openvswitch/datapath.h
311
dp = get_dp_rcu(net, dp_ifindex);
net/openvswitch/datapath.h
329
struct sk_buff *ovs_vport_cmd_build_info(struct vport *vport, struct net *net,
net/openvswitch/flow.c
1072
int ovs_flow_key_extract_userspace(struct net *net, const struct nlattr *attr,
net/openvswitch/flow.c
1085
err = ovs_nla_get_flow_metadata(net, a, attrs, key, log);
net/openvswitch/flow.h
294
int ovs_flow_key_extract_userspace(struct net *net, const struct nlattr *attr,
net/openvswitch/flow_netlink.c
1170
static int metadata_from_nlattrs(struct net *net, struct sw_flow_match *match,
net/openvswitch/flow_netlink.c
1227
ovs_ct_verify(net, OVS_KEY_ATTR_CT_STATE)) {
net/openvswitch/flow_netlink.c
1240
ovs_ct_verify(net, OVS_KEY_ATTR_CT_ZONE)) {
net/openvswitch/flow_netlink.c
1247
ovs_ct_verify(net, OVS_KEY_ATTR_CT_MARK)) {
net/openvswitch/flow_netlink.c
1254
ovs_ct_verify(net, OVS_KEY_ATTR_CT_LABELS)) {
net/openvswitch/flow_netlink.c
1486
static int ovs_key_from_nlattrs(struct net *net, struct sw_flow_match *match,
net/openvswitch/flow_netlink.c
1492
err = metadata_from_nlattrs(net, match, &attrs, a, is_mask, log);
net/openvswitch/flow_netlink.c
1775
int ovs_nla_get_match(struct net *net, struct sw_flow_match *match,
net/openvswitch/flow_netlink.c
1794
err = ovs_key_from_nlattrs(net, match, key_attrs, a, false, log);
net/openvswitch/flow_netlink.c
1840
err = ovs_key_from_nlattrs(net, match, mask_attrs, a, true,
net/openvswitch/flow_netlink.c
1927
int ovs_nla_get_flow_metadata(struct net *net,
net/openvswitch/flow_netlink.c
1945
return metadata_from_nlattrs(net, &match, &attrs, a, false, log);
net/openvswitch/flow_netlink.c
2551
static int __ovs_nla_copy_actions(struct net *net, const struct nlattr *attr,
net/openvswitch/flow_netlink.c
2558
static int validate_and_copy_sample(struct net *net, const struct nlattr *attr,
net/openvswitch/flow_netlink.c
2615
err = __ovs_nla_copy_actions(net, actions, key, sfa,
net/openvswitch/flow_netlink.c
2635
static int validate_and_copy_dec_ttl(struct net *net,
net/openvswitch/flow_netlink.c
2685
err = __ovs_nla_copy_actions(net, actions, key, sfa, eth_type,
net/openvswitch/flow_netlink.c
2707
static int validate_and_copy_clone(struct net *net,
net/openvswitch/flow_netlink.c
2734
err = __ovs_nla_copy_actions(net, attr, key, sfa,
net/openvswitch/flow_netlink.c
3123
static int validate_and_copy_check_pkt_len(struct net *net,
net/openvswitch/flow_netlink.c
3181
err = __ovs_nla_copy_actions(net, acts_if_lesser_eq, key, sfa,
net/openvswitch/flow_netlink.c
3201
err = __ovs_nla_copy_actions(net, acts_if_greater, key, sfa,
net/openvswitch/flow_netlink.c
3260
static int __ovs_nla_copy_actions(struct net *net, const struct nlattr *attr,
net/openvswitch/flow_netlink.c
3469
err = validate_and_copy_sample(net, a, key, sfa,
net/openvswitch/flow_netlink.c
3480
err = ovs_ct_copy_action(net, a, key, sfa, log);
net/openvswitch/flow_netlink.c
3540
err = validate_and_copy_clone(net, a, key, sfa,
net/openvswitch/flow_netlink.c
3553
err = validate_and_copy_check_pkt_len(net, a, key, sfa,
net/openvswitch/flow_netlink.c
3566
err = validate_and_copy_dec_ttl(net, a, key, sfa,
net/openvswitch/flow_netlink.c
3604
int ovs_nla_copy_actions(struct net *net, const struct nlattr *attr,
net/openvswitch/flow_netlink.c
3619
err = __ovs_nla_copy_actions(net, attr, key, sfa, key->eth.type,
net/openvswitch/flow_netlink.h
37
int ovs_nla_get_flow_metadata(struct net *net,
net/openvswitch/flow_netlink.h
45
int ovs_nla_get_match(struct net *, struct sw_flow_match *,
net/openvswitch/flow_netlink.h
57
int ovs_nla_copy_actions(struct net *net, const struct nlattr *attr,
net/openvswitch/vport-geneve.c
53
struct net *net = ovs_dp_get_net(parms->dp);
net/openvswitch/vport-geneve.c
85
dev = geneve_dev_create_fb(net, parms->name, NET_NAME_USER, dst_port);
net/openvswitch/vport-gre.c
41
struct net *net = ovs_dp_get_net(parms->dp);
net/openvswitch/vport-gre.c
51
dev = gretap_fb_dev_create(net, parms->name, NET_NAME_USER);
net/openvswitch/vport-vxlan.c
114
dev = vxlan_dev_create(net, parms->name, NET_NAME_USER, &conf);
net/openvswitch/vport-vxlan.c
73
struct net *net = ovs_dp_get_net(parms->dp);
net/openvswitch/vport.c
102
net_eq(ovs_dp_get_net(vport->dp), net))
net/openvswitch/vport.c
54
static struct hlist_head *hash_bucket(const struct net *net, const char *name)
net/openvswitch/vport.c
56
unsigned int hash = jhash(name, strlen(name), (unsigned long) net);
net/openvswitch/vport.c
94
struct vport *ovs_vport_locate(const struct net *net, const char *name)
net/openvswitch/vport.c
96
struct hlist_head *bucket = hash_bucket(net, name);
net/openvswitch/vport.h
31
struct vport *ovs_vport_locate(const struct net *net, const char *name);
net/packet/af_packet.c
1461
struct net *net = read_pnet(&f->net);
net/packet/af_packet.c
1465
if (!net_eq(dev_net(dev), net) || !num) {
net/packet/af_packet.c
1471
skb = ip_check_defrag(net, skb, IP_DEFRAG_AF_PACKET);
net/packet/af_packet.c
1654
read_pnet(&f->net) == sock_net(sk)) {
net/packet/af_packet.c
1739
read_pnet(&f->net) == sock_net(sk)) {
net/packet/af_packet.c
1761
write_pnet(&match->net, sock_net(sk));
net/packet/af_packet.c
1773
match->prot_hook.af_packet_net = read_pnet(&match->net);
net/packet/af_packet.c
3127
struct net *net;
net/packet/af_packet.c
3133
net = sock_net(sk);
net/packet/af_packet.c
3136
mutex_lock(&net->packet.sklist_lock);
net/packet/af_packet.c
3138
mutex_unlock(&net->packet.sklist_lock);
net/packet/af_packet.c
3140
sock_prot_inuse_add(net, sk->sk_prot, -1);
net/packet/af_packet.c
3338
static int packet_create(struct net *net, struct socket *sock, int protocol,
net/packet/af_packet.c
3346
if (!ns_capable(net->user_ns, CAP_NET_RAW))
net/packet/af_packet.c
3355
sk = sk_alloc(net, PF_PACKET, GFP_KERNEL, &packet_proto, kern);
net/packet/af_packet.c
3398
mutex_lock(&net->packet.sklist_lock);
net/packet/af_packet.c
3399
sk_add_node_tail_rcu(sk, &net->packet.sklist);
net/packet/af_packet.c
3400
mutex_unlock(&net->packet.sklist_lock);
net/packet/af_packet.c
3402
sock_prot_inuse_add(net, &packet_proto, 1);
net/packet/af_packet.c
4189
struct net *net = dev_net(dev);
net/packet/af_packet.c
4195
sk_for_each_rcu(sk, &net->packet.sklist) {
net/packet/af_packet.c
4704
struct net *net = seq_file_net(seq);
net/packet/af_packet.c
4707
return seq_hlist_start_head_rcu(&net->packet.sklist, *pos);
net/packet/af_packet.c
4712
struct net *net = seq_file_net(seq);
net/packet/af_packet.c
4713
return seq_hlist_next_rcu(v, &net->packet.sklist, pos);
net/packet/af_packet.c
4756
static int __net_init packet_net_init(struct net *net)
net/packet/af_packet.c
4758
mutex_init(&net->packet.sklist_lock);
net/packet/af_packet.c
4759
INIT_HLIST_HEAD(&net->packet.sklist);
net/packet/af_packet.c
4762
if (!proc_create_net("packet", 0, net->proc_net, &packet_seq_ops,
net/packet/af_packet.c
4770
static void __net_exit packet_net_exit(struct net *net)
net/packet/af_packet.c
4772
remove_proc_entry("packet", net->proc_net);
net/packet/af_packet.c
4773
WARN_ON_ONCE(!hlist_empty(&net->packet.sklist));
net/packet/diag.c
192
struct net *net;
net/packet/diag.c
196
net = sock_net(skb->sk);
net/packet/diag.c
200
mutex_lock(&net->packet.sklist_lock);
net/packet/diag.c
201
sk_for_each(sk, &net->packet.sklist) {
net/packet/diag.c
202
if (!net_eq(sock_net(sk), net))
net/packet/diag.c
218
mutex_unlock(&net->packet.sklist_lock);
net/packet/diag.c
227
struct net *net = sock_net(skb->sk);
net/packet/diag.c
242
return netlink_dump_start(net->diag_nlsk, skb, h, &c);
net/packet/internal.h
78
possible_net_t net;
net/phonet/af_phonet.c
230
struct net *net = sock_net(sk);
net/phonet/af_phonet.c
249
dev = dev_get_by_index(net, sk->sk_bound_dev_if);
net/phonet/af_phonet.c
250
else if (phonet_address_lookup(net, daddr) == 0) {
net/phonet/af_phonet.c
251
dev = phonet_device_get(net);
net/phonet/af_phonet.c
255
struct sock *sk = pn_find_sock_by_res(net, res);
net/phonet/af_phonet.c
258
dev = phonet_device_get(net);
net/phonet/af_phonet.c
261
dev = phonet_route_output(net, daddr);
net/phonet/af_phonet.c
263
dev = phonet_route_output(net, daddr);
net/phonet/af_phonet.c
364
struct net *net = dev_net(dev);
net/phonet/af_phonet.c
391
pn_deliver_sock_broadcast(net, skb);
net/phonet/af_phonet.c
397
struct sock *sk = pn_find_sock_by_res(net, sa.spn_resource);
net/phonet/af_phonet.c
403
if (phonet_address_lookup(net, pn_sockaddr_get_addr(&sa)) == 0) {
net/phonet/af_phonet.c
405
struct sock *sk = pn_find_sock_by_sa(net, &sa);
net/phonet/af_phonet.c
420
out_dev = phonet_route_output(net, pn_sockaddr_get_addr(&sa));
net/phonet/af_phonet.c
50
static int pn_socket_create(struct net *net, struct socket *sock, int protocol,
net/phonet/af_phonet.c
87
sk = sk_alloc(net, PF_PHONET, GFP_KERNEL, pnp->prot, kern);
net/phonet/pn_dev.c
104
struct net *net = dev_net(dev);
net/phonet/pn_dev.c
109
phonet_address_notify(net, RTM_DELADDR, ifindex, addr);
net/phonet/pn_dev.c
115
struct net_device *phonet_device_get(struct net *net)
net/phonet/pn_dev.c
117
struct phonet_device_list *pndevs = phonet_device_list(net);
net/phonet/pn_dev.c
217
int phonet_address_lookup(struct net *net, u8 addr)
net/phonet/pn_dev.c
219
struct phonet_device_list *pndevs = phonet_device_list(net);
net/phonet/pn_dev.c
266
struct net *net = dev_net(dev);
net/phonet/pn_dev.c
272
pnn = phonet_pernet(net);
net/phonet/pn_dev.c
290
rtm_phonet_notify(net, RTM_DELROUTE, ifindex, i);
net/phonet/pn_dev.c
321
static int __net_init phonet_init_net(struct net *net)
net/phonet/pn_dev.c
323
struct phonet_net *pnn = phonet_pernet(net);
net/phonet/pn_dev.c
325
if (!proc_create_net("phonet", 0, net->proc_net, &pn_sock_seq_ops,
net/phonet/pn_dev.c
335
static void __net_exit phonet_exit_net(struct net *net)
net/phonet/pn_dev.c
337
struct phonet_net *pnn = phonet_pernet(net);
net/phonet/pn_dev.c
339
remove_proc_entry("phonet", net->proc_net);
net/phonet/pn_dev.c
36
static struct phonet_net *phonet_pernet(struct net *net)
net/phonet/pn_dev.c
38
return net_generic(net, phonet_net_id);
net/phonet/pn_dev.c
41
struct phonet_device_list *phonet_device_list(struct net *net)
net/phonet/pn_dev.c
43
struct phonet_net *pnn = phonet_pernet(net);
net/phonet/pn_dev.c
433
struct net_device *phonet_route_get_rcu(struct net *net, u8 daddr)
net/phonet/pn_dev.c
435
struct phonet_net *pnn = phonet_pernet(net);
net/phonet/pn_dev.c
444
struct net_device *phonet_route_output(struct net *net, u8 daddr)
net/phonet/pn_dev.c
446
struct phonet_net *pnn = phonet_pernet(net);
net/phonet/pn_dev.c
457
dev = phonet_device_get(net); /* Default route */
net/phonet/pn_netlink.c
203
void rtm_phonet_notify(struct net *net, int event, u32 ifindex, u8 dst)
net/phonet/pn_netlink.c
220
rtnl_notify(skb, net, 0, RTNLGRP_PHONET_ROUTE, NULL, GFP_KERNEL);
net/phonet/pn_netlink.c
223
rtnl_set_sk_err(net, RTNLGRP_PHONET_ROUTE, err);
net/phonet/pn_netlink.c
234
struct net *net = sock_net(skb->sk);
net/phonet/pn_netlink.c
25
void phonet_address_notify(struct net *net, int event, u32 ifindex, u8 addr)
net/phonet/pn_netlink.c
267
dev = dev_get_by_index_rcu(net, ifindex);
net/phonet/pn_netlink.c
288
rtm_phonet_notify(net, nlh->nlmsg_type, ifindex, dst);
net/phonet/pn_netlink.c
295
struct net *net = sock_net(skb->sk);
net/phonet/pn_netlink.c
301
struct net_device *dev = phonet_route_get_rcu(net, addr << 2);
net/phonet/pn_netlink.c
42
rtnl_notify(skb, net, 0, RTNLGRP_PHONET_IFADDR, NULL, GFP_KERNEL);
net/phonet/pn_netlink.c
45
rtnl_set_sk_err(net, RTNLGRP_PHONET_IFADDR, err);
net/phonet/pn_netlink.c
55
struct net *net = sock_net(skb->sk);
net/phonet/pn_netlink.c
83
dev = dev_get_by_index_rcu(net, ifm->ifa_index);
net/phonet/pn_netlink.c
97
phonet_address_notify(net, nlh->nlmsg_type, ifm->ifa_index, pnaddr);
net/phonet/socket.c
104
void pn_deliver_sock_broadcast(struct net *net, struct sk_buff *skb)
net/phonet/socket.c
116
if (!net_eq(sock_net(sknode), net))
net/phonet/socket.c
476
struct net *net = sock_net(sk);
net/phonet/socket.c
495
tmpsk = pn_find_sock_by_sa(net, &try_sa);
net/phonet/socket.c
505
tmpsk = pn_find_sock_by_sa(net, &try_sa);
net/phonet/socket.c
524
struct net *net = seq_file_net(seq);
net/phonet/socket.c
531
if (!net_eq(net, sock_net(sknode)))
net/phonet/socket.c
544
struct net *net = seq_file_net(seq);
net/phonet/socket.c
548
while (sk && !net_eq(net, sock_net(sk)));
net/phonet/socket.c
617
struct sock *pn_find_sock_by_res(struct net *net, u8 res)
net/phonet/socket.c
621
if (!net_eq(net, &init_net))
net/phonet/socket.c
66
struct sock *pn_find_sock_by_sa(struct net *net, const struct sockaddr_pn *spn)
net/phonet/socket.c
699
struct net *net = seq_file_net(seq);
net/phonet/socket.c
702
if (!net_eq(net, &init_net))
net/phonet/socket.c
717
struct net *net = seq_file_net(seq);
net/phonet/socket.c
720
BUG_ON(!net_eq(net, &init_net));
net/phonet/socket.c
79
if (!net_eq(sock_net(sknode), net))
net/psample/psample.c
135
genlmsg_multicast_netns(&psample_nl_family, group->net, msg, 0,
net/psample/psample.c
141
static struct psample_group *psample_group_create(struct net *net,
net/psample/psample.c
150
group->net = net;
net/psample/psample.c
166
psample_group_lookup(struct net *net, u32 group_num)
net/psample/psample.c
171
if ((group->group_num == group_num) && (group->net == net))
net/psample/psample.c
176
struct psample_group *psample_group_get(struct net *net, u32 group_num)
net/psample/psample.c
182
group = psample_group_lookup(net, group_num);
net/psample/psample.c
184
group = psample_group_create(net, group_num);
net/psample/psample.c
380
if (!genl_has_listeners(&psample_nl_family, group->net,
net/psample/psample.c
510
genlmsg_multicast_netns(&psample_nl_family, group->net, nl_skb, 0,
net/psample/psample.c
82
if (!net_eq(group->net, sock_net(msg->sk)))
net/psp/psp.h
17
int psp_dev_check_access(struct psp_dev *psd, struct net *net, bool admin);
net/psp/psp.h
18
bool psp_has_assoc_dev_in_ns(struct psp_dev *psd, struct net *net);
net/psp/psp_main.c
188
static void psp_write_headers(struct net *net, struct sk_buff *skb, __be32 spi,
net/psp/psp_main.c
221
inet_get_local_port_range(net, &min, &max);
net/psp/psp_main.c
231
uh->source = udp_flow_src_port(net, skb, 0, 0, false);
net/psp/psp_main.c
248
bool psp_dev_encapsulate(struct net *net, struct sk_buff *skb, __be32 spi,
net/psp/psp_main.c
283
psp_write_headers(net, skb, spi, ver,
net/psp/psp_main.c
38
int psp_dev_check_access(struct psp_dev *psd, struct net *net, bool admin)
net/psp/psp_main.c
40
if (dev_net(psd->main_netdev) == net)
net/psp/psp_main.c
43
if (!admin && psp_has_assoc_dev_in_ns(psd, net))
net/psp/psp_nl.c
113
psp_device_get_and_lock(struct net *net, struct nlattr *dev_id,
net/psp/psp_nl.c
129
err = psp_dev_check_access(psd, net, admin);
net/psp/psp_nl.c
179
static struct net *psp_nl_resolve_assoc_dev_ns(struct psp_dev *psd,
net/psp/psp_nl.c
182
struct net *net;
net/psp/psp_nl.c
198
net = get_net_ns_by_id(genl_info_net(info), nsid);
net/psp/psp_nl.c
199
if (!net) {
net/psp/psp_nl.c
205
net = get_net(genl_info_net(info));
net/psp/psp_nl.c
208
return net;
net/psp/psp_nl.c
223
bool psp_has_assoc_dev_in_ns(struct psp_dev *psd, struct net *net)
net/psp/psp_nl.c
228
if (dev_net(entry->assoc_dev) == net)
net/psp/psp_nl.c
236
struct net *cur_net,
net/psp/psp_nl.c
237
struct net *filter_net)
net/psp/psp_nl.c
240
struct net *dev_net_ns;
net/psp/psp_nl.c
279
struct net *cur_net;
net/psp/psp_nl.c
320
struct net *net, void *ctx)
net/psp/psp_nl.c
326
if (!genl_has_listeners(&psp_nl_family, net, PSP_NLGRP_MGMT))
net/psp/psp_nl.c
334
genl_info_net_set(&info, net);
net/psp/psp_nl.c
499
struct net *net;
net/psp/psp_nl.c
508
net = psp_nl_resolve_assoc_dev_ns(psd, info);
net/psp/psp_nl.c
509
if (IS_ERR(net))
net/psp/psp_nl.c
510
return PTR_ERR(net);
net/psp/psp_nl.c
519
assoc_dev = netdev_get_by_index(net, assoc_ifindex,
net/psp/psp_nl.c
559
put_net(net);
net/psp/psp_nl.c
56
struct net *,
net/psp/psp_nl.c
572
put_net(net);
net/psp/psp_nl.c
583
struct net *net;
net/psp/psp_nl.c
585
net = psp_nl_resolve_assoc_dev_ns(psd, info);
net/psp/psp_nl.c
586
if (IS_ERR(net))
net/psp/psp_nl.c
587
return PTR_ERR(net);
net/psp/psp_nl.c
594
dev_net(entry->assoc_dev) == net) {
net/psp/psp_nl.c
601
put_net(net);
net/psp/psp_nl.c
608
put_net(net);
net/psp/psp_nl.c
612
put_net(net);
net/psp/psp_nl.c
62
struct net *main_net;
net/psp/psp_nl.c
69
struct net *assoc_net = dev_net(entry->assoc_dev);
net/psp/psp_nl.c
97
static struct sk_buff *psp_nl_clone_ntf(struct psp_dev *psd, struct net *net,
net/qrtr/af_qrtr.c
1257
static int qrtr_create(struct net *net, struct socket *sock,
net/qrtr/af_qrtr.c
1271
if (!net_eq(net, &init_net))
net/qrtr/af_qrtr.c
1274
sk = sk_alloc(net, AF_QIPCRTR, GFP_KERNEL, &qrtr_proto, kern);
net/rds/af_rds.c
359
static int rds_set_transport(struct net *net, struct rds_sock *rs,
net/rds/af_rds.c
377
if (t_type != RDS_TRANS_TCP && !net_eq(net, &init_net))
net/rds/af_rds.c
440
struct net *net = sock_net(sock->sk);
net/rds/af_rds.c
469
ret = rds_set_transport(net, rs, optval, optlen);
net/rds/af_rds.c
704
static int rds_create(struct net *net, struct socket *sock, int protocol,
net/rds/af_rds.c
712
sk = sk_alloc(net, AF_RDS, GFP_KERNEL, &rds_proto, kern);
net/rds/af_rds.c
739
struct net *net = sock_net(sock->sk);
net/rds/af_rds.c
750
if (!net_eq(sock_net(rds_rs_to_sk(rs)), net))
net/rds/af_rds.c
782
struct net *net = sock_net(sock->sk);
net/rds/af_rds.c
793
if (!net_eq(sock_net(rds_rs_to_sk(rs)), net))
net/rds/af_rds.c
818
struct net *net = sock_net(sock->sk);
net/rds/af_rds.c
830
if (!net_eq(sock_net(rds_rs_to_sk(rs)), net))
net/rds/af_rds.c
844
if (!net_eq(sock_net(rds_rs_to_sk(rs)), net))
net/rds/af_rds.c
878
struct net *net = sock_net(sock->sk);
net/rds/af_rds.c
890
if (!net_eq(sock_net(rds_rs_to_sk(rs)), net))
net/rds/af_rds.c
902
if (!net_eq(sock_net(rds_rs_to_sk(rs)), net))
net/rds/connection.c
161
static struct rds_connection *__rds_conn_create(struct net *net,
net/rds/connection.c
178
conn = rds_conn_lookup(net, head, laddr, faddr, trans, tos, dev_if);
net/rds/connection.c
226
rds_conn_net_set(conn, net);
net/rds/connection.c
241
loop_trans = rds_trans_get_preferred(net, faddr, conn->c_dev_if);
net/rds/connection.c
321
found = rds_conn_lookup(net, head, laddr, faddr, trans,
net/rds/connection.c
361
struct rds_connection *rds_conn_create(struct net *net,
net/rds/connection.c
367
return __rds_conn_create(net, laddr, faddr, trans, gfp, tos, 0, dev_if);
net/rds/connection.c
371
struct rds_connection *rds_conn_create_outgoing(struct net *net,
net/rds/connection.c
377
return __rds_conn_create(net, laddr, faddr, trans, gfp, tos, 1, dev_if);
net/rds/connection.c
571
struct net *net = sock_net(sock->sk);
net/rds/connection.c
595
if (!net_eq(rds_conn_net(conn), net))
net/rds/connection.c
695
struct net *net = sock_net(sock->sk);
net/rds/connection.c
709
if (!net_eq(rds_conn_net(conn), net))
net/rds/connection.c
744
struct net *net = sock_net(sock->sk);
net/rds/connection.c
760
if (!net_eq(rds_conn_net(conn), net))
net/rds/connection.c
83
static struct rds_connection *rds_conn_lookup(struct net *net,
net/rds/connection.c
97
net == rds_conn_net(conn) &&
net/rds/ib.c
404
static int rds_ib_laddr_check_cm(struct net *net, const struct in6_addr *addr,
net/rds/ib.c
494
static int rds_ib_laddr_check(struct net *net, const struct in6_addr *addr,
net/rds/ib.c
500
if (!net_eq(net, &init_net))
net/rds/ib.c
511
return rds_ib_laddr_check_cm(net, addr, scope_id);
net/rds/ib_cm.c
765
static u32 __rds_find_ifindex(struct net *net, const struct in6_addr *addr)
net/rds/ib_cm.c
771
for_each_netdev_rcu(net, dev) {
net/rds/ib_cm.c
772
if (ipv6_chk_addr(net, addr, dev, 1)) {
net/rds/loop.c
196
static void rds_loop_kill_conns(struct net *net)
net/rds/loop.c
203
struct net *c_net = read_pnet(&lc->conn->c_net);
net/rds/loop.c
205
if (net != c_net)
net/rds/loop.c
217
static void __net_exit rds_loop_exit_net(struct net *net)
net/rds/loop.c
219
rds_loop_kill_conns(net);
net/rds/rds.h
1042
struct rds_transport *rds_trans_get_preferred(struct net *net,
net/rds/rds.h
178
struct net *rds_conn_net(struct rds_connection *conn)
net/rds/rds.h
184
void rds_conn_net_set(struct rds_connection *conn, struct net *net)
net/rds/rds.h
186
write_pnet(&conn->c_net, net);
net/rds/rds.h
537
int (*laddr_check)(struct net *net, const struct in6_addr *addr,
net/rds/rds.h
798
struct rds_connection *rds_conn_create(struct net *net,
net/rds/rds.h
804
struct rds_connection *rds_conn_create_outgoing(struct net *net,
net/rds/tcp.c
223
struct net *net = sock_net(rds_sock->sk);
net/rds/tcp.c
236
if (!net_eq(rds_conn_net(tc->t_cpath->cp_conn), net))
net/rds/tcp.c
252
if (!net_eq(rds_conn_net(tc->t_cpath->cp_conn), net))
net/rds/tcp.c
288
struct net *net = sock_net(sock->sk);
net/rds/tcp.c
299
if (!net_eq(rds_conn_net(tc->t_cpath->cp_conn), net))
net/rds/tcp.c
314
if (!net_eq(rds_conn_net(tc->t_cpath->cp_conn), net))
net/rds/tcp.c
341
int rds_tcp_laddr_check(struct net *net, const struct in6_addr *addr,
net/rds/tcp.c
350
if (inet_addr_type(net, addr->s6_addr32[3]) == RTN_LOCAL)
net/rds/tcp.c
360
dev = dev_get_by_index_rcu(net, scope_id);
net/rds/tcp.c
370
ret = ipv6_chk_addr(net, addr, dev, 0);
net/rds/tcp.c
513
struct net *net = sock_net(sk);
net/rds/tcp.c
521
if (!maybe_get_net(net))
net/rds/tcp.c
532
put_net(net);
net/rds/tcp.c
535
rtn = net_generic(net, rds_tcp_netid);
net/rds/tcp.c
563
static __net_init int rds_tcp_init_net(struct net *net)
net/rds/tcp.c
565
struct rds_tcp_net *rtn = net_generic(net, rds_tcp_netid);
net/rds/tcp.c
576
if (net == &init_net) {
net/rds/tcp.c
589
rtn->rds_tcp_sysctl = register_net_sysctl_sz(net, "net/rds/tcp", tbl,
net/rds/tcp.c
598
rtn->rds_tcp_listen_sock = rds_tcp_listen_init(net, true);
net/rds/tcp.c
600
rtn->rds_tcp_listen_sock = rds_tcp_listen_init(net, false);
net/rds/tcp.c
607
rtn->rds_tcp_listen_sock = rds_tcp_listen_init(net, false);
net/rds/tcp.c
622
if (net != &init_net)
net/rds/tcp.c
627
static void rds_tcp_kill_sock(struct net *net)
net/rds/tcp.c
631
struct rds_tcp_net *rtn = net_generic(net, rds_tcp_netid);
net/rds/tcp.c
640
struct net *c_net = read_pnet(&tc->t_cpath->cp_conn->c_net);
net/rds/tcp.c
642
if (net != c_net)
net/rds/tcp.c
656
static void __net_exit rds_tcp_exit_net(struct net *net)
net/rds/tcp.c
658
struct rds_tcp_net *rtn = net_generic(net, rds_tcp_netid);
net/rds/tcp.c
663
if (net != &init_net)
net/rds/tcp.c
666
rds_tcp_kill_sock(net);
net/rds/tcp.c
676
void *rds_tcp_listen_sock_def_readable(struct net *net)
net/rds/tcp.c
678
struct rds_tcp_net *rtn = net_generic(net, rds_tcp_netid);
net/rds/tcp.c
692
static void rds_tcp_sysctl_reset(struct net *net)
net/rds/tcp.c
698
struct net *c_net = read_pnet(&tc->t_cpath->cp_conn->c_net);
net/rds/tcp.c
700
if (net != c_net || !tc->t_sock)
net/rds/tcp.c
723
struct net *net = sock_net(rtn->rds_tcp_listen_sock->sk);
net/rds/tcp.c
725
rds_tcp_sysctl_reset(net);
net/rds/tcp.h
82
int rds_tcp_laddr_check(struct net *net, const struct in6_addr *addr,
net/rds/tcp.h
90
struct socket *rds_tcp_listen_init(struct net *net, bool isv6);
net/rds/tcp.h
96
void *rds_tcp_listen_sock_def_readable(struct net *net);
net/rds/tcp_listen.c
382
struct socket *rds_tcp_listen_init(struct net *net, bool isv6)
net/rds/tcp_listen.c
391
ret = sock_create_kern(net, isv6 ? PF_INET6 : PF_INET, SOCK_STREAM,
net/rds/transport.c
104
if (trans && (trans->laddr_check(net, addr, scope_id) == 0) &&
net/rds/transport.c
85
struct rds_transport *rds_trans_get_preferred(struct net *net,
net/rxrpc/af_rxrpc.c
802
static int rxrpc_create(struct net *net, struct socket *sock, int protocol,
net/rxrpc/af_rxrpc.c
822
sk = sk_alloc(net, PF_RXRPC, GFP_KERNEL, &rxrpc_proto, kern);
net/rxrpc/ar-internal.h
1326
struct rxrpc_local *rxrpc_lookup_local(struct net *, const struct sockaddr_rxrpc *);
net/rxrpc/ar-internal.h
1375
static inline struct rxrpc_net *rxrpc_net(struct net *net)
net/rxrpc/ar-internal.h
1377
return net_generic(net, rxrpc_net_id);
net/rxrpc/ar-internal.h
351
struct net *net; /* The network namespace */
net/rxrpc/local_object.c
109
static struct rxrpc_local *rxrpc_alloc_local(struct net *net,
net/rxrpc/local_object.c
119
local->net = net;
net/rxrpc/local_object.c
120
local->rxnet = rxrpc_net(net);
net/rxrpc/local_object.c
162
static int rxrpc_open_socket(struct rxrpc_local *local, struct net *net)
net/rxrpc/local_object.c
187
ret = udp_sock_create(net, &udp_conf, &local->socket);
net/rxrpc/local_object.c
197
setup_udp_tunnel_sock(net, local->socket->sk, &tuncfg);
net/rxrpc/local_object.c
247
struct rxrpc_local *rxrpc_lookup_local(struct net *net,
net/rxrpc/local_object.c
251
struct rxrpc_net *rxnet = rxrpc_net(net);
net/rxrpc/local_object.c
289
local = rxrpc_alloc_local(net, srx);
net/rxrpc/local_object.c
293
ret = rxrpc_open_socket(local, net);
net/rxrpc/net_ns.c
103
static __net_exit void rxrpc_exit_net(struct net *net)
net/rxrpc/net_ns.c
105
struct rxrpc_net *rxnet = rxrpc_net(net);
net/rxrpc/net_ns.c
34
static __net_init int rxrpc_init_net(struct net *net)
net/rxrpc/net_ns.c
36
struct rxrpc_net *rxnet = rxrpc_net(net);
net/rxrpc/net_ns.c
73
rxnet->proc_net = proc_net_mkdir(net, "rxrpc", net->proc_net);
net/rxrpc/peer_object.c
154
struct net *net = local->net;
net/rxrpc/peer_object.c
174
net, fl4, NULL,
net/rxrpc/peer_object.c
193
dst = ip6_route_output(net, NULL, fl6);
net/sched/act_api.c
1397
struct tc_action *tcf_action_init_1(struct net *net, struct tcf_proto *tp,
net/sched/act_api.c
1433
err = a_o->init(net, tb[TCA_ACT_OPTIONS], est, &a, tp,
net/sched/act_api.c
1436
err = a_o->init(net, nla, est, &a, tp, userflags.value | flags,
net/sched/act_api.c
1466
int tcf_action_init(struct net *net, struct tcf_proto *tp, struct nlattr *nla,
net/sched/act_api.c
1508
act = tcf_action_init_1(net, tp, tb[i], est, ops[i - 1],
net/sched/act_api.c
1687
tcf_get_notify(struct net *net, u32 portid, struct nlmsghdr *n,
net/sched/act_api.c
1703
return rtnl_unicast(skb, net, portid);
net/sched/act_api.c
1706
static struct tc_action *tcf_action_get_1(struct net *net, struct nlattr *nla,
net/sched/act_api.c
1736
if (__tcf_idr_search(net, ops, &a, index) == 0) {
net/sched/act_api.c
1750
static int tca_action_flush(struct net *net, struct nlattr *nla,
net/sched/act_api.c
1801
err = __tcf_generic_walker(net, skb, &dcb, RTM_DELACTION, ops, extack);
net/sched/act_api.c
1812
err = rtnetlink_send(skb, net, portid, RTNLGRP_TC,
net/sched/act_api.c
1826
static int tcf_action_delete(struct net *net, struct tc_action *actions[])
net/sched/act_api.c
1855
static struct sk_buff *tcf_reoffload_del_notify_msg(struct net *net,
net/sched/act_api.c
1876
static int tcf_reoffload_del_notify(struct net *net, struct tc_action *action)
net/sched/act_api.c
1882
if (!rtnl_notify_needed(net, 0, RTNLGRP_TC)) {
net/sched/act_api.c
1885
skb = tcf_reoffload_del_notify_msg(net, action);
net/sched/act_api.c
1893
ret = rtnetlink_maybe_send(skb, net, 0, RTNLGRP_TC, 0);
net/sched/act_api.c
1912
struct net *net;
net/sched/act_api.c
1921
for_each_net(net) {
net/sched/act_api.c
1924
tn = net_generic(net, act_id);
net/sched/act_api.c
1948
tcf_reoffload_del_notify(net, p);
net/sched/act_api.c
1959
static struct sk_buff *tcf_del_notify_msg(struct net *net, struct nlmsghdr *n,
net/sched/act_api.c
1980
static int tcf_del_notify(struct net *net, struct nlmsghdr *n,
net/sched/act_api.c
1987
if (!rtnl_notify_needed(net, n->nlmsg_flags, RTNLGRP_TC)) {
net/sched/act_api.c
1990
skb = tcf_del_notify_msg(net, n, actions, portid, attr_size,
net/sched/act_api.c
1997
ret = tcf_action_delete(net, actions);
net/sched/act_api.c
2004
return rtnetlink_maybe_send(skb, net, portid, RTNLGRP_TC,
net/sched/act_api.c
2009
tca_action_gd(struct net *net, struct nlattr *nla, struct nlmsghdr *n,
net/sched/act_api.c
2025
return tca_action_flush(net, tb[1], n, portid, extack);
net/sched/act_api.c
2032
act = tcf_action_get_1(net, tb[i], n, portid, extack);
net/sched/act_api.c
2044
ret = tcf_get_notify(net, portid, n, actions, event, extack);
net/sched/act_api.c
2046
ret = tcf_del_notify(net, n, actions, portid, attr_size, extack);
net/sched/act_api.c
2056
static struct sk_buff *tcf_add_notify_msg(struct net *net, struct nlmsghdr *n,
net/sched/act_api.c
2077
static int tcf_add_notify(struct net *net, struct nlmsghdr *n,
net/sched/act_api.c
2083
if (!rtnl_notify_needed(net, n->nlmsg_flags, RTNLGRP_TC)) {
net/sched/act_api.c
2086
skb = tcf_add_notify_msg(net, n, actions, portid, attr_size,
net/sched/act_api.c
2092
return rtnetlink_maybe_send(skb, net, portid, RTNLGRP_TC,
net/sched/act_api.c
2096
static int tcf_action_add(struct net *net, struct nlattr *nla,
net/sched/act_api.c
2106
ret = tcf_action_init(net, NULL, nla, NULL, actions, init_res,
net/sched/act_api.c
2115
ret = tcf_add_notify(net, n, actions, portid, attr_size, extack);
net/sched/act_api.c
2132
struct net *net = sock_net(skb->sk);
net/sched/act_api.c
2163
ret = tcf_action_add(net, tca[TCA_ACT_TAB], n, portid, flags,
net/sched/act_api.c
2167
ret = tca_action_gd(net, tca[TCA_ACT_TAB], n,
net/sched/act_api.c
2171
ret = tca_action_gd(net, tca[TCA_ACT_TAB], n,
net/sched/act_api.c
2205
struct net *net = sock_net(skb->sk);
net/sched/act_api.c
2266
ret = __tcf_generic_walker(net, skb, cb, RTM_GETACTION, a_o, NULL);
net/sched/act_api.c
719
static int __tcf_generic_walker(struct net *net, struct sk_buff *skb,
net/sched/act_api.c
724
struct tc_action_net *tn = net_generic(net, ops->net_id);
net/sched/act_api.c
727
return ops->walk(net, skb, cb, type, ops, extack);
net/sched/act_api.c
732
static int __tcf_idr_search(struct net *net,
net/sched/act_api.c
736
struct tc_action_net *tn = net_generic(net, ops->net_id);
net/sched/act_api.c
739
return ops->lookup(net, a, index);
net/sched/act_bpf.c
277
static int tcf_bpf_init(struct net *net, struct nlattr *nla,
net/sched/act_bpf.c
282
struct tc_action_net *tn = net_generic(net, act_bpf_ops.net_id);
net/sched/act_bpf.c
404
static __net_init int bpf_init_net(struct net *net)
net/sched/act_bpf.c
406
struct tc_action_net *tn = net_generic(net, act_bpf_ops.net_id);
net/sched/act_bpf.c
408
return tc_action_net_init(net, tn, &act_bpf_ops);
net/sched/act_connmark.c
103
struct tc_action_net *tn = net_generic(net, act_connmark_ops.net_id);
net/sched/act_connmark.c
142
nparms->net = net;
net/sched/act_connmark.c
157
nparms->net = rtnl_dereference(ci->parms)->net;
net/sched/act_connmark.c
251
static __net_init int connmark_init_net(struct net *net)
net/sched/act_connmark.c
253
struct tc_action_net *tn = net_generic(net, act_connmark_ops.net_id);
net/sched/act_connmark.c
255
return tc_action_net_init(net, tn, &act_connmark_ops);
net/sched/act_connmark.c
72
if (!nf_ct_get_tuplepr(skb, skb_network_offset(skb), proto, parms->net,
net/sched/act_connmark.c
79
thash = nf_conntrack_find_get(parms->net, &zone, &tuple);
net/sched/act_connmark.c
98
static int tcf_connmark_init(struct net *net, struct nlattr *nla,
net/sched/act_csum.c
43
static int tcf_csum_init(struct net *net, struct nlattr *nla,
net/sched/act_csum.c
48
struct tc_action_net *tn = net_generic(net, act_csum_ops.net_id);
net/sched/act_csum.c
722
static __net_init int csum_init_net(struct net *net)
net/sched/act_csum.c
724
struct tc_action_net *tn = net_generic(net, act_csum_ops.net_id);
net/sched/act_csum.c
726
return tc_action_net_init(net, tn, &act_csum_ops);
net/sched/act_ct.c
1015
err = tcf_ct_handle_fragments(net, skb, family, p->zone, &defrag);
net/sched/act_ct.c
1028
cached = tcf_ct_skb_nfct_cached(net, skb, p);
net/sched/act_ct.c
1043
state.net = net;
net/sched/act_ct.c
1238
static int tcf_ct_fill_params(struct net *net,
net/sched/act_ct.c
1283
if (nf_connlabels_get(net, n_bits - 1)) {
net/sched/act_ct.c
1310
tmpl = nf_ct_tmpl_alloc(net, &zone, GFP_KERNEL);
net/sched/act_ct.c
1343
nf_connlabels_put(net);
net/sched/act_ct.c
1350
static int tcf_ct_init(struct net *net, struct nlattr *nla,
net/sched/act_ct.c
1355
struct tc_action_net *tn = net_generic(net, act_ct_ops.net_id);
net/sched/act_ct.c
1419
err = tcf_ct_fill_params(net, params, parm, tb, extack);
net/sched/act_ct.c
1423
err = tcf_ct_flow_table_get(net, params);
net/sched/act_ct.c
1653
static __net_init int ct_init_net(struct net *net)
net/sched/act_ct.c
1655
struct tc_ct_action_net *tn = net_generic(net, act_ct_ops.net_id);
net/sched/act_ct.c
1657
return tc_action_net_init(net, &tn->tn, &act_ct_ops);
net/sched/act_ct.c
204
static int tcf_ct_flow_table_add_action_nat(struct net *net,
net/sched/act_ct.c
244
static int tcf_ct_flow_table_fill_actions(struct net *net,
net/sched/act_ct.c
272
err = tcf_ct_flow_table_add_action_nat(net, ct, dir, action);
net/sched/act_ct.c
324
static int tcf_ct_flow_table_get(struct net *net, struct tcf_ct_params *params)
net/sched/act_ct.c
326
struct zones_ht_key key = { .net = net, .zone = params->zone };
net/sched/act_ct.c
355
write_pnet(&ct_ft->nf_ft.net, net);
net/sched/act_ct.c
47
struct net *net;
net/sched/act_ct.c
752
static bool tcf_ct_skb_nfct_cached(struct net *net, struct sk_buff *skb,
net/sched/act_ct.c
761
if (!net_eq(net, read_pnet(&ct->ct_net)))
net/sched/act_ct.c
843
static int tcf_ct_handle_fragments(struct net *net, struct sk_buff *skb,
net/sched/act_ct.c
866
err = nf_ct_handle_fragments(net, skb, zone, family, &proto, &cb.mru);
net/sched/act_ct.c
971
struct net *net = dev_net(skb->dev);
net/sched/act_ctinfo.c
121
proto, cp->net, &tuple))
net/sched/act_ctinfo.c
126
thash = nf_conntrack_find_get(cp->net, &zone, &tuple);
net/sched/act_ctinfo.c
155
static int tcf_ctinfo_init(struct net *net, struct nlattr *nla,
net/sched/act_ctinfo.c
160
struct tc_action_net *tn = net_generic(net, act_ctinfo_ops.net_id);
net/sched/act_ctinfo.c
245
cp_new->net = net;
net/sched/act_ctinfo.c
371
static __net_init int ctinfo_init_net(struct net *net)
net/sched/act_ctinfo.c
373
struct tc_action_net *tn = net_generic(net, act_ctinfo_ops.net_id);
net/sched/act_ctinfo.c
375
return tc_action_net_init(net, tn, &act_ctinfo_ops);
net/sched/act_gact.c
301
static __net_init int gact_init_net(struct net *net)
net/sched/act_gact.c
303
struct tc_action_net *tn = net_generic(net, act_gact_ops.net_id);
net/sched/act_gact.c
305
return tc_action_net_init(net, tn, &act_gact_ops);
net/sched/act_gact.c
53
static int tcf_gact_init(struct net *net, struct nlattr *nla,
net/sched/act_gact.c
58
struct tc_action_net *tn = net_generic(net, act_gact_ops.net_id);
net/sched/act_gate.c
347
static int tcf_gate_init(struct net *net, struct nlattr *nla,
net/sched/act_gate.c
352
struct tc_action_net *tn = net_generic(net, act_gate_ops.net_id);
net/sched/act_gate.c
751
static __net_init int gate_init_net(struct net *net)
net/sched/act_gate.c
753
struct tc_action_net *tn = net_generic(net, act_gate_ops.net_id);
net/sched/act_gate.c
755
return tc_action_net_init(net, tn, &act_gate_ops);
net/sched/act_ife.c
477
static int tcf_ife_init(struct net *net, struct nlattr *nla,
net/sched/act_ife.c
482
struct tc_action_net *tn = net_generic(net, act_ife_ops.net_id);
net/sched/act_ife.c
893
static __net_init int ife_init_net(struct net *net)
net/sched/act_ife.c
895
struct tc_action_net *tn = net_generic(net, act_ife_ops.net_id);
net/sched/act_ife.c
897
return tc_action_net_init(net, tn, &act_ife_ops);
net/sched/act_mirred.c
104
static int tcf_mirred_init(struct net *net, struct nlattr *nla,
net/sched/act_mirred.c
109
struct tc_action_net *tn = net_generic(net, act_mirred_ops.net_id);
net/sched/act_mirred.c
199
ndev = dev_get_by_index(net, parm->ifindex);
net/sched/act_mirred.c
680
static __net_init int mirred_init_net(struct net *net)
net/sched/act_mirred.c
682
struct tc_action_net *tn = net_generic(net, act_mirred_ops.net_id);
net/sched/act_mirred.c
684
return tc_action_net_init(net, tn, &act_mirred_ops);
net/sched/act_mpls.c
158
static int tcf_mpls_init(struct net *net, struct nlattr *nla,
net/sched/act_mpls.c
163
struct tc_action_net *tn = net_generic(net, act_mpls_ops.net_id);
net/sched/act_mpls.c
256
mpls_ttl = net->mpls.default_ttl ?
net/sched/act_mpls.c
257
net->mpls.default_ttl : ACT_MPLS_TTL_DEFAULT;
net/sched/act_mpls.c
454
static __net_init int mpls_init_net(struct net *net)
net/sched/act_mpls.c
456
struct tc_action_net *tn = net_generic(net, act_mpls_ops.net_id);
net/sched/act_mpls.c
458
return tc_action_net_init(net, tn, &act_mpls_ops);
net/sched/act_nat.c
328
static __net_init int nat_init_net(struct net *net)
net/sched/act_nat.c
330
struct tc_action_net *tn = net_generic(net, act_nat_ops.net_id);
net/sched/act_nat.c
332
return tc_action_net_init(net, tn, &act_nat_ops);
net/sched/act_nat.c
35
static int tcf_nat_init(struct net *net, struct nlattr *nla, struct nlattr *est,
net/sched/act_nat.c
39
struct tc_action_net *tn = net_generic(net, act_nat_ops.net_id);
net/sched/act_pedit.c
159
static int tcf_pedit_init(struct net *net, struct nlattr *nla,
net/sched/act_pedit.c
164
struct tc_action_net *tn = net_generic(net, act_pedit_ops.net_id);
net/sched/act_pedit.c
643
static __net_init int pedit_init_net(struct net *net)
net/sched/act_pedit.c
645
struct tc_action_net *tn = net_generic(net, act_pedit_ops.net_id);
net/sched/act_pedit.c
647
return tc_action_net_init(net, tn, &act_pedit_ops);
net/sched/act_police.c
40
static int tcf_police_init(struct net *net, struct nlattr *nla,
net/sched/act_police.c
505
static __net_init int police_init_net(struct net *net)
net/sched/act_police.c
507
struct tc_action_net *tn = net_generic(net, act_police_ops.net_id);
net/sched/act_police.c
509
return tc_action_net_init(net, tn, &act_police_ops);
net/sched/act_police.c
52
struct tc_action_net *tn = net_generic(net, act_police_ops.net_id);
net/sched/act_sample.c
101
psample_group = psample_group_get(net, psample_group_num);
net/sched/act_sample.c
333
static __net_init int sample_init_net(struct net *net)
net/sched/act_sample.c
335
struct tc_action_net *tn = net_generic(net, act_sample_ops.net_id);
net/sched/act_sample.c
337
return tc_action_net_init(net, tn, &act_sample_ops);
net/sched/act_sample.c
36
static int tcf_sample_init(struct net *net, struct nlattr *nla,
net/sched/act_sample.c
41
struct tc_action_net *tn = net_generic(net, act_sample_ops.net_id);
net/sched/act_simple.c
213
static __net_init int simp_init_net(struct net *net)
net/sched/act_simple.c
215
struct tc_action_net *tn = net_generic(net, act_simp_ops.net_id);
net/sched/act_simple.c
217
return tc_action_net_init(net, tn, &act_simp_ops);
net/sched/act_simple.c
87
static int tcf_simp_init(struct net *net, struct nlattr *nla,
net/sched/act_simple.c
92
struct tc_action_net *tn = net_generic(net, act_simp_ops.net_id);
net/sched/act_skbedit.c
115
static int tcf_skbedit_init(struct net *net, struct nlattr *nla,
net/sched/act_skbedit.c
120
struct tc_action_net *tn = net_generic(net, act_skbedit_ops.net_id);
net/sched/act_skbedit.c
433
static __net_init int skbedit_init_net(struct net *net)
net/sched/act_skbedit.c
435
struct tc_action_net *tn = net_generic(net, act_skbedit_ops.net_id);
net/sched/act_skbedit.c
437
return tc_action_net_init(net, tn, &act_skbedit_ops);
net/sched/act_skbmod.c
101
static int tcf_skbmod_init(struct net *net, struct nlattr *nla,
net/sched/act_skbmod.c
106
struct tc_action_net *tn = net_generic(net, act_skbmod_ops.net_id);
net/sched/act_skbmod.c
290
static __net_init int skbmod_init_net(struct net *net)
net/sched/act_skbmod.c
292
struct tc_action_net *tn = net_generic(net, act_skbmod_ops.net_id);
net/sched/act_skbmod.c
294
return tc_action_net_init(net, tn, &act_skbmod_ops);
net/sched/act_tunnel_key.c
361
static int tunnel_key_init(struct net *net, struct nlattr *nla,
net/sched/act_tunnel_key.c
366
struct tc_action_net *tn = net_generic(net, act_tunnel_key_ops.net_id);
net/sched/act_tunnel_key.c
851
static __net_init int tunnel_key_init_net(struct net *net)
net/sched/act_tunnel_key.c
853
struct tc_action_net *tn = net_generic(net, act_tunnel_key_ops.net_id);
net/sched/act_tunnel_key.c
855
return tc_action_net_init(net, tn, &act_tunnel_key_ops);
net/sched/act_vlan.c
114
static int tcf_vlan_init(struct net *net, struct nlattr *nla,
net/sched/act_vlan.c
119
struct tc_action_net *tn = net_generic(net, act_vlan_ops.net_id);
net/sched/act_vlan.c
431
static __net_init int vlan_init_net(struct net *net)
net/sched/act_vlan.c
433
struct tc_action_net *tn = net_generic(net, act_vlan_ops.net_id);
net/sched/act_vlan.c
435
return tc_action_net_init(net, tn, &act_vlan_ops);
net/sched/cls_api.c
1004
static void tcf_block_remove(struct tcf_block *block, struct net *net)
net/sched/cls_api.c
1006
struct tcf_net *tn = net_generic(net, tcf_net_id);
net/sched/cls_api.c
1013
static struct tcf_block *tcf_block_create(struct net *net, struct Qdisc *q,
net/sched/cls_api.c
1033
block->net = net;
net/sched/cls_api.c
1043
struct tcf_block *tcf_block_lookup(struct net *net, u32 block_index)
net/sched/cls_api.c
1045
struct tcf_net *tn = net_generic(net, tcf_net_id);
net/sched/cls_api.c
1051
static struct tcf_block *tcf_block_refcnt_get(struct net *net, u32 block_index)
net/sched/cls_api.c
1056
block = tcf_block_lookup(net, block_index);
net/sched/cls_api.c
1180
static int __tcf_qdisc_find(struct net *net, struct Qdisc **q,
net/sched/cls_api.c
1194
dev = dev_get_by_index_rcu(net, ifindex);
net/sched/cls_api.c
1275
static struct tcf_block *__tcf_block_find(struct net *net, struct Qdisc *q,
net/sched/cls_api.c
1283
block = tcf_block_refcnt_get(net, block_index);
net/sched/cls_api.c
1326
tcf_block_remove(block, block->net);
net/sched/cls_api.c
1349
static struct tcf_block *tcf_block_find(struct net *net, struct Qdisc **q,
net/sched/cls_api.c
1359
err = __tcf_qdisc_find(net, q, parent, ifindex, true, extack);
net/sched/cls_api.c
1367
block = __tcf_block_find(net, *q, *cl, ifindex, block_index, extack);
net/sched/cls_api.c
1469
struct net *net = qdisc_net(q);
net/sched/cls_api.c
1475
block = tcf_block_refcnt_get(net, ei->block_index);
net/sched/cls_api.c
1478
block = tcf_block_create(net, q, ei->block_index, extack);
net/sched/cls_api.c
1482
err = tcf_block_insert(block, net, extack);
net/sched/cls_api.c
2050
static int tcf_fill_node(struct net *net, struct sk_buff *skb,
net/sched/cls_api.c
2085
if (tp->ops->terse_dump(net, tp, fh, skb, tcm,
net/sched/cls_api.c
2093
tp->ops->dump(net, tp, fh, skb, tcm, rtnl_held) < 0)
net/sched/cls_api.c
2113
static struct sk_buff *tfilter_notify_prep(struct net *net,
net/sched/cls_api.c
2132
ret = tcf_fill_node(net, skb, tp, block, q, parent, fh, portid,
net/sched/cls_api.c
2146
static int tfilter_notify(struct net *net, struct sk_buff *oskb,
net/sched/cls_api.c
2156
if (!unicast && !rtnl_notify_needed(net, n->nlmsg_flags, RTNLGRP_TC))
net/sched/cls_api.c
2159
skb = tfilter_notify_prep(net, oskb, n, tp, block, q, parent, fh, event,
net/sched/cls_api.c
2165
err = rtnl_unicast(skb, net, portid);
net/sched/cls_api.c
2167
err = rtnetlink_send(skb, net, portid, RTNLGRP_TC,
net/sched/cls_api.c
2172
static int tfilter_del_notify(struct net *net, struct sk_buff *oskb,
net/sched/cls_api.c
2182
if (!rtnl_notify_needed(net, n->nlmsg_flags, RTNLGRP_TC))
net/sched/cls_api.c
2185
skb = tfilter_notify_prep(net, oskb, n, tp, block, q, parent, fh,
net/sched/cls_api.c
2198
err = rtnetlink_send(skb, net, portid, RTNLGRP_TC,
net/sched/cls_api.c
2206
static void tfilter_notify_chain(struct net *net, struct sk_buff *oskb,
net/sched/cls_api.c
2216
tfilter_notify(net, oskb, n, tp, block, q, parent, NULL,
net/sched/cls_api.c
2239
struct net *net = sock_net(skb->sk);
net/sched/cls_api.c
2295
err = __tcf_qdisc_find(net, &q, &parent, t->tcm_ifindex, false, extack);
net/sched/cls_api.c
2320
block = __tcf_block_find(net, q, cl, t->tcm_ifindex, t->tcm_block_index,
net/sched/cls_api.c
2430
err = tp->ops->change(net, skb, tp, cl, t->tcm_handle, tca, &fh,
net/sched/cls_api.c
2433
tfilter_notify(net, skb, n, tp, block, q, parent, fh,
net/sched/cls_api.c
2475
struct net *net = sock_net(skb->sk);
net/sched/cls_api.c
2510
err = __tcf_qdisc_find(net, &q, &parent, t->tcm_ifindex, false, extack);
net/sched/cls_api.c
2534
block = __tcf_block_find(net, q, cl, t->tcm_ifindex, t->tcm_block_index,
net/sched/cls_api.c
2562
tfilter_notify_chain(net, skb, block, q, parent, n,
net/sched/cls_api.c
2589
tfilter_notify(net, skb, n, tp, block, q, parent, fh,
net/sched/cls_api.c
2604
err = tfilter_del_notify(net, skb, n, tp, block, q, parent, fh,
net/sched/cls_api.c
2634
struct net *net = sock_net(skb->sk);
net/sched/cls_api.c
2669
err = __tcf_qdisc_find(net, &q, &parent, t->tcm_ifindex, false, extack);
net/sched/cls_api.c
2692
block = __tcf_block_find(net, q, cl, t->tcm_ifindex, t->tcm_block_index,
net/sched/cls_api.c
2735
err = tfilter_notify(net, skb, n, tp, block, q, parent,
net/sched/cls_api.c
2769
struct net *net = sock_net(a->skb->sk);
net/sched/cls_api.c
2771
return tcf_fill_node(net, a->skb, tp, a->block, a->q, a->parent,
net/sched/cls_api.c
2781
struct net *net = sock_net(skb->sk);
net/sched/cls_api.c
2805
if (tcf_fill_node(net, skb, tp, block, q, parent, NULL,
net/sched/cls_api.c
2847
struct net *net = sock_net(skb->sk);
net/sched/cls_api.c
2874
block = tcf_block_refcnt_get(net, tcm->tcm_block_index);
net/sched/cls_api.c
2889
dev = __dev_get_by_index(net, tcm->tcm_ifindex);
net/sched/cls_api.c
2950
struct net *net, struct sk_buff *skb,
net/sched/cls_api.c
2987
if (ops->tmplt_dump(skb, net, priv) < 0)
net/sched/cls_api.c
3011
struct net *net = block->net;
net/sched/cls_api.c
3015
if (!unicast && !rtnl_notify_needed(net, flags, RTNLGRP_TC))
net/sched/cls_api.c
3023
chain->index, net, skb, block, portid,
net/sched/cls_api.c
3030
err = rtnl_unicast(skb, net, portid);
net/sched/cls_api.c
3032
err = rtnetlink_send(skb, net, portid, RTNLGRP_TC,
net/sched/cls_api.c
3044
struct net *net = block->net;
net/sched/cls_api.c
3047
if (!rtnl_notify_needed(net, flags, RTNLGRP_TC))
net/sched/cls_api.c
3054
if (tc_chain_fill_node(tmplt_ops, tmplt_priv, chain_index, net, skb,
net/sched/cls_api.c
3060
return rtnetlink_send(skb, net, portid, RTNLGRP_TC, flags & NLM_F_ECHO);
net/sched/cls_api.c
3063
static int tc_chain_tmplt_add(struct tcf_chain *chain, struct net *net,
net/sched/cls_api.c
3090
tmplt_priv = ops->tmplt_create(net, chain, tca, extack);
net/sched/cls_api.c
3116
struct net *net = sock_net(skb->sk);
net/sched/cls_api.c
3138
block = tcf_block_find(net, &q, &parent, &cl,
net/sched/cls_api.c
3199
err = tc_chain_tmplt_add(chain, net, tca, extack);
net/sched/cls_api.c
3209
tfilter_notify_chain(net, skb, block, q, parent, n,
net/sched/cls_api.c
3247
struct net *net = sock_net(skb->sk);
net/sched/cls_api.c
3266
block = tcf_block_refcnt_get(net, tcm->tcm_block_index);
net/sched/cls_api.c
3274
dev = __dev_get_by_index(net, tcm->tcm_ifindex);
net/sched/cls_api.c
3317
chain->index, net, skb, block,
net/sched/cls_api.c
3338
int tcf_exts_init_ex(struct tcf_exts *exts, struct net *net, int action,
net/sched/cls_api.c
3351
exts->net = net;
net/sched/cls_api.c
3392
int tcf_exts_validate_ex(struct net *net, struct tcf_proto *tp, struct nlattr **tb,
net/sched/cls_api.c
3410
act = tcf_action_init_1(net, tp, tb[exts->police],
net/sched/cls_api.c
3425
err = tcf_action_init(net, tp, tb[exts->action],
net/sched/cls_api.c
3446
int tcf_exts_validate(struct net *net, struct tcf_proto *tp, struct nlattr **tb,
net/sched/cls_api.c
3450
return tcf_exts_validate_ex(net, tp, tb, rate_tlv, exts,
net/sched/cls_api.c
4078
static __net_init int tcf_net_init(struct net *net)
net/sched/cls_api.c
4080
struct tcf_net *tn = net_generic(net, tcf_net_id);
net/sched/cls_api.c
4087
static void __net_exit tcf_net_exit(struct net *net)
net/sched/cls_api.c
4089
struct tcf_net *tn = net_generic(net, tcf_net_id);
net/sched/cls_api.c
783
bo->net = dev_net(dev);
net/sched/cls_api.c
988
static int tcf_block_insert(struct tcf_block *block, struct net *net,
net/sched/cls_api.c
991
struct tcf_net *tn = net_generic(net, tcf_net_id);
net/sched/cls_basic.c
147
static int basic_set_parms(struct net *net, struct tcf_proto *tp,
net/sched/cls_basic.c
155
err = tcf_exts_validate(net, tp, tb, est, &f->exts, flags, extack);
net/sched/cls_basic.c
172
static int basic_change(struct net *net, struct sk_buff *in_skb,
net/sched/cls_basic.c
200
err = tcf_exts_init(&fnew->exts, net, TCA_BASIC_ACT, TCA_BASIC_POLICE);
net/sched/cls_basic.c
221
err = basic_set_parms(net, tp, fnew, base, tb, tca[TCA_RATE], flags,
net/sched/cls_basic.c
269
static int basic_dump(struct net *net, struct tcf_proto *tp, void *fh,
net/sched/cls_bpf.c
409
static int cls_bpf_change(struct net *net, struct sk_buff *in_skb,
net/sched/cls_bpf.c
436
ret = tcf_exts_init(&prog->exts, net, TCA_BPF_ACT, TCA_BPF_POLICE);
net/sched/cls_bpf.c
467
ret = tcf_exts_validate(net, tp, tb, tca[TCA_RATE], &prog->exts,
net/sched/cls_bpf.c
579
static int cls_bpf_dump(struct net *net, struct tcf_proto *tp, void *fh,
net/sched/cls_cgroup.c
102
err = tcf_exts_init(&new->exts, net, TCA_CGROUP_ACT, TCA_CGROUP_POLICE);
net/sched/cls_cgroup.c
113
err = tcf_exts_validate(net, tp, tb, tca[TCA_RATE], &new->exts, flags,
net/sched/cls_cgroup.c
172
static int cls_cgroup_dump(struct net *net, struct tcf_proto *tp, void *fh,
net/sched/cls_cgroup.c
78
static int cls_cgroup_change(struct net *net, struct sk_buff *in_skb,
net/sched/cls_flow.c
395
static int flow_change(struct net *net, struct sk_buff *in_skb,
net/sched/cls_flow.c
449
err = tcf_exts_init(&fnew->exts, net, TCA_FLOW_ACT, TCA_FLOW_POLICE);
net/sched/cls_flow.c
453
err = tcf_exts_validate(net, tp, tb, tca[TCA_RATE], &fnew->exts, flags,
net/sched/cls_flow.c
635
static int flow_dump(struct net *net, struct tcf_proto *tp, void *fh,
net/sched/cls_flower.c
1866
static int fl_set_key(struct net *net, struct nlattr *tca_opts,
net/sched/cls_flower.c
1874
int err = tcf_change_indev(net, tb[TCA_FLOWER_INDEV], extack);
net/sched/cls_flower.c
2353
static int fl_change(struct net *net, struct sk_buff *in_skb,
net/sched/cls_flower.c
2443
err = tcf_exts_init_ex(&fnew->exts, net, TCA_FLOWER_ACT, 0, tp, handle,
net/sched/cls_flower.c
2448
err = tcf_exts_validate_ex(net, tp, tb, tca[TCA_RATE],
net/sched/cls_flower.c
2464
err = fl_set_key(net, tca_opts, tb, &fnew->key, &mask->key, extack);
net/sched/cls_flower.c
2802
static void *fl_tmplt_create(struct net *net, struct tcf_chain *chain,
net/sched/cls_flower.c
2828
err = fl_set_key(net, tca_opts, tb, &tmplt->dummy_key,
net/sched/cls_flower.c
3435
static int fl_dump_key(struct sk_buff *skb, struct net *net,
net/sched/cls_flower.c
3441
dev = __dev_get_by_index(net, key->meta.ingress_ifindex);
net/sched/cls_flower.c
3684
static int fl_dump(struct net *net, struct tcf_proto *tp, void *fh,
net/sched/cls_flower.c
3711
if (fl_dump_key(skb, net, key, mask))
net/sched/cls_flower.c
3742
static int fl_terse_dump(struct net *net, struct tcf_proto *tp, void *fh,
net/sched/cls_flower.c
3784
static int fl_tmplt_dump(struct sk_buff *skb, struct net *net, void *tmplt_priv)
net/sched/cls_flower.c
3797
if (fl_dump_key(skb, net, key, mask))
net/sched/cls_fw.c
205
static int fw_set_parms(struct net *net, struct tcf_proto *tp,
net/sched/cls_fw.c
214
err = tcf_exts_validate(net, tp, tb, tca[TCA_RATE], &f->exts, flags,
net/sched/cls_fw.c
221
ret = tcf_change_indev(net, tb[TCA_FW_INDEV], extack);
net/sched/cls_fw.c
243
static int fw_change(struct net *net, struct sk_buff *in_skb,
net/sched/cls_fw.c
287
err = tcf_exts_init(&fnew->exts, net, TCA_FW_ACT,
net/sched/cls_fw.c
294
err = fw_set_parms(net, tp, fnew, tb, tca, base, flags, extack);
net/sched/cls_fw.c
337
err = tcf_exts_init(&f->exts, net, TCA_FW_ACT, TCA_FW_POLICE);
net/sched/cls_fw.c
343
err = fw_set_parms(net, tp, f, tb, tca, base, flags, extack);
net/sched/cls_fw.c
382
static int fw_dump(struct net *net, struct tcf_proto *tp, void *fh,
net/sched/cls_fw.c
406
dev = __dev_get_by_index(net, f->ifindex);
net/sched/cls_matchall.c
162
static int mall_change(struct net *net, struct sk_buff *in_skb,
net/sched/cls_matchall.c
196
err = tcf_exts_init(&new->exts, net, TCA_MATCHALL_ACT, 0);
net/sched/cls_matchall.c
210
err = tcf_exts_validate_ex(net, tp, tb, tca[TCA_RATE],
net/sched/cls_matchall.c
328
static int mall_dump(struct net *net, struct tcf_proto *tp, void *fh,
net/sched/cls_route.c
383
static int route4_set_parms(struct net *net, struct tcf_proto *tp,
net/sched/cls_route.c
395
err = tcf_exts_validate(net, tp, tb, est, &f->exts, flags, extack);
net/sched/cls_route.c
476
static int route4_change(struct net *net, struct sk_buff *in_skb,
net/sched/cls_route.c
514
err = tcf_exts_init(&f->exts, net, TCA_ROUTE4_ACT, TCA_ROUTE4_POLICE);
net/sched/cls_route.c
528
err = route4_set_parms(net, tp, base, f, handle, head, tb,
net/sched/cls_route.c
604
static int route4_dump(struct net *net, struct tcf_proto *tp, void *fh,
net/sched/cls_u32.c
1135
err = tcf_exts_init(&n->exts, net, TCA_U32_ACT, TCA_U32_POLICE);
net/sched/cls_u32.c
1155
err = u32_set_parms(net, tp, n, tb, tca[TCA_RATE],
net/sched/cls_u32.c
1345
static int u32_dump(struct net *net, struct tcf_proto *tp, void *fh,
net/sched/cls_u32.c
1418
dev = __dev_get_by_index(net, n->ifindex);
net/sched/cls_u32.c
740
static int u32_set_parms(struct net *net, struct tcf_proto *tp,
net/sched/cls_u32.c
747
err = tcf_exts_validate_ex(net, tp, tb, est, &n->exts, flags,
net/sched/cls_u32.c
753
ifindex = tcf_change_indev(net, tb[TCA_U32_INDEV], extack);
net/sched/cls_u32.c
821
static struct tc_u_knode *u32_init_knode(struct net *net, struct tcf_proto *tp,
net/sched/cls_u32.c
860
if (tcf_exts_init(&new->exts, net, TCA_U32_ACT, TCA_U32_POLICE)) {
net/sched/cls_u32.c
872
static int u32_change(struct net *net, struct sk_buff *in_skb,
net/sched/cls_u32.c
924
new = u32_init_knode(net, tp, n);
net/sched/cls_u32.c
928
err = u32_set_parms(net, tp, new, tb, tca[TCA_RATE],
net/sched/em_canid.c
123
static int em_canid_change(struct net *net, void *data, int len,
net/sched/em_ipset.c
19
static int em_ipset_change(struct net *net, void *data, int data_len,
net/sched/em_ipset.c
28
index = ip_set_nfnl_get_byindex(net, set->index);
net/sched/em_ipset.c
37
ip_set_nfnl_put(net, index);
net/sched/em_ipset.c
45
ip_set_nfnl_put(em->net, set->index);
net/sched/em_ipset.c
58
.net = em->net,
net/sched/em_ipset.c
94
indev = dev_get_by_index_rcu(em->net, skb->skb_iif);
net/sched/em_ipt.c
126
static int em_ipt_change(struct net *net, void *data, int data_len,
net/sched/em_ipt.c
171
ret = check_match(net, im, mdata_len);
net/sched/em_ipt.c
194
.net = em->net,
net/sched/em_ipt.c
235
indev = dev_get_by_index_rcu(em->net, skb->skb_iif);
net/sched/em_ipt.c
238
indev ?: skb->dev, skb->dev, NULL, em->net, NULL);
net/sched/em_ipt.c
42
static int check_match(struct net *net, struct em_ipt_match *im, int mdata_len)
net/sched/em_ipt.c
50
mtpar.net = net;
net/sched/em_meta.c
906
static int em_meta_change(struct net *net, void *data, int len,
net/sched/em_nbyte.c
22
static int em_nbyte_change(struct net *net, void *data, int data_len,
net/sched/em_text.c
50
static int em_text_change(struct net *net, void *data, int len,
net/sched/ematch.c
177
struct net *net = tp->chain->block->net;
net/sched/ematch.c
244
err = em->ops->change(net, data, data_len, em);
net/sched/ematch.c
277
em->net = net;
net/sched/sch_api.c
1010
static int qdisc_get_notify(struct net *net, struct sk_buff *oskb,
net/sched/sch_api.c
1028
return rtnetlink_send(skb, net, portid, RTNLGRP_TC,
net/sched/sch_api.c
1036
static int qdisc_notify(struct net *net, struct sk_buff *oskb,
net/sched/sch_api.c
1044
if (!rtnl_notify_needed(net, n->nlmsg_flags, RTNLGRP_TC))
net/sched/sch_api.c
1063
return rtnetlink_send(skb, net, portid, RTNLGRP_TC,
net/sched/sch_api.c
1071
static void notify_and_destroy(struct net *net, struct sk_buff *skb,
net/sched/sch_api.c
1077
qdisc_notify(net, skb, n, clid, old, new, extack);
net/sched/sch_api.c
1111
struct net *net = dev_net(dev);
net/sched/sch_api.c
1164
qdisc_notify(net, skb, n, classid, old, new, extack);
net/sched/sch_api.c
1177
notify_and_destroy(net, skb, n, classid, old, new, extack);
net/sched/sch_api.c
1217
notify_and_destroy(net, skb, n, classid, old, new, extack);
net/sched/sch_api.c
1491
struct net *net = sock_net(skb->sk);
net/sched/sch_api.c
1550
qdisc_get_notify(net, skb, n, clid, q, NULL);
net/sched/sch_api.c
1558
struct net *net = sock_net(skb->sk);
net/sched/sch_api.c
1569
dev = __dev_get_by_index(net, tcm->tcm_ifindex);
net/sched/sch_api.c
1816
struct net *net = sock_net(skb->sk);
net/sched/sch_api.c
1830
dev = __dev_get_by_index(net, tcm->tcm_ifindex);
net/sched/sch_api.c
1902
struct net *net = sock_net(skb->sk);
net/sched/sch_api.c
1925
for_each_netdev_dump(net, dev, ctx->ifindex) {
net/sched/sch_api.c
2018
static int tclass_notify(struct net *net, struct sk_buff *oskb,
net/sched/sch_api.c
2026
if (!rtnl_notify_needed(net, n->nlmsg_flags, RTNLGRP_TC))
net/sched/sch_api.c
2039
return rtnetlink_send(skb, net, portid, RTNLGRP_TC,
net/sched/sch_api.c
2043
static int tclass_get_notify(struct net *net, struct sk_buff *oskb,
net/sched/sch_api.c
2062
return rtnetlink_send(skb, net, portid, RTNLGRP_TC,
net/sched/sch_api.c
2066
static int tclass_del_notify(struct net *net,
net/sched/sch_api.c
2079
if (rtnl_notify_needed(net, n->nlmsg_flags, RTNLGRP_TC)) {
net/sched/sch_api.c
2098
err = rtnetlink_maybe_send(skb, net, portid, RTNLGRP_TC,
net/sched/sch_api.c
2194
struct net *net = sock_net(skb->sk);
net/sched/sch_api.c
2280
err = tclass_del_notify(net, cops, skb, n, q, cl, extack);
net/sched/sch_api.c
2285
err = tclass_get_notify(net, skb, n, q, cl, extack);
net/sched/sch_api.c
2309
tclass_notify(net, skb, n, q, new_cl, RTM_NEWTCLASS, extack);
net/sched/sch_api.c
2321
struct net *net = sock_net(skb->sk);
net/sched/sch_api.c
2332
dev = __dev_get_by_index(net, tcm->tcm_ifindex);
net/sched/sch_api.c
2447
struct net *net = sock_net(skb->sk);
net/sched/sch_api.c
2454
dev = dev_get_by_index(net, tcm->tcm_ifindex);
net/sched/sch_api.c
2478
static int __net_init psched_net_init(struct net *net)
net/sched/sch_api.c
2482
e = proc_create_single("psched", 0, net->proc_net, psched_show);
net/sched/sch_api.c
2489
static void __net_exit psched_net_exit(struct net *net)
net/sched/sch_api.c
2491
remove_proc_entry("psched", net->proc_net);
net/sched/sch_api.c
2494
static int __net_init psched_net_init(struct net *net)
net/sched/sch_api.c
2499
static void __net_exit psched_net_exit(struct net *net)
net/sched/sch_frag.c
113
ret = ip_do_fragment(net, skb->sk, skb, sch_frag_xmit);
net/sched/sch_frag.c
131
ret = ip6_fragment(net, skb->sk, skb, sch_frag_xmit);
net/sched/sch_frag.c
27
static int sch_frag_xmit(struct net *net, struct sock *sk, struct sk_buff *skb)
net/sched/sch_frag.c
89
static int sch_fragment(struct net *net, struct sk_buff *skb,
net/sctp/associola.c
1024
SCTP_INC_STATS(net, SCTP_MIB_INCTRLCHUNKS);
net/sctp/associola.c
1034
error = sctp_do_sm(net, SCTP_EVENT_T_CHUNK, subtype,
net/sctp/associola.c
1433
struct net *net = asoc->base.net;
net/sctp/associola.c
1442
(asoc->base.sk->sk_rcvbuf >> net->sctp.rwnd_upd_shift),
net/sctp/associola.c
1571
return sctp_bind_addr_copy(asoc->base.net,
net/sctp/associola.c
617
peer = sctp_transport_new(asoc->base.net, addr, gfp);
net/sctp/associola.c
67
asoc->base.net = sock_net(sk);
net/sctp/associola.c
966
struct net *net = asoc->base.net;
net/sctp/bind_addr.c
33
static int sctp_copy_one_addr(struct net *net, struct sctp_bind_addr *dest,
net/sctp/bind_addr.c
43
int sctp_bind_addr_copy(struct net *net, struct sctp_bind_addr *dest,
net/sctp/bind_addr.c
468
static int sctp_copy_one_addr(struct net *net, struct sctp_bind_addr *dest,
net/sctp/bind_addr.c
475
error = sctp_copy_local_addr_list(net, dest, scope, gfp, flags);
net/sctp/bind_addr.c
476
} else if (sctp_in_scope(net, addr, scope)) {
net/sctp/bind_addr.c
514
int sctp_in_scope(struct net *net, const union sctp_addr *addr,
net/sctp/bind_addr.c
533
switch (net->sctp.scope_policy) {
net/sctp/bind_addr.c
56
error = sctp_copy_one_addr(net, dest, &addr->a, scope,
net/sctp/bind_addr.c
68
error = sctp_copy_one_addr(net, dest, &addr->a,
net/sctp/chunk.c
229
SCTP_INC_STATS(asoc->base.net,
net/sctp/diag.c
434
struct net *net = sock_net(skb->sk);
net/sctp/diag.c
466
net, &laddr, &paddr, &commp, dif);
net/sctp/diag.c
473
struct net *net = sock_net(skb->sk);
net/sctp/diag.c
490
if (sctp_for_each_endpoint(sctp_ep_dump, net, &pos,
net/sctp/diag.c
512
net, &pos, &commp);
net/sctp/endpointola.c
112
ep->prsctp_enable = net->sctp.prsctp_enable;
net/sctp/endpointola.c
113
ep->reconf_enable = net->sctp.reconf_enable;
net/sctp/endpointola.c
114
ep->ecn_enable = net->sctp.ecn_enable;
net/sctp/endpointola.c
118
ep->base.net = sock_net(sk);
net/sctp/endpointola.c
249
struct net *net,
net/sctp/endpointola.c
256
if (net_eq(ep->base.net, net) &&
net/sctp/endpointola.c
257
sctp_sk_bound_dev_eq(net, bound_dev_if, dif, sdif) &&
net/sctp/endpointola.c
307
struct net *net = ep->base.net;
net/sctp/endpointola.c
315
if (sctp_has_association(net, &addr->a, paddr,
net/sctp/endpointola.c
333
struct net *net;
net/sctp/endpointola.c
348
net = sock_net(sk);
net/sctp/endpointola.c
400
SCTP_INC_STATS(ep->base.net, SCTP_MIB_INCTRLCHUNKS);
net/sctp/endpointola.c
408
error = sctp_do_sm(net, SCTP_EVENT_T_CHUNK, subtype, state,
net/sctp/endpointola.c
54
struct net *net = sock_net(sk);
net/sctp/endpointola.c
57
ep->asconf_enable = net->sctp.addip_enable;
net/sctp/endpointola.c
58
ep->auth_enable = net->sctp.auth_enable;
net/sctp/endpointola.c
89
ep->sndbuf_policy = net->sctp.sndbuf_policy;
net/sctp/endpointola.c
96
ep->rcvbuf_policy = net->sctp.rcvbuf_policy;
net/sctp/input.c
100
struct net *net = dev_net(skb->dev);
net/sctp/input.c
1006
.net = net,
net/sctp/input.c
1018
if (sctp_sk_bound_dev_eq(net, bound_dev_if, dif, sdif) &&
net/sctp/input.c
1037
.net = ep->base.net,
net/sctp/input.c
1053
struct net *net,
net/sctp/input.c
1062
t = sctp_addrs_lookup_transport(net, local, peer, dif, sdif);
net/sctp/input.c
107
__SCTP_INC_STATS(net, SCTP_MIB_INSCTPPACKS);
net/sctp/input.c
1075
struct sctp_association *sctp_lookup_association(struct net *net,
net/sctp/input.c
1084
asoc = __sctp_lookup_association(net, laddr, paddr, transportp, dif, sdif);
net/sctp/input.c
1091
bool sctp_has_association(struct net *net,
net/sctp/input.c
1098
if (sctp_lookup_association(net, laddr, paddr, &transport, dif, sdif)) {
net/sctp/input.c
1124
static struct sctp_association *__sctp_rcv_init_lookup(struct net *net,
net/sctp/input.c
1166
asoc = __sctp_lookup_association(net, laddr, paddr, transportp, dif, sdif);
net/sctp/input.c
1189
struct net *net,
net/sctp/input.c
1222
return __sctp_lookup_association(net, laddr, &paddr, transportp, dif, sdif);
net/sctp/input.c
1235
static struct sctp_association *__sctp_rcv_walk_lookup(struct net *net,
net/sctp/input.c
1278
if (have_auth || net->sctp.addip_noauth)
net/sctp/input.c
1280
net, ch, laddr,
net/sctp/input.c
1304
static struct sctp_association *__sctp_rcv_lookup_harder(struct net *net,
net/sctp/input.c
132
sctp_rcv_checksum(net, skb) < 0)
net/sctp/input.c
1332
return __sctp_rcv_init_lookup(net, skb, laddr, transportp, dif, sdif);
net/sctp/input.c
1334
return __sctp_rcv_walk_lookup(net, skb, laddr, transportp, dif, sdif);
net/sctp/input.c
1338
static struct sctp_association *__sctp_rcv_lookup(struct net *net,
net/sctp/input.c
1347
asoc = __sctp_lookup_association(net, laddr, paddr, transportp, dif, sdif);
net/sctp/input.c
1355
asoc = __sctp_rcv_lookup_harder(net, skb, laddr, transportp, dif, sdif);
net/sctp/input.c
165
asoc = __sctp_rcv_lookup(net, skb, &src, &dest, &transport, dif, sdif);
net/sctp/input.c
168
ep = __sctp_rcv_lookup_endpoint(net, skb, &dest, &src, dif, sdif);
net/sctp/input.c
184
__SCTP_INC_STATS(net, SCTP_MIB_OUTOFBLUES);
net/sctp/input.c
240
__SCTP_INC_STATS(net, SCTP_MIB_IN_PKT_BACKLOG);
net/sctp/input.c
242
__SCTP_INC_STATS(net, SCTP_MIB_IN_PKT_SOFTIRQ);
net/sctp/input.c
257
__SCTP_INC_STATS(net, SCTP_MIB_IN_PKT_DISCARDS);
net/sctp/input.c
444
struct net *net = sock_net(sk);
net/sctp/input.c
452
sctp_do_sm(net, SCTP_EVENT_T_OTHER,
net/sctp/input.c
460
struct sock *sctp_err_lookup(struct net *net, int family, struct sk_buff *skb,
net/sctp/input.c
49
static struct sctp_association *__sctp_rcv_lookup(struct net *net,
net/sctp/input.c
490
asoc = __sctp_lookup_association(net, &saddr, &daddr, &transport, dif, sdif);
net/sctp/input.c
529
__NET_INC_STATS(net, LINUX_MIB_LOCKDROPPEDICMPS);
net/sctp/input.c
56
struct net *net, struct sk_buff *skb,
net/sctp/input.c
61
struct net *net,
net/sctp/input.c
612
struct net *net = dev_net(skb->dev);
net/sctp/input.c
623
sk = sctp_err_lookup(net, AF_INET, skb, sctp_hdr(skb), &asoc, &transport);
net/sctp/input.c
628
__ICMP_INC_STATS(net, ICMP_MIB_INERRORS);
net/sctp/input.c
640
struct net *net = dev_net(skb->dev);
net/sctp/input.c
647
sk = sctp_err_lookup(net, AF_INET, skb, sctp_hdr(skb), &asoc, &t);
net/sctp/input.c
649
__ICMP_INC_STATS(net, ICMP_MIB_INERRORS);
net/sctp/input.c
71
static inline int sctp_rcv_checksum(struct net *net, struct sk_buff *skb)
net/sctp/input.c
736
struct net *net = sock_net(sk);
net/sctp/input.c
740
ep->hashent = sctp_ep_hashfn(net, ep->base.bind_addr.port);
net/sctp/input.c
758
if (!net_eq(sock_net(sk2), net) || sk2 == sk ||
net/sctp/input.c
79
__SCTP_INC_STATS(net, SCTP_MIB_CHECKSUMERRORS);
net/sctp/input.c
825
static inline __u32 sctp_hashfn(const struct net *net, __be16 lport,
net/sctp/input.c
836
(__force __u32)lport, net_hash_mix(net), seed);
net/sctp/input.c
841
struct net *net, struct sk_buff *skb,
net/sctp/input.c
853
hash = sctp_ep_hashfn(net, ntohs(lport));
net/sctp/input.c
857
if (sctp_endpoint_is_match(ep, net, laddr, dif, sdif))
net/sctp/input.c
861
ep = sctp_sk(net->sctp.ctl_sock)->ep;
net/sctp/input.c
866
__u32 phash = sctp_hashfn(net, lport, paddr, 0);
net/sctp/input.c
881
const struct net *net;
net/sctp/input.c
897
if (!net_eq(t->asoc->base.net, x->net))
net/sctp/input.c
912
return sctp_hashfn(t->asoc->base.net,
net/sctp/input.c
921
return sctp_hashfn(x->net, x->lport, x->paddr, seed);
net/sctp/input.c
952
arg.net = t->asoc->base.net;
net/sctp/input.c
984
bool sctp_sk_bound_dev_eq(struct net *net, int bound_dev_if, int dif, int sdif)
net/sctp/input.c
989
l3mdev_accept = !!READ_ONCE(net->sctp.l3mdev_accept);
net/sctp/input.c
996
struct net *net,
net/sctp/ipv6.c
101
&net->sctp.local_addr_list, list) {
net/sctp/ipv6.c
109
sctp_addr_wq_mgmt(net, addr, SCTP_ADDR_DEL);
net/sctp/ipv6.c
113
spin_unlock_bh(&net->sctp.local_addr_lock);
net/sctp/ipv6.c
164
struct net *net = dev_net(skb->dev);
net/sctp/ipv6.c
175
sk = sctp_err_lookup(net, AF_INET6, skb, sctp_hdr(skb), &asoc, &transport);
net/sctp/ipv6.c
180
__ICMP6_INC_STATS(net, __in6_dev_get(skb->dev), ICMP6_MIB_INERRORS);
net/sctp/ipv6.c
192
struct net *net = dev_net(skb->dev);
net/sctp/ipv6.c
199
sk = sctp_err_lookup(net, AF_INET6, skb, sctp_hdr(skb), &asoc, &t);
net/sctp/ipv6.c
201
__ICMP6_INC_STATS(net, __in6_dev_get(skb->dev), ICMP6_MIB_INERRORS);
net/sctp/ipv6.c
691
struct net *net = sock_net(sk);
net/sctp/ipv6.c
711
dev = dev_get_by_index_rcu(net, bound_dev_if);
net/sctp/ipv6.c
716
res = ipv6_can_nonlocal_bind(net, &sp->inet) ||
net/sctp/ipv6.c
717
ipv6_chk_addr(net, in6, dev, 0);
net/sctp/ipv6.c
81
struct net *net = dev_net(ifa->idev->dev);
net/sctp/ipv6.c
92
spin_lock_bh(&net->sctp.local_addr_lock);
net/sctp/ipv6.c
93
list_add_tail_rcu(&addr->list, &net->sctp.local_addr_list);
net/sctp/ipv6.c
94
sctp_addr_wq_mgmt(net, addr, SCTP_ADDR_NEW);
net/sctp/ipv6.c
95
spin_unlock_bh(&net->sctp.local_addr_lock);
net/sctp/ipv6.c
959
struct net *net;
net/sctp/ipv6.c
962
net = sock_net(&opt->inet.sk);
net/sctp/ipv6.c
964
dev = dev_get_by_index_rcu(net, addr->v6.sin6_scope_id);
net/sctp/ipv6.c
965
if (!dev || !(ipv6_can_nonlocal_bind(net, &opt->inet) ||
net/sctp/ipv6.c
966
ipv6_chk_addr(net, &addr->v6.sin6_addr,
net/sctp/ipv6.c
99
spin_lock_bh(&net->sctp.local_addr_lock);
net/sctp/objcnt.c
102
net->sctp.proc_net_sctp, &sctp_objcnt_seq_ops);
net/sctp/objcnt.c
97
void sctp_dbg_objcnt_init(struct net *net)
net/sctp/output.c
311
SCTP_INC_STATS(asoc->base.net,
net/sctp/outqueue.c
1922
SCTP_INC_STATS(asoc->base.net, SCTP_MIB_OUTCTRLCHUNKS);
net/sctp/outqueue.c
283
struct net *net = q->asoc->base.net;
net/sctp/outqueue.c
304
SCTP_INC_STATS(net, SCTP_MIB_OUTUNORDERCHUNKS);
net/sctp/outqueue.c
306
SCTP_INC_STATS(net, SCTP_MIB_OUTORDERCHUNKS);
net/sctp/outqueue.c
309
SCTP_INC_STATS(net, SCTP_MIB_OUTCTRLCHUNKS);
net/sctp/outqueue.c
540
struct net *net = q->asoc->base.net;
net/sctp/outqueue.c
544
SCTP_INC_STATS(net, SCTP_MIB_T3_RETRANSMITS);
net/sctp/outqueue.c
558
SCTP_INC_STATS(net, SCTP_MIB_FAST_RETRANSMITS);
net/sctp/outqueue.c
563
SCTP_INC_STATS(net, SCTP_MIB_PMTUD_RETRANSMITS);
net/sctp/outqueue.c
566
SCTP_INC_STATS(net, SCTP_MIB_T1_RETRANSMITS);
net/sctp/primitive.c
38
int sctp_primitive_ ## name(struct net *net, struct sctp_association *asoc, \
net/sctp/primitive.c
50
error = sctp_do_sm(net, event_type, subtype, state, ep, asoc, \
net/sctp/proc.c
376
int __net_init sctp_proc_init(struct net *net)
net/sctp/proc.c
378
net->sctp.proc_net_sctp = proc_net_mkdir(net, "sctp", net->proc_net);
net/sctp/proc.c
379
if (!net->sctp.proc_net_sctp)
net/sctp/proc.c
381
if (!proc_create_net_single("snmp", 0444, net->sctp.proc_net_sctp,
net/sctp/proc.c
384
if (!proc_create_net("eps", 0444, net->sctp.proc_net_sctp,
net/sctp/proc.c
387
if (!proc_create_net("assocs", 0444, net->sctp.proc_net_sctp,
net/sctp/proc.c
390
if (!proc_create_net("remaddr", 0444, net->sctp.proc_net_sctp,
net/sctp/proc.c
396
remove_proc_subtree("sctp", net->proc_net);
net/sctp/proc.c
397
net->sctp.proc_net_sctp = NULL;
net/sctp/proc.c
62
struct net *net = seq->private;
net/sctp/proc.c
68
net->sctp.sctp_statistics);
net/sctp/protocol.c
105
static void sctp_get_local_addr_list(struct net *net)
net/sctp/protocol.c
112
for_each_netdev_rcu(net, dev) {
net/sctp/protocol.c
115
af->copy_addrlist(&net->sctp.local_addr_list, dev);
net/sctp/protocol.c
1218
static inline int init_sctp_mibs(struct net *net)
net/sctp/protocol.c
122
static void sctp_free_local_addr_list(struct net *net)
net/sctp/protocol.c
1220
net->sctp.sctp_statistics = alloc_percpu(struct sctp_mib);
net/sctp/protocol.c
1221
if (!net->sctp.sctp_statistics)
net/sctp/protocol.c
1226
static inline void cleanup_sctp_mibs(struct net *net)
net/sctp/protocol.c
1228
free_percpu(net->sctp.sctp_statistics);
net/sctp/protocol.c
127
list_for_each_safe(pos, temp, &net->sctp.local_addr_list) {
net/sctp/protocol.c
1289
static int __net_init sctp_defaults_init(struct net *net)
net/sctp/protocol.c
1298
net->sctp.rto_initial = SCTP_RTO_INITIAL;
net/sctp/protocol.c
1300
net->sctp.rto_min = SCTP_RTO_MIN;
net/sctp/protocol.c
1302
net->sctp.rto_max = SCTP_RTO_MAX;
net/sctp/protocol.c
1304
net->sctp.rto_alpha = SCTP_RTO_ALPHA;
net/sctp/protocol.c
1306
net->sctp.rto_beta = SCTP_RTO_BETA;
net/sctp/protocol.c
1309
net->sctp.valid_cookie_life = SCTP_DEFAULT_COOKIE_LIFE;
net/sctp/protocol.c
1312
net->sctp.cookie_preserve_enable = 1;
net/sctp/protocol.c
1315
net->sctp.cookie_auth_enable =
net/sctp/protocol.c
1319
net->sctp.max_burst = SCTP_DEFAULT_MAX_BURST;
net/sctp/protocol.c
1322
net->sctp.ps_retrans = SCTP_PS_RETRANS_MAX;
net/sctp/protocol.c
1325
net->sctp.pf_enable = 1;
net/sctp/protocol.c
1328
net->sctp.pf_expose = SCTP_PF_EXPOSE_UNSET;
net/sctp/protocol.c
1334
net->sctp.max_retrans_association = 10;
net/sctp/protocol.c
1335
net->sctp.max_retrans_path = 5;
net/sctp/protocol.c
1336
net->sctp.max_retrans_init = 8;
net/sctp/protocol.c
1339
net->sctp.sndbuf_policy = 0;
net/sctp/protocol.c
1342
net->sctp.rcvbuf_policy = 0;
net/sctp/protocol.c
1345
net->sctp.hb_interval = SCTP_DEFAULT_TIMEOUT_HEARTBEAT;
net/sctp/protocol.c
1348
net->sctp.sack_timeout = SCTP_DEFAULT_TIMEOUT_SACK;
net/sctp/protocol.c
135
int sctp_copy_local_addr_list(struct net *net, struct sctp_bind_addr *bp,
net/sctp/protocol.c
1351
net->sctp.addip_enable = 0;
net/sctp/protocol.c
1352
net->sctp.addip_noauth = 0;
net/sctp/protocol.c
1353
net->sctp.default_auto_asconf = 0;
net/sctp/protocol.c
1356
net->sctp.prsctp_enable = 1;
net/sctp/protocol.c
1359
net->sctp.reconf_enable = 0;
net/sctp/protocol.c
1362
net->sctp.auth_enable = 0;
net/sctp/protocol.c
1365
net->sctp.ecn_enable = 1;
net/sctp/protocol.c
1368
net->sctp.udp_port = 0;
net/sctp/protocol.c
1371
net->sctp.encap_port = 0;
net/sctp/protocol.c
1374
net->sctp.scope_policy = SCTP_SCOPE_POLICY_ENABLE;
net/sctp/protocol.c
1377
net->sctp.rwnd_upd_shift = SCTP_DEFAULT_RWND_SHIFT;
net/sctp/protocol.c
1380
net->sctp.max_autoclose = INT_MAX / HZ;
net/sctp/protocol.c
1383
net->sctp.l3mdev_accept = 1;
net/sctp/protocol.c
1387
status = init_sctp_mibs(net);
net/sctp/protocol.c
1393
status = sctp_proc_init(net);
net/sctp/protocol.c
1398
sctp_dbg_objcnt_init(net);
net/sctp/protocol.c
1401
INIT_LIST_HEAD(&net->sctp.local_addr_list);
net/sctp/protocol.c
1402
spin_lock_init(&net->sctp.local_addr_lock);
net/sctp/protocol.c
1403
sctp_get_local_addr_list(net);
net/sctp/protocol.c
1406
INIT_LIST_HEAD(&net->sctp.addr_waitq);
net/sctp/protocol.c
1407
INIT_LIST_HEAD(&net->sctp.auto_asconf_splist);
net/sctp/protocol.c
1408
spin_lock_init(&net->sctp.addr_wq_lock);
net/sctp/protocol.c
1409
net->sctp.addr_wq_timer.expires = 0;
net/sctp/protocol.c
1410
timer_setup(&net->sctp.addr_wq_timer, sctp_addr_wq_timeout_handler, 0);
net/sctp/protocol.c
1416
cleanup_sctp_mibs(net);
net/sctp/protocol.c
1422
static void __net_exit sctp_defaults_exit(struct net *net)
net/sctp/protocol.c
1425
sctp_free_addr_wq(net);
net/sctp/protocol.c
1426
sctp_free_local_addr_list(net);
net/sctp/protocol.c
1429
remove_proc_subtree("sctp", net->proc_net);
net/sctp/protocol.c
143
list_for_each_entry_rcu(addr, &net->sctp.local_addr_list, list) {
net/sctp/protocol.c
1430
net->sctp.proc_net_sctp = NULL;
net/sctp/protocol.c
1432
cleanup_sctp_mibs(net);
net/sctp/protocol.c
1440
static int __net_init sctp_ctrlsock_init(struct net *net)
net/sctp/protocol.c
1445
status = sctp_ctl_sock_init(net);
net/sctp/protocol.c
1451
status = sctp_sysctl_net_register(net);
net/sctp/protocol.c
1453
inet_ctl_sock_destroy(net->sctp.ctl_sock);
net/sctp/protocol.c
1454
net->sctp.ctl_sock = NULL;
net/sctp/protocol.c
146
if (!sctp_in_scope(net, &addr->a, scope))
net/sctp/protocol.c
1460
static void __net_exit sctp_ctrlsock_exit(struct net *net)
net/sctp/protocol.c
1462
sctp_sysctl_net_unregister(net);
net/sctp/protocol.c
1463
sctp_udp_sock_stop(net);
net/sctp/protocol.c
1466
inet_ctl_sock_destroy(net->sctp.ctl_sock);
net/sctp/protocol.c
1467
net->sctp.ctl_sock = NULL;
net/sctp/protocol.c
355
struct net *net = sock_net(sk);
net/sctp/protocol.c
359
tb_id = l3mdev_fib_table_by_index(net, sk->sk_bound_dev_if) ?: tb_id;
net/sctp/protocol.c
360
ret = inet_addr_type_table(net, addr->v4.sin_addr.s_addr, tb_id);
net/sctp/protocol.c
364
!READ_ONCE(net->ipv4.sysctl_ip_nonlocal_bind))
net/sctp/protocol.c
603
struct net *net = timer_container_of(net, t, sctp.addr_wq_timer);
net/sctp/protocol.c
607
spin_lock_bh(&net->sctp.addr_wq_lock);
net/sctp/protocol.c
609
list_for_each_entry_safe(addrw, temp, &net->sctp.addr_waitq, list) {
net/sctp/protocol.c
611
"entry:%p\n", __func__, &net->sctp.addr_waitq, &addrw->a.sa,
net/sctp/protocol.c
625
if (ipv6_chk_addr(net, in6, NULL, 0) == 0 &&
net/sctp/protocol.c
635
mod_timer(&net->sctp.addr_wq_timer, timeo_val);
net/sctp/protocol.c
640
list_for_each_entry(sp, &net->sctp.auto_asconf_splist, auto_asconf_list) {
net/sctp/protocol.c
658
spin_unlock_bh(&net->sctp.addr_wq_lock);
net/sctp/protocol.c
661
static void sctp_free_addr_wq(struct net *net)
net/sctp/protocol.c
666
timer_shutdown_sync(&net->sctp.addr_wq_timer);
net/sctp/protocol.c
668
spin_lock_bh(&net->sctp.addr_wq_lock);
net/sctp/protocol.c
669
list_for_each_entry_safe(addrw, temp, &net->sctp.addr_waitq, list) {
net/sctp/protocol.c
673
spin_unlock_bh(&net->sctp.addr_wq_lock);
net/sctp/protocol.c
679
static struct sctp_sockaddr_entry *sctp_addr_wq_lookup(struct net *net,
net/sctp/protocol.c
684
list_for_each_entry(addrw, &net->sctp.addr_waitq, list) {
net/sctp/protocol.c
700
void sctp_addr_wq_mgmt(struct net *net, struct sctp_sockaddr_entry *addr, int cmd)
net/sctp/protocol.c
711
spin_lock_bh(&net->sctp.addr_wq_lock);
net/sctp/protocol.c
720
if (list_empty(&net->sctp.auto_asconf_splist) &&
net/sctp/protocol.c
721
list_empty(&net->sctp.addr_waitq)) {
net/sctp/protocol.c
722
spin_unlock_bh(&net->sctp.addr_wq_lock);
net/sctp/protocol.c
727
addrw = sctp_addr_wq_lookup(net, addr);
net/sctp/protocol.c
732
&net->sctp.addr_waitq);
net/sctp/protocol.c
737
spin_unlock_bh(&net->sctp.addr_wq_lock);
net/sctp/protocol.c
744
spin_unlock_bh(&net->sctp.addr_wq_lock);
net/sctp/protocol.c
748
list_add_tail(&addrw->list, &net->sctp.addr_waitq);
net/sctp/protocol.c
751
__func__, addrw->state, &addrw->a.sa, &net->sctp.addr_waitq);
net/sctp/protocol.c
753
if (!timer_pending(&net->sctp.addr_wq_timer)) {
net/sctp/protocol.c
756
mod_timer(&net->sctp.addr_wq_timer, timeo_val);
net/sctp/protocol.c
758
spin_unlock_bh(&net->sctp.addr_wq_lock);
net/sctp/protocol.c
773
struct net *net = dev_net(ifa->ifa_dev->dev);
net/sctp/protocol.c
783
spin_lock_bh(&net->sctp.local_addr_lock);
net/sctp/protocol.c
784
list_add_tail_rcu(&addr->list, &net->sctp.local_addr_list);
net/sctp/protocol.c
785
sctp_addr_wq_mgmt(net, addr, SCTP_ADDR_NEW);
net/sctp/protocol.c
786
spin_unlock_bh(&net->sctp.local_addr_lock);
net/sctp/protocol.c
790
spin_lock_bh(&net->sctp.local_addr_lock);
net/sctp/protocol.c
792
&net->sctp.local_addr_list, list) {
net/sctp/protocol.c
799
sctp_addr_wq_mgmt(net, addr, SCTP_ADDR_DEL);
net/sctp/protocol.c
803
spin_unlock_bh(&net->sctp.local_addr_lock);
net/sctp/protocol.c
816
static int sctp_ctl_sock_init(struct net *net)
net/sctp/protocol.c
824
err = inet_ctl_sock_create(&net->sctp.ctl_sock, family,
net/sctp/protocol.c
825
SOCK_SEQPACKET, IPPROTO_SCTP, net);
net/sctp/protocol.c
829
err = inet_ctl_sock_create(&net->sctp.ctl_sock, AF_INET,
net/sctp/protocol.c
831
net);
net/sctp/protocol.c
849
int sctp_udp_sock_start(struct net *net)
net/sctp/protocol.c
858
udp_conf.local_udp_port = htons(net->sctp.udp_port);
net/sctp/protocol.c
859
err = udp_sock_create(net, &udp_conf, &sock);
net/sctp/protocol.c
868
setup_udp_tunnel_sock(net, sock->sk, &tuncfg);
net/sctp/protocol.c
869
net->sctp.udp4_sock = sock->sk;
net/sctp/protocol.c
876
udp_conf.local_udp_port = htons(net->sctp.udp_port);
net/sctp/protocol.c
879
err = udp_sock_create(net, &udp_conf, &sock);
net/sctp/protocol.c
882
udp_tunnel_sock_release(net->sctp.udp4_sock);
net/sctp/protocol.c
883
net->sctp.udp4_sock = NULL;
net/sctp/protocol.c
890
setup_udp_tunnel_sock(net, sock->sk, &tuncfg);
net/sctp/protocol.c
891
net->sctp.udp6_sock = sock->sk;
net/sctp/protocol.c
897
void sctp_udp_sock_stop(struct net *net)
net/sctp/protocol.c
899
if (net->sctp.udp4_sock) {
net/sctp/protocol.c
900
udp_tunnel_sock_release(net->sctp.udp4_sock);
net/sctp/protocol.c
901
net->sctp.udp4_sock = NULL;
net/sctp/protocol.c
903
if (net->sctp.udp6_sock) {
net/sctp/protocol.c
904
udp_tunnel_sock_release(net->sctp.udp6_sock);
net/sctp/protocol.c
905
net->sctp.udp6_sock = NULL;
net/sctp/sm_make_chunk.c
1993
static int sctp_verify_ext_param(struct net *net,
net/sctp/sm_make_chunk.c
2019
if (net->sctp.addip_noauth)
net/sctp/sm_make_chunk.c
2144
static enum sctp_ierror sctp_verify_param(struct net *net,
net/sctp/sm_make_chunk.c
2175
if (!sctp_verify_ext_param(net, ep, param))
net/sctp/sm_make_chunk.c
2272
int sctp_verify_init(struct net *net, const struct sctp_endpoint *ep,
net/sctp/sm_make_chunk.c
2316
result = sctp_verify_param(net, ep, asoc, param, cid,
net/sctp/sm_make_chunk.c
2400
if (!asoc->base.net->sctp.addip_noauth &&
net/sctp/sm_make_chunk.c
2530
struct net *net = asoc->base.net;
net/sctp/sm_make_chunk.c
2558
if (sctp_in_scope(net, &addr, scope))
net/sctp/sm_make_chunk.c
2564
if (!net->sctp.cookie_preserve_enable)
net/sctp/sm_sideeffect.c
1149
int sctp_do_sm(struct net *net, enum sctp_event_type event_type,
net/sctp/sm_sideeffect.c
1167
state_fn = sctp_sm_lookup_event(net, event_type, state, subtype);
net/sctp/sm_sideeffect.c
1172
status = state_fn->fn(net, ep, asoc, subtype, event_arg, &commands);
net/sctp/sm_sideeffect.c
237
struct net *net = sock_net(sk);
net/sctp/sm_sideeffect.c
253
error = sctp_do_sm(net, SCTP_EVENT_T_TIMEOUT,
net/sctp/sm_sideeffect.c
274
struct net *net = sock_net(sk);
net/sctp/sm_sideeffect.c
295
error = sctp_do_sm(net, SCTP_EVENT_T_TIMEOUT,
net/sctp/sm_sideeffect.c
372
struct net *net = sock_net(sk);
net/sctp/sm_sideeffect.c
396
error = sctp_do_sm(net, SCTP_EVENT_T_TIMEOUT,
net/sctp/sm_sideeffect.c
418
struct net *net = sock_net(sk);
net/sctp/sm_sideeffect.c
437
sctp_do_sm(net, SCTP_EVENT_T_OTHER,
net/sctp/sm_sideeffect.c
453
struct net *net = sock_net(sk);
net/sctp/sm_sideeffect.c
470
error = sctp_do_sm(net, SCTP_EVENT_T_TIMEOUT,
net/sctp/sm_sideeffect.c
490
struct net *net = sock_net(sk);
net/sctp/sm_sideeffect.c
503
error = sctp_do_sm(net, SCTP_EVENT_T_TIMEOUT,
net/sctp/sm_sideeffect.c
587
if (asoc->base.net->sctp.pf_enable &&
net/sctp/sm_sideeffect.c
842
err = sctp_do_sm(asoc->base.net, SCTP_EVENT_T_OTHER,
net/sctp/sm_statefuns.c
103
struct net *net,
net/sctp/sm_statefuns.c
1057
enum sctp_disposition sctp_sf_sendbeat_8_3(struct net *net,
net/sctp/sm_statefuns.c
1072
SCTP_INC_STATS(net, SCTP_MIB_ABORTEDS);
net/sctp/sm_statefuns.c
1073
SCTP_DEC_STATS(net, SCTP_MIB_CURRESTAB);
net/sctp/sm_statefuns.c
110
struct net *net,
net/sctp/sm_statefuns.c
1105
enum sctp_disposition sctp_sf_send_reconf(struct net *net,
net/sctp/sm_statefuns.c
1120
SCTP_INC_STATS(net, SCTP_MIB_ABORTEDS);
net/sctp/sm_statefuns.c
1121
SCTP_DEC_STATS(net, SCTP_MIB_CURRESTAB);
net/sctp/sm_statefuns.c
1134
enum sctp_disposition sctp_sf_send_probe(struct net *net,
net/sctp/sm_statefuns.c
1182
enum sctp_disposition sctp_sf_beat_8_3(struct net *net,
net/sctp/sm_statefuns.c
119
struct net *net,
net/sctp/sm_statefuns.c
1194
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
1199
return sctp_sf_violation_chunklen(net, ep, asoc, type, arg,
net/sctp/sm_statefuns.c
1211
return sctp_sf_violation_paramlen(net, ep, asoc, type, arg,
net/sctp/sm_statefuns.c
1256
enum sctp_disposition sctp_sf_backbeat_8_3(struct net *net,
net/sctp/sm_statefuns.c
127
struct net *net,
net/sctp/sm_statefuns.c
1270
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
1275
return sctp_sf_violation_chunklen(net, ep, asoc, type, arg,
net/sctp/sm_statefuns.c
1314
return sctp_sf_send_probe(net, ep, asoc, type, link, commands);
net/sctp/sm_statefuns.c
1342
static int sctp_sf_send_restart_abort(struct net *net, union sctp_addr *ssa,
net/sctp/sm_statefuns.c
135
struct net *net,
net/sctp/sm_statefuns.c
1368
ep = sctp_sk(net->sctp.ctl_sock)->ep;
net/sctp/sm_statefuns.c
1373
pkt = sctp_abort_pkt_new(net, ep, NULL, init, errhdr, len);
net/sctp/sm_statefuns.c
1379
SCTP_INC_STATS(net, SCTP_MIB_OUTCTRLCHUNKS);
net/sctp/sm_statefuns.c
1411
struct net *net = new_asoc->base.net;
net/sctp/sm_statefuns.c
143
struct net *net,
net/sctp/sm_statefuns.c
1430
sctp_sf_send_restart_abort(net, &new_addr->ipaddr, init,
net/sctp/sm_statefuns.c
1530
struct net *net,
net/sctp/sm_statefuns.c
155
struct net *net,
net/sctp/sm_statefuns.c
1554
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
1558
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
1564
return sctp_sf_tabort_8_4_8(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
1567
return sctp_sf_new_encap_port(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
1578
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
1583
if (!sctp_verify_init(net, ep, asoc, chunk->chunk_hdr->type,
net/sctp/sm_statefuns.c
1590
packet = sctp_abort_pkt_new(net, ep, asoc, arg,
net/sctp/sm_statefuns.c
1599
SCTP_INC_STATS(net, SCTP_MIB_OUTCTRLCHUNKS);
net/sctp/sm_statefuns.c
1606
return sctp_sf_tabort_8_4_8(net, ep, asoc, type, arg,
net/sctp/sm_statefuns.c
1627
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
163
__sctp_sf_do_9_2_reshutack(struct net *net, const struct sctp_endpoint *ep,
net/sctp/sm_statefuns.c
1758
struct net *net,
net/sctp/sm_statefuns.c
1768
return sctp_sf_do_unexpected_init(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
1813
struct net *net,
net/sctp/sm_statefuns.c
1823
return sctp_sf_do_unexpected_init(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
1837
struct net *net,
net/sctp/sm_statefuns.c
1847
if (ep == sctp_sk(net->sctp.ctl_sock)->ep)
net/sctp/sm_statefuns.c
1848
return sctp_sf_ootb(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
1850
return sctp_sf_discard_chunk(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
1857
struct net *net = asoc->base.net;
net/sctp/sm_statefuns.c
1871
SCTP_INC_STATS(net, SCTP_MIB_ABORTEDS);
net/sctp/sm_statefuns.c
1872
SCTP_DEC_STATS(net, SCTP_MIB_CURRESTAB);
net/sctp/sm_statefuns.c
1883
struct net *net,
net/sctp/sm_statefuns.c
1907
if (!sctp_auth_chunk_verify(net, chunk, new_asoc))
net/sctp/sm_statefuns.c
1924
disposition = __sctp_sf_do_9_2_reshutack(net, ep, asoc,
net/sctp/sm_statefuns.c
1981
return sctp_sf_do_9_2_start_shutdown(net, ep, asoc,
net/sctp/sm_statefuns.c
2006
struct net *net,
net/sctp/sm_statefuns.c
2027
if (!sctp_auth_chunk_verify(net, chunk, new_asoc))
net/sctp/sm_statefuns.c
2033
SCTP_INC_STATS(net, SCTP_MIB_CURRESTAB);
net/sctp/sm_statefuns.c
2090
struct net *net,
net/sctp/sm_statefuns.c
2113
struct net *net,
net/sctp/sm_statefuns.c
2130
if (!sctp_auth_chunk_verify(net, chunk, asoc))
net/sctp/sm_statefuns.c
2139
SCTP_INC_STATS(net, SCTP_MIB_CURRESTAB);
net/sctp/sm_statefuns.c
2225
struct net *net,
net/sctp/sm_statefuns.c
2249
return sctp_sf_violation_chunklen(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
2283
sctp_send_stale_cookie_err(net, ep, asoc, chunk, commands,
net/sctp/sm_statefuns.c
2285
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
2288
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
2310
!sctp_verify_init(net, ep, asoc, cid, peer_init, chunk,
net/sctp/sm_statefuns.c
2315
return sctp_sf_pdiscard(net, ep, asoc, type, arg,
net/sctp/sm_statefuns.c
2326
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
2333
retval = sctp_sf_do_dupcook_a(net, ep, asoc, chunk, commands,
net/sctp/sm_statefuns.c
2338
retval = sctp_sf_do_dupcook_b(net, ep, asoc, chunk, commands,
net/sctp/sm_statefuns.c
234
enum sctp_disposition sctp_sf_do_4_C(struct net *net,
net/sctp/sm_statefuns.c
2343
retval = sctp_sf_do_dupcook_c(net, ep, asoc, chunk, commands,
net/sctp/sm_statefuns.c
2348
retval = sctp_sf_do_dupcook_d(net, ep, asoc, chunk, commands,
net/sctp/sm_statefuns.c
2353
retval = sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
2379
struct net *net,
net/sctp/sm_statefuns.c
2389
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
2402
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
2411
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
2414
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
2416
return __sctp_sf_do_9_1_abort(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
2425
struct net *net,
net/sctp/sm_statefuns.c
2435
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
244
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
2448
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
2457
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
2460
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
2470
return __sctp_sf_do_9_1_abort(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
2479
struct net *net,
net/sctp/sm_statefuns.c
2489
return sctp_sf_shutdown_sent_abort(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
2507
struct net *net,
net/sctp/sm_statefuns.c
2518
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
252
return sctp_sf_violation_chunk(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
2524
return sctp_sf_violation_chunklen(net, ep, asoc, type, arg,
net/sctp/sm_statefuns.c
2540
return sctp_sf_do_5_2_6_stale(net, ep, asoc, type,
net/sctp/sm_statefuns.c
2549
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
256
return sctp_sf_violation_chunklen(net, ep, asoc, type, arg,
net/sctp/sm_statefuns.c
2578
struct net *net,
net/sctp/sm_statefuns.c
2695
struct net *net,
net/sctp/sm_statefuns.c
2705
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
2718
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
2727
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
2730
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
2732
return __sctp_sf_do_9_1_abort(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
2736
struct net *net,
net/sctp/sm_statefuns.c
2755
SCTP_INC_STATS(net, SCTP_MIB_ABORTEDS);
net/sctp/sm_statefuns.c
2756
SCTP_DEC_STATS(net, SCTP_MIB_CURRESTAB);
net/sctp/sm_statefuns.c
2767
struct net *net,
net/sctp/sm_statefuns.c
2779
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
2792
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
2799
return sctp_stop_t1_and_abort(net, commands, error, ECONNREFUSED, asoc,
net/sctp/sm_statefuns.c
2807
struct net *net,
net/sctp/sm_statefuns.c
2814
return sctp_stop_t1_and_abort(net, commands, SCTP_ERROR_NO_ERROR,
net/sctp/sm_statefuns.c
2823
struct net *net,
net/sctp/sm_statefuns.c
2833
return sctp_sf_cookie_wait_abort(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
2842
struct net *net,
net/sctp/sm_statefuns.c
2852
SCTP_INC_STATS(net, SCTP_MIB_ABORTEDS);
net/sctp/sm_statefuns.c
289
SCTP_INC_STATS(net, SCTP_MIB_SHUTDOWNS);
net/sctp/sm_statefuns.c
2897
struct net *net,
net/sctp/sm_statefuns.c
290
SCTP_DEC_STATS(net, SCTP_MIB_CURRESTAB);
net/sctp/sm_statefuns.c
2911
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
2915
return sctp_sf_violation_chunklen(net, ep, asoc, type, arg,
net/sctp/sm_statefuns.c
2936
return sctp_sf_violation_ctsn(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
2960
disposition = sctp_sf_do_9_2_shutdown_ack(net, ep, asoc, type,
net/sctp/sm_statefuns.c
2987
struct net *net,
net/sctp/sm_statefuns.c
2999
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
3003
return sctp_sf_violation_chunklen(net, ep, asoc, type, arg,
net/sctp/sm_statefuns.c
3021
return sctp_sf_violation_ctsn(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
3041
__sctp_sf_do_9_2_reshutack(struct net *net, const struct sctp_endpoint *ep,
net/sctp/sm_statefuns.c
3051
return sctp_sf_violation_chunklen(net, ep, asoc, type, arg,
net/sctp/sm_statefuns.c
3079
sctp_sf_do_9_2_reshutack(struct net *net, const struct sctp_endpoint *ep,
net/sctp/sm_statefuns.c
3087
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
3090
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
3093
return sctp_sf_tabort_8_4_8(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
3095
return __sctp_sf_do_9_2_reshutack(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
3123
enum sctp_disposition sctp_sf_do_ecn_cwr(struct net *net,
net/sctp/sm_statefuns.c
3135
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
3138
return sctp_sf_violation_chunklen(net, ep, asoc, type, arg,
net/sctp/sm_statefuns.c
3179
enum sctp_disposition sctp_sf_do_ecne(struct net *net,
net/sctp/sm_statefuns.c
3189
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
319
enum sctp_disposition sctp_sf_do_5_1B_init(struct net *net,
net/sctp/sm_statefuns.c
3192
return sctp_sf_violation_chunklen(net, ep, asoc, type, arg,
net/sctp/sm_statefuns.c
3235
enum sctp_disposition sctp_sf_eat_data_6_2(struct net *net,
net/sctp/sm_statefuns.c
3249
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
3253
return sctp_sf_violation_chunklen(net, ep, asoc, type, arg,
net/sctp/sm_statefuns.c
3262
SCTP_INC_STATS(net, SCTP_MIB_IN_DATA_CHUNK_DISCARDS);
net/sctp/sm_statefuns.c
3266
SCTP_INC_STATS(net, SCTP_MIB_IN_DATA_CHUNK_DISCARDS);
net/sctp/sm_statefuns.c
3271
return sctp_sf_abort_violation(net, ep, asoc, chunk, commands,
net/sctp/sm_statefuns.c
3356
struct net *net,
net/sctp/sm_statefuns.c
3369
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
3373
return sctp_sf_violation_chunklen(net, ep, asoc, type, arg,
net/sctp/sm_statefuns.c
3387
return sctp_sf_abort_violation(net, ep, asoc, chunk, commands,
net/sctp/sm_statefuns.c
342
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
3447
enum sctp_disposition sctp_sf_eat_sack_6_2(struct net *net,
net/sctp/sm_statefuns.c
3459
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
3463
return sctp_sf_violation_chunklen(net, ep, asoc, type, arg,
net/sctp/sm_statefuns.c
3470
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
3479
return sctp_sf_violation_ctsn(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
350
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
3524
struct net *net,
net/sctp/sm_statefuns.c
3535
packet = sctp_ootb_pkt_new(net, asoc, chunk);
net/sctp/sm_statefuns.c
355
if (ep == sctp_sk(net->sctp.ctl_sock)->ep) {
net/sctp/sm_statefuns.c
3559
SCTP_INC_STATS(net, SCTP_MIB_OUTCTRLCHUNKS);
net/sctp/sm_statefuns.c
356
SCTP_INC_STATS(net, SCTP_MIB_OUTOFBLUES);
net/sctp/sm_statefuns.c
3561
sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
357
return sctp_sf_tabort_8_4_8(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
3571
struct net *net,
net/sctp/sm_statefuns.c
3582
packet = sctp_ootb_pkt_new(net, asoc, chunk);
net/sctp/sm_statefuns.c
3599
SCTP_INC_STATS(net, SCTP_MIB_OUTCTRLCHUNKS);
net/sctp/sm_statefuns.c
3601
sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
3613
enum sctp_disposition sctp_sf_operr_notify(struct net *net,
net/sctp/sm_statefuns.c
3624
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
3628
return sctp_sf_violation_chunklen(net, ep, asoc, type, arg,
net/sctp/sm_statefuns.c
3632
return sctp_sf_violation_paramlen(net, ep, asoc, type, arg,
net/sctp/sm_statefuns.c
364
return sctp_sf_tabort_8_4_8(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
3651
enum sctp_disposition sctp_sf_do_9_2_final(struct net *net,
net/sctp/sm_statefuns.c
3663
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
3667
return sctp_sf_violation_chunklen(net, ep, asoc, type, arg,
net/sctp/sm_statefuns.c
3700
SCTP_INC_STATS(net, SCTP_MIB_SHUTDOWNS);
net/sctp/sm_statefuns.c
3701
SCTP_DEC_STATS(net, SCTP_MIB_CURRESTAB);
net/sctp/sm_statefuns.c
373
return sctp_sf_tabort_8_4_8(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
3734
enum sctp_disposition sctp_sf_ootb(struct net *net,
net/sctp/sm_statefuns.c
3748
SCTP_INC_STATS(net, SCTP_MIB_OUTOFBLUES);
net/sctp/sm_statefuns.c
3757
return sctp_sf_violation_chunklen(net, ep, asoc, type, arg,
net/sctp/sm_statefuns.c
3763
return sctp_sf_violation_chunklen(net, ep, asoc, type, arg,
net/sctp/sm_statefuns.c
377
if (!sctp_verify_init(net, ep, asoc, chunk->chunk_hdr->type,
net/sctp/sm_statefuns.c
3778
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
3801
return sctp_sf_shut_8_4_5(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
3803
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
3805
return sctp_sf_tabort_8_4_8(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
3830
struct net *net,
net/sctp/sm_statefuns.c
384
packet = sctp_abort_pkt_new(net, ep, asoc, arg,
net/sctp/sm_statefuns.c
3841
packet = sctp_ootb_pkt_new(net, asoc, chunk);
net/sctp/sm_statefuns.c
3866
SCTP_INC_STATS(net, SCTP_MIB_OUTCTRLCHUNKS);
net/sctp/sm_statefuns.c
3872
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
3886
enum sctp_disposition sctp_sf_do_8_5_1_E_sa(struct net *net,
net/sctp/sm_statefuns.c
3900
return sctp_sf_violation_chunklen(net, ep, asoc, type, arg,
net/sctp/sm_statefuns.c
3908
SCTP_INC_STATS(net, SCTP_MIB_OUTOFBLUES);
net/sctp/sm_statefuns.c
3910
return sctp_sf_shut_8_4_5(net, ep, NULL, type, arg, commands);
net/sctp/sm_statefuns.c
3914
enum sctp_disposition sctp_sf_do_asconf(struct net *net,
net/sctp/sm_statefuns.c
3930
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
3935
return sctp_sf_violation_chunklen(net, ep, asoc, type, arg,
net/sctp/sm_statefuns.c
3945
(!net->sctp.addip_noauth && !chunk->auth))
net/sctp/sm_statefuns.c
3946
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
395
SCTP_INC_STATS(net, SCTP_MIB_OUTCTRLCHUNKS);
net/sctp/sm_statefuns.c
3953
return sctp_sf_violation_paramlen(net, ep, asoc, type, arg,
net/sctp/sm_statefuns.c
401
return sctp_sf_tabort_8_4_8(net, ep, asoc, type, arg,
net/sctp/sm_statefuns.c
4028
struct net *net,
net/sctp/sm_statefuns.c
4047
return sctp_sf_do_prm_asconf(net, ep, asoc, type, asconf, commands);
net/sctp/sm_statefuns.c
4055
enum sctp_disposition sctp_sf_do_asconf_ack(struct net *net,
net/sctp/sm_statefuns.c
4072
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
4078
return sctp_sf_violation_chunklen(net, ep, asoc, type, arg,
net/sctp/sm_statefuns.c
4088
(!net->sctp.addip_noauth && !asconf_ack->auth))
net/sctp/sm_statefuns.c
4089
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
4096
return sctp_sf_violation_paramlen(net, ep, asoc, type, arg,
net/sctp/sm_statefuns.c
4131
SCTP_INC_STATS(net, SCTP_MIB_ABORTEDS);
net/sctp/sm_statefuns.c
4132
SCTP_DEC_STATS(net, SCTP_MIB_CURRESTAB);
net/sctp/sm_statefuns.c
4142
return sctp_send_next_asconf(net, ep,
net/sctp/sm_statefuns.c
4161
SCTP_INC_STATS(net, SCTP_MIB_ABORTEDS);
net/sctp/sm_statefuns.c
4162
SCTP_DEC_STATS(net, SCTP_MIB_CURRESTAB);
net/sctp/sm_statefuns.c
4170
enum sctp_disposition sctp_sf_do_reconf(struct net *net,
net/sctp/sm_statefuns.c
4185
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
4190
return sctp_sf_violation_chunklen(net, ep, asoc, type, arg,
net/sctp/sm_statefuns.c
4194
return sctp_sf_violation_paramlen(net, ep, asoc, type, arg,
net/sctp/sm_statefuns.c
421
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
4247
enum sctp_disposition sctp_sf_eat_fwd_tsn(struct net *net,
net/sctp/sm_statefuns.c
4262
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
4266
return sctp_sf_unk_chunk(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
4270
return sctp_sf_violation_chunklen(net, ep, asoc, type, arg,
net/sctp/sm_statefuns.c
4314
struct net *net,
net/sctp/sm_statefuns.c
4329
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
4333
return sctp_sf_unk_chunk(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
4337
return sctp_sf_violation_chunklen(net, ep, asoc, type, arg,
net/sctp/sm_statefuns.c
4476
enum sctp_disposition sctp_sf_eat_auth(struct net *net,
net/sctp/sm_statefuns.c
4489
return sctp_sf_unk_chunk(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
4494
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
4499
return sctp_sf_violation_chunklen(net, ep, asoc, type, arg,
net/sctp/sm_statefuns.c
4520
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
4523
return sctp_sf_violation_chunklen(net, ep, asoc, type, arg,
net/sctp/sm_statefuns.c
4572
enum sctp_disposition sctp_sf_unk_chunk(struct net *net,
net/sctp/sm_statefuns.c
4586
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
4593
return sctp_sf_violation_chunklen(net, ep, asoc, type, arg,
net/sctp/sm_statefuns.c
4599
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
4613
sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
4652
enum sctp_disposition sctp_sf_discard_chunk(struct net *net,
net/sctp/sm_statefuns.c
4662
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
4669
return sctp_sf_violation_chunklen(net, ep, asoc, type, arg,
net/sctp/sm_statefuns.c
4695
enum sctp_disposition sctp_sf_pdiscard(struct net *net,
net/sctp/sm_statefuns.c
4701
SCTP_INC_STATS(net, SCTP_MIB_IN_PKT_DISCARDS);
net/sctp/sm_statefuns.c
4722
enum sctp_disposition sctp_sf_violation(struct net *net,
net/sctp/sm_statefuns.c
4732
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
4736
return sctp_sf_violation_chunklen(net, ep, asoc, type, arg,
net/sctp/sm_statefuns.c
4746
struct net *net,
net/sctp/sm_statefuns.c
4796
SCTP_INC_STATS(net, SCTP_MIB_OUTCTRLCHUNKS);
net/sctp/sm_statefuns.c
4810
SCTP_DEC_STATS(net, SCTP_MIB_CURRESTAB);
net/sctp/sm_statefuns.c
4813
packet = sctp_ootb_pkt_new(net, asoc, chunk);
net/sctp/sm_statefuns.c
4828
SCTP_INC_STATS(net, SCTP_MIB_OUTCTRLCHUNKS);
net/sctp/sm_statefuns.c
4831
SCTP_INC_STATS(net, SCTP_MIB_ABORTEDS);
net/sctp/sm_statefuns.c
4834
sctp_sf_pdiscard(net, ep, asoc, SCTP_ST_CHUNK(0), arg, commands);
net/sctp/sm_statefuns.c
4863
struct net *net,
net/sctp/sm_statefuns.c
4872
return sctp_sf_abort_violation(net, ep, asoc, arg, commands, err_str,
net/sctp/sm_statefuns.c
4883
struct net *net,
net/sctp/sm_statefuns.c
4903
SCTP_INC_STATS(net, SCTP_MIB_OUTCTRLCHUNKS);
net/sctp/sm_statefuns.c
4909
SCTP_DEC_STATS(net, SCTP_MIB_CURRESTAB);
net/sctp/sm_statefuns.c
4910
SCTP_INC_STATS(net, SCTP_MIB_ABORTEDS);
net/sctp/sm_statefuns.c
4913
sctp_sf_pdiscard(net, ep, asoc, SCTP_ST_CHUNK(0), arg, commands);
net/sctp/sm_statefuns.c
4926
struct net *net,
net/sctp/sm_statefuns.c
4935
return sctp_sf_abort_violation(net, ep, asoc, arg, commands, err_str,
net/sctp/sm_statefuns.c
4946
struct net *net,
net/sctp/sm_statefuns.c
4955
return sctp_sf_abort_violation(net, ep, asoc, arg, commands, err_str,
net/sctp/sm_statefuns.c
5018
enum sctp_disposition sctp_sf_do_prm_asoc(struct net *net,
net/sctp/sm_statefuns.c
5130
enum sctp_disposition sctp_sf_do_prm_send(struct net *net,
net/sctp/sm_statefuns.c
5170
struct net *net,
net/sctp/sm_statefuns.c
5192
disposition = sctp_sf_do_9_2_start_shutdown(net, ep, asoc, type,
net/sctp/sm_statefuns.c
521
enum sctp_disposition sctp_sf_do_5_1C_ack(struct net *net,
net/sctp/sm_statefuns.c
5227
struct net *net,
net/sctp/sm_statefuns.c
5257
SCTP_INC_STATS(net, SCTP_MIB_ABORTEDS);
net/sctp/sm_statefuns.c
5258
SCTP_DEC_STATS(net, SCTP_MIB_CURRESTAB);
net/sctp/sm_statefuns.c
5264
enum sctp_disposition sctp_sf_error_closed(struct net *net,
net/sctp/sm_statefuns.c
5279
struct net *net,
net/sctp/sm_statefuns.c
53
struct net *net,
net/sctp/sm_statefuns.c
5306
struct net *net,
net/sctp/sm_statefuns.c
5319
SCTP_INC_STATS(net, SCTP_MIB_SHUTDOWNS);
net/sctp/sm_statefuns.c
534
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
5341
struct net *net,
net/sctp/sm_statefuns.c
5351
return sctp_sf_cookie_wait_prm_shutdown(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
5369
struct net *net,
net/sctp/sm_statefuns.c
5388
SCTP_INC_STATS(net, SCTP_MIB_ABORTEDS);
net/sctp/sm_statefuns.c
541
return sctp_sf_violation_chunk(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
5418
struct net *net,
net/sctp/sm_statefuns.c
5428
return sctp_sf_cookie_wait_prm_abort(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
5444
struct net *net,
net/sctp/sm_statefuns.c
545
return sctp_sf_violation_chunklen(net, ep, asoc, type, arg,
net/sctp/sm_statefuns.c
5455
return sctp_sf_do_9_1_prm_abort(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
5471
struct net *net,
net/sctp/sm_statefuns.c
5486
return sctp_sf_do_9_1_prm_abort(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
5502
struct net *net,
net/sctp/sm_statefuns.c
5512
return sctp_sf_shutdown_sent_prm_abort(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
552
if (!sctp_verify_init(net, ep, asoc, chunk->chunk_hdr->type,
net/sctp/sm_statefuns.c
5538
struct net *net,
net/sctp/sm_statefuns.c
5570
enum sctp_disposition sctp_sf_do_prm_asconf(struct net *net,
net/sctp/sm_statefuns.c
5587
enum sctp_disposition sctp_sf_do_prm_reconf(struct net *net,
net/sctp/sm_statefuns.c
5606
struct net *net,
net/sctp/sm_statefuns.c
5630
struct net *net,
net/sctp/sm_statefuns.c
564
packet = sctp_abort_pkt_new(net, ep, asoc, arg,
net/sctp/sm_statefuns.c
5662
struct net *net,
net/sctp/sm_statefuns.c
5732
struct net *net,
net/sctp/sm_statefuns.c
575
SCTP_INC_STATS(net, SCTP_MIB_OUTCTRLCHUNKS);
net/sctp/sm_statefuns.c
5751
return sctp_sf_pdiscard(net, ep, asoc, type, arg,
net/sctp/sm_statefuns.c
5757
return sctp_sf_violation_chunklen(net, ep, asoc, type,
net/sctp/sm_statefuns.c
5805
enum sctp_disposition sctp_sf_ignore_other(struct net *net,
net/sctp/sm_statefuns.c
5833
enum sctp_disposition sctp_sf_do_6_3_3_rtx(struct net *net,
net/sctp/sm_statefuns.c
5842
SCTP_INC_STATS(net, SCTP_MIB_T3_RTX_EXPIREDS);
net/sctp/sm_statefuns.c
5864
SCTP_INC_STATS(net, SCTP_MIB_ABORTEDS);
net/sctp/sm_statefuns.c
5865
SCTP_DEC_STATS(net, SCTP_MIB_CURRESTAB);
net/sctp/sm_statefuns.c
592
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
5921
enum sctp_disposition sctp_sf_do_6_2_sack(struct net *net,
net/sctp/sm_statefuns.c
5928
SCTP_INC_STATS(net, SCTP_MIB_DELAY_SACK_EXPIREDS);
net/sctp/sm_statefuns.c
594
SCTP_INC_STATS(net, SCTP_MIB_ABORTEDS);
net/sctp/sm_statefuns.c
595
return sctp_stop_t1_and_abort(net, commands, error, ECONNREFUSED,
net/sctp/sm_statefuns.c
5953
struct net *net,
net/sctp/sm_statefuns.c
5966
SCTP_INC_STATS(net, SCTP_MIB_T1_INIT_EXPIREDS);
net/sctp/sm_statefuns.c
6018
struct net *net,
net/sctp/sm_statefuns.c
6030
SCTP_INC_STATS(net, SCTP_MIB_T1_COOKIE_EXPIREDS);
net/sctp/sm_statefuns.c
6069
struct net *net,
net/sctp/sm_statefuns.c
6080
SCTP_INC_STATS(net, SCTP_MIB_T2_SHUTDOWN_EXPIREDS);
net/sctp/sm_statefuns.c
6090
SCTP_INC_STATS(net, SCTP_MIB_ABORTEDS);
net/sctp/sm_statefuns.c
6091
SCTP_DEC_STATS(net, SCTP_MIB_CURRESTAB);
net/sctp/sm_statefuns.c
6140
struct net *net,
net/sctp/sm_statefuns.c
6150
SCTP_INC_STATS(net, SCTP_MIB_T4_RTO_EXPIREDS);
net/sctp/sm_statefuns.c
6175
SCTP_INC_STATS(net, SCTP_MIB_ABORTEDS);
net/sctp/sm_statefuns.c
6176
SCTP_DEC_STATS(net, SCTP_MIB_CURRESTAB);
net/sctp/sm_statefuns.c
62
struct net *net,
net/sctp/sm_statefuns.c
6212
struct net *net,
net/sctp/sm_statefuns.c
6223
SCTP_INC_STATS(net, SCTP_MIB_T5_SHUTDOWN_GUARD_EXPIREDS);
net/sctp/sm_statefuns.c
6235
SCTP_INC_STATS(net, SCTP_MIB_ABORTEDS);
net/sctp/sm_statefuns.c
6236
SCTP_DEC_STATS(net, SCTP_MIB_CURRESTAB);
net/sctp/sm_statefuns.c
6249
struct net *net,
net/sctp/sm_statefuns.c
6258
SCTP_INC_STATS(net, SCTP_MIB_AUTOCLOSE_EXPIREDS);
net/sctp/sm_statefuns.c
6273
disposition = sctp_sf_do_9_2_start_shutdown(net, ep, asoc, type,
net/sctp/sm_statefuns.c
6292
enum sctp_disposition sctp_sf_not_impl(struct net *net,
net/sctp/sm_statefuns.c
6309
enum sctp_disposition sctp_sf_bug(struct net *net,
net/sctp/sm_statefuns.c
6329
enum sctp_disposition sctp_sf_timer_ignore(struct net *net,
net/sctp/sm_statefuns.c
6374
struct net *net,
net/sctp/sm_statefuns.c
6383
packet = sctp_ootb_pkt_new(net, asoc, chunk);
net/sctp/sm_statefuns.c
640
static bool sctp_auth_chunk_verify(struct net *net, struct sctp_chunk *chunk,
net/sctp/sm_statefuns.c
6416
struct net *net,
net/sctp/sm_statefuns.c
6470
transport = sctp_transport_new(net, sctp_source(chunk), GFP_ATOMIC);
net/sctp/sm_statefuns.c
6480
sctp_sk(net->sctp.ctl_sock));
net/sctp/sm_statefuns.c
6499
static void sctp_send_stale_cookie_err(struct net *net,
net/sctp/sm_statefuns.c
65
static void sctp_send_stale_cookie_err(struct net *net,
net/sctp/sm_statefuns.c
6509
packet = sctp_ootb_pkt_new(net, asoc, chunk);
net/sctp/sm_statefuns.c
6522
SCTP_INC_STATS(net, SCTP_MIB_OUTCTRLCHUNKS);
net/sctp/sm_statefuns.c
6536
struct net *net = sock_net(sk);
net/sctp/sm_statefuns.c
656
if (!net->sctp.auth_enable || !asoc->peer.auth_capable)
net/sctp/sm_statefuns.c
6671
SCTP_INC_STATS(net, SCTP_MIB_ABORTEDS);
net/sctp/sm_statefuns.c
6672
SCTP_DEC_STATS(net, SCTP_MIB_CURRESTAB);
net/sctp/sm_statefuns.c
6682
SCTP_INC_STATS(net, SCTP_MIB_INUNORDERCHUNKS);
net/sctp/sm_statefuns.c
6686
SCTP_INC_STATS(net, SCTP_MIB_INORDERCHUNKS);
net/sctp/sm_statefuns.c
703
enum sctp_disposition sctp_sf_do_5_1D_ce(struct net *net,
net/sctp/sm_statefuns.c
72
struct net *net,
net/sctp/sm_statefuns.c
721
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
726
if (ep == sctp_sk(net->sctp.ctl_sock)->ep) {
net/sctp/sm_statefuns.c
727
SCTP_INC_STATS(net, SCTP_MIB_OUTOFBLUES);
net/sctp/sm_statefuns.c
728
return sctp_sf_tabort_8_4_8(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
737
return sctp_sf_violation_chunklen(net, ep, asoc, type, arg,
net/sctp/sm_statefuns.c
747
return sctp_sf_tabort_8_4_8(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
780
sctp_send_stale_cookie_err(net, ep, asoc, chunk, commands,
net/sctp/sm_statefuns.c
782
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
786
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
793
!sctp_verify_init(net, ep, asoc, cid, peer_init, chunk,
net/sctp/sm_statefuns.c
798
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
80
struct net *net,
net/sctp/sm_statefuns.c
805
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
829
if (!sctp_auth_chunk_verify(net, chunk, new_asoc)) {
net/sctp/sm_statefuns.c
831
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
87
struct net *net,
net/sctp/sm_statefuns.c
879
SCTP_INC_STATS(net, SCTP_MIB_CURRESTAB);
net/sctp/sm_statefuns.c
880
SCTP_INC_STATS(net, SCTP_MIB_PASSIVEESTABS);
net/sctp/sm_statefuns.c
938
enum sctp_disposition sctp_sf_do_5_1E_ca(struct net *net,
net/sctp/sm_statefuns.c
94
struct net *net,
net/sctp/sm_statefuns.c
949
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
954
return sctp_sf_pdiscard(net, ep, asoc, type, arg, commands);
net/sctp/sm_statefuns.c
960
return sctp_sf_violation_chunklen(net, ep, asoc, type, arg,
net/sctp/sm_statefuns.c
981
SCTP_INC_STATS(net, SCTP_MIB_CURRESTAB);
net/sctp/sm_statefuns.c
982
SCTP_INC_STATS(net, SCTP_MIB_ACTIVEESTABS);
net/sctp/sm_statetable.c
1006
struct net *net,
net/sctp/sm_statetable.c
41
struct net *net,
net/sctp/sm_statetable.c
66
struct net *net,
net/sctp/sm_statetable.c
73
return sctp_chunk_event_lookup(net, event_subtype.chunk, state);
net/sctp/socket.c
1075
struct net *net = sock_net(sk);
net/sctp/socket.c
1086
if (inet_port_requires_bind_service(net, ep->base.bind_addr.port) &&
net/sctp/socket.c
1087
!ns_capable(net->user_ns, CAP_NET_BIND_SERVICE))
net/sctp/socket.c
1486
struct net *net = sock_net(sk);
net/sctp/socket.c
1527
sctp_primitive_ABORT(net, asoc, chunk);
net/sctp/socket.c
1529
sctp_primitive_SHUTDOWN(net, asoc, NULL);
net/sctp/socket.c
1544
spin_lock_bh(&net->sctp.addr_wq_lock);
net/sctp/socket.c
1554
spin_unlock_bh(&net->sctp.addr_wq_lock);
net/sctp/socket.c
1756
struct net *net = sock_net(sk);
net/sctp/socket.c
1767
sctp_primitive_SHUTDOWN(net, asoc, NULL);
net/sctp/socket.c
1780
sctp_primitive_ABORT(net, asoc, chunk);
net/sctp/socket.c
1796
struct net *net = sock_net(sk);
net/sctp/socket.c
1840
err = sctp_primitive_ASSOCIATE(net, asoc, NULL);
net/sctp/socket.c
1872
err = sctp_primitive_SEND(net, asoc, datamsg);
net/sctp/socket.c
2281
struct net *net = sock_net(sk);
net/sctp/socket.c
2290
if (sp->autoclose > net->sctp.max_autoclose)
net/sctp/socket.c
2291
sp->autoclose = net->sctp.max_autoclose;
net/sctp/socket.c
2445
error = sctp_primitive_REQUESTHEARTBEAT(trans->asoc->base.net,
net/sctp/socket.c
366
struct net *net = sock_net(&sp->inet.sk);
net/sctp/socket.c
368
if (net->sctp.default_auto_asconf) {
net/sctp/socket.c
369
spin_lock_bh(&net->sctp.addr_wq_lock);
net/sctp/socket.c
370
list_add_tail(&sp->auto_asconf_list, &net->sctp.auto_asconf_splist);
net/sctp/socket.c
371
spin_unlock_bh(&net->sctp.addr_wq_lock);
net/sctp/socket.c
379
struct net *net = sock_net(sk);
net/sctp/socket.c
418
if (snum && inet_port_requires_bind_service(net, snum) &&
net/sctp/socket.c
419
!ns_capable(net->user_ns, CAP_NET_BIND_SERVICE))
net/sctp/socket.c
484
retval = sctp_primitive_ASCONF(asoc->base.net, asoc, chunk);
net/sctp/socket.c
5023
struct net *net = sock_net(sk);
net/sctp/socket.c
5054
sp->max_burst = net->sctp.max_burst;
net/sctp/socket.c
5056
sp->cookie_auth_enable = net->sctp.cookie_auth_enable;
net/sctp/socket.c
5064
sp->initmsg.sinit_max_attempts = net->sctp.max_retrans_init;
net/sctp/socket.c
5065
sp->initmsg.sinit_max_init_timeo = net->sctp.rto_max;
net/sctp/socket.c
5070
sp->rtoinfo.srto_initial = net->sctp.rto_initial;
net/sctp/socket.c
5071
sp->rtoinfo.srto_max = net->sctp.rto_max;
net/sctp/socket.c
5072
sp->rtoinfo.srto_min = net->sctp.rto_min;
net/sctp/socket.c
5077
sp->assocparams.sasoc_asocmaxrxt = net->sctp.max_retrans_association;
net/sctp/socket.c
5081
sp->assocparams.sasoc_cookie_life = net->sctp.valid_cookie_life;
net/sctp/socket.c
5091
sp->hbinterval = net->sctp.hb_interval;
net/sctp/socket.c
5092
sp->udp_port = htons(net->sctp.udp_port);
net/sctp/socket.c
5093
sp->encap_port = htons(net->sctp.encap_port);
net/sctp/socket.c
5094
sp->pathmaxrxt = net->sctp.max_retrans_path;
net/sctp/socket.c
5095
sp->pf_retrans = net->sctp.pf_retrans;
net/sctp/socket.c
5096
sp->ps_retrans = net->sctp.ps_retrans;
net/sctp/socket.c
5097
sp->pf_expose = net->sctp.pf_expose;
net/sctp/socket.c
5099
sp->sackdelay = net->sctp.sack_timeout;
net/sctp/socket.c
5138
sp->probe_interval = net->sctp.probe_interval;
net/sctp/socket.c
5153
sock_prot_inuse_add(net, sk->sk_prot, 1);
net/sctp/socket.c
5210
struct net *net = sock_net(sk);
net/sctp/socket.c
5223
sctp_primitive_SHUTDOWN(net, asoc, NULL);
net/sctp/socket.c
5328
struct sctp_transport *sctp_transport_get_next(struct net *net,
net/sctp/socket.c
5344
if (net_eq(t->asoc->base.net, net) &&
net/sctp/socket.c
5354
struct sctp_transport *sctp_transport_get_idx(struct net *net,
net/sctp/socket.c
5363
while ((t = sctp_transport_get_next(net, iter)) && !IS_ERR(t)) {
net/sctp/socket.c
5373
struct net *net, int *pos, void *p) {
net/sctp/socket.c
5384
if (sock_net(ep->base.sk) != net)
net/sctp/socket.c
5409
int sctp_transport_lookup_process(sctp_callback_t cb, struct net *net,
net/sctp/socket.c
5418
transport = sctp_addrs_lookup_transport(net, laddr, paddr, dif, dif);
net/sctp/socket.c
5439
struct net *net, int *pos, void *p)
net/sctp/socket.c
5450
tsp = sctp_transport_get_idx(net, &hti, *pos + 1);
net/sctp/socket.c
5451
for (; !IS_ERR_OR_NULL(tsp); tsp = sctp_transport_get_next(net, &hti)) {
net/sctp/socket.c
6270
struct net *net = sock_net(sk);
net/sctp/socket.c
6273
list_for_each_entry_rcu(addr, &net->sctp.local_addr_list, list) {
net/sctp/socket.c
8406
struct sctp_bind_hashbucket *head, struct net *, unsigned short snum);
net/sctp/socket.c
8413
struct net *net = sock_net(sk);
net/sctp/socket.c
8436
if (inet_is_local_reserved_port(net, rover))
net/sctp/socket.c
8438
index = sctp_phashfn(net, rover);
net/sctp/socket.c
8443
net_eq(net, pp->net))
net/sctp/socket.c
8468
head = &sctp_port_hashtable[sctp_phashfn(net, snum)];
net/sctp/socket.c
8471
if ((pp->port == snum) && net_eq(pp->net, net))
net/sctp/socket.c
8530
if (!pp && !(pp = sctp_bucket_create(head, net, snum)))
net/sctp/socket.c
8772
struct sctp_bind_hashbucket *head, struct net *net, unsigned short snum)
net/sctp/socket.c
8782
pp->net = net;
net/sctp/stream.c
234
retval = sctp_primitive_RECONF(asoc->base.net, asoc, chunk);
net/sctp/stream_interleave.c
1151
SCTP_INC_STATS(asoc->base.net, SCTP_MIB_OUTCTRLCHUNKS);
net/sctp/stream_interleave.c
244
retval = sctp_make_reassembled_event(ulpq->asoc->base.net, &ulpq->reasm,
net/sctp/stream_interleave.c
328
retval = sctp_make_reassembled_event(asoc->base.net,
net/sctp/stream_interleave.c
339
retval = sctp_make_reassembled_event(asoc->base.net, &ulpq->reasm,
net/sctp/stream_interleave.c
625
retval = sctp_make_reassembled_event(ulpq->asoc->base.net,
net/sctp/stream_interleave.c
711
retval = sctp_make_reassembled_event(asoc->base.net,
net/sctp/stream_interleave.c
722
retval = sctp_make_reassembled_event(asoc->base.net, &ulpq->reasm_uo,
net/sctp/stream_interleave.c
808
retval = sctp_make_reassembled_event(ulpq->asoc->base.net,
net/sctp/stream_interleave.c
915
retval = sctp_make_reassembled_event(ulpq->asoc->base.net,
net/sctp/sysctl.c
390
struct net *net = container_of(ctl->data, struct net,
net/sctp/sysctl.c
405
net->sctp.cookie_auth_enable = 1;
net/sctp/sysctl.c
409
net->sctp.cookie_auth_enable = 0;
net/sctp/sysctl.c
414
if (net->sctp.cookie_auth_enable)
net/sctp/sysctl.c
425
struct net *net = container_of(ctl->data, struct net, sctp.rto_min);
net/sctp/sysctl.c
437
tbl.data = &net->sctp.rto_min;
net/sctp/sysctl.c
444
net->sctp.rto_min = new_value;
net/sctp/sysctl.c
453
struct net *net = container_of(ctl->data, struct net, sctp.rto_max);
net/sctp/sysctl.c
465
tbl.data = &net->sctp.rto_max;
net/sctp/sysctl.c
472
net->sctp.rto_max = new_value;
net/sctp/sysctl.c
491
struct net *net = container_of(ctl->data, struct net, sctp.auth_enable);
net/sctp/sysctl.c
501
tbl.data = &net->sctp.auth_enable;
net/sctp/sysctl.c
505
struct sock *sk = net->sctp.ctl_sock;
net/sctp/sysctl.c
507
net->sctp.auth_enable = new_value;
net/sctp/sysctl.c
522
struct net *net = container_of(ctl->data, struct net, sctp.udp_port);
net/sctp/sysctl.c
534
tbl.data = &net->sctp.udp_port;
net/sctp/sysctl.c
538
struct sock *sk = net->sctp.ctl_sock;
net/sctp/sysctl.c
544
net->sctp.udp_port = new_value;
net/sctp/sysctl.c
545
sctp_udp_sock_stop(net);
net/sctp/sysctl.c
547
ret = sctp_udp_sock_start(net);
net/sctp/sysctl.c
549
net->sctp.udp_port = 0;
net/sctp/sysctl.c
554
sctp_sk(sk)->udp_port = htons(net->sctp.udp_port);
net/sctp/sysctl.c
565
struct net *net = container_of(ctl->data, struct net,
net/sctp/sysctl.c
576
tbl.data = &net->sctp.probe_interval;
net/sctp/sysctl.c
583
net->sctp.probe_interval = new_value;
net/sctp/sysctl.c
589
int sctp_sysctl_net_register(struct net *net)
net/sctp/sysctl.c
600
table[i].data += (char *)(&net->sctp) - (char *)&init_net.sctp;
net/sctp/sysctl.c
602
table[SCTP_RTO_MIN_IDX].extra2 = &net->sctp.rto_max;
net/sctp/sysctl.c
603
table[SCTP_RTO_MAX_IDX].extra1 = &net->sctp.rto_min;
net/sctp/sysctl.c
604
table[SCTP_PF_RETRANS_IDX].extra2 = &net->sctp.ps_retrans;
net/sctp/sysctl.c
605
table[SCTP_PS_RETRANS_IDX].extra1 = &net->sctp.pf_retrans;
net/sctp/sysctl.c
607
net->sctp.sysctl_header = register_net_sysctl_sz(net, "net/sctp",
net/sctp/sysctl.c
609
if (net->sctp.sysctl_header == NULL) {
net/sctp/sysctl.c
616
void sctp_sysctl_net_unregister(struct net *net)
net/sctp/sysctl.c
618
struct ctl_table_header *header = net->sctp.sysctl_header;
net/sctp/sysctl.c
627
net->sctp.sysctl_header = NULL;
net/sctp/transport.c
40
static void sctp_transport_init(struct net *net,
net/sctp/transport.c
488
struct net *net = tp->asoc->base.net;
net/sctp/transport.c
501
rto_beta = READ_ONCE(net->sctp.rto_beta);
net/sctp/transport.c
505
rto_alpha = READ_ONCE(net->sctp.rto_alpha);
net/sctp/transport.c
58
peer->rto = msecs_to_jiffies(net->sctp.rto_initial);
net/sctp/transport.c
68
peer->pathmaxrxt = net->sctp.max_retrans_path;
net/sctp/transport.c
69
peer->pf_retrans = net->sctp.pf_retrans;
net/sctp/transport.c
89
struct sctp_transport *sctp_transport_new(struct net *net,
net/sctp/transport.c
99
sctp_transport_init(net, transport, addr, gfp);
net/sctp/ulpqueue.c
312
struct sctp_ulpevent *sctp_make_reassembled_event(struct net *net,
net/sctp/ulpqueue.c
384
SCTP_INC_STATS(net, SCTP_MIB_REASMUSRMSGS);
net/sctp/ulpqueue.c
483
retval = sctp_make_reassembled_event(asoc->base.net,
net/sctp/ulpqueue.c
493
retval = sctp_make_reassembled_event(ulpq->asoc->base.net,
net/sctp/ulpqueue.c
559
retval = sctp_make_reassembled_event(ulpq->asoc->base.net, &ulpq->reasm,
net/sctp/ulpqueue.c
660
retval = sctp_make_reassembled_event(ulpq->asoc->base.net, &ulpq->reasm,
net/shaper/shaper.c
210
struct net *ns = genl_info_net(info);
net/shaper/shaper.c
241
struct net *ns = genl_info_net(info);
net/smc/af_smc.c
1237
struct net *net = sock_net(&smc->sk);
net/smc/af_smc.c
1247
if (smc_ib_find_route(net, smc->clcsock->sk->sk_rcv_saddr,
net/smc/af_smc.c
1962
struct net *net = sock_net(newsmcsk);
net/smc/af_smc.c
1964
this_cpu_inc(net->smc.smc_stats->srv_hshake_err_cnt);
net/smc/af_smc.c
3351
int smc_create_clcsk(struct net *net, struct sock *sk, int family)
net/smc/af_smc.c
3356
rc = sock_create_kern(net, family, SOCK_STREAM, IPPROTO_TCP,
net/smc/af_smc.c
3371
static int smc_create(struct net *net, struct socket *sock, int protocol,
net/smc/af_smc.c
3389
sk = smc_sock_alloc(net, sock, protocol);
net/smc/af_smc.c
3393
rc = smc_create_clcsk(net, sk, family);
net/smc/af_smc.c
3410
static __net_init int smc_net_init(struct net *net)
net/smc/af_smc.c
3414
rc = smc_sysctl_net_init(net);
net/smc/af_smc.c
3417
return smc_pnet_net_init(net);
net/smc/af_smc.c
3420
static void __net_exit smc_net_exit(struct net *net)
net/smc/af_smc.c
3422
smc_sysctl_net_exit(net);
net/smc/af_smc.c
3423
smc_pnet_net_exit(net);
net/smc/af_smc.c
3426
static __net_init int smc_net_stat_init(struct net *net)
net/smc/af_smc.c
3428
return smc_stats_init(net);
net/smc/af_smc.c
3431
static void __net_exit smc_net_stat_exit(struct net *net)
net/smc/af_smc.c
3433
smc_stats_exit(net);
net/smc/af_smc.c
395
void smc_sk_init(struct net *net, struct sock *sk, int protocol)
net/smc/af_smc.c
402
WRITE_ONCE(sk->sk_sndbuf, 2 * READ_ONCE(net->smc.sysctl_wmem));
net/smc/af_smc.c
403
WRITE_ONCE(sk->sk_rcvbuf, 2 * READ_ONCE(net->smc.sysctl_rmem));
net/smc/af_smc.c
415
smc->limit_smc_hs = net->smc.limit_smc_hs;
net/smc/af_smc.c
421
static struct sock *smc_sock_alloc(struct net *net, struct socket *sock,
net/smc/af_smc.c
428
sk = sk_alloc(net, PF_SMC, GFP_KERNEL, prot, 0);
net/smc/af_smc.c
433
smc_sk_init(net, sk, protocol);
net/smc/af_smc.c
793
struct net *net = sock_net(&smc->sk);
net/smc/af_smc.c
795
mutex_lock(&net->smc.mutex_fback_rsn);
net/smc/af_smc.c
797
smc_stat_inc_fback_rsn_cnt(smc, net->smc.fback_rsn->srv);
net/smc/af_smc.c
798
net->smc.fback_rsn->srv_fback_cnt++;
net/smc/af_smc.c
800
smc_stat_inc_fback_rsn_cnt(smc, net->smc.fback_rsn->clnt);
net/smc/af_smc.c
801
net->smc.fback_rsn->clnt_fback_cnt++;
net/smc/af_smc.c
803
mutex_unlock(&net->smc.mutex_fback_rsn);
net/smc/af_smc.c
966
struct net *net = sock_net(&smc->sk);
net/smc/af_smc.c
971
this_cpu_inc(net->smc.smc_stats->clnt_hshake_err_cnt);
net/smc/af_smc.c
987
struct net *net = sock_net(&smc->sk);
net/smc/af_smc.c
991
this_cpu_inc(net->smc.smc_stats->clnt_hshake_err_cnt);
net/smc/af_smc.c
999
this_cpu_inc(net->smc.smc_stats->clnt_hshake_err_cnt);
net/smc/smc.h
386
static inline void hton24(u8 *net, u32 host)
net/smc/smc.h
391
memcpy(net, ((u8 *)&t) + 1, 3);
net/smc/smc.h
395
static inline u32 ntoh24(u8 *net)
net/smc/smc.h
399
memcpy(((u8 *)&t) + 1, net, 3);
net/smc/smc.h
71
void smc_sk_init(struct net *net, struct sock *sk, int protocol);
net/smc/smc.h
73
int smc_create_clcsk(struct net *net, struct sock *sk, int family);
net/smc/smc_cdc.h
227
union smc_cdc_cursor net;
net/smc/smc_cdc.h
230
smc_curs_copy_net(&net, peer, conn);
net/smc/smc_cdc.h
231
temp.count = ntohl(net.count);
net/smc/smc_cdc.h
232
temp.wrap = ntohs(net.wrap);
net/smc/smc_clc.c
1259
struct net *net = sock_net(&smc->sk);
net/smc/smc_clc.c
1275
net->smc.sysctl_max_conns_per_lgr);
net/smc/smc_clc.c
1280
net->smc.sysctl_max_links_per_lgr);
net/smc/smc_clc.c
854
struct net *net = sock_net(&smc->sk);
net/smc/smc_clc.c
993
v2_ext->max_conns = net->smc.sysctl_max_conns_per_lgr;
net/smc/smc_clc.c
994
v2_ext->max_links = net->smc.sysctl_max_links_per_lgr;
net/smc/smc_core.c
1732
lgr->net->net_cookie, lgr_type, lgr->pnet_id);
net/smc/smc_core.c
1769
!rdma_dev_access_netns(smcibdev->ibdev, lgr->net))
net/smc/smc_core.c
1934
struct net *net)
net/smc/smc_core.c
1949
if (!rdma_dev_access_netns(lnk->smcibdev->ibdev, net))
net/smc/smc_core.c
1979
struct net *net = sock_net(&smc->sk);
net/smc/smc_core.c
2006
ini->ib_clcqpn, net)) &&
net/smc/smc_core.c
389
lgr->net->net_cookie, SMC_NLA_LGR_R_PAD))
net/smc/smc_core.c
990
lgr->net = smc_ib_net(lnk->smcibdev);
net/smc/smc_core.c
993
lgr->buf_type = lgr->net->smc.sysctl_smcr_buf_type;
net/smc/smc_core.h
368
struct net *net;
net/smc/smc_diag.c
200
struct net *net = sock_net(skb->sk);
net/smc/smc_diag.c
213
if (!net_eq(sock_net(sk), net))
net/smc/smc_diag.c
242
struct net *net = sock_net(skb->sk);
net/smc/smc_diag.c
251
return netlink_dump_start(net->diag_nlsk, skb, h, &c);
net/smc/smc_ib.c
196
int smc_ib_find_route(struct net *net, __be32 saddr, __be32 daddr,
net/smc/smc_ib.c
208
rt = ip_route_output_flow(net, &fl4, NULL);
net/smc/smc_ib.c
243
struct net *net = dev_net(ndev);
net/smc/smc_ib.c
257
if (smcrv2->daddr && smc_ib_find_route(net, smcrv2->saddr,
net/smc/smc_ib.h
115
int smc_ib_find_route(struct net *net, __be32 saddr, __be32 daddr,
net/smc/smc_ib.h
72
static inline struct net *smc_ib_net(struct smc_ib_device *smcibdev)
net/smc/smc_inet.c
111
struct net *net = sock_net(sk);
net/smc/smc_inet.c
114
smc_sk_init(net, sk, IPPROTO_SMC);
net/smc/smc_inet.c
116
return smc_create_clcsk(net, sk, sk->sk_family);
net/smc/smc_llc.c
1857
lgr->net->net_cookie, type);
net/smc/smc_llc.c
2148
struct net *net = sock_net(smc->clcsock->sk);
net/smc/smc_llc.c
2159
lgr->llc_testlink_time = READ_ONCE(net->smc.sysctl_smcr_testlink_time);
net/smc/smc_llc.c
2160
lgr->max_send_wr = (u16)(READ_ONCE(net->smc.sysctl_smcr_max_send_wr));
net/smc/smc_llc.c
2161
lgr->max_recv_wr = (u16)(READ_ONCE(net->smc.sysctl_smcr_max_recv_wr));
net/smc/smc_llc.c
2191
link->lgr->net->net_cookie,
net/smc/smc_llc.c
2210
link->lgr->net->net_cookie,
net/smc/smc_llc.c
247
lgr->net->net_cookie,
net/smc/smc_llc.c
364
SMC_LGR_ID_SIZE, &lgr->id, lgr->net->net_cookie,
net/smc/smc_pnet.c
1001
struct net *net)
net/smc/smc_pnet.c
1009
!rdma_dev_access_netns(ibdev->ibdev, net))
net/smc/smc_pnet.c
101
static int smc_pnet_remove_by_pnetid(struct net *net, char *pnet_name)
net/smc/smc_pnet.c
1031
struct net *net = lgr->net;
net/smc/smc_pnet.c
1033
_smc_pnet_find_roce_by_pnetid(lgr->pnet_id, ini, known_dev, net);
net/smc/smc_pnet.c
1042
struct net *net = dev_net(netdev);
net/smc/smc_pnet.c
1051
if (!rdma_dev_access_netns(ibdev->ibdev, net))
net/smc/smc_pnet.c
1083
struct net *net;
net/smc/smc_pnet.c
1086
net = dev_net(ndev);
net/smc/smc_pnet.c
1094
_smc_pnet_find_roce_by_pnetid(ndev_pnetid, ini, NULL, net);
net/smc/smc_pnet.c
112
sn = net_generic(net, smc_net_id);
net/smc/smc_pnet.c
138
if (net != &init_net)
net/smc/smc_pnet.c
189
struct net *net = dev_net(ndev);
net/smc/smc_pnet.c
194
sn = net_generic(net, smc_net_id);
net/smc/smc_pnet.c
221
struct net *net = dev_net(ndev);
net/smc/smc_pnet.c
226
sn = net_generic(net, smc_net_id);
net/smc/smc_pnet.c
348
static int smc_pnet_add_eth(struct smc_pnettable *pnettable, struct net *net,
net/smc/smc_pnet.c
361
ndev = dev_get_by_name(net, eth_name); /* dev_hold() */
net/smc/smc_pnet.c
477
static int smc_pnet_enter(struct net *net, struct nlattr *tb[])
net/smc/smc_pnet.c
489
sn = net_generic(net, smc_net_id);
net/smc/smc_pnet.c
501
rc = smc_pnet_add_eth(pnettable, net, string, pnet_name);
net/smc/smc_pnet.c
509
if (net != &init_net)
net/smc/smc_pnet.c
562
struct net *net = genl_info_net(info);
net/smc/smc_pnet.c
564
return smc_pnet_enter(net, info->attrs);
net/smc/smc_pnet.c
569
struct net *net = genl_info_net(info);
net/smc/smc_pnet.c
573
return smc_pnet_remove_by_pnetid(net,
net/smc/smc_pnet.c
601
static int _smc_pnet_dump(struct net *net, struct sk_buff *skb, u32 portid,
net/smc/smc_pnet.c
610
sn = net_generic(net, smc_net_id);
net/smc/smc_pnet.c
621
if (net != &init_net && pnetelem->type != SMC_PNET_ETH)
net/smc/smc_pnet.c
635
struct net *net = sock_net(skb->sk);
net/smc/smc_pnet.c
638
idx = _smc_pnet_dump(net, skb, NETLINK_CB(cb->skb).portid,
net/smc/smc_pnet.c
648
struct net *net = genl_info_net(info);
net/smc/smc_pnet.c
659
_smc_pnet_dump(net, msg, info->snd_portid, info->snd_seq,
net/smc/smc_pnet.c
676
struct net *net = genl_info_net(info);
net/smc/smc_pnet.c
678
smc_pnet_remove_by_pnetid(net, NULL);
net/smc/smc_pnet.c
726
bool smc_pnet_is_ndev_pnetid(struct net *net, u8 *pnetid)
net/smc/smc_pnet.c
728
struct smc_net *sn = net_generic(net, smc_net_id);
net/smc/smc_pnet.c
745
static int smc_pnet_add_pnetid(struct net *net, u8 *pnetid)
net/smc/smc_pnet.c
747
struct smc_net *sn = net_generic(net, smc_net_id);
net/smc/smc_pnet.c
771
static void smc_pnet_remove_pnetid(struct net *net, u8 *pnetid)
net/smc/smc_pnet.c
773
struct smc_net *sn = net_generic(net, smc_net_id);
net/smc/smc_pnet.c
789
static void smc_pnet_add_base_pnetid(struct net *net, struct net_device *dev,
net/smc/smc_pnet.c
799
smc_pnet_add_pnetid(net, ndev_pnetid);
net/smc/smc_pnet.c
804
static void smc_pnet_create_pnetids_list(struct net *net)
net/smc/smc_pnet.c
812
if (list_empty(&net->dev_base_head))
net/smc/smc_pnet.c
820
for_each_netdev(net, dev)
net/smc/smc_pnet.c
821
smc_pnet_add_base_pnetid(net, dev, ndev_pnetid);
net/smc/smc_pnet.c
826
static void smc_pnet_destroy_pnetids_list(struct net *net)
net/smc/smc_pnet.c
828
struct smc_net *sn = net_generic(net, smc_net_id);
net/smc/smc_pnet.c
843
struct net *net = dev_net(event_dev);
net/smc/smc_pnet.c
857
smc_pnet_add_base_pnetid(net, event_dev, ndev_pnetid);
net/smc/smc_pnet.c
864
smc_pnet_remove_pnetid(net, ndev_pnetid);
net/smc/smc_pnet.c
877
int smc_pnet_net_init(struct net *net)
net/smc/smc_pnet.c
879
struct smc_net *sn = net_generic(net, smc_net_id);
net/smc/smc_pnet.c
888
smc_pnet_create_pnetids_list(net);
net/smc/smc_pnet.c
908
void smc_pnet_net_exit(struct net *net)
net/smc/smc_pnet.c
911
smc_pnet_remove_by_pnetid(net, NULL);
net/smc/smc_pnet.c
912
smc_pnet_destroy_pnetids_list(net);
net/smc/smc_pnet.c
955
struct net *net = dev_net(ndev);
net/smc/smc_pnet.c
961
sn = net_generic(net, smc_net_id);
net/smc/smc_pnet.h
58
int smc_pnet_net_init(struct net *net);
net/smc/smc_pnet.h
60
void smc_pnet_net_exit(struct net *net);
net/smc/smc_pnet.h
68
bool smc_pnet_is_ndev_pnetid(struct net *net, u8 *pnetid);
net/smc/smc_stats.c
21
int smc_stats_init(struct net *net)
net/smc/smc_stats.c
23
net->smc.fback_rsn = kzalloc_obj(*net->smc.fback_rsn);
net/smc/smc_stats.c
24
if (!net->smc.fback_rsn)
net/smc/smc_stats.c
26
net->smc.smc_stats = alloc_percpu(struct smc_stats);
net/smc/smc_stats.c
269
struct net *net = sock_net(skb->sk);
net/smc/smc_stats.c
27
if (!net->smc.smc_stats)
net/smc/smc_stats.c
29
mutex_init(&net->smc.mutex_fback_rsn);
net/smc/smc_stats.c
293
src = (u64 *)per_cpu_ptr(net->smc.smc_stats, cpu);
net/smc/smc_stats.c
33
kfree(net->smc.fback_rsn);
net/smc/smc_stats.c
332
struct net *net = sock_net(skb->sk);
net/smc/smc_stats.c
340
trgt_arr = &net->smc.fback_rsn->srv[0];
net/smc/smc_stats.c
342
trgt_arr = &net->smc.fback_rsn->clnt[0];
net/smc/smc_stats.c
357
net->smc.fback_rsn->srv_fback_cnt,
net/smc/smc_stats.c
361
net->smc.fback_rsn->clnt_fback_cnt,
net/smc/smc_stats.c
38
void smc_stats_exit(struct net *net)
net/smc/smc_stats.c
390
struct net *net = sock_net(skb->sk);
net/smc/smc_stats.c
396
mutex_lock(&net->smc.mutex_fback_rsn);
net/smc/smc_stats.c
40
kfree(net->smc.fback_rsn);
net/smc/smc_stats.c
41
if (net->smc.smc_stats)
net/smc/smc_stats.c
415
mutex_unlock(&net->smc.mutex_fback_rsn);
net/smc/smc_stats.c
42
free_percpu(net->smc.smc_stats);
net/smc/smc_stats.h
113
struct net *_net = sock_net(&__smc->sk); \
net/smc/smc_stats.h
128
struct net *_net = sock_net(&__smc->sk); \
net/smc/smc_stats.h
166
struct net *_net = sock_net(&(_smc)->sk); \
net/smc/smc_stats.h
185
struct net *net = sock_net(&(_smc)->sk); \
net/smc/smc_stats.h
186
struct smc_stats __percpu *_smc_stats = net->smc.smc_stats; \
net/smc/smc_stats.h
231
struct net *net = sock_net(&(__smc)->sk); \
net/smc/smc_stats.h
232
struct smc_stats __percpu *smc_stats = net->smc.smc_stats; \
net/smc/smc_stats.h
240
#define SMC_STAT_CLNT_SUCC_INC(net, _aclc) \
net/smc/smc_stats.h
245
struct smc_stats __percpu *smc_stats = (net)->smc.smc_stats; \
net/smc/smc_stats.h
257
#define SMC_STAT_SERV_SUCC_INC(net, _ini) \
net/smc/smc_stats.h
263
typeof(net->smc.smc_stats) smc_stats = (net)->smc.smc_stats; \
net/smc/smc_stats.h
277
int smc_stats_init(struct net *net);
net/smc/smc_stats.h
278
void smc_stats_exit(struct net *net);
net/smc/smc_sysctl.c
198
int __net_init smc_sysctl_net_init(struct net *net)
net/smc/smc_sysctl.c
204
if (!net_eq(net, &init_net)) {
net/smc/smc_sysctl.c
213
rcu_assign_pointer(net->smc.hs_ctrl, ctrl);
net/smc/smc_sysctl.c
222
table[i].data += (void *)net - (void *)&init_net;
net/smc/smc_sysctl.c
225
net->smc.smc_hdr = register_net_sysctl_sz(net, "net/smc", table,
net/smc/smc_sysctl.c
227
if (!net->smc.smc_hdr)
net/smc/smc_sysctl.c
230
net->smc.sysctl_autocorking_size = SMC_AUTOCORKING_DEFAULT_SIZE;
net/smc/smc_sysctl.c
231
net->smc.sysctl_smcr_buf_type = SMCR_PHYS_CONT_BUFS;
net/smc/smc_sysctl.c
232
net->smc.sysctl_smcr_testlink_time = SMC_LLC_TESTLINK_DEFAULT_TIME;
net/smc/smc_sysctl.c
233
WRITE_ONCE(net->smc.sysctl_wmem, net_smc_wmem_init);
net/smc/smc_sysctl.c
234
WRITE_ONCE(net->smc.sysctl_rmem, net_smc_rmem_init);
net/smc/smc_sysctl.c
235
net->smc.sysctl_max_links_per_lgr = SMC_LINKS_PER_LGR_MAX_PREFER;
net/smc/smc_sysctl.c
236
net->smc.sysctl_max_conns_per_lgr = SMC_CONN_PER_LGR_PREFER;
net/smc/smc_sysctl.c
237
net->smc.sysctl_smcr_max_send_wr = SMCR_MAX_SEND_WR_DEF;
net/smc/smc_sysctl.c
238
net->smc.sysctl_smcr_max_recv_wr = SMCR_MAX_RECV_WR_DEF;
net/smc/smc_sysctl.c
240
net->smc.limit_smc_hs = 0;
net/smc/smc_sysctl.c
245
if (!net_eq(net, &init_net))
net/smc/smc_sysctl.c
249
smc_net_replace_smc_hs_ctrl(net, NULL);
net/smc/smc_sysctl.c
254
void __net_exit smc_sysctl_net_exit(struct net *net)
net/smc/smc_sysctl.c
258
table = net->smc.smc_hdr->ctl_table_arg;
net/smc/smc_sysctl.c
259
unregister_net_sysctl_table(net->smc.smc_hdr);
net/smc/smc_sysctl.c
261
smc_net_replace_smc_hs_ctrl(net, NULL);
net/smc/smc_sysctl.c
264
if (!net_eq(net, &init_net))
net/smc/smc_sysctl.c
38
static int smc_net_replace_smc_hs_ctrl(struct net *net, const char *name)
net/smc/smc_sysctl.c
51
if (ctrl == rcu_dereference(net->smc.hs_ctrl)) {
net/smc/smc_sysctl.c
61
ctrl = unrcu_pointer(xchg(&net->smc.hs_ctrl, RCU_INITIALIZER(ctrl)));
net/smc/smc_sysctl.c
73
struct net *net = container_of(ctl->data, struct net, smc.hs_ctrl);
net/smc/smc_sysctl.c
83
ctrl = rcu_dereference(net->smc.hs_ctrl);
net/smc/smc_sysctl.c
95
ret = smc_net_replace_smc_hs_ctrl(net, val);
net/smc/smc_sysctl.h
18
int __net_init smc_sysctl_net_init(struct net *net);
net/smc/smc_sysctl.h
19
void __net_exit smc_sysctl_net_exit(struct net *net);
net/smc/smc_sysctl.h
23
static inline int smc_sysctl_net_init(struct net *net)
net/smc/smc_sysctl.h
25
net->smc.sysctl_autocorking_size = SMC_AUTOCORKING_DEFAULT_SIZE;
net/smc/smc_sysctl.h
26
net->smc.sysctl_max_links_per_lgr = SMC_LINKS_PER_LGR_MAX_PREFER;
net/smc/smc_sysctl.h
27
net->smc.sysctl_max_conns_per_lgr = SMC_CONN_PER_LGR_PREFER;
net/smc/smc_sysctl.h
28
net->smc.sysctl_smcr_max_send_wr = SMCR_MAX_SEND_WR_DEF;
net/smc/smc_sysctl.h
29
net->smc.sysctl_smcr_max_recv_wr = SMCR_MAX_RECV_WR_DEF;
net/smc/smc_sysctl.h
33
static inline void smc_sysctl_net_exit(struct net *net) { }
net/smc/smc_tracepoint.h
105
__entry->net_cookie = lgr->net->net_cookie;
net/socket.c
1252
static int (*br_ioctl_hook)(struct net *net, unsigned int cmd,
net/socket.c
1255
void brioctl_set(int (*hook)(struct net *net, unsigned int cmd,
net/socket.c
1264
int br_ioctl_call(struct net *net, unsigned int cmd, void __user *uarg)
net/socket.c
1273
err = br_ioctl_hook(net, cmd, uarg);
net/socket.c
1280
static int (*vlan_ioctl_hook) (struct net *, void __user *arg);
net/socket.c
1282
void vlan_ioctl_set(int (*hook) (struct net *, void __user *))
net/socket.c
1290
static long sock_do_ioctl(struct net *net, struct socket *sock,
net/socket.c
1314
err = dev_ioctl(net, cmd, &ifr, data, &need_copyout);
net/socket.c
1334
struct net *net;
net/socket.c
1339
net = sock_net(sk);
net/socket.c
1346
err = dev_ioctl(net, cmd, &ifr, data, &need_copyout);
net/socket.c
1353
err = wext_handle_ioctl(net, cmd, argp);
net/socket.c
1375
err = br_ioctl_call(net, cmd, argp);
net/socket.c
1385
err = vlan_ioctl_hook(net, argp);
net/socket.c
1390
if (!ns_capable(net->user_ns, CAP_NET_ADMIN))
net/socket.c
1393
err = open_related_ns(&net->ns, get_net_ns);
net/socket.c
1417
err = dev_ifconf(net, argp);
net/socket.c
1421
err = sock_do_ioctl(net, sock, cmd, arg);
net/socket.c
1580
int __sock_create(struct net *net, int family, int type, int protocol,
net/socket.c
1651
err = pf->create(net, sock, protocol, kern);
net/socket.c
1725
int sock_create_kern(struct net *net, int family, int type, int protocol, struct socket **res)
net/socket.c
1727
return __sock_create(net, family, type, protocol, res, 1);
net/socket.c
3467
static int compat_siocwandev(struct net *net, struct compat_ifreq __user *uifr32)
net/socket.c
3483
err = dev_ioctl(net, SIOCWANDEV, &ifr, NULL, NULL);
net/socket.c
3493
static int compat_ifr_data_ioctl(struct net *net, unsigned int cmd,
net/socket.c
3505
return dev_ioctl(net, cmd, &ifreq, data, NULL);
net/socket.c
3513
struct net *net = sock_net(sk);
net/socket.c
3521
return compat_siocwandev(net, argp);
net/socket.c
3535
return compat_ifr_data_ioctl(net, cmd, argp);
net/socket.c
3599
return sock_do_ioctl(net, sock, cmd, arg);
net/socket.c
3612
struct net *net;
net/socket.c
3615
net = sock_net(sk);
net/socket.c
3622
ret = compat_wext_handle_ioctl(net, cmd, arg);
net/sunrpc/addr.c
161
static int rpc_parse_scope_id(struct net *net, const char *buf,
net/sunrpc/addr.c
186
dev = dev_get_by_name(net, p);
net/sunrpc/addr.c
199
static size_t rpc_pton6(struct net *net, const char *buf, const size_t buflen,
net/sunrpc/addr.c
215
if (!rpc_parse_scope_id(net, buf, buflen, delim, sin6))
net/sunrpc/addr.c
222
static size_t rpc_pton6(struct net *net, const char *buf, const size_t buflen,
net/sunrpc/addr.c
244
size_t rpc_pton(struct net *net, const char *buf, const size_t buflen,
net/sunrpc/addr.c
251
return rpc_pton6(net, buf, buflen, sap, salen);
net/sunrpc/addr.c
310
size_t rpc_uaddr2sockaddr(struct net *net, const char *uaddr,
net/sunrpc/addr.c
340
if (rpc_pton(net, buf, strlen(buf), sap, salen) == 0)
net/sunrpc/auth_gss/auth_gss.c
1042
gss_auth->net = get_net_track(rpc_net_ns(clnt), &gss_auth->ns_tracker,
net/sunrpc/auth_gss/auth_gss.c
1051
if (!gssd_running(gss_auth->net))
net/sunrpc/auth_gss/auth_gss.c
1099
put_net_track(gss_auth->net, &gss_auth->ns_tracker);
net/sunrpc/auth_gss/auth_gss.c
1115
put_net_track(gss_auth->net, &gss_auth->ns_tracker);
net/sunrpc/auth_gss/auth_gss.c
2240
static __net_init int rpcsec_gss_init_net(struct net *net)
net/sunrpc/auth_gss/auth_gss.c
2242
return gss_svc_init_net(net);
net/sunrpc/auth_gss/auth_gss.c
2245
static __net_exit void rpcsec_gss_exit_net(struct net *net)
net/sunrpc/auth_gss/auth_gss.c
2247
gss_svc_shutdown_net(net);
net/sunrpc/auth_gss/auth_gss.c
275
static int get_pipe_version(struct net *net)
net/sunrpc/auth_gss/auth_gss.c
277
struct sunrpc_net *sn = net_generic(net, sunrpc_net_id);
net/sunrpc/auth_gss/auth_gss.c
290
static void put_pipe_version(struct net *net)
net/sunrpc/auth_gss/auth_gss.c
292
struct sunrpc_net *sn = net_generic(net, sunrpc_net_id);
net/sunrpc/auth_gss/auth_gss.c
303
struct net *net = gss_msg->auth->net;
net/sunrpc/auth_gss/auth_gss.c
306
put_pipe_version(net);
net/sunrpc/auth_gss/auth_gss.c
535
vers = get_pipe_version(gss_auth->net);
net/sunrpc/auth_gss/auth_gss.c
557
put_pipe_version(gss_auth->net);
net/sunrpc/auth_gss/auth_gss.c
646
struct net *net = gss_auth->net;
net/sunrpc/auth_gss/auth_gss.c
647
struct sunrpc_net *sn = net_generic(net, sunrpc_net_id);
net/sunrpc/auth_gss/auth_gss.c
657
if (!gssd_running(net)) {
net/sunrpc/auth_gss/auth_gss.c
817
struct net *net = inode->i_sb->s_fs_info;
net/sunrpc/auth_gss/auth_gss.c
818
struct sunrpc_net *sn = net_generic(net, sunrpc_net_id);
net/sunrpc/auth_gss/auth_gss.c
852
struct net *net = inode->i_sb->s_fs_info;
net/sunrpc/auth_gss/auth_gss.c
871
put_pipe_version(net);
net/sunrpc/auth_gss/auth_gss.c
93
struct net *net;
net/sunrpc/auth_gss/auth_gss.c
974
struct net *net = rpc_net_ns(clnt);
net/sunrpc/auth_gss/auth_gss.c
982
pdo = rpc_find_or_alloc_pipe_dir_object(net,
net/sunrpc/auth_gss/auth_gss.c
995
struct net *net = rpc_net_ns(clnt);
net/sunrpc/auth_gss/auth_gss.c
997
rpc_remove_pipe_dir_object(net,
net/sunrpc/auth_gss/gss_rpc_upcall.c
130
int set_gssp_clnt(struct net *net)
net/sunrpc/auth_gss/gss_rpc_upcall.c
132
struct sunrpc_net *sn = net_generic(net, sunrpc_net_id);
net/sunrpc/auth_gss/gss_rpc_upcall.c
137
ret = gssp_rpc_create(net, &clnt);
net/sunrpc/auth_gss/gss_rpc_upcall.c
169
static int gssp_call(struct net *net, struct rpc_message *msg)
net/sunrpc/auth_gss/gss_rpc_upcall.c
171
struct sunrpc_net *sn = net_generic(net, sunrpc_net_id);
net/sunrpc/auth_gss/gss_rpc_upcall.c
271
int gssp_accept_sec_context_upcall(struct net *net,
net/sunrpc/auth_gss/gss_rpc_upcall.c
312
ret = gssp_call(net, &msg);
net/sunrpc/auth_gss/gss_rpc_upcall.c
79
static int gssp_rpc_create(struct net *net, struct rpc_clnt **_clnt)
net/sunrpc/auth_gss/gss_rpc_upcall.c
86
.net = net,
net/sunrpc/auth_gss/gss_rpc_upcall.h
28
int gssp_accept_sec_context_upcall(struct net *net,
net/sunrpc/auth_gss/gss_rpc_upcall.h
33
int set_gssp_clnt(struct net *);
net/sunrpc/auth_gss/svcauth_gss.c
1299
struct net *net = SVC_NET(rqstp);
net/sunrpc/auth_gss/svcauth_gss.c
1300
struct sunrpc_net *sn = net_generic(net, sunrpc_net_id);
net/sunrpc/auth_gss/svcauth_gss.c
1310
status = gssp_accept_sec_context_upcall(net, &ud);
net/sunrpc/auth_gss/svcauth_gss.c
1353
static int set_gss_proxy(struct net *net, int type)
net/sunrpc/auth_gss/svcauth_gss.c
1355
struct sunrpc_net *sn = net_generic(net, sunrpc_net_id);
net/sunrpc/auth_gss/svcauth_gss.c
1365
static bool use_gss_proxy(struct net *net)
net/sunrpc/auth_gss/svcauth_gss.c
1367
struct sunrpc_net *sn = net_generic(net, sunrpc_net_id);
net/sunrpc/auth_gss/svcauth_gss.c
1371
set_gss_proxy(net, 0);
net/sunrpc/auth_gss/svcauth_gss.c
1405
struct net *net = pde_data(file_inode(file));
net/sunrpc/auth_gss/svcauth_gss.c
1421
res = set_gssp_clnt(net);
net/sunrpc/auth_gss/svcauth_gss.c
1424
res = set_gss_proxy(net, 1);
net/sunrpc/auth_gss/svcauth_gss.c
1433
struct net *net = pde_data(file_inode(file));
net/sunrpc/auth_gss/svcauth_gss.c
1434
struct sunrpc_net *sn = net_generic(net, sunrpc_net_id);
net/sunrpc/auth_gss/svcauth_gss.c
1458
static int create_use_gss_proxy_proc_entry(struct net *net)
net/sunrpc/auth_gss/svcauth_gss.c
1460
struct sunrpc_net *sn = net_generic(net, sunrpc_net_id);
net/sunrpc/auth_gss/svcauth_gss.c
1466
&use_gss_proxy_proc_ops, net);
net/sunrpc/auth_gss/svcauth_gss.c
1473
static void destroy_use_gss_proxy_proc_entry(struct net *net)
net/sunrpc/auth_gss/svcauth_gss.c
1475
struct sunrpc_net *sn = net_generic(net, sunrpc_net_id);
net/sunrpc/auth_gss/svcauth_gss.c
1513
static int create_krb5_enctypes_proc_entry(struct net *net)
net/sunrpc/auth_gss/svcauth_gss.c
1515
struct sunrpc_net *sn = net_generic(net, sunrpc_net_id);
net/sunrpc/auth_gss/svcauth_gss.c
1520
net);
net/sunrpc/auth_gss/svcauth_gss.c
1524
static void destroy_krb5_enctypes_proc_entry(struct net *net)
net/sunrpc/auth_gss/svcauth_gss.c
1526
struct sunrpc_net *sn = net_generic(net, sunrpc_net_id);
net/sunrpc/auth_gss/svcauth_gss.c
1534
static int create_use_gss_proxy_proc_entry(struct net *net)
net/sunrpc/auth_gss/svcauth_gss.c
1539
static void destroy_use_gss_proxy_proc_entry(struct net *net) {}
net/sunrpc/auth_gss/svcauth_gss.c
1541
static int create_krb5_enctypes_proc_entry(struct net *net)
net/sunrpc/auth_gss/svcauth_gss.c
1546
static void destroy_krb5_enctypes_proc_entry(struct net *net) {}
net/sunrpc/auth_gss/svcauth_gss.c
2019
static int rsi_cache_create_net(struct net *net)
net/sunrpc/auth_gss/svcauth_gss.c
2021
struct sunrpc_net *sn = net_generic(net, sunrpc_net_id);
net/sunrpc/auth_gss/svcauth_gss.c
2025
cd = cache_create_net(&rsi_cache_template, net);
net/sunrpc/auth_gss/svcauth_gss.c
2028
err = cache_register_net(cd, net);
net/sunrpc/auth_gss/svcauth_gss.c
2030
cache_destroy_net(cd, net);
net/sunrpc/auth_gss/svcauth_gss.c
2037
static void rsi_cache_destroy_net(struct net *net)
net/sunrpc/auth_gss/svcauth_gss.c
2039
struct sunrpc_net *sn = net_generic(net, sunrpc_net_id);
net/sunrpc/auth_gss/svcauth_gss.c
2044
cache_unregister_net(cd, net);
net/sunrpc/auth_gss/svcauth_gss.c
2045
cache_destroy_net(cd, net);
net/sunrpc/auth_gss/svcauth_gss.c
2048
static int rsc_cache_create_net(struct net *net)
net/sunrpc/auth_gss/svcauth_gss.c
2050
struct sunrpc_net *sn = net_generic(net, sunrpc_net_id);
net/sunrpc/auth_gss/svcauth_gss.c
2054
cd = cache_create_net(&rsc_cache_template, net);
net/sunrpc/auth_gss/svcauth_gss.c
2057
err = cache_register_net(cd, net);
net/sunrpc/auth_gss/svcauth_gss.c
2059
cache_destroy_net(cd, net);
net/sunrpc/auth_gss/svcauth_gss.c
2066
static void rsc_cache_destroy_net(struct net *net)
net/sunrpc/auth_gss/svcauth_gss.c
2068
struct sunrpc_net *sn = net_generic(net, sunrpc_net_id);
net/sunrpc/auth_gss/svcauth_gss.c
2073
cache_unregister_net(cd, net);
net/sunrpc/auth_gss/svcauth_gss.c
2074
cache_destroy_net(cd, net);
net/sunrpc/auth_gss/svcauth_gss.c
2078
gss_svc_init_net(struct net *net)
net/sunrpc/auth_gss/svcauth_gss.c
2082
rv = rsc_cache_create_net(net);
net/sunrpc/auth_gss/svcauth_gss.c
2085
rv = rsi_cache_create_net(net);
net/sunrpc/auth_gss/svcauth_gss.c
2088
rv = create_use_gss_proxy_proc_entry(net);
net/sunrpc/auth_gss/svcauth_gss.c
2092
rv = create_krb5_enctypes_proc_entry(net);
net/sunrpc/auth_gss/svcauth_gss.c
2099
destroy_use_gss_proxy_proc_entry(net);
net/sunrpc/auth_gss/svcauth_gss.c
2101
rsi_cache_destroy_net(net);
net/sunrpc/auth_gss/svcauth_gss.c
2103
rsc_cache_destroy_net(net);
net/sunrpc/auth_gss/svcauth_gss.c
2108
gss_svc_shutdown_net(struct net *net)
net/sunrpc/auth_gss/svcauth_gss.c
2110
destroy_krb5_enctypes_proc_entry(net);
net/sunrpc/auth_gss/svcauth_gss.c
2111
destroy_use_gss_proxy_proc_entry(net);
net/sunrpc/auth_gss/svcauth_gss.c
2112
rsi_cache_destroy_net(net);
net/sunrpc/auth_gss/svcauth_gss.c
2113
rsc_cache_destroy_net(net);
net/sunrpc/cache.c
1671
static int create_cache_proc_entries(struct cache_detail *cd, struct net *net)
net/sunrpc/cache.c
1679
sn = net_generic(net, sunrpc_net_id);
net/sunrpc/cache.c
1712
int cache_register_net(struct cache_detail *cd, struct net *net)
net/sunrpc/cache.c
1717
ret = create_cache_proc_entries(cd, net);
net/sunrpc/cache.c
1724
void cache_unregister_net(struct cache_detail *cd, struct net *net)
net/sunrpc/cache.c
1731
struct cache_detail *cache_create_net(const struct cache_detail *tmpl, struct net *net)
net/sunrpc/cache.c
1748
cd->net = net;
net/sunrpc/cache.c
1753
void cache_destroy_net(struct cache_detail *cd, struct net *net)
net/sunrpc/cache.c
1985
if (!genl_has_listeners(&sunrpc_nl_family, cd->net,
net/sunrpc/cache.c
2006
return genlmsg_multicast_netns(&sunrpc_nl_family, cd->net, msg, 0,
net/sunrpc/clnt.c
104
struct net *net = rpc_net_ns(clnt);
net/sunrpc/clnt.c
107
pipefs_sb = rpc_get_sb_net(net);
net/sunrpc/clnt.c
111
rpc_put_sb_net(net);
net/sunrpc/clnt.c
1459
static int rpc_sockname(struct net *net, struct sockaddr *sap, size_t salen,
net/sunrpc/clnt.c
1465
err = __sock_create(net, sap->sa_family,
net/sunrpc/clnt.c
1570
struct net *net;
net/sunrpc/clnt.c
1578
net = get_net(xprt->xprt_net);
net/sunrpc/clnt.c
1582
err = rpc_sockname(net, sap, salen, buf);
net/sunrpc/clnt.c
1583
put_net(net);
net/sunrpc/clnt.c
1609
struct net *rpc_net_ns(struct rpc_clnt *clnt)
net/sunrpc/clnt.c
1611
struct net *ret;
net/sunrpc/clnt.c
209
static struct rpc_clnt *rpc_get_client_for_event(struct net *net, int event)
net/sunrpc/clnt.c
211
struct sunrpc_net *sn = net_generic(net, sunrpc_net_id);
net/sunrpc/clnt.c
293
struct net *net = rpc_net_ns(clnt);
net/sunrpc/clnt.c
299
pipefs_sb = rpc_get_sb_net(net);
net/sunrpc/clnt.c
308
rpc_put_sb_net(net);
net/sunrpc/clnt.c
319
pipefs_sb = rpc_get_sb_net(net);
net/sunrpc/clnt.c
324
rpc_put_sb_net(net);
net/sunrpc/clnt.c
3377
void rpc_show_tasks(struct net *net)
net/sunrpc/clnt.c
3382
struct sunrpc_net *sn = net_generic(net, sunrpc_net_id);
net/sunrpc/clnt.c
524
.net = args->net,
net/sunrpc/clnt.c
79
struct net *net = rpc_net_ns(clnt);
net/sunrpc/clnt.c
80
struct sunrpc_net *sn = net_generic(net, sunrpc_net_id);
net/sunrpc/clnt.c
89
struct net *net = rpc_net_ns(clnt);
net/sunrpc/clnt.c
90
struct sunrpc_net *sn = net_generic(net, sunrpc_net_id);
net/sunrpc/netns.h
41
int ip_map_cache_create(struct net *);
net/sunrpc/netns.h
42
void ip_map_cache_destroy(struct net *);
net/sunrpc/rpc_pipe.c
1012
int rpc_pipefs_init_net(struct net *net)
net/sunrpc/rpc_pipe.c
1014
struct sunrpc_net *sn = net_generic(net, sunrpc_net_id);
net/sunrpc/rpc_pipe.c
1025
void rpc_pipefs_exit_net(struct net *net)
net/sunrpc/rpc_pipe.c
1027
struct sunrpc_net *sn = net_generic(net, sunrpc_net_id);
net/sunrpc/rpc_pipe.c
1038
struct super_block *rpc_get_sb_net(const struct net *net)
net/sunrpc/rpc_pipe.c
1040
struct sunrpc_net *sn = net_generic(net, sunrpc_net_id);
net/sunrpc/rpc_pipe.c
1050
void rpc_put_sb_net(const struct net *net)
net/sunrpc/rpc_pipe.c
1052
struct sunrpc_net *sn = net_generic(net, sunrpc_net_id);
net/sunrpc/rpc_pipe.c
1121
struct net *net = sb->s_fs_info;
net/sunrpc/rpc_pipe.c
1122
struct sunrpc_net *sn = net_generic(net, sunrpc_net_id);
net/sunrpc/rpc_pipe.c
1144
net->ns.inum, NET_NAME(net));
net/sunrpc/rpc_pipe.c
1155
gssd_running(struct net *net)
net/sunrpc/rpc_pipe.c
1157
struct sunrpc_net *sn = net_generic(net, sunrpc_net_id);
net/sunrpc/rpc_pipe.c
1190
struct net *net = sb->s_fs_info;
net/sunrpc/rpc_pipe.c
1191
struct sunrpc_net *sn = net_generic(net, sunrpc_net_id);
net/sunrpc/rpc_pipe.c
1200
net->ns.inum, NET_NAME(net));
net/sunrpc/rpc_pipe.c
1207
put_net(net);
net/sunrpc/rpc_pipe.c
41
#define NET_NAME(net) ((net == &init_net) ? " (init_net)" : "")
net/sunrpc/rpc_pipe.c
727
rpc_add_pipe_dir_object_locked(struct net *net,
net/sunrpc/rpc_pipe.c
741
rpc_remove_pipe_dir_object_locked(struct net *net,
net/sunrpc/rpc_pipe.c
758
rpc_add_pipe_dir_object(struct net *net,
net/sunrpc/rpc_pipe.c
765
struct sunrpc_net *sn = net_generic(net, sunrpc_net_id);
net/sunrpc/rpc_pipe.c
768
ret = rpc_add_pipe_dir_object_locked(net, pdh, pdo);
net/sunrpc/rpc_pipe.c
783
rpc_remove_pipe_dir_object(struct net *net,
net/sunrpc/rpc_pipe.c
788
struct sunrpc_net *sn = net_generic(net, sunrpc_net_id);
net/sunrpc/rpc_pipe.c
791
rpc_remove_pipe_dir_object_locked(net, pdh, pdo);
net/sunrpc/rpc_pipe.c
807
rpc_find_or_alloc_pipe_dir_object(struct net *net,
net/sunrpc/rpc_pipe.c
813
struct sunrpc_net *sn = net_generic(net, sunrpc_net_id);
net/sunrpc/rpc_pipe.c
825
rpc_add_pipe_dir_object_locked(net, pdh, pdo);
net/sunrpc/rpcb_clnt.c
164
static int rpcb_get_local(struct net *net)
net/sunrpc/rpcb_clnt.c
167
struct sunrpc_net *sn = net_generic(net, sunrpc_net_id);
net/sunrpc/rpcb_clnt.c
178
void rpcb_put_local(struct net *net)
net/sunrpc/rpcb_clnt.c
180
struct sunrpc_net *sn = net_generic(net, sunrpc_net_id);
net/sunrpc/rpcb_clnt.c
206
static void rpcb_set_local(struct net *net, struct rpc_clnt *clnt,
net/sunrpc/rpcb_clnt.c
210
struct sunrpc_net *sn = net_generic(net, sunrpc_net_id);
net/sunrpc/rpcb_clnt.c
228
static int rpcb_create_af_local(struct net *net,
net/sunrpc/rpcb_clnt.c
232
.net = net,
net/sunrpc/rpcb_clnt.c
268
rpcb_set_local(net, clnt, clnt4, true);
net/sunrpc/rpcb_clnt.c
274
static int rpcb_create_local_abstract(struct net *net)
net/sunrpc/rpcb_clnt.c
281
return rpcb_create_af_local(net, &rpcb_localaddr_abstract);
net/sunrpc/rpcb_clnt.c
284
static int rpcb_create_local_unix(struct net *net)
net/sunrpc/rpcb_clnt.c
291
return rpcb_create_af_local(net, &rpcb_localaddr_unix);
net/sunrpc/rpcb_clnt.c
298
static int rpcb_create_local_net(struct net *net)
net/sunrpc/rpcb_clnt.c
306
.net = net,
net/sunrpc/rpcb_clnt.c
335
rpcb_set_local(net, clnt, clnt4, false);
net/sunrpc/rpcb_clnt.c
345
int rpcb_create_local(struct net *net)
net/sunrpc/rpcb_clnt.c
350
if (rpcb_get_local(net))
net/sunrpc/rpcb_clnt.c
354
if (rpcb_get_local(net))
net/sunrpc/rpcb_clnt.c
357
if (rpcb_create_local_abstract(net) != 0 &&
net/sunrpc/rpcb_clnt.c
358
rpcb_create_local_unix(net) != 0)
net/sunrpc/rpcb_clnt.c
359
result = rpcb_create_local_net(net);
net/sunrpc/rpcb_clnt.c
366
static struct rpc_clnt *rpcb_create(struct net *net, const char *nodename,
net/sunrpc/rpcb_clnt.c
374
.net = net,
net/sunrpc/rpcb_clnt.c
454
int rpcb_register(struct net *net, u32 prog, u32 vers, int prot, unsigned short port)
net/sunrpc/rpcb_clnt.c
465
struct sunrpc_net *sn = net_generic(net, sunrpc_net_id);
net/sunrpc/rpcb_clnt.c
588
int rpcb_v4_register(struct net *net, const u32 program, const u32 version,
net/sunrpc/rpcb_clnt.c
600
struct sunrpc_net *sn = net_generic(net, sunrpc_net_id);
net/sunrpc/stats.c
287
do_register(struct net *net, const char *name, void *data,
net/sunrpc/stats.c
293
sn = net_generic(net, sunrpc_net_id);
net/sunrpc/stats.c
298
rpc_proc_register(struct net *net, struct rpc_stat *statp)
net/sunrpc/stats.c
300
return do_register(net, statp->program->name, statp, &rpc_proc_ops);
net/sunrpc/stats.c
305
rpc_proc_unregister(struct net *net, const char *name)
net/sunrpc/stats.c
309
sn = net_generic(net, sunrpc_net_id);
net/sunrpc/stats.c
315
svc_proc_register(struct net *net, struct svc_stat *statp, const struct proc_ops *proc_ops)
net/sunrpc/stats.c
317
return do_register(net, statp->program->pg_name, net, proc_ops);
net/sunrpc/stats.c
322
svc_proc_unregister(struct net *net, const char *name)
net/sunrpc/stats.c
326
sn = net_generic(net, sunrpc_net_id);
net/sunrpc/stats.c
331
int rpc_proc_init(struct net *net)
net/sunrpc/stats.c
336
sn = net_generic(net, sunrpc_net_id);
net/sunrpc/stats.c
337
sn->proc_net_rpc = proc_mkdir("rpc", net->proc_net);
net/sunrpc/stats.c
344
void rpc_proc_exit(struct net *net)
net/sunrpc/stats.c
347
remove_proc_entry("rpc", net->proc_net);
net/sunrpc/sunrpc_syms.c
36
static __net_init int sunrpc_init_net(struct net *net)
net/sunrpc/sunrpc_syms.c
39
struct sunrpc_net *sn = net_generic(net, sunrpc_net_id);
net/sunrpc/sunrpc_syms.c
41
err = rpc_proc_init(net);
net/sunrpc/sunrpc_syms.c
45
err = ip_map_cache_create(net);
net/sunrpc/sunrpc_syms.c
49
err = unix_gid_cache_create(net);
net/sunrpc/sunrpc_syms.c
53
err = rpc_pipefs_init_net(net);
net/sunrpc/sunrpc_syms.c
63
unix_gid_cache_destroy(net);
net/sunrpc/sunrpc_syms.c
65
ip_map_cache_destroy(net);
net/sunrpc/sunrpc_syms.c
67
rpc_proc_exit(net);
net/sunrpc/sunrpc_syms.c
72
static __net_exit void sunrpc_exit_net(struct net *net)
net/sunrpc/sunrpc_syms.c
74
struct sunrpc_net *sn = net_generic(net, sunrpc_net_id);
net/sunrpc/sunrpc_syms.c
76
rpc_pipefs_exit_net(net);
net/sunrpc/sunrpc_syms.c
77
unix_gid_cache_destroy(net);
net/sunrpc/sunrpc_syms.c
78
ip_map_cache_destroy(net);
net/sunrpc/sunrpc_syms.c
79
rpc_proc_exit(net);
net/sunrpc/svc.c
1054
static int __svc_rpcb_register4(struct net *net, const u32 program,
net/sunrpc/svc.c
1078
error = rpcb_v4_register(net, program, version,
net/sunrpc/svc.c
1086
error = rpcb_register(net, program, version, protocol, port);
net/sunrpc/svc.c
1102
static int __svc_rpcb_register6(struct net *net, const u32 program,
net/sunrpc/svc.c
1126
error = rpcb_v4_register(net, program, version,
net/sunrpc/svc.c
1146
static int __svc_register(struct net *net, const char *progname,
net/sunrpc/svc.c
1156
error = __svc_rpcb_register4(net, program, version,
net/sunrpc/svc.c
1161
error = __svc_rpcb_register6(net, program, version,
net/sunrpc/svc.c
1171
int svc_rpcbind_set_version(struct net *net,
net/sunrpc/svc.c
1177
return __svc_register(net, progp->pg_name, progp->pg_prog,
net/sunrpc/svc.c
1182
int svc_generic_rpcbind_set(struct net *net,
net/sunrpc/svc.c
1207
error = svc_rpcbind_set_version(net, progp, version,
net/sunrpc/svc.c
1224
int svc_register(const struct svc_serv *serv, struct net *net,
net/sunrpc/svc.c
1240
error = progp->pg_rpcbind_set(net, progp, i,
net/sunrpc/svc.c
1261
static void __svc_unregister(struct net *net, const u32 program, const u32 version,
net/sunrpc/svc.c
1266
error = rpcb_v4_register(net, program, version, NULL, "");
net/sunrpc/svc.c
1273
error = rpcb_register(net, program, version, 0, 0);
net/sunrpc/svc.c
1286
static void svc_unregister(const struct svc_serv *serv, struct net *net)
net/sunrpc/svc.c
1302
__svc_unregister(net, progp->pg_prog, i, progp->pg_name);
net/sunrpc/svc.c
39
static void svc_unregister(const struct svc_serv *serv, struct net *net);
net/sunrpc/svc.c
421
static int svc_rpcb_setup(struct svc_serv *serv, struct net *net)
net/sunrpc/svc.c
425
err = rpcb_create_local(net);
net/sunrpc/svc.c
430
svc_unregister(serv, net);
net/sunrpc/svc.c
434
void svc_rpcb_cleanup(struct svc_serv *serv, struct net *net)
net/sunrpc/svc.c
436
svc_unregister(serv, net);
net/sunrpc/svc.c
437
rpcb_put_local(net);
net/sunrpc/svc.c
458
int svc_bind(struct svc_serv *serv, struct net *net)
net/sunrpc/svc.c
462
return svc_rpcb_setup(serv, net);
net/sunrpc/svc_xprt.c
1169
static int svc_close_list(struct svc_serv *serv, struct list_head *xprt_list, struct net *net)
net/sunrpc/svc_xprt.c
1176
if (xprt->xpt_net != net)
net/sunrpc/svc_xprt.c
1186
static void svc_clean_up_xprts(struct svc_serv *serv, struct net *net)
net/sunrpc/svc_xprt.c
1197
if (xprt->xpt_net == net) {
net/sunrpc/svc_xprt.c
1226
void svc_xprt_destroy_all(struct svc_serv *serv, struct net *net,
net/sunrpc/svc_xprt.c
1231
while (svc_close_list(serv, &serv->sv_permsocks, net) +
net/sunrpc/svc_xprt.c
1232
svc_close_list(serv, &serv->sv_tempsocks, net)) {
net/sunrpc/svc_xprt.c
1234
svc_clean_up_xprts(serv, net);
net/sunrpc/svc_xprt.c
1239
svc_rpcb_cleanup(serv, net);
net/sunrpc/svc_xprt.c
1380
struct net *net, const struct sockaddr *sa)
net/sunrpc/svc_xprt.c
1387
if (xprt->xpt_net != net)
net/sunrpc/svc_xprt.c
1419
struct net *net, const sa_family_t af,
net/sunrpc/svc_xprt.c
1431
if (xprt->xpt_net != net)
net/sunrpc/svc_xprt.c
195
void svc_xprt_init(struct net *net, struct svc_xprt_class *xcl,
net/sunrpc/svc_xprt.c
209
xprt->xpt_net = get_net_track(net, &xprt->ns_tracker, GFP_ATOMIC);
net/sunrpc/svc_xprt.c
264
struct net *net, struct sockaddr *sap,
net/sunrpc/svc_xprt.c
281
newxprt = xcl->xcl_ops->xpo_create(serv, net, sap, len, flags);
net/sunrpc/svc_xprt.c
313
struct net *net, struct sockaddr *sap,
net/sunrpc/svc_xprt.c
332
err = _svc_xprt_create(serv, xprt_name, net, sap, len, flags, cred);
net/sunrpc/svc_xprt.c
335
err = _svc_xprt_create(serv, xprt_name, net, sap, len, flags,
net/sunrpc/svc_xprt.c
356
struct net *net, const int family,
net/sunrpc/svc_xprt.c
387
return svc_xprt_create_from_sa(serv, xprt_name, net, sap, flags, cred);
net/sunrpc/svcauth_unix.c
1445
if (rpc_pton(cd->net, nla_data(tb[SUNRPC_A_IP_MAP_ADDR]),
net/sunrpc/svcauth_unix.c
1547
int ip_map_cache_create(struct net *net)
net/sunrpc/svcauth_unix.c
1549
struct sunrpc_net *sn = net_generic(net, sunrpc_net_id);
net/sunrpc/svcauth_unix.c
1553
cd = cache_create_net(&ip_map_cache_template, net);
net/sunrpc/svcauth_unix.c
1556
err = cache_register_net(cd, net);
net/sunrpc/svcauth_unix.c
1558
cache_destroy_net(cd, net);
net/sunrpc/svcauth_unix.c
1565
void ip_map_cache_destroy(struct net *net)
net/sunrpc/svcauth_unix.c
1567
struct sunrpc_net *sn = net_generic(net, sunrpc_net_id);
net/sunrpc/svcauth_unix.c
1572
cache_unregister_net(cd, net);
net/sunrpc/svcauth_unix.c
1573
cache_destroy_net(cd, net);
net/sunrpc/svcauth_unix.c
214
if (rpc_pton(cd->net, buf, len, &address.sa, sizeof(address)) == 0)
net/sunrpc/svcauth_unix.c
331
void svcauth_unix_purge(struct net *net)
net/sunrpc/svcauth_unix.c
335
sn = net_generic(net, sunrpc_net_id);
net/sunrpc/svcauth_unix.c
869
int unix_gid_cache_create(struct net *net)
net/sunrpc/svcauth_unix.c
871
struct sunrpc_net *sn = net_generic(net, sunrpc_net_id);
net/sunrpc/svcauth_unix.c
875
cd = cache_create_net(&unix_gid_cache_template, net);
net/sunrpc/svcauth_unix.c
878
err = cache_register_net(cd, net);
net/sunrpc/svcauth_unix.c
880
cache_destroy_net(cd, net);
net/sunrpc/svcauth_unix.c
887
void unix_gid_cache_destroy(struct net *net)
net/sunrpc/svcauth_unix.c
889
struct sunrpc_net *sn = net_generic(net, sunrpc_net_id);
net/sunrpc/svcauth_unix.c
894
cache_unregister_net(cd, net);
net/sunrpc/svcauth_unix.c
895
cache_destroy_net(cd, net);
net/sunrpc/svcauth_unix.c
946
struct net *net = xprt->xpt_net;
net/sunrpc/svcauth_unix.c
947
struct sunrpc_net *sn = net_generic(net, sunrpc_net_id);
net/sunrpc/svcsock.c
1329
struct net *net,
net/sunrpc/svcsock.c
1333
return svc_create_socket(serv, IPPROTO_TCP, net, sa, salen, flags);
net/sunrpc/svcsock.c
1519
int svc_addsock(struct svc_serv *serv, struct net *net, const int fd,
net/sunrpc/svcsock.c
1532
if (sock_net(so->sk) != net)
net/sunrpc/svcsock.c
1570
struct net *net,
net/sunrpc/svcsock.c
1601
error = __sock_create(net, family, type, protocol, &sock, 1);
net/sunrpc/svcsock.c
814
struct net *net,
net/sunrpc/svcsock.c
818
return svc_create_socket(serv, IPPROTO_UDP, net, sa, salen, flags);
net/sunrpc/svcsock.c
98
struct net *, struct sockaddr *,
net/sunrpc/sysfs.c
341
xprt_create_args.net = xprt->xprt_net;
net/sunrpc/sysfs.c
560
kobject)->net);
net/sunrpc/sysfs.c
566
kobject)->net);
net/sunrpc/sysfs.c
664
struct net *net,
net/sunrpc/sysfs.c
671
p->net = net;
net/sunrpc/sysfs.c
684
struct net *net,
net/sunrpc/sysfs.c
691
p->net = net;
net/sunrpc/sysfs.c
724
struct net *net)
net/sunrpc/sysfs.c
734
net, clnt->cl_clid);
net/sunrpc/sysfs.c
756
struct net *net;
net/sunrpc/sysfs.c
759
net = xprt_switch->xps_net;
net/sunrpc/sysfs.c
761
net = xprt->xprt_net;
net/sunrpc/sysfs.c
764
xprt_switch, net, gfp_flags);
net/sunrpc/sysfs.h
10
struct net *net;
net/sunrpc/sysfs.h
26
struct net *net);
net/sunrpc/xprt.c
1832
struct rpc_xprt *xprt_alloc(struct net *net, size_t size,
net/sunrpc/xprt.c
1845
xprt_init(xprt, net);
net/sunrpc/xprt.c
2039
static void xprt_init(struct rpc_xprt *xprt, struct net *net)
net/sunrpc/xprt.c
2067
xprt->xprt_net = get_net_track(net, &xprt->ns_tracker, GFP_KERNEL);
net/sunrpc/xprt.c
72
static void xprt_init(struct rpc_xprt *xprt, struct net *net);
net/sunrpc/xprtrdma/svc_rdma_backchannel.c
243
xprt = xprt_alloc(args->net, sizeof(*new_xprt),
net/sunrpc/xprtrdma/svc_rdma_transport.c
145
svc_rdma_create_listen_id(struct net *net, struct sockaddr *sap,
net/sunrpc/xprtrdma/svc_rdma_transport.c
151
listen_id = rdma_create_id(net, svc_rdma_listen_handler, context,
net/sunrpc/xprtrdma/svc_rdma_transport.c
180
struct net *net, int node)
net/sunrpc/xprtrdma/svc_rdma_transport.c
191
svc_xprt_init(net, &svc_rdma_class, &cma_xprt->sc_xprt, serv);
net/sunrpc/xprtrdma/svc_rdma_transport.c
373
struct net *net,
net/sunrpc/xprtrdma/svc_rdma_transport.c
382
cma_xprt = svc_rdma_create_xprt(serv, net, NUMA_NO_NODE);
net/sunrpc/xprtrdma/svc_rdma_transport.c
388
listen_id = svc_rdma_create_listen_id(net, sa, cma_xprt);
net/sunrpc/xprtrdma/svc_rdma_transport.c
67
struct net *net, int node);
net/sunrpc/xprtrdma/svc_rdma_transport.c
71
struct net *net,
net/sunrpc/xprtrdma/transport.c
322
xprt = xprt_alloc(args->net, sizeof(struct rpcrdma_xprt), 0,
net/sunrpc/xprtsock.c
2284
struct net *net = sock_net(sock->sk);
net/sunrpc/xprtsock.c
2313
READ_ONCE(net->ipv4.sysctl_tcp_syn_retries), 1);
net/sunrpc/xprtsock.c
2693
.net = upper_xprt->xprt_net,
net/sunrpc/xprtsock.c
3207
xprt = xprt_alloc(args->net, sizeof(*new), slot_table_size,
net/sysctl_net.c
123
static void ensure_safe_net_sysctl(struct net *net, const char *path,
net/sysctl_net.c
128
pr_debug("Registering net sysctl (net %p): %s\n", net, path);
net/sysctl_net.c
163
struct ctl_table_header *register_net_sysctl_sz(struct net *net,
net/sysctl_net.c
168
if (!net_eq(net, &init_net))
net/sysctl_net.c
169
ensure_safe_net_sysctl(net, path, table, table_size);
net/sysctl_net.c
171
return __register_sysctl_table(&net->sysctls, path, table, table_size);
net/sysctl_net.c
45
struct net *net = container_of(head->set, struct net, sysctls);
net/sysctl_net.c
48
if (ns_capable_noaudit(net->user_ns, CAP_NET_ADMIN)) {
net/sysctl_net.c
59
struct net *net = container_of(head->set, struct net, sysctls);
net/sysctl_net.c
63
ns_root_uid = make_kuid(net->user_ns, 0);
net/sysctl_net.c
67
ns_root_gid = make_kgid(net->user_ns, 0);
net/sysctl_net.c
78
static int __net_init sysctl_net_init(struct net *net)
net/sysctl_net.c
80
setup_sysctl_set(&net->sysctls, &net_sysctl_root, is_seen);
net/sysctl_net.c
84
static void __net_exit sysctl_net_exit(struct net *net)
net/sysctl_net.c
86
retire_sysctl_set(&net->sysctls);
net/tipc/addr.c
56
void tipc_set_node_id(struct net *net, u8 *id)
net/tipc/addr.c
58
struct tipc_net *tn = tipc_net(net);
net/tipc/addr.c
64
tipc_own_id_string(net), tn->net_id);
net/tipc/addr.c
67
void tipc_set_node_addr(struct net *net, u32 addr)
net/tipc/addr.c
69
struct tipc_net *tn = tipc_net(net);
net/tipc/addr.c
73
if (!tipc_own_id(net)) {
net/tipc/addr.c
75
tipc_set_node_id(net, node_id);
net/tipc/addr.h
105
static inline char *tipc_own_id_string(struct net *net)
net/tipc/addr.h
107
return tipc_net(net)->node_id_string;
net/tipc/addr.h
120
static inline int tipc_scope2node(struct net *net, int sc)
net/tipc/addr.h
122
return sc != TIPC_NODE_SCOPE ? 0 : tipc_own_addr(net);
net/tipc/addr.h
125
static inline int in_own_node(struct net *net, u32 addr)
net/tipc/addr.h
127
return addr == tipc_own_addr(net) || !addr;
net/tipc/addr.h
131
void tipc_set_node_id(struct net *net, u8 *id);
net/tipc/addr.h
132
void tipc_set_node_addr(struct net *net, u32 addr);
net/tipc/addr.h
91
static inline u32 tipc_own_addr(struct net *net)
net/tipc/addr.h
93
return tipc_net(net)->node_addr;
net/tipc/addr.h
96
static inline u8 *tipc_own_id(struct net *net)
net/tipc/addr.h
98
struct tipc_net *tn = tipc_net(net);
net/tipc/bcast.c
107
static void tipc_bcbase_select_primary(struct net *net)
net/tipc/bcast.c
109
struct tipc_bc_base *bb = tipc_bc_base(net);
net/tipc/bcast.c
125
mtu = tipc_bearer_mtu(net, i);
net/tipc/bcast.c
132
bb->bcast_support &= tipc_bearer_bcast_support(net, i);
net/tipc/bcast.c
139
if ((i ^ tipc_own_addr(net)) & 1)
net/tipc/bcast.c
144
bb->bcast_support = tipc_bearer_bcast_support(net, prim);
net/tipc/bcast.c
147
void tipc_bcast_inc_bearer_dst_cnt(struct net *net, int bearer_id)
net/tipc/bcast.c
149
struct tipc_bc_base *bb = tipc_bc_base(net);
net/tipc/bcast.c
151
tipc_bcast_lock(net);
net/tipc/bcast.c
153
tipc_bcbase_select_primary(net);
net/tipc/bcast.c
154
tipc_bcast_unlock(net);
net/tipc/bcast.c
157
void tipc_bcast_dec_bearer_dst_cnt(struct net *net, int bearer_id)
net/tipc/bcast.c
159
struct tipc_bc_base *bb = tipc_bc_base(net);
net/tipc/bcast.c
161
tipc_bcast_lock(net);
net/tipc/bcast.c
163
tipc_bcbase_select_primary(net);
net/tipc/bcast.c
164
tipc_bcast_unlock(net);
net/tipc/bcast.c
177
static void tipc_bcbase_xmit(struct net *net, struct sk_buff_head *xmitq)
net/tipc/bcast.c
180
struct tipc_bc_base *bb = tipc_bc_base(net);
net/tipc/bcast.c
190
tipc_bearer_bc_xmit(net, bearer_id, xmitq);
net/tipc/bcast.c
206
tipc_bearer_bc_xmit(net, bearer_id, &_xmitq);
net/tipc/bcast.c
212
static void tipc_bcast_select_xmit_method(struct net *net, int dests,
net/tipc/bcast.c
215
struct tipc_bc_base *bb = tipc_bc_base(net);
net/tipc/bcast.c
233
if (!(tipc_net(net)->capabilities & TIPC_MCAST_RBCTL) &&
net/tipc/bcast.c
259
int tipc_bcast_xmit(struct net *net, struct sk_buff_head *pkts,
net/tipc/bcast.c
262
struct tipc_link *l = tipc_bc_sndlink(net);
net/tipc/bcast.c
267
tipc_bcast_lock(net);
net/tipc/bcast.c
270
tipc_bcast_unlock(net);
net/tipc/bcast.c
271
tipc_bcbase_xmit(net, &xmitq);
net/tipc/bcast.c
288
static int tipc_rcast_xmit(struct net *net, struct sk_buff_head *pkts,
net/tipc/bcast.c
304
if (tipc_node_xmit(net, &_pkts, dnode, selector) == -ELINKCONG)
net/tipc/bcast.c
317
static int tipc_mcast_send_sync(struct net *net, struct sk_buff *skb,
net/tipc/bcast.c
328
if (!(tipc_net(net)->capabilities & TIPC_MCAST_RBCTL))
net/tipc/bcast.c
358
rc = tipc_bcast_xmit(net, &tmpq, &cong_link_cnt);
net/tipc/bcast.c
360
rc = tipc_rcast_xmit(net, &tmpq, dests, &cong_link_cnt);
net/tipc/bcast.c
378
int tipc_mcast_xmit(struct net *net, struct sk_buff_head *pkts,
net/tipc/bcast.c
398
tipc_bcast_select_xmit_method(net, dests->remote, method);
net/tipc/bcast.c
408
rc = tipc_mcast_send_sync(net, skb, method, dests);
net/tipc/bcast.c
417
rc = tipc_rcast_xmit(net, pkts, dests, cong_link_cnt);
net/tipc/bcast.c
419
rc = tipc_bcast_xmit(net, pkts, cong_link_cnt);
net/tipc/bcast.c
423
tipc_loopback_trace(net, &localq);
net/tipc/bcast.c
424
tipc_sk_mcast_rcv(net, &localq, &inputq);
net/tipc/bcast.c
436
int tipc_bcast_rcv(struct net *net, struct tipc_link *l, struct sk_buff *skb)
net/tipc/bcast.c
439
struct sk_buff_head *inputq = &tipc_bc_base(net)->inputq;
net/tipc/bcast.c
445
if (msg_mc_netid(hdr) != tipc_netid(net) || !tipc_link_is_up(l)) {
net/tipc/bcast.c
450
tipc_bcast_lock(net);
net/tipc/bcast.c
455
tipc_bcast_unlock(net);
net/tipc/bcast.c
457
tipc_bcbase_xmit(net, &xmitq);
net/tipc/bcast.c
461
tipc_sk_rcv(net, inputq);
net/tipc/bcast.c
470
void tipc_bcast_ack_rcv(struct net *net, struct tipc_link *l,
net/tipc/bcast.c
473
struct sk_buff_head *inputq = &tipc_bc_base(net)->inputq;
net/tipc/bcast.c
483
tipc_bcast_lock(net);
net/tipc/bcast.c
485
tipc_bcast_unlock(net);
net/tipc/bcast.c
487
tipc_bcbase_xmit(net, &xmitq);
net/tipc/bcast.c
491
tipc_sk_rcv(net, inputq);
net/tipc/bcast.c
498
int tipc_bcast_sync_rcv(struct net *net, struct tipc_link *l,
net/tipc/bcast.c
502
struct sk_buff_head *inputq = &tipc_bc_base(net)->inputq;
net/tipc/bcast.c
510
tipc_bcast_lock(net);
net/tipc/bcast.c
527
tipc_bcast_unlock(net);
net/tipc/bcast.c
529
tipc_bcbase_xmit(net, &xmitq);
net/tipc/bcast.c
533
tipc_sk_rcv(net, inputq);
net/tipc/bcast.c
541
void tipc_bcast_add_peer(struct net *net, struct tipc_link *uc_l,
net/tipc/bcast.c
544
struct tipc_link *snd_l = tipc_bc_sndlink(net);
net/tipc/bcast.c
546
tipc_bcast_lock(net);
net/tipc/bcast.c
548
tipc_bcbase_select_primary(net);
net/tipc/bcast.c
549
tipc_bcbase_calc_bc_threshold(net);
net/tipc/bcast.c
550
tipc_bcast_unlock(net);
net/tipc/bcast.c
557
void tipc_bcast_remove_peer(struct net *net, struct tipc_link *rcv_l)
net/tipc/bcast.c
559
struct tipc_link *snd_l = tipc_bc_sndlink(net);
net/tipc/bcast.c
560
struct sk_buff_head *inputq = &tipc_bc_base(net)->inputq;
net/tipc/bcast.c
565
tipc_bcast_lock(net);
net/tipc/bcast.c
567
tipc_bcbase_select_primary(net);
net/tipc/bcast.c
568
tipc_bcbase_calc_bc_threshold(net);
net/tipc/bcast.c
569
tipc_bcast_unlock(net);
net/tipc/bcast.c
571
tipc_bcbase_xmit(net, &xmitq);
net/tipc/bcast.c
575
tipc_sk_rcv(net, inputq);
net/tipc/bcast.c
578
int tipc_bclink_reset_stats(struct net *net, struct tipc_link *l)
net/tipc/bcast.c
583
tipc_bcast_lock(net);
net/tipc/bcast.c
585
tipc_bcast_unlock(net);
net/tipc/bcast.c
589
static int tipc_bc_link_set_queue_limits(struct net *net, u32 max_win)
net/tipc/bcast.c
591
struct tipc_link *l = tipc_bc_sndlink(net);
net/tipc/bcast.c
599
tipc_bcast_lock(net);
net/tipc/bcast.c
601
tipc_bcast_unlock(net);
net/tipc/bcast.c
605
static int tipc_bc_link_set_broadcast_mode(struct net *net, u32 bc_mode)
net/tipc/bcast.c
607
struct tipc_bc_base *bb = tipc_bc_base(net);
net/tipc/bcast.c
638
static int tipc_bc_link_set_broadcast_ratio(struct net *net, u32 bc_ratio)
net/tipc/bcast.c
640
struct tipc_bc_base *bb = tipc_bc_base(net);
net/tipc/bcast.c
649
tipc_bcast_lock(net);
net/tipc/bcast.c
650
tipc_bcbase_calc_bc_threshold(net);
net/tipc/bcast.c
651
tipc_bcast_unlock(net);
net/tipc/bcast.c
656
int tipc_nl_bc_link_set(struct net *net, struct nlattr *attrs[])
net/tipc/bcast.c
679
err = tipc_bc_link_set_broadcast_mode(net, bc_mode);
net/tipc/bcast.c
684
err = tipc_bc_link_set_broadcast_ratio(net, bc_ratio);
net/tipc/bcast.c
689
err = tipc_bc_link_set_queue_limits(net, win);
net/tipc/bcast.c
695
int tipc_bcast_init(struct net *net)
net/tipc/bcast.c
697
struct tipc_net *tn = tipc_net(net);
net/tipc/bcast.c
705
spin_lock_init(&tipc_net(net)->bclock);
net/tipc/bcast.c
707
if (!tipc_link_bc_create(net, 0, 0, NULL,
net/tipc/bcast.c
728
void tipc_bcast_stop(struct net *net)
net/tipc/bcast.c
730
struct tipc_net *tn = net_generic(net, tipc_net_id);
net/tipc/bcast.c
767
u32 tipc_bcast_get_mode(struct net *net)
net/tipc/bcast.c
769
struct tipc_bc_base *bb = tipc_bc_base(net);
net/tipc/bcast.c
77
static struct tipc_bc_base *tipc_bc_base(struct net *net)
net/tipc/bcast.c
783
u32 tipc_bcast_get_broadcast_ratio(struct net *net)
net/tipc/bcast.c
785
struct tipc_bc_base *bb = tipc_bc_base(net);
net/tipc/bcast.c
79
return tipc_net(net)->bcbase;
net/tipc/bcast.c
790
void tipc_mcast_filter_msg(struct net *net, struct sk_buff_head *defq,
net/tipc/bcast.c
808
if (node == tipc_own_addr(net))
net/tipc/bcast.c
86
int tipc_bcast_get_mtu(struct net *net)
net/tipc/bcast.c
88
return tipc_link_mss(tipc_bc_sndlink(net));
net/tipc/bcast.c
91
void tipc_bcast_toggle_rcast(struct net *net, bool supp)
net/tipc/bcast.c
93
tipc_bc_base(net)->rcast_support = supp;
net/tipc/bcast.c
96
static void tipc_bcbase_calc_bc_threshold(struct net *net)
net/tipc/bcast.c
98
struct tipc_bc_base *bb = tipc_bc_base(net);
net/tipc/bcast.c
99
int cluster_size = tipc_link_bc_peers(tipc_bc_sndlink(net));
net/tipc/bcast.h
101
int tipc_nl_add_bc_link(struct net *net, struct tipc_nl_msg *msg,
net/tipc/bcast.h
103
int tipc_nl_bc_link_set(struct net *net, struct nlattr *attrs[]);
net/tipc/bcast.h
104
int tipc_bclink_reset_stats(struct net *net, struct tipc_link *l);
net/tipc/bcast.h
106
u32 tipc_bcast_get_mode(struct net *net);
net/tipc/bcast.h
107
u32 tipc_bcast_get_broadcast_ratio(struct net *net);
net/tipc/bcast.h
109
void tipc_mcast_filter_msg(struct net *net, struct sk_buff_head *defq,
net/tipc/bcast.h
112
static inline void tipc_bcast_lock(struct net *net)
net/tipc/bcast.h
114
spin_lock_bh(&tipc_net(net)->bclock);
net/tipc/bcast.h
117
static inline void tipc_bcast_unlock(struct net *net)
net/tipc/bcast.h
119
spin_unlock_bh(&tipc_net(net)->bclock);
net/tipc/bcast.h
122
static inline struct tipc_link *tipc_bc_sndlink(struct net *net)
net/tipc/bcast.h
124
return tipc_net(net)->bcl;
net/tipc/bcast.h
81
int tipc_bcast_init(struct net *net);
net/tipc/bcast.h
82
void tipc_bcast_stop(struct net *net);
net/tipc/bcast.h
83
void tipc_bcast_add_peer(struct net *net, struct tipc_link *l,
net/tipc/bcast.h
85
void tipc_bcast_remove_peer(struct net *net, struct tipc_link *rcv_bcl);
net/tipc/bcast.h
86
void tipc_bcast_inc_bearer_dst_cnt(struct net *net, int bearer_id);
net/tipc/bcast.h
87
void tipc_bcast_dec_bearer_dst_cnt(struct net *net, int bearer_id);
net/tipc/bcast.h
88
int tipc_bcast_get_mtu(struct net *net);
net/tipc/bcast.h
89
void tipc_bcast_toggle_rcast(struct net *net, bool supp);
net/tipc/bcast.h
90
int tipc_mcast_xmit(struct net *net, struct sk_buff_head *pkts,
net/tipc/bcast.h
93
int tipc_bcast_xmit(struct net *net, struct sk_buff_head *pkts,
net/tipc/bcast.h
95
int tipc_bcast_rcv(struct net *net, struct tipc_link *l, struct sk_buff *skb);
net/tipc/bcast.h
96
void tipc_bcast_ack_rcv(struct net *net, struct tipc_link *l,
net/tipc/bcast.h
98
int tipc_bcast_sync_rcv(struct net *net, struct tipc_link *l,
net/tipc/bearer.c
1013
struct net *net = sock_net(skb->sk);
net/tipc/bearer.c
1048
return tipc_enable_bearer(net, bearer, domain, prio, attrs,
net/tipc/bearer.c
1069
struct net *net = sock_net(skb->sk);
net/tipc/bearer.c
1085
b = tipc_bearer_find(net, name);
net/tipc/bearer.c
1114
struct net *net = sock_net(skb->sk);
net/tipc/bearer.c
1131
b = tipc_bearer_find(net, name);
net/tipc/bearer.c
1147
tipc_node_apply_property(net, b, TIPC_NLA_PROP_TOL);
net/tipc/bearer.c
1167
tipc_node_apply_property(net, b, TIPC_NLA_PROP_MTU);
net/tipc/bearer.c
181
struct tipc_bearer *tipc_bearer_find(struct net *net, const char *name)
net/tipc/bearer.c
183
struct tipc_net *tn = tipc_net(net);
net/tipc/bearer.c
200
int tipc_bearer_get_name(struct net *net, char *name, u32 bearer_id)
net/tipc/bearer.c
202
struct tipc_net *tn = tipc_net(net);
net/tipc/bearer.c
216
void tipc_bearer_add_dest(struct net *net, u32 bearer_id, u32 dest)
net/tipc/bearer.c
221
b = bearer_get(net, bearer_id);
net/tipc/bearer.c
227
void tipc_bearer_remove_dest(struct net *net, u32 bearer_id, u32 dest)
net/tipc/bearer.c
232
b = bearer_get(net, bearer_id);
net/tipc/bearer.c
247
static int tipc_enable_bearer(struct net *net, const char *name,
net/tipc/bearer.c
252
struct tipc_net *tn = tipc_net(net);
net/tipc/bearer.c
331
res = m->enable_media(net, b, attr);
net/tipc/bearer.c
348
res = tipc_disc_create(net, b, &b->bcast_addr, &skb);
net/tipc/bearer.c
350
bearer_disable(net, b);
net/tipc/bearer.c
357
if (tipc_mon_create(net, bearer_id)) {
net/tipc/bearer.c
358
bearer_disable(net, b);
net/tipc/bearer.c
366
tipc_bearer_xmit_skb(net, bearer_id, skb, &b->bcast_addr);
net/tipc/bearer.c
381
static int tipc_reset_bearer(struct net *net, struct tipc_bearer *b)
net/tipc/bearer.c
384
tipc_node_delete_links(net, b->identity);
net/tipc/bearer.c
385
tipc_disc_reset(net, b);
net/tipc/bearer.c
407
static void bearer_disable(struct net *net, struct tipc_bearer *b)
net/tipc/bearer.c
409
struct tipc_net *tn = tipc_net(net);
net/tipc/bearer.c
414
tipc_node_delete_links(net, bearer_id);
net/tipc/bearer.c
421
tipc_mon_delete(net, bearer_id);
net/tipc/bearer.c
424
int tipc_enable_l2_media(struct net *net, struct tipc_bearer *b,
net/tipc/bearer.c
433
dev = dev_get_by_name(net, dev_name);
net/tipc/bearer.c
440
if (dev == net->loopback_dev) {
net/tipc/bearer.c
447
if (!tipc_own_id(net) && hwaddr_len <= NODE_ID_LEN) {
net/tipc/bearer.c
449
tipc_net_init(net, node_id, 0);
net/tipc/bearer.c
451
if (!tipc_own_id(net)) {
net/tipc/bearer.c
497
int tipc_l2_send_msg(struct net *net, struct sk_buff *skb,
net/tipc/bearer.c
521
bool tipc_bearer_bcast_support(struct net *net, u32 bearer_id)
net/tipc/bearer.c
527
b = bearer_get(net, bearer_id);
net/tipc/bearer.c
534
int tipc_bearer_mtu(struct net *net, u32 bearer_id)
net/tipc/bearer.c
540
b = bearer_get(net, bearer_id);
net/tipc/bearer.c
547
int tipc_bearer_min_mtu(struct net *net, u32 bearer_id)
net/tipc/bearer.c
553
b = bearer_get(net, bearer_id);
net/tipc/bearer.c
562
void tipc_bearer_xmit_skb(struct net *net, u32 bearer_id,
net/tipc/bearer.c
570
b = bearer_get(net, bearer_id);
net/tipc/bearer.c
573
tipc_crypto_xmit(net, &skb, b, dest, NULL);
net/tipc/bearer.c
576
b->media->send_msg(net, skb, b, dest);
net/tipc/bearer.c
585
void tipc_bearer_xmit(struct net *net, u32 bearer_id,
net/tipc/bearer.c
597
b = bearer_get(net, bearer_id);
net/tipc/bearer.c
604
tipc_crypto_xmit(net, &skb, b, dst, __dnode);
net/tipc/bearer.c
607
b->media->send_msg(net, skb, b, dst);
net/tipc/bearer.c
617
void tipc_bearer_bc_xmit(struct net *net, u32 bearer_id,
net/tipc/bearer.c
62
static struct tipc_bearer *bearer_get(struct net *net, int bearer_id)
net/tipc/bearer.c
620
struct tipc_net *tn = tipc_net(net);
net/tipc/bearer.c
628
b = bearer_get(net, bearer_id);
net/tipc/bearer.c
638
tipc_crypto_xmit(net, &skb, b, dst, NULL);
net/tipc/bearer.c
64
struct tipc_net *tn = tipc_net(net);
net/tipc/bearer.c
641
b->media->send_msg(net, skb, b, dst);
net/tipc/bearer.c
69
static void bearer_disable(struct net *net, struct tipc_bearer *b);
net/tipc/bearer.c
691
struct net *net = dev_net(dev);
net/tipc/bearer.c
708
tipc_reset_bearer(net, b);
net/tipc/bearer.c
715
bearer_disable(net, b);
net/tipc/bearer.c
719
tipc_reset_bearer(net, b);
net/tipc/bearer.c
724
tipc_reset_bearer(net, b);
net/tipc/bearer.c
728
bearer_disable(net, b);
net/tipc/bearer.c
749
void tipc_bearer_stop(struct net *net)
net/tipc/bearer.c
751
struct tipc_net *tn = tipc_net(net);
net/tipc/bearer.c
758
bearer_disable(net, b);
net/tipc/bearer.c
764
void tipc_clone_to_loopback(struct net *net, struct sk_buff_head *pkts)
net/tipc/bearer.c
766
struct net_device *dev = net->loopback_dev;
net/tipc/bearer.c
799
int tipc_attach_loopback(struct net *net)
net/tipc/bearer.c
801
struct net_device *dev = net->loopback_dev;
net/tipc/bearer.c
802
struct tipc_net *tn = tipc_net(net);
net/tipc/bearer.c
815
void tipc_detach_loopback(struct net *net)
net/tipc/bearer.c
817
struct tipc_net *tn = tipc_net(net);
net/tipc/bearer.c
820
netdev_put(net->loopback_dev, &tn->loopback_pt.dev_tracker);
net/tipc/bearer.c
886
struct net *net = sock_net(skb->sk);
net/tipc/bearer.c
887
struct tipc_net *tn = tipc_net(net);
net/tipc/bearer.c
920
struct net *net = genl_info_net(info);
net/tipc/bearer.c
944
bearer = tipc_bearer_find(net, name);
net/tipc/bearer.c
970
struct net *net = sock_net(skb->sk);
net/tipc/bearer.c
986
bearer = tipc_bearer_find(net, name);
net/tipc/bearer.c
992
bearer_disable(net, bearer);
net/tipc/bearer.h
105
int (*send_msg)(struct net *net, struct sk_buff *buf,
net/tipc/bearer.h
108
int (*enable_media)(struct net *net, struct tipc_bearer *b,
net/tipc/bearer.h
188
void tipc_rcv(struct net *net, struct sk_buff *skb, struct tipc_bearer *b);
net/tipc/bearer.h
218
int tipc_enable_l2_media(struct net *net, struct tipc_bearer *b,
net/tipc/bearer.h
223
int tipc_l2_send_msg(struct net *net, struct sk_buff *buf,
net/tipc/bearer.h
226
void tipc_bearer_add_dest(struct net *net, u32 bearer_id, u32 dest);
net/tipc/bearer.h
227
void tipc_bearer_remove_dest(struct net *net, u32 bearer_id, u32 dest);
net/tipc/bearer.h
228
struct tipc_bearer *tipc_bearer_find(struct net *net, const char *name);
net/tipc/bearer.h
229
int tipc_bearer_get_name(struct net *net, char *name, u32 bearer_id);
net/tipc/bearer.h
233
void tipc_bearer_stop(struct net *net);
net/tipc/bearer.h
234
int tipc_bearer_mtu(struct net *net, u32 bearer_id);
net/tipc/bearer.h
235
int tipc_bearer_min_mtu(struct net *net, u32 bearer_id);
net/tipc/bearer.h
236
bool tipc_bearer_bcast_support(struct net *net, u32 bearer_id);
net/tipc/bearer.h
237
void tipc_bearer_xmit_skb(struct net *net, u32 bearer_id,
net/tipc/bearer.h
240
void tipc_bearer_xmit(struct net *net, u32 bearer_id,
net/tipc/bearer.h
244
void tipc_bearer_bc_xmit(struct net *net, u32 bearer_id,
net/tipc/bearer.h
246
void tipc_clone_to_loopback(struct net *net, struct sk_buff_head *pkts);
net/tipc/bearer.h
247
int tipc_attach_loopback(struct net *net);
net/tipc/bearer.h
248
void tipc_detach_loopback(struct net *net);
net/tipc/bearer.h
250
static inline void tipc_loopback_trace(struct net *net,
net/tipc/bearer.h
253
if (unlikely(dev_nit_active(net->loopback_dev)))
net/tipc/bearer.h
254
tipc_clone_to_loopback(net, pkts);
net/tipc/core.c
108
static void __net_exit tipc_exit_net(struct net *net)
net/tipc/core.c
110
struct tipc_net *tn = tipc_net(net);
net/tipc/core.c
112
tipc_detach_loopback(net);
net/tipc/core.c
113
tipc_net_stop(net);
net/tipc/core.c
116
tipc_bcast_stop(net);
net/tipc/core.c
117
tipc_nametbl_stop(net);
net/tipc/core.c
118
tipc_sk_rht_destroy(net);
net/tipc/core.c
120
tipc_crypto_stop(&tipc_net(net)->crypto_tx);
net/tipc/core.c
125
static void __net_exit tipc_pernet_pre_exit(struct net *net)
net/tipc/core.c
127
tipc_node_pre_cleanup_net(net);
net/tipc/core.c
54
static int __net_init tipc_init_net(struct net *net)
net/tipc/core.c
56
struct tipc_net *tn = net_generic(net, tipc_net_id);
net/tipc/core.c
73
err = tipc_crypto_start(&tn->crypto_tx, net, NULL);
net/tipc/core.c
77
err = tipc_sk_rht_init(net);
net/tipc/core.c
81
err = tipc_nametbl_init(net);
net/tipc/core.c
85
err = tipc_bcast_init(net);
net/tipc/core.c
89
err = tipc_attach_loopback(net);
net/tipc/core.c
96
tipc_nametbl_stop(net);
net/tipc/core.c
98
tipc_sk_rht_destroy(net);
net/tipc/core.h
150
static inline struct tipc_net *tipc_net(struct net *net)
net/tipc/core.h
152
return net_generic(net, tipc_net_id);
net/tipc/core.h
155
static inline int tipc_netid(struct net *net)
net/tipc/core.h
157
return tipc_net(net)->net_id;
net/tipc/core.h
160
static inline struct list_head *tipc_nodes(struct net *net)
net/tipc/core.h
162
return &tipc_net(net)->node_list;
net/tipc/core.h
165
static inline struct name_table *tipc_name_table(struct net *net)
net/tipc/core.h
167
return tipc_net(net)->nametbl;
net/tipc/core.h
170
static inline struct tipc_topsrv *tipc_topsrv(struct net *net)
net/tipc/core.h
172
return tipc_net(net)->topsrv;
net/tipc/core.h
205
static inline u32 tipc_net_hash_mixes(struct net *net, int tn_rand)
net/tipc/core.h
207
return net_hash_mix(&init_net) ^ net_hash_mix(net) ^ tn_rand;
net/tipc/crypto.c
1039
static int tipc_ehdr_build(struct net *net, struct tipc_aead *aead,
net/tipc/crypto.c
1065
return tipc_crypto_key_revoke(net, tx_key);
net/tipc/crypto.c
1085
memcpy(ehdr->id, tipc_own_id(net), NODE_ID_LEN);
net/tipc/crypto.c
1220
tx = tipc_net(rx->net)->crypto_tx;
net/tipc/crypto.c
1393
struct tipc_crypto *tx = tipc_net(rx->net)->crypto_tx;
net/tipc/crypto.c
1395
u32 self = tipc_own_addr(rx->net);
net/tipc/crypto.c
1448
static int tipc_crypto_key_revoke(struct net *net, u8 tx_key)
net/tipc/crypto.c
1450
struct tipc_crypto *tx = tipc_net(net)->crypto_tx;
net/tipc/crypto.c
1466
int tipc_crypto_start(struct tipc_crypto **crypto, struct net *net,
net/tipc/crypto.c
1498
c->net = net;
net/tipc/crypto.c
1511
tipc_own_id_string(c->net));
net/tipc/crypto.c
1553
struct tipc_net *tn = tipc_net(rx->net);
net/tipc/crypto.c
1647
tipc_crypto_do_cmd(rx->net, cmd);
net/tipc/crypto.c
1650
static inline void tipc_crypto_clone_msg(struct net *net, struct sk_buff *_skb,
net/tipc/crypto.c
1660
tipc_crypto_xmit(net, &skb, b, dst, __dnode);
net/tipc/crypto.c
1662
b->media->send_msg(net, skb, b, dst);
net/tipc/crypto.c
1689
int tipc_crypto_xmit(struct net *net, struct sk_buff **skb,
net/tipc/crypto.c
1694
struct tipc_crypto *tx = tipc_net(net)->crypto_tx;
net/tipc/crypto.c
1721
tipc_crypto_clone_msg(net, *skb, b, dst, __dnode,
net/tipc/crypto.c
1745
tipc_crypto_clone_msg(net, *skb, b, dst,
net/tipc/crypto.c
1763
rc = tipc_ehdr_build(net, aead, tx_key, *skb, __rx);
net/tipc/crypto.c
1814
int tipc_crypto_rcv(struct net *net, struct tipc_crypto *rx,
net/tipc/crypto.c
1817
struct tipc_crypto *tx = tipc_net(net)->crypto_tx;
net/tipc/crypto.c
1853
rc = tipc_aead_decrypt(net, aead, *skb, b);
net/tipc/crypto.c
1893
tipc_crypto_rcv_complete(net, aead, b, skb, rc);
net/tipc/crypto.c
1897
static void tipc_crypto_rcv_complete(struct net *net, struct tipc_aead *aead,
net/tipc/crypto.c
1919
tipc_rcv(net, (*skb)->next, b);
net/tipc/crypto.c
1930
n = tipc_node_create(net, 0, ehdr->id, 0xffffu, 0,
net/tipc/crypto.c
2007
static void tipc_crypto_do_cmd(struct net *net, int cmd)
net/tipc/crypto.c
2009
struct tipc_net *tn = tipc_net(net);
net/tipc/crypto.c
2030
pr_info("TX(%7.7s)\n%s", tipc_own_id_string(net),
net/tipc/crypto.c
204
struct net *net;
net/tipc/crypto.c
2050
j = scnprintf(buf, 200, "TX(%7.7s) ", tipc_own_id_string(net));
net/tipc/crypto.c
2164
void tipc_crypto_msg_rcv(struct net *net, struct sk_buff *skb)
net/tipc/crypto.c
2173
rx = tipc_node_crypto_rx_by_addr(net, msg_prevnode(hdr));
net/tipc/crypto.c
2214
rc = tipc_crypto_key_xmit(tx->net, aead->key,
net/tipc/crypto.c
2238
static int tipc_crypto_key_xmit(struct net *net, struct tipc_aead_key *skey,
net/tipc/crypto.c
2254
tipc_msg_init(tipc_own_addr(net), hdr, MSG_CRYPTO, KEY_DISTR_MSG,
net/tipc/crypto.c
2269
rc = tipc_node_xmit(net, &pkts, dnode, 0);
net/tipc/crypto.c
2271
rc = tipc_bcast_xmit(net, &pkts, &cong_link_cnt);
net/tipc/crypto.c
2289
struct tipc_crypto *tx = tipc_net(rx->net)->crypto_tx;
net/tipc/crypto.c
2359
struct tipc_crypto *tx = tipc_net(rx->net)->crypto_tx;
net/tipc/crypto.c
271
static int tipc_aead_decrypt(struct net *net, struct tipc_aead *aead,
net/tipc/crypto.c
275
static int tipc_ehdr_build(struct net *net, struct tipc_aead *aead,
net/tipc/crypto.c
291
static int tipc_crypto_key_revoke(struct net *net, u8 tx_key);
net/tipc/crypto.c
292
static inline void tipc_crypto_clone_msg(struct net *net, struct sk_buff *_skb,
net/tipc/crypto.c
296
static void tipc_crypto_rcv_complete(struct net *net, struct tipc_aead *aead,
net/tipc/crypto.c
299
static void tipc_crypto_do_cmd(struct net *net, int cmd);
net/tipc/crypto.c
303
static int tipc_crypto_key_xmit(struct net *net, struct tipc_aead_key *skey,
net/tipc/crypto.c
812
if (!maybe_get_net(aead->crypto->net)) {
net/tipc/crypto.c
824
put_net(aead->crypto->net);
net/tipc/crypto.c
839
struct net *net = tx->net;
net/tipc/crypto.c
846
b->media->send_msg(net, skb, b, &tx_ctx->dst);
net/tipc/crypto.c
862
put_net(net);
net/tipc/crypto.c
877
static int tipc_aead_decrypt(struct net *net, struct tipc_aead *aead,
net/tipc/crypto.c
921
salt ^= tipc_own_addr(net);
net/tipc/crypto.c
945
if (!maybe_get_net(net)) {
net/tipc/crypto.c
957
put_net(net);
net/tipc/crypto.c
972
struct net *net = aead->crypto->net;
net/tipc/crypto.c
986
tipc_crypto_rcv_complete(net, aead, b, &skb, err);
net/tipc/crypto.c
989
tipc_rcv(net, skb, b);
net/tipc/crypto.c
995
put_net(net);
net/tipc/crypto.h
159
int tipc_crypto_start(struct tipc_crypto **crypto, struct net *net,
net/tipc/crypto.h
163
int tipc_crypto_xmit(struct net *net, struct sk_buff **skb,
net/tipc/crypto.h
166
int tipc_crypto_rcv(struct net *net, struct tipc_crypto *rx,
net/tipc/crypto.h
173
void tipc_crypto_msg_rcv(struct net *net, struct sk_buff *skb);
net/tipc/diag.c
80
struct net *net = sock_net(skb->sk);
net/tipc/diag.c
91
netlink_dump_start(net->diag_nlsk, skb, h, &c);
net/tipc/discover.c
100
msg_set_peer_net_hash(hdr, tipc_net_hash_mixes(net, tn->random));
net/tipc/discover.c
101
msg_set_node_id(hdr, tipc_own_id(net));
net/tipc/discover.c
104
static void tipc_disc_msg_xmit(struct net *net, u32 mtyp, u32 dst,
net/tipc/discover.c
116
tipc_disc_init_msg(net, skb, mtyp, b);
net/tipc/discover.c
119
tipc_bearer_xmit_skb(net, b->identity, skb, maddr);
net/tipc/discover.c
151
struct net *net = d->net;
net/tipc/discover.c
152
struct tipc_net *tn = tipc_net(net);
net/tipc/discover.c
153
u32 self = tipc_own_addr(net);
net/tipc/discover.c
182
sugg_addr = tipc_node_try_addr(net, peer_id, src);
net/tipc/discover.c
184
tipc_disc_msg_xmit(net, DSC_TRIAL_FAIL_MSG, src,
net/tipc/discover.c
195
void tipc_disc_rcv(struct net *net, struct sk_buff *skb,
net/tipc/discover.c
198
struct tipc_net *tn = tipc_net(net);
net/tipc/discover.c
241
self = tipc_own_addr(net);
net/tipc/discover.c
244
if (in_own_node(net, src)) {
net/tipc/discover.c
252
tipc_node_check_dest(net, src, peer_id, b, caps, signature, pnet_hash,
net/tipc/discover.c
260
tipc_disc_msg_xmit(net, DSC_RESP_MSG, src, self, 0, &maddr, b);
net/tipc/discover.c
298
struct tipc_net *tn = tipc_net(d->net);
net/tipc/discover.c
301
struct net *net = d->net;
net/tipc/discover.c
313
if (!time_before(jiffies, tn->addr_trial_end) && !tipc_own_addr(net)) {
net/tipc/discover.c
340
tipc_bearer_xmit_skb(net, bearer_id, skb, &maddr);
net/tipc/discover.c
352
int tipc_disc_create(struct net *net, struct tipc_bearer *b,
net/tipc/discover.c
355
struct tipc_net *tn = tipc_net(net);
net/tipc/discover.c
366
tipc_disc_init_msg(net, d->skb, DSC_REQ_MSG, b);
net/tipc/discover.c
369
if (!tipc_own_addr(net)) {
net/tipc/discover.c
374
d->net = net;
net/tipc/discover.c
411
void tipc_disc_reset(struct net *net, struct tipc_bearer *b)
net/tipc/discover.c
418
tipc_disc_init_msg(net, d->skb, DSC_REQ_MSG, b);
net/tipc/discover.c
419
d->net = net;
net/tipc/discover.c
429
tipc_bearer_xmit_skb(net, b->identity, skb, &maddr);
net/tipc/discover.c
66
struct net *net;
net/tipc/discover.c
83
static void tipc_disc_init_msg(struct net *net, struct sk_buff *skb,
net/tipc/discover.c
86
struct tipc_net *tn = tipc_net(net);
net/tipc/discover.h
42
int tipc_disc_create(struct net *net, struct tipc_bearer *b_ptr,
net/tipc/discover.h
45
void tipc_disc_reset(struct net *net, struct tipc_bearer *b_ptr);
net/tipc/discover.h
48
void tipc_disc_rcv(struct net *net, struct sk_buff *buf,
net/tipc/group.c
163
struct tipc_group *tipc_group_create(struct net *net, u32 portid,
net/tipc/group.c
175
tipc_nlist_init(&grp->dests, tipc_own_addr(net));
net/tipc/group.c
180
grp->net = net;
net/tipc/group.c
190
if (tipc_topsrv_kern_subscr(net, portid, type, 0, ~0,
net/tipc/group.c
197
void tipc_group_join(struct net *net, struct tipc_group *grp, int *sk_rcvbuf)
net/tipc/group.c
208
tipc_node_distr_xmit(net, &xmitq);
net/tipc/group.c
212
void tipc_group_delete(struct net *net, struct tipc_group *grp)
net/tipc/group.c
226
tipc_node_distr_xmit(net, &xmitq);
net/tipc/group.c
228
tipc_topsrv_kern_unsubscr(net, grp->subid);
net/tipc/group.c
447
tipc_node_distr_xmit(grp->net, &xmitq);
net/tipc/group.c
672
{ u32 dnode = tipc_own_addr(grp->net);
net/tipc/group.c
711
m->node, tipc_own_addr(grp->net),
net/tipc/group.c
754
if (grp->scope == TIPC_NODE_SCOPE && node != tipc_own_addr(grp->net))
net/tipc/group.c
86
struct net *net;
net/tipc/group.c
872
struct net *net;
net/tipc/group.c
878
net = grp->net;
net/tipc/group.c
879
self = tipc_own_addr(net);
net/tipc/group.c
920
if (!tipc_node_is_up(net, node))
net/tipc/group.h
46
struct tipc_group *tipc_group_create(struct net *net, u32 portid,
net/tipc/group.h
49
void tipc_group_join(struct net *net, struct tipc_group *grp, int *sk_rcv_buf);
net/tipc/group.h
50
void tipc_group_delete(struct net *net, struct tipc_group *grp);
net/tipc/link.c
1279
tipc_crypto_msg_rcv(l->net, skb);
net/tipc/link.c
1324
tipc_bcast_lock(l->net);
net/tipc/link.c
1326
tipc_bcast_unlock(l->net);
net/tipc/link.c
140
struct net *net;
net/tipc/link.c
1501
tipc_bcast_lock(bcl->net);
net/tipc/link.c
1505
tipc_bcast_unlock(bcl->net);
net/tipc/link.c
1695
if (((l->rcv_nxt ^ tipc_own_addr(l->net)) & 0xf) != 0xf)
net/tipc/link.c
1742
match2 = tipc_own_addr(l->net) & 0xf;
net/tipc/link.c
1859
l->addr, tipc_own_addr(l->net), 0, 0, 0);
net/tipc/link.c
1889
tipc_mon_prep(l->net, data + glen, &dlen, mstate, l->bearer_id);
net/tipc/link.c
1919
u32 onode = tipc_own_addr(l->net);
net/tipc/link.c
1973
tipc_own_addr(l->net),
net/tipc/link.c
1994
BASIC_H_SIZE, 0, l->addr, tipc_own_addr(l->net),
net/tipc/link.c
2005
tipc_msg_init(tipc_own_addr(l->net), &tnlhdr, TUNNEL_PROTOCOL,
net/tipc/link.c
2201
if (tipc_own_addr(l->net) > msg_prevnode(hdr))
net/tipc/link.c
2220
if (msg_max < tipc_bearer_min_mtu(l->net, l->bearer_id))
net/tipc/link.c
2301
tipc_mon_rcv(l->net, data + glen, dlen - glen, l->addr,
net/tipc/link.c
2343
0, l->addr, tipc_own_addr(l->net), 0, 0, 0);
net/tipc/link.c
2515
if (dnode == tipc_own_addr(l->net)) {
net/tipc/link.c
2669
int __tipc_nl_add_link(struct net *net, struct tipc_nl_msg *msg,
net/tipc/link.c
2672
u32 self = tipc_own_addr(net);
net/tipc/link.c
2789
int tipc_nl_add_bc_link(struct net *net, struct tipc_nl_msg *msg,
net/tipc/link.c
2796
u32 bc_mode = tipc_bcast_get_mode(net);
net/tipc/link.c
2797
u32 bc_ratio = tipc_bcast_get_broadcast_ratio(net);
net/tipc/link.c
2802
tipc_bcast_lock(net);
net/tipc/link.c
2807
tipc_bcast_unlock(net);
net/tipc/link.c
2845
tipc_bcast_unlock(net);
net/tipc/link.c
2856
tipc_bcast_unlock(net);
net/tipc/link.c
353
struct net *tipc_link_net(struct tipc_link *l)
net/tipc/link.c
355
return l->net;
net/tipc/link.c
476
bool tipc_link_create(struct net *net, char *if_name, int bearer_id,
net/tipc/link.c
498
if (tipc_nodeid2string(self_str, tipc_own_id(net)) > NODE_ID_LEN)
net/tipc/link.c
510
l->net = net;
net/tipc/link.c
553
bool tipc_link_bc_create(struct net *net, u32 ownnode, u32 peer, u8 *peer_id,
net/tipc/link.c
562
if (!tipc_link_create(net, "", MAX_BEARERS, 0, 'Z', mtu, 0, min_win,
net/tipc/link.c
591
tipc_bcast_toggle_rcast(net, false);
net/tipc/link.c
834
tipc_mon_get_state(l->net, l->addr, mstate, l->bearer_id);
net/tipc/link.c
883
u32 dnode = tipc_own_addr(l->net);
net/tipc/link.h
128
int __tipc_nl_add_link(struct net *net, struct tipc_nl_msg *msg,
net/tipc/link.h
157
struct net *tipc_link_net(struct tipc_link *l);
net/tipc/link.h
74
bool tipc_link_create(struct net *net, char *if_name, int bearer_id,
net/tipc/link.h
83
bool tipc_link_bc_create(struct net *net, u32 ownnode, u32 peer, u8 *peer_id,
net/tipc/monitor.c
100
static struct tipc_monitor *tipc_monitor(struct net *net, int bearer_id)
net/tipc/monitor.c
102
return tipc_net(net)->monitors[bearer_id];
net/tipc/monitor.c
195
static struct tipc_peer *get_self(struct net *net, int bearer_id)
net/tipc/monitor.c
197
struct tipc_monitor *mon = tipc_monitor(net, bearer_id);
net/tipc/monitor.c
202
static inline bool tipc_mon_is_active(struct net *net, struct tipc_monitor *mon)
net/tipc/monitor.c
204
struct tipc_net *tn = tipc_net(net);
net/tipc/monitor.c
352
void tipc_mon_remove_peer(struct net *net, u32 addr, int bearer_id)
net/tipc/monitor.c
354
struct tipc_monitor *mon = tipc_monitor(net, bearer_id);
net/tipc/monitor.c
361
self = get_self(net, bearer_id);
net/tipc/monitor.c
378
if (!tipc_mon_is_active(net, mon)) {
net/tipc/monitor.c
422
void tipc_mon_peer_up(struct net *net, u32 addr, int bearer_id)
net/tipc/monitor.c
424
struct tipc_monitor *mon = tipc_monitor(net, bearer_id);
net/tipc/monitor.c
425
struct tipc_peer *self = get_self(net, bearer_id);
net/tipc/monitor.c
441
void tipc_mon_peer_down(struct net *net, u32 addr, int bearer_id)
net/tipc/monitor.c
443
struct tipc_monitor *mon = tipc_monitor(net, bearer_id);
net/tipc/monitor.c
452
self = get_self(net, bearer_id);
net/tipc/monitor.c
480
void tipc_mon_rcv(struct net *net, void *data, u16 dlen, u32 addr,
net/tipc/monitor.c
483
struct tipc_monitor *mon = tipc_monitor(net, bearer_id);
net/tipc/monitor.c
566
void tipc_mon_prep(struct net *net, void *data, int *dlen,
net/tipc/monitor.c
569
struct tipc_monitor *mon = tipc_monitor(net, bearer_id);
net/tipc/monitor.c
575
if (!tipc_mon_is_active(net, mon)) {
net/tipc/monitor.c
599
void tipc_mon_get_state(struct net *net, u32 addr,
net/tipc/monitor.c
603
struct tipc_monitor *mon = tipc_monitor(net, bearer_id);
net/tipc/monitor.c
606
if (!tipc_mon_is_active(net, mon)) {
net/tipc/monitor.c
647
int tipc_mon_create(struct net *net, int bearer_id)
net/tipc/monitor.c
649
struct tipc_net *tn = tipc_net(net);
net/tipc/monitor.c
668
mon->net = net;
net/tipc/monitor.c
672
self->addr = tipc_own_addr(net);
net/tipc/monitor.c
682
void tipc_mon_delete(struct net *net, int bearer_id)
net/tipc/monitor.c
684
struct tipc_net *tn = tipc_net(net);
net/tipc/monitor.c
685
struct tipc_monitor *mon = tipc_monitor(net, bearer_id);
net/tipc/monitor.c
692
self = get_self(net, bearer_id);
net/tipc/monitor.c
709
void tipc_mon_reinit_self(struct net *net)
net/tipc/monitor.c
715
mon = tipc_monitor(net, bearer_id);
net/tipc/monitor.c
720
mon->self->addr = tipc_own_addr(net);
net/tipc/monitor.c
725
int tipc_nl_monitor_set_threshold(struct net *net, u32 cluster_size)
net/tipc/monitor.c
727
struct tipc_net *tn = tipc_net(net);
net/tipc/monitor.c
737
int tipc_nl_monitor_get_threshold(struct net *net)
net/tipc/monitor.c
739
struct tipc_net *tn = tipc_net(net);
net/tipc/monitor.c
798
int tipc_nl_add_monitor_peer(struct net *net, struct tipc_nl_msg *msg,
net/tipc/monitor.c
801
struct tipc_monitor *mon = tipc_monitor(net, bearer_id);
net/tipc/monitor.c
827
int __tipc_nl_add_monitor(struct net *net, struct tipc_nl_msg *msg,
net/tipc/monitor.c
830
struct tipc_monitor *mon = tipc_monitor(net, bearer_id);
net/tipc/monitor.c
836
ret = tipc_bearer_get_name(net, bearer_name, bearer_id);
net/tipc/monitor.c
852
if (tipc_mon_is_active(net, mon))
net/tipc/monitor.c
95
struct net *net;
net/tipc/monitor.h
60
int tipc_mon_create(struct net *net, int bearer_id);
net/tipc/monitor.h
61
void tipc_mon_delete(struct net *net, int bearer_id);
net/tipc/monitor.h
63
void tipc_mon_peer_up(struct net *net, u32 addr, int bearer_id);
net/tipc/monitor.h
64
void tipc_mon_peer_down(struct net *net, u32 addr, int bearer_id);
net/tipc/monitor.h
65
void tipc_mon_prep(struct net *net, void *data, int *dlen,
net/tipc/monitor.h
67
void tipc_mon_rcv(struct net *net, void *data, u16 dlen, u32 addr,
net/tipc/monitor.h
69
void tipc_mon_get_state(struct net *net, u32 addr,
net/tipc/monitor.h
72
void tipc_mon_remove_peer(struct net *net, u32 addr, int bearer_id);
net/tipc/monitor.h
74
int tipc_nl_monitor_set_threshold(struct net *net, u32 cluster_size);
net/tipc/monitor.h
75
int tipc_nl_monitor_get_threshold(struct net *net);
net/tipc/monitor.h
76
int __tipc_nl_add_monitor(struct net *net, struct tipc_nl_msg *msg,
net/tipc/monitor.h
78
int tipc_nl_add_monitor_peer(struct net *net, struct tipc_nl_msg *msg,
net/tipc/monitor.h
80
void tipc_mon_reinit_self(struct net *net);
net/tipc/msg.c
713
bool tipc_msg_lookup_dest(struct net *net, struct sk_buff *skb, int *err)
net/tipc/msg.c
717
u32 self = tipc_own_addr(net);
net/tipc/msg.c
736
sk.node = tipc_scope2node(net, scope);
net/tipc/msg.c
737
if (!tipc_nametbl_lookup_anycast(net, &ua, &sk))
net/tipc/msg.c
862
void tipc_skb_reject(struct net *net, int err, struct sk_buff *skb,
net/tipc/msg.c
865
if (tipc_msg_reverse(tipc_own_addr(net), &skb, err))
net/tipc/msg.h
1158
void tipc_skb_reject(struct net *net, int err, struct sk_buff *skb,
net/tipc/msg.h
1175
bool tipc_msg_lookup_dest(struct net *net, struct sk_buff *skb, int *err);
net/tipc/name_distr.c
101
skb = named_prepare_buf(net, PUBLICATION, ITEM_SIZE, 0);
net/tipc/name_distr.c
118
struct sk_buff *tipc_named_withdraw(struct net *net, struct publication *p)
net/tipc/name_distr.c
120
struct name_table *nt = tipc_name_table(net);
net/tipc/name_distr.c
130
skb = named_prepare_buf(net, WITHDRAWAL, ITEM_SIZE, 0);
net/tipc/name_distr.c
150
static void named_distribute(struct net *net, struct sk_buff_head *list,
net/tipc/name_distr.c
156
u32 msg_dsz = ((tipc_node_get_mtu(net, dnode, 0, false) - INT_H_SIZE) /
net/tipc/name_distr.c
164
skb = named_prepare_buf(net, PUBLICATION, msg_rem,
net/tipc/name_distr.c
206
void tipc_named_node_up(struct net *net, u32 dnode, u16 capabilities)
net/tipc/name_distr.c
208
struct name_table *nt = tipc_name_table(net);
net/tipc/name_distr.c
209
struct tipc_net *tn = tipc_net(net);
net/tipc/name_distr.c
221
named_distribute(net, &head, dnode, &nt->cluster_scope, seqno);
net/tipc/name_distr.c
222
tipc_node_xmit(net, &head, dnode, 0);
net/tipc/name_distr.c
235
static void tipc_publ_purge(struct net *net, struct publication *p, u32 addr)
net/tipc/name_distr.c
237
struct tipc_net *tn = tipc_net(net);
net/tipc/name_distr.c
244
_p = tipc_nametbl_remove_publ(net, &ua, &p->sk, p->key);
net/tipc/name_distr.c
246
tipc_node_unsubscribe(net, &_p->binding_node, addr);
net/tipc/name_distr.c
252
void tipc_publ_notify(struct net *net, struct list_head *nsub_list,
net/tipc/name_distr.c
255
struct name_table *nt = tipc_name_table(net);
net/tipc/name_distr.c
256
struct tipc_net *tn = tipc_net(net);
net/tipc/name_distr.c
261
tipc_publ_purge(net, publ, addr);
net/tipc/name_distr.c
279
static bool tipc_update_nametbl(struct net *net, struct distr_item *i,
net/tipc/name_distr.c
302
p = tipc_nametbl_insert_publ(net, &ua, &sk, key);
net/tipc/name_distr.c
304
tipc_node_subscribe(net, &p->binding_node, node);
net/tipc/name_distr.c
308
p = tipc_nametbl_remove_publ(net, &ua, &sk, key);
net/tipc/name_distr.c
310
tipc_node_unsubscribe(net, &p->binding_node, node);
net/tipc/name_distr.c
373
void tipc_named_rcv(struct net *net, struct sk_buff_head *namedq,
net/tipc/name_distr.c
376
struct tipc_net *tn = tipc_net(net);
net/tipc/name_distr.c
389
tipc_update_nametbl(net, item, node, msg_type(hdr));
net/tipc/name_distr.c
405
void tipc_named_reinit(struct net *net)
net/tipc/name_distr.c
407
struct name_table *nt = tipc_name_table(net);
net/tipc/name_distr.c
408
struct tipc_net *tn = tipc_net(net);
net/tipc/name_distr.c
410
u32 self = tipc_own_addr(net);
net/tipc/name_distr.c
67
static struct sk_buff *named_prepare_buf(struct net *net, u32 type, u32 size,
net/tipc/name_distr.c
71
u32 self = tipc_own_addr(net);
net/tipc/name_distr.c
88
struct sk_buff *tipc_named_publish(struct net *net, struct publication *p)
net/tipc/name_distr.c
90
struct name_table *nt = tipc_name_table(net);
net/tipc/name_distr.h
70
struct sk_buff *tipc_named_publish(struct net *net, struct publication *publ);
net/tipc/name_distr.h
71
struct sk_buff *tipc_named_withdraw(struct net *net, struct publication *publ);
net/tipc/name_distr.h
72
void tipc_named_node_up(struct net *net, u32 dnode, u16 capabilities);
net/tipc/name_distr.h
73
void tipc_named_rcv(struct net *net, struct sk_buff_head *namedq,
net/tipc/name_distr.h
75
void tipc_named_reinit(struct net *net);
net/tipc/name_distr.h
76
void tipc_publ_notify(struct net *net, struct list_head *nsub_list,
net/tipc/name_table.c
1052
static int tipc_nl_service_list(struct net *net, struct tipc_nl_msg *msg,
net/tipc/name_table.c
1055
struct tipc_net *tn = tipc_net(net);
net/tipc/name_table.c
1074
service = tipc_service_find(net, &ua);
net/tipc/name_table.c
1104
struct net *net = sock_net(skb->sk);
net/tipc/name_table.c
1120
err = tipc_nl_service_list(net, &msg, &last_type,
net/tipc/name_table.c
257
static struct tipc_service *tipc_service_create(struct net *net,
net/tipc/name_table.c
260
struct name_table *nt = tipc_name_table(net);
net/tipc/name_table.c
330
static bool tipc_service_insert_publ(struct net *net,
net/tipc/name_table.c
360
if (in_own_node(net, p->sk.node))
net/tipc/name_table.c
463
static struct tipc_service *tipc_service_find(struct net *net,
net/tipc/name_table.c
466
struct name_table *nt = tipc_name_table(net);
net/tipc/name_table.c
478
struct publication *tipc_nametbl_insert_publ(struct net *net,
net/tipc/name_table.c
490
sc = tipc_service_find(net, ua);
net/tipc/name_table.c
492
sc = tipc_service_create(net, ua);
net/tipc/name_table.c
493
if (sc && tipc_service_insert_publ(net, sc, p))
net/tipc/name_table.c
499
struct publication *tipc_nametbl_remove_publ(struct net *net,
net/tipc/name_table.c
510
sc = tipc_service_find(net, ua);
net/tipc/name_table.c
571
bool tipc_nametbl_lookup_anycast(struct net *net,
net/tipc/name_table.c
575
struct tipc_net *tn = tipc_net(net);
net/tipc/name_table.c
577
u32 self = tipc_own_addr(net);
net/tipc/name_table.c
589
sc = tipc_service_find(net, ua);
net/tipc/name_table.c
630
bool tipc_nametbl_lookup_group(struct net *net, struct tipc_uaddr *ua,
net/tipc/name_table.c
634
u32 self = tipc_own_addr(net);
net/tipc/name_table.c
642
sc = tipc_service_find(net, ua);
net/tipc/name_table.c
677
void tipc_nametbl_lookup_mcast_sockets(struct net *net, struct tipc_uaddr *ua,
net/tipc/name_table.c
686
sc = tipc_service_find(net, ua);
net/tipc/name_table.c
707
void tipc_nametbl_lookup_mcast_nodes(struct net *net, struct tipc_uaddr *ua,
net/tipc/name_table.c
715
sc = tipc_service_find(net, ua);
net/tipc/name_table.c
732
void tipc_nametbl_build_group(struct net *net, struct tipc_group *grp,
net/tipc/name_table.c
741
sc = tipc_service_find(net, ua);
net/tipc/name_table.c
762
struct publication *tipc_nametbl_publish(struct net *net, struct tipc_uaddr *ua,
net/tipc/name_table.c
765
struct name_table *nt = tipc_name_table(net);
net/tipc/name_table.c
766
struct tipc_net *tn = tipc_net(net);
net/tipc/name_table.c
778
p = tipc_nametbl_insert_publ(net, ua, sk, key);
net/tipc/name_table.c
781
skb = tipc_named_publish(net, p);
net/tipc/name_table.c
788
tipc_node_broadcast(net, skb, rc_dests);
net/tipc/name_table.c
800
void tipc_nametbl_withdraw(struct net *net, struct tipc_uaddr *ua,
net/tipc/name_table.c
803
struct name_table *nt = tipc_name_table(net);
net/tipc/name_table.c
804
struct tipc_net *tn = tipc_net(net);
net/tipc/name_table.c
811
p = tipc_nametbl_remove_publ(net, ua, sk, key);
net/tipc/name_table.c
814
skb = tipc_named_withdraw(net, p);
net/tipc/name_table.c
822
tipc_node_broadcast(net, skb, rc_dests);
net/tipc/name_table.c
831
struct tipc_net *tn = tipc_net(sub->net);
net/tipc/name_table.c
840
sc = tipc_service_find(sub->net, &ua);
net/tipc/name_table.c
842
sc = tipc_service_create(sub->net, &ua);
net/tipc/name_table.c
862
struct tipc_net *tn = tipc_net(sub->net);
net/tipc/name_table.c
869
sc = tipc_service_find(sub->net, &ua);
net/tipc/name_table.c
887
int tipc_nametbl_init(struct net *net)
net/tipc/name_table.c
889
struct tipc_net *tn = tipc_net(net);
net/tipc/name_table.c
913
static void tipc_service_delete(struct net *net, struct tipc_service *sc)
net/tipc/name_table.c
932
void tipc_nametbl_stop(struct net *net)
net/tipc/name_table.c
934
struct name_table *nt = tipc_name_table(net);
net/tipc/name_table.c
935
struct tipc_net *tn = tipc_net(net);
net/tipc/name_table.c
949
tipc_service_delete(net, service);
net/tipc/name_table.h
117
bool tipc_nametbl_lookup_anycast(struct net *net, struct tipc_uaddr *ua,
net/tipc/name_table.h
119
void tipc_nametbl_lookup_mcast_sockets(struct net *net, struct tipc_uaddr *ua,
net/tipc/name_table.h
121
void tipc_nametbl_lookup_mcast_nodes(struct net *net, struct tipc_uaddr *ua,
net/tipc/name_table.h
123
bool tipc_nametbl_lookup_group(struct net *net, struct tipc_uaddr *ua,
net/tipc/name_table.h
126
void tipc_nametbl_build_group(struct net *net, struct tipc_group *grp,
net/tipc/name_table.h
128
struct publication *tipc_nametbl_publish(struct net *net, struct tipc_uaddr *ua,
net/tipc/name_table.h
130
void tipc_nametbl_withdraw(struct net *net, struct tipc_uaddr *ua,
net/tipc/name_table.h
132
struct publication *tipc_nametbl_insert_publ(struct net *net,
net/tipc/name_table.h
136
struct publication *tipc_nametbl_remove_publ(struct net *net,
net/tipc/name_table.h
142
int tipc_nametbl_init(struct net *net);
net/tipc/name_table.h
143
void tipc_nametbl_stop(struct net *net);
net/tipc/net.c
109
static void tipc_net_finalize(struct net *net, u32 addr);
net/tipc/net.c
111
int tipc_net_init(struct net *net, u8 *node_id, u32 addr)
net/tipc/net.c
113
if (tipc_own_id(net)) {
net/tipc/net.c
120
tipc_set_node_id(net, node_id);
net/tipc/net.c
122
tipc_net_finalize(net, addr);
net/tipc/net.c
126
static void tipc_net_finalize(struct net *net, u32 addr)
net/tipc/net.c
128
struct tipc_net *tn = tipc_net(net);
net/tipc/net.c
137
tipc_set_node_addr(net, addr);
net/tipc/net.c
138
tipc_named_reinit(net);
net/tipc/net.c
139
tipc_sk_reinit(net);
net/tipc/net.c
140
tipc_mon_reinit_self(net);
net/tipc/net.c
141
tipc_nametbl_publish(net, &ua, &sk, addr);
net/tipc/net.c
153
void tipc_net_stop(struct net *net)
net/tipc/net.c
155
if (!tipc_own_id(net))
net/tipc/net.c
159
tipc_bearer_stop(net);
net/tipc/net.c
160
tipc_node_stop(net);
net/tipc/net.c
166
static int __tipc_nl_add_net(struct net *net, struct tipc_nl_msg *msg)
net/tipc/net.c
168
struct tipc_net *tn = net_generic(net, tipc_net_id);
net/tipc/net.c
204
struct net *net = sock_net(skb->sk);
net/tipc/net.c
216
err = __tipc_nl_add_net(net, &msg);
net/tipc/net.c
230
struct net *net = sock_net(skb->sk);
net/tipc/net.c
231
struct tipc_net *tn = tipc_net(net);
net/tipc/net.c
245
if (tipc_own_addr(net))
net/tipc/net.c
265
tipc_net_init(net, NULL, addr);
net/tipc/net.c
277
tipc_net_init(net, node_id, 0);
net/tipc/net.c
293
static int __tipc_nl_addr_legacy_get(struct net *net, struct tipc_nl_msg *msg)
net/tipc/net.c
295
struct tipc_net *tn = tipc_net(net);
net/tipc/net.c
327
struct net *net = sock_net(skb->sk);
net/tipc/net.c
340
err = __tipc_nl_addr_legacy_get(net, &msg);
net/tipc/net.h
44
int tipc_net_init(struct net *net, u8 *node_id, u32 addr);
net/tipc/net.h
46
void tipc_net_stop(struct net *net);
net/tipc/netlink_compat.c
1140
struct nlattr *net;
net/tipc/netlink_compat.c
1144
net = nla_nest_start_noflag(skb, TIPC_NLA_NET);
net/tipc/netlink_compat.c
1145
if (!net)
net/tipc/netlink_compat.c
1155
nla_nest_end(skb, net);
net/tipc/netlink_compat.c
1164
struct nlattr *net[TIPC_NLA_NET_MAX + 1];
net/tipc/netlink_compat.c
1170
err = nla_parse_nested_deprecated(net, TIPC_NLA_NET_MAX,
net/tipc/netlink_compat.c
1175
id = htonl(nla_get_u32(net[TIPC_NLA_NET_ID]));
net/tipc/netlink_compat.c
1306
msg.net = genl_info_net(info);
net/tipc/netlink_compat.c
1336
genlmsg_unicast(msg.net, msg.rep, NETLINK_CB(skb).portid);
net/tipc/netlink_compat.c
200
if (__tipc_dump_start(&cb, msg->net)) {
net/tipc/netlink_compat.c
60
struct net *net;
net/tipc/netlink_compat.c
829
bearer = tipc_bearer_find(msg->net, lc->name);
net/tipc/node.c
1006
tipc_bearer_remove_dest(n->net, *bearer_id, n->addr);
net/tipc/node.c
1042
tipc_bcast_dec_bearer_dst_cnt(n->net, *bearer_id);
net/tipc/node.c
1045
tipc_bcast_dec_bearer_dst_cnt(n->net, *bearer_id);
net/tipc/node.c
1091
tipc_mon_remove_peer(n->net, n->addr, old_bearer_id);
net/tipc/node.c
1093
tipc_bearer_xmit(n->net, bearer_id, &xmitq, maddr, n);
net/tipc/node.c
1094
tipc_sk_rcv(n->net, &le->inputq);
net/tipc/node.c
1102
bool tipc_node_is_up(struct net *net, u32 addr)
net/tipc/node.c
1107
if (in_own_node(net, addr))
net/tipc/node.c
1110
n = tipc_node_find(net, addr);
net/tipc/node.c
1118
static u32 tipc_node_suggest_addr(struct net *net, u32 addr)
net/tipc/node.c
1122
addr ^= tipc_net(net)->random;
net/tipc/node.c
1123
while ((n = tipc_node_find(net, addr))) {
net/tipc/node.c
1133
u32 tipc_node_try_addr(struct net *net, u8 *id, u32 addr)
net/tipc/node.c
1135
struct tipc_net *tn = tipc_net(net);
net/tipc/node.c
1141
n = tipc_node_find(net, addr);
net/tipc/node.c
1148
return tipc_node_suggest_addr(net, addr);
net/tipc/node.c
1152
n = tipc_node_find_by_id(net, id);
net/tipc/node.c
1163
return tipc_node_suggest_addr(net, addr);
net/tipc/node.c
1168
void tipc_node_check_dest(struct net *net, u32 addr,
net/tipc/node.c
119
struct net *net;
net/tipc/node.c
1190
n = tipc_node_create(net, addr, peer_id, capabilities, hash_mixes,
net/tipc/node.c
1279
if (!tipc_link_create(net, if_name, b->identity, b->tolerance,
net/tipc/node.c
1282
tipc_own_addr(net), addr, peer_id,
net/tipc/node.c
1284
tipc_bc_sndlink(n->net), n->bc_entry.link,
net/tipc/node.c
1313
void tipc_node_delete_links(struct net *net, int bearer_id)
net/tipc/node.c
1315
struct tipc_net *tn = net_generic(net, tipc_net_id);
net/tipc/node.c
143
struct net *peer_net;
net/tipc/node.c
1530
tipc_bcast_remove_peer(n->net, n->bc_entry.link);
net/tipc/node.c
1547
SHORT_H_SIZE, 0, tipc_own_addr(n->net),
net/tipc/node.c
1568
int tipc_node_get_linkname(struct net *net, u32 bearer_id, u32 addr,
net/tipc/node.c
1573
struct tipc_node *node = tipc_node_find(net, addr);
net/tipc/node.c
1627
static void tipc_lxc_xmit(struct net *peer_net, struct sk_buff_head *list)
net/tipc/node.c
1687
int tipc_node_xmit(struct net *net, struct sk_buff_head *list,
net/tipc/node.c
1694
struct net *peer_net;
net/tipc/node.c
1698
if (in_own_node(net, dnode)) {
net/tipc/node.c
1699
tipc_loopback_trace(net, list);
net/tipc/node.c
1701
tipc_sk_rcv(net, list);
net/tipc/node.c
1705
n = tipc_node_find(net, dnode);
net/tipc/node.c
1746
tipc_bearer_xmit(net, bearer_id, &xmitq, &le->maddr, n);
net/tipc/node.c
1759
int tipc_node_xmit_skb(struct net *net, struct sk_buff *skb, u32 dnode,
net/tipc/node.c
1766
tipc_node_xmit(net, &head, dnode, selector);
net/tipc/node.c
1773
int tipc_node_distr_xmit(struct net *net, struct sk_buff_head *xmitq)
net/tipc/node.c
1781
tipc_node_xmit_skb(net, skb, dnode, selector);
net/tipc/node.c
1786
void tipc_node_broadcast(struct net *net, struct sk_buff *skb, int rc_dests)
net/tipc/node.c
1795
if (!rc_dests && tipc_bcast_get_mode(net) != BCLINK_MODE_RCAST) {
net/tipc/node.c
1798
tipc_bcast_xmit(net, &xmitq, &dummy);
net/tipc/node.c
1804
list_for_each_entry_rcu(n, tipc_nodes(net), list) {
net/tipc/node.c
1806
if (in_own_node(net, dst))
net/tipc/node.c
1814
tipc_node_xmit_skb(net, txskb, dst, 0);
net/tipc/node.c
183
static struct tipc_node *tipc_node_find(struct net *net, u32 addr);
net/tipc/node.c
1830
tipc_sk_mcast_rcv(n->net, &be->arrvq, &be->inputq2);
net/tipc/node.c
184
static struct tipc_node *tipc_node_find_by_id(struct net *net, u8 *id);
net/tipc/node.c
1840
rc = tipc_bcast_sync_rcv(n->net, n->bc_entry.link, hdr, xmitq, valid);
net/tipc/node.c
1872
static void tipc_node_bc_rcv(struct net *net, struct sk_buff *skb, int bearer_id)
net/tipc/node.c
1886
if ((usr == BCAST_PROTOCOL) && (dnode != tipc_own_addr(net)))
net/tipc/node.c
1887
n = tipc_node_find(net, dnode);
net/tipc/node.c
1889
n = tipc_node_find(net, msg_prevnode(hdr));
net/tipc/node.c
1897
rc = tipc_bcast_rcv(net, be->link, skb);
net/tipc/node.c
1907
tipc_bearer_xmit(net, bearer_id, &xmitq, &le->maddr, n);
net/tipc/node.c
1914
tipc_named_rcv(net, &n->bc_entry.namedq,
net/tipc/node.c
205
int tipc_node_get_mtu(struct net *net, u32 addr, u32 sel, bool connected)
net/tipc/node.c
2086
void tipc_rcv(struct net *net, struct sk_buff *skb, struct tipc_bearer *b)
net/tipc/node.c
2093
u32 self = tipc_own_addr(net);
net/tipc/node.c
2105
n = tipc_node_find(net, ntohl(ehdr->addr));
net/tipc/node.c
2109
n = tipc_node_find_by_id(net, ehdr->id);
net/tipc/node.c
211
n = tipc_node_find(net, addr);
net/tipc/node.c
2112
tipc_crypto_rcv(net, (n) ? n->crypto_rx : NULL, &skb, b);
net/tipc/node.c
2129
return tipc_disc_rcv(net, skb, b);
net/tipc/node.c
2131
return tipc_node_bc_rcv(net, skb, bearer_id);
net/tipc/node.c
2139
n = tipc_node_find(net, msg_prevnode(hdr));
net/tipc/node.c
2159
tipc_bcast_ack_rcv(net, n->bc_entry.link, hdr);
net/tipc/node.c
2195
tipc_named_rcv(net, &n->bc_entry.namedq,
net/tipc/node.c
2203
tipc_sk_rcv(net, &le->inputq);
net/tipc/node.c
2206
tipc_bearer_xmit(net, bearer_id, &xmitq, &le->maddr, n);
net/tipc/node.c
2214
void tipc_node_apply_property(struct net *net, struct tipc_bearer *b,
net/tipc/node.c
2217
struct tipc_net *tn = tipc_net(net);
net/tipc/node.c
2242
tipc_bearer_xmit(net, bearer_id, &xmitq, &e->maddr, NULL);
net/tipc/node.c
2250
struct net *net = sock_net(skb->sk);
net/tipc/node.c
2251
struct tipc_net *tn = net_generic(net, tipc_net_id);
net/tipc/node.c
2287
if (in_own_node(net, addr))
net/tipc/node.c
2291
peer = tipc_node_find(net, addr);
net/tipc/node.c
230
bool tipc_node_get_id(struct net *net, u32 addr, u8 *id)
net/tipc/node.c
2314
tipc_bcast_toggle_rcast(net, (tn->capabilities & TIPC_BCAST_RCAST));
net/tipc/node.c
232
u8 *own_id = tipc_own_id(net);
net/tipc/node.c
2326
struct net *net = sock_net(skb->sk);
net/tipc/node.c
2327
struct tipc_net *tn = net_generic(net, tipc_net_id);
net/tipc/node.c
2342
node = tipc_node_find(net, last_addr);
net/tipc/node.c
238
if (addr == tipc_own_addr(net)) {
net/tipc/node.c
2394
static struct tipc_node *tipc_node_find_by_name(struct net *net,
net/tipc/node.c
2398
struct tipc_net *tn = net_generic(net, tipc_net_id);
net/tipc/node.c
242
n = tipc_node_find(net, addr);
net/tipc/node.c
2435
struct net *net = sock_net(skb->sk);
net/tipc/node.c
2454
return tipc_nl_bc_link_set(net, attrs);
net/tipc/node.c
2456
node = tipc_node_find_by_name(net, name, &bearer_id);
net/tipc/node.c
2501
tipc_bearer_xmit(net, bearer_id, &xmitq, &node->links[bearer_id].maddr,
net/tipc/node.c
2508
struct net *net = genl_info_net(info);
net/tipc/node.c
251
u16 tipc_node_get_capabilities(struct net *net, u32 addr)
net/tipc/node.c
2536
err = tipc_nl_add_bc_link(net, &msg, tipc_net(net)->bcl);
net/tipc/node.c
2544
node = tipc_node_find_by_name(net, name, &bearer_id);
net/tipc/node.c
2558
err = __tipc_nl_add_link(net, &msg, link, 0);
net/tipc/node.c
256
n = tipc_node_find(net, addr);
net/tipc/node.c
2579
struct net *net = sock_net(skb->sk);
net/tipc/node.c
2580
struct tipc_net *tn = tipc_net(net);
net/tipc/node.c
2599
err = tipc_bclink_reset_stats(net, tipc_bc_sndlink(net));
net/tipc/node.c
2609
err = tipc_bclink_reset_stats(net, link);
net/tipc/node.c
2619
node = tipc_node_find_by_name(net, link_name, &bearer_id);
net/tipc/node.c
2639
static int __tipc_nl_add_node_links(struct net *net, struct tipc_nl_msg *msg,
net/tipc/node.c
2652
err = __tipc_nl_add_link(net, msg,
net/tipc/node.c
2660
err = tipc_nl_add_bc_link(net, msg, node->bc_entry.link);
net/tipc/node.c
2672
struct net *net = sock_net(skb->sk);
net/tipc/node.c
2675
struct tipc_net *tn = net_generic(net, tipc_net_id);
net/tipc/node.c
2709
node = tipc_node_find(net, prev_node);
net/tipc/node.c
2725
err = __tipc_nl_add_node_links(net, &msg, node,
net/tipc/node.c
2734
err = tipc_nl_add_bc_link(net, &msg, tn->bcl);
net/tipc/node.c
2740
err = __tipc_nl_add_node_links(net, &msg, node,
net/tipc/node.c
2764
struct net *net = sock_net(skb->sk);
net/tipc/node.c
2781
err = tipc_nl_monitor_set_threshold(net, val);
net/tipc/node.c
2789
static int __tipc_nl_add_monitor_prop(struct net *net, struct tipc_nl_msg *msg)
net/tipc/node.c
2804
val = tipc_nl_monitor_get_threshold(net);
net/tipc/node.c
2824
struct net *net = sock_net(skb->sk);
net/tipc/node.c
2834
err = __tipc_nl_add_monitor_prop(net, &msg);
net/tipc/node.c
2845
struct net *net = sock_net(skb->sk);
net/tipc/node.c
2860
err = __tipc_nl_add_monitor(net, &msg, bearer_id);
net/tipc/node.c
2873
struct net *net = sock_net(skb->sk);
net/tipc/node.c
290
struct tipc_crypto *tipc_node_crypto_rx_by_addr(struct net *net, u32 addr)
net/tipc/node.c
2911
err = tipc_nl_add_monitor_peer(net, &msg, bearer_id, &prev_node);
net/tipc/node.c
294
n = tipc_node_find(net, addr);
net/tipc/node.c
2972
struct net *net = sock_net(skb->sk);
net/tipc/node.c
2973
struct tipc_crypto *tx = tipc_net(net)->crypto_tx, *c = tx;
net/tipc/node.c
2990
own_id = tipc_own_id(net);
net/tipc/node.c
3019
n = tipc_node_find_by_id(net, id) ?:
net/tipc/node.c
3020
tipc_node_create(net, 0, id, 0xffffu, 0, true);
net/tipc/node.c
3064
struct net *net = sock_net(skb->sk);
net/tipc/node.c
3065
struct tipc_net *tn = tipc_net(net);
net/tipc/node.c
3146
void tipc_node_pre_cleanup_net(struct net *exit_net)
net/tipc/node.c
3150
struct net *tmp;
net/tipc/node.c
330
static struct tipc_node *tipc_node_find(struct net *net, u32 addr)
net/tipc/node.c
332
struct tipc_net *tn = tipc_net(net);
net/tipc/node.c
352
static struct tipc_node *tipc_node_find_by_id(struct net *net, u8 *id)
net/tipc/node.c
354
struct tipc_net *tn = tipc_net(net);
net/tipc/node.c
400
struct net *net = n->net;
net/tipc/node.c
414
sk.node = tipc_own_addr(net);
net/tipc/node.c
425
tipc_publ_notify(net, publ_list, node, n->capabilities);
net/tipc/node.c
428
tipc_named_node_up(net, node, n->capabilities);
net/tipc/node.c
431
tipc_mon_peer_up(net, node, bearer_id);
net/tipc/node.c
432
tipc_nametbl_publish(net, &ua, &sk, sk.ref);
net/tipc/node.c
435
tipc_mon_peer_down(net, node, bearer_id);
net/tipc/node.c
436
tipc_nametbl_withdraw(net, &ua, &sk, sk.ref);
net/tipc/node.c
442
int net_id = tipc_netid(n->net);
net/tipc/node.c
444
struct net *tmp;
net/tipc/node.c
468
struct tipc_node *tipc_node_create(struct net *net, u32 addr, u8 *peer_id,
net/tipc/node.c
472
struct tipc_net *tn = net_generic(net, tipc_net_id);
net/tipc/node.c
473
struct tipc_link *l, *snd_l = tipc_bc_sndlink(net);
net/tipc/node.c
480
n = tipc_node_find(net, addr) ?:
net/tipc/node.c
481
tipc_node_find_by_id(net, peer_id);
net/tipc/node.c
489
if (!tipc_link_bc_create(net, tipc_own_addr(net), addr, peer_id, U16_MAX,
net/tipc/node.c
533
tipc_bcast_toggle_rcast(net,
net/tipc/node.c
545
if (unlikely(tipc_crypto_start(&n->crypto_rx, net, n))) {
net/tipc/node.c
555
n->net = net;
net/tipc/node.c
579
!tipc_link_bc_create(net, tipc_own_addr(net), addr, peer_id, U16_MAX,
net/tipc/node.c
606
tipc_bcast_toggle_rcast(net, (tn->capabilities & TIPC_BCAST_RCAST));
net/tipc/node.c
645
void tipc_node_stop(struct net *net)
net/tipc/node.c
647
struct tipc_net *tn = tipc_net(net);
net/tipc/node.c
656
void tipc_node_subscribe(struct net *net, struct list_head *subscr, u32 addr)
net/tipc/node.c
660
if (in_own_node(net, addr))
net/tipc/node.c
663
n = tipc_node_find(net, addr);
net/tipc/node.c
674
void tipc_node_unsubscribe(struct net *net, struct list_head *subscr, u32 addr)
net/tipc/node.c
678
if (in_own_node(net, addr))
net/tipc/node.c
681
n = tipc_node_find(net, addr);
net/tipc/node.c
692
int tipc_node_add_conn(struct net *net, u32 dnode, u32 port, u32 peer_port)
net/tipc/node.c
698
if (in_own_node(net, dnode))
net/tipc/node.c
701
node = tipc_node_find(net, dnode);
net/tipc/node.c
723
void tipc_node_remove_conn(struct net *net, u32 dnode, u32 port)
net/tipc/node.c
728
if (in_own_node(net, dnode))
net/tipc/node.c
731
node = tipc_node_find(net, dnode);
net/tipc/node.c
767
struct tipc_net *tn = tipc_net(peer->net);
net/tipc/node.c
793
tipc_bcast_toggle_rcast(peer->net,
net/tipc/node.c
841
tipc_bearer_xmit(n->net, bearer_id, &xmitq, &le->maddr, n);
net/tipc/node.c
878
tipc_bearer_add_dest(n->net, bearer_id, n->addr);
net/tipc/node.c
879
tipc_bcast_inc_bearer_dst_cnt(n->net, bearer_id);
net/tipc/node.c
895
tipc_bcast_add_peer(n->net, nl, xmitq);
net/tipc/node.c
933
tipc_bearer_xmit(n->net, bearer_id, xmitq, maddr, n);
net/tipc/node.h
101
int tipc_node_xmit(struct net *net, struct sk_buff_head *list, u32 dnode,
net/tipc/node.h
103
int tipc_node_distr_xmit(struct net *net, struct sk_buff_head *list);
net/tipc/node.h
104
int tipc_node_xmit_skb(struct net *net, struct sk_buff *skb, u32 dest,
net/tipc/node.h
106
void tipc_node_subscribe(struct net *net, struct list_head *subscr, u32 addr);
net/tipc/node.h
107
void tipc_node_unsubscribe(struct net *net, struct list_head *subscr, u32 addr);
net/tipc/node.h
108
void tipc_node_broadcast(struct net *net, struct sk_buff *skb, int rc_dests);
net/tipc/node.h
109
int tipc_node_add_conn(struct net *net, u32 dnode, u32 port, u32 peer_port);
net/tipc/node.h
110
void tipc_node_remove_conn(struct net *net, u32 dnode, u32 port);
net/tipc/node.h
111
int tipc_node_get_mtu(struct net *net, u32 addr, u32 sel, bool connected);
net/tipc/node.h
112
bool tipc_node_is_up(struct net *net, u32 addr);
net/tipc/node.h
113
u16 tipc_node_get_capabilities(struct net *net, u32 addr);
net/tipc/node.h
130
void tipc_node_pre_cleanup_net(struct net *exit_net);
net/tipc/node.h
77
void tipc_node_stop(struct net *net);
net/tipc/node.h
78
bool tipc_node_get_id(struct net *net, u32 addr, u8 *id);
net/tipc/node.h
83
struct tipc_node *tipc_node_create(struct net *net, u32 addr, u8 *peer_id,
net/tipc/node.h
89
struct tipc_crypto *tipc_node_crypto_rx_by_addr(struct net *net, u32 addr);
net/tipc/node.h
91
u32 tipc_node_try_addr(struct net *net, u8 *id, u32 addr);
net/tipc/node.h
92
void tipc_node_check_dest(struct net *net, u32 onode, u8 *peer_id128,
net/tipc/node.h
97
void tipc_node_delete_links(struct net *net, int bearer_id);
net/tipc/node.h
98
void tipc_node_apply_property(struct net *net, struct tipc_bearer *b, int prop);
net/tipc/node.h
99
int tipc_node_get_linkname(struct net *net, u32 bearer_id, u32 node,
net/tipc/socket.c
1012
struct net *net = sock_net(sk);
net/tipc/socket.c
1029
if (!tipc_nametbl_lookup_group(net, ua, &dsts, &dstcnt,
net/tipc/socket.c
1067
rc = tipc_send_group_msg(net, tsk, m, mbr, node, port, dlen);
net/tipc/socket.c
1087
struct net *net = sock_net(sk);
net/tipc/socket.c
1094
int mtu = tipc_bcast_get_mtu(net);
net/tipc/socket.c
1132
rc = tipc_mcast_xmit(net, &pkts, method, dsts, &tsk->cong_link_cnt);
net/tipc/socket.c
1164
struct net *net = sock_net(sk);
net/tipc/socket.c
1172
if (!tipc_nametbl_lookup_group(net, ua, &dsts, &dstcnt, exclude, true))
net/tipc/socket.c
1192
void tipc_sk_mcast_rcv(struct net *net, struct sk_buff_head *arrvq,
net/tipc/socket.c
1195
u32 self = tipc_own_addr(net);
net/tipc/socket.c
1243
tipc_nametbl_lookup_mcast_sockets(net, &ua, &dports);
net/tipc/socket.c
1266
tipc_sk_rcv(net, inputq);
net/tipc/socket.c
1276
struct net *net = sock_net(&tsk->sk);
net/tipc/socket.c
1314
rc = tipc_node_xmit(net, txq, dnode, tsk->portid);
net/tipc/socket.c
1413
struct net *net = sock_net(sk);
net/tipc/socket.c
1474
if (!tipc_nametbl_lookup_anycast(net, ua, &skaddr))
net/tipc/socket.c
1505
mtu = tipc_node_get_mtu(net, skaddr.node, tsk->portid, true);
net/tipc/socket.c
1516
rc = tipc_node_xmit(net, &pkts, skaddr.node, tsk->portid);
net/tipc/socket.c
154
static struct tipc_sock *tipc_sk_lookup(struct net *net, u32 portid);
net/tipc/socket.c
1565
struct net *net = sock_net(sk);
net/tipc/socket.c
1580
tsk->peer_caps = tipc_node_get_capabilities(net, dnode);
net/tipc/socket.c
1627
rc = tipc_node_xmit(net, txq, dnode, tsk->portid);
net/tipc/socket.c
1666
struct net *net = sock_net(sk);
net/tipc/socket.c
1678
tipc_node_add_conn(net, peer_node, tsk->portid, peer_port);
net/tipc/socket.c
1679
tsk->max_pkt = tipc_node_get_mtu(net, peer_node, tsk->portid, true);
net/tipc/socket.c
1680
tsk->peer_caps = tipc_node_get_capabilities(net, peer_node);
net/tipc/socket.c
2199
struct net *net = sock_net(sk);
net/tipc/socket.c
2253
tipc_node_get_capabilities(net, onode) & TIPC_SYN_BIT)
net/tipc/socket.c
2280
tipc_node_remove_conn(net, pnode, tsk->portid);
net/tipc/socket.c
2346
struct net *net = sock_net(sk);
net/tipc/socket.c
2363
tipc_mcast_filter_msg(net, &tsk->mc_method.deferredq, &inputq);
net/tipc/socket.c
2381
if (tipc_msg_reverse(tipc_own_addr(net), &skb, err)) {
net/tipc/socket.c
2485
void tipc_sk_rcv(struct net *net, struct sk_buff_head *inputq)
net/tipc/socket.c
2497
tsk = tipc_sk_lookup(net, dport);
net/tipc/socket.c
2517
if (tipc_msg_lookup_dest(net, skb, &err))
net/tipc/socket.c
2521
if (!tipc_msg_reverse(tipc_own_addr(net), &skb, err))
net/tipc/socket.c
2527
tipc_node_xmit_skb(net, skb, dnode, dport);
net/tipc/socket.c
2910
struct net *net = sock_net(sk);
net/tipc/socket.c
2921
skaddr.node = tipc_own_addr(net);
net/tipc/socket.c
2922
p = tipc_nametbl_publish(net, ua, &skaddr, key);
net/tipc/socket.c
2934
struct net *net = sock_net(&tsk->sk);
net/tipc/socket.c
2943
tipc_nametbl_withdraw(net, &_ua, &p->sk, p->key);
net/tipc/socket.c
2955
tipc_nametbl_withdraw(net, ua, &p->sk, p->key);
net/tipc/socket.c
2969
void tipc_sk_reinit(struct net *net)
net/tipc/socket.c
2971
struct tipc_net *tn = net_generic(net, tipc_net_id);
net/tipc/socket.c
2986
msg_set_prevnode(msg, tipc_own_addr(net));
net/tipc/socket.c
2987
msg_set_orignode(msg, tipc_own_addr(net));
net/tipc/socket.c
2999
static struct tipc_sock *tipc_sk_lookup(struct net *net, u32 portid)
net/tipc/socket.c
3001
struct tipc_net *tn = net_generic(net, tipc_net_id);
net/tipc/socket.c
3016
struct net *net = sock_net(sk);
net/tipc/socket.c
3017
struct tipc_net *tn = net_generic(net, tipc_net_id);
net/tipc/socket.c
3055
int tipc_sk_rht_init(struct net *net)
net/tipc/socket.c
3057
struct tipc_net *tn = net_generic(net, tipc_net_id);
net/tipc/socket.c
3062
void tipc_sk_rht_destroy(struct net *net)
net/tipc/socket.c
3064
struct tipc_net *tn = net_generic(net, tipc_net_id);
net/tipc/socket.c
3074
struct net *net = sock_net(&tsk->sk);
net/tipc/socket.c
3088
grp = tipc_group_create(net, tsk->portid, mreq, &tsk->group_is_open);
net/tipc/socket.c
3097
tipc_nametbl_build_group(net, grp, &ua);
net/tipc/socket.c
3100
tipc_group_delete(net, grp);
net/tipc/socket.c
3107
tipc_group_join(net, grp, &tsk->sk.sk_rcvbuf);
net/tipc/socket.c
3113
struct net *net = sock_net(&tsk->sk);
net/tipc/socket.c
3123
tipc_group_delete(net, grp);
net/tipc/socket.c
3305
struct net *net = sock_net(sock->sk);
net/tipc/socket.c
3314
if (!tipc_node_get_linkname(net,
net/tipc/socket.c
3325
if (!tipc_node_get_id(net, nr.peer, nr.node_id))
net/tipc/socket.c
3507
struct net *net = sock_net(skb->sk);
net/tipc/socket.c
3511
nla_put_u32(skb, TIPC_NLA_SOCK_ADDR, tipc_own_addr(net)))
net/tipc/socket.c
3598
int __tipc_dump_start(struct netlink_callback *cb, struct net *net)
net/tipc/socket.c
3602
struct tipc_net *tn = tipc_net(net);
net/tipc/socket.c
3786
struct net *net = sock_net(skb->sk);
net/tipc/socket.c
3811
tsk = tipc_sk_lookup(net, tsk_portid);
net/tipc/socket.c
459
static int tipc_sk_create(struct net *net, struct socket *sock,
net/tipc/socket.c
487
sk = sk_alloc(net, AF_TIPC, GFP_KERNEL, &tipc_proto, kern);
net/tipc/socket.c
513
tipc_msg_init(tipc_own_addr(net), msg, TIPC_LOW_IMPORTANCE,
net/tipc/socket.c
554
struct net *net = sock_net(sk);
net/tipc/socket.c
585
tipc_node_remove_conn(net, dnode, tsk->portid);
net/tipc/socket.c
598
tipc_node_xmit_skb(net, skb, dnode, tsk->portid);
net/tipc/socket.c
849
struct net *net = sock_net(sk);
net/tipc/socket.c
850
int mtu = tipc_bcast_get_mtu(net);
net/tipc/socket.c
864
tipc_nlist_init(&dsts, tipc_own_addr(net));
net/tipc/socket.c
865
tipc_nametbl_lookup_mcast_nodes(net, ua, &dsts);
net/tipc/socket.c
887
rc = tipc_mcast_xmit(net, &pkts, &tsk->mc_method, &dsts,
net/tipc/socket.c
906
static int tipc_send_group_msg(struct net *net, struct tipc_sock *tsk,
net/tipc/socket.c
926
mtu = tipc_node_get_mtu(net, dnode, tsk->portid, false);
net/tipc/socket.c
932
rc = tipc_node_xmit(net, &pkts, dnode, tsk->portid);
net/tipc/socket.c
964
struct net *net = sock_net(sk);
net/tipc/socket.c
986
rc = tipc_send_group_msg(net, tsk, m, mb, node, port, dlen);
net/tipc/socket.h
56
void tipc_sk_rcv(struct net *net, struct sk_buff_head *inputq);
net/tipc/socket.h
57
void tipc_sk_mcast_rcv(struct net *net, struct sk_buff_head *arrvq,
net/tipc/socket.h
59
void tipc_sk_reinit(struct net *net);
net/tipc/socket.h
60
int tipc_sk_rht_init(struct net *net);
net/tipc/socket.h
61
void tipc_sk_rht_destroy(struct net *net);
net/tipc/socket.h
72
int __tipc_dump_start(struct netlink_callback *cb, struct net *net);
net/tipc/subscr.c
131
struct tipc_subscription *tipc_sub_subscribe(struct net *net,
net/tipc/subscr.c
153
sub->net = net;
net/tipc/subscr.c
63
tipc_topsrv_queue_evt(sub->net, sub->conid, event, evt);
net/tipc/subscr.h
67
struct net *net;
net/tipc/subscr.h
76
struct tipc_subscription *tipc_sub_subscribe(struct net *net,
net/tipc/subscr.h
84
int __net_init tipc_topsrv_init_net(struct net *net);
net/tipc/subscr.h
85
void __net_exit tipc_topsrv_exit_net(struct net *net);
net/tipc/topsrv.c
116
static void tipc_topsrv_kern_evt(struct net *net, struct tipc_event *evt);
net/tipc/topsrv.c
233
struct tipc_net *tn = tipc_net(con->server->net);
net/tipc/topsrv.c
286
tipc_topsrv_kern_evt(srv->net, evt);
net/tipc/topsrv.c
314
void tipc_topsrv_queue_evt(struct net *net, int conid,
net/tipc/topsrv.c
317
struct tipc_topsrv *srv = tipc_topsrv(net);
net/tipc/topsrv.c
365
struct tipc_net *tn = tipc_net(srv->net);
net/tipc/topsrv.c
378
sub = tipc_sub_subscribe(srv->net, s, con->conid);
net/tipc/topsrv.c
518
rc = sock_create_kern(srv->net, AF_TIPC, SOCK_SEQPACKET, 0, &lsock);
net/tipc/topsrv.c
573
bool tipc_topsrv_kern_subscr(struct net *net, u32 port, u32 type, u32 lower,
net/tipc/topsrv.c
587
con = tipc_conn_alloc(tipc_topsrv(net), NULL);
net/tipc/topsrv.c
592
rc = tipc_conn_rcv_sub(tipc_topsrv(net), con, &sub);
net/tipc/topsrv.c
600
void tipc_topsrv_kern_unsubscr(struct net *net, int conid)
net/tipc/topsrv.c
604
con = tipc_conn_lookup(tipc_topsrv(net), conid);
net/tipc/topsrv.c
614
static void tipc_topsrv_kern_evt(struct net *net, struct tipc_event *evt)
net/tipc/topsrv.c
617
u32 self = tipc_own_addr(net);
net/tipc/topsrv.c
629
tipc_loopback_trace(net, &evtq);
net/tipc/topsrv.c
630
tipc_sk_rcv(net, &evtq);
net/tipc/topsrv.c
657
static int tipc_topsrv_start(struct net *net)
net/tipc/topsrv.c
659
struct tipc_net *tn = tipc_net(net);
net/tipc/topsrv.c
668
srv->net = net;
net/tipc/topsrv.c
696
static void tipc_topsrv_stop(struct net *net)
net/tipc/topsrv.c
698
struct tipc_topsrv *srv = tipc_topsrv(net);
net/tipc/topsrv.c
71
struct net *net;
net/tipc/topsrv.c
725
int __net_init tipc_topsrv_init_net(struct net *net)
net/tipc/topsrv.c
727
return tipc_topsrv_start(net);
net/tipc/topsrv.c
730
void __net_exit tipc_topsrv_exit_net(struct net *net)
net/tipc/topsrv.c
732
tipc_topsrv_stop(net);
net/tipc/topsrv.h
47
void tipc_topsrv_queue_evt(struct net *net, int conid,
net/tipc/topsrv.h
50
bool tipc_topsrv_kern_subscr(struct net *net, u32 port, u32 type, u32 lower,
net/tipc/topsrv.h
52
void tipc_topsrv_kern_unsubscr(struct net *net, int conid);
net/tipc/udp_media.c
174
static int tipc_udp_xmit(struct net *net, struct sk_buff *skb,
net/tipc/udp_media.c
193
rt = ip_route_output_key(net, &fl);
net/tipc/udp_media.c
214
ndst = ip6_dst_lookup_flow(net, ub->sk,
net/tipc/udp_media.c
237
static int tipc_udp_send_msg(struct net *net, struct sk_buff *skb,
net/tipc/udp_media.c
261
return tipc_udp_xmit(net, skb, ub, src, dst,
net/tipc/udp_media.c
274
err = tipc_udp_xmit(net, _skb, ub, src, &rcast->addr,
net/tipc/udp_media.c
467
struct net *net = sock_net(skb->sk);
net/tipc/udp_media.c
486
b = tipc_bearer_find(net, bname);
net/tipc/udp_media.c
493
struct net *net = sock_net(skb->sk);
net/tipc/udp_media.c
494
struct tipc_net *tn = net_generic(net, tipc_net_id);
net/tipc/udp_media.c
656
static int tipc_udp_enable(struct net *net, struct tipc_bearer *b,
net/tipc/udp_media.c
708
if (!tipc_own_id(net)) {
net/tipc/udp_media.c
710
tipc_net_init(net, node_id, 0);
net/tipc/udp_media.c
712
if (!tipc_own_id(net)) {
net/tipc/udp_media.c
724
dev = __ip_dev_find(net, local.ipv4.s_addr, false);
net/tipc/udp_media.c
742
dev = ub->ifindex ? __dev_get_by_index(net, ub->ifindex) : NULL;
net/tipc/udp_media.c
743
dev = ipv6_dev_find(net, &local.ipv6, dev);
net/tipc/udp_media.c
764
err = udp_sock_create(net, &udp_conf, &sock);
net/tipc/udp_media.c
773
setup_udp_tunnel_sock(net, ub->sk, &tuncfg);
net/tls/tls.h
136
int __net_init tls_proc_init(struct net *net);
net/tls/tls.h
137
void __net_exit tls_proc_fini(struct net *net);
net/tls/tls.h
47
#define __TLS_INC_STATS(net, field) \
net/tls/tls.h
48
__SNMP_INC_STATS((net)->mib.tls_statistics, field)
net/tls/tls.h
49
#define TLS_INC_STATS(net, field) \
net/tls/tls.h
50
SNMP_INC_STATS((net)->mib.tls_statistics, field)
net/tls/tls.h
51
#define TLS_DEC_STATS(net, field) \
net/tls/tls.h
52
SNMP_DEC_STATS((net)->mib.tls_statistics, field)
net/tls/tls_main.c
1189
static int __net_init tls_init_net(struct net *net)
net/tls/tls_main.c
1193
net->mib.tls_statistics = alloc_percpu(struct linux_tls_mib);
net/tls/tls_main.c
1194
if (!net->mib.tls_statistics)
net/tls/tls_main.c
1197
err = tls_proc_init(net);
net/tls/tls_main.c
1203
free_percpu(net->mib.tls_statistics);
net/tls/tls_main.c
1207
static void __net_exit tls_exit_net(struct net *net)
net/tls/tls_main.c
1209
tls_proc_fini(net);
net/tls/tls_main.c
1210
free_percpu(net->mib.tls_statistics);
net/tls/tls_proc.c
36
struct net *net = seq->private;
net/tls/tls_proc.c
41
net->mib.tls_statistics);
net/tls/tls_proc.c
49
int __net_init tls_proc_init(struct net *net)
net/tls/tls_proc.c
52
if (!proc_create_net_single("tls_stat", 0444, net->proc_net,
net/tls/tls_proc.c
60
void __net_exit tls_proc_fini(struct net *net)
net/tls/tls_proc.c
62
remove_proc_entry("tls_stat", net->proc_net);
net/unix/af_unix.c
1082
static struct sock *unix_create1(struct net *net, struct socket *sock, int kern, int type)
net/unix/af_unix.c
1095
sk = sk_alloc(net, PF_UNIX, GFP_KERNEL, &unix_stream_proto, kern);
net/unix/af_unix.c
1097
sk = sk_alloc(net, PF_UNIX, GFP_KERNEL, &unix_dgram_proto, kern);
net/unix/af_unix.c
1110
sk->sk_max_ack_backlog = READ_ONCE(net->unx.sysctl_max_dgram_qlen);
net/unix/af_unix.c
1126
unix_insert_unbound_socket(net, sk);
net/unix/af_unix.c
1128
sock_prot_inuse_add(net, sk->sk_prot, 1);
net/unix/af_unix.c
1137
static int unix_create(struct net *net, struct socket *sock, int protocol,
net/unix/af_unix.c
1167
sk = unix_create1(net, sock, kern, sock->type);
net/unix/af_unix.c
1253
static struct sock *unix_find_abstract(struct net *net,
net/unix/af_unix.c
1261
sk = unix_find_socket_byname(net, sunaddr, addr_len, hash);
net/unix/af_unix.c
1272
static struct sock *unix_find_other(struct net *net,
net/unix/af_unix.c
1281
sk = unix_find_abstract(net, sunaddr, addr_len, type);
net/unix/af_unix.c
1290
struct net *net = sock_net(sk);
net/unix/af_unix.c
1320
unix_table_double_lock(net, old_hash, new_hash);
net/unix/af_unix.c
1322
if (__unix_find_socket_byname(net, addr->name, addr->len, new_hash)) {
net/unix/af_unix.c
1323
unix_table_double_unlock(net, old_hash, new_hash);
net/unix/af_unix.c
1340
__unix_set_addr_hash(net, sk, addr, new_hash);
net/unix/af_unix.c
1341
unix_table_double_unlock(net, old_hash, new_hash);
net/unix/af_unix.c
1355
struct net *net = sock_net(sk);
net/unix/af_unix.c
1394
unix_table_double_lock(net, old_hash, new_hash);
net/unix/af_unix.c
1397
__unix_set_addr_hash(net, sk, addr, new_hash);
net/unix/af_unix.c
1398
unix_table_double_unlock(net, old_hash, new_hash);
net/unix/af_unix.c
1422
struct net *net = sock_net(sk);
net/unix/af_unix.c
1441
unix_table_double_lock(net, old_hash, new_hash);
net/unix/af_unix.c
1443
if (__unix_find_socket_byname(net, addr->name, addr->len, new_hash))
net/unix/af_unix.c
1446
__unix_set_addr_hash(net, sk, addr, new_hash);
net/unix/af_unix.c
1447
unix_table_double_unlock(net, old_hash, new_hash);
net/unix/af_unix.c
1452
unix_table_double_unlock(net, old_hash, new_hash);
net/unix/af_unix.c
1633
struct net *net = sock_net(sk);
net/unix/af_unix.c
1660
newsk = unix_create1(net, NULL, 0, sock->type);
net/unix/af_unix.c
1675
other = unix_find_other(net, sunaddr, addr_len, sk->sk_type, flags);
net/unix/af_unix.c
228
static void unix_table_double_lock(struct net *net,
net/unix/af_unix.c
232
spin_lock(&net->unx.table.locks[hash1]);
net/unix/af_unix.c
239
spin_lock(&net->unx.table.locks[hash1]);
net/unix/af_unix.c
240
spin_lock(&net->unx.table.locks[hash2]);
net/unix/af_unix.c
243
static void unix_table_double_unlock(struct net *net,
net/unix/af_unix.c
247
spin_unlock(&net->unx.table.locks[hash1]);
net/unix/af_unix.c
251
spin_unlock(&net->unx.table.locks[hash1]);
net/unix/af_unix.c
252
spin_unlock(&net->unx.table.locks[hash2]);
net/unix/af_unix.c
3485
struct net *net = seq_file_net(seq);
net/unix/af_unix.c
3489
spin_lock(&net->unx.table.locks[bucket]);
net/unix/af_unix.c
3495
spin_unlock(&net->unx.table.locks[bucket]);
net/unix/af_unix.c
377
static void __unix_insert_socket(struct net *net, struct sock *sk)
net/unix/af_unix.c
380
sk_add_node(sk, &net->unx.table.buckets[sk->sk_hash]);
net/unix/af_unix.c
3805
static int __net_init unix_net_init(struct net *net)
net/unix/af_unix.c
3809
net->unx.sysctl_max_dgram_qlen = 10;
net/unix/af_unix.c
3810
if (unix_sysctl_register(net))
net/unix/af_unix.c
3814
if (!proc_create_net("unix", 0, net->proc_net, &unix_seq_ops,
net/unix/af_unix.c
3819
net->unx.table.locks = kvmalloc_objs(spinlock_t, UNIX_HASH_SIZE);
net/unix/af_unix.c
3820
if (!net->unx.table.locks)
net/unix/af_unix.c
3823
net->unx.table.buckets = kvmalloc_objs(struct hlist_head,
net/unix/af_unix.c
3825
if (!net->unx.table.buckets)
net/unix/af_unix.c
3829
spin_lock_init(&net->unx.table.locks[i]);
net/unix/af_unix.c
383
static void __unix_set_addr_hash(struct net *net, struct sock *sk,
net/unix/af_unix.c
3830
lock_set_cmp_fn(&net->unx.table.locks[i], unix_table_lock_cmp_fn, NULL);
net/unix/af_unix.c
3831
INIT_HLIST_HEAD(&net->unx.table.buckets[i]);
net/unix/af_unix.c
3837
kvfree(net->unx.table.locks);
net/unix/af_unix.c
3840
remove_proc_entry("unix", net->proc_net);
net/unix/af_unix.c
3843
unix_sysctl_unregister(net);
net/unix/af_unix.c
3848
static void __net_exit unix_net_exit(struct net *net)
net/unix/af_unix.c
3850
kvfree(net->unx.table.buckets);
net/unix/af_unix.c
3851
kvfree(net->unx.table.locks);
net/unix/af_unix.c
3852
unix_sysctl_unregister(net);
net/unix/af_unix.c
3853
remove_proc_entry("unix", net->proc_net);
net/unix/af_unix.c
390
__unix_insert_socket(net, sk);
net/unix/af_unix.c
393
static void unix_remove_socket(struct net *net, struct sock *sk)
net/unix/af_unix.c
395
spin_lock(&net->unx.table.locks[sk->sk_hash]);
net/unix/af_unix.c
397
spin_unlock(&net->unx.table.locks[sk->sk_hash]);
net/unix/af_unix.c
400
static void unix_insert_unbound_socket(struct net *net, struct sock *sk)
net/unix/af_unix.c
402
spin_lock(&net->unx.table.locks[sk->sk_hash]);
net/unix/af_unix.c
403
__unix_insert_socket(net, sk);
net/unix/af_unix.c
404
spin_unlock(&net->unx.table.locks[sk->sk_hash]);
net/unix/af_unix.c
425
static struct sock *__unix_find_socket_byname(struct net *net,
net/unix/af_unix.c
431
sk_for_each(s, &net->unx.table.buckets[hash]) {
net/unix/af_unix.c
441
static inline struct sock *unix_find_socket_byname(struct net *net,
net/unix/af_unix.c
447
spin_lock(&net->unx.table.locks[hash]);
net/unix/af_unix.c
448
s = __unix_find_socket_byname(net, sunname, len, hash);
net/unix/af_unix.c
451
spin_unlock(&net->unx.table.locks[hash]);
net/unix/af_unix.h
41
int unix_sysctl_register(struct net *net);
net/unix/af_unix.h
42
void unix_sysctl_unregister(struct net *net);
net/unix/af_unix.h
44
static inline int unix_sysctl_register(struct net *net)
net/unix/af_unix.h
49
static inline void unix_sysctl_unregister(struct net *net)
net/unix/diag.c
179
struct net *net = sock_net(skb->sk);
net/unix/diag.c
192
spin_lock(&net->unx.table.locks[slot]);
net/unix/diag.c
193
sk_for_each(sk, &net->unx.table.buckets[slot]) {
net/unix/diag.c
210
spin_unlock(&net->unx.table.locks[slot]);
net/unix/diag.c
216
spin_unlock(&net->unx.table.locks[slot]);
net/unix/diag.c
225
static struct sock *unix_lookup_by_ino(struct net *net, unsigned int ino)
net/unix/diag.c
231
spin_lock(&net->unx.table.locks[i]);
net/unix/diag.c
232
sk_for_each(sk, &net->unx.table.buckets[i]) {
net/unix/diag.c
235
spin_unlock(&net->unx.table.locks[i]);
net/unix/diag.c
239
spin_unlock(&net->unx.table.locks[i]);
net/unix/diag.c
248
struct net *net = sock_net(in_skb->sk);
net/unix/diag.c
258
sk = unix_lookup_by_ino(net, req->udiag_ino);
net/unix/diag.c
285
err = nlmsg_unicast(net->diag_nlsk, rep, NETLINK_CB(in_skb).portid);
net/unix/sysctl_net_unix.c
26
int __net_init unix_sysctl_register(struct net *net)
net/unix/sysctl_net_unix.c
30
if (net_eq(net, &init_net)) {
net/unix/sysctl_net_unix.c
37
table[0].data = &net->unx.sysctl_max_dgram_qlen;
net/unix/sysctl_net_unix.c
40
net->unx.ctl = register_net_sysctl_sz(net, "net/unix", table,
net/unix/sysctl_net_unix.c
42
if (net->unx.ctl == NULL)
net/unix/sysctl_net_unix.c
48
if (!net_eq(net, &init_net))
net/unix/sysctl_net_unix.c
54
void unix_sysctl_unregister(struct net *net)
net/unix/sysctl_net_unix.c
58
table = net->unx.ctl->ctl_table_arg;
net/unix/sysctl_net_unix.c
59
unregister_net_sysctl_table(net->unx.ctl);
net/unix/sysctl_net_unix.c
60
if (!net_eq(net, &init_net))
net/vmw_vsock/af_vsock.c
2687
static int vsock_create(struct net *net, struct socket *sock,
net/vmw_vsock/af_vsock.c
2716
sk = __vsock_create(net, sock, NULL, GFP_KERNEL, 0, kern);
net/vmw_vsock/af_vsock.c
2862
struct net *net;
net/vmw_vsock/af_vsock.c
2867
net = container_of(table->data, struct net, vsock.mode);
net/vmw_vsock/af_vsock.c
2870
vsock_net_mode(net), NULL);
net/vmw_vsock/af_vsock.c
2877
struct net *net;
net/vmw_vsock/af_vsock.c
2880
net = container_of(table->data, struct net, vsock.child_ns_mode);
net/vmw_vsock/af_vsock.c
2883
vsock_net_child_mode(net), &new_mode);
net/vmw_vsock/af_vsock.c
2891
if (vsock_net_mode(net) == VSOCK_NET_MODE_LOCAL &&
net/vmw_vsock/af_vsock.c
2895
if (!vsock_net_set_child_mode(net, new_mode))
net/vmw_vsock/af_vsock.c
2928
static int __net_init vsock_sysctl_register(struct net *net)
net/vmw_vsock/af_vsock.c
2932
if (net_eq(net, &init_net)) {
net/vmw_vsock/af_vsock.c
2939
table[0].data = &net->vsock.mode;
net/vmw_vsock/af_vsock.c
2940
table[1].data = &net->vsock.child_ns_mode;
net/vmw_vsock/af_vsock.c
2941
table[2].data = &net->vsock.g2h_fallback;
net/vmw_vsock/af_vsock.c
2944
net->vsock.sysctl_hdr = register_net_sysctl_sz(net, "net/vsock", table,
net/vmw_vsock/af_vsock.c
2946
if (!net->vsock.sysctl_hdr)
net/vmw_vsock/af_vsock.c
2952
if (!net_eq(net, &init_net))
net/vmw_vsock/af_vsock.c
2958
static void vsock_sysctl_unregister(struct net *net)
net/vmw_vsock/af_vsock.c
2962
table = net->vsock.sysctl_hdr->ctl_table_arg;
net/vmw_vsock/af_vsock.c
2963
unregister_net_sysctl_table(net->vsock.sysctl_hdr);
net/vmw_vsock/af_vsock.c
2964
if (!net_eq(net, &init_net))
net/vmw_vsock/af_vsock.c
2968
static void vsock_net_init(struct net *net)
net/vmw_vsock/af_vsock.c
2970
if (net_eq(net, &init_net))
net/vmw_vsock/af_vsock.c
2971
net->vsock.mode = VSOCK_NET_MODE_GLOBAL;
net/vmw_vsock/af_vsock.c
2973
net->vsock.mode = vsock_net_child_mode(current->nsproxy->net_ns);
net/vmw_vsock/af_vsock.c
2975
net->vsock.child_ns_mode = net->vsock.mode;
net/vmw_vsock/af_vsock.c
2976
net->vsock.child_ns_mode_locked = 0;
net/vmw_vsock/af_vsock.c
2977
net->vsock.g2h_fallback = 1;
net/vmw_vsock/af_vsock.c
2980
static __net_init int vsock_sysctl_init_net(struct net *net)
net/vmw_vsock/af_vsock.c
2982
vsock_net_init(net);
net/vmw_vsock/af_vsock.c
2984
if (vsock_sysctl_register(net))
net/vmw_vsock/af_vsock.c
2990
static __net_exit void vsock_sysctl_exit_net(struct net *net)
net/vmw_vsock/af_vsock.c
2992
vsock_sysctl_unregister(net);
net/vmw_vsock/af_vsock.c
301
struct net *net)
net/vmw_vsock/af_vsock.c
309
vsock_net_check_mode(sock_net(sk), net))
net/vmw_vsock/af_vsock.c
315
vsock_net_check_mode(sock_net(sk), net))
net/vmw_vsock/af_vsock.c
324
struct sockaddr_vm *dst, struct net *net)
net/vmw_vsock/af_vsock.c
334
vsock_net_check_mode(sock_net(sk), net)) {
net/vmw_vsock/af_vsock.c
384
struct net *net)
net/vmw_vsock/af_vsock.c
389
sk = __vsock_find_bound_socket_net(addr, net);
net/vmw_vsock/af_vsock.c
417
struct net *net)
net/vmw_vsock/af_vsock.c
422
sk = __vsock_find_connected_socket_net(src, dst, net);
net/vmw_vsock/af_vsock.c
810
struct net *net = sock_net(sk_vsock(vsk));
net/vmw_vsock/af_vsock.c
813
if (!net->vsock.port)
net/vmw_vsock/af_vsock.c
814
net->vsock.port = get_random_u32_above(LAST_RESERVED_PORT);
net/vmw_vsock/af_vsock.c
823
if (net->vsock.port == VMADDR_PORT_ANY ||
net/vmw_vsock/af_vsock.c
824
net->vsock.port <= LAST_RESERVED_PORT)
net/vmw_vsock/af_vsock.c
825
net->vsock.port = LAST_RESERVED_PORT + 1;
net/vmw_vsock/af_vsock.c
827
new_addr.svm_port = net->vsock.port++;
net/vmw_vsock/af_vsock.c
829
if (!__vsock_find_bound_socket_net(&new_addr, net)) {
net/vmw_vsock/af_vsock.c
846
if (__vsock_find_bound_socket_net(&new_addr, net))
net/vmw_vsock/af_vsock.c
908
static struct sock *__vsock_create(struct net *net,
net/vmw_vsock/af_vsock.c
919
sk = sk_alloc(net, AF_VSOCK, priority, &vsock_proto, kern);
net/vmw_vsock/diag.c
113
if (!net_eq(sock_net(sk), net))
net/vmw_vsock/diag.c
144
struct net *net = sock_net(skb->sk);
net/vmw_vsock/diag.c
153
return netlink_dump_start(net->diag_nlsk, skb, h, &c);
net/vmw_vsock/diag.c
55
struct net *net;
net/vmw_vsock/diag.c
59
net = sock_net(skb->sk);
net/vmw_vsock/diag.c
79
if (!net_eq(sock_net(sk), net))
net/vmw_vsock/virtio_transport.c
237
virtio_transport_send_pkt(struct sk_buff *skb, struct net *net)
net/vmw_vsock/virtio_transport_common.c
1210
.net = sock_net(sk_vsock(vsk)),
net/vmw_vsock/virtio_transport_common.c
1226
.net = sock_net(sk_vsock(vsk)),
net/vmw_vsock/virtio_transport_common.c
1253
.net = sock_net(sk_vsock(vsk)),
net/vmw_vsock/virtio_transport_common.c
1291
.net = sock_net(sk_vsock(vsk)),
net/vmw_vsock/virtio_transport_common.c
1309
struct sk_buff *skb, struct net *net)
net/vmw_vsock/virtio_transport_common.c
1346
return t->send_pkt(reply, net);
net/vmw_vsock/virtio_transport_common.c
1661
.net = sock_net(sk_vsock(vsk)),
net/vmw_vsock/virtio_transport_common.c
1771
struct sk_buff *skb, struct net *net)
net/vmw_vsock/virtio_transport_common.c
1794
(void)virtio_transport_reset_no_sock(t, skb, net);
net/vmw_vsock/virtio_transport_common.c
1801
sk = vsock_find_connected_socket_net(&src, &dst, net);
net/vmw_vsock/virtio_transport_common.c
1803
sk = vsock_find_bound_socket_net(&dst, net);
net/vmw_vsock/virtio_transport_common.c
1805
(void)virtio_transport_reset_no_sock(t, skb, net);
net/vmw_vsock/virtio_transport_common.c
1811
(void)virtio_transport_reset_no_sock(t, skb, net);
net/vmw_vsock/virtio_transport_common.c
1830
(void)virtio_transport_reset_no_sock(t, skb, net);
net/vmw_vsock/virtio_transport_common.c
1862
(void)virtio_transport_reset_no_sock(t, skb, net);
net/vmw_vsock/virtio_transport_common.c
391
ret = t_ops->send_pkt(skb, info->net);
net/vmw_vsock/virtio_transport_common.c
663
.net = sock_net(sk_vsock(vsk)),
net/vmw_vsock/vsock_loopback.c
29
static int vsock_loopback_send_pkt(struct sk_buff *skb, struct net *net)
net/wireless/core.c
157
struct net *net)
net/wireless/core.c
169
err = dev_change_net_namespace(wdev->netdev, net, "wlan%d");
net/wireless/core.c
177
net = wiphy_net(&rdev->wiphy);
net/wireless/core.c
185
err = dev_change_net_namespace(wdev->netdev, net,
net/wireless/core.c
1861
static void __net_exit cfg80211_pernet_exit(struct net *net)
net/wireless/core.c
1867
if (net_eq(wiphy_net(&rdev->wiphy), net))
net/wireless/core.c
204
wiphy_net_set(&rdev->wiphy, net);
net/wireless/core.h
246
struct net *net);
net/wireless/nl80211.c
141
__cfg80211_rdev_from_attrs(struct net *netns, struct nlattr **attrs)
net/wireless/nl80211.c
14186
struct net *net;
net/wireless/nl80211.c
14192
net = get_net_ns_by_pid(pid);
net/wireless/nl80211.c
14196
net = get_net_ns_by_fd(fd);
net/wireless/nl80211.c
14201
if (IS_ERR(net))
net/wireless/nl80211.c
14202
return PTR_ERR(net);
net/wireless/nl80211.c
14212
if (!ns_capable(net->user_ns, CAP_NET_ADMIN)) {
net/wireless/nl80211.c
14213
put_net(net);
net/wireless/nl80211.c
14220
if (!net_eq(wiphy_net(&rdev->wiphy), net))
net/wireless/nl80211.c
14221
err = cfg80211_switch_netns(rdev, net);
net/wireless/nl80211.c
14223
put_net(net);
net/wireless/nl80211.c
221
cfg80211_get_dev_from_info(struct net *netns, struct genl_info *info)
net/wireless/nl80211.c
69
struct net *netns, struct nlattr **attrs)
net/wireless/scan.c
3494
cfg80211_get_dev_from_ifindex(struct net *net, int ifindex)
net/wireless/scan.c
3501
dev = dev_get_by_index(net, ifindex);
net/wireless/wext-core.c
1001
static int wext_ioctl_dispatch(struct net *net, struct iwreq *iwr,
net/wireless/wext-core.c
1011
dev_load(net, iwr->ifr_name);
net/wireless/wext-core.c
1013
ret = wireless_process_ioctl(net, iwr, cmd, info, standard, private);
net/wireless/wext-core.c
1063
int wext_handle_ioctl(struct net *net, unsigned int cmd, void __user *arg)
net/wireless/wext-core.c
1074
ret = wext_ioctl_dispatch(net, &iwr, cmd, &info,
net/wireless/wext-core.c
1120
int compat_wext_handle_ioctl(struct net *net, unsigned int cmd,
net/wireless/wext-core.c
1140
ret = wext_ioctl_dispatch(net, &iwr, cmd, &info,
net/wireless/wext-core.c
348
struct net *net;
net/wireless/wext-core.c
351
for_each_net(net) {
net/wireless/wext-core.c
352
while ((skb = skb_dequeue(&net->wext_nlevents)))
net/wireless/wext-core.c
353
rtnl_notify(skb, net, 0, RTNLGRP_LINK, NULL,
net/wireless/wext-core.c
379
static int __net_init wext_pernet_init(struct net *net)
net/wireless/wext-core.c
381
skb_queue_head_init(&net->wext_nlevents);
net/wireless/wext-core.c
385
static void __net_exit wext_pernet_exit(struct net *net)
net/wireless/wext-core.c
387
skb_queue_purge(&net->wext_nlevents);
net/wireless/wext-core.c
942
static int wireless_process_ioctl(struct net *net, struct iwreq *iwr,
net/wireless/wext-core.c
955
if ((dev = __dev_get_by_name(net, iwr->ifr_name)) == NULL)
net/wireless/wext-proc.c
100
for_each_netdev(net, dev)
net/wireless/wext-proc.c
108
struct net *net = seq_file_net(seq);
net/wireless/wext-proc.c
113
first_net_device(net) : next_net_device(v);
net/wireless/wext-proc.c
128
int __net_init wext_proc_init(struct net *net)
net/wireless/wext-proc.c
131
if (!proc_create_net("wireless", 0444, net->proc_net,
net/wireless/wext-proc.c
138
void __net_exit wext_proc_exit(struct net *net)
net/wireless/wext-proc.c
140
remove_proc_entry("wireless", net->proc_net);
net/wireless/wext-proc.c
91
struct net *net = seq_file_net(seq);
net/x25/af_x25.c
504
static struct sock *x25_alloc_socket(struct net *net, int kern)
net/x25/af_x25.c
507
struct sock *sk = sk_alloc(net, AF_X25, GFP_ATOMIC, &x25_proto, kern);
net/x25/af_x25.c
523
static int x25_create(struct net *net, struct socket *sock, int protocol,
net/x25/af_x25.c
530
if (!net_eq(net, &init_net))
net/x25/af_x25.c
542
if ((sk = x25_alloc_socket(net, kern)) == NULL)
net/xdp/xsk.c
1342
struct net *net;
net/xdp/xsk.c
1347
net = sock_net(sk);
net/xdp/xsk.c
1352
mutex_lock(&net->xdp.lock);
net/xdp/xsk.c
1354
mutex_unlock(&net->xdp.lock);
net/xdp/xsk.c
1356
sock_prot_inuse_add(net, sk->sk_prot, -1);
net/xdp/xsk.c
1905
struct net *net = dev_net(dev);
net/xdp/xsk.c
1910
mutex_lock(&net->xdp.lock);
net/xdp/xsk.c
1911
sk_for_each(sk, &net->xdp.list) {
net/xdp/xsk.c
1927
mutex_unlock(&net->xdp.lock);
net/xdp/xsk.c
1970
static int xsk_create(struct net *net, struct socket *sock, int protocol,
net/xdp/xsk.c
1976
if (!ns_capable(net->user_ns, CAP_NET_RAW))
net/xdp/xsk.c
1986
sk = sk_alloc(net, PF_XDP, GFP_KERNEL, &xsk_proto, kern);
net/xdp/xsk.c
2008
mutex_lock(&net->xdp.lock);
net/xdp/xsk.c
2009
sk_add_node_rcu(sk, &net->xdp.list);
net/xdp/xsk.c
2010
mutex_unlock(&net->xdp.lock);
net/xdp/xsk.c
2012
sock_prot_inuse_add(net, &xsk_proto, 1);
net/xdp/xsk.c
2027
static int __net_init xsk_net_init(struct net *net)
net/xdp/xsk.c
2029
mutex_init(&net->xdp.lock);
net/xdp/xsk.c
2030
INIT_HLIST_HEAD(&net->xdp.list);
net/xdp/xsk.c
2034
static void __net_exit xsk_net_exit(struct net *net)
net/xdp/xsk.c
2036
WARN_ON_ONCE(!hlist_empty(&net->xdp.list));
net/xdp/xsk_diag.c
154
struct net *net = sock_net(nlskb->sk);
net/xdp/xsk_diag.c
158
mutex_lock(&net->xdp.lock);
net/xdp/xsk_diag.c
160
sk_for_each(sk, &net->xdp.list) {
net/xdp/xsk_diag.c
161
if (!net_eq(sock_net(sk), net))
net/xdp/xsk_diag.c
176
mutex_unlock(&net->xdp.lock);
net/xdp/xsk_diag.c
185
struct net *net = sock_net(nlskb->sk);
net/xdp/xsk_diag.c
193
return netlink_dump_start(net->diag_nlsk, nlskb, hdr, &c);
net/xfrm/trace_iptfs.h
215
#define TRACE_INCLUDE_PATH ../../net/xfrm
net/xfrm/xfrm_device.c
239
int xfrm_dev_state_add(struct net *net, struct xfrm_state *x,
net/xfrm/xfrm_device.c
276
dev = dev_get_by_index(net, xuo->ifindex);
net/xfrm/xfrm_device.c
289
params.net = net;
net/xfrm/xfrm_device.c
359
int xfrm_dev_policy_add(struct net *net, struct xfrm_policy *xp,
net/xfrm/xfrm_device.c
375
dev = dev_get_by_index(net, xuo->ifindex);
net/xfrm/xfrm_input.c
41
int (*finish)(struct net *net, struct sock *sk, struct sk_buff *skb);
net/xfrm/xfrm_input.c
42
struct net *net;
net/xfrm/xfrm_input.c
469
struct net *net = dev_net(skb->dev);
net/xfrm/xfrm_input.c
491
XFRM_INC_STATS(net, LINUX_MIB_XFRMACQUIREERROR);
net/xfrm/xfrm_input.c
493
XFRM_INC_STATS(net,
net/xfrm/xfrm_input.c
531
XFRM_INC_STATS(net, LINUX_MIB_XFRMINSTATEPROTOERROR);
net/xfrm/xfrm_input.c
536
XFRM_INC_STATS(net, LINUX_MIB_XFRMINSTATEPROTOERROR);
net/xfrm/xfrm_input.c
540
XFRM_INC_STATS(net, LINUX_MIB_XFRMINBUFFERERROR);
net/xfrm/xfrm_input.c
545
XFRM_INC_STATS(net, LINUX_MIB_XFRMINHDRERROR);
net/xfrm/xfrm_input.c
571
XFRM_INC_STATS(net, LINUX_MIB_XFRMINERROR);
net/xfrm/xfrm_input.c
578
XFRM_INC_STATS(net, LINUX_MIB_XFRMINHDRERROR);
net/xfrm/xfrm_input.c
589
XFRM_INC_STATS(net, LINUX_MIB_XFRMINBUFFERERROR);
net/xfrm/xfrm_input.c
593
x = xfrm_input_state_lookup(net, mark, daddr, spi, nexthdr, family);
net/xfrm/xfrm_input.c
596
XFRM_INC_STATS(net, LINUX_MIB_XFRMINNOSTATES);
net/xfrm/xfrm_input.c
603
XFRM_INC_STATS(net, LINUX_MIB_XFRMINSTATEDIRERROR);
net/xfrm/xfrm_input.c
616
XFRM_INC_STATS(net, LINUX_MIB_XFRMINERROR);
net/xfrm/xfrm_input.c
630
XFRM_INC_STATS(net, LINUX_MIB_XFRMACQUIREERROR);
net/xfrm/xfrm_input.c
632
XFRM_INC_STATS(net,
net/xfrm/xfrm_input.c
638
XFRM_INC_STATS(net, LINUX_MIB_XFRMINSTATEMISMATCH);
net/xfrm/xfrm_input.c
643
XFRM_INC_STATS(net, LINUX_MIB_XFRMINSTATESEQERROR);
net/xfrm/xfrm_input.c
648
XFRM_INC_STATS(net, LINUX_MIB_XFRMINSTATEEXPIRED);
net/xfrm/xfrm_input.c
653
XFRM_INC_STATS(net, LINUX_MIB_XFRMINSTATEMODEERROR);
net/xfrm/xfrm_input.c
678
XFRM_INC_STATS(net, LINUX_MIB_XFRMINSTATEPROTOERROR);
net/xfrm/xfrm_input.c
686
XFRM_INC_STATS(net, LINUX_MIB_XFRMINSTATESEQERROR);
net/xfrm/xfrm_input.c
706
XFRM_INC_STATS(net, LINUX_MIB_XFRMINSTATEMODEERROR);
net/xfrm/xfrm_input.c
724
XFRM_INC_STATS(net, LINUX_MIB_XFRMINHDRERROR);
net/xfrm/xfrm_input.c
804
struct net *net = XFRM_TRANS_SKB_CB(skb)->net;
net/xfrm/xfrm_input.c
806
XFRM_TRANS_SKB_CB(skb)->finish(net, NULL, skb);
net/xfrm/xfrm_input.c
807
put_net(net);
net/xfrm/xfrm_input.c
812
int xfrm_trans_queue_net(struct net *net, struct sk_buff *skb,
net/xfrm/xfrm_input.c
813
int (*finish)(struct net *, struct sock *,
net/xfrm/xfrm_input.c
817
struct net *hold_net;
net/xfrm/xfrm_input.c
826
hold_net = maybe_get_net(net);
net/xfrm/xfrm_input.c
831
XFRM_TRANS_SKB_CB(skb)->net = hold_net;
net/xfrm/xfrm_input.c
841
int (*finish)(struct net *, struct sock *,
net/xfrm/xfrm_interface_core.c
154
static struct xfrm_if *xfrmi_lookup(struct net *net, struct xfrm_state *x)
net/xfrm/xfrm_interface_core.c
156
struct xfrmi_net *xfrmn = net_generic(net, xfrmi_net_id);
net/xfrm/xfrm_interface_core.c
193
struct net *net = xs_net(xfrm_input_state(skb));
net/xfrm/xfrm_interface_core.c
195
dev = dev_get_by_index_rcu(net, ifindex);
net/xfrm/xfrm_interface_core.c
206
res->net = xi->net;
net/xfrm/xfrm_interface_core.c
245
static int xfrmi_create(struct net *net, struct net_device *dev)
net/xfrm/xfrm_interface_core.c
248
struct xfrmi_net *xfrmn = net_generic(net, xfrmi_net_id);
net/xfrm/xfrm_interface_core.c
267
static struct xfrm_if *xfrmi_locate(struct net *net, struct xfrm_if_parms *p)
net/xfrm/xfrm_interface_core.c
271
struct xfrmi_net *xfrmn = net_generic(net, xfrmi_net_id);
net/xfrm/xfrm_interface_core.c
285
struct xfrmi_net *xfrmn = net_generic(xi->net, xfrmi_net_id);
net/xfrm/xfrm_interface_core.c
387
xnet = !net_eq(xi->net, dev_net(skb->dev));
net/xfrm/xfrm_interface_core.c
456
dst = xfrm_lookup_with_ifid(xi->net, dst, fl, NULL, 0, if_id);
net/xfrm/xfrm_interface_core.c
504
xfrmi_scrub_packet(skb, !net_eq(xi->net, dev_net(dev)));
net/xfrm/xfrm_interface_core.c
508
err = dst_output(xi->net, skb_to_full_sk(skb), skb);
net/xfrm/xfrm_interface_core.c
588
struct net *net = dev_net(skb->dev);
net/xfrm/xfrm_interface_core.c
625
x = xfrm_state_lookup(net, skb->mark, (const xfrm_address_t *)&iph->daddr,
net/xfrm/xfrm_interface_core.c
630
xi = xfrmi_lookup(net, x);
net/xfrm/xfrm_interface_core.c
637
ipv4_update_pmtu(skb, net, info, 0, protocol);
net/xfrm/xfrm_interface_core.c
639
ipv4_redirect(skb, net, 0, protocol);
net/xfrm/xfrm_interface_core.c
649
struct net *net = dev_net(skb->dev);
net/xfrm/xfrm_interface_core.c
679
x = xfrm_state_lookup(net, skb->mark, (const xfrm_address_t *)&iph->daddr,
net/xfrm/xfrm_interface_core.c
684
xi = xfrmi_lookup(net, x);
net/xfrm/xfrm_interface_core.c
691
ip6_redirect(skb, net, skb->dev->ifindex, 0,
net/xfrm/xfrm_interface_core.c
692
sock_net_uid(net, NULL));
net/xfrm/xfrm_interface_core.c
694
ip6_update_pmtu(skb, net, info, 0, 0, sock_net_uid(net, NULL));
net/xfrm/xfrm_interface_core.c
712
struct net *net = xi->net;
net/xfrm/xfrm_interface_core.c
713
struct xfrmi_net *xfrmn = net_generic(net, xfrmi_net_id);
net/xfrm/xfrm_interface_core.c
73
static int xfrmi_build_state(struct net *net, struct nlattr *nla,
net/xfrm/xfrm_interface_core.c
764
struct net_device *phydev = __dev_get_by_index(xi->net, xi->p.link);
net/xfrm/xfrm_interface_core.c
823
struct net *net;
net/xfrm/xfrm_interface_core.c
826
net = params->link_net ? : dev_net(dev);
net/xfrm/xfrm_interface_core.c
829
struct xfrmi_net *xfrmn = net_generic(net, xfrmi_net_id);
net/xfrm/xfrm_interface_core.c
845
xi = xfrmi_locate(net, &p);
net/xfrm/xfrm_interface_core.c
852
xi->net = net;
net/xfrm/xfrm_interface_core.c
855
err = xfrmi_create(net, dev);
net/xfrm/xfrm_interface_core.c
869
struct net *net = xi->net;
net/xfrm/xfrm_interface_core.c
872
if (!rtnl_dev_link_net_capable(dev, net))
net/xfrm/xfrm_interface_core.c
886
xi = xfrmi_locate(net, &p);
net/xfrm/xfrm_interface_core.c
924
static struct net *xfrmi_get_link_net(const struct net_device *dev)
net/xfrm/xfrm_interface_core.c
928
return READ_ONCE(xi->net);
net/xfrm/xfrm_interface_core.c
953
static void __net_exit xfrmi_exit_rtnl(struct net *net,
net/xfrm/xfrm_interface_core.c
956
struct xfrmi_net *xfrmn = net_generic(net, xfrmi_net_id);
net/xfrm/xfrm_interface_core.c
963
(xi = rtnl_net_dereference(net, *xip)) != NULL;
net/xfrm/xfrm_interface_core.c
968
xi = rtnl_net_dereference(net, xfrmn->collect_md_xfrmi);
net/xfrm/xfrm_iptfs.c
1003
XFRM_INC_STATS(net,
net/xfrm/xfrm_iptfs.c
1030
XFRM_INC_STATS(net, LINUX_MIB_XFRMINBUFFERERROR);
net/xfrm/xfrm_iptfs.c
1176
XFRM_INC_STATS(net, LINUX_MIB_XFRMINIPTFSERROR);
net/xfrm/xfrm_iptfs.c
1225
struct net *net;
net/xfrm/xfrm_iptfs.c
1231
net = xs_net(x);
net/xfrm/xfrm_iptfs.c
1243
XFRM_INC_STATS(net, LINUX_MIB_XFRMINBUFFERERROR);
net/xfrm/xfrm_iptfs.c
1255
XFRM_INC_STATS(net, LINUX_MIB_XFRMINBUFFERERROR);
net/xfrm/xfrm_iptfs.c
1260
XFRM_INC_STATS(net, LINUX_MIB_XFRMINHDRERROR);
net/xfrm/xfrm_iptfs.c
1265
XFRM_INC_STATS(net, LINUX_MIB_XFRMINHDRERROR);
net/xfrm/xfrm_iptfs.c
1833
static int iptfs_output_collect(struct net *net, struct sock *sk, struct sk_buff *skb)
net/xfrm/xfrm_iptfs.c
1871
XFRM_INC_STATS(net, LINUX_MIB_XFRMOUTERROR);
net/xfrm/xfrm_iptfs.c
1895
XFRM_INC_STATS(net, LINUX_MIB_XFRMOUTNOQSPACE);
net/xfrm/xfrm_iptfs.c
2524
static int iptfs_user_init(struct net *net, struct xfrm_state *x,
net/xfrm/xfrm_iptfs.c
954
struct net *net;
net/xfrm/xfrm_iptfs.c
961
net = xs_net(x);
net/xfrm/xfrm_iptfs.c
985
XFRM_INC_STATS(net, LINUX_MIB_XFRMINBUFFERERROR);
net/xfrm/xfrm_nat_keepalive.c
102
sock_net_set(sk, net);
net/xfrm/xfrm_nat_keepalive.c
103
dst = ip6_dst_lookup_flow(net, sk, &fl6, NULL);
net/xfrm/xfrm_nat_keepalive.c
204
struct net *net;
net/xfrm/xfrm_nat_keepalive.c
209
net = container_of(work, struct net, xfrm.nat_keepalive_work.work);
net/xfrm/xfrm_nat_keepalive.c
211
xfrm_state_walk(net, &walk, nat_keepalive_work_single, &ctx);
net/xfrm/xfrm_nat_keepalive.c
212
xfrm_state_walk_done(&walk, net);
net/xfrm/xfrm_nat_keepalive.c
214
schedule_delayed_work(&net->xfrm.nat_keepalive_work,
net/xfrm/xfrm_nat_keepalive.c
22
struct net *net;
net/xfrm/xfrm_nat_keepalive.c
250
struct net *net;
net/xfrm/xfrm_nat_keepalive.c
255
net = xs_net(x);
net/xfrm/xfrm_nat_keepalive.c
256
schedule_delayed_work(&net->xfrm.nat_keepalive_work, 0);
net/xfrm/xfrm_nat_keepalive.c
259
int __net_init xfrm_nat_keepalive_net_init(struct net *net)
net/xfrm/xfrm_nat_keepalive.c
261
INIT_DELAYED_WORK(&net->xfrm.nat_keepalive_work, nat_keepalive_work);
net/xfrm/xfrm_nat_keepalive.c
265
int xfrm_nat_keepalive_net_fini(struct net *net)
net/xfrm/xfrm_nat_keepalive.c
267
disable_delayed_work_sync(&net->xfrm.nat_keepalive_work);
net/xfrm/xfrm_nat_keepalive.c
33
ka->net = xs_net(x);
net/xfrm/xfrm_nat_keepalive.c
45
struct net *net = ka->net;
net/xfrm/xfrm_nat_keepalive.c
55
ka->encap_sport, sock_net_uid(net, NULL));
net/xfrm/xfrm_nat_keepalive.c
57
rt = ip_route_output_key(net, &fl4);
net/xfrm/xfrm_nat_keepalive.c
67
sock_net_set(sk, net);
net/xfrm/xfrm_nat_keepalive.c
79
struct net *net = ka->net;
net/xfrm/xfrm_output.c
27
static int xfrm_output2(struct net *net, struct sock *sk, struct sk_buff *skb);
net/xfrm/xfrm_output.c
503
struct net *net = xs_net(x);
net/xfrm/xfrm_output.c
511
XFRM_INC_STATS(net, LINUX_MIB_XFRMOUTERROR);
net/xfrm/xfrm_output.c
519
XFRM_INC_STATS(net, LINUX_MIB_XFRMOUTSTATEMODEERROR);
net/xfrm/xfrm_output.c
526
XFRM_INC_STATS(net, LINUX_MIB_XFRMOUTSTATEINVALID);
net/xfrm/xfrm_output.c
533
XFRM_INC_STATS(net, LINUX_MIB_XFRMOUTSTATEEXPIRED);
net/xfrm/xfrm_output.c
539
XFRM_INC_STATS(net, LINUX_MIB_XFRMOUTSTATESEQERROR);
net/xfrm/xfrm_output.c
551
XFRM_INC_STATS(net, LINUX_MIB_XFRMOUTERROR);
net/xfrm/xfrm_output.c
569
XFRM_INC_STATS(net, LINUX_MIB_XFRMOUTSTATEPROTOERROR);
net/xfrm/xfrm_output.c
575
XFRM_INC_STATS(net, LINUX_MIB_XFRMOUTERROR);
net/xfrm/xfrm_output.c
595
struct net *net = xs_net(skb_dst(skb)->xfrm);
net/xfrm/xfrm_output.c
600
err = skb_dst(skb)->ops->local_out(net, sk, skb);
net/xfrm/xfrm_output.c
605
return dst_output(net, sk, skb);
net/xfrm/xfrm_output.c
608
NF_INET_POST_ROUTING, net, sk, skb,
net/xfrm/xfrm_output.c
626
struct net *net = xs_net(x);
net/xfrm/xfrm_output.c
631
XFRM_INC_STATS(net, LINUX_MIB_XFRMOUTERROR);
net/xfrm/xfrm_output.c
638
err = skb_dst(skb)->ops->local_out(net, sk, skb);
net/xfrm/xfrm_output.c
656
static int xfrm_output2(struct net *net, struct sock *sk, struct sk_buff *skb)
net/xfrm/xfrm_output.c
661
static int xfrm_output_gso(struct net *net, struct sock *sk, struct sk_buff *skb)
net/xfrm/xfrm_output.c
678
err = xfrm_output2(net, sk, segs);
net/xfrm/xfrm_output.c
752
struct net *net = dev_net(skb_dst(skb)->dev);
net/xfrm/xfrm_output.c
774
XFRM_INC_STATS(net, LINUX_MIB_XFRMOUTERROR);
net/xfrm/xfrm_output.c
800
XFRM_INC_STATS(net, LINUX_MIB_XFRMOUTERROR);
net/xfrm/xfrm_output.c
814
return xfrm_output_gso(net, sk, skb);
net/xfrm/xfrm_output.c
824
return xfrm_output_gso(net, sk, skb);
net/xfrm/xfrm_output.c
830
XFRM_INC_STATS(net, LINUX_MIB_XFRMOUTERROR);
net/xfrm/xfrm_output.c
837
return xfrm_output2(net, sk, skb);
net/xfrm/xfrm_policy.c
1016
static void xfrm_policy_inexact_node_merge(struct net *net,
net/xfrm/xfrm_policy.c
1032
xfrm_policy_inexact_node_reinsert(net, node, &n->root,
net/xfrm/xfrm_policy.c
1041
xfrm_policy_inexact_list_reinsert(net, n, family);
net/xfrm/xfrm_policy.c
1045
xfrm_policy_inexact_insert_node(struct net *net,
net/xfrm/xfrm_policy.c
1097
xfrm_policy_inexact_node_merge(net, node,
net/xfrm/xfrm_policy.c
1162
static void __xfrm_policy_inexact_flush(struct net *net)
net/xfrm/xfrm_policy.c
1166
lockdep_assert_held(&net->xfrm.xfrm_policy_lock);
net/xfrm/xfrm_policy.c
1168
list_for_each_entry_safe(bin, t, &net->xfrm.inexact_bins, inexact_bins)
net/xfrm/xfrm_policy.c
1177
struct net *net;
net/xfrm/xfrm_policy.c
1179
net = xp_net(policy);
net/xfrm/xfrm_policy.c
1180
lockdep_assert_held(&net->xfrm.xfrm_policy_lock);
net/xfrm/xfrm_policy.c
1189
n = xfrm_policy_inexact_insert_node(net,
net/xfrm/xfrm_policy.c
1204
n = xfrm_policy_inexact_insert_node(net,
net/xfrm/xfrm_policy.c
121
possible_net_t net;
net/xfrm/xfrm_policy.c
1220
n = xfrm_policy_inexact_insert_node(net,
net/xfrm/xfrm_policy.c
1238
struct net *net;
net/xfrm/xfrm_policy.c
1244
net = xp_net(policy);
net/xfrm/xfrm_policy.c
1245
lockdep_assert_held(&net->xfrm.xfrm_policy_lock);
net/xfrm/xfrm_policy.c
1278
struct net *net = container_of(work, struct net,
net/xfrm/xfrm_policy.c
1292
seq = read_seqbegin(&net->xfrm.policy_hthresh.lock);
net/xfrm/xfrm_policy.c
1294
lbits4 = net->xfrm.policy_hthresh.lbits4;
net/xfrm/xfrm_policy.c
1295
rbits4 = net->xfrm.policy_hthresh.rbits4;
net/xfrm/xfrm_policy.c
1296
lbits6 = net->xfrm.policy_hthresh.lbits6;
net/xfrm/xfrm_policy.c
1297
rbits6 = net->xfrm.policy_hthresh.rbits6;
net/xfrm/xfrm_policy.c
1298
} while (read_seqretry(&net->xfrm.policy_hthresh.lock, seq));
net/xfrm/xfrm_policy.c
1300
spin_lock_bh(&net->xfrm.xfrm_policy_lock);
net/xfrm/xfrm_policy.c
1301
write_seqcount_begin(&net->xfrm.xfrm_policy_hash_generation);
net/xfrm/xfrm_policy.c
1306
list_for_each_entry(policy, &net->xfrm.policy_all, walk.all) {
net/xfrm/xfrm_policy.c
1347
net->xfrm.policy_bydst[dir].dbits4 = rbits4;
net/xfrm/xfrm_policy.c
1348
net->xfrm.policy_bydst[dir].sbits4 = lbits4;
net/xfrm/xfrm_policy.c
1349
net->xfrm.policy_bydst[dir].dbits6 = rbits6;
net/xfrm/xfrm_policy.c
1350
net->xfrm.policy_bydst[dir].sbits6 = lbits6;
net/xfrm/xfrm_policy.c
1353
net->xfrm.policy_bydst[dir].dbits4 = lbits4;
net/xfrm/xfrm_policy.c
1354
net->xfrm.policy_bydst[dir].sbits4 = rbits4;
net/xfrm/xfrm_policy.c
1355
net->xfrm.policy_bydst[dir].dbits6 = lbits6;
net/xfrm/xfrm_policy.c
1356
net->xfrm.policy_bydst[dir].sbits6 = rbits6;
net/xfrm/xfrm_policy.c
1361
list_for_each_entry_reverse(policy, &net->xfrm.policy_all, walk.all) {
net/xfrm/xfrm_policy.c
1369
chain = policy_hash_bysel(net, &policy->selector,
net/xfrm/xfrm_policy.c
1392
__xfrm_policy_inexact_flush(net);
net/xfrm/xfrm_policy.c
1393
write_seqcount_end(&net->xfrm.xfrm_policy_hash_generation);
net/xfrm/xfrm_policy.c
1394
spin_unlock_bh(&net->xfrm.xfrm_policy_lock);
net/xfrm/xfrm_policy.c
1399
void xfrm_policy_hash_rebuild(struct net *net)
net/xfrm/xfrm_policy.c
1401
schedule_work(&net->xfrm.policy_hthresh.work);
net/xfrm/xfrm_policy.c
1407
static u32 xfrm_gen_index(struct net *net, int dir, u32 index)
net/xfrm/xfrm_policy.c
1416
idx = (net->xfrm.idx_generator | dir);
net/xfrm/xfrm_policy.c
1417
net->xfrm.idx_generator += 8;
net/xfrm/xfrm_policy.c
1425
list = net->xfrm.policy_byidx + idx_hash(net, idx);
net/xfrm/xfrm_policy.c
1491
return jhash_3words(a, k->if_id, net_hash_mix(read_pnet(&k->net)),
net/xfrm/xfrm_policy.c
1509
if (!net_eq(read_pnet(&b->k.net), read_pnet(&key->net)))
net/xfrm/xfrm_policy.c
1574
struct net *net = xp_net(policy);
net/xfrm/xfrm_policy.c
1581
spin_lock_bh(&net->xfrm.xfrm_policy_lock);
net/xfrm/xfrm_policy.c
1582
chain = policy_hash_bysel(net, &policy->selector, policy->family, dir);
net/xfrm/xfrm_policy.c
1589
spin_unlock_bh(&net->xfrm.xfrm_policy_lock);
net/xfrm/xfrm_policy.c
1597
rt_genid_bump_ipv4(net);
net/xfrm/xfrm_policy.c
1599
rt_genid_bump_ipv6(net);
net/xfrm/xfrm_policy.c
1605
policy->index = delpol ? delpol->index : xfrm_gen_index(net, dir, policy->index);
net/xfrm/xfrm_policy.c
1606
hlist_add_head(&policy->byidx, net->xfrm.policy_byidx+idx_hash(net, policy->index));
net/xfrm/xfrm_policy.c
1611
spin_unlock_bh(&net->xfrm.xfrm_policy_lock);
net/xfrm/xfrm_policy.c
1615
else if (xfrm_bydst_should_resize(net, dir, NULL))
net/xfrm/xfrm_policy.c
1616
schedule_work(&net->xfrm.policy_hash_work);
net/xfrm/xfrm_policy.c
1645
xfrm_policy_bysel_ctx(struct net *net, const struct xfrm_mark *mark, u32 if_id,
net/xfrm/xfrm_policy.c
1654
spin_lock_bh(&net->xfrm.xfrm_policy_lock);
net/xfrm/xfrm_policy.c
1655
chain = policy_hash_bysel(net, sel, sel->family, dir);
net/xfrm/xfrm_policy.c
1660
bin = xfrm_policy_inexact_lookup(net, type,
net/xfrm/xfrm_policy.c
1663
spin_unlock_bh(&net->xfrm.xfrm_policy_lock);
net/xfrm/xfrm_policy.c
1670
spin_unlock_bh(&net->xfrm.xfrm_policy_lock);
net/xfrm/xfrm_policy.c
1697
spin_unlock_bh(&net->xfrm.xfrm_policy_lock);
net/xfrm/xfrm_policy.c
1706
spin_unlock_bh(&net->xfrm.xfrm_policy_lock);
net/xfrm/xfrm_policy.c
1715
xfrm_policy_byid(struct net *net, const struct xfrm_mark *mark, u32 if_id,
net/xfrm/xfrm_policy.c
1726
spin_lock_bh(&net->xfrm.xfrm_policy_lock);
net/xfrm/xfrm_policy.c
1727
chain = net->xfrm.policy_byidx + idx_hash(net, id);
net/xfrm/xfrm_policy.c
1737
spin_unlock_bh(&net->xfrm.xfrm_policy_lock);
net/xfrm/xfrm_policy.c
1746
spin_unlock_bh(&net->xfrm.xfrm_policy_lock);
net/xfrm/xfrm_policy.c
1756
xfrm_policy_flush_secctx_check(struct net *net, u8 type, bool task_valid)
net/xfrm/xfrm_policy.c
1761
list_for_each_entry(pol, &net->xfrm.policy_all, walk.all) {
net/xfrm/xfrm_policy.c
1776
static inline int xfrm_dev_policy_flush_secctx_check(struct net *net,
net/xfrm/xfrm_policy.c
1783
list_for_each_entry(pol, &net->xfrm.policy_all, walk.all) {
net/xfrm/xfrm_policy.c
1799
xfrm_policy_flush_secctx_check(struct net *net, u8 type, bool task_valid)
net/xfrm/xfrm_policy.c
1804
static inline int xfrm_dev_policy_flush_secctx_check(struct net *net,
net/xfrm/xfrm_policy.c
1812
int xfrm_policy_flush(struct net *net, u8 type, bool task_valid)
net/xfrm/xfrm_policy.c
1817
spin_lock_bh(&net->xfrm.xfrm_policy_lock);
net/xfrm/xfrm_policy.c
1819
err = xfrm_policy_flush_secctx_check(net, type, task_valid);
net/xfrm/xfrm_policy.c
1824
list_for_each_entry(pol, &net->xfrm.policy_all, walk.all) {
net/xfrm/xfrm_policy.c
1834
spin_unlock_bh(&net->xfrm.xfrm_policy_lock);
net/xfrm/xfrm_policy.c
1838
spin_lock_bh(&net->xfrm.xfrm_policy_lock);
net/xfrm/xfrm_policy.c
1842
__xfrm_policy_inexact_flush(net);
net/xfrm/xfrm_policy.c
1846
spin_unlock_bh(&net->xfrm.xfrm_policy_lock);
net/xfrm/xfrm_policy.c
1851
int xfrm_dev_policy_flush(struct net *net, struct net_device *dev,
net/xfrm/xfrm_policy.c
1857
spin_lock_bh(&net->xfrm.xfrm_policy_lock);
net/xfrm/xfrm_policy.c
1859
err = xfrm_dev_policy_flush_secctx_check(net, dev, task_valid);
net/xfrm/xfrm_policy.c
1864
list_for_each_entry(pol, &net->xfrm.policy_all, walk.all) {
net/xfrm/xfrm_policy.c
1874
spin_unlock_bh(&net->xfrm.xfrm_policy_lock);
net/xfrm/xfrm_policy.c
1878
spin_lock_bh(&net->xfrm.xfrm_policy_lock);
net/xfrm/xfrm_policy.c
1882
__xfrm_policy_inexact_flush(net);
net/xfrm/xfrm_policy.c
1886
spin_unlock_bh(&net->xfrm.xfrm_policy_lock);
net/xfrm/xfrm_policy.c
1891
int xfrm_policy_walk(struct net *net, struct xfrm_policy_walk *walk,
net/xfrm/xfrm_policy.c
1906
spin_lock_bh(&net->xfrm.xfrm_policy_lock);
net/xfrm/xfrm_policy.c
1908
x = list_first_entry(&net->xfrm.policy_all, struct xfrm_policy_walk_entry, all);
net/xfrm/xfrm_policy.c
1913
list_for_each_entry_from(x, &net->xfrm.policy_all, all) {
net/xfrm/xfrm_policy.c
1934
spin_unlock_bh(&net->xfrm.xfrm_policy_lock);
net/xfrm/xfrm_policy.c
1948
void xfrm_policy_walk_done(struct xfrm_policy_walk *walk, struct net *net)
net/xfrm/xfrm_policy.c
195
xfrm_policy_inexact_lookup(struct net *net, u8 type, u16 family, u8 dir,
net/xfrm/xfrm_policy.c
1953
spin_lock_bh(&net->xfrm.xfrm_policy_lock); /*FIXME where is net? */
net/xfrm/xfrm_policy.c
1955
spin_unlock_bh(&net->xfrm.xfrm_policy_lock);
net/xfrm/xfrm_policy.c
199
xfrm_policy_inexact_lookup_rcu(struct net *net,
net/xfrm/xfrm_policy.c
2056
xfrm_policy_inexact_lookup_rcu(struct net *net, u8 type, u16 family,
net/xfrm/xfrm_policy.c
2066
write_pnet(&k.net, net);
net/xfrm/xfrm_policy.c
2073
xfrm_policy_inexact_lookup(struct net *net, u8 type, u16 family,
net/xfrm/xfrm_policy.c
2078
lockdep_assert_held(&net->xfrm.xfrm_policy_lock);
net/xfrm/xfrm_policy.c
2081
bin = xfrm_policy_inexact_lookup_rcu(net, type, family, dir, if_id);
net/xfrm/xfrm_policy.c
2150
static struct xfrm_policy *xfrm_policy_lookup_bytype(struct net *net, u8 type,
net/xfrm/xfrm_policy.c
2171
sequence = read_seqcount_begin(&net->xfrm.xfrm_policy_hash_generation);
net/xfrm/xfrm_policy.c
2172
chain = policy_hash_direct(net, daddr, saddr, family, dir);
net/xfrm/xfrm_policy.c
2173
} while (read_seqcount_retry(&net->xfrm.xfrm_policy_hash_generation, sequence));
net/xfrm/xfrm_policy.c
2193
bin = xfrm_policy_inexact_lookup_rcu(net, type, family, dir, if_id);
net/xfrm/xfrm_policy.c
2207
if (read_seqcount_retry(&net->xfrm.xfrm_policy_hash_generation, sequence))
net/xfrm/xfrm_policy.c
2218
static struct xfrm_policy *xfrm_policy_lookup(struct net *net,
net/xfrm/xfrm_policy.c
2225
pol = xfrm_policy_lookup_bytype(net, XFRM_POLICY_TYPE_SUB, fl, family,
net/xfrm/xfrm_policy.c
2230
return xfrm_policy_lookup_bytype(net, XFRM_POLICY_TYPE_MAIN, fl, family,
net/xfrm/xfrm_policy.c
2277
static u32 xfrm_gen_pos_slow(struct net *net)
net/xfrm/xfrm_policy.c
2283
list_for_each_entry_reverse(policy, &net->xfrm.policy_all, walk.all) {
net/xfrm/xfrm_policy.c
2291
static u32 xfrm_gen_pos(struct net *net)
net/xfrm/xfrm_policy.c
2297
list_for_each_entry(policy, &net->xfrm.policy_all, walk.all) {
net/xfrm/xfrm_policy.c
2302
return xfrm_gen_pos_slow(net);
net/xfrm/xfrm_policy.c
2313
struct net *net = xp_net(pol);
net/xfrm/xfrm_policy.c
2319
pol->pos = xfrm_gen_pos(net);
net/xfrm/xfrm_policy.c
2323
list_add(&pol->walk.all, &net->xfrm.policy_all);
net/xfrm/xfrm_policy.c
2324
WRITE_ONCE(net->xfrm.policy_count[dir], net->xfrm.policy_count[dir] + 1);
net/xfrm/xfrm_policy.c
2331
struct net *net = xp_net(pol);
net/xfrm/xfrm_policy.c
2343
WRITE_ONCE(net->xfrm.policy_count[dir], net->xfrm.policy_count[dir] - 1);
net/xfrm/xfrm_policy.c
2360
struct net *net = xp_net(pol);
net/xfrm/xfrm_policy.c
2362
spin_lock_bh(&net->xfrm.xfrm_policy_lock);
net/xfrm/xfrm_policy.c
2364
spin_unlock_bh(&net->xfrm.xfrm_policy_lock);
net/xfrm/xfrm_policy.c
2375
struct net *net = sock_net(sk);
net/xfrm/xfrm_policy.c
2383
spin_lock_bh(&net->xfrm.xfrm_policy_lock);
net/xfrm/xfrm_policy.c
2385
lockdep_is_held(&net->xfrm.xfrm_policy_lock));
net/xfrm/xfrm_policy.c
2388
pol->index = xfrm_gen_index(net, XFRM_POLICY_MAX+dir, 0);
net/xfrm/xfrm_policy.c
2401
spin_unlock_bh(&net->xfrm.xfrm_policy_lock);
net/xfrm/xfrm_policy.c
2412
struct net *net = xp_net(old);
net/xfrm/xfrm_policy.c
2433
spin_lock_bh(&net->xfrm.xfrm_policy_lock);
net/xfrm/xfrm_policy.c
2435
spin_unlock_bh(&net->xfrm.xfrm_policy_lock);
net/xfrm/xfrm_policy.c
2483
struct net *net = xp_net(policy);
net/xfrm/xfrm_policy.c
2505
params.net = net;
net/xfrm/xfrm_policy.c
2519
XFRM_INC_STATS(net, LINUX_MIB_XFRMOUTSTATEDIRERROR);
net/xfrm/xfrm_policy.c
2596
static inline struct xfrm_dst *xfrm_alloc_dst(struct net *net, int family)
net/xfrm/xfrm_policy.c
2607
dst_ops = &net->xfrm.xfrm4_dst_ops;
net/xfrm/xfrm_policy.c
2611
dst_ops = &net->xfrm.xfrm6_dst_ops;
net/xfrm/xfrm_policy.c
2669
struct net *net = xp_net(policy);
net/xfrm/xfrm_policy.c
2690
struct xfrm_dst *xdst = xfrm_alloc_dst(net, family);
net/xfrm/xfrm_policy.c
2857
struct net *net = xp_net(pols[0]);
net/xfrm/xfrm_policy.c
2871
XFRM_INC_STATS(net, LINUX_MIB_XFRMOUTPOLERROR);
net/xfrm/xfrm_policy.c
2877
XFRM_INC_STATS(net, LINUX_MIB_XFRMOUTBUNDLEGENERROR);
net/xfrm/xfrm_policy.c
2896
struct net *net = xp_net(pol);
net/xfrm/xfrm_policy.c
2914
xfrm_decode_session(net, skb, &fl, dst->ops->family);
net/xfrm/xfrm_policy.c
2919
dst = xfrm_lookup(net, xfrm_dst_path(dst), &fl, sk, XFRM_LOOKUP_QUEUE);
net/xfrm/xfrm_policy.c
2950
xfrm_decode_session(net, skb, &fl, skb_dst(skb)->ops->family);
net/xfrm/xfrm_policy.c
2954
dst = xfrm_lookup(net, xfrm_dst_path(skb_dst(skb)), &fl, skb->sk, 0);
net/xfrm/xfrm_policy.c
2964
dst_output(net, skb_to_full_sk(skb), skb);
net/xfrm/xfrm_policy.c
2977
static int xdst_queue_output(struct net *net, struct sock *sk, struct sk_buff *skb)
net/xfrm/xfrm_policy.c
301
struct net *net = xs_net(x);
net/xfrm/xfrm_policy.c
3019
static struct xfrm_dst *xfrm_create_dummy_bundle(struct net *net,
net/xfrm/xfrm_policy.c
3031
xdst = xfrm_alloc_dst(net, family);
net/xfrm/xfrm_policy.c
3036
net->xfrm.sysctl_larval_drop ||
net/xfrm/xfrm_policy.c
3078
static struct xfrm_dst *xfrm_bundle_lookup(struct net *net,
net/xfrm/xfrm_policy.c
3090
pols[0] = xfrm_policy_lookup(net, fl, family, dir, if_id);
net/xfrm/xfrm_policy.c
3123
xdst = xfrm_create_dummy_bundle(net, xflo, fl, num_xfrms, family);
net/xfrm/xfrm_policy.c
3135
XFRM_INC_STATS(net, LINUX_MIB_XFRMOUTPOLERROR);
net/xfrm/xfrm_policy.c
3141
static struct dst_entry *make_blackhole(struct net *net, u16 family,
net/xfrm/xfrm_policy.c
315
params.net = net;
net/xfrm/xfrm_policy.c
3151
ret = afinfo->blackhole_route(net, dst_orig);
net/xfrm/xfrm_policy.c
3166
struct dst_entry *xfrm_lookup_with_ifid(struct net *net,
net/xfrm/xfrm_policy.c
3228
!READ_ONCE(net->xfrm.policy_count[XFRM_POLICY_OUT])))
net/xfrm/xfrm_policy.c
3231
xdst = xfrm_bundle_lookup(net, fl, family, dir, &xflo, if_id);
net/xfrm/xfrm_policy.c
3253
if (net->xfrm.sysctl_larval_drop) {
net/xfrm/xfrm_policy.c
3254
XFRM_INC_STATS(net, LINUX_MIB_XFRMOUTNOSTATES);
net/xfrm/xfrm_policy.c
3261
XFRM_INC_STATS(net, LINUX_MIB_XFRMOUTNOSTATES);
net/xfrm/xfrm_policy.c
3280
XFRM_INC_STATS(net, LINUX_MIB_XFRMOUTPOLBLOCK);
net/xfrm/xfrm_policy.c
3302
READ_ONCE(net->xfrm.policy_default[dir]) == XFRM_USERPOLICY_BLOCK) {
net/xfrm/xfrm_policy.c
3326
struct dst_entry *xfrm_lookup(struct net *net, struct dst_entry *dst_orig,
net/xfrm/xfrm_policy.c
3330
return xfrm_lookup_with_ifid(net, dst_orig, fl, sk, flags, 0);
net/xfrm/xfrm_policy.c
3337
struct dst_entry *xfrm_lookup_route(struct net *net, struct dst_entry *dst_orig,
net/xfrm/xfrm_policy.c
3341
struct dst_entry *dst = xfrm_lookup(net, dst_orig, fl, sk,
net/xfrm/xfrm_policy.c
3346
return make_blackhole(net, dst_orig->ops->family, dst_orig);
net/xfrm/xfrm_policy.c
3496
int __xfrm_decode_session(struct net *net, struct sk_buff *skb, struct flowi *fl,
net/xfrm/xfrm_policy.c
3502
__skb_flow_dissect(net, skb, &xfrm_session_dissector, &flkeys,
net/xfrm/xfrm_policy.c
3627
struct net *net = dev_net(skb->dev);
net/xfrm/xfrm_policy.c
3632
pol = xfrm_policy_lookup(net, &fl1, family, XFRM_POLICY_FWD, if_id);
net/xfrm/xfrm_policy.c
3645
struct net *net = dev_net(skb->dev);
net/xfrm/xfrm_policy.c
3654
dst2 = xfrm_lookup(net, dst, &fl1, NULL, (XFRM_LOOKUP_QUEUE | XFRM_LOOKUP_ICMP));
net/xfrm/xfrm_policy.c
3673
struct net *net = dev_net(skb->dev);
net/xfrm/xfrm_policy.c
3694
net = r.net;
net/xfrm/xfrm_policy.c
3702
if (__xfrm_decode_session(net, skb, &fl, family, reverse) < 0) {
net/xfrm/xfrm_policy.c
3703
XFRM_INC_STATS(net, LINUX_MIB_XFRMINHDRERROR);
net/xfrm/xfrm_policy.c
3724
XFRM_INC_STATS(net, LINUX_MIB_XFRMINSTATEMISMATCH);
net/xfrm/xfrm_policy.c
3736
XFRM_INC_STATS(net, LINUX_MIB_XFRMINPOLERROR);
net/xfrm/xfrm_policy.c
3742
pol = xfrm_policy_lookup(net, &fl, family, dir, if_id);
net/xfrm/xfrm_policy.c
3745
XFRM_INC_STATS(net, LINUX_MIB_XFRMINPOLERROR);
net/xfrm/xfrm_policy.c
3756
if (READ_ONCE(net->xfrm.policy_default[dir]) == XFRM_USERPOLICY_BLOCK) {
net/xfrm/xfrm_policy.c
3757
XFRM_INC_STATS(net, LINUX_MIB_XFRMINNOPOLS);
net/xfrm/xfrm_policy.c
3763
XFRM_INC_STATS(net, LINUX_MIB_XFRMINNOPOLS);
net/xfrm/xfrm_policy.c
3776
pols[1] = xfrm_policy_lookup_bytype(net, XFRM_POLICY_TYPE_MAIN,
net/xfrm/xfrm_policy.c
3781
XFRM_INC_STATS(net, LINUX_MIB_XFRMINPOLERROR);
net/xfrm/xfrm_policy.c
3808
XFRM_INC_STATS(net, LINUX_MIB_XFRMINPOLBLOCK);
net/xfrm/xfrm_policy.c
3812
XFRM_INC_STATS(net, LINUX_MIB_XFRMINBUFFERERROR);
net/xfrm/xfrm_policy.c
3846
XFRM_INC_STATS(net, LINUX_MIB_XFRMINTMPLMISMATCH);
net/xfrm/xfrm_policy.c
3852
XFRM_INC_STATS(net, LINUX_MIB_XFRMINTMPLMISMATCH);
net/xfrm/xfrm_policy.c
3862
XFRM_INC_STATS(net, LINUX_MIB_XFRMINPOLBLOCK);
net/xfrm/xfrm_policy.c
3874
struct net *net = dev_net(skb->dev);
net/xfrm/xfrm_policy.c
3879
if (xfrm_decode_session(net, skb, &fl, family) < 0) {
net/xfrm/xfrm_policy.c
3880
XFRM_INC_STATS(net, LINUX_MIB_XFRMFWDHDRERROR);
net/xfrm/xfrm_policy.c
3887
XFRM_INC_STATS(net, LINUX_MIB_XFRMFWDHDRERROR);
net/xfrm/xfrm_policy.c
3896
dst = xfrm_lookup(net, dst, &fl, NULL, XFRM_LOOKUP_QUEUE);
net/xfrm/xfrm_policy.c
4184
static int __net_init xfrm_statistics_init(struct net *net)
net/xfrm/xfrm_policy.c
4187
net->mib.xfrm_statistics = alloc_percpu(struct linux_xfrm_mib);
net/xfrm/xfrm_policy.c
4188
if (!net->mib.xfrm_statistics)
net/xfrm/xfrm_policy.c
4190
rv = xfrm_proc_init(net);
net/xfrm/xfrm_policy.c
4192
free_percpu(net->mib.xfrm_statistics);
net/xfrm/xfrm_policy.c
4196
static void xfrm_statistics_fini(struct net *net)
net/xfrm/xfrm_policy.c
4198
xfrm_proc_fini(net);
net/xfrm/xfrm_policy.c
4199
free_percpu(net->mib.xfrm_statistics);
net/xfrm/xfrm_policy.c
4202
static int __net_init xfrm_statistics_init(struct net *net)
net/xfrm/xfrm_policy.c
4207
static void xfrm_statistics_fini(struct net *net)
net/xfrm/xfrm_policy.c
4212
static int __net_init xfrm_policy_init(struct net *net)
net/xfrm/xfrm_policy.c
4217
if (net_eq(net, &init_net)) {
net/xfrm/xfrm_policy.c
4227
net->xfrm.policy_byidx = xfrm_hash_alloc(sz);
net/xfrm/xfrm_policy.c
4228
if (!net->xfrm.policy_byidx)
net/xfrm/xfrm_policy.c
4230
net->xfrm.policy_idx_hmask = hmask;
net/xfrm/xfrm_policy.c
4235
net->xfrm.policy_count[dir] = 0;
net/xfrm/xfrm_policy.c
4236
net->xfrm.policy_count[XFRM_POLICY_MAX + dir] = 0;
net/xfrm/xfrm_policy.c
4238
htab = &net->xfrm.policy_bydst[dir];
net/xfrm/xfrm_policy.c
4248
net->xfrm.policy_hthresh.lbits4 = 32;
net/xfrm/xfrm_policy.c
4249
net->xfrm.policy_hthresh.rbits4 = 32;
net/xfrm/xfrm_policy.c
4250
net->xfrm.policy_hthresh.lbits6 = 128;
net/xfrm/xfrm_policy.c
4251
net->xfrm.policy_hthresh.rbits6 = 128;
net/xfrm/xfrm_policy.c
4253
seqlock_init(&net->xfrm.policy_hthresh.lock);
net/xfrm/xfrm_policy.c
4255
INIT_LIST_HEAD(&net->xfrm.policy_all);
net/xfrm/xfrm_policy.c
4256
INIT_LIST_HEAD(&net->xfrm.inexact_bins);
net/xfrm/xfrm_policy.c
4257
INIT_WORK(&net->xfrm.policy_hash_work, xfrm_hash_resize);
net/xfrm/xfrm_policy.c
4258
INIT_WORK(&net->xfrm.policy_hthresh.work, xfrm_hash_rebuild);
net/xfrm/xfrm_policy.c
4265
htab = &net->xfrm.policy_bydst[dir];
net/xfrm/xfrm_policy.c
4268
xfrm_hash_free(net->xfrm.policy_byidx, sz);
net/xfrm/xfrm_policy.c
4273
static void __net_exit xfrm_net_pre_exit(struct net *net)
net/xfrm/xfrm_policy.c
4275
disable_work_sync(&net->xfrm.policy_hthresh.work);
net/xfrm/xfrm_policy.c
4276
flush_work(&net->xfrm.policy_hash_work);
net/xfrm/xfrm_policy.c
4278
xfrm_policy_flush(net, XFRM_POLICY_TYPE_SUB, false);
net/xfrm/xfrm_policy.c
4280
xfrm_policy_flush(net, XFRM_POLICY_TYPE_MAIN, false);
net/xfrm/xfrm_policy.c
4283
static void xfrm_policy_fini(struct net *net)
net/xfrm/xfrm_policy.c
4289
WARN_ON(!list_empty(&net->xfrm.policy_all));
net/xfrm/xfrm_policy.c
4294
htab = &net->xfrm.policy_bydst[dir];
net/xfrm/xfrm_policy.c
4300
sz = (net->xfrm.policy_idx_hmask + 1) * sizeof(struct hlist_head);
net/xfrm/xfrm_policy.c
4301
WARN_ON(!hlist_empty(net->xfrm.policy_byidx));
net/xfrm/xfrm_policy.c
4302
xfrm_hash_free(net->xfrm.policy_byidx, sz);
net/xfrm/xfrm_policy.c
4304
spin_lock_bh(&net->xfrm.xfrm_policy_lock);
net/xfrm/xfrm_policy.c
4305
list_for_each_entry_safe(b, t, &net->xfrm.inexact_bins, inexact_bins)
net/xfrm/xfrm_policy.c
4307
spin_unlock_bh(&net->xfrm.xfrm_policy_lock);
net/xfrm/xfrm_policy.c
431
struct xfrm_policy *xfrm_policy_alloc(struct net *net, gfp_t gfp)
net/xfrm/xfrm_policy.c
4310
static int __net_init xfrm_net_init(struct net *net)
net/xfrm/xfrm_policy.c
4315
spin_lock_init(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_policy.c
4316
spin_lock_init(&net->xfrm.xfrm_policy_lock);
net/xfrm/xfrm_policy.c
4317
seqcount_spinlock_init(&net->xfrm.xfrm_policy_hash_generation, &net->xfrm.xfrm_policy_lock);
net/xfrm/xfrm_policy.c
4318
mutex_init(&net->xfrm.xfrm_cfg_mutex);
net/xfrm/xfrm_policy.c
4319
net->xfrm.policy_default[XFRM_POLICY_IN] = XFRM_USERPOLICY_ACCEPT;
net/xfrm/xfrm_policy.c
4320
net->xfrm.policy_default[XFRM_POLICY_FWD] = XFRM_USERPOLICY_ACCEPT;
net/xfrm/xfrm_policy.c
4321
net->xfrm.policy_default[XFRM_POLICY_OUT] = XFRM_USERPOLICY_ACCEPT;
net/xfrm/xfrm_policy.c
4323
rv = xfrm_statistics_init(net);
net/xfrm/xfrm_policy.c
4326
rv = xfrm_state_init(net);
net/xfrm/xfrm_policy.c
4329
rv = xfrm_policy_init(net);
net/xfrm/xfrm_policy.c
4332
rv = xfrm_sysctl_init(net);
net/xfrm/xfrm_policy.c
4336
rv = xfrm_nat_keepalive_net_init(net);
net/xfrm/xfrm_policy.c
4343
xfrm_sysctl_fini(net);
net/xfrm/xfrm_policy.c
4345
xfrm_policy_fini(net);
net/xfrm/xfrm_policy.c
4347
xfrm_state_fini(net);
net/xfrm/xfrm_policy.c
4349
xfrm_statistics_fini(net);
net/xfrm/xfrm_policy.c
4354
static void __net_exit xfrm_net_exit(struct net *net)
net/xfrm/xfrm_policy.c
4356
xfrm_nat_keepalive_net_fini(net);
net/xfrm/xfrm_policy.c
4357
xfrm_sysctl_fini(net);
net/xfrm/xfrm_policy.c
4358
xfrm_policy_fini(net);
net/xfrm/xfrm_policy.c
4359
xfrm_state_fini(net);
net/xfrm/xfrm_policy.c
4360
xfrm_statistics_fini(net);
net/xfrm/xfrm_policy.c
438
write_pnet(&policy->xp_net, net);
net/xfrm/xfrm_policy.c
4489
u8 dir, u8 type, struct net *net, u32 if_id)
net/xfrm/xfrm_policy.c
4523
pol = xfrm_policy_lookup_bytype(net, type, &fl, sel->family, dir, if_id);
net/xfrm/xfrm_policy.c
4658
struct xfrm_kmaddress *k, struct net *net,
net/xfrm/xfrm_policy.c
4681
pol = xfrm_migrate_policy_find(sel, dir, type, net, if_id);
net/xfrm/xfrm_policy.c
4690
if ((x = xfrm_migrate_state_find(mp, net, if_id))) {
net/xfrm/xfrm_policy.c
4697
xc = xfrm_state_migrate(x, mp, net, extack);
net/xfrm/xfrm_policy.c
4720
km_migrate(sel, dir, type, m, num_migrate, k, net, encap);
net/xfrm/xfrm_policy.c
482
struct net *net = xp_net(policy);
net/xfrm/xfrm_policy.c
501
spin_lock_bh(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_policy.c
505
spin_unlock_bh(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_policy.c
512
static inline unsigned int idx_hash(struct net *net, u32 index)
net/xfrm/xfrm_policy.c
514
return __idx_hash(index, net->xfrm.policy_idx_hmask);
net/xfrm/xfrm_policy.c
518
static void __get_hash_thresh(struct net *net,
net/xfrm/xfrm_policy.c
524
*dbits = net->xfrm.policy_bydst[dir].dbits4;
net/xfrm/xfrm_policy.c
525
*sbits = net->xfrm.policy_bydst[dir].sbits4;
net/xfrm/xfrm_policy.c
529
*dbits = net->xfrm.policy_bydst[dir].dbits6;
net/xfrm/xfrm_policy.c
530
*sbits = net->xfrm.policy_bydst[dir].sbits6;
net/xfrm/xfrm_policy.c
539
static struct hlist_head *policy_hash_bysel(struct net *net,
net/xfrm/xfrm_policy.c
543
unsigned int hmask = net->xfrm.policy_bydst[dir].hmask;
net/xfrm/xfrm_policy.c
548
__get_hash_thresh(net, family, dir, &dbits, &sbits);
net/xfrm/xfrm_policy.c
554
return rcu_dereference_check(net->xfrm.policy_bydst[dir].table,
net/xfrm/xfrm_policy.c
555
lockdep_is_held(&net->xfrm.xfrm_policy_lock)) + hash;
net/xfrm/xfrm_policy.c
558
static struct hlist_head *policy_hash_direct(struct net *net,
net/xfrm/xfrm_policy.c
563
unsigned int hmask = net->xfrm.policy_bydst[dir].hmask;
net/xfrm/xfrm_policy.c
568
__get_hash_thresh(net, family, dir, &dbits, &sbits);
net/xfrm/xfrm_policy.c
571
return rcu_dereference_check(net->xfrm.policy_bydst[dir].table,
net/xfrm/xfrm_policy.c
572
lockdep_is_held(&net->xfrm.xfrm_policy_lock)) + hash;
net/xfrm/xfrm_policy.c
575
static void xfrm_dst_hash_transfer(struct net *net,
net/xfrm/xfrm_policy.c
591
__get_hash_thresh(net, pol->family, dir, &dbits, &sbits);
net/xfrm/xfrm_policy.c
632
static void xfrm_bydst_resize(struct net *net, int dir)
net/xfrm/xfrm_policy.c
634
unsigned int hmask = net->xfrm.policy_bydst[dir].hmask;
net/xfrm/xfrm_policy.c
644
spin_lock_bh(&net->xfrm.xfrm_policy_lock);
net/xfrm/xfrm_policy.c
645
write_seqcount_begin(&net->xfrm.xfrm_policy_hash_generation);
net/xfrm/xfrm_policy.c
647
odst = rcu_dereference_protected(net->xfrm.policy_bydst[dir].table,
net/xfrm/xfrm_policy.c
648
lockdep_is_held(&net->xfrm.xfrm_policy_lock));
net/xfrm/xfrm_policy.c
651
xfrm_dst_hash_transfer(net, odst + i, ndst, nhashmask, dir);
net/xfrm/xfrm_policy.c
653
rcu_assign_pointer(net->xfrm.policy_bydst[dir].table, ndst);
net/xfrm/xfrm_policy.c
654
net->xfrm.policy_bydst[dir].hmask = nhashmask;
net/xfrm/xfrm_policy.c
656
write_seqcount_end(&net->xfrm.xfrm_policy_hash_generation);
net/xfrm/xfrm_policy.c
657
spin_unlock_bh(&net->xfrm.xfrm_policy_lock);
net/xfrm/xfrm_policy.c
664
static void xfrm_byidx_resize(struct net *net)
net/xfrm/xfrm_policy.c
666
unsigned int hmask = net->xfrm.policy_idx_hmask;
net/xfrm/xfrm_policy.c
669
struct hlist_head *oidx = net->xfrm.policy_byidx;
net/xfrm/xfrm_policy.c
676
spin_lock_bh(&net->xfrm.xfrm_policy_lock);
net/xfrm/xfrm_policy.c
681
net->xfrm.policy_byidx = nidx;
net/xfrm/xfrm_policy.c
682
net->xfrm.policy_idx_hmask = nhashmask;
net/xfrm/xfrm_policy.c
684
spin_unlock_bh(&net->xfrm.xfrm_policy_lock);
net/xfrm/xfrm_policy.c
689
static inline int xfrm_bydst_should_resize(struct net *net, int dir, int *total)
net/xfrm/xfrm_policy.c
691
unsigned int cnt = READ_ONCE(net->xfrm.policy_count[dir]);
net/xfrm/xfrm_policy.c
692
unsigned int hmask = net->xfrm.policy_bydst[dir].hmask;
net/xfrm/xfrm_policy.c
704
static inline int xfrm_byidx_should_resize(struct net *net, int total)
net/xfrm/xfrm_policy.c
706
unsigned int hmask = net->xfrm.policy_idx_hmask;
net/xfrm/xfrm_policy.c
715
void xfrm_spd_getinfo(struct net *net, struct xfrmk_spdinfo *si)
net/xfrm/xfrm_policy.c
717
si->incnt = READ_ONCE(net->xfrm.policy_count[XFRM_POLICY_IN]);
net/xfrm/xfrm_policy.c
718
si->outcnt = READ_ONCE(net->xfrm.policy_count[XFRM_POLICY_OUT]);
net/xfrm/xfrm_policy.c
719
si->fwdcnt = READ_ONCE(net->xfrm.policy_count[XFRM_POLICY_FWD]);
net/xfrm/xfrm_policy.c
720
si->inscnt = READ_ONCE(net->xfrm.policy_count[XFRM_POLICY_IN+XFRM_POLICY_MAX]);
net/xfrm/xfrm_policy.c
721
si->outscnt = READ_ONCE(net->xfrm.policy_count[XFRM_POLICY_OUT+XFRM_POLICY_MAX]);
net/xfrm/xfrm_policy.c
722
si->fwdscnt = READ_ONCE(net->xfrm.policy_count[XFRM_POLICY_FWD+XFRM_POLICY_MAX]);
net/xfrm/xfrm_policy.c
723
si->spdhcnt = net->xfrm.policy_idx_hmask;
net/xfrm/xfrm_policy.c
731
struct net *net = container_of(work, struct net, xfrm.policy_hash_work);
net/xfrm/xfrm_policy.c
738
if (xfrm_bydst_should_resize(net, dir, &total))
net/xfrm/xfrm_policy.c
739
xfrm_bydst_resize(net, dir);
net/xfrm/xfrm_policy.c
741
if (xfrm_byidx_should_resize(net, total))
net/xfrm/xfrm_policy.c
742
xfrm_byidx_resize(net);
net/xfrm/xfrm_policy.c
761
struct net *net = xp_net(pol);
net/xfrm/xfrm_policy.c
763
lockdep_assert_held(&net->xfrm.xfrm_policy_lock);
net/xfrm/xfrm_policy.c
765
write_pnet(&k.net, net);
net/xfrm/xfrm_policy.c
779
seqcount_spinlock_init(&bin->count, &net->xfrm.xfrm_policy_lock);
net/xfrm/xfrm_policy.c
785
list_add(&bin->inexact_bins, &net->xfrm.inexact_bins);
net/xfrm/xfrm_policy.c
895
static void xfrm_policy_inexact_list_reinsert(struct net *net,
net/xfrm/xfrm_policy.c
905
list_for_each_entry_reverse(policy, &net->xfrm.policy_all, walk.all) {
net/xfrm/xfrm_policy.c
958
static void xfrm_policy_inexact_node_reinsert(struct net *net,
net/xfrm/xfrm_policy.c
997
xfrm_policy_inexact_list_reinsert(net, node, family);
net/xfrm/xfrm_proc.c
54
struct net *net = seq->private;
net/xfrm/xfrm_proc.c
59
xfrm_state_update_stats(net);
net/xfrm/xfrm_proc.c
61
net->mib.xfrm_statistics);
net/xfrm/xfrm_proc.c
69
int __net_init xfrm_proc_init(struct net *net)
net/xfrm/xfrm_proc.c
71
if (!proc_create_net_single("xfrm_stat", 0444, net->proc_net,
net/xfrm/xfrm_proc.c
77
void xfrm_proc_fini(struct net *net)
net/xfrm/xfrm_proc.c
79
remove_proc_entry("xfrm_stat", net->proc_net);
net/xfrm/xfrm_replay.c
101
struct net *net = xs_net(x);
net/xfrm/xfrm_replay.c
114
if (xfrm_aevent_is_on(net))
net/xfrm/xfrm_replay.c
193
struct net *net = xs_net(x);
net/xfrm/xfrm_replay.c
206
if (xfrm_aevent_is_on(net))
net/xfrm/xfrm_replay.c
426
struct net *net = xs_net(x);
net/xfrm/xfrm_replay.c
444
if (xfrm_aevent_is_on(net))
net/xfrm/xfrm_replay.c
615
struct net *net = xs_net(x);
net/xfrm/xfrm_replay.c
644
if (xfrm_aevent_is_on(net))
net/xfrm/xfrm_replay.c
656
struct net *net = xs_net(x);
net/xfrm/xfrm_replay.c
684
if (xfrm_aevent_is_on(net))
net/xfrm/xfrm_replay.c
696
struct net *net = xs_net(x);
net/xfrm/xfrm_replay.c
736
if (xfrm_aevent_is_on(net))
net/xfrm/xfrm_state.c
1001
spin_unlock_bh(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
1024
void xfrm_sad_getinfo(struct net *net, struct xfrmk_sadinfo *si)
net/xfrm/xfrm_state.c
1026
spin_lock_bh(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
1027
si->sadcnt = net->xfrm.state_num;
net/xfrm/xfrm_state.c
1028
si->sadhcnt = net->xfrm.state_hmask + 1;
net/xfrm/xfrm_state.c
1030
spin_unlock_bh(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
1117
static void xfrm_hash_ptrs_get(const struct net *net, struct xfrm_hash_state_ptrs *ptrs)
net/xfrm/xfrm_state.c
1122
sequence = read_seqcount_begin(&net->xfrm.xfrm_state_hash_generation);
net/xfrm/xfrm_state.c
1124
ptrs->bydst = xfrm_state_deref_check(net->xfrm.state_bydst, net);
net/xfrm/xfrm_state.c
1125
ptrs->bysrc = xfrm_state_deref_check(net->xfrm.state_bysrc, net);
net/xfrm/xfrm_state.c
1126
ptrs->byspi = xfrm_state_deref_check(net->xfrm.state_byspi, net);
net/xfrm/xfrm_state.c
1127
ptrs->hmask = net->xfrm.state_hmask;
net/xfrm/xfrm_state.c
1128
} while (read_seqcount_retry(&net->xfrm.xfrm_state_hash_generation, sequence));
net/xfrm/xfrm_state.c
1201
struct xfrm_state *xfrm_input_state_lookup(struct net *net, u32 mark,
net/xfrm/xfrm_state.c
1213
state_cache_input = raw_cpu_ptr(net->xfrm.state_cache_input);
net/xfrm/xfrm_state.c
1229
xfrm_hash_ptrs_get(net, &state_ptrs);
net/xfrm/xfrm_state.c
1233
spin_lock(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
1247
spin_unlock(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
1285
struct net *net = xs_net(x);
net/xfrm/xfrm_state.c
1288
xfrm_hash_ptrs_get(net, &state_ptrs);
net/xfrm/xfrm_state.c
1300
static void xfrm_hash_grow_check(struct net *net, int have_hash_collision)
net/xfrm/xfrm_state.c
1303
(net->xfrm.state_hmask + 1) < xfrm_state_hashmax &&
net/xfrm/xfrm_state.c
1304
net->xfrm.state_num > net->xfrm.state_hmask)
net/xfrm/xfrm_state.c
1305
schedule_work(&net->xfrm.state_hash_work);
net/xfrm/xfrm_state.c
1363
struct net *net = xp_net(pol);
net/xfrm/xfrm_state.c
1383
sequence = read_seqcount_begin(&net->xfrm.xfrm_state_hash_generation);
net/xfrm/xfrm_state.c
1386
xfrm_hash_ptrs_get(net, &state_ptrs);
net/xfrm/xfrm_state.c
1511
c.net = net;
net/xfrm/xfrm_state.c
1521
x = xfrm_state_alloc(net);
net/xfrm/xfrm_state.c
1568
spin_lock_bh(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
1571
list_add(&x->km.all, &net->xfrm.state_all);
net/xfrm/xfrm_state.c
1572
h = xfrm_dst_hash(net, daddr, saddr, tmpl->reqid, encap_family);
net/xfrm/xfrm_state.c
1574
xfrm_state_deref_prot(net->xfrm.state_bydst, net) + h,
net/xfrm/xfrm_state.c
1576
h = xfrm_src_hash(net, daddr, saddr, encap_family);
net/xfrm/xfrm_state.c
1578
xfrm_state_deref_prot(net->xfrm.state_bysrc, net) + h,
net/xfrm/xfrm_state.c
1582
h = xfrm_spi_hash(net, &x->id.daddr, x->id.spi, x->id.proto, encap_family);
net/xfrm/xfrm_state.c
1584
xfrm_state_deref_prot(net->xfrm.state_byspi, net) + h,
net/xfrm/xfrm_state.c
1588
h = xfrm_seq_hash(net, x->km.seq);
net/xfrm/xfrm_state.c
1590
xfrm_state_deref_prot(net->xfrm.state_byseq, net) + h,
net/xfrm/xfrm_state.c
1593
x->lft.hard_add_expires_seconds = net->xfrm.sysctl_acq_expires;
net/xfrm/xfrm_state.c
1595
ktime_set(net->xfrm.sysctl_acq_expires, 0),
net/xfrm/xfrm_state.c
1597
net->xfrm.state_num++;
net/xfrm/xfrm_state.c
1598
xfrm_hash_grow_check(net, x->bydst.next != NULL);
net/xfrm/xfrm_state.c
1599
spin_unlock_bh(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
163
struct net *net = container_of(work, struct net, xfrm.state_hash_work);
net/xfrm/xfrm_state.c
1632
spin_lock_bh(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
1635
spin_unlock_bh(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
1642
if (read_seqcount_retry(&net->xfrm.xfrm_state_hash_generation, sequence)) {
net/xfrm/xfrm_state.c
1654
xfrm_stateonly_find(struct net *net, u32 mark, u32 if_id,
net/xfrm/xfrm_state.c
1661
spin_lock_bh(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
1662
h = xfrm_dst_hash(net, daddr, saddr, reqid, family);
net/xfrm/xfrm_state.c
1663
hlist_for_each_entry(x, xfrm_state_deref_prot(net->xfrm.state_bydst, net) + h, bydst) {
net/xfrm/xfrm_state.c
1680
spin_unlock_bh(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
1687
struct xfrm_state *xfrm_state_lookup_byspi(struct net *net, __be32 spi,
net/xfrm/xfrm_state.c
169
nsize = xfrm_hash_new_size(net->xfrm.state_hmask);
net/xfrm/xfrm_state.c
1693
spin_lock_bh(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
1694
list_for_each_entry(w, &net->xfrm.state_all, all) {
net/xfrm/xfrm_state.c
1701
spin_unlock_bh(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
1704
spin_unlock_bh(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
1709
static struct xfrm_state *xfrm_state_lookup_spi_proto(struct net *net, __be32 spi, u8 proto)
net/xfrm/xfrm_state.c
1714
for (i = 0; i <= net->xfrm.state_hmask; i++) {
net/xfrm/xfrm_state.c
1715
hlist_for_each_entry(x, xfrm_state_deref_prot(net->xfrm.state_byspi, net) + i, byspi) {
net/xfrm/xfrm_state.c
1725
struct net *net = xs_net(x);
net/xfrm/xfrm_state.c
1728
list_add(&x->km.all, &net->xfrm.state_all);
net/xfrm/xfrm_state.c
1733
h = xfrm_dst_hash(net, &x->id.daddr, &x->props.saddr,
net/xfrm/xfrm_state.c
1736
xfrm_state_deref_prot(net->xfrm.state_bydst, net) + h,
net/xfrm/xfrm_state.c
1739
h = xfrm_src_hash(net, &x->id.daddr, &x->props.saddr, x->props.family);
net/xfrm/xfrm_state.c
1741
xfrm_state_deref_prot(net->xfrm.state_bysrc, net) + h,
net/xfrm/xfrm_state.c
1745
h = xfrm_spi_hash(net, &x->id.daddr, x->id.spi, x->id.proto,
net/xfrm/xfrm_state.c
1749
xfrm_state_deref_prot(net->xfrm.state_byspi, net) + h,
net/xfrm/xfrm_state.c
1754
h = xfrm_seq_hash(net, x->km.seq);
net/xfrm/xfrm_state.c
1757
xfrm_state_deref_prot(net->xfrm.state_byseq, net) + h,
net/xfrm/xfrm_state.c
1765
net->xfrm.state_num++;
net/xfrm/xfrm_state.c
1767
xfrm_hash_grow_check(net, x->bydst.next != NULL);
net/xfrm/xfrm_state.c
1774
struct net *net = xs_net(xnew);
net/xfrm/xfrm_state.c
1783
h = xfrm_dst_hash(net, &xnew->id.daddr, &xnew->props.saddr, reqid, family);
net/xfrm/xfrm_state.c
1784
hlist_for_each_entry(x, xfrm_state_deref_prot(net->xfrm.state_bydst, net) + h, bydst) {
net/xfrm/xfrm_state.c
1798
struct net *net = xs_net(x);
net/xfrm/xfrm_state.c
1800
spin_lock_bh(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
1803
spin_unlock_bh(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
1808
static struct xfrm_state *__find_acq_core(struct net *net,
net/xfrm/xfrm_state.c
1816
unsigned int h = xfrm_dst_hash(net, daddr, saddr, reqid, family);
net/xfrm/xfrm_state.c
1820
hlist_for_each_entry(x, xfrm_state_deref_prot(net->xfrm.state_bydst, net) + h, bydst) {
net/xfrm/xfrm_state.c
1840
x = xfrm_state_alloc(net);
net/xfrm/xfrm_state.c
1871
x->lft.hard_add_expires_seconds = net->xfrm.sysctl_acq_expires;
net/xfrm/xfrm_state.c
1874
ktime_set(net->xfrm.sysctl_acq_expires, 0),
net/xfrm/xfrm_state.c
1876
list_add(&x->km.all, &net->xfrm.state_all);
net/xfrm/xfrm_state.c
1878
xfrm_state_deref_prot(net->xfrm.state_bydst, net) + h,
net/xfrm/xfrm_state.c
1880
h = xfrm_src_hash(net, daddr, saddr, family);
net/xfrm/xfrm_state.c
1882
xfrm_state_deref_prot(net->xfrm.state_bysrc, net) + h,
net/xfrm/xfrm_state.c
1885
net->xfrm.state_num++;
net/xfrm/xfrm_state.c
1887
xfrm_hash_grow_check(net, x->bydst.next != NULL);
net/xfrm/xfrm_state.c
1893
static struct xfrm_state *__xfrm_find_acq_byseq(struct net *net, u32 mark, u32 seq, u32 pcpu_num);
net/xfrm/xfrm_state.c
1897
struct net *net = xs_net(x);
net/xfrm/xfrm_state.c
1908
spin_lock_bh(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
1919
x1 = __xfrm_find_acq_byseq(net, mark, x->km.seq, x->pcpu_num);
net/xfrm/xfrm_state.c
192
spin_lock_bh(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
1928
x1 = __find_acq_core(net, &x->mark, family, x->props.mode,
net/xfrm/xfrm_state.c
193
write_seqcount_begin(&net->xfrm.xfrm_state_hash_generation);
net/xfrm/xfrm_state.c
1937
spin_unlock_bh(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
196
odst = xfrm_state_deref_prot(net->xfrm.state_bydst, net);
net/xfrm/xfrm_state.c
197
for (i = net->xfrm.state_hmask; i >= 0; i--)
net/xfrm/xfrm_state.c
1979
struct net *net = xs_net(orig);
net/xfrm/xfrm_state.c
1980
struct xfrm_state *x = xfrm_state_alloc(net);
net/xfrm/xfrm_state.c
200
osrc = xfrm_state_deref_prot(net->xfrm.state_bysrc, net);
net/xfrm/xfrm_state.c
201
ospi = xfrm_state_deref_prot(net->xfrm.state_byspi, net);
net/xfrm/xfrm_state.c
202
oseq = xfrm_state_deref_prot(net->xfrm.state_byseq, net);
net/xfrm/xfrm_state.c
203
ohashmask = net->xfrm.state_hmask;
net/xfrm/xfrm_state.c
205
rcu_assign_pointer(net->xfrm.state_bydst, ndst);
net/xfrm/xfrm_state.c
206
rcu_assign_pointer(net->xfrm.state_bysrc, nsrc);
net/xfrm/xfrm_state.c
207
rcu_assign_pointer(net->xfrm.state_byspi, nspi);
net/xfrm/xfrm_state.c
208
rcu_assign_pointer(net->xfrm.state_byseq, nseq);
net/xfrm/xfrm_state.c
209
net->xfrm.state_hmask = nhashmask;
net/xfrm/xfrm_state.c
2096
struct xfrm_state *xfrm_migrate_state_find(struct xfrm_migrate *m, struct net *net,
net/xfrm/xfrm_state.c
2102
spin_lock_bh(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
2105
h = xfrm_dst_hash(net, &m->old_daddr, &m->old_saddr,
net/xfrm/xfrm_state.c
2107
hlist_for_each_entry(x, xfrm_state_deref_prot(net->xfrm.state_bydst, net) + h, bydst) {
net/xfrm/xfrm_state.c
211
write_seqcount_end(&net->xfrm.xfrm_state_hash_generation);
net/xfrm/xfrm_state.c
212
spin_unlock_bh(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
2124
h = xfrm_src_hash(net, &m->old_daddr, &m->old_saddr,
net/xfrm/xfrm_state.c
2126
hlist_for_each_entry(x, xfrm_state_deref_prot(net->xfrm.state_bysrc, net) + h, bysrc) {
net/xfrm/xfrm_state.c
2142
spin_unlock_bh(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
2150
struct net *net,
net/xfrm/xfrm_state.c
2167
if (m->xuo && xfrm_dev_state_add(net, xc, m->xuo, extack))
net/xfrm/xfrm_state.c
2207
struct net *net,
net/xfrm/xfrm_state.c
2212
xc = xfrm_state_migrate_create(x, m, net, extack);
net/xfrm/xfrm_state.c
2231
struct net *net = xs_net(x);
net/xfrm/xfrm_state.c
2235
spin_lock_bh(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
2265
spin_unlock_bh(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
2302
spin_lock_bh(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
2311
spin_unlock_bh(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
2358
void xfrm_state_update_stats(struct net *net)
net/xfrm/xfrm_state.c
2363
spin_lock_bh(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
2364
for (i = 0; i <= net->xfrm.state_hmask; i++) {
net/xfrm/xfrm_state.c
2365
hlist_for_each_entry(x, xfrm_state_deref_prot(net->xfrm.state_bydst, net) + i, bydst)
net/xfrm/xfrm_state.c
2368
spin_unlock_bh(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
2372
xfrm_state_lookup(struct net *net, u32 mark, const xfrm_address_t *daddr, __be32 spi,
net/xfrm/xfrm_state.c
2379
xfrm_hash_ptrs_get(net, &state_ptrs);
net/xfrm/xfrm_state.c
2388
xfrm_state_lookup_byaddr(struct net *net, u32 mark,
net/xfrm/xfrm_state.c
2397
xfrm_hash_ptrs_get(net, &state_ptrs);
net/xfrm/xfrm_state.c
2406
xfrm_find_acq(struct net *net, const struct xfrm_mark *mark, u8 mode, u32 reqid,
net/xfrm/xfrm_state.c
2412
spin_lock_bh(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
2413
x = __find_acq_core(net, mark, family, mode, reqid, if_id, pcpu_num,
net/xfrm/xfrm_state.c
2415
spin_unlock_bh(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
2551
static struct xfrm_state *__xfrm_find_acq_byseq(struct net *net, u32 mark, u32 seq, u32 pcpu_num)
net/xfrm/xfrm_state.c
2553
unsigned int h = xfrm_seq_hash(net, seq);
net/xfrm/xfrm_state.c
2556
hlist_for_each_entry(x, xfrm_state_deref_prot(net->xfrm.state_byseq, net) + h, byseq) {
net/xfrm/xfrm_state.c
2569
struct xfrm_state *xfrm_find_acq_byseq(struct net *net, u32 mark, u32 seq, u32 pcpu_num)
net/xfrm/xfrm_state.c
2573
spin_lock_bh(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
2574
x = __xfrm_find_acq_byseq(net, mark, seq, pcpu_num);
net/xfrm/xfrm_state.c
2575
spin_unlock_bh(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
2625
struct net *net = xs_net(x);
net/xfrm/xfrm_state.c
2650
spin_lock_bh(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
2651
x0 = xfrm_state_lookup_spi_proto(net, newspi, x->id.proto);
net/xfrm/xfrm_state.c
2654
h = xfrm_spi_hash(net, &x->id.daddr, newspi, x->id.proto, x->props.family);
net/xfrm/xfrm_state.c
2656
xfrm_state_deref_prot(net->xfrm.state_byspi, net) + h,
net/xfrm/xfrm_state.c
2658
spin_unlock_bh(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
2662
spin_unlock_bh(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
2701
int xfrm_state_walk(struct net *net, struct xfrm_state_walk *walk,
net/xfrm/xfrm_state.c
2712
spin_lock_bh(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
2714
x = list_first_entry(&net->xfrm.state_all, struct xfrm_state_walk, all);
net/xfrm/xfrm_state.c
2717
list_for_each_entry_from(x, &net->xfrm.state_all, all) {
net/xfrm/xfrm_state.c
2738
spin_unlock_bh(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
2754
void xfrm_state_walk_done(struct xfrm_state_walk *walk, struct net *net)
net/xfrm/xfrm_state.c
2761
spin_lock_bh(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
2763
spin_unlock_bh(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
2889
const struct xfrm_kmaddress *k, struct net *net,
net/xfrm/xfrm_state.c
2900
net, encap);
net/xfrm/xfrm_state.c
2911
int km_report(struct net *net, u8 proto, struct xfrm_selector *sel, xfrm_address_t *addr)
net/xfrm/xfrm_state.c
2920
ret = km->report(net, proto, sel, addr);
net/xfrm/xfrm_state.c
3325
int __net_init xfrm_state_init(struct net *net)
net/xfrm/xfrm_state.c
3330
if (net_eq(net, &init_net))
net/xfrm/xfrm_state.c
3334
INIT_LIST_HEAD(&net->xfrm.state_all);
net/xfrm/xfrm_state.c
3341
rcu_assign_pointer(net->xfrm.state_bydst, ndst);
net/xfrm/xfrm_state.c
3346
rcu_assign_pointer(net->xfrm.state_bysrc, nsrc);
net/xfrm/xfrm_state.c
3351
rcu_assign_pointer(net->xfrm.state_byspi, nspi);
net/xfrm/xfrm_state.c
3356
rcu_assign_pointer(net->xfrm.state_byseq, nseq);
net/xfrm/xfrm_state.c
3358
net->xfrm.state_cache_input = alloc_percpu(struct hlist_head);
net/xfrm/xfrm_state.c
3359
if (!net->xfrm.state_cache_input)
net/xfrm/xfrm_state.c
3362
net->xfrm.state_hmask = ((sz / sizeof(struct hlist_head)) - 1);
net/xfrm/xfrm_state.c
3364
net->xfrm.state_num = 0;
net/xfrm/xfrm_state.c
3365
INIT_WORK(&net->xfrm.state_hash_work, xfrm_hash_resize);
net/xfrm/xfrm_state.c
3366
spin_lock_init(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
3367
seqcount_spinlock_init(&net->xfrm.xfrm_state_hash_generation,
net/xfrm/xfrm_state.c
3368
&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
3385
void xfrm_state_fini(struct net *net)
net/xfrm/xfrm_state.c
3390
flush_work(&net->xfrm.state_hash_work);
net/xfrm/xfrm_state.c
3391
xfrm_state_flush(net, 0, false);
net/xfrm/xfrm_state.c
3394
WARN_ON(!list_empty(&net->xfrm.state_all));
net/xfrm/xfrm_state.c
3396
for (i = 0; i <= net->xfrm.state_hmask; i++) {
net/xfrm/xfrm_state.c
3397
WARN_ON(!hlist_empty(xfrm_state_deref_netexit(net->xfrm.state_byseq) + i));
net/xfrm/xfrm_state.c
3398
WARN_ON(!hlist_empty(xfrm_state_deref_netexit(net->xfrm.state_byspi) + i));
net/xfrm/xfrm_state.c
3399
WARN_ON(!hlist_empty(xfrm_state_deref_netexit(net->xfrm.state_bysrc) + i));
net/xfrm/xfrm_state.c
3400
WARN_ON(!hlist_empty(xfrm_state_deref_netexit(net->xfrm.state_bydst) + i));
net/xfrm/xfrm_state.c
3403
sz = (net->xfrm.state_hmask + 1) * sizeof(struct hlist_head);
net/xfrm/xfrm_state.c
3404
xfrm_hash_free(xfrm_state_deref_netexit(net->xfrm.state_byseq), sz);
net/xfrm/xfrm_state.c
3405
xfrm_hash_free(xfrm_state_deref_netexit(net->xfrm.state_byspi), sz);
net/xfrm/xfrm_state.c
3406
xfrm_hash_free(xfrm_state_deref_netexit(net->xfrm.state_bysrc), sz);
net/xfrm/xfrm_state.c
3407
xfrm_hash_free(xfrm_state_deref_netexit(net->xfrm.state_bydst), sz);
net/xfrm/xfrm_state.c
3408
free_percpu(net->xfrm.state_cache_input);
net/xfrm/xfrm_state.c
35
#define xfrm_state_deref_prot(table, net) \
net/xfrm/xfrm_state.c
36
rcu_dereference_protected((table), lockdep_is_held(&(net)->xfrm.xfrm_state_lock))
net/xfrm/xfrm_state.c
37
#define xfrm_state_deref_check(table, net) \
net/xfrm/xfrm_state.c
38
rcu_dereference_check((table), lockdep_is_held(&(net)->xfrm.xfrm_state_lock))
net/xfrm/xfrm_state.c
61
static inline unsigned int xfrm_dst_hash(struct net *net,
net/xfrm/xfrm_state.c
67
lockdep_assert_held(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
69
return __xfrm_dst_hash(daddr, saddr, reqid, family, net->xfrm.state_hmask);
net/xfrm/xfrm_state.c
72
static inline unsigned int xfrm_src_hash(struct net *net,
net/xfrm/xfrm_state.c
731
struct xfrm_state *xfrm_state_alloc(struct net *net)
net/xfrm/xfrm_state.c
738
write_pnet(&x->xs_net, net);
net/xfrm/xfrm_state.c
77
lockdep_assert_held(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
79
return __xfrm_src_hash(daddr, saddr, family, net->xfrm.state_hmask);
net/xfrm/xfrm_state.c
813
struct net *net = xs_net(x);
net/xfrm/xfrm_state.c
819
spin_lock(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
83
xfrm_spi_hash(struct net *net, const xfrm_address_t *daddr,
net/xfrm/xfrm_state.c
832
net->xfrm.state_num--;
net/xfrm/xfrm_state.c
834
spin_unlock(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
86
lockdep_assert_held(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
866
xfrm_state_flush_secctx_check(struct net *net, u8 proto, bool task_valid)
net/xfrm/xfrm_state.c
870
for (i = 0; i <= net->xfrm.state_hmask; i++) {
net/xfrm/xfrm_state.c
873
hlist_for_each_entry(x, xfrm_state_deref_prot(net->xfrm.state_bydst, net) + i, bydst) {
net/xfrm/xfrm_state.c
88
return __xfrm_spi_hash(daddr, spi, proto, family, net->xfrm.state_hmask);
net/xfrm/xfrm_state.c
886
xfrm_dev_state_flush_secctx_check(struct net *net, struct net_device *dev, bool task_valid)
net/xfrm/xfrm_state.c
890
for (i = 0; i <= net->xfrm.state_hmask; i++) {
net/xfrm/xfrm_state.c
894
hlist_for_each_entry(x, xfrm_state_deref_prot(net->xfrm.state_bydst, net) + i, bydst) {
net/xfrm/xfrm_state.c
909
xfrm_state_flush_secctx_check(struct net *net, u8 proto, bool task_valid)
net/xfrm/xfrm_state.c
91
static unsigned int xfrm_seq_hash(struct net *net, u32 seq)
net/xfrm/xfrm_state.c
915
xfrm_dev_state_flush_secctx_check(struct net *net, struct net_device *dev, bool task_valid)
net/xfrm/xfrm_state.c
921
int xfrm_state_flush(struct net *net, u8 proto, bool task_valid)
net/xfrm/xfrm_state.c
925
spin_lock_bh(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
926
err = xfrm_state_flush_secctx_check(net, proto, task_valid);
net/xfrm/xfrm_state.c
93
lockdep_assert_held(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
931
for (i = 0; i <= net->xfrm.state_hmask; i++) {
net/xfrm/xfrm_state.c
934
hlist_for_each_entry(x, xfrm_state_deref_prot(net->xfrm.state_bydst, net) + i, bydst) {
net/xfrm/xfrm_state.c
938
spin_unlock_bh(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
947
spin_lock_bh(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
95
return __xfrm_seq_hash(seq, net->xfrm.state_hmask);
net/xfrm/xfrm_state.c
953
spin_unlock_bh(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
961
int xfrm_dev_state_flush(struct net *net, struct net_device *dev, bool task_valid)
net/xfrm/xfrm_state.c
968
spin_lock_bh(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
969
err = xfrm_dev_state_flush_secctx_check(net, dev, task_valid);
net/xfrm/xfrm_state.c
974
for (i = 0; i <= net->xfrm.state_hmask; i++) {
net/xfrm/xfrm_state.c
976
hlist_for_each_entry(x, xfrm_state_deref_prot(net->xfrm.state_bydst, net) + i, bydst) {
net/xfrm/xfrm_state.c
981
spin_unlock_bh(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state.c
992
spin_lock_bh(&net->xfrm.xfrm_state_lock);
net/xfrm/xfrm_state_bpf.c
68
struct net *net = dev_net(xdp->rxq->dev);
net/xfrm/xfrm_state_bpf.c
85
net = get_net_ns_by_id(net, opts->netns_id);
net/xfrm/xfrm_state_bpf.c
86
if (unlikely(!net)) {
net/xfrm/xfrm_state_bpf.c
92
x = xfrm_state_lookup(net, opts->mark, &opts->daddr, opts->spi,
net/xfrm/xfrm_state_bpf.c
96
put_net(net);
net/xfrm/xfrm_sysctl.c
10
net->xfrm.sysctl_aevent_rseqth = XFRM_AE_SEQT_SIZE;
net/xfrm/xfrm_sysctl.c
11
net->xfrm.sysctl_larval_drop = 1;
net/xfrm/xfrm_sysctl.c
12
net->xfrm.sysctl_acq_expires = 30;
net/xfrm/xfrm_sysctl.c
43
int __net_init xfrm_sysctl_init(struct net *net)
net/xfrm/xfrm_sysctl.c
48
__xfrm_sysctl_init(net);
net/xfrm/xfrm_sysctl.c
53
table[0].data = &net->xfrm.sysctl_aevent_etime;
net/xfrm/xfrm_sysctl.c
54
table[1].data = &net->xfrm.sysctl_aevent_rseqth;
net/xfrm/xfrm_sysctl.c
55
table[2].data = &net->xfrm.sysctl_larval_drop;
net/xfrm/xfrm_sysctl.c
56
table[3].data = &net->xfrm.sysctl_acq_expires;
net/xfrm/xfrm_sysctl.c
59
if (net->user_ns != &init_user_ns)
net/xfrm/xfrm_sysctl.c
62
net->xfrm.sysctl_hdr = register_net_sysctl_sz(net, "net/core", table,
net/xfrm/xfrm_sysctl.c
64
if (!net->xfrm.sysctl_hdr)
net/xfrm/xfrm_sysctl.c
7
static void __net_init __xfrm_sysctl_init(struct net *net)
net/xfrm/xfrm_sysctl.c
74
void __net_exit xfrm_sysctl_fini(struct net *net)
net/xfrm/xfrm_sysctl.c
78
table = net->xfrm.sysctl_hdr->ctl_table_arg;
net/xfrm/xfrm_sysctl.c
79
unregister_net_sysctl_table(net->xfrm.sysctl_hdr);
net/xfrm/xfrm_sysctl.c
83
int __net_init xfrm_sysctl_init(struct net *net)
net/xfrm/xfrm_sysctl.c
85
__xfrm_sysctl_init(net);
net/xfrm/xfrm_sysctl.c
9
net->xfrm.sysctl_aevent_etime = XFRM_AE_ETIME;
net/xfrm/xfrm_user.c
1003
x->replay_maxdiff = net->xfrm.sysctl_aevent_rseqth;
net/xfrm/xfrm_user.c
1005
x->replay_maxage = (net->xfrm.sysctl_aevent_etime*HZ)/XFRM_AE_ETH_M;
net/xfrm/xfrm_user.c
1016
err = xfrm_dev_state_add(net, x,
net/xfrm/xfrm_user.c
1024
err = x->mode_cbs->user_init(net, x, attrs, extack);
net/xfrm/xfrm_user.c
1042
struct net *net = sock_net(skb->sk);
net/xfrm/xfrm_user.c
1052
x = xfrm_state_construct(net, p, attrs, &err, extack);
net/xfrm/xfrm_user.c
1084
static struct xfrm_state *xfrm_user_state_lookup(struct net *net,
net/xfrm/xfrm_user.c
1096
x = xfrm_state_lookup(net, mark, &p->daddr, p->spi, p->proto, p->family);
net/xfrm/xfrm_user.c
1107
x = xfrm_state_lookup_byaddr(net, mark,
net/xfrm/xfrm_user.c
1121
struct net *net = sock_net(skb->sk);
net/xfrm/xfrm_user.c
1127
x = xfrm_user_state_lookup(net, p, attrs, &err);
net/xfrm/xfrm_user.c
1539
struct net *net = sock_net(sk);
net/xfrm/xfrm_user.c
1542
xfrm_state_walk_done(walk, net);
net/xfrm/xfrm_user.c
1548
struct net *net = sock_net(skb->sk);
net/xfrm/xfrm_user.c
1594
(void) xfrm_state_walk(net, walk, dump_one_state, &info);
net/xfrm/xfrm_user.c
1627
static inline int xfrm_nlmsg_multicast(struct net *net, struct sk_buff *skb,
net/xfrm/xfrm_user.c
1630
struct sock *nlsk = rcu_dereference(net->xfrm.nlsk);
net/xfrm/xfrm_user.c
1661
static int build_spdinfo(struct sk_buff *skb, struct net *net,
net/xfrm/xfrm_user.c
1679
xfrm_spd_getinfo(net, &si);
net/xfrm/xfrm_user.c
1690
lseq = read_seqbegin(&net->xfrm.policy_hthresh.lock);
net/xfrm/xfrm_user.c
1692
spt4.lbits = net->xfrm.policy_hthresh.lbits4;
net/xfrm/xfrm_user.c
1693
spt4.rbits = net->xfrm.policy_hthresh.rbits4;
net/xfrm/xfrm_user.c
1694
spt6.lbits = net->xfrm.policy_hthresh.lbits6;
net/xfrm/xfrm_user.c
1695
spt6.rbits = net->xfrm.policy_hthresh.rbits6;
net/xfrm/xfrm_user.c
1696
} while (read_seqretry(&net->xfrm.policy_hthresh.lock, lseq));
net/xfrm/xfrm_user.c
1718
struct net *net = sock_net(skb->sk);
net/xfrm/xfrm_user.c
1751
write_seqlock(&net->xfrm.policy_hthresh.lock);
net/xfrm/xfrm_user.c
1753
net->xfrm.policy_hthresh.lbits4 = thresh4->lbits;
net/xfrm/xfrm_user.c
1754
net->xfrm.policy_hthresh.rbits4 = thresh4->rbits;
net/xfrm/xfrm_user.c
1757
net->xfrm.policy_hthresh.lbits6 = thresh6->lbits;
net/xfrm/xfrm_user.c
1758
net->xfrm.policy_hthresh.rbits6 = thresh6->rbits;
net/xfrm/xfrm_user.c
1760
write_sequnlock(&net->xfrm.policy_hthresh.lock);
net/xfrm/xfrm_user.c
1762
xfrm_policy_hash_rebuild(net);
net/xfrm/xfrm_user.c
1772
struct net *net = sock_net(skb->sk);
net/xfrm/xfrm_user.c
1783
err = build_spdinfo(r_skb, net, sportid, seq, *flags);
net/xfrm/xfrm_user.c
1786
return nlmsg_unicast(xfrm_net_nlsk(net, skb), r_skb, sportid);
net/xfrm/xfrm_user.c
1796
static int build_sadinfo(struct sk_buff *skb, struct net *net,
net/xfrm/xfrm_user.c
1811
xfrm_sad_getinfo(net, &si);
net/xfrm/xfrm_user.c
1832
struct net *net = sock_net(skb->sk);
net/xfrm/xfrm_user.c
1843
err = build_sadinfo(r_skb, net, sportid, seq, *flags);
net/xfrm/xfrm_user.c
1846
return nlmsg_unicast(xfrm_net_nlsk(net, skb), r_skb, sportid);
net/xfrm/xfrm_user.c
1852
struct net *net = sock_net(skb->sk);
net/xfrm/xfrm_user.c
1858
x = xfrm_user_state_lookup(net, p, attrs, &err);
net/xfrm/xfrm_user.c
1866
err = nlmsg_unicast(xfrm_net_nlsk(net, skb), resp_skb, NETLINK_CB(skb).portid);
net/xfrm/xfrm_user.c
1877
struct net *net = sock_net(skb->sk);
net/xfrm/xfrm_user.c
1915
x = xfrm_find_acq_byseq(net, mark, p->info.seq, pcpu_num);
net/xfrm/xfrm_user.c
1923
x = xfrm_find_acq(net, &m, p->info.mode, p->info.reqid,
net/xfrm/xfrm_user.c
1957
err = nlmsg_unicast(xfrm_net_nlsk(net, skb), resp_skb, NETLINK_CB(skb).portid);
net/xfrm/xfrm_user.c
2237
static struct xfrm_policy *xfrm_policy_construct(struct net *net,
net/xfrm/xfrm_user.c
2243
struct xfrm_policy *xp = xfrm_policy_alloc(net, GFP_KERNEL);
net/xfrm/xfrm_user.c
2269
err = xfrm_dev_policy_add(net, xp,
net/xfrm/xfrm_user.c
2288
struct net *net = sock_net(skb->sk);
net/xfrm/xfrm_user.c
2302
xp = xfrm_policy_construct(net, p, attrs, &err, extack);
net/xfrm/xfrm_user.c
2456
struct net *net = sock_net(cb->skb->sk);
net/xfrm/xfrm_user.c
2458
xfrm_policy_walk_done(walk, net);
net/xfrm/xfrm_user.c
2474
struct net *net = sock_net(skb->sk);
net/xfrm/xfrm_user.c
2483
(void) xfrm_policy_walk(net, walk, dump_one_policy, &info);
net/xfrm/xfrm_user.c
2514
static int xfrm_notify_userpolicy(struct net *net)
net/xfrm/xfrm_user.c
2533
up->in = READ_ONCE(net->xfrm.policy_default[XFRM_POLICY_IN]);
net/xfrm/xfrm_user.c
2534
up->fwd = READ_ONCE(net->xfrm.policy_default[XFRM_POLICY_FWD]);
net/xfrm/xfrm_user.c
2535
up->out = READ_ONCE(net->xfrm.policy_default[XFRM_POLICY_OUT]);
net/xfrm/xfrm_user.c
2540
err = xfrm_nlmsg_multicast(net, skb, 0, XFRMNLGRP_POLICY);
net/xfrm/xfrm_user.c
2555
struct net *net = sock_net(skb->sk);
net/xfrm/xfrm_user.c
2559
WRITE_ONCE(net->xfrm.policy_default[XFRM_POLICY_IN], up->in);
net/xfrm/xfrm_user.c
2562
WRITE_ONCE(net->xfrm.policy_default[XFRM_POLICY_FWD], up->fwd);
net/xfrm/xfrm_user.c
2565
WRITE_ONCE(net->xfrm.policy_default[XFRM_POLICY_OUT], up->out);
net/xfrm/xfrm_user.c
2567
rt_genid_bump_all(net);
net/xfrm/xfrm_user.c
2569
xfrm_notify_userpolicy(net);
net/xfrm/xfrm_user.c
2578
struct net *net = sock_net(skb->sk);
net/xfrm/xfrm_user.c
2595
r_up->in = READ_ONCE(net->xfrm.policy_default[XFRM_POLICY_IN]);
net/xfrm/xfrm_user.c
2596
r_up->fwd = READ_ONCE(net->xfrm.policy_default[XFRM_POLICY_FWD]);
net/xfrm/xfrm_user.c
2597
r_up->out = READ_ONCE(net->xfrm.policy_default[XFRM_POLICY_OUT]);
net/xfrm/xfrm_user.c
2600
return nlmsg_unicast(xfrm_net_nlsk(net, skb), r_skb, portid);
net/xfrm/xfrm_user.c
2607
struct net *net = sock_net(skb->sk);
net/xfrm/xfrm_user.c
2634
xp = xfrm_policy_byid(net, &m, if_id, type, p->dir,
net/xfrm/xfrm_user.c
2652
xp = xfrm_policy_bysel_ctx(net, &m, if_id, type, p->dir,
net/xfrm/xfrm_user.c
2666
err = nlmsg_unicast(xfrm_net_nlsk(net, skb), resp_skb,
net/xfrm/xfrm_user.c
2691
struct net *net = sock_net(skb->sk);
net/xfrm/xfrm_user.c
2696
err = xfrm_state_flush(net, p->proto, true);
net/xfrm/xfrm_user.c
2706
c.net = net;
net/xfrm/xfrm_user.c
2805
struct net *net = sock_net(skb->sk);
net/xfrm/xfrm_user.c
2817
x = xfrm_state_lookup(net, mark, &id->daddr, id->spi, id->proto, id->family);
net/xfrm/xfrm_user.c
2845
err = nlmsg_unicast(xfrm_net_nlsk(net, skb), r_skb, NETLINK_CB(skb).portid);
net/xfrm/xfrm_user.c
2854
struct net *net = sock_net(skb->sk);
net/xfrm/xfrm_user.c
2880
x = xfrm_state_lookup(net, mark, &p->sa_id.daddr, p->sa_id.spi, p->sa_id.proto, p->sa_id.family);
net/xfrm/xfrm_user.c
2912
struct net *net = sock_net(skb->sk);
net/xfrm/xfrm_user.c
2921
err = xfrm_policy_flush(net, type, true);
net/xfrm/xfrm_user.c
2932
c.net = net;
net/xfrm/xfrm_user.c
2941
struct net *net = sock_net(skb->sk);
net/xfrm/xfrm_user.c
2964
xp = xfrm_policy_byid(net, &m, if_id, type, p->dir, p->index,
net/xfrm/xfrm_user.c
2982
xp = xfrm_policy_bysel_ctx(net, &m, if_id, type, p->dir,
net/xfrm/xfrm_user.c
3008
struct net *net = sock_net(skb->sk);
net/xfrm/xfrm_user.c
3016
x = xfrm_state_lookup(net, mark, &p->id.daddr, p->id.spi, p->id.proto, p->family);
net/xfrm/xfrm_user.c
3046
struct net *net = sock_net(skb->sk);
net/xfrm/xfrm_user.c
3054
struct xfrm_state *x = xfrm_state_alloc(net);
net/xfrm/xfrm_user.c
3079
xp = xfrm_policy_construct(net, &ua->policy, attrs, &err, extack);
net/xfrm/xfrm_user.c
3192
struct net *net = sock_net(skb->sk);
net/xfrm/xfrm_user.c
3233
err = xfrm_migrate(&pi->sel, pi->dir, type, m, n, kmp, net, encap,
net/xfrm/xfrm_user.c
3322
static int xfrm_send_migrate_state(struct net *net,
net/xfrm/xfrm_user.c
3340
return xfrm_nlmsg_multicast(net, skb, 0, XFRMNLGRP_MIGRATE);
net/xfrm/xfrm_user.c
3347
struct net *net = sock_net(skb->sk);
net/xfrm/xfrm_user.c
3383
x = xfrm_state_lookup(net, m.old_mark.v & m.old_mark.m,
net/xfrm/xfrm_user.c
3461
x_new = xfrm_state_lookup(net, new_mark_key, &m.new_daddr,
net/xfrm/xfrm_user.c
3471
xc = xfrm_state_migrate_create(x, &m, net, extack);
net/xfrm/xfrm_user.c
3507
err = xfrm_send_migrate_state(net, um, &m, xc->dir,
net/xfrm/xfrm_user.c
3630
const struct xfrm_kmaddress *k, struct net *net,
net/xfrm/xfrm_user.c
3645
return xfrm_nlmsg_multicast(net, skb, 0, XFRMNLGRP_MIGRATE);
net/xfrm/xfrm_user.c
3650
const struct xfrm_kmaddress *k, struct net *net,
net/xfrm/xfrm_user.c
38
static struct sock *xfrm_net_nlsk(const struct net *net, const struct sk_buff *skb)
net/xfrm/xfrm_user.c
3840
struct net *net = sock_net(skb->sk);
net/xfrm/xfrm_user.c
3886
err = netlink_dump_start(xfrm_net_nlsk(net, skb), skb, nlh, &c);
net/xfrm/xfrm_user.c
3926
struct net *net = sock_net(skb->sk);
net/xfrm/xfrm_user.c
3928
mutex_lock(&net->xfrm.xfrm_cfg_mutex);
net/xfrm/xfrm_user.c
3930
mutex_unlock(&net->xfrm.xfrm_cfg_mutex);
net/xfrm/xfrm_user.c
3982
struct net *net = xs_net(x);
net/xfrm/xfrm_user.c
3994
return xfrm_nlmsg_multicast(net, skb, 0, XFRMNLGRP_EXPIRE);
net/xfrm/xfrm_user.c
3999
struct net *net = xs_net(x);
net/xfrm/xfrm_user.c
4010
return xfrm_nlmsg_multicast(net, skb, 0, XFRMNLGRP_AEVENTS);
net/xfrm/xfrm_user.c
4015
struct net *net = c->net;
net/xfrm/xfrm_user.c
4036
return xfrm_nlmsg_multicast(net, skb, 0, XFRMNLGRP_SA);
net/xfrm/xfrm_user.c
4099
struct net *net = xs_net(x);
net/xfrm/xfrm_user.c
4149
return xfrm_nlmsg_multicast(net, skb, 0, XFRMNLGRP_SA);
net/xfrm/xfrm_user.c
4238
struct net *net = xs_net(x);
net/xfrm/xfrm_user.c
4249
return xfrm_nlmsg_multicast(net, skb, 0, XFRMNLGRP_ACQUIRE);
net/xfrm/xfrm_user.c
4258
struct net *net = sock_net(sk);
net/xfrm/xfrm_user.c
4297
xp = xfrm_policy_alloc(net, GFP_ATOMIC);
net/xfrm/xfrm_user.c
4360
struct net *net = xp_net(xp);
net/xfrm/xfrm_user.c
4371
return xfrm_nlmsg_multicast(net, skb, 0, XFRMNLGRP_EXPIRE);
net/xfrm/xfrm_user.c
4377
struct net *net = xp_net(xp);
net/xfrm/xfrm_user.c
44
return rcu_dereference_protected(net->xfrm.nlsk, sk->sk_net_refcnt);
net/xfrm/xfrm_user.c
4438
return xfrm_nlmsg_multicast(net, skb, 0, XFRMNLGRP_POLICY);
net/xfrm/xfrm_user.c
4447
struct net *net = c->net;
net/xfrm/xfrm_user.c
4466
return xfrm_nlmsg_multicast(net, skb, 0, XFRMNLGRP_POLICY);
net/xfrm/xfrm_user.c
4525
static int xfrm_send_report(struct net *net, u8 proto,
net/xfrm/xfrm_user.c
4538
return xfrm_nlmsg_multicast(net, skb, 0, XFRMNLGRP_REPORT);
net/xfrm/xfrm_user.c
4576
struct net *net = xs_net(x);
net/xfrm/xfrm_user.c
4593
return xfrm_nlmsg_multicast(net, skb, 0, XFRMNLGRP_MAPPING);
net/xfrm/xfrm_user.c
4598
return (bool)xfrm_acquire_is_on(c->net);
net/xfrm/xfrm_user.c
4612
static int __net_init xfrm_user_net_init(struct net *net)
net/xfrm/xfrm_user.c
4620
nlsk = netlink_kernel_create(net, NETLINK_XFRM, &cfg);
net/xfrm/xfrm_user.c
4623
net->xfrm.nlsk_stash = nlsk; /* Don't set to NULL */
net/xfrm/xfrm_user.c
4624
rcu_assign_pointer(net->xfrm.nlsk, nlsk);
net/xfrm/xfrm_user.c
4628
static void __net_exit xfrm_user_net_pre_exit(struct net *net)
net/xfrm/xfrm_user.c
4630
RCU_INIT_POINTER(net->xfrm.nlsk, NULL);
net/xfrm/xfrm_user.c
4635
struct net *net;
net/xfrm/xfrm_user.c
4637
list_for_each_entry(net, net_exit_list, exit_list)
net/xfrm/xfrm_user.c
4638
netlink_kernel_release(net->xfrm.nlsk_stash);
net/xfrm/xfrm_user.c
907
static struct xfrm_state *xfrm_state_construct(struct net *net,
net/xfrm/xfrm_user.c
913
struct xfrm_state *x = xfrm_state_alloc(net);
security/apparmor/af_unix.c
268
if (is_unix_addr_fs(ad->net.addr, ad->net.addrlen))
security/apparmor/af_unix.c
274
unix_addr(ad->net.addr),
security/apparmor/af_unix.c
275
ad->net.addrlen,
security/apparmor/af_unix.c
503
ad.net.addr = unix_addr(addr);
security/apparmor/af_unix.c
504
ad.net.addrlen = addrlen;
security/apparmor/af_unix.c
609
ad.net.peer.addr = peer_addr;
security/apparmor/af_unix.c
610
ad.net.peer.addrlen = peer_addrlen;
security/apparmor/include/audit.h
149
} net;
security/apparmor/include/net.h
68
NAME.common.u.net = &(NAME ## _net); \
security/apparmor/include/net.h
70
NAME.net.type = (T); \
security/apparmor/include/net.h
71
NAME.net.protocol = (P)
security/apparmor/lsm.c
2417
static int __net_init apparmor_nf_register(struct net *net)
security/apparmor/lsm.c
2419
return nf_register_net_hooks(net, apparmor_nf_ops,
security/apparmor/lsm.c
2423
static void __net_exit apparmor_nf_unregister(struct net *net)
security/apparmor/lsm.c
2425
nf_unregister_net_hooks(net, apparmor_nf_ops,
security/apparmor/net.c
121
if (address_family_names[ad->common.u.net->family])
security/apparmor/net.c
123
address_family_names[ad->common.u.net->family]);
security/apparmor/net.c
126
ad->common.u.net->family);
security/apparmor/net.c
127
if (sock_type_names[ad->net.type])
security/apparmor/net.c
129
sock_type_names[ad->net.type]);
security/apparmor/net.c
132
ad->net.type);
security/apparmor/net.c
133
audit_log_format(ab, " protocol=%d", ad->net.protocol);
security/apparmor/net.c
146
if (ad->common.u.net->family == PF_UNIX) {
security/apparmor/net.c
147
if (ad->net.addr || !ad->common.u.net->sk)
security/apparmor/net.c
149
unix_addr(ad->net.addr),
security/apparmor/net.c
150
ad->net.addrlen);
security/apparmor/net.c
152
audit_unix_sk_addr(ab, "addr", ad->common.u.net->sk);
security/apparmor/net.c
155
unix_addr(ad->net.peer.addr),
security/apparmor/net.c
156
ad->net.peer.addrlen);
security/landlock/access.h
51
access_mask_t net : LANDLOCK_NUM_ACCESS_NET;
security/landlock/audit.c
535
return access_masks.net;
security/landlock/net.c
118
.audit.u.net = &audit_net,
security/landlock/net.c
256
.audit.u.net = &audit_net,
security/landlock/net.c
266
.net = LANDLOCK_ACCESS_NET_BIND_UDP,
security/landlock/net.c
298
sizeof(port0), bind_udp.net, false);
security/landlock/net.c
59
.net = access_request,
security/landlock/ruleset.h
284
ruleset->access_masks[layer_level].net |= net_mask;
security/landlock/ruleset.h
311
return ruleset->access_masks[layer_level].net;
security/landlock/syscalls.c
281
ruleset->quiet_masks.net = ruleset_attr.quiet_access_net;
security/landlock/syscalls.c
416
if (flags & LANDLOCK_ADD_RULE_QUIET && !ruleset->quiet_masks.net)
security/landlock/task.c
291
.u.net = &(struct lsm_network_audit) {
security/landlock/task.c
328
.u.net = &(struct lsm_network_audit) {
security/lsm_audit.c
100
ad->u.net->v6info.saddr = ip6->saddr;
security/lsm_audit.c
101
ad->u.net->v6info.daddr = ip6->daddr;
security/lsm_audit.c
120
ad->u.net->sport = th->source;
security/lsm_audit.c
121
ad->u.net->dport = th->dest;
security/lsm_audit.c
131
ad->u.net->sport = uh->source;
security/lsm_audit.c
132
ad->u.net->dport = uh->dest;
security/lsm_audit.c
141
ad->u.net->sport = sh->source;
security/lsm_audit.c
142
ad->u.net->dport = sh->dest;
security/lsm_audit.c
286
if (a->u.net->sk) {
security/lsm_audit.c
287
const struct sock *sk = a->u.net->sk;
security/lsm_audit.c
338
switch (a->u.net->family) {
security/lsm_audit.c
340
print_ipv4_addr(ab, a->u.net->v4info.saddr,
security/lsm_audit.c
341
a->u.net->sport,
security/lsm_audit.c
343
print_ipv4_addr(ab, a->u.net->v4info.daddr,
security/lsm_audit.c
344
a->u.net->dport,
security/lsm_audit.c
348
print_ipv6_addr(ab, &a->u.net->v6info.saddr,
security/lsm_audit.c
349
a->u.net->sport,
security/lsm_audit.c
351
print_ipv6_addr(ab, &a->u.net->v6info.daddr,
security/lsm_audit.c
352
a->u.net->dport,
security/lsm_audit.c
356
if (a->u.net->netif > 0) {
security/lsm_audit.c
360
dev = dev_get_by_index(&init_net, a->u.net->netif);
security/lsm_audit.c
46
ad->u.net->v4info.saddr = ih->saddr;
security/lsm_audit.c
47
ad->u.net->v4info.daddr = ih->daddr;
security/lsm_audit.c
59
ad->u.net->sport = th->source;
security/lsm_audit.c
60
ad->u.net->dport = th->dest;
security/lsm_audit.c
66
ad->u.net->sport = uh->source;
security/lsm_audit.c
67
ad->u.net->dport = uh->dest;
security/lsm_audit.c
73
ad->u.net->sport = sh->source;
security/lsm_audit.c
74
ad->u.net->dport = sh->dest;
security/selinux/hooks.c
235
struct lsm_network_audit *net,
security/selinux/hooks.c
239
ad->u.net = net;
security/selinux/hooks.c
240
net->netif = ifindex;
security/selinux/hooks.c
241
net->sk = sk;
security/selinux/hooks.c
242
net->family = family;
security/selinux/hooks.c
246
struct lsm_network_audit *net,
security/selinux/hooks.c
249
__ad_net_init(ad, net, 0, sk, 0);
security/selinux/hooks.c
253
struct lsm_network_audit *net,
security/selinux/hooks.c
256
__ad_net_init(ad, net, ifindex, NULL, family);
security/selinux/hooks.c
4634
ad->u.net->v4info.saddr = ih->saddr;
security/selinux/hooks.c
4635
ad->u.net->v4info.daddr = ih->daddr;
security/selinux/hooks.c
4653
ad->u.net->sport = th->source;
security/selinux/hooks.c
4654
ad->u.net->dport = th->dest;
security/selinux/hooks.c
4669
ad->u.net->sport = uh->source;
security/selinux/hooks.c
4670
ad->u.net->dport = uh->dest;
security/selinux/hooks.c
4686
ad->u.net->sport = sh->source;
security/selinux/hooks.c
4687
ad->u.net->dport = sh->dest;
security/selinux/hooks.c
4714
ad->u.net->v6info.saddr = ip6->saddr;
security/selinux/hooks.c
4715
ad->u.net->v6info.daddr = ip6->daddr;
security/selinux/hooks.c
4735
ad->u.net->sport = th->source;
security/selinux/hooks.c
4736
ad->u.net->dport = th->dest;
security/selinux/hooks.c
4747
ad->u.net->sport = uh->source;
security/selinux/hooks.c
4748
ad->u.net->dport = uh->dest;
security/selinux/hooks.c
4760
ad->u.net->sport = sh->source;
security/selinux/hooks.c
4761
ad->u.net->dport = sh->dest;
security/selinux/hooks.c
4781
switch (ad->u.net->family) {
security/selinux/hooks.c
4786
addrp = (char *)(src ? &ad->u.net->v4info.saddr :
security/selinux/hooks.c
4787
&ad->u.net->v4info.daddr);
security/selinux/hooks.c
4795
addrp = (char *)(src ? &ad->u.net->v6info.saddr :
security/selinux/hooks.c
4796
&ad->u.net->v6info.daddr);
security/selinux/hooks.c
4923
struct lsm_network_audit net;
security/selinux/hooks.c
4928
ad_net_init_from_sk(&ad, &net, sk);
security/selinux/hooks.c
5018
struct lsm_network_audit net = {0,};
security/selinux/hooks.c
5070
ad.u.net = &net;
security/selinux/hooks.c
5071
ad.u.net->sport = htons(snum);
security/selinux/hooks.c
5072
ad.u.net->family = family_sa;
security/selinux/hooks.c
5116
ad.u.net->v4info.saddr = addr4->sin_addr.s_addr;
security/selinux/hooks.c
5118
ad.u.net->v6info.saddr = addr6->sin6_addr;
security/selinux/hooks.c
5167
struct lsm_network_audit net = {0,};
security/selinux/hooks.c
5215
ad.u.net = &net;
security/selinux/hooks.c
5216
ad.u.net->dport = htons(snum);
security/selinux/hooks.c
5217
ad.u.net->family = address->sa_family;
security/selinux/hooks.c
5340
struct lsm_network_audit net;
security/selinux/hooks.c
5343
ad_net_init_from_sk(&ad, &net, other);
security/selinux/hooks.c
5370
struct lsm_network_audit net;
security/selinux/hooks.c
5372
ad_net_init_from_sk(&ad, &net, other->sk);
security/selinux/hooks.c
5378
static int selinux_inet_sys_rcv_skb(struct net *ns, int ifindex,
security/selinux/hooks.c
5408
struct lsm_network_audit net;
security/selinux/hooks.c
5411
ad_net_init_from_iif(&ad, &net, skb->skb_iif, family);
security/selinux/hooks.c
5438
struct lsm_network_audit net;
security/selinux/hooks.c
5460
ad_net_init_from_iif(&ad, &net, skb->skb_iif, family);
security/selinux/hooks.c
5625
struct lsm_network_audit net;
security/selinux/hooks.c
5661
ad_net_init_from_sk(&ad, &net, asoc->base.sk);
security/selinux/hooks.c
5988
struct lsm_network_audit net;
security/selinux/hooks.c
6004
ad_net_init_from_iif(&ad, &net, ifindex, family);
security/selinux/hooks.c
6011
err = selinux_inet_sys_rcv_skb(state->net, ifindex,
security/selinux/hooks.c
6084
struct lsm_network_audit net;
security/selinux/hooks.c
6092
ad_net_init_from_iif(&ad, &net, state->out->ifindex, state->pf);
security/selinux/hooks.c
6117
struct lsm_network_audit net;
security/selinux/hooks.c
6214
ad_net_init_from_iif(&ad, &net, ifindex, family);
security/selinux/hooks.c
6227
if (sel_netif_sid(state->net, ifindex, &if_sid))
security/selinux/hooks.c
7967
static int __net_init selinux_nf_register(struct net *net)
security/selinux/hooks.c
7969
return nf_register_net_hooks(net, selinux_nf_ops,
security/selinux/hooks.c
7973
static void __net_exit selinux_nf_unregister(struct net *net)
security/selinux/hooks.c
7975
nf_unregister_net_hooks(net, selinux_nf_ops,
security/selinux/include/netif.h
22
int sel_netif_sid(struct net *ns, int ifindex, u32 *sid);
security/selinux/include/objsec.h
115
const struct net *ns; /* network namespace */
security/selinux/include/xfrm.h
50
struct net *net;
security/selinux/include/xfrm.h
53
for_each_net(net)
security/selinux/include/xfrm.h
54
rt_genid_bump_all(net);
security/selinux/netif.c
133
static int sel_netif_sid_slow(struct net *ns, int ifindex, u32 *sid)
security/selinux/netif.c
196
int sel_netif_sid(struct net *ns, int ifindex, u32 *sid)
security/selinux/netif.c
222
static void sel_netif_kill(const struct net *ns, int ifindex)
security/selinux/netif.c
53
static inline u32 sel_netif_hashfn(const struct net *ns, int ifindex)
security/selinux/netif.c
68
static inline struct sel_netif *sel_netif_find(const struct net *ns,
security/smack/smack.h
480
char type, struct lsm_network_audit *net)
security/smack/smack.h
483
memset(net, 0, sizeof(*net));
security/smack/smack.h
484
a->a.u.net = net;
security/smack/smack.h
510
a->a.u.net->sk = sk;
security/smack/smack_lsm.c
2688
struct lsm_network_audit net;
security/smack/smack_lsm.c
2690
smk_ad_init_net(&ad, __func__, LSM_AUDIT_DATA_NET, &net);
security/smack/smack_lsm.c
2691
ad.a.u.net->family = sap->sin_family;
security/smack/smack_lsm.c
2692
ad.a.u.net->dport = sap->sin_port;
security/smack/smack_lsm.c
2693
ad.a.u.net->v4info.daddr = sap->sin_addr.s_addr;
security/smack/smack_lsm.c
2724
struct lsm_network_audit net;
security/smack/smack_lsm.c
2730
smk_ad_init_net(&ad, __func__, LSM_AUDIT_DATA_NET, &net);
security/smack/smack_lsm.c
2731
ad.a.u.net->family = PF_INET6;
security/smack/smack_lsm.c
2732
ad.a.u.net->dport = address->sin6_port;
security/smack/smack_lsm.c
2734
ad.a.u.net->v6info.saddr = address->sin6_addr;
security/smack/smack_lsm.c
2736
ad.a.u.net->v6info.daddr = address->sin6_addr;
security/smack/smack_lsm.c
3934
struct lsm_network_audit net;
security/smack/smack_lsm.c
3941
smk_ad_init_net(&ad, __func__, LSM_AUDIT_DATA_NET, &net);
security/smack/smack_lsm.c
3988
struct lsm_network_audit net;
security/smack/smack_lsm.c
3990
smk_ad_init_net(&ad, __func__, LSM_AUDIT_DATA_NET, &net);
security/smack/smack_lsm.c
4253
struct lsm_network_audit net;
security/smack/smack_lsm.c
4278
smk_ad_init_net(&ad, __func__, LSM_AUDIT_DATA_NET, &net);
security/smack/smack_lsm.c
4279
ad.a.u.net->family = family;
security/smack/smack_lsm.c
4280
ad.a.u.net->netif = skb->skb_iif;
security/smack/smack_lsm.c
4310
smk_ad_init_net(&ad, __func__, LSM_AUDIT_DATA_NET, &net);
security/smack/smack_lsm.c
4311
ad.a.u.net->family = family;
security/smack/smack_lsm.c
4312
ad.a.u.net->netif = skb->skb_iif;
security/smack/smack_lsm.c
4453
struct lsm_network_audit net;
security/smack/smack_lsm.c
4483
smk_ad_init_net(&ad, __func__, LSM_AUDIT_DATA_NET, &net);
security/smack/smack_lsm.c
4484
ad.a.u.net->family = family;
security/smack/smack_lsm.c
4485
ad.a.u.net->netif = skb->skb_iif;
security/smack/smack_netfilter.c
55
static int __net_init smack_nf_register(struct net *net)
security/smack/smack_netfilter.c
57
return nf_register_net_hooks(net, smack_nf_ops,
security/smack/smack_netfilter.c
61
static void __net_exit smack_nf_unregister(struct net *net)
security/smack/smack_netfilter.c
63
nf_unregister_net_hooks(net, smack_nf_ops, ARRAY_SIZE(smack_nf_ops));
tools/testing/selftests/bpf/progs/bpf_smc.c
112
struct net___local *net = (struct net___local *)task->nsproxy->net_ns;
tools/testing/selftests/bpf/progs/bpf_smc.c
114
if (!bpf_core_field_exists(struct net___local, smc) || !net->smc.hs_ctrl)
tools/testing/selftests/bpf/progs/sock_iter_batch.c
125
udptable = sk->sk_net.net->ipv4.udp_table;
tools/testing/selftests/bpf/progs/sock_iter_batch.c
37
struct net *net;
tools/testing/selftests/bpf/progs/sock_iter_batch.c
62
net = sk->sk_net.net;
tools/testing/selftests/bpf/progs/sock_iter_batch.c
63
hash = jhash2(sk->sk_v6_rcv_saddr.s6_addr32, 4, net->hash_mix);
tools/testing/selftests/bpf/progs/sock_iter_batch.c
65
hinfo = net->ipv4.tcp_death_row.hashinfo;
tools/testing/selftests/bpf/progs/type_cast.c
31
inum = dev->nd_net.net->ns.inum;
tools/testing/selftests/net/tcp_ao/bench-lookups.c
18
union tcp_addr net = {};
tools/testing/selftests/net/tcp_ao/bench-lookups.c
21
if (inet_pton(TEST_FAMILY, TEST_NETWORK, &net) != 1)
tools/testing/selftests/net/tcp_ao/bench-lookups.c
26
ips[i] = gen_tcp_addr(net, 2 * i + 1);
tools/testing/selftests/net/tcp_ao/bench-lookups.c
32
ips[i] = gen_tcp_addr(net, r);
tools/testing/selftests/net/tcp_ao/lib/aolib.h
224
static inline union tcp_addr gen_tcp_addr(union tcp_addr net, size_t n)
tools/testing/selftests/net/tcp_ao/lib/aolib.h
226
union tcp_addr ret = net;
tools/testing/selftests/net/tcp_ao/lib/aolib.h
232
ret.a4.s_addr = htonl(ntohl(net.a4.s_addr) + n);
tools/testing/selftests/net/tcp_ao/setsockopt-closed.c
237
union tcp_addr net = {};
tools/testing/selftests/net/tcp_ao/setsockopt-closed.c
240
if (inet_pton(TEST_FAMILY, TEST_NETWORK, &net) != 1)
tools/testing/selftests/net/tcp_ao/setsockopt-closed.c
249
key_peer = gen_tcp_addr(net, i + 1);