[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: [PATCH 2/4] Update to NDIS 6.30


  • To: "paul@xxxxxxx" <paul@xxxxxxx>, "win-pv-devel@xxxxxxxxxxxxxxxxxxxx" <win-pv-devel@xxxxxxxxxxxxxxxxxxxx>
  • From: Owen Smith <owen.smith@xxxxxxxxxx>
  • Date: Tue, 2 Nov 2021 10:35:58 +0000
  • Accept-language: en-GB, en-US
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=citrix.com; dmarc=pass action=none header.from=citrix.com; dkim=pass header.d=citrix.com; arc=none
  • Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=5tzuDEb+L9S/Ibf74nP5xm1gsi7oNMdPt+y1xtQvxG4=; b=KTaJAh6wTlTLgocbesfE4U7FKihBK8vmYjOkFbSZ5F3L/9wAgrI1OKQ4Ei5TQ4gyOADLTPUaF8LEJoC8hBQ6bq5RL7SSWBw3Vi8Vg6WjCZ7wvc5C/NVpD27oHJIZ7c5VjN0fUs/f7fgvZ6TQf2FB/saKz2yY3Iyl7fibJPRO5S6t9z8Kr3GrpY7/OLKdQ/KryE0R9K7Jsi7rFxEIAP8SVNwTl+j+4YFcmdTaeCtjhdtg84fGcE2o2X6VPfFYFRKBYZRKR3MyuT51rGn2lckBYPdP0BWeo6NXDJwt8dbRD3JTNgDsC/8lfJ0OBD16XZ8aerbV+UQLlC8dtNHf4MSnsw==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=LI9hhldKaUIpivi6VC0z/FV5UAvTPVwSur0SZSRpwh/BBMwIKGQjysJp6ABP0ao8/P4eYLKvh44+zzPcEQ7X3khh0/o/+3XyPjFAFD9HjbAKZMGCQuHfgMA1tXmsU6Vs+cPH0FyrXcMKpvpHswu57x/pfFW9O9G6s0V8JUUV5uMs0SDsoGQ/Z/zOZL4awuxrUbFrwp2Ax9+iUVto5KzFNysRFhgNK9kHt5FAed+IPSVWaoWQKrxCOU4r2c+s2ohF3U3MuukfNV7AzhCEXRwzM/+KYxuUfMaxeRueNVvW8j1vuQPOhyNQS+i2oOtLwpbYHguiu8b7SHwyLpVjx+yyhA==
  • Authentication-results: esa5.hc3370-68.iphmx.com; dkim=pass (signature verified) header.i=@citrix.onmicrosoft.com
  • Delivery-date: Tue, 02 Nov 2021 10:36:05 +0000
  • Ironport-data: A9a23:MCbhk6tqyowk73ntPEnw+dhCvefnVJ5ZMUV32f8akzHdYApBsoF/q tZmKTuAO/feNGr3fNggYdji9hkFusOBzNRkSgVsrHhnFiJA+JbJXdiXEBz9bniYRiHhoOOLz Cm8hv3odp1coqr0/0/1WlTZQP0VOZigHtIQMsadUsxKbVIiGHhJZS5LwbZj29cx2YLhWmthh PupyyHhEA79s9JLGjp8B5Kr8HuDa9yr5Vv0FnRnDRx6lAe2e0s9VfrzFonoR5fMeaFGH/bSe gr25OrRElU1XfsaIojNfr7TKiXmS1NJVOSEoiI+t6OK2nCuqsGuu0qS2TV1hUp/0l20c95NJ NplsM2gazgsA6r2yfkMaAsEGihMAbV49+qSSZS/mZT7I0zudnLtx7NlDV0sPJ1e8eFyaY1M3 aVGcnZXNEnF3r/ohuLgIgVvrp1LwM3DO5wSvDd7yDDFDd4tQIzZQrWM7thdtNs1rp0QQa6CO JpFAdZpRC3uXjxpawkmM6w/wuW1uVzRQg0BqGvA8MLb5ECMlVcsgdABKuH9Zd2MAN1L20qVu G/C12D4GQ0BcsySzyKf9XChjfOJmjn0MKoKHaC83u5nhhuU3GN7NfENfQLl+7/j0Bf4Ao8Bb RxPksYzkUQs3En6XvvCWiC/mi+ZryUOB9NZIdEi1g7Yn8I4/D2lLmQDSzdAbvkvu8k3WSEm2 ze1oj/5OdB8mObLECzAr994uRv3YHFIdjFaOUfoWCNcu4G7yLzfmC4jWTqK/ESdqtTuUQ/9z DmRxMTVr+VC1JVbv0lXEL2uvt5NmnQrZlJljuk0djj8hu+cWGJDT9bxgbQ8xa0YRLt1tnHb4 BA5dzG2tYji962lmi2XW/kqF7q0/fuDOzC0qQcxRMR+pm71pCT5JNw4DNRCyKFBaJ9sldjBO xe7hO+szMULYCvCgVFfOtrZ5zsWIVjISo2+C6G8gitmaZltbg6XlByClmbLt10BZHMEyPllU b/CKJ7EJS9DVcxPkWrnL89AgORD7n1vmgvuqWXTkk3PPUy2PyXOF9/o8TKmM4gE0U9ziFyOr osEaJfSk32ykoTWO0HqzGLaFnhTRVATDpHqsc1HMOmFJwttAmY6DPHNh7gmfuRYc259z48kJ 1mxBR1VzkTRn3rCJVnYY3xvcuq3D51+sWg6LWonOlPxgyovZoOm7aE+cZorfOZ4qLw/nKAsF /RVKd+dBvlvSyjc/2hPZ5fKs4E/Jg+gghiDPnT5bWFnLYJgXQHA5vTtYhDrqHsVFiOyuMZn+ ++g2wrXTIAtXQNnCMqKOvujw0no5SoWmf5oXluOKd5WIR2+/I9vIi33r/k2P8BTdkmTmmrEj 16bWE5Kq/PMrok59MjyqZqF94r5QfFjGkd6HnXA6erkPyft4Wf+k5RLV/yFfG6BWTqsqrmif +hc09r1LOYDwARRq4N5HrtmkfA+6t/oq+MIxwhoBiyWPVGiC7cmKXiax8hf8KZKw+YB6wexX 0uO/PhcOKmIZ5y5QAJAelJ9Y7TRz+wQlxnT8e8xcRfz6yJA9baaVVlfYkuXgytHIbopaI4oz I/NYiLNB9BTXvbyDuu7sw==
  • Ironport-hdrordr: A9a23:HcBdtayGoPN0MOo/UX7BKrPxk+skLtp133Aq2lEZdPULSKOlfp GV8MjziyWYtN9IYgBbpTnyAtj8fZq6z+843WBxB8buYOCCggWVxe5ZnO3fKlHbak7DH6tmpN xdmstFeZLN5DpB/L/HCWCDer5KqrjmzEnrv5an854Ed3AyV0gK1XYdNu/vKDwQeOAwP+tcKH Pz3LskmxOQPVAsKuirDHgMWObO4/fRkoj9XBIADxk7rCGTkDKB8tfBYlal9yZbdwkK7aYp8G DDnQC8zL6kqeuHxhjV0HKWx4hKmeHm1sBICKW3+4kow3TX+0aVjbZaKv+/VQMO0aSSAZER4Z 3xSiIbTodOArXqDyaISFXWqk/dOX0VmgPfIBej8ATeSIrCNWoH4oN69PxkWwqc5Ew6sN5m1q VXm2qfqppMFBvF2D/w/t7SSnhR5wKJSFcZ4JguZkZkIMIjgX5q3P4i1VIQFI1FEDPx6YghHu UrBMbA5OxOeVffa3zCpGFgzNGlQ3x2R369MwI/k93Q1yITkGFyzkMeysBalnAc9IglQ50B4+ jfKKxnmLxHU8dTZ6NgA+UKR9exFwX2MFnxGXPXJU6iGLAMOnrLpZKy6LIp5PuycJhN15c2kI SpaiIuiYfzQTObNSSj5uw6zvn9ehTJYd228LAu23FQgMyOeIbW
  • Ironport-sdr: t96J+VAGNR9XktzgvP3iRdS34T4fPYOFv1LIOhc+PPA4rZZ9VI03FH43Jt83XAhaMSKOgZKSbB pc64cKkQBKvpepwtdOVz8aUjxkhfT3PCVSwGKYQnTBZUrZp7tjScC/FEC7Jq6F/cpztlOtVHGH pr7PhdwQNHhthe8JG5JO1HncP43XuH4x7kgfBGqbKKVlgcAOzlXDNT4tTor9MSDiS7PxEXEQcA L4/gh/urU9C/SV4KoFcl4U3z/vLdu5lLH6cs+XqFPQJXuP50CETIGt2QJKYRNPyUsWrsZzgKsd dx3ddDF4jB2sqdDR7zAP0iyn
  • List-id: Developer list for the Windows PV Drivers subproject <win-pv-devel.lists.xenproject.org>
  • Thread-index: AQHXyjjTPolPNZWqp0yfvASsNlk1ZqvwDtQAgAAFnYA=
  • Thread-topic: [PATCH 2/4] Update to NDIS 6.30

-----Original Message-----
From: win-pv-devel <win-pv-devel-bounces@xxxxxxxxxxxxxxxxxxxx> On Behalf Of 
Durrant, Paul
Sent: 02 November 2021 10:09
To: win-pv-devel@xxxxxxxxxxxxxxxxxxxx
Subject: Re: [PATCH 2/4] Update to NDIS 6.30

[CAUTION - EXTERNAL EMAIL] DO NOT reply, click links, or open attachments 
unless you have verified the sender and know the content is safe.

On 26/10/2021 08:12, Owen Smith wrote:
> NDIS 6.30 was introduced in Server 2012. Update XenNet to use the NDIS 
> 6.30 interfaces. No additional features of NDIS 6.30 are used.

This doesn't seem to be the case. You've clearly updated RSS in this patch. 
Could you expand the commit comment accordingly?

   Paul


Most of the changes are updating structure versions, though NDIS 6.20 -> 6.30 
had to change some structures to fit the newer API.
There is an extra property required by the tests, and it needs to limit the 
reported number of RSS queues.
There is also some changes to use the NDIS 6.30 structures, specifically there 
is a change from processor indexes to PROCESSOR_NUMBERs passed for the 
indirection table (which xennet had to convert to a PROCESSOR_NUMBER array 
before passing to xenvif). I did rename TableSize to TableCount for clarity 
(i.e. number of elements, not number of bytes)

These were bare minimum changes to pass the NDIS WHQL tests.

I will re-post with an expanded patch message

Owen

> Also fixes "NDIS 6.5 GlitchFreeDevice" test by correctly reporting 
> XenNet uses a WDM lower edge.
> 
> Signed-off-by: Owen Smith <owen.smith@xxxxxxxxxx>
> ---
>   src/xennet.inf               |  7 +++
>   src/xennet/adapter.c         | 89 +++++++++++++++++++-----------------
>   vs2015/xennet/xennet.vcxproj |  2 +-
>   vs2017/xennet/xennet.vcxproj |  2 +-
>   vs2019/xennet/xennet.vcxproj |  2 +-
>   5 files changed, 56 insertions(+), 46 deletions(-)
> 
> diff --git a/src/xennet.inf b/src/xennet.inf index b36b1e3..f93acba 
> 100644
> --- a/src/xennet.inf
> +++ b/src/xennet.inf
> @@ -166,6 +166,12 @@ HKR, Ndi\params\*RSS,                             
> Optional,   0, "0"
>   HKR, Ndi\params\*RSS\enum,                        "0",        0, %Disabled%
>   HKR, Ndi\params\*RSS\enum,                        "1",        0, %Enabled%
>   
> +HKR, Ndi\params\*NumRSSQueues,                    ParamDesc,  0, 
> %NumRSSQueues%
> +HKR, Ndi\params\*NumRSSQueues,                    Type,       0, "int"
> +HKR, Ndi\params\*NumRSSQueues,                    Default,    0, "8"
> +HKR, Ndi\params\*NumRSSQueues,                    Min,        0, "1"
> +HKR, Ndi\params\*NumRSSQueues,                    Max,        0, "8"
> +
>   [XenNet_Inst.Services]
>   AddService=xennet,0x02,XenNet_Service,XenNet_EventLog
>   
> @@ -211,6 +217,7 @@ LSOV2IPv6="Large Send Offload V2 (IPv6)"
>   LROIPv4="Large Receive Offload (IPv4)"
>   LROIPv6="Large Receive Offload (IPv6)"
>   RSS="Receive Side Scaling"
> +NumRSSQueues="Maximum Number of RSS Queues"
>   HeaderDataSplit="Header Data Split"
>   Disabled="Disabled"
>   Enabled="Enabled"
> diff --git a/src/xennet/adapter.c b/src/xennet/adapter.c index 
> eaa2c1b..7bfdc4a 100644
> --- a/src/xennet/adapter.c
> +++ b/src/xennet/adapter.c
> @@ -61,17 +61,18 @@ typedef struct _PROPERTIES {
>       int lrov4;
>       int lrov6;
>       int rss;
> +    int numrssqueues;
>   } PROPERTIES, *PPROPERTIES;
>   
>   typedef struct _XENNET_RSS {
> -    BOOLEAN Supported;
> -    BOOLEAN HashEnabled;
> -    BOOLEAN ScaleEnabled;
> -    ULONG   Types;
> -    UCHAR   Key[NDIS_RSS_HASH_SECRET_KEY_MAX_SIZE_REVISION_1];
> -    ULONG   KeySize;
> -    CCHAR   Table[NDIS_RSS_INDIRECTION_TABLE_MAX_SIZE_REVISION_1];
> -    ULONG   TableSize;
> +    BOOLEAN             Supported;
> +    BOOLEAN             HashEnabled;
> +    BOOLEAN             ScaleEnabled;
> +    ULONG               Types;
> +    UCHAR               Key[NDIS_RSS_HASH_SECRET_KEY_MAX_SIZE_REVISION_2];
> +    ULONG               KeySize;
> +    PROCESSOR_NUMBER    Table[NDIS_RSS_INDIRECTION_TABLE_MAX_SIZE_REVISION_2 
> / sizeof(PROCESSOR_NUMBER)];
> +    ULONG               TableCount;
>   } XENNET_RSS, *PXENNET_RSS;
>   
>   struct _XENNET_ADAPTER {
> @@ -88,7 +89,7 @@ struct _XENNET_ADAPTER {
>   
>       NDIS_HANDLE                 NdisAdapterHandle;
>       NDIS_HANDLE                 NdisDmaHandle;
> -    NDIS_PNP_CAPABILITIES       Capabilities;
> +    NDIS_PM_CAPABILITIES        Capabilities;
>       NDIS_OFFLOAD                Offload;
>       PROPERTIES                  Properties;
>       XENNET_RSS                  Rss;
> @@ -108,6 +109,7 @@ static NDIS_OID XennetSupportedOids[] =
>       OID_GEN_MEDIA_SUPPORTED,
>       OID_GEN_MEDIA_IN_USE,
>       OID_GEN_PHYSICAL_MEDIUM,
> +    OID_GEN_PHYSICAL_MEDIUM_EX,
>       OID_GEN_CURRENT_LOOKAHEAD,
>       OID_GEN_MAXIMUM_LOOKAHEAD,
>       OID_GEN_MAXIMUM_FRAME_SIZE,
> @@ -150,7 +152,7 @@ static NDIS_OID XennetSupportedOids[] =
>       OID_802_3_XMIT_MORE_COLLISIONS,
>       OID_OFFLOAD_ENCAPSULATION,
>       OID_TCP_OFFLOAD_PARAMETERS,
> -    OID_PNP_CAPABILITIES,
> +    OID_PM_CURRENT_CAPABILITIES,
>       OID_PNP_QUERY_POWER,
>       OID_PNP_SET_POWER,
>       OID_GEN_RECEIVE_SCALE_PARAMETERS, @@ -721,14 +723,12 @@ 
> AdapterDisableRSSHash(
>   
>   static NDIS_STATUS
>   AdapterUpdateRSSTable(
> -    IN  PXENNET_ADAPTER Adapter,
> -    IN  PCCHAR          Table,
> -    IN  ULONG           TableSize
> +    IN  PXENNET_ADAPTER     Adapter,
> +    IN  PPROCESSOR_NUMBER   Table,
> +    IN  ULONG               TableSize
>       )
>   {
> -    PROCESSOR_NUMBER    
> Mapping[NDIS_RSS_INDIRECTION_TABLE_MAX_SIZE_REVISION_1];
> -    ULONG               Index;
> -    NTSTATUS            status;
> +    NTSTATUS                status;
>   
>       if (TableSize == 0) {
>           AdapterDisableRSSHash(Adapter); @@ -740,18 +740,12 @@ 
> AdapterUpdateRSSTable(
>   
>       RtlZeroMemory(Adapter->Rss.Table, sizeof (Adapter->Rss.Table)) ;
>       RtlCopyMemory(Adapter->Rss.Table, Table, TableSize);
> -    Adapter->Rss.TableSize = TableSize;
> -
> -    RtlZeroMemory(Mapping, sizeof (Mapping));
> -    for (Index = 0; Index < TableSize; Index++) {
> -        Mapping[Index].Group = 0;
> -        Mapping[Index].Number = Table[Index];
> -    }
> +    Adapter->Rss.TableCount = TableSize / sizeof(PROCESSOR_NUMBER);
>   
>       status = XENVIF_VIF(UpdateHashMapping,
>                           &Adapter->VifInterface,
> -                        Mapping,
> -                        TableSize);
> +                        Table,
> +                        Adapter->Rss.TableCount);
>   
>       return (NT_SUCCESS(status)) ? NDIS_STATUS_SUCCESS : 
> NDIS_STATUS_INVALID_DATA;
>   }
> @@ -900,12 +894,12 @@ DisplayRss(
>           }
>       }
>   
> -    if (Rss->TableSize != 0) {
> +    if (Rss->TableCount != 0) {
>           ULONG   Index;
>   
>           Trace("Table:\n");
>   
> -        for (Index = 0; Index < Rss->TableSize; ) {
> +        for (Index = 0; Index < Rss->TableCount; ) {
>               CHAR    Buffer[80];
>               STRING  String;
>               ULONG   Count;
> @@ -916,8 +910,8 @@ DisplayRss(
>               String.Length = 0;
>   
>               Count = 8;
> -            if (Index + Count >= Rss->TableSize)
> -                Count = Rss->TableSize - Index;
> +            if (Index + Count >= Rss->TableCount)
> +                Count = Rss->TableCount - Index;
>   
>               (VOID) StringPrintf(&String, "[%2u - %2u]: ",
>                                   Index, @@ -928,8 +922,9 @@ 
> DisplayRss(
>               String.Length = 0;
>   
>               for (Column = 0; Column < Count; Column++, Index++) {
> -                (VOID) StringPrintf(&String, "%02x ",
> -                                    Rss->Table[Index]);
> +                (VOID) StringPrintf(&String, "%02x:%02x ",
> +                                    Rss->Table[Index].Group,
> +                                    Rss->Table[Index].Number);
>   
>                   String.Buffer += String.Length;
>                   String.MaximumLength -= String.Length; @@ -950,8 
> +945,8 @@ AdapterGetReceiveScaleParameters(
>       NDIS_STATUS                         ndisStatus;
>   
>       ASSERT3U(Parameters->Header.Type, ==, NDIS_OBJECT_TYPE_RSS_PARAMETERS);
> -    ASSERT3U(Parameters->Header.Revision, ==, 
> NDIS_RECEIVE_SCALE_PARAMETERS_REVISION_1);
> -    ASSERT3U(Parameters->Header.Size, >=, 
> NDIS_SIZEOF_RECEIVE_SCALE_PARAMETERS_REVISION_1);
> +    ASSERT3U(Parameters->Header.Revision, ==, 
> NDIS_RECEIVE_SCALE_PARAMETERS_REVISION_2);
> +    ASSERT3U(Parameters->Header.Size, >=, 
> + NDIS_SIZEOF_RECEIVE_SCALE_PARAMETERS_REVISION_2);
>   
>       if (!Adapter->Rss.Supported)
>           return NDIS_STATUS_NOT_SUPPORTED; @@ -985,7 +980,7 @@ 
> AdapterGetReceiveScaleParameters(
>   
>       if (!(Parameters->Flags & NDIS_RSS_PARAM_FLAG_ITABLE_UNCHANGED)) {
>           ndisStatus = AdapterUpdateRSSTable(Adapter,
> -                                           (PCCHAR)Parameters + 
> Parameters->IndirectionTableOffset,
> +                                           
> + (PPROCESSOR_NUMBER)((PCCHAR)Parameters + 
> + Parameters->IndirectionTableOffset),
>                                              
> Parameters->IndirectionTableSize);
>           if (ndisStatus != NDIS_STATUS_SUCCESS)
>               goto fail;
> @@ -2277,7 +2272,7 @@ AdapterQueryInformation(
>       ndisStatus = NDIS_STATUS_SUCCESS;
>   
>       switch (Request->DATA.QUERY_INFORMATION.Oid) {
> -    case OID_PNP_CAPABILITIES:
> +    case OID_PM_CURRENT_CAPABILITIES:
>           BytesNeeded = sizeof(Adapter->Capabilities);
>           ndisStatus = __CopyBuffer(Buffer,
>                                     BufferLength, @@ -2926,6 +2921,7 
> @@ AdapterGetAdvancedSettings(
>       READ_PROPERTY(Adapter->Properties.lrov6, L"LROIPv6", 1, Handle);
>       READ_PROPERTY(Adapter->Properties.need_csum_value, 
> L"NeedChecksumValue", 1, Handle);
>       READ_PROPERTY(Adapter->Properties.rss, L"*RSS", 1, Handle);
> +    READ_PROPERTY(Adapter->Properties.numrssqueues, L"*NumRSSQueues", 
> + 8, Handle);
>   
>       NdisCloseConfiguration(Handle);
>   
> @@ -2949,11 +2945,12 @@ AdapterSetRegistrationAttributes(
>   
>       RtlZeroMemory(&Attribs, sizeof(Attribs));
>       Attribs.Header.Type = 
> NDIS_OBJECT_TYPE_MINIPORT_ADAPTER_REGISTRATION_ATTRIBUTES;
> -    Attribs.Header.Revision = 
> NDIS_MINIPORT_ADAPTER_REGISTRATION_ATTRIBUTES_REVISION_1;
> -    Attribs.Header.Size = 
> NDIS_SIZEOF_MINIPORT_ADAPTER_REGISTRATION_ATTRIBUTES_REVISION_1;
> +    Attribs.Header.Revision = 
> NDIS_MINIPORT_ADAPTER_REGISTRATION_ATTRIBUTES_REVISION_2;
> +    Attribs.Header.Size = 
> + NDIS_SIZEOF_MINIPORT_ADAPTER_REGISTRATION_ATTRIBUTES_REVISION_2;
>       Attribs.MiniportAdapterContext = (NDIS_HANDLE)Adapter;
>       Attribs.AttributeFlags = NDIS_MINIPORT_ATTRIBUTES_BUS_MASTER |
> -                             NDIS_MINIPORT_ATTRIBUTES_NO_HALT_ON_SUSPEND;
> +                             NDIS_MINIPORT_ATTRIBUTES_NO_HALT_ON_SUSPEND |
> +                             NDIS_MINIPORT_ATTRIBUTES_NDIS_WDM;
>       Attribs.CheckForHangTimeInSeconds = 0;
>       Attribs.InterfaceType = XENNET_INTERFACE_TYPE;
>   
> @@ -2976,8 +2973,8 @@ AdapterSetGeneralAttributes(
>   
>       RtlZeroMemory(&Attribs, sizeof(Attribs));
>       Attribs.Header.Type = 
> NDIS_OBJECT_TYPE_MINIPORT_ADAPTER_GENERAL_ATTRIBUTES;
> -    Attribs.Header.Revision = 
> NDIS_MINIPORT_ADAPTER_GENERAL_ATTRIBUTES_REVISION_1;
> -    Attribs.Header.Size = 
> NDIS_SIZEOF_MINIPORT_ADAPTER_GENERAL_ATTRIBUTES_REVISION_1;
> +    Attribs.Header.Revision = 
> NDIS_MINIPORT_ADAPTER_GENERAL_ATTRIBUTES_REVISION_2;
> +    Attribs.Header.Size = 
> + NDIS_SIZEOF_MINIPORT_ADAPTER_GENERAL_ATTRIBUTES_REVISION_2;
>       Attribs.MediaType = XENNET_MEDIA_TYPE;
>   
>       XENVIF_VIF(MacQueryMaximumFrameSize,
> @@ -2992,7 +2989,7 @@ AdapterSetGeneralAttributes(
>       Attribs.MediaConnectState = MediaConnectStateConnected;
>       Attribs.MediaDuplexState = MediaDuplexStateFull;
>       Attribs.LookaheadSize = Adapter->MaximumFrameSize;
> -    Attribs.PowerManagementCapabilities = &Adapter->Capabilities;
> +    Attribs.PowerManagementCapabilitiesEx = &Adapter->Capabilities;
>       Attribs.MacOptions = XENNET_MAC_OPTIONS;
>       Attribs.SupportedPacketFilters = XENNET_SUPPORTED_PACKET_FILTERS;
>       Attribs.MaxMulticastListSize = 32; @@ -3054,8 +3051,8 @@ 
> AdapterSetGeneralAttributes(
>   
>       RtlZeroMemory(&Rss, sizeof(Rss));
>       Rss.Header.Type = NDIS_OBJECT_TYPE_RSS_CAPABILITIES;
> -    Rss.Header.Revision = NDIS_RECEIVE_SCALE_CAPABILITIES_REVISION_1;
> -    Rss.Header.Size = NDIS_SIZEOF_RECEIVE_SCALE_CAPABILITIES_REVISION_1;
> +    Rss.Header.Revision = NDIS_RECEIVE_SCALE_CAPABILITIES_REVISION_2;
> +    Rss.Header.Size = 
> + NDIS_SIZEOF_RECEIVE_SCALE_CAPABILITIES_REVISION_2;
>   
>       Rss.CapabilitiesFlags = NDIS_RSS_CAPS_MESSAGE_SIGNALED_INTERRUPTS |
>                               NDIS_RSS_CAPS_CLASSIFICATION_AT_ISR | @@ 
> -3073,6 +3070,12 @@ AdapterSetGeneralAttributes(
>                  &Rss.NumberOfReceiveQueues);
>       Rss.NumberOfInterruptMessages = Rss.NumberOfReceiveQueues;
>   
> +    if ((ULONG)Adapter->Properties.numrssqueues < Rss.NumberOfReceiveQueues)
> +        Rss.NumberOfReceiveQueues = Adapter->Properties.numrssqueues;
> +
> +    Rss.NumberOfInterruptMessages = Rss.NumberOfReceiveQueues;
> +    Rss.NumberOfIndirectionTableEntries = 128; // WHQL requirement 
> + for NDIS 6.30
> +
>       Info("%ws: RSS ENABLED (%u QUEUES)\n",
>            Adapter->Location,
>            Rss.NumberOfReceiveQueues); diff --git 
> a/vs2015/xennet/xennet.vcxproj b/vs2015/xennet/xennet.vcxproj index 
> 2d04c4e..b68d734 100644
> --- a/vs2015/xennet/xennet.vcxproj
> +++ b/vs2015/xennet/xennet.vcxproj
> @@ -22,7 +22,7 @@
>     </PropertyGroup>
>     <ItemDefinitionGroup>
>       <ClCompile>
> -      
> <PreprocessorDefinitions>PROJECT=$(ProjectName);NDIS_MINIPORT_DRIVER;NDIS_WDM=1;NDIS61_MINIPORT=1;POOL_NX_OPTIN=1;NT_PROCESSOR_GROUPS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
> +      
> + <PreprocessorDefinitions>PROJECT=$(ProjectName);NDIS_MINIPORT_DRIVER
> + ;NDIS_WDM=1;NDIS630_MINIPORT=1;POOL_NX_OPTIN=1;NT_PROCESSOR_GROUPS;%
> + (PreprocessorDefinitions)</PreprocessorDefinitions>
>         
> <AdditionalIncludeDirectories>$(WindowsSdkDir)\include\km;..\..\include;..\..\include\xen;</AdditionalIncludeDirectories>
>         <WarningLevel>EnableAllWarnings</WarningLevel>
>         
> <DisableSpecificWarnings>4464;4711;4548;4820;4668;4255;6001;6054;28160
> ;28196;30030;30029;%(DisableSpecificWarnings)</DisableSpecificWarnings
> > diff --git a/vs2017/xennet/xennet.vcxproj 
> b/vs2017/xennet/xennet.vcxproj index 0c27304..130b0e6 100644
> --- a/vs2017/xennet/xennet.vcxproj
> +++ b/vs2017/xennet/xennet.vcxproj
> @@ -22,7 +22,7 @@
>     </PropertyGroup>
>     <ItemDefinitionGroup>
>       <ClCompile>
> -      
> <PreprocessorDefinitions>PROJECT=$(ProjectName);NDIS_MINIPORT_DRIVER;NDIS_WDM=1;NDIS61_MINIPORT=1;POOL_NX_OPTIN=1;NT_PROCESSOR_GROUPS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
> +      
> + <PreprocessorDefinitions>PROJECT=$(ProjectName);NDIS_MINIPORT_DRIVER
> + ;NDIS_WDM=1;NDIS630_MINIPORT=1;POOL_NX_OPTIN=1;NT_PROCESSOR_GROUPS;%
> + (PreprocessorDefinitions)</PreprocessorDefinitions>
>         <IntrinsicFunctions>true</IntrinsicFunctions>
>         
> <AdditionalIncludeDirectories>$(WindowsSdkDir)\include\km;..\..\include;..\..\include\xen;</AdditionalIncludeDirectories>
>         <WarningLevel>EnableAllWarnings</WarningLevel>
> diff --git a/vs2019/xennet/xennet.vcxproj 
> b/vs2019/xennet/xennet.vcxproj index d79a691..1ad5601 100644
> --- a/vs2019/xennet/xennet.vcxproj
> +++ b/vs2019/xennet/xennet.vcxproj
> @@ -21,7 +21,7 @@
>     </PropertyGroup>
>     <ItemDefinitionGroup>
>       <ClCompile>
> -      
> <PreprocessorDefinitions>PROJECT=$(ProjectName);NDIS_MINIPORT_DRIVER;NDIS_WDM=1;NDIS61_MINIPORT=1;POOL_NX_OPTIN=1;NT_PROCESSOR_GROUPS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
> +      
> + <PreprocessorDefinitions>PROJECT=$(ProjectName);NDIS_MINIPORT_DRIVER
> + ;NDIS_WDM=1;NDIS630_MINIPORT=1;POOL_NX_OPTIN=1;NT_PROCESSOR_GROUPS;%
> + (PreprocessorDefinitions)</PreprocessorDefinitions>
>         <IntrinsicFunctions>true</IntrinsicFunctions>
>         
> <AdditionalIncludeDirectories>$(WindowsSdkDir)\include\km;..\..\include;..\..\include\xen;</AdditionalIncludeDirectories>
>         <WarningLevel>EnableAllWarnings</WarningLevel>
> 



 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.