HomeFreeBSD

if_tuntap: trigger the bpf hook on transmitting for the tap interface

Description

if_tuntap: trigger the bpf hook on transmitting for the tap interface

The tun interface triggers the bpf hook when a packet is transmitted,
the tap interface triggers it when the packet is read from the
character device. This is inconsistent.
So fix the tap device such that it behaves like the tun device.
This is needed for adding support for the tap device to packetdrill.

Reviewed by: kevans, rscheff
MFC after: 1 week
Sponsored by: Netflix, Inc.
Differential Revision: https://reviews.freebsd.org/D42467

Details

Provenance
tuexenAuthored on Nov 5 2023, 7:32 PM
Reviewer
kevans
Differential Revision
D42467: if_tuntap: trigger the bpf hook on transmitting for the tap interface
Parents
rG03c3a70abe5e: udplite: make socketoption available on IPv6 sockets
Branches
Unknown
Tags
Unknown