-use ExAllocatePoolWithTag instead of ExAllocatePool

-IoMapTransfer should not called without an AdapterObject

svn path=/trunk/; revision=27472
This commit is contained in:
Christoph von Wittich 2007-07-08 13:24:53 +00:00
parent 540155a12a
commit 7a7bdde4ec

View file

@ -698,7 +698,7 @@ SpiAllocateCommonBuffer(PSCSI_PORT_DEVICE_EXTENSION DeviceExtension, ULONG NonCa
if (!DeviceExtension->AdapterObject)
{
/* From nonpaged pool if there is no DMA */
CommonBuffer = ExAllocatePool(NonPagedPool, CommonBufferLength);
CommonBuffer = ExAllocatePoolWithTag(NonPagedPool, CommonBufferLength, TAG_SCSIPORT);
}
else
{
@ -3058,8 +3058,8 @@ SpiAdapterControl(PDEVICE_OBJECT DeviceObject,
either from NonPagedPool, or from our static list */
if (SrbInfo->NumberOfMapRegisters > MAX_SG_LIST)
{
SrbInfo->ScatterGather = ExAllocatePool(
NonPagedPool, SrbInfo->NumberOfMapRegisters * sizeof(SCSI_SG_ADDRESS));
SrbInfo->ScatterGather = ExAllocatePoolWithTag(
NonPagedPool, SrbInfo->NumberOfMapRegisters * sizeof(SCSI_SG_ADDRESS), TAG_SCSIPORT);
if (SrbInfo->ScatterGather == NULL)
ASSERT(FALSE);
@ -3088,7 +3088,7 @@ SpiAdapterControl(PDEVICE_OBJECT DeviceObject,
while (TotalLength < Srb->DataTransferLength)
{
ScatterGatherList->Length = Srb->DataTransferLength - TotalLength;
ScatterGatherList->PhysicalAddress = IoMapTransfer(NULL,
ScatterGatherList->PhysicalAddress = IoMapTransfer(DeviceExtension->AdapterObject,
Irp->MdlAddress,
MapRegisterBase,
DataVA + TotalLength,