36 *AddressingReset =
FALSE;
56 UINT firstBufferLength, totalBufferLength;
61 ASSERT(sgList->NumberOfElements == 1);
62 ASSERT(sgList->Elements[0].Address.HighPart == 0);
63 ASSERT((sgList->Elements[0].Address.LowPart & 3) == 0);
85 transmitBuffer =
adapter->RuntTxBuffersPa.LowPart +
94 if (firstBufferVa ==
NULL)
101 ASSERT(firstBufferLength == totalBufferLength);
109 transmitLength = sgList->Elements[0].Length;
110 transmitBuffer = sgList->Elements[0].Address.LowPart;
212 UINT resourceListSize;
261 resourceListSize = 0;
295 for (
i = 0;
i < resourceList->
Count;
i++)
469 if (resourceList !=
NULL)
493 characteristics.MajorNdisVersion = NDIS_MINIPORT_MAJOR_VERSION;
494 characteristics.MinorNdisVersion = NDIS_MINIPORT_MINOR_VERSION;
495 characteristics.CheckForHangHandler =
NULL;
496 characteristics.DisableInterruptHandler =
NULL;
497 characteristics.EnableInterruptHandler =
NULL;
503 characteristics.ReconfigureHandler =
NULL;
507 characteristics.TransferDataHandler =
NULL;
508 characteristics.ReturnPacketHandler =
NULL;
509 characteristics.SendPacketsHandler =
NULL;
510 characteristics.AllocateCompleteHandler =
NULL;
static const WCHAR Cleanup[]
DRIVER_INITIALIZE DriverEntry
#define NDIS_DbgPrint(_t_, _x_)
NDIS_STATUS NTAPI NICPowerOn(IN PE1000_ADAPTER Adapter)
NDIS_STATUS NTAPI NICEnableTxRx(IN PE1000_ADAPTER Adapter)
NDIS_STATUS NTAPI NICSoftReset(IN PE1000_ADAPTER Adapter)
NDIS_STATUS NTAPI NICGetPermanentMacAddress(IN PE1000_ADAPTER Adapter, OUT PUCHAR MacAddress)
VOID NTAPI NICUpdateLinkStatus(IN PE1000_ADAPTER Adapter)
NDIS_STATUS NTAPI MiniportSetInformation(IN NDIS_HANDLE MiniportAdapterContext, IN NDIS_OID Oid, IN PVOID InformationBuffer, IN ULONG InformationBufferLength, OUT PULONG BytesRead, OUT PULONG BytesNeeded)
NDIS_STATUS NTAPI MiniportQueryInformation(IN NDIS_HANDLE MiniportAdapterContext, IN NDIS_OID Oid, IN PVOID InformationBuffer, IN ULONG InformationBufferLength, OUT PULONG BytesWritten, OUT PULONG BytesNeeded)
VOID NTAPI MiniportISR(OUT PBOOLEAN InterruptRecognized, OUT PBOOLEAN QueueMiniportHandleInterrupt, IN NDIS_HANDLE MiniportAdapterContext)
VOID NTAPI MiniportHandleInterrupt(IN NDIS_HANDLE MiniportAdapterContext)
static NDIS_STATUS NICTransmitPacket(_In_ PE1000_ADAPTER Adapter, _In_ PHYSICAL_ADDRESS PhysicalAddress, _In_ ULONG Length)
NDIS_STATUS NTAPI NICRemoveReceiveBuffer(IN PRTL_ADAPTER Adapter)
NDIS_STATUS NTAPI NICRegisterReceiveBuffer(IN PRTL_ADAPTER Adapter)
VOID EXPORT NdisMQueryAdapterResources(OUT PNDIS_STATUS Status, IN NDIS_HANDLE WrapperConfigurationContext, OUT PNDIS_RESOURCE_LIST ResourceList, IN OUT PUINT BufferSize)
VOID EXPORT NdisMDeregisterInterrupt(IN PNDIS_MINIPORT_INTERRUPT Interrupt)
VOID EXPORT NdisMDeregisterIoPortRange(IN NDIS_HANDLE MiniportAdapterHandle, IN UINT InitialPort, IN UINT NumberOfPorts, IN PVOID PortOffset)
NDIS_STATUS EXPORT NdisMRegisterIoPortRange(OUT PVOID *PortOffset, IN NDIS_HANDLE MiniportAdapterHandle, IN UINT InitialPort, IN UINT NumberOfPorts)
NDIS_STATUS EXPORT NdisMInitializeScatterGatherDma(IN NDIS_HANDLE MiniportAdapterHandle, IN BOOLEAN Dma64BitAddresses, IN ULONG MaximumPhysicalMapping)
NDIS_STATUS EXPORT NdisMRegisterInterrupt(OUT PNDIS_MINIPORT_INTERRUPT Interrupt, IN NDIS_HANDLE MiniportAdapterHandle, IN UINT InterruptVector, IN UINT InterruptLevel, IN BOOLEAN RequestIsr, IN BOOLEAN SharedInterrupt, IN NDIS_INTERRUPT_MODE InterruptMode)
VOID EXPORT NdisFreeMemory(IN PVOID VirtualAddress, IN UINT Length, IN UINT MemoryFlags)
NDIS_STATUS EXPORT NdisAllocateMemoryWithTag(OUT PVOID *VirtualAddress, IN UINT Length, IN ULONG Tag)
VOID EXPORT NdisMAllocateSharedMemory(IN NDIS_HANDLE MiniportAdapterHandle, IN ULONG Length, IN BOOLEAN Cached, OUT PVOID *VirtualAddress, OUT PNDIS_PHYSICAL_ADDRESS PhysicalAddress)
VOID EXPORT NdisMFreeSharedMemory(IN NDIS_HANDLE MiniportAdapterHandle, IN ULONG Length, IN BOOLEAN Cached, IN PVOID VirtualAddress, IN NDIS_PHYSICAL_ADDRESS PhysicalAddress)
NDIS_STATUS NTAPI MiniportInitialize(OUT PNDIS_STATUS OpenErrorStatus, OUT PUINT SelectedMediumIndex, IN PNDIS_MEDIUM MediumArray, IN UINT MediumArraySize, IN NDIS_HANDLE MiniportAdapterHandle, IN NDIS_HANDLE WrapperConfigurationContext)
VOID NTAPI MiniportHalt(IN NDIS_HANDLE MiniportAdapterContext)
NDIS_STATUS NTAPI MiniportReset(OUT PBOOLEAN AddressingReset, IN NDIS_HANDLE MiniportAdapterContext)
#define MAXIMUM_FRAME_SIZE
#define DEFAULT_INTERRUPT_MASK
NDIS_STATUS NTAPI MiniportSend(_In_ NDIS_HANDLE MiniportAdapterContext, _In_ PNDIS_PACKET Packet, _In_ UINT Flags)
FORCEINLINE VOID NICApplyInterruptMask(_In_ PE1000_ADAPTER Adapter)
#define IEEE_802_ADDR_LENGTH
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
#define CmResourceTypePort
#define CmResourceTypeInterrupt
#define RtlFillMemory(Dest, Length, Fill)
#define NdisReleaseSpinLock(_SpinLock)
_In_ NDIS_HANDLE _In_ PNDIS_PACKET Packet
#define NdisInterruptLatched
#define NDIS_ATTRIBUTE_BUS_MASTER
#define NdisInterruptLevelSensitive
#define NdisAllocateSpinLock(_SpinLock)
#define NDIS_PER_PACKET_INFO_FROM_PACKET(Packet, InfoType)
#define NDIS_STATUS_FAILURE
_Must_inspect_result_ _Out_ PNDIS_STATUS _Out_ PNDIS_STATUS _Out_ PNDIS_HANDLE _Out_ PUINT SelectedMediumIndex
#define NDIS_STATUS_SUCCESS
_Must_inspect_result_ _Out_ PNDIS_STATUS _Out_ PNDIS_STATUS _Out_ PNDIS_HANDLE _Out_ PUINT _In_ UINT MediumArraySize
_Must_inspect_result_ _Out_ PNDIS_STATUS _Out_ PNDIS_HANDLE _In_ NDIS_HANDLE WrapperConfigurationContext
#define NdisGetFirstBufferFromPacketSafe(_Packet, _FirstBuffer, _FirstBufferVA, _FirstBufferLength, _TotalBufferLength, _Priority)
@ ScatterGatherListPacketInfo
_In_ NDIS_HANDLE MiniportAdapterHandle
#define NDIS_STATUS_UNSUPPORTED_MEDIA
_Must_inspect_result_ _Out_ PNDIS_STATUS _Out_ PNDIS_STATUS OpenErrorStatus
#define NdisMInitializeWrapper(NdisWrapperHandle, SystemSpecific1, SystemSpecific2, SystemSpecific3)
#define NdisAcquireSpinLock(_SpinLock)
#define NDIS_STATUS_RESOURCES
#define CM_RESOURCE_INTERRUPT_LATCHED
VOID EXPORT NdisMSetAttributesEx(IN NDIS_HANDLE MiniportAdapterHandle, IN NDIS_HANDLE MiniportAdapterContext, IN UINT CheckForHangTimeInSeconds OPTIONAL, IN ULONG AttributeFlags, IN NDIS_INTERFACE_TYPE AdapterType)
NDIS_STATUS EXPORT NdisMRegisterMiniport(IN NDIS_HANDLE NdisWrapperHandle, IN PNDIS_MINIPORT_CHARACTERISTICS MiniportCharacteristics, IN UINT CharacteristicsLength)
VOID EXPORT NdisTerminateWrapper(IN NDIS_HANDLE NdisWrapperHandle, IN PVOID SystemSpecific)
enum _NDIS_MEDIUM * PNDIS_MEDIUM
#define RESOURCE_LIST_TAG
struct _RTL_ADAPTER * PRTL_ADAPTER
#define MINIMUM_FRAME_SIZE
#define FULL_RECEIVE_BUFFER_SIZE
struct _CM_PARTIAL_RESOURCE_DESCRIPTOR::@391::@393 Port
union _CM_PARTIAL_RESOURCE_DESCRIPTOR::@391 u
struct _CM_PARTIAL_RESOURCE_DESCRIPTOR::@391::@394 Interrupt
CM_PARTIAL_RESOURCE_DESCRIPTOR PartialDescriptors[1]
#define RtlCopyMemory(Destination, Source, Length)
#define RtlZeroMemory(Destination, Length)
_Must_inspect_result_ _In_ PDRIVER_OBJECT _In_ PCUNICODE_STRING RegistryPath
_Must_inspect_result_ _In_ PDRIVER_OBJECT DriverObject
_Must_inspect_result_ _In_ ULONG Flags
struct _SCATTER_GATHER_LIST * PSCATTER_GATHER_LIST