summaryrefslogtreecommitdiffstats
path: root/drivers/gpio/Kconfig
diff options
context:
space:
mode:
authorKent Gibson <warthog618@gmail.com>2020-09-28 08:27:52 +0800
committerBartosz Golaszewski <bgolaszewski@baylibre.com>2020-09-30 10:56:42 +0200
commitd143493c01b7fc3a9b9369a795e20329561222c5 (patch)
treea775840c49b5364aed598090f582003a706741db /drivers/gpio/Kconfig
parentb53911aa872db462be2e5f1dd611b25c4c2e663b (diff)
downloadlinux-d143493c01b7fc3a9b9369a795e20329561222c5.tar.gz
linux-d143493c01b7fc3a9b9369a795e20329561222c5.tar.bz2
linux-d143493c01b7fc3a9b9369a795e20329561222c5.zip
gpiolib: make cdev a build option
Make the gpiolib-cdev module a build option. This allows the CDEV interface to be removed from the kernel to reduce kernel size in applications where is it not required, and provides the parent for other CDEV interface specific build options to follow. Suggested-by: Bartosz Golaszewski <bgolaszewski@baylibre.com> Signed-off-by: Kent Gibson <warthog618@gmail.com> Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com> Signed-off-by: Bartosz Golaszewski <bgolaszewski@baylibre.com>
Diffstat (limited to 'drivers/gpio/Kconfig')
-rw-r--r--drivers/gpio/Kconfig17
1 files changed, 15 insertions, 2 deletions
diff --git a/drivers/gpio/Kconfig b/drivers/gpio/Kconfig
index c7292a50aec4..cbf8a60dec03 100644
--- a/drivers/gpio/Kconfig
+++ b/drivers/gpio/Kconfig
@@ -66,8 +66,21 @@ config GPIO_SYSFS
This ABI is deprecated. If you want to use GPIO from userspace,
use the character device /dev/gpiochipN with the appropriate
- ioctl() operations instead. The character device is always
- available.
+ ioctl() operations instead.
+
+config GPIO_CDEV
+ bool
+ prompt "Character device (/dev/gpiochipN) support" if EXPERT
+ default y
+ help
+ Say Y here to add the character device /dev/gpiochipN interface
+ for GPIOs. The character device allows userspace to control GPIOs
+ using ioctl() operations.
+
+ Only say N if you are sure that the GPIO character device is not
+ required.
+
+ If unsure, say Y.
config GPIO_GENERIC
depends on HAS_IOMEM # Only for IOMEM drivers