Presentation is loading. Please wait.

Presentation is loading. Please wait.

NDIS vNext - NetAdapter

Similar presentations


Presentation on theme: "NDIS vNext - NetAdapter"— Presentation transcript:

1 NDIS vNext - NetAdapter
WinHEC 2015 9/12/2018 1:43 AM NDIS vNext - NetAdapter Don Stanwyck Sr PM, Windows Core Networking © 2015 Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

2 Agenda What, why and how of NetAdapter The architecture
Real world results What’s in it for you

3 Microsoft Build 2017 9/12/2018 1:43 AM What is NetAdapter? NetAdapter is a WDF class extension that makes it easy to write a driver for your network card or USB Ethernet dongle NetAdapter joins the productivity of WDF with the networking and performance of NDIS Try our API preview in the Windows 10 Creators Update © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

4 Why build NetAdapter? Popular demand
Microsoft Build 2017 9/12/2018 1:43 AM Why build NetAdapter? Popular demand “I want to leverage WDF, and I'm not exactly clear how mixing the NdisMRegisterDevice within a KMDF driver will work.” “I have a USB driver for a special Ethernet USB hardware based on KMDF. Now I want to use the USB driver as a classical windows network device also and implement NDIS (with KMDF).“ “[NDIS has] no books, no seminars that I'm aware of.” © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

5 Microsoft Build 2017 9/12/2018 1:43 AM Why build NetAdapter? Avoid resources spent in troubleshooting pnp/power bugs Let WDF deal with PnP and Power complexity Avoid late breaking bugs in PnP/power path, e.g. system hibernate/suspend Avoid resources on abstracting other OS-specific complexities Spend resources on domain-specific complexity instead If a simple abstraction is available in WDF, why redo it? Example: new Power framework, USB selective suspend, DMA ... New OS features available easily – PoFx , DMA, FL/PL reset etc. Flexibility to move the same model to user mode in future WDF provides a mode-agnostic model for most features © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

6 Why build NetAdapter? Reduce port driver development/maintenance cost
Microsoft Build 2017 9/12/2018 1:43 AM Why build NetAdapter? Reduce port driver development/maintenance cost Popular demand WDF manages the complexity WDF has more features Scale for the cloud 100G NICs with 1000’s of queues Cloud hosting uses NICs in new ways Improved reliability 9F and 133 bugcheck resiliency No more lost NET_BUFFER_LISTs © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

7 How we design NetAdapter
Microsoft Build 2017 9/12/2018 1:43 AM How we design NetAdapter Right should be easy; wrong should be hard. Stay consistent with WDF. Build a fast, reliable, close-to-the-metal datapath. Be 100% compatible with the network stack, usermode apps, existing NDIS APIs, and the universal driver model. © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

8 Help 3rd parties improve driver quality and reduce development time
Microsoft Build 2017 9/12/2018 1:43 AM Help 3rd parties improve driver quality and reduce development time Simpler model for driver development Rich and familiar set of abstractions across device silos WDF familiarity leads to shorter development time and better quality E.g. Industry has strong WDF-skilled developer pool 100s of WDF drivers on SoC platforms Developer resources can be easily reassigned Same user and kernel driver model Rich debugging and verification support Shorter time to production 3rd parties are not constrained by silo-specific model limitations Side-band communication, Bus enumeration, Idle power management, … © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

9 Traditional NDIS Miniport Model
Microsoft Build 2017 9/12/2018 1:43 AM Kernel Protocol PnP Power Data OIDs Traditional NDIS Miniport Model NDIS Your NIC Driver Your hardware © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

10 The NetAdapter Class Extension
Microsoft Build 2017 9/12/2018 1:43 AM Kernel Protocol Data OIDs PnP Power WDF NDIS The NetAdapter Class Extension Your NIC Driver Net- Adapter Data OIDs WDF Your hardware © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

11 Does it network? Microsoft Build 2017 9/12/2018 1:43 AM
© Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

12 Case Study: Realtek PCIe GBE Family Controller
Microsoft Build 2017 9/12/2018 1:43 AM Case Study: Realtek PCIe GBE Family Controller Microsoft and Realtek collaborated to port their existing NDIS 6.40 miniport driver to use NetAdapter. Realtek RTL8111D/RTL8168D chipset 1Gbps Ethernet Typical PCIe: interrupt-driven with bus-mastering DMA Checksum offload Wake-on-LAN © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

13 Case Study: Realtek PCIe GBE Family Controller
Microsoft Build 2017 9/12/2018 1:43 AM Case Study: Realtek PCIe GBE Family Controller Half the lines of code when using NetAdapter class extension. The Tx and Rx handlers have zero spinlocks. No refcounts, no linked lists, no async code, no klunky pause The transmit path can bypass DMA when allowed © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

14 Case Study: USB network adapter
Microsoft Build 2017 9/12/2018 1:43 AM Case Study: USB network adapter We started with an existing NDIS miniport driver, which used WDF in miniport mode USB 2.0 chipset 100Mbps Ethernet Typical USB: bulk-in, bulk-out, and interrupt pipes USB selective suspend, AOAC Wake-on-LAN, PM protocol offloads © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

15 Case Study: USB network adapter
Microsoft Build 2017 9/12/2018 1:43 AM Case Study: USB network adapter Only 400 lines of code for a complete datapath: both Tx and Rx. “Power managed” data path spinlocks, interlocks, DPCs, workitems, timers, context, or memory allocations { } No on the datapath © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

16 How does this affect you?
Microsoft Build 2017 9/12/2018 1:43 AM How does this affect you? © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

17 What’s not changing today
Microsoft Build 2017 9/12/2018 1:43 AM What’s not changing today NDIS is not going away. NDIS will still get new features in the future. You can still build, certify, and ship NDIS drivers. NDISTest still verifies your driver does networking well. Protocol drivers and LWFs interoperate with NetAdapter-based NIC drivers, same as NDIS miniports. NDIS protocol & LWF drivers are not changing. © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

18 Microsoft Build 2017 9/12/2018 1:43 AM The Adoption Plan It’s crucial that NetAdapter get feedback from IHVs early on. Therefore, we follow an open source/open development model All IHVs are encouraged to Follow our development on GitHub Experiment with the latest NetAdapter drop with their hardware Open issues and provide feedback to MS Close collaboration with a few selected IHVs A long road ahead of us NDIS 6 and NetAdapter will co-exist for the foreseeable future Server Class Ethernet NIC, WLAN, MBB and UMDF support are coming later as NetAdapter matures © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

19 NetAdapter on Native Stack – where we are
Microsoft Build 2017 9/12/2018 1:43 AM NetAdapter on Native Stack – where we are Applications WinHttp/WinInet TCPIP & filters NDIS WiFi Driver MBB Ethernet NetAdapter - Realtek Appear as NetAdapter/NDIS Translator NBL data path PD data path New data path In production In Prototype Unmodified © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

20 NetAdapter – what we still need to do
The current sample and source are not API stable The current sample and class definition are not performance tuned Features like RSS, VMQ, LSO, RSC, etc. have yet to be implemented Expansion to multiple queues is an ongoing development item Buffer management needs to be developed And lots more. We have a long way to go …

21 NetAdapter – what we still need to do
… and we need YOUR HELP What we ask from you Review the sample Review the source code on github Tell us how to improve this Tell us how we could light up special capabilities of your NIC

22 Your next driver will use NetAdapter
Microsoft Build 2017 9/12/2018 1:43 AM Your next driver will use NetAdapter WDF is productive & feature-rich NetAdapter is built for speed It’s all based on your feedback © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

23 Where to get more information?

24 What you’ll see at https://aka.ms/NetAdapter
4 videos giving details of NetAdapter Information about what we do (and don’t) have at this stage of development The documentation: Driver samples on GitHub: The source code for NetAdapter itself:

25 Where to get more information?
Questions?

26 9/12/2018 1:43 AM © 2014 Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.


Download ppt "NDIS vNext - NetAdapter"

Similar presentations


Ads by Google