PCI: Use PCI Express Capability accessor
Use PCI Express Capability access functions to simplify device Capabilities Register usages. Signed-off-by: Myron Stowe <myron.stowe@redhat.com> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
This commit is contained in:

committed by
Bjorn Helgaas

parent
7c9c003c68
commit
1c531d82ee
@@ -1707,7 +1707,7 @@ static inline u16 pcie_caps_reg(const struct pci_dev *dev)
|
||||
*/
|
||||
static inline int pci_pcie_type(const struct pci_dev *dev)
|
||||
{
|
||||
return (dev->pcie_flags_reg & PCI_EXP_FLAGS_TYPE) >> 4;
|
||||
return (pcie_caps_reg(dev) & PCI_EXP_FLAGS_TYPE) >> 4;
|
||||
}
|
||||
|
||||
void pci_request_acs(void);
|
||||
|
Reference in New Issue
Block a user