aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/acpi_gpio.h
diff options
context:
space:
mode:
authorMika Westerberg <mika.westerberg@linux.intel.com>2014-01-08 05:40:56 -0500
committerLinus Walleij <linus.walleij@linaro.org>2014-01-08 09:07:28 -0500
commit5ccff85276addfdaad0046390bc5624f7e44e614 (patch)
tree4e1c1cdbdc77dcc647f926330c691066ad14b65d /include/linux/acpi_gpio.h
parent664e3e5ac64c8a1999e2d94bc307e5bcd17d3646 (diff)
gpio / ACPI: get rid of acpi_gpio.h
Now that all users of acpi_gpio.h have been moved to use either the GPIO descriptor interface or to the internal gpiolib.h we can get rid of acpi_gpio.h entirely. Once this is done the only interface to get GPIOs to drivers enumerated from ACPI namespace is the descriptor based interface. Signed-off-by: Mika Westerberg <mika.westerberg@linux.intel.com> Acked-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Acked-by: Alexandre Courbot <acourbot@nvidia.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Diffstat (limited to 'include/linux/acpi_gpio.h')
-rw-r--r--include/linux/acpi_gpio.h45
1 files changed, 0 insertions, 45 deletions
diff --git a/include/linux/acpi_gpio.h b/include/linux/acpi_gpio.h
deleted file mode 100644
index af96a0d452f6..000000000000
--- a/include/linux/acpi_gpio.h
+++ /dev/null
@@ -1,45 +0,0 @@
1#ifndef _LINUX_ACPI_GPIO_H_
2#define _LINUX_ACPI_GPIO_H_
3
4#include <linux/device.h>
5#include <linux/err.h>
6#include <linux/errno.h>
7#include <linux/gpio.h>
8#include <linux/gpio/consumer.h>
9
10/**
11 * struct acpi_gpio_info - ACPI GPIO specific information
12 * @gpioint: if %true this GPIO is of type GpioInt otherwise type is GpioIo
13 * @active_low: in case of @gpioint, the pin is active low
14 */
15struct acpi_gpio_info {
16 bool gpioint;
17 bool active_low;
18};
19
20#ifdef CONFIG_GPIO_ACPI
21
22struct gpio_desc *acpi_get_gpiod_by_index(struct device *dev, int index,
23 struct acpi_gpio_info *info);
24#else /* CONFIG_GPIO_ACPI */
25
26static inline struct gpio_desc *
27acpi_get_gpiod_by_index(struct device *dev, int index,
28 struct acpi_gpio_info *info)
29{
30 return ERR_PTR(-ENOSYS);
31}
32
33#endif /* CONFIG_GPIO_ACPI */
34
35static inline int acpi_get_gpio_by_index(struct device *dev, int index,
36 struct acpi_gpio_info *info)
37{
38 struct gpio_desc *desc = acpi_get_gpiod_by_index(dev, index, info);
39
40 if (IS_ERR(desc))
41 return PTR_ERR(desc);
42 return desc_to_gpio(desc);
43}
44
45#endif /* _LINUX_ACPI_GPIO_H_ */