svn commit: r299980 - in projects/vnet: share/man/man9 sys/kern sys/sys
Bjoern A. Zeeb
bz at FreeBSD.org
Mon May 16 22:33:50 UTC 2016
Author: bz
Date: Mon May 16 22:33:48 2016
New Revision: 299980
URL: https://svnweb.freebsd.org/changeset/base/299980
Log:
Rather than having a printf under INVARIANTS, make 3rd party code
fail compile by removing pr_destroy; otherwise unhappiness will
most likely follow on VNET destroy or module unload.
Sponsored by: The FreeBSD Foundation
Modified:
projects/vnet/share/man/man9/domain.9
projects/vnet/sys/kern/uipc_domain.c
projects/vnet/sys/sys/protosw.h
Modified: projects/vnet/share/man/man9/domain.9
==============================================================================
--- projects/vnet/share/man/man9/domain.9 Mon May 16 22:16:54 2016 (r299979)
+++ projects/vnet/share/man/man9/domain.9 Mon May 16 22:33:48 2016 (r299980)
@@ -26,7 +26,7 @@
.\"
.\" $FreeBSD$
.\"
-.Dd November 6, 2014
+.Dd May 16, 2016
.Dt DOMAIN 9
.Os
.Sh NAME
@@ -105,7 +105,6 @@ struct protosw {
pr_ctloutput_t *pr_ctloutput; /* control output (from above) */
/* utility hooks */
pr_init_t *pr_init;
- pr_destroy_t *pr_destroy;
pr_fasttimo_t *pr_fasttimo; /* fast timeout (200ms) */
pr_slowtimo_t *pr_slowtimo; /* slow timeout (500ms) */
pr_drain_t *pr_drain; /* flush any excess space possible */
Modified: projects/vnet/sys/kern/uipc_domain.c
==============================================================================
--- projects/vnet/sys/kern/uipc_domain.c Mon May 16 22:16:54 2016 (r299979)
+++ projects/vnet/sys/kern/uipc_domain.c Mon May 16 22:33:48 2016 (r299980)
@@ -196,15 +196,7 @@ void
vnet_domain_uninit(void *arg)
{
struct domain *dp = arg;
- struct protosw *pr;
- for (pr = dp->dom_protosw; pr < dp->dom_protoswNPROTOSW; pr++)
- if (pr->pr_destroy) {
-#ifdef INVARIANTS
- printf("%s: pr %p called pr_destroy\n", __func__, pr);
-#endif
- (*pr->pr_destroy)();
- }
if (dp->dom_destroy)
(*dp->dom_destroy)();
}
Modified: projects/vnet/sys/sys/protosw.h
==============================================================================
--- projects/vnet/sys/sys/protosw.h Mon May 16 22:16:54 2016 (r299979)
+++ projects/vnet/sys/sys/protosw.h Mon May 16 22:33:48 2016 (r299980)
@@ -70,7 +70,6 @@ typedef int pr_output_t (struct mbuf *,
typedef void pr_ctlinput_t (int, struct sockaddr *, void *);
typedef int pr_ctloutput_t (struct socket *, struct sockopt *);
typedef void pr_init_t (void);
-typedef void pr_destroy_t (void);
typedef void pr_fasttimo_t (void);
typedef void pr_slowtimo_t (void);
typedef void pr_drain_t (void);
@@ -87,7 +86,6 @@ struct protosw {
pr_ctloutput_t *pr_ctloutput; /* control output (from above) */
/* utility hooks */
pr_init_t *pr_init;
- pr_destroy_t *pr_destroy;
pr_fasttimo_t *pr_fasttimo; /* fast timeout (200ms) */
pr_slowtimo_t *pr_slowtimo; /* slow timeout (500ms) */
pr_drain_t *pr_drain; /* flush any excess space possible */
More information about the svn-src-projects
mailing list