Another NDIS question about the NDIS Packet descriptor

In my IM NDIS driver, when I get a NDIS_Packet sending
to the ethernet NIC from NDIS, I found the first
buffer descriptor always contain the ethernet header
and second buffer descriptor contain the IP header or
IP header plus some data sometimes.
Can I assumu these are always true? If not, how are
the buffers in the NDIS packet constructed?

Thanks!
William

Generally, you can’t assume anything. There can be another IM driver layered above yours which can use buffers any way. Your driver should handle correctly even pathological case when there is one buffer per every byte.

Best regards,

Michal Vodicka
UPEK, Inc.
[xxxxx@upek.com, http:://www.upek.com]


From: xxxxx@lists.osr.com[SMTP:xxxxx@lists.osr.com] on behalf of William Zhang[SMTP:xxxxx@sbcglobal.net]
Reply To: Windows System Software Devs Interest List
Sent: Thursday, April 08, 2004 1:03 AM
To: Windows System Software Devs Interest List
Subject: [ntdev] Another NDIS question about the NDIS Packet descriptor

In my IM NDIS driver, when I get a NDIS_Packet sending
to the ethernet NIC from NDIS, I found the first
buffer descriptor always contain the ethernet header
and second buffer descriptor contain the IP header or
IP header plus some data sometimes.
Can I assumu these are always true? If not, how are
the buffers in the NDIS packet constructed?

Thanks!
William


Questions? First check the Kernel Driver FAQ at http://www.osronline.com/article.cfm?id=256

You are currently subscribed to ntdev as: xxxxx@upek.com
To unsubscribe send a blank email to xxxxx@lists.osr.com

See the “NDIS_PACKET” discussion at NDIS.COM:

http://www.ndis.com/papers/default.htm

Good luck,

Thomas F. Divine
http://www.rawehter.net

“William Zhang” wrote in message news:xxxxx@ntdev…
> In my IM NDIS driver, when I get a NDIS_Packet sending
> to the ethernet NIC from NDIS, I found the first
> buffer descriptor always contain the ethernet header
> and second buffer descriptor contain the IP header or
> IP header plus some data sometimes.
> Can I assumu these are always true? If not, how are
> the buffers in the NDIS packet constructed?
>
> Thanks!
> William
>