Commit d8c27ba8 authored by Dan Carpenter's avatar Dan Carpenter Committed by Borislav Petkov

EDAC, thunderx: Fix memory leak in thunderx_l2c_threaded_isr()

Fix memory leak in L2c threaded interrupt handler.

 [ bp: Rewrite commit message. ]

Fixes: 41003396 ("EDAC, thunderx: Add Cavium ThunderX EDAC driver")
Signed-off-by: default avatarDan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: default avatarBorislav Petkov <bp@suse.de>
CC: David Daney <david.daney@cavium.com>
CC: Jan Glauber <jglauber@cavium.com>
CC: Mauro Carvalho Chehab <mchehab@kernel.org>
CC: Sergey Temerkhanov <s.temerkhanov@gmail.com>
CC: linux-edac <linux-edac@vger.kernel.org>
Link: http://lkml.kernel.org/r/20181013102843.GG16086@mwanda
parent 8f189738
...@@ -1884,7 +1884,7 @@ static irqreturn_t thunderx_l2c_threaded_isr(int irq, void *irq_id) ...@@ -1884,7 +1884,7 @@ static irqreturn_t thunderx_l2c_threaded_isr(int irq, void *irq_id)
default: default:
dev_err(&l2c->pdev->dev, "Unsupported device: %04x\n", dev_err(&l2c->pdev->dev, "Unsupported device: %04x\n",
l2c->pdev->device); l2c->pdev->device);
return IRQ_NONE; goto err_free;
} }
while (CIRC_CNT(l2c->ring_head, l2c->ring_tail, while (CIRC_CNT(l2c->ring_head, l2c->ring_tail,
...@@ -1906,7 +1906,7 @@ static irqreturn_t thunderx_l2c_threaded_isr(int irq, void *irq_id) ...@@ -1906,7 +1906,7 @@ static irqreturn_t thunderx_l2c_threaded_isr(int irq, void *irq_id)
l2c->ring_tail++; l2c->ring_tail++;
} }
return IRQ_HANDLED; ret = IRQ_HANDLED;
err_free: err_free:
kfree(other); kfree(other);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment