From owner-svn-src-all@freebsd.org Thu Oct 27 04:55:20 2016 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 80844C225BF; Thu, 27 Oct 2016 04:55:20 +0000 (UTC) (envelope-from sephe@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 380838C9; Thu, 27 Oct 2016 04:55:20 +0000 (UTC) (envelope-from sephe@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id u9R4tJIV098279; Thu, 27 Oct 2016 04:55:19 GMT (envelope-from sephe@FreeBSD.org) Received: (from sephe@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id u9R4tJHQ098276; Thu, 27 Oct 2016 04:55:19 GMT (envelope-from sephe@FreeBSD.org) Message-Id: <201610270455.u9R4tJHQ098276@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: sephe set sender to sephe@FreeBSD.org using -f From: Sepherosa Ziehau Date: Thu, 27 Oct 2016 04:55:19 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r307987 - in head/sys: dev/hyperv/netvsc net X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 27 Oct 2016 04:55:20 -0000 Author: sephe Date: Thu Oct 27 04:55:19 2016 New Revision: 307987 URL: https://svnweb.freebsd.org/changeset/base/307987 Log: hyperv/hn: Define empty packet filter. MFC after: 1 week Sponsored by: Microsoft Differential Revision: https://reviews.freebsd.org/D8342 Modified: head/sys/dev/hyperv/netvsc/hv_netvsc_drv_freebsd.c head/sys/dev/hyperv/netvsc/if_hnvar.h head/sys/net/rndis.h Modified: head/sys/dev/hyperv/netvsc/hv_netvsc_drv_freebsd.c ============================================================================== --- head/sys/dev/hyperv/netvsc/hv_netvsc_drv_freebsd.c Thu Oct 27 04:42:39 2016 (r307986) +++ head/sys/dev/hyperv/netvsc/hv_netvsc_drv_freebsd.c Thu Oct 27 04:55:19 2016 (r307987) @@ -3849,8 +3849,8 @@ hn_suspend_data(struct hn_softc *sc) /* * Disable RX by clearing RX filter. */ - hn_rndis_set_rxfilter(sc, 0); - sc->hn_rx_filter = 0; + sc->hn_rx_filter = NDIS_PACKET_TYPE_NONE; + hn_rndis_set_rxfilter(sc, sc->hn_rx_filter); /* * Give RNDIS enough time to flush all pending data packets. Modified: head/sys/dev/hyperv/netvsc/if_hnvar.h ============================================================================== --- head/sys/dev/hyperv/netvsc/if_hnvar.h Thu Oct 27 04:42:39 2016 (r307986) +++ head/sys/dev/hyperv/netvsc/if_hnvar.h Thu Oct 27 04:55:19 2016 (r307987) @@ -106,7 +106,7 @@ int hn_rndis_query_rsscaps(struct hn_so int hn_rndis_get_eaddr(struct hn_softc *sc, uint8_t *eaddr); int hn_rndis_get_linkstatus(struct hn_softc *sc, uint32_t *link_status); -/* filter: NDIS_PACKET_TYPE_ or 0. */ +/* filter: NDIS_PACKET_TYPE_. */ int hn_rndis_set_rxfilter(struct hn_softc *sc, uint32_t filter); int hn_nvs_attach(struct hn_softc *sc, int mtu); Modified: head/sys/net/rndis.h ============================================================================== --- head/sys/net/rndis.h Thu Oct 27 04:42:39 2016 (r307986) +++ head/sys/net/rndis.h Thu Oct 27 04:55:19 2016 (r307987) @@ -352,6 +352,7 @@ struct rndis_keepalive_comp { }; /* Packet filter bits used by OID_GEN_CURRENT_PACKET_FILTER */ +#define NDIS_PACKET_TYPE_NONE 0x00000000 #define NDIS_PACKET_TYPE_DIRECTED 0x00000001 #define NDIS_PACKET_TYPE_MULTICAST 0x00000002 #define NDIS_PACKET_TYPE_ALL_MULTICAST 0x00000004