• Home
  • Raw
  • Download

Lines Matching refs:btv

47 bttv_risc_packed(struct bttv *btv, struct btcx_riscmem *risc,  in bttv_risc_packed()  argument
66 if ((rc = btcx_riscmem_alloc(btv->c.pci,risc,instructions)) < 0) in bttv_risc_packed()
82 if ((btv->opt_vcr_hack) && in bttv_risc_packed()
126 bttv_risc_planar(struct bttv *btv, struct btcx_riscmem *risc, in bttv_risc_planar() argument
149 if ((rc = btcx_riscmem_alloc(btv->c.pci,risc,instructions*4*5)) < 0) in bttv_risc_planar()
162 if ((btv->opt_vcr_hack) && in bttv_risc_planar()
246 bttv_risc_overlay(struct bttv *btv, struct btcx_riscmem *risc, in bttv_risc_overlay() argument
266 if ((rc = btcx_riscmem_alloc(btv->c.pci,risc,dwords*4)) < 0) { in bttv_risc_overlay()
276 addr = (unsigned long)btv->fbuf.base; in bttv_risc_overlay()
277 addr += btv->fbuf.fmt.bytesperline * ov->w.top; in bttv_risc_overlay()
282 line++, addr += btv->fbuf.fmt.bytesperline) { in bttv_risc_overlay()
283 if ((btv->opt_vcr_hack) && in bttv_risc_overlay()
336 bttv_calc_geo_old(struct bttv *btv, struct bttv_geometry *geo, in bttv_calc_geo_old() argument
347 if (btv->input == btv->dig) { in bttv_calc_geo_old()
370 if (btv->opt_combfilter) { in bttv_calc_geo_old()
380 bttv_calc_geo (struct bttv * btv, in bttv_calc_geo() argument
397 || btv->input == btv->dig) { in bttv_calc_geo()
398 bttv_calc_geo_old(btv, geo, width, height, in bttv_calc_geo()
426 if (btv->opt_combfilter) { in bttv_calc_geo()
436 bttv_apply_geo(struct bttv *btv, struct bttv_geometry *geo, int odd) in bttv_apply_geo() argument
463 bttv_set_dma(struct bttv *btv, int override) in bttv_set_dma() argument
468 btv->cap_ctl = 0; in bttv_set_dma()
469 if (NULL != btv->curr.top) btv->cap_ctl |= 0x02; in bttv_set_dma()
470 if (NULL != btv->curr.bottom) btv->cap_ctl |= 0x01; in bttv_set_dma()
471 if (NULL != btv->cvbi) btv->cap_ctl |= 0x0c; in bttv_set_dma()
474 capctl |= (btv->cap_ctl & 0x03) ? 0x03 : 0x00; /* capture */ in bttv_set_dma()
475 capctl |= (btv->cap_ctl & 0x0c) ? 0x0c : 0x00; /* vbi data */ in bttv_set_dma()
479 btv->c.nr,capctl,btv->loop_irq, in bttv_set_dma()
480 btv->cvbi ? (unsigned long long)btv->cvbi->top.dma : 0, in bttv_set_dma()
481 btv->curr.top ? (unsigned long long)btv->curr.top->top.dma : 0, in bttv_set_dma()
482 btv->cvbi ? (unsigned long long)btv->cvbi->bottom.dma : 0, in bttv_set_dma()
483 btv->curr.bottom ? (unsigned long long)btv->curr.bottom->bottom.dma : 0); in bttv_set_dma()
486 if (btv->loop_irq) { in bttv_set_dma()
488 cmd |= (btv->loop_irq & 0x0f) << 16; in bttv_set_dma()
489 cmd |= (~btv->loop_irq & 0x0f) << 20; in bttv_set_dma()
491 if (btv->curr.frame_irq || btv->loop_irq || btv->cvbi) { in bttv_set_dma()
492 mod_timer(&btv->timeout, jiffies+BTTV_TIMEOUT); in bttv_set_dma()
494 del_timer(&btv->timeout); in bttv_set_dma()
496 btv->main.cpu[RISC_SLOT_LOOP] = cpu_to_le32(cmd); in bttv_set_dma()
500 if (btv->dma_on) in bttv_set_dma()
502 btwrite(btv->main.dma, BT848_RISC_STRT_ADD); in bttv_set_dma()
504 btv->dma_on = 1; in bttv_set_dma()
506 if (!btv->dma_on) in bttv_set_dma()
509 btv->dma_on = 0; in bttv_set_dma()
515 bttv_risc_init_main(struct bttv *btv) in bttv_risc_init_main() argument
519 if ((rc = btcx_riscmem_alloc(btv->c.pci,&btv->main,PAGE_SIZE)) < 0) in bttv_risc_init_main()
522 btv->c.nr, (unsigned long long)btv->main.dma); in bttv_risc_init_main()
524 btv->main.cpu[0] = cpu_to_le32(BT848_RISC_SYNC | BT848_RISC_RESYNC | in bttv_risc_init_main()
526 btv->main.cpu[1] = cpu_to_le32(0); in bttv_risc_init_main()
527 btv->main.cpu[2] = cpu_to_le32(BT848_RISC_JUMP); in bttv_risc_init_main()
528 btv->main.cpu[3] = cpu_to_le32(btv->main.dma + (4<<2)); in bttv_risc_init_main()
531 btv->main.cpu[4] = cpu_to_le32(BT848_RISC_JUMP); in bttv_risc_init_main()
532 btv->main.cpu[5] = cpu_to_le32(btv->main.dma + (6<<2)); in bttv_risc_init_main()
533 btv->main.cpu[6] = cpu_to_le32(BT848_RISC_JUMP); in bttv_risc_init_main()
534 btv->main.cpu[7] = cpu_to_le32(btv->main.dma + (8<<2)); in bttv_risc_init_main()
536 btv->main.cpu[8] = cpu_to_le32(BT848_RISC_SYNC | BT848_RISC_RESYNC | in bttv_risc_init_main()
538 btv->main.cpu[9] = cpu_to_le32(0); in bttv_risc_init_main()
541 btv->main.cpu[10] = cpu_to_le32(BT848_RISC_JUMP); in bttv_risc_init_main()
542 btv->main.cpu[11] = cpu_to_le32(btv->main.dma + (12<<2)); in bttv_risc_init_main()
543 btv->main.cpu[12] = cpu_to_le32(BT848_RISC_JUMP); in bttv_risc_init_main()
544 btv->main.cpu[13] = cpu_to_le32(btv->main.dma + (14<<2)); in bttv_risc_init_main()
547 btv->main.cpu[14] = cpu_to_le32(BT848_RISC_JUMP); in bttv_risc_init_main()
548 btv->main.cpu[15] = cpu_to_le32(btv->main.dma + (0<<2)); in bttv_risc_init_main()
554 bttv_risc_hook(struct bttv *btv, int slot, struct btcx_riscmem *risc, in bttv_risc_hook() argument
558 unsigned long next = btv->main.dma + ((slot+2) << 2); in bttv_risc_hook()
561 d2printk("%d: risc=%p slot[%d]=NULL\n", btv->c.nr, risc, slot); in bttv_risc_hook()
562 btv->main.cpu[slot+1] = cpu_to_le32(next); in bttv_risc_hook()
565 btv->c.nr, risc, slot, in bttv_risc_hook()
575 btv->main.cpu[slot+1] = cpu_to_le32(risc->dma); in bttv_risc_hook()
581 bttv_dma_free(struct videobuf_queue *q,struct bttv *btv, struct bttv_buffer *buf) in bttv_dma_free() argument
589 btcx_riscmem_free(btv->c.pci,&buf->bottom); in bttv_dma_free()
590 btcx_riscmem_free(btv->c.pci,&buf->top); in bttv_dma_free()
595 bttv_buffer_activate_vbi(struct bttv *btv, in bttv_buffer_activate_vbi() argument
640 bttv_risc_hook(btv, RISC_SLOT_O_VBI, top, top_irq_flags); in bttv_buffer_activate_vbi()
641 bttv_risc_hook(btv, RISC_SLOT_E_VBI, bottom, bottom_irq_flags); in bttv_buffer_activate_vbi()
647 bttv_buffer_activate_video(struct bttv *btv, in bttv_buffer_activate_video() argument
664 bttv_apply_geo(btv, &set->top->geo, 1); in bttv_buffer_activate_video()
665 bttv_apply_geo(btv, &set->bottom->geo,0); in bttv_buffer_activate_video()
666 bttv_risc_hook(btv, RISC_SLOT_O_FIELD, &set->top->top, in bttv_buffer_activate_video()
668 bttv_risc_hook(btv, RISC_SLOT_E_FIELD, &set->bottom->bottom, in bttv_buffer_activate_video()
678 bttv_apply_geo(btv, &set->top->geo,1); in bttv_buffer_activate_video()
679 bttv_apply_geo(btv, &set->top->geo,0); in bttv_buffer_activate_video()
680 bttv_risc_hook(btv, RISC_SLOT_O_FIELD, &set->top->top, in bttv_buffer_activate_video()
682 bttv_risc_hook(btv, RISC_SLOT_E_FIELD, NULL, 0); in bttv_buffer_activate_video()
689 bttv_apply_geo(btv, &set->bottom->geo,1); in bttv_buffer_activate_video()
690 bttv_apply_geo(btv, &set->bottom->geo,0); in bttv_buffer_activate_video()
691 bttv_risc_hook(btv, RISC_SLOT_O_FIELD, NULL, 0); in bttv_buffer_activate_video()
692 bttv_risc_hook(btv, RISC_SLOT_E_FIELD, &set->bottom->bottom, in bttv_buffer_activate_video()
697 bttv_risc_hook(btv, RISC_SLOT_O_FIELD, NULL, 0); in bttv_buffer_activate_video()
698 bttv_risc_hook(btv, RISC_SLOT_E_FIELD, NULL, 0); in bttv_buffer_activate_video()
707 bttv_buffer_risc(struct bttv *btv, struct bttv_buffer *buf) in bttv_buffer_risc() argument
713 btv->c.nr, v4l2_field_names[buf->vb.field], in bttv_buffer_risc()
721 bttv_calc_geo(btv,&buf->geo,buf->vb.width,buf->vb.height, in bttv_buffer_risc()
727 bttv_risc_packed(btv,&buf->top,dma->sglist, in bttv_buffer_risc()
733 bttv_risc_packed(btv,&buf->bottom,dma->sglist, in bttv_buffer_risc()
737 bttv_risc_packed(btv,&buf->top,dma->sglist, in bttv_buffer_risc()
739 bttv_risc_packed(btv,&buf->bottom,dma->sglist, in bttv_buffer_risc()
743 bttv_risc_packed(btv,&buf->top,dma->sglist, in bttv_buffer_risc()
745 bttv_risc_packed(btv,&buf->bottom,dma->sglist, in bttv_buffer_risc()
775 bttv_calc_geo(btv,&buf->geo,buf->vb.width, in bttv_buffer_risc()
778 bttv_risc_planar(btv, &buf->top, dma->sglist, in bttv_buffer_risc()
784 bttv_calc_geo(btv,&buf->geo,buf->vb.width, in bttv_buffer_risc()
787 bttv_risc_planar(btv, &buf->bottom, dma->sglist, in bttv_buffer_risc()
793 bttv_calc_geo(btv,&buf->geo,buf->vb.width, in bttv_buffer_risc()
799 bttv_risc_planar(btv,&buf->top, in bttv_buffer_risc()
806 bttv_risc_planar(btv,&buf->bottom, in bttv_buffer_risc()
816 bttv_calc_geo(btv,&buf->geo,buf->vb.width, in bttv_buffer_risc()
822 bttv_risc_planar(btv,&buf->top, in bttv_buffer_risc()
830 bttv_risc_planar(btv,&buf->bottom, in bttv_buffer_risc()
848 bttv_calc_geo(btv,&buf->geo,tvnorm->swidth,tvnorm->sheight, in bttv_buffer_risc()
850 bttv_risc_packed(btv, &buf->top, dma->sglist, in bttv_buffer_risc()
853 bttv_risc_packed(btv, &buf->bottom, dma->sglist, in bttv_buffer_risc()
867 bttv_overlay_risc(struct bttv *btv, in bttv_overlay_risc() argument
874 btv->c.nr, v4l2_field_names[buf->vb.field], in bttv_overlay_risc()
878 bttv_calc_geo(btv,&buf->geo,ov->w.width,ov->w.height, in bttv_overlay_risc()
885 bttv_risc_overlay(btv, &buf->top, fmt, ov, 0, 0); in bttv_overlay_risc()
888 bttv_risc_overlay(btv, &buf->bottom, fmt, ov, 0, 0); in bttv_overlay_risc()
891 bttv_risc_overlay(btv, &buf->top, fmt, ov, 0, 1); in bttv_overlay_risc()
892 bttv_risc_overlay(btv, &buf->bottom, fmt, ov, 1, 0); in bttv_overlay_risc()