Lines Matching refs:task
154 MPP_RET hal_jpege_vepu2_get_task(void *hal, HalEncTask *task) in hal_jpege_vepu2_get_task() argument
157 JpegeSyntax *syntax = (JpegeSyntax *)task->syntax.data; in hal_jpege_vepu2_get_task()
165 ctx->hal_start_pos = mpp_packet_get_length(task->packet); in hal_jpege_vepu2_get_task()
175 task->part_first = 1; in hal_jpege_vepu2_get_task()
176 task->part_last = 0; in hal_jpege_vepu2_get_task()
177 task->flags.reg_idx = 0; in hal_jpege_vepu2_get_task()
181 task->flags.reg_idx = ctx->task_idx++; in hal_jpege_vepu2_get_task()
330 task->rc_task->frm.is_intra = 1; in hal_jpege_vepu2_get_task()
366 MPP_RET hal_jpege_vepu2_gen_regs(void *hal, HalEncTask *task) in hal_jpege_vepu2_gen_regs() argument
369 MppBuffer input = task->input; in hal_jpege_vepu2_gen_regs()
370 MppBuffer output = task->output; in hal_jpege_vepu2_gen_regs()
379 RK_S32 reg_idx = task->flags.reg_idx; in hal_jpege_vepu2_gen_regs()
381 size_t length = mpp_packet_get_length(task->packet); in hal_jpege_vepu2_gen_regs()
427 syntax->q_factor = 100 - task->rc_task->info.quality_target; in hal_jpege_vepu2_gen_regs()
580 static MPP_RET multi_core_start(HalJpegeCtx *ctx, HalEncTask *task) in multi_core_start() argument
586 RK_S32 reg_idx = task->flags.reg_idx; in multi_core_start()
624 regs[77] = mpp_buffer_get_fd(task->output); in multi_core_start()
625 regs[53] = mpp_buffer_get_size(task->output) - part_bytepos; in multi_core_start()
738 static MPP_RET multi_core_wait(HalJpegeCtx *ctx, HalEncTask *task) in multi_core_wait() argument
760 RK_S32 fd = mpp_buffer_get_fd(task->output); in multi_core_wait()
770 task->length = feedback->stream_length; in multi_core_wait()
771 task->hw_length = task->length - ctx->hal_start_pos; in multi_core_wait()
773 mpp_dmabuf_sync_partial_begin(fd, 1, 0, task->length, __FUNCTION__); in multi_core_wait()
775 void *stream_ptr = mpp_buffer_get_ptr(task->output); in multi_core_wait()
790 task->length = feedback->stream_length; in multi_core_wait()
791 task->hw_length += partion_len; in multi_core_wait()
796 sw_bit, hw_bit, feedback->stream_length, task->hw_length); in multi_core_wait()
801 MPP_RET hal_jpege_vepu2_start(void *hal, HalEncTask *task) in hal_jpege_vepu2_start() argument
810 multi_core_start(ctx, task); in hal_jpege_vepu2_start()
817 RK_S32 reg_idx = task->flags.reg_idx; in hal_jpege_vepu2_start()
848 (void)task; in hal_jpege_vepu2_start()
852 MPP_RET hal_jpege_vepu2_wait(void *hal, HalEncTask *task) in hal_jpege_vepu2_wait() argument
861 multi_core_wait(ctx, task); in hal_jpege_vepu2_wait()
865 RK_S32 reg_idx = task->flags.reg_idx; in hal_jpege_vepu2_wait()
887 task->length = feedback->stream_length; in hal_jpege_vepu2_wait()
888 task->hw_length = task->length - ctx->hal_start_pos; in hal_jpege_vepu2_wait()
891 sw_bit, hw_bit, feedback->stream_length, task->hw_length); in hal_jpege_vepu2_wait()
898 MPP_RET hal_jpege_vepu2_part_start(void *hal, HalEncTask *task) in hal_jpege_vepu2_part_start() argument
902 JpegeSyntax *syntax = (JpegeSyntax *)task->syntax.data; in hal_jpege_vepu2_part_start()
907 RK_S32 reg_idx = task->flags.reg_idx; in hal_jpege_vepu2_part_start()
917 task->part_first = !mcu_y; in hal_jpege_vepu2_part_start()
923 task->part_last = 0; in hal_jpege_vepu2_part_start()
929 task->part_last = 1; in hal_jpege_vepu2_part_start()
932 hal_jpege_dbg_detail("part first %d last %d\n", task->part_first, task->part_last); in hal_jpege_vepu2_part_start()
942 regs[77] = mpp_buffer_get_fd(task->output); in hal_jpege_vepu2_part_start()
993 (void)task; in hal_jpege_vepu2_part_start()
997 MPP_RET hal_jpege_vepu2_part_wait(void *hal, HalEncTask *task) in hal_jpege_vepu2_part_wait() argument
1001 RK_S32 reg_idx = task->flags.reg_idx; in hal_jpege_vepu2_part_wait()
1023 task->length = ctx->part_bytepos; in hal_jpege_vepu2_part_wait()
1024 task->hw_length = task->length - ctx->hal_start_pos; in hal_jpege_vepu2_part_wait()
1030 ctx->sw_bit, hw_bit, feedback->stream_length, task->hw_length); in hal_jpege_vepu2_part_wait()
1036 MPP_RET hal_jpege_vepu2_ret_task(void *hal, HalEncTask *task) in hal_jpege_vepu2_ret_task() argument
1039 EncRcTaskInfo *rc_info = &task->rc_task->info; in hal_jpege_vepu2_ret_task()
1041 task->rc_task->info.bit_real = ctx->feedback.stream_length * 8; in hal_jpege_vepu2_ret_task()
1042 task->hal_ret.data = &ctx->feedback; in hal_jpege_vepu2_ret_task()
1043 task->hal_ret.number = 1; in hal_jpege_vepu2_ret_task()