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

Commit 1605506f authored by Venkat Chinta's avatar Venkat Chinta Committed by Gerrit - the friendly Code Review server
Browse files

msm: camera: vfe: Quieten driver during boot



In bus initialization, error irq must be subscribed to
only if tasklet has been initialized in the hw manager.
This change adds checks for the above to prevent
unnecessary error logging.

Change-Id: I9e979e1e36c0b18f66a5f8b1809aa61221d9398c
Signed-off-by: default avatarVenkat Chinta <vchinta@codeaurora.org>
parent 3b3e314b
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
// SPDX-License-Identifier: GPL-2.0-only
/*
 * Copyright (c) 2017-2018, The Linux Foundation. All rights reserved.
 * Copyright (c) 2017-2019, The Linux Foundation. All rights reserved.
 */

#include <linux/slab.h>
@@ -99,7 +99,7 @@ int cam_vfe_init_soc_resources(struct cam_hw_soc_info *soc_info,
		CAM_VFE_DSP_CLK_NAME, &soc_private->dsp_clk,
		&soc_private->dsp_clk_index, &soc_private->dsp_clk_rate);
	if (rc)
		CAM_WARN(CAM_ISP, "option clk get failed");
		CAM_WARN(CAM_ISP, "Option clk get failed with rc %d", rc);

	rc = cam_vfe_request_platform_resource(soc_info, vfe_irq_handler,
		irq_data);
+18 −15
Original line number Diff line number Diff line
// SPDX-License-Identifier: GPL-2.0-only
/*
 * Copyright (c) 2018-2019, The Linux Foundation. All rights reserved.
/* Copyright (c) 2018-2019, The Linux Foundation. All rights reserved.
 */

#include <linux/ratelimit.h>
@@ -3252,11 +3252,12 @@ static int cam_vfe_bus_init_hw(void *hw_priv,
		NULL,
		NULL);

	if (bus_priv->irq_handle <= 0) {
	if ((int)bus_priv->irq_handle <= 0) {
		CAM_ERR(CAM_ISP, "Failed to subscribe BUS IRQ");
		return -EFAULT;
	}

	if (bus_priv->tasklet_info != NULL) {
		bus_priv->error_irq_handle = cam_irq_controller_subscribe_irq(
			bus_priv->common_data.bus_irq_controller,
			CAM_IRQ_PRIORITY_0,
@@ -3267,10 +3268,12 @@ static int cam_vfe_bus_init_hw(void *hw_priv,
			bus_priv->tasklet_info,
			&tasklet_bh_api);

	if (bus_priv->irq_handle <= 0) {
		CAM_ERR(CAM_ISP, "Failed to subscribe BUS IRQ");
		if ((int)bus_priv->error_irq_handle <= 0) {
			CAM_ERR(CAM_ISP, "Failed to subscribe BUS error IRQ %d",
				bus_priv->error_irq_handle);
			return -EFAULT;
		}
	}

	/*Set Debug Registers*/
	cam_io_w_mb(CAM_VFE_BUS_SET_DEBUG_REG, bus_priv->common_data.mem_base +
+2 −2
Original line number Diff line number Diff line
@@ -2763,7 +2763,7 @@ static int cam_vfe_bus_ver3_init_hw(void *hw_priv,
		NULL,
		NULL);

	if (bus_priv->irq_handle <= 0) {
	if ((int)bus_priv->irq_handle <= 0) {
		CAM_ERR(CAM_ISP, "Failed to subscribe BUS IRQ");
		return -EFAULT;
	}
@@ -2779,7 +2779,7 @@ static int cam_vfe_bus_ver3_init_hw(void *hw_priv,
			bus_priv->tasklet_info,
			&tasklet_bh_api);

		if (bus_priv->error_irq_handle <= 0) {
		if ((int)bus_priv->error_irq_handle <= 0) {
			CAM_ERR(CAM_ISP, "Failed to subscribe BUS Error IRQ");
			return -EFAULT;
		}