Mailing List archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[linux-dvb] [PATCH] video_device->close
Hi,
I added a close function that stops DMA which is highly
appreciated and the normal behaviour of v4l drivers.
The functionality is implemented for < 2.5 only, yet.
--
Best regards,
Denis Oliver Kropp
.------------------------------------------.
| DirectFB - Hardware accelerated graphics |
| http://www.directfb.org/ |
"------------------------------------------"
Convergence GmbH
Index: driver/av7110/av7110.c
===================================================================
RCS file: /cvs/linuxtv/DVB/driver/av7110/av7110.c,v
retrieving revision 1.28
diff -u -r1.28 av7110.c
--- driver/av7110/av7110.c 24 Feb 2003 22:53:05 -0000 1.28
+++ driver/av7110/av7110.c 4 Mar 2003 17:15:47 -0000
@@ -3250,6 +3250,17 @@
return mask;
}
+#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,5,0))
+static
+void dvb_close(struct video_device *dev)
+{
+ int zero = 0;
+ av7110_t *av7110 = dev->priv;
+
+ /* Disable video DMA */
+ saacomm(SAA7146_V4L_CCAPTURE, &zero);
+}
+#endif
#if !(LINUX_VERSION_CODE < KERNEL_VERSION(2,5,0))
static struct file_operations dvb_fops = {
@@ -3274,6 +3285,7 @@
#if LINUX_VERSION_CODE < KERNEL_VERSION(2,5,0)
.ioctl = dvb_ioctl,
.mmap = dvb_mmap,
+ .close = dvb_close
#else
.fops = &dvb_fops
#endif
Home |
Main Index |
Thread Index