thermal_zone_get_temp(9)
π thermal_zone_get_temp(9) π
okay so bestie, you're in the Kernel API Manual and this page is literally about thermal_zone_get_temp(9) β she's a little function that tells you how hot a thermal zone is. no cap, that's the whole gig. π‘οΈβ¨
πΈ NAME πΈ
thermal_zone_get_temp β bestie, she returns the temperature of a thermal zone, that's it, that's the job π«Ά
π SYNOPSIS π
int thermal_zone_get_temp (struct thermal_zone_device *tz , int *temp );
like look at her, so clean, so iconic π
π¦ ARGUMENTS π¦
tzβ a valid pointer to astruct thermal_zone_device. yes, valid, we mean it, don't be messy with this one πtempβ a valid pointer to where to store the resulting temperature. she's your output spot, hand her a real address please π
β¨ DESCRIPTION β¨
so when you pass in a valid thermal zone reference, she will fetch its temperature and fill temp for you. that's the vibe check: valid zone in, temperature out, everybody slays π
π₯ RETURN π₯
On success she returns 0. otherwise you get an error code β not a vibe, but at least she's honest about it π
π SEE ALSO π
- Kernel file
./drivers/thermal/thermal_helpers.c __thermal_zone_get_temp(9)thermal_cdev_update(9)thermal_cdev_update_nocheck(9)thermal_zone_get_slope(9)thermal_zone_get_offset(9)
π reminder:tzandtempboth gotta be valid pointers. this page says it twice because it matters. fr fr.
okay that's the whole page bestie, go forth and read those temps πβ¨
shoutout to ./drivers/thermal for hosting her, and to October 2026 for the timestamp β she's dated, she's sourced, she's iconic ππ¦π
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms