/*
- $Id: bttv-if.c,v 1.3 2004/10/13 10:39:00 kraxel Exp $
-
bttv-if.c -- old gpio interface to other kernel modules
don't use in new code, will go away in 2.7
have a look at bttv-gpio.c instead.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-
+
*/
#include <linux/module.h>
if (card >= bttv_num) {
return -EINVAL;
}
-
+
btv = &bttvs[card];
gpio_inout(mask,data);
if (bttv_gpio)
int bttv_read_gpio(unsigned int card, unsigned long *data)
{
struct bttv *btv;
-
+
if (card >= bttv_num) {
return -EINVAL;
}
return -ENODEV;
}
-/* prior setting BT848_GPIO_REG_INP is (probably) not needed
+/* prior setting BT848_GPIO_REG_INP is (probably) not needed
because we set direct input on init */
*data = gpio_read();
return 0;
int bttv_write_gpio(unsigned int card, unsigned long mask, unsigned long data)
{
struct bttv *btv;
-
+
if (card >= bttv_num) {
return -EINVAL;
}
btv = &bttvs[card];
-/* prior setting BT848_GPIO_REG_INP is (probably) not needed
+/* prior setting BT848_GPIO_REG_INP is (probably) not needed
because direct input is set on init */
gpio_bits(mask,data);
if (bttv_gpio)