d1f0ee548c
While netbooting with loader.efi on at least one arm64 platform which uses u-boot emulating UEFI, the kernel gets corrupted, we suspected the u-boot ethernet driver was still running. Use netdev.dv_cleanup for efinet_dev to address this. This in turn requires calling dev_cleanup() before bi_load() to avoid a loader crash since bi_load() calls ExitBootServices. Reviewed by: imp Sponsored by: Juniper Networks, Inc. Differential Revision: https://reviews.freebsd.org/D51186