From 44090b37e4d39ed3f093610ea3b2dc5b649467b9 Mon Sep 17 00:00:00 2001 From: John Crispin Date: Thu, 11 Oct 2012 11:58:09 +0000 Subject: [kernel] gpiodev/gpioctl RIP git-svn-id: svn://svn.openwrt.org/openwrt/trunk@33725 3c298f89-4303-0410-b956-a3cf2f4a3e73 --- .../linux/generic/files/include/linux/gpio_dev.h | 42 ---------------------- 1 file changed, 42 deletions(-) delete mode 100644 target/linux/generic/files/include/linux/gpio_dev.h (limited to 'target/linux/generic/files/include') diff --git a/target/linux/generic/files/include/linux/gpio_dev.h b/target/linux/generic/files/include/linux/gpio_dev.h deleted file mode 100644 index a2a4b51c78..0000000000 --- a/target/linux/generic/files/include/linux/gpio_dev.h +++ /dev/null @@ -1,42 +0,0 @@ -#ifndef _GPIO_DEV_H__ -#define _GPIO_DEV_H__ - -/********************************************************************* - * - * This Linux kernel header is expanded from the original driver - * (gpio_dev) by John Crispin. It provides an ioctl based interface to - * GPIO pins via the /dev/gpio char device and gpiolib within the kernel. - * The third argument to each ioctl is the GPIO pin number. - * - * This driver has been tested with lk 2.6.31 and works. The original - * driver fails quietly with this version. The protocol is now a bit - * different: the ioctl(fd, GPIO_REQUEST, ) should be called - * after the open("/dev/gpio", O_RDWR) to determine if the is - * already in use. If the ioctl is successful (i.e. returns 0 for not - * in use) then the is claimed by this driver and - * ioctl(fd, GPIO_FREE, ) should be called prior to close(fd) . - * - * See /Documentation/gpio.txt - * Note that kernel designers prefer the use of the sysfs gpio interface. - * This char driver is easier to use from code and faster. - ********************************************************************/ - -/* This header can be included in both the user and kernel spaces */ -/* The _IO macro is defined in sys/ioctl.h */ - -#define IOC_GPIODEV_MAGIC 'B' - -#define GPIO_GET _IO(IOC_GPIODEV_MAGIC, 10) -#define GPIO_SET _IO(IOC_GPIODEV_MAGIC, 11) -#define GPIO_CLEAR _IO(IOC_GPIODEV_MAGIC, 12) -#define GPIO_DIR_IN _IO(IOC_GPIODEV_MAGIC, 13) -#define GPIO_DIR_OUT _IO(IOC_GPIODEV_MAGIC, 14) - /* Sets the direction out and clears the (low) */ - -#define GPIO_DIR_HIGH _IO(IOC_GPIODEV_MAGIC, 15) - /* Sets the direction out and sets the (high) */ -#define GPIO_REQUEST _IO(IOC_GPIODEV_MAGIC, 16) -#define GPIO_FREE _IO(IOC_GPIODEV_MAGIC, 17) -#define GPIO_CAN_SLEEP _IO(IOC_GPIODEV_MAGIC, 18) - -#endif -- cgit v1.2.3