Re: [PATCH v3 00/26] Add definition for the number of standard PCI BARs

2019-09-18 Thread Andrew Murray
On Mon, Sep 16, 2019 at 11:41:32PM +0300, Denis Efremov wrote: > Code that iterates over all standard PCI BARs typically uses > PCI_STD_RESOURCE_END, but this is error-prone because it requires > "i <= PCI_STD_RESOURCE_END" rather than something like > "i < PCI_STD_NUM_BARS". We could add such a de

[PATCH v3 00/26] Add definition for the number of standard PCI BARs

2019-09-16 Thread Denis Efremov
Code that iterates over all standard PCI BARs typically uses PCI_STD_RESOURCE_END, but this is error-prone because it requires "i <= PCI_STD_RESOURCE_END" rather than something like "i < PCI_STD_NUM_BARS". We could add such a definition and use it the same way PCI_SRIOV_NUM_BARS is used. The patchs