svn commit: r305044 - in head/sys: dev/hyperv/netvsc net
Sepherosa Ziehau
sephe at FreeBSD.org
Tue Aug 30 02:55:08 UTC 2016
Author: sephe
Date: Tue Aug 30 02:55:07 2016
New Revision: 305044
URL: https://svnweb.freebsd.org/changeset/base/305044
Log:
hyperv/hn: Move OIDs to net/rndis.h; they are standard NDIS OIDs.
Actually all OIDs defined in net/rndis.h are standard NDIS OIDs.
While I'm here, use the verbose macro name as in NDIS spec.
MFC after: 1 week
Sponsored by: Microsoft
Differential Revision: https://reviews.freebsd.org/D7679
Modified:
head/sys/dev/hyperv/netvsc/hv_rndis_filter.c
head/sys/dev/hyperv/netvsc/ndis.h
head/sys/net/rndis.h
Modified: head/sys/dev/hyperv/netvsc/hv_rndis_filter.c
==============================================================================
--- head/sys/dev/hyperv/netvsc/hv_rndis_filter.c Tue Aug 30 02:09:40 2016 (r305043)
+++ head/sys/dev/hyperv/netvsc/hv_rndis_filter.c Tue Aug 30 02:55:07 2016 (r305044)
@@ -941,7 +941,7 @@ hn_rndis_get_rsscaps(struct hn_softc *sc
in.ndis_hdr.ndis_size = NDIS_RSS_CAPS_SIZE;
caps_len = NDIS_RSS_CAPS_SIZE;
- error = hn_rndis_query(sc, OID_GEN_RSS_CAPABILITIES,
+ error = hn_rndis_query(sc, OID_GEN_RECEIVE_SCALE_CAPABILITIES,
&in, NDIS_RSS_CAPS_SIZE, &caps, &caps_len);
if (error)
return (error);
@@ -1092,7 +1092,8 @@ hn_rndis_conf_rss(struct hn_softc *sc, i
for (i = 0; i < NDIS_HASH_INDCNT; ++i)
rss->rss_ind[i] = i % nchan;
- error = hn_rndis_set(sc, OID_GEN_RSS_PARAMETERS, rss, sizeof(*rss));
+ error = hn_rndis_set(sc, OID_GEN_RECEIVE_SCALE_PARAMETERS,
+ rss, sizeof(*rss));
if (error) {
if_printf(sc->hn_ifp, "RSS config failed: %d\n", error);
} else {
Modified: head/sys/dev/hyperv/netvsc/ndis.h
==============================================================================
--- head/sys/dev/hyperv/netvsc/ndis.h Tue Aug 30 02:09:40 2016 (r305043)
+++ head/sys/dev/hyperv/netvsc/ndis.h Tue Aug 30 02:55:07 2016 (r305044)
@@ -32,10 +32,6 @@
#define NDIS_MEDIA_STATE_CONNECTED 0
#define NDIS_MEDIA_STATE_DISCONNECTED 1
-#define OID_GEN_RSS_CAPABILITIES 0x00010203
-#define OID_GEN_RSS_PARAMETERS 0x00010204
-#define OID_TCP_OFFLOAD_PARAMETERS 0xFC01020C
-
#define NDIS_OBJTYPE_DEFAULT 0x80
#define NDIS_OBJTYPE_RSS_CAPS 0x88
#define NDIS_OBJTYPE_RSS_PARAMS 0x89
@@ -143,7 +139,7 @@ struct ndis_offload_params {
#define NDIS_OFFLOAD_RSC_ON 2
/*
- * OID_GEN_RSS_CAPABILITIES
+ * OID_GEN_RECEIVE_SCALE_CAPABILITIES
* ndis_type: NDIS_OBJTYPE_RSS_CAPS
*/
struct ndis_rss_caps {
@@ -174,7 +170,7 @@ struct ndis_rss_caps {
#define NDIS_RSS_CAP_HASH_TOEPLITZ 0x00000001
/*
- * OID_GEN_RSS_PARAMETERS
+ * OID_GEN_RECEIVE_SCALE_PARAMETERS
* ndis_type: NDIS_OBJTYPE_RSS_PARAMS
*/
struct ndis_rss_params {
Modified: head/sys/net/rndis.h
==============================================================================
--- head/sys/net/rndis.h Tue Aug 30 02:09:40 2016 (r305043)
+++ head/sys/net/rndis.h Tue Aug 30 02:55:07 2016 (r305044)
@@ -62,6 +62,8 @@
#define OID_GEN_SUPPORTED_GUIDS 0x00010117
#define OID_GEN_NETWORK_LAYER_ADDRESSES 0x00010118
#define OID_GEN_TRANSPORT_HEADER_OFFSET 0x00010119
+#define OID_GEN_RECEIVE_SCALE_CAPABILITIES 0x00010203
+#define OID_GEN_RECEIVE_SCALE_PARAMETERS 0x00010204
#define OID_GEN_MACHINE_NAME 0x0001021A
#define OID_GEN_RNDIS_CONFIG_PARAMETER 0x0001021B
#define OID_GEN_VLAN_ID 0x0001021C
@@ -82,6 +84,8 @@
#define OID_802_3_XMIT_TIMES_CRS_LOST 0x01020206
#define OID_802_3_XMIT_LATE_COLLISIONS 0x01020207
+#define OID_TCP_OFFLOAD_PARAMETERS 0xFC01020C
+
#define RNDIS_MEDIUM_802_3 0x00000000
/* Device flags */
More information about the svn-src-head
mailing list