The problem is actually quite simple to formulate: I need to know current CPU and memory consumption of the whole system from kernel-mode driver under Windows. Of course, I have watched related question and tried this code. Results are not good: environment of Visual Studio 2013 for developing drivers does not know any headers from mentioned samples. E.g.:
#include "windows.h"
MEMORYSTATUSEX memInfo;
memInfo.dwLength = sizeof(MEMORYSTATUSEX);
GlobalMemoryStatusEx(&memInfo);
DWORDLONG totalVirtualMem = memInfo.ullTotalPageFile;
The code above is not compiling. I carefully examined almost all "Kernel-Mode Driver Reference" in MSDN searching for similar functions and did not succeed.
So, does anyone know how to get same information from kernel-mode driver under Windows?
Or this is impossible? (This is quite strange, if true.)