#include <linux/delay.h>
#include <linux/device.h>
#include <linux/err.h>
#include <linux/gpio/consumer.h>
#include <linux/i2c.h>
#include <linux/lockdep.h>
#include <linux/mfd/core.h>
#include <linux/mod_devicetable.h>
#include <linux/mutex.h>
#include <linux/of_platform.h>
#include <linux/regmap.h>
#include <linux/mfd/lochnagar.h>
#include <linux/mfd/lochnagar1_regs.h>
#include <linux/mfd/lochnagar2_regs.h>
#define LOCHNAGAR_BOOT_RETRIES …
#define LOCHNAGAR_BOOT_DELAY_MS …
#define LOCHNAGAR_CONFIG_POLL_US …
static bool lochnagar1_readable_register(struct device *dev, unsigned int reg)
{ … }
static const struct regmap_config lochnagar1_i2c_regmap = …;
static const struct reg_sequence lochnagar1_patch[] = …;
static bool lochnagar2_readable_register(struct device *dev, unsigned int reg)
{ … }
static bool lochnagar2_volatile_register(struct device *dev, unsigned int reg)
{ … }
static const struct regmap_config lochnagar2_i2c_regmap = …;
static const struct reg_sequence lochnagar2_patch[] = …;
struct lochnagar_config { … };
static struct lochnagar_config lochnagar_configs[] = …;
static const struct of_device_id lochnagar_of_match[] = …;
static int lochnagar_wait_for_boot(struct regmap *regmap, unsigned int *id)
{ … }
int lochnagar_update_config(struct lochnagar *lochnagar)
{ … }
EXPORT_SYMBOL_GPL(…);
static int lochnagar_i2c_probe(struct i2c_client *i2c)
{ … }
static struct i2c_driver lochnagar_i2c_driver = …;
static int __init lochnagar_i2c_init(void)
{ … }
subsys_initcall(lochnagar_i2c_init);