Skip to content
  • Zhang Rui's avatar
    Thermal: Introduce .get_trend() callback. · 601f3d42
    Zhang Rui authored
    
    
    According to ACPI spec, tc1 and tc2 are used by OSPM
    to anticipate the temperature trends.
    We introduced the same concept to the generic thermal layer
    for passive cooling, but now it seems that these values
    are hard to be used on other platforms.
    
    So We introduce .get_trend() as a more general solution.
    
    For the platform thermal drivers that have their own way to
    anticipate the temperature trends, they should provide
    their own .get_trend() callback.
    Or else, we will calculate the temperature trends by simply
    comparing the current temperature and the cached previous
    temperature reading.
    
    Signed-off-by: default avatarZhang Rui <rui.zhang@intel.com>
    Reviewed-by: default avatarRafael J. Wysocki <rjw@sisk.pl>
    Reviewed-by: default avatarValentin, Eduardo <eduardo.valentin@ti.com>
    601f3d42