projects
/
reactos.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
09da0e3
)
[NTOS:MM]
author
Thomas Faber
<thomas.faber@reactos.org>
Fri, 26 Jun 2015 11:02:40 +0000
(11:02 +0000)
committer
Thomas Faber
<thomas.faber@reactos.org>
Fri, 26 Jun 2015 11:02:40 +0000
(11:02 +0000)
- Do not request a page in MiAllocatePagesForMdl if no pages are available. Fixes kmtest:MmMdl.
CORE-9879 #resolve
svn path=/trunk/; revision=68274
reactos/ntoskrnl/mm/freelist.c
patch
|
blob
|
history
diff --git
a/reactos/ntoskrnl/mm/freelist.c
b/reactos/ntoskrnl/mm/freelist.c
index
0012054
..
849b567
100644
(file)
--- a/
reactos/ntoskrnl/mm/freelist.c
+++ b/
reactos/ntoskrnl/mm/freelist.c
@@
-232,7
+232,12
@@
MiAllocatePagesForMdl(IN PHYSICAL_ADDRESS LowAddress,
/* Grab a page */
MI_SET_USAGE(MI_USAGE_MDL);
MI_SET_PROCESS2("Kernel");
- Page = MiRemoveAnyPage(0);
+
+ /* FIXME: This check should be smarter */
+ Page = 0;
+ if (MmAvailablePages != 0)
+ Page = MiRemoveAnyPage(0);
+
if (Page == 0)
{
/* This is not good... hopefully we have at least SOME pages */