patch-2.4.19 linux-2.4.19/drivers/media/video/zr36067.c
Next file: linux-2.4.19/drivers/message/fusion/Config.in
Previous file: linux-2.4.19/drivers/media/video/w9966.c
Back to the patch index
Back to the overall index
- Lines: 66
- Date:
Fri Aug 2 17:39:44 2002
- Orig file:
linux-2.4.18/drivers/media/video/zr36067.c
- Orig date:
Mon Feb 25 11:37:58 2002
diff -urN linux-2.4.18/drivers/media/video/zr36067.c linux-2.4.19/drivers/media/video/zr36067.c
@@ -3265,7 +3265,10 @@
btwrite(IRQ_MASK, ZR36057_ISR); // Clears interrupts
btor(ZR36057_ICR_IntPinEn, ZR36057_ICR);
- dev->busy = 0; /* Allow second open */
+ /* FIXME: Don't do it this way, use the
+ * video_device->fops registration for a sane
+ * implementation of multiple opens */
+ dev->users--; /* Allow second open */
}
break;
@@ -3323,6 +3326,7 @@
}
}
+ dev->users++;
zr->user--;
MOD_DEC_USE_COUNT;
@@ -4205,9 +4209,7 @@
/* sleep 1 second */
- timeout = jiffies + 1 * HZ;
- while (jiffies < timeout)
- schedule();
+ schedule_timeout(HZ);
/* Get status of video decoder */
@@ -4397,22 +4399,18 @@
}
static struct video_device zoran_template = {
- THIS_MODULE,
- ZORAN_NAME,
- VID_TYPE_CAPTURE | VID_TYPE_OVERLAY | VID_TYPE_CLIPPING |
- VID_TYPE_FRAMERAM | VID_TYPE_SCALES | VID_TYPE_SUBCAPTURE,
- ZORAN_HARDWARE,
- zoran_open,
- zoran_close,
- zoran_read,
- zoran_write,
- NULL,
- zoran_ioctl,
- zoran_mmap,
- zoran_init_done,
- NULL,
- 0,
- 0
+ owner: THIS_MODULE,
+ name: ZORAN_NAME,
+ type: VID_TYPE_CAPTURE | VID_TYPE_OVERLAY | VID_TYPE_CLIPPING |
+ VID_TYPE_FRAMERAM | VID_TYPE_SCALES | VID_TYPE_SUBCAPTURE,
+ hardware: ZORAN_HARDWARE,
+ open: zoran_open,
+ close: zoran_close,
+ read: zoran_read,
+ write: zoran_write,
+ ioctl: zoran_ioctl,
+ mmap: zoran_mmap,
+ initialize: zoran_init_done,
};
/*
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)