freebsd-nq/sys/dev/netmap
Patrick Kelsey dd4fcbc594 When a netmap process terminates without the full set of buffers it
was granted via rings and ni_bufs_list_head represented in those rings
and lists (e.g., via SIGKILL), those buffers are no longer available
for subsequent users for the lifetime of the system. To mitigate this
resource leak, reset the allocator state when the last ref to that
allocator is released.

Note that this only recovers leaked resources for an allocator when
there are no longer any users of that allocator, so there remain
circumstances in which leaked allocator resources may not ever be
recovered - consider a set of multiple netmap processes that are all
using the same allocator (say, the global allocator) where members of
that set may be killed and restarted over time but at any given point
there is one member of that set running.

Based on intial work by adrian@.

Reviewed by: Giuseppe Lettieri (g.lettieri@iet.unipi.it), luigi
Approved by: jmallett (mentor)
MFC after: 1 week
Sponsored by: Norse Corp, Inc.
2015-05-15 15:36:57 +00:00
..
if_em_netmap.h Update to the current version of netmap. 2014-08-16 15:00:01 +00:00
if_igb_netmap.h Update to the current version of netmap. 2014-08-16 15:00:01 +00:00
if_ixl_netmap.h Add native netmap support to ixl. 2015-02-24 06:20:50 +00:00
if_lem_netmap.h Mechanically convert to if_inc_counter(). 2014-09-19 03:51:26 +00:00
if_re_netmap.h Mechanically convert to if_inc_counter(). 2014-09-19 03:51:26 +00:00
if_vtnet_netmap.h staticize two functions, and use proper format for a struct sglist 2014-08-17 10:25:27 +00:00
ixgbe_netmap.h Make ix_crcstrip a public symbol for the moment; it probably is not 2015-03-24 09:46:47 +00:00
netmap_freebsd.c add MODULE_VERSION, needed to track module dependencies 2015-02-23 07:28:31 +00:00
netmap_generic.c sync a comment with our internal repo 2014-11-10 20:19:58 +00:00
netmap_kern.h add support for private knote lock (reduces lock contention), 2014-11-13 00:40:34 +00:00
netmap_mbq.c introduce mbq_lock() and mbq_unlock() for the mbq, 2014-06-06 18:02:32 +00:00
netmap_mbq.h Update to the current version of netmap. 2014-08-16 15:00:01 +00:00
netmap_mem2.c When a netmap process terminates without the full set of buffers it 2015-05-15 15:36:57 +00:00
netmap_mem2.h Update to the current version of netmap. 2014-08-16 15:00:01 +00:00
netmap_monitor.c we need full barriers here 2014-11-13 00:14:25 +00:00
netmap_offloadings.c Update to the current version of netmap. 2014-08-16 15:00:01 +00:00
netmap_pipe.c we need full barriers here 2014-11-13 00:14:25 +00:00
netmap_vale.c Update to the current version of netmap. 2014-08-16 15:00:01 +00:00
netmap.c netmap: improve the netmap attach message on FreeBSD. 2015-04-11 06:20:46 +00:00