mirror of
https://github.com/opnsense/src.git
synced 2026-05-28 04:12:45 -04:00
netmap: check if we already ran mmap before we attempt it
Submitted by: neel@neelc.org Reviewed by: vmaffione MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D22390
This commit is contained in:
parent
f8d4f9bce9
commit
a56e6334d1
1 changed files with 2 additions and 1 deletions
|
|
@ -981,7 +981,8 @@ nm_close(struct nm_desc *d)
|
|||
static int
|
||||
nm_mmap(struct nm_desc *d, const struct nm_desc *parent)
|
||||
{
|
||||
//XXX TODO: check if mmap is already done
|
||||
if (d->done_mmap)
|
||||
return 0;
|
||||
|
||||
if (IS_NETMAP_DESC(parent) && parent->mem &&
|
||||
parent->req.nr_arg2 == d->req.nr_arg2) {
|
||||
|
|
|
|||
Loading…
Reference in a new issue