MmFreeContiguousMemory 함수(wdm.h)

MmFreeContiguousMemory 루틴은 MmAllocateContiguousMemoryXxx 루틴에 의해 할당된 물리적으로 연속된 메모리 범위를 해제합니다.

구문

void MmFreeContiguousMemory(
  [in] PVOID BaseAddress
);

매개 변수

[in] BaseAddress

해제할 메모리의 가상 주소에 대한 포인터입니다.

반환 값

없음

설명

MmFreeContiguousMemory 루틴은 MmAllocateContiguousMemory, MmAllocateContiguousMemorySpecifyCache 또는 MmAllocateContiguousMemorySpecifyCacheNode 루틴에 대한 이전 호출에 의해 할당된 물리적으로 연속 메모리 블록을 해제합니다. BaseAddress 매개 변수는 MmAllocateContiguousMemoryXxx 루틴에 대한 이전 호출에서 가져온 기본 주소여야 합니다.

연속 메모리를 사용해야 하는 디바이스 드라이버는 시스템이 실행될 때 실제 메모리가 조각화될 가능성이 높기 때문에 드라이버 초기화 중에 필요한 것만 할당해야 합니다. 이러한 드라이버는 메모리를 사용하여 드라이버가 완료되면 메모리의 할당을 취소해야 합니다.

MmFreeContiguousMemory의 호출자는 IRQL = APC_LEVEL 실행되어야 합니다. Windows Server 2008 이상 버전의 Windows 운영 체제의 경우 IRQL <= DISPATCH_LEVEL 사용하여 MmFreeContiguousMemory를 호출할 수도 있습니다. 그러나 APC_LEVEL 이하에서 를 호출하여 드라이버 성능을 향상시킬 수 있습니다.

요구 사항

요구 사항
지원되는 최소 클라이언트 Windows 2000부터 사용할 수 있습니다.
대상 플랫폼 유니버설
헤더 wdm.h(Wdm.h, Ntddk.h 포함)
라이브러리 NtosKrnl.lib
DLL NtosKrnl.exe
IRQL 설명 섹션을 참조하십시오.
DDI 규정 준수 규칙 HwStorPortProhibitedDDIs(storport), IrqlMmDispatch(wdm)

추가 정보

MmAllocateContiguousMemory

MmAllocateContiguousMemorySpecifyCache

MmAllocateContiguousMemorySpecifyCacheNode