1 /* include/linux/regulator/charge-regulator.h
\r
3 * Copyright (C) 2010 ROCKCHIP, Inc.
\r
5 * This software is licensed under the terms of the GNU General Public
\r
6 * License version 2, as published by the Free Software Foundation, and
\r
7 * may be copied, distributed, and modified under those terms.
\r
9 * This program is distributed in the hope that it will be useful,
\r
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
\r
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
\r
12 * GNU General Public License for more details.
\r
15 #ifndef __LINUX_REGULATOR_PWM_H
\r
17 #define __LINUX_REGULATOR_PWM_H
\r
19 #include <linux/regulator/machine.h>
\r
20 //#include <plat/pwm.h>
\r
22 #define PWM_DIV PWM_DIV2
\r
25 struct regulator_init_data;
\r
27 struct pwm_platform_data {
\r
30 struct pwm_device *pwm;
\r
31 unsigned int period;
\r
32 unsigned int pwm_period_ns;
\r
34 unsigned int pwm_voltage;
\r
35 unsigned int suspend_voltage;
\r
36 unsigned int coefficient;
\r
37 unsigned int min_uV;
\r
38 unsigned int max_uV;
\r
39 unsigned int *pwm_voltage_map;
\r
40 struct regulator_init_data *init_data;
\r
42 struct regulator_dev **rdev;
\r
43 int pwm_vol_map_count;
\r
46 struct pwm_regulator_board {
\r
48 struct pwm_device *pwm;
\r
49 struct regulator_init_data *pwm_init_data[4];
\r
50 struct device_node *of_node[4];
\r
52 unsigned int *pwm_voltage_map;
\r
53 unsigned int pwm_init_vol;
\r
54 unsigned int pwm_max_vol;
\r
55 unsigned int pwm_min_vol;
\r
56 unsigned int pwm_suspend_vol;
\r
57 unsigned int pwm_coefficient;
\r
59 struct regulator_dev **rdev;
\r
60 int pwm_vol_map_count;
\r