svn commit: r293722 - head/sys/dev/hyperv/netvsc
Sepherosa Ziehau
sephe at FreeBSD.org
Tue Jan 12 01:55:59 UTC 2016
Author: sephe
Date: Tue Jan 12 01:55:57 2016
New Revision: 293722
URL: https://svnweb.freebsd.org/changeset/base/293722
Log:
hyperv/hn: Removed unused netvsc_init()
Submitted by: Dexuan Cui <decui microsoft com>
Reviewed by: me, adrian, royger,
Hongjiang Zhang <honzhan microsoft com>
Approved by: adrian (mentor)
Sponsored by: Microsoft OSTC
Differential Revision: https://reviews.freebsd.org/D4594
Modified:
head/sys/dev/hyperv/netvsc/hv_netvsc_drv_freebsd.c
Modified: head/sys/dev/hyperv/netvsc/hv_netvsc_drv_freebsd.c
==============================================================================
--- head/sys/dev/hyperv/netvsc/hv_netvsc_drv_freebsd.c Tue Jan 12 01:50:56 2016 (r293721)
+++ head/sys/dev/hyperv/netvsc/hv_netvsc_drv_freebsd.c Tue Jan 12 01:55:57 2016 (r293722)
@@ -149,14 +149,6 @@ __FBSDID("$FreeBSD$");
(hiwat) <= HN_LRO_HIWAT_MAX)
/*
- * Data types
- */
-
-struct hv_netvsc_driver_context {
- uint32_t drv_inited;
-};
-
-/*
* Be aware that this sleepable mutex will exhibit WITNESS errors when
* certain TCP and ARP code paths are taken. This appears to be a
* well-known condition, as all other drivers checked use a sleeping
@@ -178,9 +170,6 @@ struct hv_netvsc_driver_context {
int hv_promisc_mode = 0; /* normal mode by default */
-/* The one and only one */
-static struct hv_netvsc_driver_context g_netvsc_drv;
-
/* Trust tcp segements verification on host side. */
static int hn_trust_hosttcp = 0;
TUNABLE_INT("dev.hn.trust_hosttcp", &hn_trust_hosttcp);
@@ -289,37 +278,6 @@ hn_ifmedia_sts(struct ifnet *ifp, struct
ifmr->ifm_active |= IFM_10G_T | IFM_FDX;
}
-/*
- * NetVsc driver initialization
- * Note: Filter init is no longer required
- */
-static int
-netvsc_drv_init(void)
-{
- return (0);
-}
-
-/*
- * NetVsc global initialization entry point
- */
-static void
-netvsc_init(void)
-{
- if (bootverbose)
- printf("Netvsc initializing... ");
-
- /*
- * XXXKYS: cleanup initialization
- */
- if (!cold && !g_netvsc_drv.drv_inited) {
- g_netvsc_drv.drv_inited = 1;
- netvsc_drv_init();
- if (bootverbose)
- printf("done!\n");
- } else if (bootverbose)
- printf("Already initialized!\n");
-}
-
/* {F8615163-DF3E-46c5-913F-F2D2F965ED0E} */
static const hv_guid g_net_vsc_device_type = {
.data = {0x63, 0x51, 0x61, 0xF8, 0x3E, 0xDF, 0xc5, 0x46,
@@ -365,8 +323,6 @@ netvsc_attach(device_t dev)
struct sysctl_ctx_list *ctx;
int ret;
- netvsc_init();
-
sc = device_get_softc(dev);
if (sc == NULL) {
return (ENOMEM);
@@ -1608,6 +1564,3 @@ static devclass_t netvsc_devclass;
DRIVER_MODULE(hn, vmbus, netvsc_driver, netvsc_devclass, 0, 0);
MODULE_VERSION(hn, 1);
MODULE_DEPEND(hn, vmbus, 1, 1, 1);
-SYSINIT(netvsc_initx, SI_SUB_KTHREAD_IDLE, SI_ORDER_MIDDLE + 1, netvsc_init,
- NULL);
-
More information about the svn-src-all
mailing list