lkml.org 
[lkml]   [2023]   [Oct]   [9]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [PATCH 1/2] dmaengine: pxa_dma: Remove an erroneous BUG_ON() in pxad_free_desc()
Date

On Sat, 07 Oct 2023 13:13:09 +0200, Christophe JAILLET wrote:
> If pxad_alloc_desc() fails on the first dma_pool_alloc() call, then
> sw_desc->nb_desc is zero.
> In such a case pxad_free_desc() is called and it will BUG_ON().
>
> Remove this erroneous BUG_ON().
>
> It is also useless, because if "sw_desc->nb_desc == 0", then, on the first
> iteration of the for loop, i is -1 and the loop will not be executed.
> (both i and sw_desc->nb_desc are 'int')
>
> [...]

Applied, thanks!

[1/2] dmaengine: pxa_dma: Remove an erroneous BUG_ON() in pxad_free_desc()
commit: 83c761f568733277ce1f7eb9dc9e890649c29a8c
[2/2] dmaengine: pxa_dma: Annotate struct pxad_desc_sw with __counted_by
commit: 0481291f0ccbc5147635cf0eb108f9fe5a05ee7d

Best regards,
--
~Vinod


\
 
 \ /
  Last update: 2023-10-09 08:13    [W:1.109 / U:0.260 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site