162306a36Sopenharmony_ciTMON - A Monitoring and Testing Tool for Linux kernel thermal subsystem
262306a36Sopenharmony_ci
362306a36Sopenharmony_ciWhy TMON?
462306a36Sopenharmony_ci==========
562306a36Sopenharmony_ciIncreasingly, Linux is running on thermally constrained devices. The simple
662306a36Sopenharmony_cithermal relationship between processor and fan has become past for modern
762306a36Sopenharmony_cicomputers.
862306a36Sopenharmony_ci
962306a36Sopenharmony_ciAs hardware vendors cope with the thermal constraints on their products, more
1062306a36Sopenharmony_ciand more sensors are added, new cooling capabilities are introduced. The
1162306a36Sopenharmony_cicomplexity of the thermal relationship can grow exponentially among cooling
1262306a36Sopenharmony_cidevices, zones, sensors, and trip points. They can also change dynamically.
1362306a36Sopenharmony_ci
1462306a36Sopenharmony_ciTo expose such relationship to the userspace, Linux generic thermal layer
1562306a36Sopenharmony_ciintroduced sysfs entry at /sys/class/thermal with a matrix of symbolic
1662306a36Sopenharmony_cilinks, trip point bindings, and device instances. To traverse such
1762306a36Sopenharmony_cimatrix by hand is not a trivial task. Testing is also difficult in that
1862306a36Sopenharmony_cithermal conditions are often exception cases that hard to reach in
1962306a36Sopenharmony_cinormal operations.
2062306a36Sopenharmony_ci
2162306a36Sopenharmony_ciTMON is conceived as a tool to help visualize, tune, and test the
2262306a36Sopenharmony_cicomplex thermal subsystem.
2362306a36Sopenharmony_ci
2462306a36Sopenharmony_ciFiles
2562306a36Sopenharmony_ci=====
2662306a36Sopenharmony_ci	tmon.c : main function for set up and configurations.
2762306a36Sopenharmony_ci	tui.c : handles ncurses based user interface
2862306a36Sopenharmony_ci	sysfs.c : access to the generic thermal sysfs
2962306a36Sopenharmony_ci	pid.c : a proportional-integral-derivative (PID) controller
3062306a36Sopenharmony_ci	that can be used for thermal relationship training.
3162306a36Sopenharmony_ci
3262306a36Sopenharmony_ciRequirements
3362306a36Sopenharmony_ci============
3462306a36Sopenharmony_ciDepends on ncurses
3562306a36Sopenharmony_ci
3662306a36Sopenharmony_ciBuild
3762306a36Sopenharmony_ci=========
3862306a36Sopenharmony_ci$ make
3962306a36Sopenharmony_ci$ sudo ./tmon -h
4062306a36Sopenharmony_ciUsage: tmon [OPTION...]
4162306a36Sopenharmony_ci  -c, --control         cooling device in control
4262306a36Sopenharmony_ci  -d, --daemon          run as daemon, no TUI
4362306a36Sopenharmony_ci  -l, --log             log data to /var/tmp/tmon.log
4462306a36Sopenharmony_ci  -h, --help            show this help message
4562306a36Sopenharmony_ci  -t, --time-interval   set time interval for sampling
4662306a36Sopenharmony_ci  -v, --version         show version
4762306a36Sopenharmony_ci  -g, --debug           debug message in syslog
4862306a36Sopenharmony_ci
4962306a36Sopenharmony_ci1. For monitoring only:
5062306a36Sopenharmony_ci$ sudo ./tmon
51