summaryrefslogtreecommitdiff
path: root/include/linux/gpio/driver.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/linux/gpio/driver.h')
-rw-r--r--include/linux/gpio/driver.h7
1 files changed, 4 insertions, 3 deletions
diff --git a/include/linux/gpio/driver.h b/include/linux/gpio/driver.h
index 82fda487453f..f3f1dbd43c9b 100644
--- a/include/linux/gpio/driver.h
+++ b/include/linux/gpio/driver.h
@@ -1,6 +1,7 @@
#ifndef __LINUX_GPIO_DRIVER_H
#define __LINUX_GPIO_DRIVER_H
+#include <linux/device.h>
#include <linux/types.h>
#include <linux/module.h>
#include <linux/irq.h>
@@ -10,22 +11,22 @@
#include <linux/pinctrl/pinctrl.h>
#include <linux/kconfig.h>
-struct device;
struct gpio_desc;
struct of_phandle_args;
struct device_node;
struct seq_file;
+struct gpio_device;
#ifdef CONFIG_GPIOLIB
/**
* struct gpio_chip - abstract a GPIO controller
* @label: for diagnostics
+ * @gpiodev: the internal state holder, opaque struct
* @parent: optional parent device providing the GPIOs
* @cdev: class device used by sysfs interface (may be NULL)
* @owner: helps prevent removal of modules exporting active GPIOs
* @data: per-instance data assigned by the driver
- * @list: links gpio_chips together for traversal
* @request: optional hook for chip-specific activation, such as
* enabling module power and clock; may sleep
* @free: optional hook for chip-specific deactivation, such as
@@ -107,11 +108,11 @@ struct seq_file;
*/
struct gpio_chip {
const char *label;
+ struct gpio_device *gpiodev;
struct device *parent;
struct device *cdev;
struct module *owner;
void *data;
- struct list_head list;
int (*request)(struct gpio_chip *chip,
unsigned offset);