From d8a8746446849e167202af993f99955d19c12641 Mon Sep 17 00:00:00 2001 From: David Spruill Date: Wed, 24 Jan 2024 17:38:05 -0500 Subject: Replace deprecated ExAllocatePool* APIs with ExAllocatePool2. --- video/KMDOD/memory.cxx | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/video/KMDOD/memory.cxx b/video/KMDOD/memory.cxx index aae795df..5b68c297 100644 --- a/video/KMDOD/memory.cxx +++ b/video/KMDOD/memory.cxx @@ -23,7 +23,10 @@ void* __cdecl operator new(size_t Size, POOL_TYPE PoolType) Size = (Size != 0) ? Size : 1; - void* pObject = ExAllocatePoolWithTag(PoolType, Size, BDDTAG); + // Note that ExAllocatePool2 replaces ExAllocatePool* APIs in OS's starting + // with Windows 10, version 2004. If your driver targets previous versions it + // should use ExAllocatePoolZero instead. + void* pObject = ExAllocatePool2(PoolType, Size, BDDTAG); #if DBG if (pObject != NULL) @@ -44,7 +47,7 @@ void* __cdecl operator new[](size_t Size, POOL_TYPE PoolType) Size = (Size != 0) ? Size : 1; - void* pObject = ExAllocatePoolWithTag(PoolType, Size, BDDTAG); + void* pObject = ExAllocatePool2(PoolType, Size, BDDTAG); #if DBG if (pObject != NULL) -- cgit v1.3.1 From 4699c9735a7077cd991a2b0b666d00760f04d9ee Mon Sep 17 00:00:00 2001 From: David Spruill Date: Mon, 12 Feb 2024 13:07:42 -0500 Subject: update the project settings for the IDD sample --- .../IddSampleApp/IddSampleApp.vcxproj | 2 +- .../IddSampleDriver/IddSampleDriver.vcxproj | 24 ++++++++++++++-------- 2 files changed, 17 insertions(+), 9 deletions(-) diff --git a/video/IndirectDisplay/IddSampleApp/IddSampleApp.vcxproj b/video/IndirectDisplay/IddSampleApp/IddSampleApp.vcxproj index 64eccf0a..90afb399 100644 --- a/video/IndirectDisplay/IddSampleApp/IddSampleApp.vcxproj +++ b/video/IndirectDisplay/IddSampleApp/IddSampleApp.vcxproj @@ -38,7 +38,7 @@ 16.0 {ED59DFCA-E75B-4DD8-B5C2-6BFF77A225A6} IddSampleApp - $(LatestTargetPlatformVersion) + 10.0 diff --git a/video/IndirectDisplay/IddSampleDriver/IddSampleDriver.vcxproj b/video/IndirectDisplay/IddSampleDriver/IddSampleDriver.vcxproj index 288dbb03..d8c2a49c 100644 --- a/video/IndirectDisplay/IddSampleDriver/IddSampleDriver.vcxproj +++ b/video/IndirectDisplay/IddSampleDriver/IddSampleDriver.vcxproj @@ -102,6 +102,7 @@ true 1 4 + Spectre Windows10 @@ -111,6 +112,7 @@ true 1 4 + Spectre Windows10 @@ -120,6 +122,7 @@ true 1 4 + Spectre Windows10 @@ -129,6 +132,7 @@ true 1 4 + Spectre Windows10 @@ -138,6 +142,7 @@ true 1 4 + Spectre Windows10 @@ -147,6 +152,7 @@ true 1 4 + Spectre Windows10 @@ -156,6 +162,7 @@ true 1 4 + Spectre Windows10 @@ -165,6 +172,7 @@ true 1 4 + Spectre @@ -210,7 +218,7 @@ true true trace.h - Async + Sync true /DUMDF_DRIVER /DIDDCX_VERSION_MAJOR=1 /DIDDCX_VERSION_MINOR=6 /DIDDCX_MINIMUM_VERSION_REQUIRED=4 %(AdditionalOptions) @@ -226,7 +234,7 @@ true true trace.h - Async + Sync true /DUMDF_DRIVER /DIDDCX_VERSION_MAJOR=1 /DIDDCX_VERSION_MINOR=6 /DIDDCX_MINIMUM_VERSION_REQUIRED=4 %(AdditionalOptions) @@ -242,7 +250,7 @@ true true trace.h - Async + Sync true _WIN64;_AMD64_;AMD64;%(PreprocessorDefinitions) /D_ATL_NO_WIN_SUPPORT /DUMDF_DRIVER /DIDDCX_VERSION_MAJOR=1 /DIDDCX_VERSION_MINOR=6 /DIDDCX_MINIMUM_VERSION_REQUIRED=4 %(AdditionalOptions) @@ -259,7 +267,7 @@ true true trace.h - Async + Sync true _WIN64;_AMD64_;AMD64;%(PreprocessorDefinitions) /D_ATL_NO_WIN_SUPPORT /DUMDF_DRIVER /DIDDCX_VERSION_MAJOR=1 /DIDDCX_VERSION_MINOR=6 /DIDDCX_MINIMUM_VERSION_REQUIRED=4 %(AdditionalOptions) @@ -277,7 +285,7 @@ true true trace.h - Async + Sync true /DUMDF_DRIVER /DIDDCX_VERSION_MAJOR=1 /DIDDCX_VERSION_MINOR=6 /DIDDCX_MINIMUM_VERSION_REQUIRED=4 %(AdditionalOptions) @@ -290,7 +298,7 @@ true true trace.h - Async + Sync true /DUMDF_DRIVER /DIDDCX_VERSION_MAJOR=1 /DIDDCX_VERSION_MINOR=6 /DIDDCX_MINIMUM_VERSION_REQUIRED=4 %(AdditionalOptions) @@ -303,7 +311,7 @@ true true trace.h - Async + Sync true /DUMDF_DRIVER /DIDDCX_VERSION_MAJOR=1 /DIDDCX_VERSION_MINOR=6 /DIDDCX_MINIMUM_VERSION_REQUIRED=4 %(AdditionalOptions) @@ -316,7 +324,7 @@ true true trace.h - Async + Sync true /DUMDF_DRIVER /DIDDCX_VERSION_MAJOR=1 /DIDDCX_VERSION_MINOR=6 /DIDDCX_MINIMUM_VERSION_REQUIRED=4 %(AdditionalOptions) -- cgit v1.3.1