freebsd-dev/sbin/ifconfig
Kyle Evans 251a32b5b2 tun/tap: merge and rename to tuntap
tun(4) and tap(4) share the same general management interface and have a lot
in common. Bugs exist in tap(4) that have been fixed in tun(4), and
vice-versa. Let's reduce the maintenance requirements by merging them
together and using flags to differentiate between the three interface types
(tun, tap, vmnet).

This fixes a couple of tap(4)/vmnet(4) issues right out of the gate:
- tap devices may no longer be destroyed while they're open [0]
- VIMAGE issues already addressed in tun by kp

[0] emaste had removed an easy-panic-button in r240938 due to devdrn
blocking. A naive glance over this leads me to believe that this isn't quite
complete -- destroy_devl will only block while executing d_* functions, but
doesn't block the device from being destroyed while a process has it open.
The latter is the intent of the condvar in tun, so this is "fixed" (for
certain definitions of the word -- it wasn't really broken in tap, it just
wasn't quite ideal).

ifconfig(8) also grew the ability to map an interface name to a kld, so
that `ifconfig {tun,tap}0` can continue to autoload the correct module, and
`ifconfig vmnet0 create` will now autoload the correct module. This is a
low overhead addition.

(MFC commentary)

This may get MFC'd if many bugs in tun(4)/tap(4) are discovered after this,
and how critical they are. Changes after this are likely easily MFC'd
without taking this merge, but the merge will be easier.

I have no plans to do this MFC as of now.

Reviewed by:	bcr (manpages), tuexen (testing, syzkaller/packetdrill)
Input also from:	melifaro
Relnotes:	yes
Differential Revision:	https://reviews.freebsd.org/D20044
2019-05-08 02:32:11 +00:00
..
tests Merge ^/user/ngie/release-pkg-fix-tests to unbreak how test files are installed 2016-05-04 23:20:53 +00:00
af_inet6.c Update for IETF draft-ietf-6man-ipv6only-flag. 2019-03-06 23:31:42 +00:00
af_inet.c ifconfig: eliminate trailing whitespace 2019-02-26 03:34:47 +00:00
af_link.c Allow to specify PCP on packets not belonging to any VLAN. 2018-03-27 15:29:32 +00:00
af_nd6.c Update for IETF draft-ietf-6man-ipv6only-flag. 2019-03-06 23:31:42 +00:00
carp.c various: general adoption of SPDX licensing ID tags. 2017-11-27 15:37:16 +00:00
ifbridge.c various: general adoption of SPDX licensing ID tags. 2017-11-27 15:37:16 +00:00
ifclone.c Make lagg creation more fault tolerant 2018-04-17 12:54:58 +00:00
ifconfig.8 Select lacp egress ports based on NUMA domain 2019-05-03 14:43:21 +00:00
ifconfig.c tun/tap: merge and rename to tuntap 2019-05-08 02:32:11 +00:00
ifconfig.h Make lagg creation more fault tolerant 2018-04-17 12:54:58 +00:00
iffib.c various: general adoption of SPDX licensing ID tags. 2017-11-27 15:37:16 +00:00
ifgif.c various: general adoption of SPDX licensing ID tags. 2017-11-27 15:37:16 +00:00
ifgre.c Add GRE-in-UDP encapsulation support as defined in RFC8086. 2019-04-24 09:05:45 +00:00
ifgroup.c ifconfig: eliminate trailing whitespace 2019-02-26 03:34:47 +00:00
ifieee80211.c ifconfig(8): display 802.11n rates correctly for 'roam:rate' parameter 2019-02-10 21:32:39 +00:00
ifipsec.c Update ifr_name before invoking IPSECSREQID ioctl, this fixes the case, 2018-09-22 16:30:48 +00:00
iflagg.c Select lacp egress ports based on NUMA domain 2019-05-03 14:43:21 +00:00
ifmac.c various: general adoption of SPDX licensing ID tags. 2017-11-27 15:37:16 +00:00
ifmedia.c Finish removing FDDI and tokenring media support. 2018-04-23 21:10:33 +00:00
ifpfsync.c ifconfig: fix endianness bug displaying pfsync interfaces 2019-01-28 18:34:04 +00:00
ifvlan.c spdx: initial adoption of licensing ID tags. 2017-11-18 14:26:50 +00:00
ifvxlan.c Add support for IPv6 scoped addresses to vxlan 2017-12-30 04:03:53 +00:00
Makefile Update for IETF draft-ietf-6man-ipv6only-flag. 2019-03-06 23:31:42 +00:00
Makefile.depend DIRDEPS_BUILD: Update dependencies. 2017-10-31 00:07:04 +00:00
sfp.c ifconfig(8): Display extended compliance code string for SFP transceivers 2017-12-05 18:42:07 +00:00