Author: cgutman
Date: Tue Aug 9 06:36:10 2011
New Revision: 53148
URL:
http://svn.reactos.org/svn/reactos?rev=53148&view=rev
Log:
[PCNET]
- Allocate receive and transmit buffers (each 49152 bytes) as cached shared memory to
increase the likelihood of a successful allocation in a low memory scenario
See issue #6284 for more details.
Modified:
trunk/reactos/drivers/network/dd/pcnet/pcnet.c
Modified: trunk/reactos/drivers/network/dd/pcnet/pcnet.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/network/dd/pcnet/p…
==============================================================================
--- trunk/reactos/drivers/network/dd/pcnet/pcnet.c [iso-8859-1] (original)
+++ trunk/reactos/drivers/network/dd/pcnet/pcnet.c [iso-8859-1] Tue Aug 9 06:36:10 2011
@@ -373,7 +373,7 @@
/* allocate transmit buffers */
Adapter->TransmitBufferLength = BUFFER_SIZE * NUMBER_OF_BUFFERS;
NdisMAllocateSharedMemory(Adapter->MiniportAdapterHandle,
Adapter->TransmitBufferLength,
- FALSE, (PVOID *)&Adapter->TransmitBufferPtrVirt, &PhysicalAddress);
+ TRUE, (PVOID *)&Adapter->TransmitBufferPtrVirt, &PhysicalAddress);
if(!Adapter->TransmitBufferPtrVirt)
{
DPRINT1("insufficient resources\n");
@@ -392,7 +392,7 @@
/* allocate receive buffers */
Adapter->ReceiveBufferLength = BUFFER_SIZE * NUMBER_OF_BUFFERS;
NdisMAllocateSharedMemory(Adapter->MiniportAdapterHandle,
Adapter->ReceiveBufferLength,
- FALSE, (PVOID *)&Adapter->ReceiveBufferPtrVirt, &PhysicalAddress);
+ TRUE, (PVOID *)&Adapter->ReceiveBufferPtrVirt, &PhysicalAddress);
if(!Adapter->ReceiveBufferPtrVirt)
{
DPRINT1("insufficient resources\n");