mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2025-01-01 10:45:49 +00:00
7251b9e8a0
CPU temperature can be negative in some cases. Thus the negative CPU
temperature should not be considered as a failure.
Fix intel_tcc_get_temp() and its users to support negative CPU
temperature.
Fixes: a3c1f066e1
("thermal/intel: Introduce Intel TCC library")
Signed-off-by: Zhang Rui <rui.zhang@intel.com>
Reviewed-by: Stanislaw Gruszka <stanislaw.gruszka@linux.intel.com>
Cc: 6.3+ <stable@vger.kernel.org> # 6.3+
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
19 lines
429 B
C
19 lines
429 B
C
/* SPDX-License-Identifier: GPL-2.0 */
|
|
/*
|
|
* header for Intel TCC (thermal control circuitry) library
|
|
*
|
|
* Copyright (C) 2022 Intel Corporation.
|
|
*/
|
|
|
|
#ifndef __INTEL_TCC_H__
|
|
#define __INTEL_TCC_H__
|
|
|
|
#include <linux/types.h>
|
|
|
|
int intel_tcc_get_tjmax(int cpu);
|
|
int intel_tcc_get_offset(int cpu);
|
|
int intel_tcc_set_offset(int cpu, int offset);
|
|
int intel_tcc_get_temp(int cpu, int *temp, bool pkg);
|
|
|
|
#endif /* __INTEL_TCC_H__ */
|