Skip to content

Commit 0650006

Browse files
tititiou36vinodkoul
authored andcommitted
dmaengine: fsl-qdma: Remove a useless devm_kfree()
'status_head' is a managed resource. It will be freed automatically if fsl_qdma_prep_status_queue(), and so fsl_qdma_probe(), fails. Remove the redundant (and harmless) devm_kfree() call. Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr> Link: https://lore.kernel.org/r/6b7f60aa2b92f73b35c586886daffc1a5ac58697.1704621515.git.christophe.jaillet@wanadoo.fr Signed-off-by: Vinod Koul <vkoul@kernel.org>
1 parent 3aa58cb commit 0650006

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

drivers/dma/fsl-qdma.c

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -568,10 +568,9 @@ static struct fsl_qdma_queue
568568
status_size,
569569
&status_head->bus_addr,
570570
GFP_KERNEL);
571-
if (!status_head->cq) {
572-
devm_kfree(&pdev->dev, status_head);
571+
if (!status_head->cq)
573572
return NULL;
574-
}
573+
575574
status_head->n_cq = status_size;
576575
status_head->virt_head = status_head->cq;
577576
status_head->virt_tail = status_head->cq;

0 commit comments

Comments
 (0)