From 5001621745651443d3825a30a92897cac7f1ec53 Mon Sep 17 00:00:00 2001 From: "Suren A. Chilingaryan" Date: Wed, 12 Aug 2015 20:57:37 +0200 Subject: Do not fail if PCI configuration is not fully available to unprivileged user --- pcilib/pci.h | 1 + 1 file changed, 1 insertion(+) (limited to 'pcilib/pci.h') diff --git a/pcilib/pci.h b/pcilib/pci.h index 51bb352..340abd3 100644 --- a/pcilib/pci.h +++ b/pcilib/pci.h @@ -42,6 +42,7 @@ struct pcilib_s { int pci_cfg_space_fd; /**< File descriptor linking to PCI configuration space in sysfs */ uint32_t pci_cfg_space_cache[64]; /**< Cached PCI configuration space */ + size_t pci_cfg_space_size; /**< Size of the cached PCI configuration space, sometimes not fully is available for unpriveledged user */ const uint32_t *pcie_capabilities; /**< PCI Capbility structure (just a pointer at appropriate place in the pci_cfg_space) */ int reg_bar_mapped; /**< Indicates that all BARs used to access registers are mapped */ -- cgit v1.2.3