STRUCT EXYNOS_TMU_DATA(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸŽ€ NAME πŸŽ€

okay so bestie, welcome to struct exynos_tmu_data β€” the manual page for it lives under the Kernel API Manual, and this whole thing is literally just a structure to hold the private data of the TMU driver. that's it, that's the vibe πŸ’…


✨ SYNOPSIS ✨

like, here's the whole glow-up, copied exactly so you can't mess it up:

struct exynos_tmu_data {
    void __iomem *base;
    void __iomem *base_second;
    int irq;
    enum soc_type soc;
    struct mutex lock;
    struct clk *clk, *clk_sec, *sclk;
    u32 cal_type;
    u32 efuse_value;
    u32 min_efuse_value;
    u32 max_efuse_value;
    u16 temp_error1, temp_error2;
    u8 gain;
    u8 reference_voltage;
    struct thermal_zone_device *tzd;
    bool enabled;
    void (*tmu_set_low_temp)(struct exynos_tmu_data *data, u8 temp);
    void (*tmu_set_high_temp)(struct exynos_tmu_data *data, u8 temp);
    void (*tmu_set_crit_temp)(struct exynos_tmu_data *data, u8 temp);
    void (*tmu_disable_low)(struct exynos_tmu_data *data);
    void (*tmu_disable_high)(struct exynos_tmu_data *data);
    void (*tmu_initialize)(struct platform_device *pdev);
    void (*tmu_control)(struct platform_device *pdev, bool on);
    int (*tmu_read)(struct exynos_tmu_data *data);
    void (*tmu_set_emulation)(struct exynos_tmu_data *data, int temp);
    void (*tmu_clear_irqs)(struct exynos_tmu_data *data);
 };

🌈 Members 🌈

okay this is the part where we go member by member, no skipping, we are NOT leaving anyone out 🫢

  • base β€” base address of the single instance of the TMU controller ✨
  • base_second β€” base address of the common registers of the TMU controller
  • irq β€” irq number of the TMU controller, iconic honestly
  • soc β€” id of the SOC type
  • lock β€” lock to implement synchronization πŸ”’ (please respect the lock, bestie)
  • clk β€” pointer to the clock structure
  • clk_sec β€” pointer to the clock structure for accessing the base_second
  • sclk β€” pointer to the clock structure for accessing the tmu special clk
  • cal_type β€” calibration type for temperature
  • efuse_value β€” SoC defined fuse value
  • min_efuse_value β€” minimum valid trimming data
  • max_efuse_value β€” maximum valid trimming data
  • temp_error1 β€” fused value of the first point trim.
  • temp_error2 β€” fused value of the second point trim.
  • gain β€” gain of amplifier in the positive-TC generator block, and the rules are 0 < gain <= 15 πŸ“
  • reference_voltage β€” reference voltage of amplifier in the positive-TC generator block, and again, 0 < reference_voltage <= 31 ⚑
  • tzd β€” pointer to thermal_zone_device structure
  • enabled β€” current status of TMU device
  • tmu_set_low_temp β€” SoC specific method to set trip (falling threshold) 🌑️
  • tmu_set_high_temp β€” SoC specific method to set trip (rising threshold) πŸ”₯
  • tmu_set_crit_temp β€” SoC specific method to set critical temperature πŸ’€
  • tmu_disable_low β€” SoC specific method to disable an interrupt (falling threshold)
  • tmu_disable_high β€” SoC specific method to disable an interrupt (rising threshold)
  • tmu_initialize β€” SoC specific TMU initialization method
  • tmu_control β€” SoC specific TMU control method
  • tmu_read β€” SoC specific TMU temperature read method
  • tmu_set_emulation β€” SoC specific TMU emulation setting method
  • tmu_clear_irqs β€” SoC specific TMU interrupts clearing method
lowkey a whole army of function pointers in there β€” every one of them is SoC specific, fr fr. don't go thinking one size fits all πŸ™ˆ

🌟 SEE ALSO 🌟

  • Kernel file ./drivers/thermal/samsung/exynos_tmu.c β€” go read it, iykyk πŸ“–

and that's the whole page bestie! this was the struct exynos_tmu_data(9) moment, brought to you by the fine folks at ./drivers/thermal/samsung, dated October 2026 β€” mwah, slay, periodt πŸ’–πŸ¦‹πŸŒΈ

πŸ“¦ where this page comes from