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

Commit 16eb1366 authored by Tanvi Aggarwal's avatar Tanvi Aggarwal Committed by Gerrit - the friendly Code Review server
Browse files

msm: sensor: Limiting error messages during sensor probe



Limiting error messages during sensor probe and power up.

CRs-Fixed: 2083441
Change-Id: I4c14c580ee457ee847e861870a6e2fb88f71411d
Signed-off-by: default avatarTanvi Aggarwal <tanvia@qti.qualcomm.com>
parent 486b948c
Loading
Loading
Loading
Loading
+3 −3
Original line number Diff line number Diff line
@@ -1464,7 +1464,7 @@ int msm_camera_power_up(struct msm_camera_power_ctrl_t *ctrl,
		switch (power_setting->seq_type) {
		case SENSOR_CLK:
			if (power_setting->seq_val >= ctrl->clk_info_size) {
				pr_err("%s clk index %d >= max %zu\n", __func__,
				pr_err_ratelimited("%s clk index %d >= max %zu\n", __func__,
					power_setting->seq_val,
					ctrl->clk_info_size);
				goto power_up_failed;
@@ -1476,7 +1476,7 @@ int msm_camera_power_up(struct msm_camera_power_ctrl_t *ctrl,
				ctrl->clk_info, ctrl->clk_ptr,
				ctrl->clk_info_size, true);
			if (rc < 0) {
				pr_err("%s: clk enable failed\n", __func__);
				pr_err_ratelimited("%s: clk enable failed\n", __func__);
				goto power_up_failed;
			}
			break;
@@ -1559,7 +1559,7 @@ int msm_camera_power_up(struct msm_camera_power_ctrl_t *ctrl,
	CDBG("%s exit\n", __func__);
	return 0;
power_up_failed:
	pr_err("%s:%d failed\n", __func__, __LINE__);
	pr_err_ratelimited("%s:%d failed\n", __func__, __LINE__);
	for (index--; index >= 0; index--) {
		CDBG("%s index %d\n", __func__, index);
		power_setting = &ctrl->power_setting[index];
+3 −3
Original line number Diff line number Diff line
/* Copyright (c) 2013-2016, The Linux Foundation. All rights reserved.
/* Copyright (c) 2013-2017, The Linux Foundation. All rights reserved.
 *
 * This program is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 2 and
@@ -77,7 +77,7 @@ static int32_t msm_sensor_driver_cmd(struct msm_sensor_init_t *s_init,
			cfg->entity_name);
		mutex_unlock(&s_init->imutex);
		if (rc < 0)
			pr_err("%s failed (non-fatal) rc %d", __func__, rc);
			pr_err_ratelimited("%s failed (non-fatal) rc %d", __func__, rc);
		break;

	case CFG_SINIT_PROBE_DONE:
@@ -142,7 +142,7 @@ static long msm_sensor_init_subdev_do_ioctl(
		cmd = VIDIOC_MSM_SENSOR_INIT_CFG;
		rc = msm_sensor_init_subdev_ioctl(sd, cmd, &sensor_init_data);
		if (rc < 0) {
			pr_err("%s:%d VIDIOC_MSM_SENSOR_INIT_CFG failed (non-fatal)",
			pr_err_ratelimited("%s:%d VIDIOC_MSM_SENSOR_INIT_CFG failed (non-fatal)",
				__func__, __LINE__);
			return rc;
		}