em(4): honor vlanhwtag offload
The FreeBSD em driver fails to properly reset the VME flag in the e1000 CTRL register oneg the following ifconfig command ifconfig em1 -vlanhwtag Tested on the e1000 device emulated by QEMU, and on a real NIC (chip=0x10d38086). PR: 236584 Submitted by: murat@sunnyvalley.io Reported by: murat@sunnyvalley.io MFC after: 3 weeks Differential Revision: https://reviews.freebsd.org/D25286
This commit is contained in:
parent
d8e1e85c42
commit
7e6223b23f
@ -1334,6 +1334,11 @@ em_if_init(if_ctx_t ctx)
|
||||
ctrl |= E1000_CTRL_VME;
|
||||
E1000_WRITE_REG(&adapter->hw, E1000_CTRL, ctrl);
|
||||
}
|
||||
} else {
|
||||
u32 ctrl;
|
||||
ctrl = E1000_READ_REG(&adapter->hw, E1000_CTRL);
|
||||
ctrl &= ~E1000_CTRL_VME;
|
||||
E1000_WRITE_REG(&adapter->hw, E1000_CTRL, ctrl);
|
||||
}
|
||||
|
||||
/* Don't lose promiscuous settings */
|
||||
|
Loading…
Reference in New Issue
Block a user