1 /* SPDX-License-Identifier: GPL-2.0-or-later */
46 * struct max77686_para - max77686 register parameters
47 * @param vol_addr i2c address of the given buck/ldo register
48 * @param vol_bitpos bit position to be set or clear within register
49 * @param vol_bitmask bit mask value
50 * @param reg_enaddr control register address, which enable the given
52 * @param reg_enbitpos bit position to be enabled
53 * @param reg_enbiton value to be written to buck/ldo to make it ON
54 * @param reg_enbitoff value to be written to buck/ldo to make it OFF
55 * @param vol_min minimum voltage level supported by given buck/ldo
56 * @param vol_div voltage division value of given buck/ldo
58 struct max77686_para
{
71 /* I2C device address for pmic max77686 */
72 #define MAX77686_I2C_ADDR (0x12 >> 1)
80 MAX77686_MV
= 0, /* millivolt */
81 MAX77686_UV
/* microvolt */
85 * This function enables the 32KHz coprocessor clock.
89 * Return 0 if ok, else -1
91 int max77686_enable_32khz_cp(unsigned int bus
);
94 * Set the required voltage level of pmic
97 * @param reg register number of buck/ldo to be set
98 * @param volt voltage level to be set
99 * @param enable enable or disable bit
100 * @param volt_units MAX77686_MV or MAX77686_UV, unit of the
103 * @return Return 0 if ok, else -1
105 int max77686_volsetting(unsigned int bus
, enum max77686_regnum reg
,
106 unsigned int volt
, int enable
, int volt_units
);
109 * Disable charging of the RTC backup battery
113 * @return Return 0 if ok, else -1
115 int max77686_disable_backup_batt(unsigned int bus
);
117 #endif /* __MAX77686_H_ */