|
@@ -3065,6 +3065,9 @@ static int __cam_isp_ctx_config_dev_in_top_state(
|
|
struct cam_req_mgr_add_request add_req;
|
|
struct cam_req_mgr_add_request add_req;
|
|
struct cam_isp_context *ctx_isp =
|
|
struct cam_isp_context *ctx_isp =
|
|
(struct cam_isp_context *) ctx->ctx_priv;
|
|
(struct cam_isp_context *) ctx->ctx_priv;
|
|
|
|
+ struct cam_hw_cmd_args hw_cmd_args;
|
|
|
|
+ struct cam_isp_hw_cmd_args isp_hw_cmd_args;
|
|
|
|
+ uint32_t packet_opcode = 0;
|
|
|
|
|
|
CAM_DBG(CAM_ISP, "get free request object......");
|
|
CAM_DBG(CAM_ISP, "get free request object......");
|
|
|
|
|
|
@@ -3113,7 +3116,23 @@ static int __cam_isp_ctx_config_dev_in_top_state(
|
|
CAM_DBG(CAM_ISP, "Packet size 0x%x", packet->header.size);
|
|
CAM_DBG(CAM_ISP, "Packet size 0x%x", packet->header.size);
|
|
CAM_DBG(CAM_ISP, "packet op %d", packet->header.op_code);
|
|
CAM_DBG(CAM_ISP, "packet op %d", packet->header.op_code);
|
|
|
|
|
|
- if ((((packet->header.op_code + 1) & 0xF) == CAM_ISP_PACKET_UPDATE_DEV)
|
|
|
|
|
|
+ /* Query the packet opcode */
|
|
|
|
+ hw_cmd_args.ctxt_to_hw_map = ctx_isp->hw_ctx;
|
|
|
|
+ hw_cmd_args.cmd_type = CAM_HW_MGR_CMD_INTERNAL;
|
|
|
|
+ isp_hw_cmd_args.cmd_type = CAM_ISP_HW_MGR_GET_PACKET_OPCODE;
|
|
|
|
+ isp_hw_cmd_args.cmd_data = (void *)packet;
|
|
|
|
+ hw_cmd_args.u.internal_args = (void *)&isp_hw_cmd_args;
|
|
|
|
+ rc = ctx->hw_mgr_intf->hw_cmd(ctx->hw_mgr_intf->hw_mgr_priv,
|
|
|
|
+ &hw_cmd_args);
|
|
|
|
+ if (rc) {
|
|
|
|
+ CAM_ERR(CAM_ISP, "HW command failed");
|
|
|
|
+ goto free_req;
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ packet_opcode = isp_hw_cmd_args.u.packet_op_code;
|
|
|
|
+ CAM_DBG(CAM_ISP, "packet op %d", packet_opcode);
|
|
|
|
+
|
|
|
|
+ if ((packet_opcode == CAM_ISP_PACKET_UPDATE_DEV)
|
|
&& (packet->header.request_id <= ctx->last_flush_req)) {
|
|
&& (packet->header.request_id <= ctx->last_flush_req)) {
|
|
CAM_INFO(CAM_ISP,
|
|
CAM_INFO(CAM_ISP,
|
|
"request %lld has been flushed, reject packet",
|
|
"request %lld has been flushed, reject packet",
|