Uploaded image for project: 'Core ReactOS'
  1. Core ReactOS
  2. CORE-6635

kd: Really display the total used memory in serial debug logs.



    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Fix Version/s: 0.3.15
    • Component/s: NTCore
    • Labels:
    • Module:
    • Sprint:
      Sprint 1


      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.


          Issue Links



              • Assignee:
                ThFabba ThFabba
                hbelusca hbelusca
              • Votes:
                0 Vote for this issue
                4 Start watching this issue


                • Created: