ReactOS Network Infrastructure

News

20 Nov 03 Casper gave me
this link for an AMD PCNet driver, which should work in VMWare. Meanwhile, I'm continuinng to work on tcpip.sys. More news as it is available.

Old news

Overview

While most of the network infrastructure components have had at least some work done on them (and some have been considerably developed), much work remains. This page is an attempt to get myself and anyone else who wants to work on network-related ReactOS code organized. To that end, please send mail to ros-kernel@reactos.com or to me directly if you want to work on something non-trivial mentioned here so work doesn't get duplicated.

The current status of the ReactOS network stack is as follows:
- The ISA NE2000 driver basically works. This is the card emulated by Bochs
- The PCI PCNet driver works. This is the card emulated by VMWare
- We are able to ping a ReactOS host across a network wire

Here is a list of some important network stack milestones in the order in which I think we'll hit them.

Ndis.sys

Goal: provide a full NDIS5.1 wrapper with full device detection support, full wan miniport support, connection-oritented NDIS support, WDM Miniport support, Intermediate driver support, and a modern binding engine and registry layout, and native support for windows 2k/xp/2k3 installer support.

A secondary goal is binary compatibility with Windows (probably 2000), such that individual binaries (afd.sys, tcpip.sys, even perhaps ndis.sys) can be replaced with Windows 2000 binaries. This implies a very complete level of compatibility between the two systems, which I believe will be necessary for success with 3rd party miniport and protocol drivers.

Latest NDIS patch: nothing outstanding

Projects: These projects are in very loose priority order. There are some dependancies that force an order as well. Let me know if there are comments/suggestions.

There is lots of basic code cleanup that needs doing as well. We need to convert to ExAllocatePoolWithTag() and start doing pool tracking to check for leaks. It would be nice to do some linting and make use of Royce's red-zone detection code as well. Anyone who wants to do basic code scrubbing is welcome to help. Contact me if you need to know where to get a lint program.

------------------------------------
|Unimplemented API list (125 total)|
------------------------------------

Many of these unimplemented APIs are 
  a) critical to the operation of the average miniport, and
  b) really easy to implement (i.e. pass-through to other NTOS functions)

If you're looking for something quick to do, try to find an API or two that
aren't implemented and that correspond closely to other apis (KeSomething,
ExSomething, ZwSomething, etc), and code them up.  

I'm aiming for absolute strict DDK conformance in the API, so be sure to
completely understand the appropriate DDK documentation before coding.

General NDIS API
----------------
 - NdisAcquireReadWriteLock
 - NdisReleaseReadWriteLock
    -> These functions handle two-way locks - reading is cheap; writing locks a spinlock

 - NdisMRegisterDmaChannel
 - NdisMDeregisterDmaChannel
 - NdisMSetupDmaTransfer
 - NdisMCompleteDmaTransfer
 - NdisMReadDmaCounter
 - NdisMInitializeScatterGatherDMA*
 - NdisMAllocateSharedMemoryAsync
 - NdisMUpdateSharedMemory
 - NdisGetCacheFillSize
    -> These functions handle DMA operations with the cards

 - NdisCopyBuffer
 - NdisFlushBuffer
 - NdisCreateLookaheadBufferFromSharedMemory
 - NdisDestroyLookaheadBufferFromSharedMemory
 - NdisQueryBufferSafe*
 - NdisBufferVirtualAddress
 - NdisGetBufferPhysicalArraySize
    -> These functions handle packet buffer operations

 - NdisAllocatePacketPoolEx
 - NdisDprAllocatePacket
 - NdisDprFreePacket
 - NdisDprAllocatePacketNonInterlocked
 - NdisDprFreePacketNonInterlocked
 - NdisPacketPoolUsage
    -> Packet pool operations

 - NdisMoveFromMappedMemory
 - NdisMoveToMappedMemory
 - NdisImmediateWriteSharedMemory
    -> Mapped memory access functions

 - NdisCompleteBindAdapter
 - NdisCompleteUnbindAdapter
    -> binding support functions

 - NdisMapFile 
 - NdisUnmapFile 
    -> File operation functions

 - NdisMCreateLog
 - NdisMWriteLogData
 - NdisMFlushLog
 - NdisMCloseLog
 - NdisWriteEventLogEntry
    -> logging facilities

 - NdisMIndicateStatus
 - NdisMIndicateStatusComplete
    -> miniport status (link up/down, etc)

 - NdisGetCurrentProcessorCpuUsage
 - NdisGetCurrentProcessorCounts
 - NdisSystemProcessorCount
 - NdisGetSystemUptime
    -> Processor information

 - NdisReturnPackets
 - NdisGetReceivedPacket
 - NdisQueryAdapterInstanceName
 - NdisSetProtocolFilter
 - NdisGetDriverHandle
 - NdisCompletePnPEvent
    -> Other protocol support functions

 - NdisMSynchronizeWithInterrupt
 - NdisMQueryAdapterResources (stubbed pending PnP, awaiting patch)
 - NdisMQueryAdapterInstanceName
 - NdisMGetDeviceProperty
 - NdisMRegisterDevice
 - NdisMDeregisterDevice
 - NdisMRegisterUnloadHandler
    -> Other miniport support functions

 - NdisRegisterTdiCallback
    -> Other NDIS support functions

LBFO support
------------
 - NdisMPromoteMiniport
 - NdisMSetMiniportSecondary
 - NdisMRemoveMiniport

PCMCIA support
--------------
 - NdisReadPcmciaAttributeMemory
 - NdisWritePcmciaAttributeMemory

EISA support
------------
 - NdisReadEisaSlotInformation
 - NdisReadEisaSlotInformationEx

NDIS3 support
-------------
 - NdisCompleteDmaTransfer
 - NdisCompleteQueryStatistics
 - NdisUpdateSharedMemory

NDISWAN support
---------------
 - NdisMWanIndicateReceive
 - NdisMWanIndicateReceiveComplete

NDIS Intermediate Driver API
----------------------------
 - NdisIMAssociateMiniport
 - NdisIMCancelInitializeDeviceInstance
 - NdisIMCopySendCompletePerPacketInfo
 - NdisIMCopySendPerPacketIfno
 - NdisIMDeregisterLayeredMiniport
 - NdisIMGetBindingContext
 - NdisIMGetDeviceContext
 - NdisIMInitializeDeviceInstanceEx
 - NdisIMDeinitializeDeviceInstance
 - NdisIMInitializeDeviceInstance
 - NdisIMRegisterLayeredMiniport

Connection-Oriented NDIS API
----------------------------
 - NdisClAddParty
 - NdisClDropParty
 - NdisClOpenAddressFamily
 - NdisClCloseAddressFamily
 - NdisClMakeCall
 - NdisClCloseCall
 - NdisClIncomingCallComplete
 - NdisClRegisterSap
 - NdisClDeregisterSap
 - NdisClModifyCallQos
 - NdisCoCreateVc
 - NdisCoDeleteVc
 - NdisCoRequest
 - NdisCoRequestComplete
 - NdisCoSendPackets
 - NdisMCoActivateVcComplete
 - NdisMCoDeactivateVcComplete
 - NdisMCoIndicateReceivePacket
 - NdisMCoIndicateStatus
 - NdisMCoReceiveComplete
 - NdisMCoRequestComplete
 - NdisMCoSendComplete
 - NdisCmActivateVc
 - NdisCmAddPartyComplete
 - NdisCmCloseAddressFamilyComplete
 - NdisCmCloseCallComplete
 - NdisCmDeactiveateVc
 - NdisCmDeregisterSapComplete
 - NdisCmDispatchCallConnected
 - NdisCmDispatchIncomingCall
 - NdisCmDispatchIncomingCallQosChange
 - NdisCmDispatchIncomingCloseCall
 - NdisCmDispatchIncomingDropParty
 - NdisCmDropPartyComplete
 - NdisCmMakeCallComplete
 - NdisCmModifyCallQosComplete
 - NdisCmOpenAddressFamilyComplete
 - NdisCmRegisterAddressFAmily
 - NdisCmRegisterSapComplete
 - NdisMCmActivateVc
 - NdisMCmCreateVc
 - NdisMCmDeactivateVc
 - NdisMCmDeleteVc
 - NdisMCmRegisterAddressFamily
 - NdisMCmRequest
 - NdisConvertStringToAtmAddress
 

Drivers

ReactOS currently supports the following network card drivers:

The following drivers are currently under construction:

The following drivers are in need of work. Please let me know if you would like to add a card to this list; this just represents the list of NICs at my house.

Documentation

A slightly broken but mostly useful
NT network config description that I found on the 'net

Links

These are links to other useful ReactOS-related websites.
Please mail me at vizzini@plasmic.com with questions or comments. The only exception to this rule is that I don't want to hear about my crappy html. That's why I do kernel coding.

My public key is here for reference.

-----BEGIN PGP PUBLIC KEY BLOCK-----
Version: GnuPG v1.2.3 (GNU/Linux)

mIsEPw3HWAEEANbEAVx5bXFRE5AO4JOT1Swul2bqot1AbsLatm1d4ZEUOD/9U7nO
ccI2p1dLEIMhVirPecpuIUJG0PBxUWWhr2kApCuml3vDo2d/5Mp4uLa6MsMjJXLK
92FHLMORo5PEf8LbUs+zrGxKbRIGKjEWDU6TnArnVmUtx3unVJtII+oPAAYptB1W
aXp6aW5pIDx2aXp6aW5pQHBsYXNtaWMuY29tPoiyBBMBAgAcBQI/DcdYAhsDBAsH
AwIDFQIDAxYCAQIeAQIXgAAKCRDnrh2a9eo6YQJMBADSjuAt1y31/GZEHpSZRpUA
t5bmOnrg+nnJYYgNq0nzl+pU4R9bRS8fIGSgAwdey4whtbngCEls3vUuY2su5fCv
288rIOtJArgpvPBaGhs+DzI6YktzkDurgBgC7uYju3cSMQ1nbekWMMMLlOvE7r3x
v1F3XKxH5glKN4C/RmOxng==
=Yce9
-----END PGP PUBLIC KEY BLOCK-----