lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:   Tue, 22 Mar 2022 09:52:27 +0100
From:   Paolo Abeni <pabeni@...hat.com>
To:     Xiaomeng Tong <xiam0nd.tong@...il.com>, davem@...emloft.net,
        kuba@...nel.org
Cc:     aelior@...vell.com, manishc@...vell.com, netdev@...r.kernel.org,
        linux-kernel@...r.kernel.org
Subject: Re: [PATCH] qed: remove an unneed NULL check on list iterator

Hello,

On Sat, 2022-03-19 at 12:36 +0800, Xiaomeng Tong wrote:
> The define for_each_pci_dev(d) is:
>  while ((d = pci_get_device(PCI_ANY_ID, PCI_ANY_ID, d)) != NULL)
> 
> Thus, the list iterator 'd' is always non-NULL so it doesn't need to
> be checked. So just remove the unnecessary NULL check. Also remove the
> unnecessary initializer because the list iterator is always initialized.
> 
> Signed-off-by: Xiaomeng Tong <xiam0nd.tong@...il.com>

This looks like a net-next change, but net-next is now closed. please
repost 2 weeks, thanks!

Paolo

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ