Windows System Software -- Consulting, Training, Development -- Unique Expertise, Guaranteed Results

Sept/Oct 2019 Issue of The NT Insider available


Download PDF here: http://insider.osr.com/2019/ntinsider_2019_01.pdf

It’s a particularly BIG issue, too: 40 pages of technical goodness, ranging from WDF to Minifilters. Check it out.
Before Posting...
Please check out the Community Guidelines in the Announcements and Administration Category.

Error C2065: Undeclared Identifier "NDIS_HASH_UDP_IPV4" for UDP RSS

ronakdoshironakdoshi Member Posts: 12

Hello,

I am trying to add RSS support for miniport driver. For IP/TCP RSS, the code compiles fine. However, when I add support for udp RSS, the compiler throws following error:
I am using Windows 10.

Error C2065: 'NDIS_HASH_UDP_IPV4' : undeclared Identifier

Below declaration works/compiles fine:
SupportedRssHashTypes = NDIS_HASH_IPV4 |
NDIS_HASH_TCP_IPV4 |
NDIS_HASH_IPV6 |
NDIS_HASH_TCP_IPV6;

Below declaration throws the error for UDP RSS fields:
SupportedRssHashTypes = NDIS_HASH_IPV4 |
NDIS_HASH_TCP_IPV4 |
NDIS_HASH_UDP_IPV4 | <==== UDP RSS
NDIS_HASH_IPV6 |
NDIS_HASH_TCP_IPV6 |
NDIS_HASH_UDP_IPV6; <==== UDP RSS

Same goes for advertising UDP RSS capabilities to the stack. Below declarations also result in same error.
NDIS_RSS_CAPS_HASH_TYPE_UDP_IPV4 |
NDIS_RSS_CAPS_HASH_TYPE_UDP_IPV6;

MSDN documentation states UDP RSS is supported. https://docs.microsoft.com/en-us/windows-hardware/drivers/network/rss-hashing-types
It does not mention that any specific header files need to be included for UDP RSS support.

So, the question is do we need to add any specific header files for UDP RSS declarations? Any documentation pointing to it would be helpful. I thought NDIS_HASH_XX_XX RSS declarations would be in same header. If it works for TCP, should be the same for UDP. But maybe I am wrong.

Any help is appreciated.

Thanks

Comments

  • Tim_RobertsTim_Roberts Member - All Emails Posts: 13,131

    The documentation is wrong. RSS is all about distributing connections, and UDP packets are not part of a connection. Those symbols do not exist.

    Tim Roberts, [email protected]
    Providenza & Boekelheide, Inc.

  • Andy_MoretonAndy_Moreton Member Posts: 9

    The docs are fine, and the symbols do exist. Either the driver is being built with an old WDK, or the project file does not define "NDIS680_MINIPORT=1".
    RSS uses the src/dest IP addresses, and the src/dest TCP/UDP ports to compute a hash, with the low bits of the hash used as the index for the indirection table. UDP works fine if the hardware supports it.

  • Tim_RobertsTim_Roberts Member - All Emails Posts: 13,131
    edited November 11

    Comment withdrawn. The symbols are present.

    Tim Roberts, [email protected]
    Providenza & Boekelheide, Inc.

  • ronakdoshironakdoshi Member Posts: 12

    Thanks Andy for the response.

    The docs are fine, and the symbols do exist. Either the driver is being built with an old WDK, or the project file does not define "NDIS680_MINIPORT=1".

    Can you point me to where it mentions NDIS680 is required for UDP RSS? Maybe that's the issue. That's not defined yet as the docs I pointed did not mentioned anything related to UDP RSS is supported after certain NDIS6 version.

    Thanks

Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Upcoming OSR Seminars
Writing WDF Drivers 21 Oct 2019 OSR Seminar Space & ONLINE
Internals & Software Drivers 18 Nov 2019 Dulles, VA
Kernel Debugging 30 Mar 2020 OSR Seminar Space
Developing Minifilters 27 Apr 2020 OSR Seminar Space & ONLINE