48{
49 ULONG InterruptPending;
52
54
56
57
58
60 {
62
63 InterruptPending &= ~E1000_IMS_LSC;
65
67
69
72 }
73
74
76 {
81 ULONG RxDescHead, RxDescTail, CurrRxDesc;
82
83
85
88
90 {
94
95
97 {
98
99 break;
100 }
101
102
104
106 {
108 }
109
110
112 {
113 goto NextReceiveDescriptor;
114 }
115
116 if (ReceiveDescriptor->
Length != 0 && ReceiveDescriptor->
Address != 0)
117 {
119
124 (
PCHAR)(EthHeader + 1),
127
129 }
130 else
131 {
133 }
134
135NextReceiveDescriptor:
136
137 ReceiveDescriptor->
Status = 0;
138
139 RxDescTail = CurrRxDesc;
140 }
141
142 if (bGotAny)
143 {
144
146
148
150 }
151 }
152
153
155 {
158
159
161
163 {
165
167 {
169 {
172 TransmitDescriptor->
Status = 0;
173 }
174
177 }
178 else
179 {
180 break;
181 }
182 }
183
184 if (NumPackets)
185 {
188
189 for (
i = 0;
i < NumPackets; ++
i)
190 {
192 }
193 }
194 }
195
196 ASSERT(InterruptPending == 0);
197}
struct _ETH_HEADER * PETH_HEADER
#define NDIS_DbgPrint(_t_, _x_)
VOID NTAPI NICUpdateLinkStatus(IN PE1000_ADAPTER Adapter)
struct _E1000_ADAPTER * PE1000_ADAPTER
FORCEINLINE VOID E1000ReadUlong(_In_ PE1000_ADAPTER Adapter, _In_ ULONG Address, _Out_ PULONG Value)
FORCEINLINE VOID E1000WriteUlong(_In_ PE1000_ADAPTER Adapter, _In_ ULONG Address, _In_ ULONG Value)
#define E1000_RDESC_STATUS_PIF
#define E1000_RDESC_STATUS_IXSM
#define E1000_RDESC_STATUS_DD
#define E1000_IMS_TXD_LOW
#define E1000_TDESC_STATUS_DD
#define NUM_RECEIVE_DESCRIPTORS
#define E1000_RDESC_STATUS_EOP
#define NUM_TRANSMIT_DESCRIPTORS
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
long __cdecl _InterlockedExchange(_Interlocked_operand_ long volatile *_Target, long _Value)
#define NDIS_STATUS_MEDIA_CONNECT
#define NdisMEthIndicateReceiveComplete(MiniportAdapterHandle)
#define NdisMIndicateStatusComplete(MiniportAdapterHandle)
#define NdisMEthIndicateReceive(MiniportAdapterHandle, MiniportReceiveContext, HeaderBuffer, HeaderBufferSize, LookaheadBuffer, LookaheadBufferSize, PacketSize)
#define NDIS_STATUS_MEDIA_DISCONNECT
#define NDIS_STATUS_SUCCESS
#define NdisMSendComplete(MiniportAdapterHandle, Packet, Status)
#define NdisMIndicateStatus(MiniportAdapterHandle, GeneralStatus, StatusBuffer, StatusBufferSize)
@ NdisMediaStateConnected
PE1000_RECEIVE_DESCRIPTOR ReceiveDescriptors
ULONG ReceiveBufferEntrySize
PE1000_TRANSMIT_DESCRIPTOR TransmitDescriptors
PNDIS_PACKET TransmitPackets[NUM_TRANSMIT_DESCRIPTORS]
NDIS_HANDLE AdapterHandle
_Interlocked_ volatile LONG InterruptPending
volatile PUCHAR ReceiveBuffer