As you’ve written, deserialized NDIS drivers aren’t documented for NT and
there can be some differences. I wrote my driver several years before when
the only documentation for deserialized drivers was ImSamp code and short
document attached. So I used the same method as for serialized drivers i.e.
examine packet status after NdisMIndicateReceive() return and when isn’t
pending, regain ownership of the packet. When pending, let it be until
MiniportReceivePacket() is called. We did many stress tests with this driver
and never encountered a problem. Also, I’ve never received a report about a
crash caused by this driver from customers. Well, this means virtually
nothing about correctness of this method. I wasn’t aware about any problem
there until read w2k DDK docs. Yes, there are race conditions if
MiniportReturnPacket() is called before NdisMIndicateReceive() returns and
frees packet. Examining status would touch non-existent packet and this is
probably the reason why we must not touch it. However, this project was
already closed and I decided to not change it until real problem occurs
(don’t fix what is working…).
There is probably a difference between NT4 and w2k NDIS implementation and
the first one doesn’t depend on Status field on input. I only guess, correct
answer could give you somebody from m$ or somebody who disassembled this
part of NDIS. This is what I recommend you: disassemble NDIS or trace
through NdisMIndicateReceive() function to see how the packet status is
processed (a memory breakpoint on Status field should be enough). Or maybe
anybody else has experience with it and give us better method.
BTW, I’ve found that only one of MiniportReturnPacket() and
MiniportTransferData() can be set in NT4 IM driver. NDIS makes some
assumptions based on these values and setting both handlers causes problems.
It implies that driver can use only one method for packet indication (which
is normally sufficient).
Best regards,
Michal Vodicka
Veridicom
(RKK - Skytale)
[WWW: http://www.veridicom.com , http://www.skytale.com]
From: Ramit Bhalla[SMTP:xxxxx@wipro.com]
Sent: Tuesday, February 27, 2001 9:56 AM
To: NT Developers Interest List
Subject: NT Deserial driver and MiniportReturnPacketHi,
I’m developing a NT Deserial driver.
I’m using a version of ndis.h and ndis.lib that was given to me by someone
at microsoft. I’m also using sp6.The problem is no matter what i try the MiniportReturnPacket function is
not being called by NDIS.
I’m going by the documentation of Win2K since there is no documentation
for NT and deserial support.I have tried setting the packet status to everything and nothing seems to
work. No matter what I try it doesn’t call my miniportreturnpacket
function.
The only way i’ve found around this is setting the packet status to
RESOURCES, but this hits the performance drastically.The same driver is also adapter to run as a serial driver that is when the
DESERIAL flag is not set. Then it function fine and the
minportreturnpacket is called, as soon as I specify the DESERIAL flag, it
stops calling the miniportreturn packet.This driver has a common source code for NDIS 4 and NDIS 5, that is it
also runs on win2K and it runs absolutely perfectly and the
miniportreturnpacket function is called.
I’m only facing this problem on WINNT.Has anyone seen this problem and I’ll appreciate any help/clue to this
problem.
Does anyone know about any documentation related to this???Thanks
Ramit.
You are currently subscribed to ntdev as: $subst(‘Recip.EmailAddr’)
To unsubscribe send a blank email to leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com