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

Commit 0b297c15 authored by qctecmdr's avatar qctecmdr Committed by Gerrit - the friendly Code Review server
Browse files

Merge "msm: camera: Error handling for optional clock"

parents 46f9c29e 5eab0836
Loading
Loading
Loading
Loading
+3 −2
Original line number Diff line number Diff line
@@ -606,8 +606,9 @@ int cam_sensor_match_id(struct cam_sensor_ctrl_t *s_ctrl)

	CAM_DBG(CAM_SENSOR, "read id: 0x%x expected id 0x%x:",
		chipid, slave_info->sensor_id);

	if (cam_sensor_id_by_mask(s_ctrl, chipid) != slave_info->sensor_id) {
		CAM_ERR(CAM_SENSOR, "chip id %x does not match %x",
		CAM_WARN(CAM_SENSOR, "read id: 0x%x expected id 0x%x:",
				chipid, slave_info->sensor_id);
		return -ENODEV;
	}
+7 −0
Original line number Diff line number Diff line
@@ -512,6 +512,13 @@ int cam_soc_util_get_option_clk_by_name(struct cam_hw_soc_info *soc_info,
	index = of_property_match_string(of_node, "clock-names-option",
		clk_name);

	if (index < 0) {
		CAM_INFO(CAM_UTIL, "No clk data for %s", clk_name);
		*clk_index = -1;
		*clk = ERR_PTR(-EINVAL);
		return -EINVAL;
	}

	*clk = cam_soc_util_option_clk_get(of_node, index);
	if (IS_ERR(*clk)) {
		CAM_ERR(CAM_UTIL, "No clk named %s found. Dev %s", clk_name,