aboutsummaryrefslogtreecommitdiff
path: root/sys/dev/sfxge/common/efx_nic.c
diff options
context:
space:
mode:
authorAndrew Rybchenko <arybchik@FreeBSD.org>2018-11-26 06:20:13 +0000
committerAndrew Rybchenko <arybchik@FreeBSD.org>2018-11-26 06:20:13 +0000
commitfdbe38cf9d141b62afae760a2f30d545949d8650 (patch)
tree40240151e1fa3f3b199a3606c2be6286ebd63d85 /sys/dev/sfxge/common/efx_nic.c
parenta02bd3e38ccefc7c2de92652ebd11d12e53efa85 (diff)
downloadsrc-fdbe38cf9d141b62afae760a2f30d545949d8650.tar.gz
src-fdbe38cf9d141b62afae760a2f30d545949d8650.zip
sfxge(4): add API to control UDP tunnel ports
HW needs to know which UDP packets should be treated as tunnel encapsulation to do inner packet recognition, classification and offloads. Submitted by: Ivan Malov <ivan.malov at oktetlabs.ru> Sponsored by: Solarflare Communications, Inc. Differential Revision: https://reviews.freebsd.org/D18134
Notes
Notes: svn path=/head/; revision=340928
Diffstat (limited to 'sys/dev/sfxge/common/efx_nic.c')
-rw-r--r--sys/dev/sfxge/common/efx_nic.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/sys/dev/sfxge/common/efx_nic.c b/sys/dev/sfxge/common/efx_nic.c
index e5e8efde4bfb..e0dd26e10dae 100644
--- a/sys/dev/sfxge/common/efx_nic.c
+++ b/sys/dev/sfxge/common/efx_nic.c
@@ -510,7 +510,7 @@ efx_nic_reset(
EFSYS_ASSERT3U(enp->en_magic, ==, EFX_NIC_MAGIC);
EFSYS_ASSERT(enp->en_mod_flags & EFX_MOD_PROBE);
/*
- * All modules except the MCDI, PROBE, NVRAM, VPD, MON
+ * All modules except the MCDI, PROBE, NVRAM, VPD, MON, TUNNEL
* (which we do not reset here) must have been shut down or never
* initialized.
*
@@ -520,7 +520,10 @@ efx_nic_reset(
*/
mod_flags = enp->en_mod_flags;
mod_flags &= ~(EFX_MOD_MCDI | EFX_MOD_PROBE | EFX_MOD_NVRAM |
- EFX_MOD_VPD | EFX_MOD_MON);
+ EFX_MOD_VPD | EFX_MOD_MON);
+#if EFSYS_OPT_TUNNEL
+ mod_flags &= ~EFX_MOD_TUNNEL;
+#endif /* EFSYS_OPT_TUNNEL */
EFSYS_ASSERT3U(mod_flags, ==, 0);
if (mod_flags != 0) {
rc = EINVAL;