#include <linux/errno.h>
#include <linux/gpio/driver.h>
#include <linux/kernel.h>
#include <linux/init.h>
#include <linux/mfd/tps6586x.h>
#include <linux/of.h>
#include <linux/platform_device.h>
#define TPS6586X_GPIOSET1 …
#define TPS6586X_GPIOSET2 …
struct tps6586x_gpio { … };
static int tps6586x_gpio_get(struct gpio_chip *gc, unsigned offset)
{ … }
static void tps6586x_gpio_set(struct gpio_chip *gc, unsigned offset,
int value)
{ … }
static int tps6586x_gpio_output(struct gpio_chip *gc, unsigned offset,
int value)
{ … }
static int tps6586x_gpio_to_irq(struct gpio_chip *gc, unsigned offset)
{ … }
static int tps6586x_gpio_probe(struct platform_device *pdev)
{ … }
static struct platform_driver tps6586x_gpio_driver = …;
static int __init tps6586x_gpio_init(void)
{ … }
subsys_initcall(tps6586x_gpio_init);