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

Commit b0e84d76 authored by Linux Build Service Account's avatar Linux Build Service Account Committed by Gerrit - the friendly Code Review server
Browse files

Merge "msm: camera: reduce logging in case of ISP iommu page fault"

parents a35c4d02 ee869c28
Loading
Loading
Loading
Loading
+26 −0
Original line number Diff line number Diff line
@@ -2130,3 +2130,29 @@ void msm_isp_process_axi_irq(struct vfe_device *vfe_dev,
	}
	return;
}

void msm_isp_axi_disable_all_wm(struct vfe_device *vfe_dev)
{
	struct msm_vfe_axi_stream *stream_info;
	struct msm_vfe_axi_shared_data *axi_data = &vfe_dev->axi_data;
	int i, j;

	if (!vfe_dev || !axi_data) {
		pr_err("%s: error %p %p\n", __func__, vfe_dev, axi_data);
		return;
	}

	for (i = 0; i < MAX_NUM_STREAM; i++) {
		stream_info = &axi_data->stream_info[i];

		if (stream_info->state != ACTIVE)
			continue;

		for (j = 0; j < stream_info->num_planes; j++)
			vfe_dev->hw_info->vfe_ops.axi_ops.enable_wm(vfe_dev,
				stream_info->wm[j], 0);

		vfe_dev->hw_info->vfe_ops.core_ops.reg_update(vfe_dev,
			SRC_TO_INTF(stream_info->stream_src));
	}
}
+4 −1
Original line number Diff line number Diff line
/* Copyright (c) 2013-2014, The Linux Foundation. All rights reserved.
/* Copyright (c) 2013-2015, 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
@@ -68,4 +68,7 @@ void msm_isp_notify(struct vfe_device *vfe_dev, uint32_t event_type,
void msm_isp_process_axi_irq(struct vfe_device *vfe_dev,
	uint32_t irq_status0, uint32_t irq_status1,
	struct msm_isp_timestamp *ts);

void msm_isp_axi_disable_all_wm(struct vfe_device *vfe_dev);

#endif /* __MSM_ISP_AXI_UTIL_H__ */
+16 −0
Original line number Diff line number Diff line
@@ -764,3 +764,19 @@ int msm_isp_update_stats_stream(struct vfe_device *vfe_dev, void *arg)
	}
	return rc;
}

void msm_isp_stats_disable(struct vfe_device *vfe_dev)
{
	int i;
	unsigned int mask = 0;

	if (!vfe_dev) {
		pr_err("%s: error NULL ptr\n", __func__);
		return;
	}

	for (i = 0; i < vfe_dev->hw_info->stats_hw_info->num_stats_type; i++)
		mask |= 1 << i;

	vfe_dev->hw_info->vfe_ops.stats_ops.enable_module(vfe_dev, mask, 0);
}
+2 −1
Original line number Diff line number Diff line
/* Copyright (c) 2013-2014, The Linux Foundation. All rights reserved.
/* Copyright (c) 2013-2015, 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
@@ -24,4 +24,5 @@ int msm_isp_update_stats_stream(struct vfe_device *vfe_dev, void *arg);
int msm_isp_release_stats_stream(struct vfe_device *vfe_dev, void *arg);
int msm_isp_request_stats_stream(struct vfe_device *vfe_dev, void *arg);
void msm_isp_update_stats_framedrop_reg(struct vfe_device *vfe_dev);
void msm_isp_stats_disable(struct vfe_device *vfe_dev);
#endif /* __MSM_ISP_STATS_UTIL_H__ */
+2 −0
Original line number Diff line number Diff line
@@ -1809,6 +1809,8 @@ static int msm_vfe_iommu_fault_handler(struct iommu_domain *domain,

	if (token) {
		vfe_dev = (struct vfe_device *)token;
		msm_isp_axi_disable_all_wm(vfe_dev);
		msm_isp_stats_disable(vfe_dev);
		if (!vfe_dev->buf_mgr || !vfe_dev->buf_mgr->ops) {
			pr_err("%s:%d] buf_mgr %p\n", __func__,
				__LINE__, vfe_dev->buf_mgr);