#include <linux/module.h>
#include <linux/of.h>
#include <linux/platform_device.h>
#include <linux/regmap.h>
#include <linux/mfd/mt6397/core.h>
#include <linux/mfd/mt6357/registers.h>
#include <linux/regulator/driver.h>
#include <linux/regulator/machine.h>
#include <linux/regulator/mt6357-regulator.h>
#include <linux/regulator/of_regulator.h>
struct mt6357_regulator_info { … };
#define MT6357_BUCK(match, vreg, min, max, step, \
volt_ranges, vosel_reg, vosel_mask, _da_vsel_mask) …
#define MT6357_LDO(match, vreg, ldo_volt_table, \
enreg, vosel, vosel_mask) …
#define MT6357_LDO1(match, vreg, min, max, step, volt_ranges, \
enreg, vosel, vosel_mask) …
#define MT6357_REG_FIXED(match, vreg, volt) …
static int mt6357_get_buck_voltage_sel(struct regulator_dev *rdev)
{ … }
static const struct regulator_ops mt6357_volt_range_ops = …;
static const struct regulator_ops mt6357_volt_table_ops = …;
static const struct regulator_ops mt6357_volt_fixed_ops = …;
static const int vxo22_voltages[] = …;
static const int vefuse_voltages[] = …;
static const int vcn33_voltages[] = …;
static const int vcama_voltages[] = …;
static const int vcamd_voltages[] = …;
static const int vldo28_voltages[] = …;
static const int vdram_voltages[] = …;
static const int vsim_voltages[] = …;
static const int vibr_voltages[] = …;
static const int vmc_voltages[] = …;
static const int vmch_voltages[] = …;
static const int vemc_voltages[] = …;
static const int vusb_voltages[] = …;
static const struct linear_range buck_volt_range1[] = …;
static const struct linear_range buck_volt_range2[] = …;
static const struct linear_range buck_volt_range3[] = …;
static const struct linear_range buck_volt_range4[] = …;
static struct mt6357_regulator_info mt6357_regulators[] = …;
static int mt6357_regulator_probe(struct platform_device *pdev)
{ … }
static const struct platform_device_id mt6357_platform_ids[] = …;
MODULE_DEVICE_TABLE(platform, mt6357_platform_ids);
static struct platform_driver mt6357_regulator_driver = …;
module_platform_driver(…) …;
MODULE_AUTHOR(…) …;
MODULE_AUTHOR(…) …;
MODULE_AUTHOR(…) …;
MODULE_DESCRIPTION(…) …;
MODULE_LICENSE(…) …;