فهرست منبع

video: driver: handle resume command response

handle resume command response from fw.

Change-Id: Ib45a7e1f6b6ffab6573699dfc4efb2305ced511c
Signed-off-by: Darshana Patil <[email protected]>
Darshana Patil 4 سال پیش
والد
کامیت
a11586233a
2فایلهای تغییر یافته به همراه16 افزوده شده و 1 حذف شده
  1. 1 1
      driver/vidc/src/msm_vidc_driver.c
  2. 15 0
      driver/vidc/src/venus_hfi_response.c

+ 1 - 1
driver/vidc/src/msm_vidc_driver.c

@@ -1849,7 +1849,7 @@ int msm_vidc_release_internal_buffers(struct msm_vidc_inst *inst,
 		/* mark pending release */
 		buffer->attr |= MSM_VIDC_ATTR_PENDING_RELEASE;
 
-		i_vpr_e(inst, "%s: released buffer_type %#x, size %d\n",
+		i_vpr_h(inst, "%s: released buffer_type %#x, size %d\n",
 			__func__, buffer_type, buffers->size);
 	}
 

+ 15 - 0
driver/vidc/src/venus_hfi_response.c

@@ -1013,6 +1013,19 @@ static int handle_session_delivery_mode(struct msm_vidc_inst *inst,
 	return 0;
 }
 
+static int handle_session_resume(struct msm_vidc_inst *inst,
+	struct hfi_packet *pkt)
+{
+	if (pkt->flags & HFI_FW_FLAGS_SESSION_ERROR) {
+		i_vpr_e(inst, "%s: received session error\n", __func__);
+		msm_vidc_change_inst_state(inst, MSM_VIDC_ERROR, __func__);
+	}
+
+	if (pkt->flags & HFI_FW_FLAGS_SUCCESS)
+		i_vpr_h(inst, "%s: successful\n", __func__);
+	return 0;
+}
+
 static int handle_session_command(struct msm_vidc_inst *inst,
 	struct hfi_packet *pkt)
 {
@@ -1035,6 +1048,8 @@ static int handle_session_command(struct msm_vidc_inst *inst,
 		return handle_session_subscribe_mode(inst, pkt);
 	case HFI_CMD_DELIVERY_MODE:
 		return handle_session_delivery_mode(inst, pkt);
+	case HFI_CMD_RESUME:
+		return handle_session_resume(inst, pkt);
 	default:
 		i_vpr_e(inst, "%s: Unsupported command type: %#x\n",
 			__func__, pkt->type);