• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /netgear-R7000-V1.0.7.12_1.2.5/components/opensource/linux/linux-2.6.36/drivers/media/video/au0828/

Lines Matching refs:fh

648 	struct au0828_fh *fh = vq->priv_data;
649 *size = (fh->dev->width * fh->dev->height * 16 + 7) >> 3;
662 struct au0828_fh *fh = vq->priv_data;
663 struct au0828_dev *dev = fh->dev;
690 struct au0828_fh *fh = vq->priv_data;
692 struct au0828_dev *dev = fh->dev;
695 buf->vb.size = (fh->dev->width * fh->dev->height * 16 + 7) >> 3;
739 struct au0828_fh *fh = vq->priv_data;
740 struct au0828_dev *dev = fh->dev;
851 static int res_get(struct au0828_fh *fh, unsigned int bit)
853 struct au0828_dev *dev = fh->dev;
855 if (fh->resources & bit)
867 fh->resources |= bit;
874 static int res_check(struct au0828_fh *fh, unsigned int bit)
876 return fh->resources & bit;
884 static void res_free(struct au0828_fh *fh, unsigned int bits)
886 struct au0828_dev *dev = fh->dev;
888 BUG_ON((fh->resources & bits) != bits);
891 fh->resources &= ~bits;
897 static int get_ressource(struct au0828_fh *fh)
899 switch (fh->type) {
915 struct au0828_fh *fh;
929 fh = kzalloc(sizeof(struct au0828_fh), GFP_KERNEL);
930 if (NULL == fh) {
935 fh->type = type;
936 fh->dev = dev;
937 filp->private_data = fh;
939 if (fh->type == V4L2_BUF_TYPE_VIDEO_CAPTURE && dev->users == 0) {
964 videobuf_queue_vmalloc_init(&fh->vb_vidq, &au0828_video_qops,
968 sizeof(struct au0828_buffer), fh);
973 videobuf_queue_vmalloc_init(&fh->vb_vbiq, &au0828_vbi_qops,
977 sizeof(struct au0828_buffer), fh);
986 struct au0828_fh *fh = filp->private_data;
987 struct au0828_dev *dev = fh->dev;
989 if (res_check(fh, AU0828_RESOURCE_VIDEO)) {
990 videobuf_stop(&fh->vb_vidq);
991 res_free(fh, AU0828_RESOURCE_VIDEO);
994 if (res_check(fh, AU0828_RESOURCE_VBI)) {
995 videobuf_stop(&fh->vb_vbiq);
996 res_free(fh, AU0828_RESOURCE_VBI);
1020 videobuf_mmap_free(&fh->vb_vidq);
1021 videobuf_mmap_free(&fh->vb_vbiq);
1022 kfree(fh);
1031 struct au0828_fh *fh = filp->private_data;
1032 struct au0828_dev *dev = fh->dev;
1039 if (fh->type == V4L2_BUF_TYPE_VIDEO_CAPTURE) {
1043 return videobuf_read_stream(&fh->vb_vidq, buf, count, pos, 0,
1047 if (fh->type == V4L2_BUF_TYPE_VBI_CAPTURE) {
1048 if (!res_get(fh, AU0828_RESOURCE_VBI))
1051 return videobuf_read_stream(&fh->vb_vbiq, buf, count, pos, 0,
1060 struct au0828_fh *fh = filp->private_data;
1061 struct au0828_dev *dev = fh->dev;
1068 if (fh->type == V4L2_BUF_TYPE_VIDEO_CAPTURE) {
1069 if (!res_get(fh, AU0828_RESOURCE_VIDEO))
1071 return videobuf_poll_stream(filp, &fh->vb_vidq, wait);
1072 } else if (fh->type == V4L2_BUF_TYPE_VBI_CAPTURE) {
1073 if (!res_get(fh, AU0828_RESOURCE_VBI))
1075 return videobuf_poll_stream(filp, &fh->vb_vbiq, wait);
1083 struct au0828_fh *fh = filp->private_data;
1084 struct au0828_dev *dev = fh->dev;
1091 if (fh->type == V4L2_BUF_TYPE_VIDEO_CAPTURE)
1092 rc = videobuf_mmap_mapper(&fh->vb_vidq, vma);
1093 else if (fh->type == V4L2_BUF_TYPE_VBI_CAPTURE)
1094 rc = videobuf_mmap_mapper(&fh->vb_vbiq, vma);
1167 struct au0828_fh *fh = priv;
1168 struct au0828_dev *dev = fh->dev;
1179 struct au0828_fh *fh = priv;
1180 struct au0828_dev *dev = fh->dev;
1216 struct au0828_fh *fh = priv;
1217 struct au0828_dev *dev = fh->dev;
1232 struct au0828_fh *fh = priv;
1233 struct au0828_dev *dev = fh->dev;
1241 struct au0828_fh *fh = priv;
1242 struct au0828_dev *dev = fh->dev;
1251 if (videobuf_queue_is_busy(&fh->vb_vidq)) {
1265 struct au0828_fh *fh = priv;
1266 struct au0828_dev *dev = fh->dev;
1276 struct au0828_fh *fh = priv;
1277 struct au0828_dev *dev = fh->dev;
1312 struct au0828_fh *fh = priv;
1313 struct au0828_dev *dev = fh->dev;
1320 struct au0828_fh *fh = priv;
1321 struct au0828_dev *dev = fh->dev;
1379 struct au0828_fh *fh = priv;
1380 struct au0828_dev *dev = fh->dev;
1399 struct au0828_fh *fh = priv;
1400 struct au0828_dev *dev = fh->dev;
1409 struct au0828_fh *fh = priv;
1410 struct au0828_dev *dev = fh->dev;
1420 struct au0828_fh *fh = priv;
1421 struct au0828_dev *dev = fh->dev;
1428 struct au0828_fh *fh = priv;
1429 struct au0828_dev *dev = fh->dev;
1442 struct au0828_fh *fh = priv;
1443 struct au0828_dev *dev = fh->dev;
1459 struct au0828_fh *fh = priv;
1460 struct au0828_dev *dev = fh->dev;
1470 struct au0828_fh *fh = priv;
1471 struct au0828_dev *dev = fh->dev;
1493 struct au0828_fh *fh = priv;
1494 struct au0828_dev *dev = fh->dev;
1513 struct au0828_fh *fh = priv;
1514 struct au0828_dev *dev = fh->dev;
1533 struct au0828_fh *fh = priv;
1534 struct au0828_dev *dev = fh->dev;
1555 struct au0828_fh *fh = priv;
1556 struct au0828_dev *dev = fh->dev;
1563 if (unlikely(type != fh->type))
1566 dprintk(1, "vidioc_streamon fh=%p t=%d fh->res=%d dev->res=%d\n",
1567 fh, type, fh->resources, dev->resources);
1569 if (unlikely(!res_get(fh, get_ressource(fh))))
1577 if (fh->type == V4L2_BUF_TYPE_VIDEO_CAPTURE)
1578 rc = videobuf_streamon(&fh->vb_vidq);
1579 else if (fh->type == V4L2_BUF_TYPE_VBI_CAPTURE)
1580 rc = videobuf_streamon(&fh->vb_vbiq);
1588 struct au0828_fh *fh = priv;
1589 struct au0828_dev *dev = fh->dev;
1597 if (fh->type != V4L2_BUF_TYPE_VIDEO_CAPTURE &&
1598 fh->type != V4L2_BUF_TYPE_VBI_CAPTURE)
1600 if (type != fh->type)
1603 dprintk(1, "vidioc_streamoff fh=%p t=%d fh->res=%d dev->res=%d\n",
1604 fh, type, fh->resources, dev->resources);
1606 if (fh->type == V4L2_BUF_TYPE_VIDEO_CAPTURE) {
1618 videobuf_streamoff(&fh->vb_vidq);
1619 res_free(fh, AU0828_RESOURCE_VIDEO);
1620 } else if (fh->type == V4L2_BUF_TYPE_VBI_CAPTURE) {
1621 videobuf_streamoff(&fh->vb_vbiq);
1622 res_free(fh, AU0828_RESOURCE_VBI);
1632 struct au0828_fh *fh = priv;
1633 struct au0828_dev *dev = fh->dev;
1647 struct au0828_fh *fh = priv;
1648 struct au0828_dev *dev = fh->dev;
1664 struct au0828_fh *fh = priv;
1665 struct au0828_dev *dev = fh->dev;
1672 return videobuf_reqbufs(&fh->vb_vidq, rb);
1678 struct au0828_fh *fh = priv;
1679 struct au0828_dev *dev = fh->dev;
1686 return videobuf_querybuf(&fh->vb_vidq, b);
1691 struct au0828_fh *fh = priv;
1692 struct au0828_dev *dev = fh->dev;
1699 return videobuf_qbuf(&fh->vb_vidq, b);
1704 struct au0828_fh *fh = priv;
1705 struct au0828_dev *dev = fh->dev;
1718 return videobuf_dqbuf(&fh->vb_vidq, b, file->f_flags & O_NONBLOCK);
1724 struct au0828_fh *fh = priv;
1726 return videobuf_cgmbuf(&fh->vb_vidq, mbuf, 8);