blob: 69747547988ca648d0a1151ad1801bb63b832d3a [file] [log] [blame]
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -07001/*
2 * Copyright (c) 2011, Code Aurora Forum. All rights reserved.
3 *
4 * This program is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License version 2 and
6 * only version 2 as published by the Free Software Foundation.
7 *
8 * This program is distributed in the hope that it will be useful,
9 * but WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 * GNU General Public License for more details.
12 */
13
14/*
15 * Qualcomm PMIC PM8xxx Thermal Manager driver
16 */
17
18#ifndef __PM8XXX_TM_H
19#define __PM8XXX_TM_H
20
21#include <linux/errno.h>
22
23#define PM8XXX_TM_DEV_NAME "pm8xxx-tm"
24
25enum pm8xxx_tm_adc_type {
26 PM8XXX_TM_ADC_NONE, /* Estimates temp based on overload level. */
Anirudh Ghayalc2019332011-11-12 06:29:10 +053027 PM8XXX_TM_ADC_PM8058_ADC,
Siddartha Mohanadossaf91d902011-10-20 10:23:34 -070028 PM8XXX_TM_ADC_PM8XXX_ADC,
Bryan Huntsman3f2bc4d2011-08-16 17:27:22 -070029};
30
31struct pm8xxx_tm_core_data {
32 int adc_channel;
33 unsigned long default_no_adc_temp;
34 enum pm8xxx_tm_adc_type adc_type;
35 u16 reg_addr_temp_alarm_ctrl;
36 u16 reg_addr_temp_alarm_pwm;
37 char *tm_name;
38 char *irq_name_temp_stat;
39 char *irq_name_over_temp;
40};
41
42#endif