brintos

brintos / linux-shallow public Read only

0
0
Text · 2.1 KiB · 4fd2c20 Raw
79 lines · c
1/* SPDX-License-Identifier: GPL-2.0-only */2/*3 * OMAP thermal definitions4 *5 * Copyright (C) 2012 Texas Instruments Incorporated - http://www.ti.com/6 * Contact:7 *   Eduardo Valentin <eduardo.valentin@ti.com>8 */9#ifndef __TI_THERMAL_H10#define __TI_THERMAL_H11 12#include "ti-bandgap.h"13 14/* PCB sensor calculation constants */15#define OMAP_GRADIENT_SLOPE_W_PCB_4430				016#define OMAP_GRADIENT_CONST_W_PCB_4430				2000017#define OMAP_GRADIENT_SLOPE_W_PCB_4460				114218#define OMAP_GRADIENT_CONST_W_PCB_4460				-39319#define OMAP_GRADIENT_SLOPE_W_PCB_4470				106320#define OMAP_GRADIENT_CONST_W_PCB_4470				-47721 22#define OMAP_GRADIENT_SLOPE_W_PCB_5430_CPU			10023#define OMAP_GRADIENT_CONST_W_PCB_5430_CPU			48424#define OMAP_GRADIENT_SLOPE_W_PCB_5430_GPU			46425#define OMAP_GRADIENT_CONST_W_PCB_5430_GPU			-510226 27#define DRA752_GRADIENT_SLOPE_W_PCB				028#define DRA752_GRADIENT_CONST_W_PCB				200029 30/* trip points of interest in milicelsius (at hotspot level) */31#define OMAP_TRIP_COLD						10000032#define OMAP_TRIP_HOT						11000033#define OMAP_TRIP_SHUTDOWN					12500034#define OMAP_TRIP_NUMBER					235#define OMAP_TRIP_STEP							\36	((OMAP_TRIP_SHUTDOWN - OMAP_TRIP_HOT) / (OMAP_TRIP_NUMBER - 1))37 38/* Update rates */39#define FAST_TEMP_MONITORING_RATE				25040 41#ifdef CONFIG_TI_THERMAL42int ti_thermal_expose_sensor(struct ti_bandgap *bgp, int id, char *domain);43int ti_thermal_remove_sensor(struct ti_bandgap *bgp, int id);44int ti_thermal_report_sensor_temperature(struct ti_bandgap *bgp, int id);45int ti_thermal_register_cpu_cooling(struct ti_bandgap *bgp, int id);46int ti_thermal_unregister_cpu_cooling(struct ti_bandgap *bgp, int id);47#else48static inline49int ti_thermal_expose_sensor(struct ti_bandgap *bgp, int id, char *domain)50{51	return 0;52}53 54static inline55int ti_thermal_remove_sensor(struct ti_bandgap *bgp, int id)56{57	return 0;58}59 60static inline61int ti_thermal_report_sensor_temperature(struct ti_bandgap *bgp, int id)62{63	return 0;64}65 66static inline67int ti_thermal_register_cpu_cooling(struct ti_bandgap *bgp, int id)68{69	return 0;70}71 72static inline73int ti_thermal_unregister_cpu_cooling(struct ti_bandgap *bgp, int id)74{75	return 0;76}77#endif78#endif79