|
|
Why does NdisAllocatePacket fail unexpectedly on Windows 2000?
SymptomsWhen a NDIS protocol driver built under the Windows NT 4.0 DDK is run
on Windows 2000 calls to NdisAllocatePacket will eventually fail unexpectedly
and prematurely. CauseBasically, prior to Windows 2000 Beta 3 RC1 the NdisFreePacket MACRO defined in the
Windows NT
4.0 NDIS.H file was functionally identical to the NdisFreePacket function exported by the
NDIS library. So, NdisAllocatePacket/NdisFreePacket worked correctly for NDIS protocol
drivers, which use the MACRO. Calling the NdisFreePacket MACRO does not actually return the NDIS_PACKET to the free
pool on Windows 2000. As a result, calls to NdisAllocatePacket will eventually fail
prematurely. ResolutionThe most highly recommended solution to this problem is to build drivers intended for the Windows 2000 platform under the Windows 2000 DDK. This approach is required by Microsoft and is used by PCAUSA.
In you must use Windows NT4.0 DDK for your Windows 2000 protocol driver, you
can add this fragment after #include NDIS.H but before any
reference to NdisFreePacket: If you follow the route of using the Windows NT 4.0 DDK for your Windows 2000 NDIS protocol driver, then you will almost certainly encounter other problems similar to this one. Apparently Microsoft has a Knowledge Base article on the same topic. See: NdisFreePacket
Macro Causes NDIS Protocol Drivers to Fail in Windows 2000
It is a shame that one can only find these KB articles after spending time debugging...
Status
CommentsPlease click the following link to send e-mail relating to this PCAUSA Knowledge Base topic:
|
|
PCAUSA Home ·
Privacy Statement ·
Products ·
Ordering ·
Support ·
Utilities ·
Resources
|