Description
Since ages, serial debug logs showed (for example) :
(C:/Users/ReactOS/trunk/reactos/ntoskrnl/kd/kdio.c:376) -----------------------------------------------------
(C:/Users/ReactOS/trunk/reactos/ntoskrnl/kd/kdio.c:377) ReactOS 0.4-SVN (Build 20120912-r57283)
(C:/Users/ReactOS/trunk/reactos/ntoskrnl/kd/kdio.c:379) 1 System Processor [0 MB Memory]
"0 MB Memory" instead of the real quantity of total memory.
It is due to the fact that, at this stage, the Memory Manager isn't fully initialized and the MmNumberOfPhysicalPages global variable isn't initialized (in fact, it is equal to zero). On the opposite, when such information is shown either on the screen (debug mode) or either when debug outputs are displayed on screen (with the help of the /SCREEN boot commutator) or by creating a debug log file, these information lines are displayed / written AFTER the Memory Manager is initialized, therefore AFTER the MmNumberOfPhysicalPages variable is initialized, thus displaying the REAL quantity of memory.
This patch attempts to correct this behaviour in order to make the serial debug logs also showing this information, by implementing a new helper function which does almost the same – by using the same algorithm – as the Mm function which initializes MmNumberOfPhysicalPages. The helper computes the total quantity of memory available.
Attachments
Issue Links
- duplicates
-
CORE-6298 bootlog shows always [0 MB Memory]
- Resolved