linux/drivers/regulator/mp8859.c

// SPDX-License-Identifier: GPL-2.0
//
// Copyright (c) 2019 five technologies GmbH
// Author: Markus Reichl <[email protected]>

#include <linux/module.h>
#include <linux/i2c.h>
#include <linux/of.h>
#include <linux/regulator/driver.h>
#include <linux/regmap.h>


#define VOL_MIN_IDX
#define VOL_MAX_IDX

/* Register definitions */
#define MP8859_VOUT_L_REG
#define MP8859_VOUT_H_REG
#define MP8859_VOUT_GO_REG
#define MP8859_IOUT_LIM_REG
#define MP8859_CTL1_REG
#define MP8859_CTL2_REG
#define MP8859_RESERVED1_REG
#define MP8859_RESERVED2_REG
#define MP8859_RESERVED3_REG
#define MP8859_STATUS_REG
#define MP8859_INTERRUPT_REG
#define MP8859_MASK_REG
#define MP8859_ID1_REG
#define MP8859_MFR_ID_REG
#define MP8859_DEV_ID_REG
#define MP8859_IC_REV_REG

#define MP8859_MAX_REG

#define MP8859_GO_BIT

#define MP8859_IOUT_LIM_MASK

#define MP8859_ENABLE_MASK
#define MP8859_DISCHG_EN_MASK
#define MP8859_MODE_MASK

#define MP8859_PG_MASK
#define MP8859_OTP_MASK
#define MP8859_OTW_MASK
#define MP8859_CC_CV_MASK

static int mp8859_set_voltage_sel(struct regulator_dev *rdev, unsigned int sel)
{}

static int mp8859_get_voltage_sel(struct regulator_dev *rdev)
{}

static int mp8859_set_voltage_time_sel(struct regulator_dev *rdev,
				       unsigned int from, unsigned int to)
{}

static unsigned int mp8859_get_mode(struct regulator_dev *rdev)
{}

static int mp8859_set_mode(struct regulator_dev *rdev, unsigned int mode)
{}

static int mp8859_set_current_limit(struct regulator_dev *rdev,
				    int min_uA, int max_uA)
{}

static int mp8859_get_status(struct regulator_dev *rdev)
{}

static int mp8859_get_error_flags(struct regulator_dev *rdev,
				  unsigned int *flags)
{}

static const struct linear_range mp8859_dcdc_ranges[] =;

static bool mp8859_readable(struct device *dev, unsigned int reg)
{}

static bool mp8859_volatile(struct device *dev, unsigned int reg)
{}

static const struct regmap_config mp8859_regmap =;

static const struct regulator_ops mp8859_ops =;

static const struct regulator_desc mp8859_regulators[] =;

static int mp8859_i2c_probe(struct i2c_client *i2c)
{}

static const struct of_device_id mp8859_dt_id[] __maybe_unused =;
MODULE_DEVICE_TABLE(of, mp8859_dt_id);

static const struct i2c_device_id mp8859_i2c_id[] =;
MODULE_DEVICE_TABLE(i2c, mp8859_i2c_id);

static struct i2c_driver mp8859_regulator_driver =;

module_i2c_driver();

MODULE_DESCRIPTION();
MODULE_AUTHOR();
MODULE_LICENSE();