Re: [PATCH] staging: vchiq: Fix list_for_each exit tests

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Sep 28, 2020 at 12:11:03PM +0300, Dan Carpenter wrote:
> This code code here used to be list_for_each() and after the loop then
> the "entry" pointer was non-NULL if we found the correct entry or NULL
> if we couldn't find it.  Then we changed the code to use list_for_each_entry()
> and so now the "entry" pointer is always non-NULL when we exit the loop.
> 
> I have introduced a new "found" variable to say if we found the correct
> enty or not.  I fixed one test by making it an else statement because
> that was more readable than testing "if (!found)".
> 
> Fixes: 46e4b9ec4fa4 ("staging: vchiq_arm: use list_for_each_entry when accessing bulk_waiter_list")
> Signed-off-by: Dan Carpenter <dan.carpenter@xxxxxxxxxx>
> ---
>  .../vc04_services/interface/vchiq_arm/vchiq_arm.c    | 12 +++++++-----
>  1 file changed, 7 insertions(+), 5 deletions(-)

This doesn't apply against my tree, what branch did you make it against?

thanks,

greg k-h



[Index of Archives]     [Kernel Development]     [Kernel Announce]     [Kernel Newbies]     [Linux Networking Development]     [Share Photos]     [IDE]     [Security]     [Git]     [Netfilter]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Device Mapper]

  Powered by Linux