Skip to content

Commit

Permalink
NetKVM: Some cosmetic changes
Browse files Browse the repository at this point in the history
This mainly removes unneeded whitespaces.

Signed-off-by: Leonid Bloch <lbloch@redhat.com>
  • Loading branch information
Leonid Bloch authored and vrozenfe committed Jun 15, 2016
1 parent 911bad6 commit 7544814
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 11 deletions.
10 changes: 5 additions & 5 deletions NetKVM/Common/ParaNdis-Common.cpp
Expand Up @@ -1542,7 +1542,7 @@ static BOOLEAN ProcessReceiveQueue(PARANDIS_ADAPTER *pContext,
PNET_BUFFER_LIST *indicateTail,
ULONG *nIndicate)
{

pRxNetDescriptor pBufferDescriptor;

if(NdisInterlockedIncrement(&pTargetReceiveQueue->ActiveProcessorsCount) == 1)
Expand Down Expand Up @@ -1594,16 +1594,16 @@ static BOOLEAN ProcessReceiveQueue(PARANDIS_ADAPTER *pContext,
}


/* DPC throttling implementation.
/* DPC throttling implementation.
The main loop of the function RxDPCWorkBody finishes under light traffic
when there are no more packets in the virtqueue receive queue. Under the
heavy traffic, the situation is more complicated: the ready-to process packets
are fetched from the virtqueue's receive queue, indicated toward the OS upper
layer in the ProcessReceiveQueue and, depending on the relative speed of
a virtual NIC and guest OS, may be returned by the upper layer to the driver
a virtual NIC and guest OS, may be returned by the upper layer to the driver
with ParaNdis6_ReturnNetBufferLists and reinserted into the virtqueue for
reading.
reading.
Under these conditions, the RxDPCWorkBody's loop terminates because
ProcessReceiveQueue is limited by the nPacketsToIndicate parameter, accepting
Expand Down Expand Up @@ -2097,7 +2097,7 @@ VOID ParaNdis_PowerOff(PARANDIS_ADAPTER *pContext)
pContext->bConnected = FALSE;

ParaNdis_RemoveDriverOKStatus(pContext);

#if !NDIS_SUPPORT_NDIS620
// WLK tests for Windows 2008 require media disconnect indication
// on power off. HCK tests for newer versions require media state unknown
Expand Down
5 changes: 2 additions & 3 deletions NetKVM/Common/sw-offload.cpp
Expand Up @@ -366,7 +366,7 @@ static __inline USHORT GetXxpHeaderAndPayloadLen(IPHeader *pIpHeader, tTcpIpPack
{
USHORT headerLength = IP_HEADER_LENGTH(&pIpHeader->v4);
USHORT len = swap_short(pIpHeader->v4.ip_length);
return len - headerLength;
return len - headerLength;
}
if (res.ipStatus == ppresIPV6)
{
Expand Down Expand Up @@ -728,8 +728,7 @@ VOID AnalyzeL3Proto(
}

static
BOOLEAN AnalyzeL2Hdr(
PNET_PACKET_INFO packetInfo)
BOOLEAN AnalyzeL2Hdr(PNET_PACKET_INFO packetInfo)
{
PETH_HEADER dataBuffer = (PETH_HEADER) packetInfo->headersBuffer;

Expand Down
6 changes: 3 additions & 3 deletions NetKVM/DebugTools/Netchecksum/netchecksum.cpp
Expand Up @@ -47,7 +47,7 @@ bool ProcessFile(FILE *f, ULONG flags, ULONG result[4])
ULONG expected;
ULONG pass = 0;
bContinue = true;

if (bContinue)
{
pass++;
Expand Down Expand Up @@ -88,8 +88,8 @@ bool ProcessFile(FILE *f, ULONG flags, ULONG result[4])
DPrintf(0, ("%d pass FAILED: expected %08X, received %08X", pass, expected, res.value));
bContinue = false;
}
}
}

if (bContinue)
{
pass++;
Expand Down

0 comments on commit 7544814

Please sign in to comment.