Compartilhar via


NDIS Driver Development and Testing

Posted January 29, 2003

Chat Date: January 22, 2003

Chat Participants:

  • Eliyas Yakub, Software Design Engineer
  • Aditya Dube, NDIS Developer
  • Brad Williamson, Software Design Engineer
  • Alireza Dabagh, Software Design Engineer
  • Igor Kostic, Program Manager
  • Sumeet Bawa, Software Design Engineer
  • Jim Mateer, Program Manager

Moderator: Eric S (Microsoft):
Welcome to today's Chat. Our topic is NDIS driver development and testing. We have a great line-up of experts ready to tackle your questions.

Moderator: Eric S (Microsoft):
Let's introduce our experts (aka hosts) for today.

Host: Eliyas (Microsoft):
Hi, My name is Eliyas Yakub. I'm an Software Design Engineer in Core OS Team.

Host: Aditya (Microsoft):
Hi! My name is Aditya Dube. I am an NDIS developer.

Host: Brad W (Microsoft):
Hi, I'm Brad Williamson, Software Design Engineer with the NDIS Team

Host: Alid (Microsoft):
My name is Alireza Dabagh and I work on NDIS.

Host: Igor (Microsoft):
Hi, my name is Igor Kostic and I am the Program Manager for Wireless Devices.

Host Guest_Om_MSFT:
Hi, my name is Om and I am developer for Ndis Test Development team

Host: Sumeet (Microsoft):
Hi! My name is Sumeet Bawa. I am a network configuration developer.

Host: Jim (Microsoft):
Hi, I'm Jim Mateer, the Microsoft Program Manager responsible for NDIS

Moderator: Eric S (Microsoft):
Welcome everyone, let's get started!

Host: Jim (Microsoft):
Q: I recently read articles about RDMA(Remote DAM) and TOE(TCP/IP offload engine). Can someone comment about: 1)If MS is going to support RMDA and TOE in the Windows? 2)If so, how to get/learn about how to develop products for these two?

A: Yes, Microsoft will support TOE and RDMA in the next release of the OS. There will be information about these in the DDK distributed at WinHEC

Host Guest_Om_MSFT:
Q: Are NDIS IM Driver required to pass 2m_addre.tst? If so, not sure how can they do it without Miniport Driver underneath accepting the network address change (i.e getting reloaded)?

A: Send mail to Ndiststr@microsoft.com with details about your IM Driver and we will get back to you.

Host: Brad W (Microsoft):
Q: We are developing App's using VS.NET to communicate with microcontrollers using RS232, but the new generations have onchip USB or Ethernet, what is the better way to develop specific driver for this microcontrollers.

A: Do you wish to expose your device as a network device? If so, you should consider using Remote NDIS.

Host: Alid (Microsoft):
Q: Network Adapter driver, full MAC versus Miniport driver behavior: about flow controlling application sourced outgoing traffic : In a miniport dirver, this can be done using NDIS_STATUS_RESOURCES. In a full mac driver, how should the protocol be

A: Full mac drivers have to queue packets the same way a desterilized miniport does.

Host: Jim (Microsoft):
Q: SAM : Sam:Q:When Mobile IP will be supported in MS TCP/ip?

A: There are plans to support Mobil IP. We don't have the TCPIP folks with us today, so I can't go into detail. More details will be presented at WinHEC

Host: Brad W (Microsoft):
Q: Is your VS.Net/RS232 NDIS 5.0 model based? Where can I find the document on this?

A: RNDIS is for USB devices. Information about RNDIS be found at https://www.microsoft.com/hwdev/resources/hwservices/rndis.asp

Host: Igor (Microsoft):
Q: There are a lot of rumors around Microsoft Soft WiFi for Wireless LAN. What is the status of Soft WiFi?

A: The initial high-level concept of Soft Wi-Fi (also known as Native Wi-Fi) was presented at WinHEC2002. Native Wi-Fi is happening and a lot more details will be disclosed at WinHEC2003.

Host Guest_Soemin_MSFT:
Q: Will the NDIS source be included with CE .NET?

A: Yes for premium customer.

Host: Igor (Microsoft):
Q: Also, How are wireless devices tested for the WHQL logo?

A: NDIS Tester, which is included in the Hardware Compatibility Tests (HCTs), allow you to select a wireless device tests. These have to be passed for a WHQL logo.

Host: Brad W (Microsoft):
Q: are the slides from the winhec2002 for the soft wifi available online?

A: The slides for WinHEC 2002 are located at https://www.microsoft.com/hwdev/futurepc/winhec2002/default.asp

Host: Aditya (Microsoft):
Q: Do any flow charts exist that illustrate the correct action a miniport should take when receiving or transmitting packets?

A: The current DDK does not have this. For the next DDK, after Windows Server 2003, we are adding State machine diagrams to the DDK.

Host: Alid (Microsoft):
Q: MG : There is a OID_GEN_VLAN_ID introduced in NDIS 5.1, Is there any user interface to set this Oid? Also when Upper layer protocols query this Oid , do they use it to tag it?

A: You can use WMI (GUID_NDIS_GEN_VLAN_ID). Setting a VID does not mean that the packets will be tagged with this VID or they will be tagged at all. The rules about what to do with outgoing or incoming packet when NIC supports VLAN are being updated and will be in next DDK.

Host: Alid (Microsoft):
Q: You mean to link all from the protocol received ndis packets in a linked list, no matter how large it grows, and no feedback to the protocol?

A: Yes

Host: Jim (Microsoft):
Q: : There is an NDISUIO sample in the XP DDK, but the interface has already changed for XP SP1. Is there an updated sample and/or header file for NDISUIO?

A: What changed interface are you referring to?

Host: Igor (Microsoft):
Q: Is there special tests for multiple PHYs devices?

A: If referring to wireless (like a/b or a/g) devices the answer is yes. The wireless tests in the HCTs have to be run against two APs, supporting corresponding PHYs (a and g or a and b).

Host: Eliyas (Microsoft):
Q: There is an NDISUIO sample in the XP DDK, but the interface has already changed for XP SP1. Is there an updated sample and/or header file for NDISUIO?

A: Please read this newsgroup posting https://groups.google.com/groups?selm=Y3bmZpdrCHA.2276%40cpmsftngxa09\&output=gplain

Host: Aditya (Microsoft):
Q: what is the future for NDISUIO support? will Native WiFi supercede this driver?

A: We are still evaluating the future of the interactions between NDISUIO and wireless for Windows version codenamed Longhorn

Host Guest_Om_MSFT:
Q: Are there any documents that describe which OID's actually change NDIS behavior vs OID's that are simply for info purposes only?

A: Can you elaborate on this question?

Host: Igor (Microsoft):
Q: Are there any other documents regarding Soft WiFi available online?

A: Not at this time. WinHEC2003 will be the place for disclosing the details on Native Wi-Fi.

Host: Alid (Microsoft):
Q: Sometimes our NDIS miniport driver fails to unload after attempting to disable it from the Network Control Panel. Is this because we have previously indicated NDIS_STATUS_RESOURCES on a send attempt? Our MiniportHalt() is never called

A: No failing the packets can not be the problem. You may have some packets or requests that you did not complete.

Host: Brad W (Microsoft):
Q: When and where the WinHEC2003 will be?

A: information about WinHEC2003 can be found at https://www.microsoft.com/hwdev/events/default.asp

Host: Aditya (Microsoft):
Q: I build a deserialize miniport driver for a gigabit Ethernet adapter base on the source code of 8255x in DDK sample, everything is fine except working in IIS server. When a web page with CGI script being browser

A: Please make sure the miniport passes the NDIS Tester. That is a way we verify our NDIS miniports too.

Host: Jim (Microsoft):
Q: When will NDIS6 arrive?

A: We will have a developer release of NDIS 6 functionality to hand out at WinHEC2003. This will give you sufficient information to begin NDIS 6 driver development. NDIS 6 will be released with future OS releases

Host: Alid (Microsoft):
Q: We don't pend any OID Sets/Requests, but we do pend send requests. So it must be some transmit frame that's not completed back to NDIS?

A: Yes.

Host Guest_Om_MSFT:
Q: How do you tell is a OID value will change the way NDIS works? Example, for an Ethernet miniport, if it reports the speed as 10Mbps vs 100Mbps, does NDIS just ignore this anyway?

A: Windows DDK enumerates all the OIDs with specific information about set/query or both. You can assume that networking stack can change behavior based on OIDs

Host: Eliyas (Microsoft):
Q: I was asked to write an NDIS driver to encrypt and decrypt packets for VPN. the enc/dec are done in the application mode. So I need to get the packets from the kernel mode to the application. Can anyone give a scenario on how to achieve this?

A: NDISUIO sample demonstrates how to send & receive packets from kernel-mode to user mode and vice versa. So please study that.

Host: Alid (Microsoft):
Q: Ok, then how does the protocol know when to stop allocating packets in case the application keeps sending to Winsock (like a UDP sender)? Is there a threshold somewhere?

A: There is no threshold as far as I know. I have seen systems running out of memory because miniport drivers did not complete the sends.

Host: Eliyas (Microsoft):
Q: Were there any changes in the driver verifier from 2K to XP to identify memory leaks? We have seen that even if the driver has memory leaks in shutdown routines, the 2K verifier does not identify them.

A: There are lot of new enhancements to driver verifier in XP. So I recommend testing your driver on XP.

Host: Aditya (Microsoft):
Q: Newbie: is everything that is sent on a network in network byte order?

A: Yes

Host: Igor (Microsoft):
Q: Will WMI OID puts be fixed soon? for WiFi OID's...

A: Please re-post this question on the microsoft.public.development.device.drivers newsgroup. The latest OID definitions can be found on: https://www.microsoft.com/hwdev/tech/network/802x/80211\_netadapt.asp

Host: Eliyas (Microsoft):
Q: Were there any changes in the driver verifier from 2K to XP to identify memory leaks?

A: This page outlines all the enhancement to driver verifier on XP: https://www.microsoft.com/hwdev/driver/verifier.asp.

Host: Aditya (Microsoft):
Q: hen should one call NdisMSendComplete? Should it be when the device actually sends the packet? Should it only be when the packet memory is not needed? Does it matter?

A: The device may send complete the packet without sending it on the wire. Once it SendCompletes the NdisPacket, it can no longer access the NdisPacket or its NdisBuffers.

Host Guest_Soemin_MSFT:
Q: I have had problems with NDIS (under PocketPC 2002) submitting multiple packets to my miniport. I thought the miniport should only have to handle one at a time. What could I be doing wrong? Sometimes I return NDIS_STATUS_FAILURE, SUCCESS or PENDING

A: If the miniport supports SendPacketsHandler() then it may be requested to send multiple packets at a time. Also if the miniport supports SendHandler() and return NDIS_STATUS_PENDING, NDIS may send more packets down even before the first packet gets completed.

Host: Igor (Microsoft):
Q: Is soft wifi defined in ndis6? or is it still be architected?

A: Native Wi-Fi will support NDIS 6.0. The more details will be available at WinHEC 2003.

Host: Alid (Microsoft):
Q: Would you then agree that for full mac drivers, to avoid the NP pool getting low, the linked list for packets received from the protocol in macSend should be limited, and that any overflow should be ignored, returning NDIS_STATUS_SUC

A: No, you should fail the packets and not succeed them and if you get too many packets that you can not handle, you should start failing them (preferably) in your CheckForHang handler.

Host: Igor (Microsoft):
Q: The current MS Zero config scheme supports 802.11(a,b,g) only - Is there plan to extend this support onto other medium?

A: We are looking into supporting other media, but at this time don't have more details.

Host: Alid (Microsoft):
Q: D- : So we should consider NDISUIO an exclusive driver to ZeroWirelessConfig driver and not load it re-entrantly?

A: Yes.

Host: Igor (Microsoft):
Q: Is there any documentation on the WMI classes for accessing 802.11 OIDs? There does not appear to be any in the DDK.

A: Every WMI guid has a corresponding OID. For OID functionality refer to: https://www.microsoft.com/hwdev/tech/network/802x/80211\_netadapt.asp

Host: Alid (Microsoft):
Q: On the question of NDISUIO, are you recommending that we build our own version of NDISUIO from the source and ship with it? This will require WHQL, correct?

A: If the purpose of doing this is to bypass zero-config the answer is that we No, we do not recommend this. And yes this will require WHQL certification.

Host: Igor (Microsoft):
Q: do you have any 802.11 sample drivers available?

A: We are preparing a Native Wi-Fi miniport sample driver. We will disclose it at WinHEC 2003.

Host Guest_Soemin_MSFT:
Q: So if I want NDIS to handle the queuing for me, then I should return NDIS_STATUS_RESOURCES followed by NdisMSendRscAvail() when they are available?

A: Unfortunately no, for serialized driver (which I assume it will be for CE Pocket PC), then the packet that get NDIS_STATUS_RESOURCE will be retried by NDIS.

Moderator: Eric S (Microsoft):
Thanks for joining us today and thanks for the questions. It's time for us to go now.

Moderator: Eric S (Microsoft):
If we didn't get a chance to get to your question please ask in microsoft.public.development.device.drivers newsgroup, or go to the following URL: https://msdn.microsoft.com/newsgroups

Host: Aditya (Microsoft):
Also for CE microsoft.public.windowsce.embedded microsoft.public.windowsce.targetted.device. And for 4.2 release microsoft.beta.mckendric.general

Top of pageTop of page