1
2
3
4
5
6
7
8
9
10
11
12#ifndef _LP8727_H
13#define _LP8727_H
14
15enum lp8727_eoc_level {
16 LP8727_EOC_5P,
17 LP8727_EOC_10P,
18 LP8727_EOC_16P,
19 LP8727_EOC_20P,
20 LP8727_EOC_25P,
21 LP8727_EOC_33P,
22 LP8727_EOC_50P,
23};
24
25enum lp8727_ichg {
26 LP8727_ICHG_90mA,
27 LP8727_ICHG_100mA,
28 LP8727_ICHG_400mA,
29 LP8727_ICHG_450mA,
30 LP8727_ICHG_500mA,
31 LP8727_ICHG_600mA,
32 LP8727_ICHG_700mA,
33 LP8727_ICHG_800mA,
34 LP8727_ICHG_900mA,
35 LP8727_ICHG_1000mA,
36};
37
38
39
40
41
42
43struct lp8727_chg_param {
44 enum lp8727_eoc_level eoc_level;
45 enum lp8727_ichg ichg;
46};
47
48
49
50
51
52
53
54
55
56
57
58struct lp8727_platform_data {
59 u8 (*get_batt_present)(void);
60 u16 (*get_batt_level)(void);
61 u8 (*get_batt_capacity)(void);
62 u8 (*get_batt_temp)(void);
63 struct lp8727_chg_param *ac;
64 struct lp8727_chg_param *usb;
65 unsigned int debounce_msec;
66};
67
68#endif
69