mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/herbert/cryptodev-2.6.git
synced 2026-04-23 05:56:14 -04:00
gpiolib: Clean up headers
There is a few things done: - include only the headers we are direct user of - when pointer is in use, provide a forward declaration - add missing headers - group generic headers and subsystem headers - sort each group alphabetically Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
This commit is contained in:
@@ -2,27 +2,35 @@
|
||||
#ifndef __LINUX_GPIO_DRIVER_H
|
||||
#define __LINUX_GPIO_DRIVER_H
|
||||
|
||||
#include <linux/device.h>
|
||||
#include <linux/irq.h>
|
||||
#include <linux/bits.h>
|
||||
#include <linux/irqchip/chained_irq.h>
|
||||
#include <linux/irqdomain.h>
|
||||
#include <linux/irqhandler.h>
|
||||
#include <linux/lockdep.h>
|
||||
#include <linux/pinctrl/pinconf-generic.h>
|
||||
#include <linux/pinctrl/pinctrl.h>
|
||||
#include <linux/property.h>
|
||||
#include <linux/spinlock_types.h>
|
||||
#include <linux/types.h>
|
||||
|
||||
#ifdef CONFIG_GENERIC_MSI_IRQ
|
||||
#include <asm/msi.h>
|
||||
#endif
|
||||
|
||||
struct gpio_desc;
|
||||
struct of_phandle_args;
|
||||
struct seq_file;
|
||||
struct gpio_device;
|
||||
struct device;
|
||||
struct irq_chip;
|
||||
struct irq_data;
|
||||
struct module;
|
||||
enum gpiod_flags;
|
||||
enum gpio_lookup_flags;
|
||||
struct of_phandle_args;
|
||||
struct pinctrl_dev;
|
||||
struct seq_file;
|
||||
|
||||
struct gpio_chip;
|
||||
struct gpio_desc;
|
||||
struct gpio_device;
|
||||
|
||||
enum gpio_lookup_flags;
|
||||
enum gpiod_flags;
|
||||
|
||||
union gpio_irq_fwspec {
|
||||
struct irq_fwspec fwspec;
|
||||
@@ -679,6 +687,10 @@ bool gpiochip_irqchip_irq_valid(const struct gpio_chip *gc,
|
||||
int gpiochip_irqchip_add_domain(struct gpio_chip *gc,
|
||||
struct irq_domain *domain);
|
||||
#else
|
||||
|
||||
#include <asm/bug.h>
|
||||
#include <asm/errno.h>
|
||||
|
||||
static inline int gpiochip_irqchip_add_domain(struct gpio_chip *gc,
|
||||
struct irq_domain *domain)
|
||||
{
|
||||
@@ -756,6 +768,10 @@ struct gpio_chip *gpiod_to_chip(const struct gpio_desc *desc);
|
||||
|
||||
#else /* CONFIG_GPIOLIB */
|
||||
|
||||
#include <linux/err.h>
|
||||
|
||||
#include <asm/bug.h>
|
||||
|
||||
static inline struct gpio_chip *gpiod_to_chip(const struct gpio_desc *desc)
|
||||
{
|
||||
/* GPIO can never have been requested */
|
||||
|
||||
Reference in New Issue
Block a user