thermal_zone_get_temp(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… 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 a struct 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 🌈


πŸ’€ reminder: tz and temp both 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