#include <linux/bitops.h>
#include <linux/err.h>
#include <linux/i2c.h>
#include <linux/module.h>
#include <linux/of.h>
#include <linux/param.h>
#include <linux/platform_device.h>
#include <linux/regmap.h>
#include <linux/regulator/driver.h>
#include <linux/regulator/fan53555.h>
#include <linux/regulator/machine.h>
#include <linux/regulator/of_regulator.h>
#include <linux/slab.h>
#define FAN53555_VSEL0 …
#define FAN53555_VSEL1 …
#define RK8602_VSEL0 …
#define RK8602_VSEL1 …
#define TCS4525_VSEL0 …
#define TCS4525_VSEL1 …
#define TCS4525_TIME …
#define TCS4525_COMMAND …
#define FAN53555_CONTROL …
#define FAN53555_ID1 …
#define FAN53555_ID2 …
#define FAN53555_MONITOR …
#define VSEL_BUCK_EN …
#define VSEL_MODE …
#define DIE_ID …
#define DIE_REV …
#define CTL_OUTPUT_DISCHG …
#define CTL_SLEW_MASK …
#define CTL_RESET …
#define CTL_MODE_VSEL0_MODE …
#define CTL_MODE_VSEL1_MODE …
#define FAN53555_NVOLTAGES …
#define FAN53526_NVOLTAGES …
#define RK8602_NVOLTAGES …
#define TCS_VSEL0_MODE …
#define TCS_VSEL1_MODE …
#define TCS_SLEW_MASK …
enum fan53555_vendor { … };
enum { … };
enum { … };
enum { … };
enum { … };
enum { … };
enum { … };
enum { … };
enum { … };
enum { … };
struct fan53555_device_info { … };
static int fan53555_set_suspend_voltage(struct regulator_dev *rdev, int uV)
{ … }
static int fan53555_set_suspend_enable(struct regulator_dev *rdev)
{ … }
static int fan53555_set_suspend_disable(struct regulator_dev *rdev)
{ … }
static int fan53555_set_mode(struct regulator_dev *rdev, unsigned int mode)
{ … }
static unsigned int fan53555_get_mode(struct regulator_dev *rdev)
{ … }
static const unsigned int slew_rates[] = …;
static const unsigned int tcs_slew_rates[] = …;
static const struct regulator_ops fan53555_regulator_ops = …;
static int fan53526_voltages_setup_fairchild(struct fan53555_device_info *di)
{ … }
static int fan53555_voltages_setup_fairchild(struct fan53555_device_info *di)
{ … }
static int fan53555_voltages_setup_rockchip(struct fan53555_device_info *di)
{ … }
static int rk8602_voltages_setup_rockchip(struct fan53555_device_info *di)
{ … }
static int fan53555_voltages_setup_silergy(struct fan53555_device_info *di)
{ … }
static int fan53526_voltages_setup_tcs(struct fan53555_device_info *di)
{ … }
static int fan53555_device_setup(struct fan53555_device_info *di,
struct fan53555_platform_data *pdata)
{ … }
static int fan53555_regulator_register(struct fan53555_device_info *di,
struct regulator_config *config)
{ … }
static const struct regmap_config fan53555_regmap_config = …;
static struct fan53555_platform_data *fan53555_parse_dt(struct device *dev,
struct device_node *np,
const struct regulator_desc *desc)
{ … }
static const struct of_device_id __maybe_unused fan53555_dt_ids[] = …;
MODULE_DEVICE_TABLE(of, fan53555_dt_ids);
static int fan53555_regulator_probe(struct i2c_client *client)
{ … }
static const struct i2c_device_id fan53555_id[] = …;
MODULE_DEVICE_TABLE(i2c, fan53555_id);
static struct i2c_driver fan53555_regulator_driver = …;
module_i2c_driver(…) …;
MODULE_AUTHOR(…) …;
MODULE_DESCRIPTION(…) …;
MODULE_LICENSE(…) …;