Lines Matching refs:vpu_dev
19 struct vpu_device *vpu_dev = dev_get_drvdata(dev); in wave5_initialize_vpu() local
21 ret = mutex_lock_interruptible(&vpu_dev->hw_lock); in wave5_initialize_vpu()
25 if (wave5_vpu_is_init(vpu_dev)) { in wave5_initialize_vpu()
38 mutex_unlock(&vpu_dev->hw_lock); in wave5_initialize_vpu()
86 struct vpu_device *vpu_dev = dev_get_drvdata(dev); in wave5_vpu_get_version_info() local
88 ret = mutex_lock_interruptible(&vpu_dev->hw_lock); in wave5_vpu_get_version_info()
92 if (!wave5_vpu_is_init(vpu_dev)) { in wave5_vpu_get_version_info()
98 *product_id = vpu_dev->product; in wave5_vpu_get_version_info()
99 ret = wave5_vpu_get_version(vpu_dev, revision); in wave5_vpu_get_version_info()
102 mutex_unlock(&vpu_dev->hw_lock); in wave5_vpu_get_version_info()
135 struct vpu_device *vpu_dev = inst->dev; in wave5_vpu_dec_open() local
143 ret = mutex_lock_interruptible(&vpu_dev->hw_lock); in wave5_vpu_dec_open()
147 if (!wave5_vpu_is_init(vpu_dev)) { in wave5_vpu_dec_open()
148 mutex_unlock(&vpu_dev->hw_lock); in wave5_vpu_dec_open()
168 mutex_unlock(&vpu_dev->hw_lock); in wave5_vpu_dec_open()
196 struct vpu_device *vpu_dev = inst->dev; in wave5_vpu_dec_close() local
203 ret = mutex_lock_interruptible(&vpu_dev->hw_lock); in wave5_vpu_dec_close()
223 wave5_vdi_free_dma_memory(vpu_dev, &p_dec_info->vb_work); in wave5_vpu_dec_close()
233 wave5_vdi_free_dma_memory(vpu_dev, &p_dec_info->vb_task); in wave5_vpu_dec_close()
236 mutex_unlock(&vpu_dev->hw_lock); in wave5_vpu_dec_close()
244 struct vpu_device *vpu_dev = inst->dev; in wave5_vpu_dec_issue_seq_init() local
246 ret = mutex_lock_interruptible(&vpu_dev->hw_lock); in wave5_vpu_dec_issue_seq_init()
252 mutex_unlock(&vpu_dev->hw_lock); in wave5_vpu_dec_issue_seq_init()
261 struct vpu_device *vpu_dev = inst->dev; in wave5_vpu_dec_complete_seq_init() local
263 ret = mutex_lock_interruptible(&vpu_dev->hw_lock); in wave5_vpu_dec_complete_seq_init()
276 mutex_unlock(&vpu_dev->hw_lock); in wave5_vpu_dec_complete_seq_init()
286 struct vpu_device *vpu_dev = inst->dev; in wave5_vpu_dec_register_frame_buffer_ex() local
304 ret = mutex_lock_interruptible(&vpu_dev->hw_lock); in wave5_vpu_dec_register_frame_buffer_ex()
318 mutex_unlock(&vpu_dev->hw_lock); in wave5_vpu_dec_register_frame_buffer_ex()
330 struct vpu_device *vpu_dev = inst->dev; in wave5_vpu_dec_get_bitstream_buffer() local
335 ret = mutex_lock_interruptible(&vpu_dev->hw_lock); in wave5_vpu_dec_get_bitstream_buffer()
339 mutex_unlock(&vpu_dev->hw_lock); in wave5_vpu_dec_get_bitstream_buffer()
366 struct vpu_device *vpu_dev = inst->dev; in wave5_vpu_dec_update_bitstream_buffer() local
394 ret = mutex_lock_interruptible(&vpu_dev->hw_lock); in wave5_vpu_dec_update_bitstream_buffer()
398 mutex_unlock(&vpu_dev->hw_lock); in wave5_vpu_dec_update_bitstream_buffer()
407 struct vpu_device *vpu_dev = inst->dev; in wave5_vpu_dec_start_one_frame() local
412 ret = mutex_lock_interruptible(&vpu_dev->hw_lock); in wave5_vpu_dec_start_one_frame()
418 mutex_unlock(&vpu_dev->hw_lock); in wave5_vpu_dec_start_one_frame()
427 struct vpu_device *vpu_dev = inst->dev; in wave5_vpu_dec_set_rd_ptr() local
429 ret = mutex_lock_interruptible(&vpu_dev->hw_lock); in wave5_vpu_dec_set_rd_ptr()
439 mutex_unlock(&vpu_dev->hw_lock); in wave5_vpu_dec_set_rd_ptr()
469 struct vpu_device *vpu_dev = inst->dev; in wave5_vpu_dec_get_output_info() local
477 ret = mutex_lock_interruptible(&vpu_dev->hw_lock); in wave5_vpu_dec_get_output_info()
538 p_dec_info->frame_display_flag = vpu_read_reg(vpu_dev, W5_RET_DEC_DISP_IDC); in wave5_vpu_dec_get_output_info()
567 mutex_unlock(&vpu_dev->hw_lock); in wave5_vpu_dec_get_output_info()
576 struct vpu_device *vpu_dev = inst->dev; in wave5_vpu_dec_clr_disp_flag() local
581 ret = mutex_lock_interruptible(&vpu_dev->hw_lock); in wave5_vpu_dec_clr_disp_flag()
585 mutex_unlock(&vpu_dev->hw_lock); in wave5_vpu_dec_clr_disp_flag()
594 struct vpu_device *vpu_dev = inst->dev; in wave5_vpu_dec_set_disp_flag() local
599 ret = mutex_lock_interruptible(&vpu_dev->hw_lock); in wave5_vpu_dec_set_disp_flag()
603 mutex_unlock(&vpu_dev->hw_lock); in wave5_vpu_dec_set_disp_flag()
670 struct vpu_device *vpu_dev = inst->dev; in wave5_vpu_enc_open() local
676 ret = mutex_lock_interruptible(&vpu_dev->hw_lock); in wave5_vpu_enc_open()
680 if (!wave5_vpu_is_init(vpu_dev)) { in wave5_vpu_enc_open()
681 mutex_unlock(&vpu_dev->hw_lock); in wave5_vpu_enc_open()
688 ret = wave5_vpu_build_up_enc_param(vpu_dev->dev, inst, open_param); in wave5_vpu_enc_open()
689 mutex_unlock(&vpu_dev->hw_lock); in wave5_vpu_enc_open()
699 struct vpu_device *vpu_dev = inst->dev; in wave5_vpu_enc_close() local
705 ret = mutex_lock_interruptible(&vpu_dev->hw_lock); in wave5_vpu_enc_close()
713 mutex_unlock(&vpu_dev->hw_lock); in wave5_vpu_enc_close()
719 mutex_unlock(&vpu_dev->hw_lock); in wave5_vpu_enc_close()
726 wave5_vdi_free_dma_memory(vpu_dev, &p_enc_info->vb_work); in wave5_vpu_enc_close()
729 wave5_vdi_free_dma_memory(vpu_dev, &p_enc_info->vb_sub_sam_buf); in wave5_vpu_enc_close()
730 wave5_vdi_free_dma_memory(vpu_dev, &p_enc_info->vb_mv); in wave5_vpu_enc_close()
731 wave5_vdi_free_dma_memory(vpu_dev, &p_enc_info->vb_fbc_y_tbl); in wave5_vpu_enc_close()
732 wave5_vdi_free_dma_memory(vpu_dev, &p_enc_info->vb_fbc_c_tbl); in wave5_vpu_enc_close()
735 wave5_vdi_free_dma_memory(vpu_dev, &p_enc_info->vb_task); in wave5_vpu_enc_close()
737 mutex_unlock(&vpu_dev->hw_lock); in wave5_vpu_enc_close()
748 struct vpu_device *vpu_dev = inst->dev; in wave5_vpu_enc_register_frame_buffer() local
767 ret = mutex_lock_interruptible(&vpu_dev->hw_lock); in wave5_vpu_enc_register_frame_buffer()
795 mutex_unlock(&vpu_dev->hw_lock); in wave5_vpu_enc_register_frame_buffer()
824 struct vpu_device *vpu_dev = inst->dev; in wave5_vpu_enc_start_one_frame() local
835 ret = mutex_lock_interruptible(&vpu_dev->hw_lock); in wave5_vpu_enc_start_one_frame()
843 mutex_unlock(&vpu_dev->hw_lock); in wave5_vpu_enc_start_one_frame()
852 struct vpu_device *vpu_dev = inst->dev; in wave5_vpu_enc_get_output_info() local
854 ret = mutex_lock_interruptible(&vpu_dev->hw_lock); in wave5_vpu_enc_get_output_info()
868 mutex_unlock(&vpu_dev->hw_lock); in wave5_vpu_enc_get_output_info()
921 struct vpu_device *vpu_dev = inst->dev; in wave5_vpu_enc_issue_seq_init() local
923 ret = mutex_lock_interruptible(&vpu_dev->hw_lock); in wave5_vpu_enc_issue_seq_init()
929 mutex_unlock(&vpu_dev->hw_lock); in wave5_vpu_enc_issue_seq_init()
938 struct vpu_device *vpu_dev = inst->dev; in wave5_vpu_enc_complete_seq_init() local
943 ret = mutex_lock_interruptible(&vpu_dev->hw_lock); in wave5_vpu_enc_complete_seq_init()
950 mutex_unlock(&vpu_dev->hw_lock); in wave5_vpu_enc_complete_seq_init()
957 mutex_unlock(&vpu_dev->hw_lock); in wave5_vpu_enc_complete_seq_init()