From d63d9efb3957becb17253f1e36fa6dc7f577b5d4 Mon Sep 17 00:00:00 2001 From: Dibyamartanda Samanta Date: Thu, 9 May 2024 12:23:16 +0200 Subject: [PATCH] Added CcMdlReadComplete2 --- CC/ccmdlhandler.cpp | 41 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) create mode 100644 CC/ccmdlhandler.cpp diff --git a/CC/ccmdlhandler.cpp b/CC/ccmdlhandler.cpp new file mode 100644 index 0000000..d36326c --- /dev/null +++ b/CC/ccmdlhandler.cpp @@ -0,0 +1,41 @@ +/* +* PROJECT: Alcyone Kernel +* LICENSE: BSD Clause 3 +* PURPOSE: Cache Controller:: MDL Handler +* NT KERNEL: 5.11.9360 +* COPYRIGHT: 2023-2029 Dibymartanda Samanta <> +* +*/ + +#include +#define NTDEBUG +#include +#include "ccinternal.hpp" +#include "ccmdl.hpp" + +/* Intenal Functions */ + +VOID +NTAPI +CcMdlReadComplete2 ( + IN PFILE_OBJECT FileObject, + IN PMDL MdlChain +) +{ + /* Check if MDL Chain is Valid */ + if (MdlChain) + { + + /*Iterate Through the MDL CHain*/ + for( auto it = begin(MdlChain); it != end(MdlChain);++it) + { + /*Unlock the memory pages associated with the MDL*/ + MmUnlockPages(*it); + /*Free The MDL */ + IoFreeMdl(*it); + } + } +} + + +