vxcan.c (552c69b36ebd966186573b9c7a286b390935cce1) | vxcan.c (d0522f1cd25edb796548f91e04766fa3cbc3b6df) |
---|---|
1/* 2 * vxcan.c - Virtual CAN Tunnel for cross namespace communication 3 * 4 * This code is derived from drivers/net/can/vcan.c for the virtual CAN 5 * specific parts and from drivers/net/veth.c to implement the netlink API 6 * for network interface pairs in a common and established way. 7 * 8 * Copyright (c) 2017 Oliver Hartkopp <socketcan@hartkopp.net> --- 193 unchanged lines hidden (view full) --- 202 name_assign_type = NET_NAME_ENUM; 203 } 204 205 peer_net = rtnl_link_get_net(net, tbp); 206 if (IS_ERR(peer_net)) 207 return PTR_ERR(peer_net); 208 209 peer = rtnl_create_link(peer_net, ifname, name_assign_type, | 1/* 2 * vxcan.c - Virtual CAN Tunnel for cross namespace communication 3 * 4 * This code is derived from drivers/net/can/vcan.c for the virtual CAN 5 * specific parts and from drivers/net/veth.c to implement the netlink API 6 * for network interface pairs in a common and established way. 7 * 8 * Copyright (c) 2017 Oliver Hartkopp <socketcan@hartkopp.net> --- 193 unchanged lines hidden (view full) --- 202 name_assign_type = NET_NAME_ENUM; 203 } 204 205 peer_net = rtnl_link_get_net(net, tbp); 206 if (IS_ERR(peer_net)) 207 return PTR_ERR(peer_net); 208 209 peer = rtnl_create_link(peer_net, ifname, name_assign_type, |
210 &vxcan_link_ops, tbp); | 210 &vxcan_link_ops, tbp, extack); |
211 if (IS_ERR(peer)) { 212 put_net(peer_net); 213 return PTR_ERR(peer); 214 } 215 216 if (ifmp && dev->ifindex) 217 peer->ifindex = ifmp->ifi_index; 218 --- 99 unchanged lines hidden --- | 211 if (IS_ERR(peer)) { 212 put_net(peer_net); 213 return PTR_ERR(peer); 214 } 215 216 if (ifmp && dev->ifindex) 217 peer->ifindex = ifmp->ifi_index; 218 --- 99 unchanged lines hidden --- |