Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 22 Oct 2019 00:18:16 +0000 (UTC)
From:      Kyle Evans <kevans@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r353877 - head/sys/net
Message-ID:  <201910220018.x9M0IGgO090844@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: kevans
Date: Tue Oct 22 00:18:16 2019
New Revision: 353877
URL: https://svnweb.freebsd.org/changeset/base/353877

Log:
  tuntap(4): properly declare if_tun and if_tap modules
  
  Simply adding MODULE_VERSION does not do the trick, because the modules
  haven't been declared. This should actually fix modfind/kldstat, which
  r351229 aimed and failed to do.
  
  This should make vm-bhyve do the right thing again when using the ports
  version, rather than the latest version not in ports.
  
  MFC after:	3 days

Modified:
  head/sys/net/if_tuntap.c

Modified: head/sys/net/if_tuntap.c
==============================================================================
--- head/sys/net/if_tuntap.c	Mon Oct 21 23:12:14 2019	(r353876)
+++ head/sys/net/if_tuntap.c	Tue Oct 22 00:18:16 2019	(r353877)
@@ -783,9 +783,15 @@ static moduledata_t tuntap_mod = {
 	0
 };
 
+/* We'll only ever have these two, so no need for a macro. */
+static moduledata_t tun_mod = { "if_tun", NULL, 0 };
+static moduledata_t tap_mod = { "if_tap", NULL, 0 };
+
 DECLARE_MODULE(if_tuntap, tuntap_mod, SI_SUB_PSEUDO, SI_ORDER_ANY);
 MODULE_VERSION(if_tuntap, 1);
+DECLARE_MODULE(if_tun, tun_mod, SI_SUB_PSEUDO, SI_ORDER_ANY);
 MODULE_VERSION(if_tun, 1);
+DECLARE_MODULE(if_tap, tap_mod, SI_SUB_PSEUDO, SI_ORDER_ANY);
 MODULE_VERSION(if_tap, 1);
 
 static int



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201910220018.x9M0IGgO090844>