[Justification]
The purpose of this bug is that prevent the regression in the future.
The automatic test scripts are better for the future SRU and is still on the planning.
[Test case]
For these CPU series, RPL/ADL/TGL/CML/CFL/KBL, the following tests will be run on machines in the CI lab:
1. Run stress-ng, and observe the temperature/frequency/power with s-tui
- Temperatures should stay just below trip values
- Power/performance profiles should stay roughly the same between old thermald and new thermald (unless specifically expected eg: to fix premature/insufficient throttling)
2. check if thermald could read rules from /dev/acpi_thermal_rel and generate the xml file on /etc/thermald/ correctly.
- this depends on if acpi_thermal_rel exist.
- if the machine suppots acpi_thermal_rel, the "thermal-conf.xml.auto"
could be landed in etc/thermald/.
- if not, the user-defined xml could be created, then jump to (3).
- run thermald with --loglevel=debug, and compare the log with xml.auto file. check if the configuration could be parsed correctly.
3. check if theramd-conf.xml and thermal-cpu-cdev-order.xml can be loaded correctly.
- run thermald with --loglevel=debug, and compare the log with xml files.
- if parsed correctly, the configurations from XML files would appear in the log.
4. Run unit tests, the scripts are under test folder, using emul_temp to simulate the High temperatue and check thermald would throttle CPU through the related cooling device.
- rapl.sh
- intel_pstate.sh
- powerclamp.sh
- processor.sh
5. check if the power/frequency would be throttled once the temperature reach the trip-points of thermal zone.
6. check if system would be throttled even the temperature is under the trip-points.
[ Where problems could occur ]
since the PL1 min/max is introduced, there may have some cases that don't check the minimum of PL1 then make PL1 to smaller and smaller and throttle the CPU.
this may cause machines run like the old behavior that doesn't have PL1 min/max.
finish the sru template as we discussed