Lines Matching full:vcd
3 * Driver for Video Capture/Differentiation Engine (VCD) and Encoding
69 * VIDEO_CAPTURING: a flag indicating if the VCD is capturing a frame
506 struct regmap *vcd = video->vcd_regmap; in npcm_video_build_table() local
511 regmap_read(vcd, VCD_DIFF_TBL + (j + info->index), &value); in npcm_video_build_table()
600 struct regmap *vcd = video->vcd_regmap; in npcm_video_capres() local
609 regmap_write(vcd, VCD_CAP_RES, res); in npcm_video_capres()
610 regmap_read(vcd, VCD_CAP_RES, &cap_res); in npcm_video_capres()
632 struct regmap *vcd = video->vcd_regmap; in npcm_video_vcd_state_machine_reset() local
634 regmap_update_bits(vcd, VCD_MODE, VCD_MODE_VCDE, 0); in npcm_video_vcd_state_machine_reset()
635 regmap_update_bits(vcd, VCD_MODE, VCD_MODE_IDBC, 0); in npcm_video_vcd_state_machine_reset()
636 regmap_update_bits(vcd, VCD_CMD, VCD_CMD_RST, VCD_CMD_RST); in npcm_video_vcd_state_machine_reset()
639 * VCD_CMD_RST will reset VCD internal state machines and clear FIFOs, in npcm_video_vcd_state_machine_reset()
644 regmap_write(vcd, VCD_STAT, VCD_STAT_CLEAR); in npcm_video_vcd_state_machine_reset()
645 regmap_update_bits(vcd, VCD_MODE, VCD_MODE_VCDE, VCD_MODE_VCDE); in npcm_video_vcd_state_machine_reset()
646 regmap_update_bits(vcd, VCD_MODE, VCD_MODE_IDBC, VCD_MODE_IDBC); in npcm_video_vcd_state_machine_reset()
660 struct regmap *vcd = video->vcd_regmap; in npcm_video_kvm_bw() local
663 regmap_update_bits(vcd, VCD_MODE, VCD_MODE_KVM_BW_SET, in npcm_video_kvm_bw()
666 regmap_update_bits(vcd, VCD_MODE, VCD_MODE_KVM_BW_SET, 0); in npcm_video_kvm_bw()
717 struct regmap *vcd = video->vcd_regmap; in npcm_video_set_linepitch() local
723 regmap_write(vcd, VCD_FB_LP, FIELD_PREP(VCD_FBA_LP, pitch) | in npcm_video_set_linepitch()
729 struct regmap *vcd = video->vcd_regmap; in npcm_video_get_linepitch() local
732 regmap_read(vcd, VCD_FB_LP, &linepitch); in npcm_video_get_linepitch()
738 struct regmap *vcd = video->vcd_regmap; in npcm_video_command() local
741 regmap_write(vcd, VCD_STAT, VCD_STAT_CLEAR); in npcm_video_command()
742 regmap_read(vcd, VCD_CMD, &cmd); in npcm_video_command()
745 regmap_write(vcd, VCD_CMD, cmd); in npcm_video_command()
746 regmap_update_bits(vcd, VCD_CMD, VCD_CMD_GO, VCD_CMD_GO); in npcm_video_command()
752 struct regmap *gcr = video->gcr_regmap, *vcd = video->vcd_regmap; in npcm_video_init_reg() local
769 regmap_write(vcd, VCD_FIFO, VCD_FIFO_TH); in npcm_video_init_reg()
772 regmap_write(vcd, VCD_RCHG, FIELD_PREP(VCD_RCHG_TIM_PRSCL, 0xf) | in npcm_video_init_reg()
776 regmap_write(vcd, VCD_MODE, VCD_MODE_VCDE | VCD_MODE_CM565 | in npcm_video_init_reg()
783 struct regmap *vcd = video->vcd_regmap; in npcm_video_start_frame() local
792 ret = regmap_read_poll_timeout(vcd, VCD_STAT, val, !(val & VCD_STAT_BUSY), in npcm_video_start_frame()
813 regmap_read(vcd, VCD_HOR_AC_TIM, &val); in npcm_video_start_frame()
814 regmap_update_bits(vcd, VCD_HOR_AC_LST, VCD_HOR_AC_LAST, in npcm_video_start_frame()
817 regmap_read(vcd, VCD_VER_HI_TIM, &val); in npcm_video_start_frame()
818 regmap_update_bits(vcd, VCD_VER_HI_LST, VCD_VER_HI_LAST, in npcm_video_start_frame()
821 regmap_update_bits(vcd, VCD_INTE, VCD_INTE_DONE_IE | VCD_INTE_IFOT_IE | in npcm_video_start_frame()
906 struct regmap *vcd = video->vcd_regmap; in npcm_video_set_resolution() local
926 regmap_read(vcd, VCD_MODE, &mode); in npcm_video_set_resolution()
928 dev_dbg(video->dev, "VCD mode = 0x%x, %s mode\n", mode, in npcm_video_set_resolution()
944 dev_err(video->dev, "Failed to allocate VCD frame buffer\n"); in npcm_video_start()
971 struct regmap *vcd = video->vcd_regmap; in npcm_video_stop() local
975 regmap_write(vcd, VCD_INTE, 0); in npcm_video_stop()
976 regmap_write(vcd, VCD_MODE, 0); in npcm_video_stop()
977 regmap_write(vcd, VCD_RCHG, 0); in npcm_video_stop()
978 regmap_write(vcd, VCD_STAT, VCD_STAT_CLEAR); in npcm_video_stop()
1050 struct regmap *vcd = video->vcd_regmap; in npcm_video_irq() local
1060 regmap_read(vcd, VCD_STAT, &status); in npcm_video_irq()
1061 dev_dbg(video->dev, "VCD irq status 0x%x\n", status); in npcm_video_irq()
1063 regmap_write(vcd, VCD_STAT, VCD_STAT_CLEAR); in npcm_video_irq()
1070 regmap_write(vcd, VCD_INTE, 0); in npcm_video_irq()
1121 dev_warn(video->dev, "VCD FIFO overrun or over thresholds\n"); in npcm_video_irq()
1492 struct regmap *vcd = video->vcd_regmap; in npcm_video_stop_streaming() local
1495 regmap_write(vcd, VCD_INTE, 0); in npcm_video_stop_streaming()
1496 regmap_write(vcd, VCD_STAT, VCD_STAT_CLEAR); in npcm_video_stop_streaming()
1706 dev_err(dev, "Failed to find VCD IRQ\n"); in npcm_video_init()
1749 dev_err(&pdev->dev, "Failed to parse VCD reg in DTS\n"); in npcm_video_probe()
1756 dev_err(&pdev->dev, "Failed to initialize VCD regmap\n"); in npcm_video_probe()
1762 dev_err(&pdev->dev, "Failed to get VCD reset control in DTS\n"); in npcm_video_probe()
1804 { .compatible = "nuvoton,npcm750-vcd" },
1805 { .compatible = "nuvoton,npcm845-vcd" },