mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2025-01-06 05:44:20 +08:00
58bfaaac03
The forward declaration for struct gpio_device should be provided for
both branches of the #ifdef.
Fixes: 08a149c40b
("gpiolib: Clean up headers")
Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
Reviewed-by: Linus Walleij <linus.walleij@linaro.org>
Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
27 lines
478 B
C
27 lines
478 B
C
/* SPDX-License-Identifier: GPL-2.0 */
|
|
|
|
#ifndef GPIOLIB_SYSFS_H
|
|
#define GPIOLIB_SYSFS_H
|
|
|
|
struct gpio_device;
|
|
|
|
#ifdef CONFIG_GPIO_SYSFS
|
|
|
|
int gpiochip_sysfs_register(struct gpio_device *gdev);
|
|
void gpiochip_sysfs_unregister(struct gpio_device *gdev);
|
|
|
|
#else
|
|
|
|
static inline int gpiochip_sysfs_register(struct gpio_device *gdev)
|
|
{
|
|
return 0;
|
|
}
|
|
|
|
static inline void gpiochip_sysfs_unregister(struct gpio_device *gdev)
|
|
{
|
|
}
|
|
|
|
#endif /* CONFIG_GPIO_SYSFS */
|
|
|
|
#endif /* GPIOLIB_SYSFS_H */
|