On 09/03/17(Thu) 08:48, Stefan Sperling wrote: > This diff converts a struct ifnet pointer in pfsync's softc into an > ifindex with corresponding if_get()/if_put() calls.
This avoid the panic but obfuscate the problem. What you want is a detachhook such that if the parent interface is destroyed you don't leave a sale pointer. You can look at how vlan(4) or other pseudo drivers do it.