msm: camera: core: Add delay detection support

This changes is to detect workqueue and tasklet
scheduling and execution delay.

CRs-Fixed: 2977775
Change-Id: Ia4b4845a067c22bd1f24bd63a971d103fcfc049c
Signed-off-by: Ayush Kumar <ayushkr@codeaurora.org>
This commit is contained in:
Ayush Kumar
2020-11-02 05:21:18 +05:30
parent 46d07dd8d8
commit 8554f46816
10 changed files with 103 additions and 52 deletions

View File

@@ -7,6 +7,7 @@
#include "cam_cci_core.h"
#include "cam_cci_dev.h"
#include "cam_req_mgr_workq.h"
#include "cam_common_util.h"
static int32_t cam_cci_convert_type_to_num_bytes(
enum camera_sensor_i2c_type type)
@@ -1516,8 +1517,10 @@ static void cam_cci_write_async_helper(struct work_struct *work)
enum cci_i2c_master_t master;
struct cam_cci_master_info *cci_master_info;
cam_req_mgr_thread_switch_delay_detect(CAM_CCI_WORKQUEUE_NAME,
write_async->workq_scheduled_ts);
cam_common_util_thread_switch_delay_detect(
"CCI workq schedule",
write_async->workq_scheduled_ts,
CAM_WORKQ_SCHEDULE_TIME_THRESHOLD);
cci_dev = write_async->cci_dev;
i2c_msg = &write_async->c_ctrl.cfg.cci_i2c_write_cfg;
master = write_async->c_ctrl.cci_info->cci_i2c_master;