HomeFreeBSD

xen/netfront: release resources on removal

Description

xen/netfront: release resources on removal

Current netfront code doesn't release the resources (grants and mbufs) on
removal. Add a new helper that releases the resources, so FreeBSD doesn't run
out of grants or memory when performing heavy hotplug/unplug of Xen PV nic
devices.

This is a direct commit to stable/10 because the code in newer branches has
been completely refactored and no longer has this issue.

Reviewed by: royger
Submitted by: Ouyangzhaowei <ouyangzhaowei@huawei.com>
Differential review: https://reviews.freebsd.org/D10088

Details

Provenance
roygerAuthored on
Reviewer
royger
Parents
rS316139: MFC r314870: Add mechanism to unload CAM periph drivers.
Branches
Unknown
Tags
Unknown