Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 2de358bc authored by Lynus Vaz's avatar Lynus Vaz Committed by Tony Lijo Jose
Browse files

msm: camera: icp: Reduce the device idle timer



Reduce the device idle timer to 400 msecs, to turn off clocks that
are not in use and save power.

Change-Id: I3c76c645bf11a05cdc7a8cc125719b00c198c87b
Signed-off-by: default avatarLynus Vaz <lvaz@codeaurora.org>
Signed-off-by: default avatarTony Lijo Jose <tjose@codeaurora.org>
parent 51c8f3bd
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -57,6 +57,8 @@
#define ICP_DEV_TYPE_TO_CLK_TYPE(dev_type) \
	((dev_type == CAM_ICP_RES_TYPE_BPS) ? ICP_CLK_HW_BPS : ICP_CLK_HW_IPE)

#define ICP_DEVICE_IDLE_TIMEOUT 400

static struct cam_icp_hw_mgr icp_hw_mgr;

static int cam_icp_send_ubwc_cfg(struct cam_icp_hw_mgr *hw_mgr)
@@ -491,7 +493,7 @@ static int cam_icp_device_timer_start(struct cam_icp_hw_mgr *hw_mgr)
	for (i = 0; i < ICP_CLK_HW_MAX; i++)  {
		if (!hw_mgr->clk_info[i].watch_dog) {
			rc = crm_timer_init(&hw_mgr->clk_info[i].watch_dog,
				3000, &hw_mgr->clk_info[i],
				ICP_DEVICE_IDLE_TIMEOUT, &hw_mgr->clk_info[i],
				&cam_icp_device_timer_cb);

			if (rc)