Loading drivers/media/platform/msm/vidc/hfi_response_handler.c +10 −0 Original line number Diff line number Diff line Loading @@ -1032,6 +1032,7 @@ static int hfi_process_session_etb_done(u32 device_id, struct msm_vidc_cb_info *info) { struct msm_vidc_cb_data_done data_done = {0}; struct hfi_picture_type *hfi_picture_type = NULL; dprintk(VIDC_DBG, "RECEIVED: SESSION_ETB_DONE[%#x]\n", pkt->session_id); Loading @@ -1055,6 +1056,15 @@ static int hfi_process_session_etb_done(u32 device_id, (ion_phys_addr_t)pkt->extra_data_buffer; data_done.input_done.status = hfi_map_err_status(pkt->error_type); hfi_picture_type = (struct hfi_picture_type *)&pkt->rgData[0]; if (hfi_picture_type->is_sync_frame) { if (hfi_picture_type->picture_type) data_done.input_done.flags = hfi_picture_type->picture_type; else dprintk(VIDC_DBG, "Non-Sync frame sent for H264/HEVC\n"); } trace_msm_v4l2_vidc_buffer_event_end("ETB", (u32)pkt->packet_buffer, -1, -1, Loading drivers/media/platform/msm/vidc/msm_smem.c +1 −0 Original line number Diff line number Diff line Loading @@ -100,6 +100,7 @@ static int get_device_address(struct smem_client *smem_client, if (rc != table->nents) { dprintk(VIDC_ERR, "dma_map_sg failed! (%d != %d)\n", rc, table->nents); rc = -ENOMEM; goto mem_map_sg_failed; } if (table->sgl) { Loading drivers/media/platform/msm/vidc/msm_vdec.c +13 −7 Original line number Diff line number Diff line Loading @@ -167,12 +167,12 @@ static struct msm_vidc_ctrl msm_vdec_ctrls[] = { .qmenu = mpeg_video_output_order, }, { .id = V4L2_CID_MPEG_VIDC_VIDEO_ENABLE_PICTURE_TYPE, .id = V4L2_CID_MPEG_VIDC_VIDEO_PICTYPE_DEC_MODE, .name = "Picture Type Decoding", .type = V4L2_CTRL_TYPE_INTEGER, .minimum = 1, .maximum = 15, .default_value = 15, .type = V4L2_CTRL_TYPE_BOOLEAN, .minimum = 0, .maximum = 1, .default_value = 0, .step = 1, .menu_skip_mask = 0, .qmenu = NULL, Loading Loading @@ -2130,9 +2130,15 @@ static int try_set_ctrl(struct msm_vidc_inst *inst, struct v4l2_ctrl *ctrl) property_val = ctrl->val; pdata = &property_val; break; case V4L2_CID_MPEG_VIDC_VIDEO_ENABLE_PICTURE_TYPE: case V4L2_CID_MPEG_VIDC_VIDEO_PICTYPE_DEC_MODE: property_id = HAL_PARAM_VDEC_PICTURE_TYPE_DECODE; enable_picture.picture_type = ctrl->val; if (ctrl->val == V4L2_MPEG_VIDC_VIDEO_PICTYPE_DECODE_ON) enable_picture.picture_type = HAL_PICTURE_I; else enable_picture.picture_type = HAL_PICTURE_I | HAL_PICTURE_P | HAL_PICTURE_B | HAL_PICTURE_IDR; pdata = &enable_picture; break; case V4L2_CID_MPEG_VIDC_VIDEO_KEEP_ASPECT_RATIO: Loading drivers/media/platform/msm/vidc/msm_vidc_common.c +18 −4 Original line number Diff line number Diff line Loading @@ -1441,6 +1441,10 @@ static void handle_ebd(enum hal_command_response cmd, void *data) dprintk(VIDC_INFO, "Failed: Start code not found\n"); } if (empty_buf_done->flags & HAL_BUFFERFLAG_SYNCFRAME) vb->v4l2_buf.flags |= V4L2_QCOM_BUF_FLAG_IDRFRAME | V4L2_BUF_FLAG_KEYFRAME; } dprintk(VIDC_DBG, "Got ebd from hal: device_addr: %pa, alloc: %d, status: %#x, pic_type: %#x, flags: %#x\n", Loading Loading @@ -1748,12 +1752,13 @@ static void handle_fbd(enum hal_command_response cmd, void *data) vb->v4l2_planes[extra_idx].length); } dprintk(VIDC_DBG, "Got fbd from hal: device_addr: %pa, alloc: %d, filled: %d, offset: %d, ts: %lld, flags: %#x, crop: %d %d %d %d, pic_type: %#x\n", "Got fbd from hal: device_addr: %pa, alloc: %d, filled: %d, offset: %d, ts: %lld, flags: %#x, crop: %d %d %d %d, pic_type: %#x, mark_data: %d\n", &fill_buf_done->packet_buffer1, fill_buf_done->alloc_len1, fill_buf_done->filled_len1, fill_buf_done->offset1, time_usec, fill_buf_done->flags1, fill_buf_done->start_x_coord, fill_buf_done->start_y_coord, fill_buf_done->frame_width, fill_buf_done->frame_height, fill_buf_done->picture_type); fill_buf_done->frame_height, fill_buf_done->picture_type, fill_buf_done->mark_data); mutex_lock(&inst->bufq[CAPTURE_PORT].lock); vb2_buffer_done(vb, VB2_BUF_STATE_DONE); Loading Loading @@ -3293,12 +3298,21 @@ int msm_comm_qbuf(struct vb2_buffer *vb) frame_data.flags |= HAL_BUFFERFLAG_EXTRADATA; } if (msm_comm_g_ctrl(inst, V4L2_CID_MPEG_VIDC_VIDEO_PICTYPE_DEC_MODE)) { frame_data.mark_data = frame_data.mark_target = 0xdeadbeef; } else { frame_data.mark_data = frame_data.mark_target = 0; } dprintk(VIDC_DBG, "Sending etb to hal: device_addr: %pa, alloc: %d, filled: %d, offset: %d, ts: %lld, flags = %#x, v4l2_buf index = %d\n", "Sending etb to hal: device_addr: %pa, alloc: %d, filled: %d, offset: %d, ts: %lld, flags = %#x, v4l2_buf index = %d, mark_data: %d\n", &frame_data.device_addr, frame_data.alloc_len, frame_data.filled_len, frame_data.offset, frame_data.timestamp, frame_data.flags, vb->v4l2_buf.index); vb->v4l2_buf.index, frame_data.mark_data); msm_dcvs_check_and_scale_clocks(inst, true); rc = call_hfi_op(hdev, session_etb, (void *) Loading drivers/media/platform/msm/vidc/vidc_hfi_api.h +1 −0 Original line number Diff line number Diff line Loading @@ -614,6 +614,7 @@ enum hal_picture { HAL_PICTURE_P = 0x02, HAL_PICTURE_B = 0x04, HAL_PICTURE_IDR = 0x08, HAL_PICTURE_CRA = 0x10, HAL_FRAME_NOTCODED = 0x7F002000, HAL_FRAME_YUV = 0x7F004000, HAL_UNUSED_PICT = 0x10000000, Loading Loading
drivers/media/platform/msm/vidc/hfi_response_handler.c +10 −0 Original line number Diff line number Diff line Loading @@ -1032,6 +1032,7 @@ static int hfi_process_session_etb_done(u32 device_id, struct msm_vidc_cb_info *info) { struct msm_vidc_cb_data_done data_done = {0}; struct hfi_picture_type *hfi_picture_type = NULL; dprintk(VIDC_DBG, "RECEIVED: SESSION_ETB_DONE[%#x]\n", pkt->session_id); Loading @@ -1055,6 +1056,15 @@ static int hfi_process_session_etb_done(u32 device_id, (ion_phys_addr_t)pkt->extra_data_buffer; data_done.input_done.status = hfi_map_err_status(pkt->error_type); hfi_picture_type = (struct hfi_picture_type *)&pkt->rgData[0]; if (hfi_picture_type->is_sync_frame) { if (hfi_picture_type->picture_type) data_done.input_done.flags = hfi_picture_type->picture_type; else dprintk(VIDC_DBG, "Non-Sync frame sent for H264/HEVC\n"); } trace_msm_v4l2_vidc_buffer_event_end("ETB", (u32)pkt->packet_buffer, -1, -1, Loading
drivers/media/platform/msm/vidc/msm_smem.c +1 −0 Original line number Diff line number Diff line Loading @@ -100,6 +100,7 @@ static int get_device_address(struct smem_client *smem_client, if (rc != table->nents) { dprintk(VIDC_ERR, "dma_map_sg failed! (%d != %d)\n", rc, table->nents); rc = -ENOMEM; goto mem_map_sg_failed; } if (table->sgl) { Loading
drivers/media/platform/msm/vidc/msm_vdec.c +13 −7 Original line number Diff line number Diff line Loading @@ -167,12 +167,12 @@ static struct msm_vidc_ctrl msm_vdec_ctrls[] = { .qmenu = mpeg_video_output_order, }, { .id = V4L2_CID_MPEG_VIDC_VIDEO_ENABLE_PICTURE_TYPE, .id = V4L2_CID_MPEG_VIDC_VIDEO_PICTYPE_DEC_MODE, .name = "Picture Type Decoding", .type = V4L2_CTRL_TYPE_INTEGER, .minimum = 1, .maximum = 15, .default_value = 15, .type = V4L2_CTRL_TYPE_BOOLEAN, .minimum = 0, .maximum = 1, .default_value = 0, .step = 1, .menu_skip_mask = 0, .qmenu = NULL, Loading Loading @@ -2130,9 +2130,15 @@ static int try_set_ctrl(struct msm_vidc_inst *inst, struct v4l2_ctrl *ctrl) property_val = ctrl->val; pdata = &property_val; break; case V4L2_CID_MPEG_VIDC_VIDEO_ENABLE_PICTURE_TYPE: case V4L2_CID_MPEG_VIDC_VIDEO_PICTYPE_DEC_MODE: property_id = HAL_PARAM_VDEC_PICTURE_TYPE_DECODE; enable_picture.picture_type = ctrl->val; if (ctrl->val == V4L2_MPEG_VIDC_VIDEO_PICTYPE_DECODE_ON) enable_picture.picture_type = HAL_PICTURE_I; else enable_picture.picture_type = HAL_PICTURE_I | HAL_PICTURE_P | HAL_PICTURE_B | HAL_PICTURE_IDR; pdata = &enable_picture; break; case V4L2_CID_MPEG_VIDC_VIDEO_KEEP_ASPECT_RATIO: Loading
drivers/media/platform/msm/vidc/msm_vidc_common.c +18 −4 Original line number Diff line number Diff line Loading @@ -1441,6 +1441,10 @@ static void handle_ebd(enum hal_command_response cmd, void *data) dprintk(VIDC_INFO, "Failed: Start code not found\n"); } if (empty_buf_done->flags & HAL_BUFFERFLAG_SYNCFRAME) vb->v4l2_buf.flags |= V4L2_QCOM_BUF_FLAG_IDRFRAME | V4L2_BUF_FLAG_KEYFRAME; } dprintk(VIDC_DBG, "Got ebd from hal: device_addr: %pa, alloc: %d, status: %#x, pic_type: %#x, flags: %#x\n", Loading Loading @@ -1748,12 +1752,13 @@ static void handle_fbd(enum hal_command_response cmd, void *data) vb->v4l2_planes[extra_idx].length); } dprintk(VIDC_DBG, "Got fbd from hal: device_addr: %pa, alloc: %d, filled: %d, offset: %d, ts: %lld, flags: %#x, crop: %d %d %d %d, pic_type: %#x\n", "Got fbd from hal: device_addr: %pa, alloc: %d, filled: %d, offset: %d, ts: %lld, flags: %#x, crop: %d %d %d %d, pic_type: %#x, mark_data: %d\n", &fill_buf_done->packet_buffer1, fill_buf_done->alloc_len1, fill_buf_done->filled_len1, fill_buf_done->offset1, time_usec, fill_buf_done->flags1, fill_buf_done->start_x_coord, fill_buf_done->start_y_coord, fill_buf_done->frame_width, fill_buf_done->frame_height, fill_buf_done->picture_type); fill_buf_done->frame_height, fill_buf_done->picture_type, fill_buf_done->mark_data); mutex_lock(&inst->bufq[CAPTURE_PORT].lock); vb2_buffer_done(vb, VB2_BUF_STATE_DONE); Loading Loading @@ -3293,12 +3298,21 @@ int msm_comm_qbuf(struct vb2_buffer *vb) frame_data.flags |= HAL_BUFFERFLAG_EXTRADATA; } if (msm_comm_g_ctrl(inst, V4L2_CID_MPEG_VIDC_VIDEO_PICTYPE_DEC_MODE)) { frame_data.mark_data = frame_data.mark_target = 0xdeadbeef; } else { frame_data.mark_data = frame_data.mark_target = 0; } dprintk(VIDC_DBG, "Sending etb to hal: device_addr: %pa, alloc: %d, filled: %d, offset: %d, ts: %lld, flags = %#x, v4l2_buf index = %d\n", "Sending etb to hal: device_addr: %pa, alloc: %d, filled: %d, offset: %d, ts: %lld, flags = %#x, v4l2_buf index = %d, mark_data: %d\n", &frame_data.device_addr, frame_data.alloc_len, frame_data.filled_len, frame_data.offset, frame_data.timestamp, frame_data.flags, vb->v4l2_buf.index); vb->v4l2_buf.index, frame_data.mark_data); msm_dcvs_check_and_scale_clocks(inst, true); rc = call_hfi_op(hdev, session_etb, (void *) Loading
drivers/media/platform/msm/vidc/vidc_hfi_api.h +1 −0 Original line number Diff line number Diff line Loading @@ -614,6 +614,7 @@ enum hal_picture { HAL_PICTURE_P = 0x02, HAL_PICTURE_B = 0x04, HAL_PICTURE_IDR = 0x08, HAL_PICTURE_CRA = 0x10, HAL_FRAME_NOTCODED = 0x7F002000, HAL_FRAME_YUV = 0x7F004000, HAL_UNUSED_PICT = 0x10000000, Loading