Thermal Monitor for ACRN¶
To monitor the thermal information of CPUs, ACRN provide a monitor tool to implement this feature. The main daemon thread is resident in Service VM and collect the thermal information of all CPUs, including which are allocated to Standard VM and RTVM.
Thermal Monitor source code¶
When ACRN Hypervisor source code is downloaded, source code of Thermal Monitor is included. The method to get ACRN source code refer to Compile ACRN for Different Platforms. The path of Thermal Monitor source code in ACRN: misc/services/thermal_monitor
Preparation before Build¶
Before building and running the thermal monitor, following steps need to be completed:
Install ACRN on target platform, and configure ivshmem between Service VM and RTVM (if RTVM is configured). The method to configure ivshmem on ACRN refer to ACRN documentation.
Install
python3-dev
on Service VM and RTVM (if RTVM is configured).Install
msr-tools
on Service VM and RTVM (if RTVM is configured).
Build and run Thermal Monitor¶
In
thermal_monitor
directory, executemake
to build the application for Service VM and RTVM. After building, there are two applications inbuild
folder:ther_monitor_sos
is for Service VM andther_monitor_rtvm
is for RTVM.ther_monitor_sos
could be executed in Service VM directly and it would collect the thermal information for Service VM and Standard VM.ther_monitor_rtvm
should be copied into RTVM and executed. It would collect the thermal information for RTVM and send it to Service VM.