drm/atomic-helper: document drm_atomic_helper_check() restrictions
[drm/drm-misc.git] / include / linux / power / twl4030_madc_battery.h
blob26517e9dfaa966ad69d42036bb0d90eaf3d033de
1 /* SPDX-License-Identifier: GPL-2.0-or-later */
2 /*
3 * Dumb driver for LiIon batteries using TWL4030 madc.
5 * Copyright 2013 Golden Delicious Computers
6 * Nikolaus Schaller <hns@goldelico.com>
7 */
9 #ifndef __TWL4030_MADC_BATTERY_H
10 #define __TWL4030_MADC_BATTERY_H
13 * Usually we can assume 100% @ 4.15V and 0% @ 3.3V but curves differ for
14 * charging and discharging!
17 struct twl4030_madc_bat_calibration {
18 short voltage; /* in mV - specify -1 for end of list */
19 short level; /* in percent (0 .. 100%) */
22 struct twl4030_madc_bat_platform_data {
23 unsigned int capacity; /* total capacity in uAh */
24 struct twl4030_madc_bat_calibration *charging;
25 int charging_size;
26 struct twl4030_madc_bat_calibration *discharging;
27 int discharging_size;
30 #endif