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] [thread-next>] [day] [month] [year] [list]
Message-ID: <20190816133147.GM253360@google.com>
Date:   Fri, 16 Aug 2019 08:31:47 -0500
From:   Bjorn Helgaas <helgaas@...nel.org>
To:     Thomas Gleixner <tglx@...utronix.de>
Cc:     Denis Efremov <efremov@...ux.com>,
        "H. Peter Anvin" <hpa@...or.com>, x86@...nel.org,
        linux-pci@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH v2 03/10] x86/PCI: Loop using PCI_STD_NUM_BARS

On Fri, Aug 16, 2019 at 11:32:41AM +0200, Thomas Gleixner wrote:
> On Fri, 16 Aug 2019, Denis Efremov wrote:
> 
> > Refactor loops to use 'i < PCI_STD_NUM_BARS' instead of
> > 'i <= PCI_STD_RESOURCE_END'.
> 
> Please describe the WHY not the WHAT. I can see the WHAT from the patch
> itself, but I can't figure out WHY.

Good point; the WHY is to use idiomatic C style and avoid
the fencepost error of using "i < PCI_STD_RESOURCE_END"
when "i <= PCI_STD_RESOURCE_END" is required, e.g.,
2f686f1d9bee ("PCI: Correct PCI_STD_RESOURCE_END usage")

Denis, can you include something along those lines in the next
version?

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ