Re: MmGetSystemAddressForMdlSafe(...)

Hi Peter,

I have the same problem with MmGetSystemAddressForMdlSafe when it fails during a critical operation.

I looked at these reserve functions you suggested to use (MmAllocateMappingAddress, MmFreeMappingAddress,
MmMapLockedPagesWithReservedMapping).
But they seem to be available only beginning from Win XP.
So I can’t use them in Win 2000.

Is it possible to implement such a reservation engine in a driver for Win 2000 ?

Or maybe there is another way to reserve some PTEs and use them in low PTE conditions?

Thank you in advance.

Best regards,
Valeriy Glushkov

----- Original Message -----
From: “Peter Wieland”
To: “Windows System Software Devs Interest List”
Sent: Saturday, December 20, 2003 3:10 AM
Subject: [ntdev] RE: Monolithic SCSI port and MmGetSystemAddressForMdlSafe(…)

look-up reserve mappings in the DDK. Basically you can get MM to put
aside a KVA range for you and then use it to map transfers in as
necessary. Scsiport sets up one of these (of the maximum transfer size)
during initialization to use in the case where
MmGetSystemAddressForMdlSafe fails.

you have to do some work to ensure that you’re only trying to map one
MDL into the reserved range at a time (basically queueing requests until
the reserve is available if you need it) but it’s not that hard.

-p