From 7d7033d831893f6ba6975707f7d076ad15dfdf2c Mon Sep 17 00:00:00 2001 From: Deepak Nibade Date: Tue, 2 Feb 2016 15:57:33 +0530 Subject: gpu: nvgpu: return error for handled intr only In gk20a_gr_handle_fecs_error(), we always return error value and that triggers recovery in each case Return error only if we need to trigger recovery (depending on case) Otherwise, clear the interrupt and return success Bug 200156699 Change-Id: I117f3702b751e8bbc1cd3834b1b72b6533e246f9 Signed-off-by: Deepak Nibade Reviewed-on: http://git-master/r/1001694 Reviewed-by: Terje Bergstrom Tested-by: Terje Bergstrom --- drivers/gpu/nvgpu/gk20a/gr_gk20a.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'drivers/gpu/nvgpu/gk20a/gr_gk20a.c') diff --git a/drivers/gpu/nvgpu/gk20a/gr_gk20a.c b/drivers/gpu/nvgpu/gk20a/gr_gk20a.c index a96bc4e1..4d3f5068 100644 --- a/drivers/gpu/nvgpu/gk20a/gr_gk20a.c +++ b/drivers/gpu/nvgpu/gk20a/gr_gk20a.c @@ -4885,6 +4885,7 @@ int gk20a_gr_handle_fecs_error(struct gk20a *g, struct channel_gk20a *ch, struct gr_gk20a_isr_data *isr_data) { u32 gr_fecs_intr = gk20a_readl(g, gr_fecs_host_int_status_r()); + int ret = 0; gk20a_dbg_fn(""); @@ -4897,10 +4898,11 @@ int gk20a_gr_handle_fecs_error(struct gk20a *g, struct channel_gk20a *ch, "firmware method error 0x%08x for offset 0x%04x", gk20a_readl(g, gr_fecs_ctxsw_mailbox_r(6)), isr_data->data_lo); + ret = -1; } gk20a_writel(g, gr_fecs_host_int_clear_r(), gr_fecs_intr); - return -EINVAL; + return ret; } static int gk20a_gr_handle_class_error(struct gk20a *g, -- cgit v1.2.2