mirror of
https://github.com/torvalds/linux.git
synced 2026-09-25 21:21:09 -04:00
qcom: bam_dma: Delete useless kfree code
The parameter of kfree function is NULL, so kfree code is useless, delete it. Therefore, goto expression is no longer needed, so simplify it. Signed-off-by: Zheng Yongjun <[email protected]> Reviewed-by: Bjorn Andersson <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Vinod Koul <[email protected]>
This commit is contained in:
committed by
Vinod Koul
parent
595a334148
commit
ba42f61b36
@@ -630,7 +630,7 @@ static struct dma_async_tx_descriptor *bam_prep_slave_sg(struct dma_chan *chan,
|
||||
GFP_NOWAIT);
|
||||
|
||||
if (!async_desc)
|
||||
goto err_out;
|
||||
return NULL;
|
||||
|
||||
if (flags & DMA_PREP_FENCE)
|
||||
async_desc->flags |= DESC_FLAG_NWD;
|
||||
@@ -670,10 +670,6 @@ static struct dma_async_tx_descriptor *bam_prep_slave_sg(struct dma_chan *chan,
|
||||
}
|
||||
|
||||
return vchan_tx_prep(&bchan->vc, &async_desc->vd, flags);
|
||||
|
||||
err_out:
|
||||
kfree(async_desc);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user