{
    "mode": "man",
    "parameter": "pcilib",
    "section": "7",
    "url": "https://www.chedong.com/phpMan.php/man/pcilib/7/json",
    "generated": "2026-08-07T18:57:50Z",
    "sections": {
        "NAME": {
            "content": "pcilib - a library for accessing PCI devices\n\n",
            "subsections": []
        },
        "DESCRIPTION": {
            "content": "The PCI library (also known as pcilib and libpci) is a portable library for accessing PCI de‐\nvices and their configuration space.\n\n",
            "subsections": []
        },
        "ACCESS METHODS": {
            "content": "The  library supports a variety of methods to access the configuration space on different op‐\nerating systems. By default, the first matching method in this list  is  used,  but  you  can\nspecify override the decision (see the -A switch of lspci).\n\n",
            "subsections": [
                {
                    "name": "linux-sysfs",
                    "content": "The /sys filesystem on Linux 2.6 and newer. The standard header of the config space is\navailable  to all users, the rest only to root. Supports extended configuration space,\nPCI domains, VPD (from Linux 2.6.26), physical slots (also since Linux 2.6.26) and in‐\nformation on attached kernel drivers.\n"
                },
                {
                    "name": "linux-proc",
                    "content": "The /proc/bus/pci interface supported by Linux 2.1 and newer. The standard  header  of\nthe config space is available to all users, the rest only to root.\n"
                },
                {
                    "name": "intel-conf1",
                    "content": "Direct hardware access via Intel configuration mechanism 1. Available on i386 and com‐\npatibles on Linux, Solaris/x86, GNU Hurd, Windows, BeOS and Haiku. Requires root priv‐\nileges.\n"
                },
                {
                    "name": "intel-conf2",
                    "content": "Direct hardware access via Intel configuration mechanism 2. Available on i386 and com‐\npatibles on Linux, Solaris/x86, GNU Hurd, Windows, BeOS and Haiku. Requires root priv‐\nileges.  Warning:  This method is able to address only the first 16 devices on any bus\nand it seems to be very unreliable in many cases.\n"
                },
                {
                    "name": "mmio-conf1",
                    "content": "Direct hardware access via Intel configuration  mechanism  1  via  memory-mapped  I/O.\nMostly  used  on  non-i386  platforms.  Requires root privileges. Warning: This method\nneeds to be properly configured via the mmio-conf1.addrs parameter.\n"
                },
                {
                    "name": "mmio-conf1-ext",
                    "content": "Direct hardware access via Extended PCIe Intel configuration mechanism 1  via  memory-\nmapped  I/O.   Mostly  used  on non-i386 platforms. Requires root privileges. Warning:\nThis method needs to be properly configured via the mmio-conf1-ext.addrs parameter.\n\necam   Direct hardware access  via  PCIe  ECAM  (Enhanced  Configuration  Access  Mechanism).\nAvailable on all PCIe-compliant hardware. Requires root privileges and access to phys‐\nical  memory (on Linux systems disabled CONFIGSTRICTDEVMEM option). On ACPI compati‐\nble systems is ECAM mapping read from the MCFG table specified  by  the  ecam.acpimcfg\nparameter.  On EFI compatible systems, ACPI MCFG table can be located in physical mem‐\nory via EFI system table specified by the ecam.efisystab parameter. On  FreeBSD/NetBSD\nsystems,  physical  address of ACPI MCFG table can be located by kenv or sysctl inter‐\nface when the ecam.bsd parameter is not disabled. On x86 BIOS compatible systems, ACPI\nMCFG table can be located in physical memory by scanning  x86  BIOS  memory  when  the\necam.x86bios  parameter  is not disabled. Alternatively ECAM mappings can be specified\nby the ecam.addrs parameter which takes precedence over ACPI MCFG table.  This  option\nis required on systems without ACPI and also on systems without EFI or x86 BIOS.\n"
                },
                {
                    "name": "fbsd-device",
                    "content": "The /dev/pci device on FreeBSD. Requires root privileges.\n"
                },
                {
                    "name": "aix-device",
                    "content": "Access method used on AIX. Requires root privileges.\n"
                },
                {
                    "name": "nbsd-libpci",
                    "content": "The /dev/pci0 device on NetBSD accessed using the local libpci library.\n"
                },
                {
                    "name": "obsd-device",
                    "content": "The /dev/pci device on OpenBSD. Requires root privileges.\n\ndump   Read  the  contents  of configuration registers from a file specified in the dump.name\nparameter. The format corresponds to the output of lspci -x.\n\ndarwin Access method used on Mac OS X / Darwin. Must be run as root and the system must  have\nbeen booted with debug=0x144.\n"
                },
                {
                    "name": "win32-cfgmgr32",
                    "content": "Device  listing  on  Windows  systems using the Windows Configuration Manager via cfg‐\nmgr32.dll system library. This method  does  not  require  any  special  Administrator\nrights  or privileges. Configuration Manager provides only basic information about de‐\nvices, assigned resources and device tree structure. There is no  access  to  the  PCI\nconfiguration  space but libpci either tries to use other access method to access con‐\nfiguration space or it provides read-only virtual emulation based on information  from\nConfiguration  Manager. Other access method can be chosen by the win32.cfgmethod para‐\nmeter. By default the first working one is selected (if any). Starting with Windows  8\n(NT  6.2)  it is not possible to retrieve resources from 32-bit application or library\non 64-bit system.\n"
                },
                {
                    "name": "win32-sysdbg",
                    "content": "Access to the PCI configuration space via NT  SysDbg  interface  on  Windows  systems.\nProcess needs to have Debug privilege, which local Administrators have by default. Not\navailable  on  64-bit  systems and neither on recent 32-bit systems. Only devices from\nthe first domain are accessible and only first 256  bytes  of  the  PCI  configuration\nspace is accessible via this method.\n"
                },
                {
                    "name": "win32-kldbg",
                    "content": "Access  to the PCI configuration space via Kernel Local Debugging Driver kldbgdrv.sys.\nThis driver is not part of the Windows system but is  part  of  the  Microsoft  WinDbg\ntool.  It  is required to have kldbgdrv.sys driver installed in the system32 directory\nor to have windbg.exe or kd.exe binary in PATH.  kldbgdrv.sys driver has some restric‐\ntions. Process needs to have Debug privilege and Windows system has to be booted  with\nDebugging  option. Debugging option can be enabled by calling (takes effect after next\nboot): bcdedit /debug on\n\nDownload links for WinDbg 6.12.2.633 standalone installer from Microsoft  Windows  SDK\nfor Windows 7 and .NET Framework 4:\namd64:               https://download.microsoft.com/download/A/6/A/A6AC035D-DA3F-4F0C-\nADA4-37C8E5D34E3D/setup/WinSDKDebuggingToolsamd64/dbgamd64.msi\nia64:                https://download.microsoft.com/download/A/6/A/A6AC035D-DA3F-4F0C-\nADA4-37C8E5D34E3D/setup/WinSDKDebuggingToolsia64/dbgia64.msi\nx86:                 https://download.microsoft.com/download/A/6/A/A6AC035D-DA3F-4F0C-\nADA4-37C8E5D34E3D/setup/WinSDKDebuggingTools/dbgx86.msi\n\nArchived download links of previous WinDbg versions:\nhttps://web.archive.org/web/20110221133326/https://www.microsoft.com/whdc/devtools/de‐\nbugging/installx86.mspx\nhttps://web.archive.org/web/20110214012715/https://www.microsoft.com/whdc/devtools/de‐\nbugging/install64bit.mspx\n\n"
                }
            ]
        },
        "PARAMETERS": {
            "content": "The library is controlled by several parameters. They should have  sensible  default  values,\nbut in case you want to do something unusual (or even something weird), you can override them\n(see the -O switch of lspci).\n\n",
            "subsections": [
                {
                    "name": "Parameters of specific access methods",
                    "content": ""
                },
                {
                    "name": "dump.name",
                    "content": "Name of the bus dump file to read from.\n"
                },
                {
                    "name": "fbsd.path",
                    "content": "Path to the FreeBSD PCI device.\n"
                },
                {
                    "name": "nbsd.path",
                    "content": "Path to the NetBSD PCI device.\n"
                },
                {
                    "name": "obsd.path",
                    "content": "Path to the OpenBSD PCI device.\n"
                },
                {
                    "name": "proc.path",
                    "content": "Path to the procfs bus tree.\n"
                },
                {
                    "name": "sysfs.path",
                    "content": "Path to the sysfs device tree.\n"
                },
                {
                    "name": "devmem.path",
                    "content": "Path to the /dev/mem device.\n"
                },
                {
                    "name": "mmio-conf1.addrs",
                    "content": "Physical  addresses  of  memory-mapped  I/O ports for Intel configuration mechanism 1.\nCF8 (address) and CFC (data) I/O port addresses are separated by  slash  and  multiple\naddresses   for   different   PCI   domains   are   separated   by   commas.   Format:\n0xaddr1/0xdata1,0xaddr2/0xdata2,...\n"
                },
                {
                    "name": "mmio-conf1-ext.addrs",
                    "content": "Physical addresses of memory-mapped I/O ports for Extended  PCIe  Intel  configuration\nmechanism 1.  It has same format as mmio-conf1.addrs parameter.\n"
                },
                {
                    "name": "ecam.addrs",
                    "content": "Physical  addresses  of  PCIe  ECAM mappings. Each mapping must contains first PCI bus\nnumber and physical address where mapping starts. And then it may contain  the  length\nof  the  mapping, the last PCI bus number and PCI domain number. When the last PCI bus\nnumber is not provided then it is calculated from the length of the mapping or  it  is\nassumed  0xff.  When  length of the mapping is provided then it is calculated from the\nlast PCI bus number. And when PCI domain is not provided then 0x0 is assumed. All num‐\nbers must be supplied in hexadecimal form (leading prefix 0x is not required).  Multi‐\nple      mappings      are      separated      by      commas.       Format:      [do‐\nmain:]startbus[-endbus]:startaddr[+length],...\n"
                },
                {
                    "name": "ecam.acpimcfg",
                    "content": "Path to the ACPI MCFG table. Processed by the glob(3)  function,  so  it  may  contain\nwildcards (*).\n"
                },
                {
                    "name": "ecam.efisystab",
                    "content": "Path to the EFI system table.\n"
                },
                {
                    "name": "ecam.bsd",
                    "content": "When  not  set to 0 then use BSD kenv or sysctl to find ACPI MCFG table. Default value\nis 1 on BSD systems.\n"
                },
                {
                    "name": "ecam.x86bios",
                    "content": "When not set to 0 then scan x86 BIOS memory for ACPI MCFG table. Default value is 1 on\nx86 systems.\n"
                },
                {
                    "name": "win32.cfgmethod",
                    "content": "Config space access method to use with win32-cfgmgr32 on Windows systems.  Value  auto\nor an empty string selects the first access method which supports access to the config\nspace  on  Windows.  Value win32-cfgmgr32 or none only builds a read-only virtual emu‐\nlated config space with information from the Configuration Manager.\n\n"
                },
                {
                    "name": "Parameters for resolving of ID's via DNS",
                    "content": ""
                },
                {
                    "name": "net.domain",
                    "content": "DNS domain containing the ID database.\n"
                },
                {
                    "name": "net.cache_name",
                    "content": "Name of the file used for caching of resolved ID's.\n\n"
                },
                {
                    "name": "Parameters for resolving of ID's via UDEV's HWDB",
                    "content": ""
                },
                {
                    "name": "hwdb.disable",
                    "content": "Disable use of HWDB if set to a non-zero value.\n\n"
                }
            ]
        },
        "SEE ALSO": {
            "content": "lspci(8), setpci(8), pci.ids(5), update-pciids(8)\n\n",
            "subsections": []
        },
        "AUTHOR": {
            "content": "The PCI Utilities are maintained by Martin Mares <mj@ucw.cz>.\n\npciutils-3.10.0                              01 May 2023                                   pcilib(7)",
            "subsections": []
        }
    },
    "summary": "pcilib - a library for accessing PCI devices",
    "flags": [],
    "examples": [],
    "see_also": [
        {
            "name": "lspci",
            "section": "8",
            "url": "https://www.chedong.com/phpMan.php/man/lspci/8/json"
        },
        {
            "name": "setpci",
            "section": "8",
            "url": "https://www.chedong.com/phpMan.php/man/setpci/8/json"
        },
        {
            "name": "pci.ids",
            "section": "5",
            "url": "https://www.chedong.com/phpMan.php/man/pci.ids/5/json"
        },
        {
            "name": "update-pciids",
            "section": "8",
            "url": "https://www.chedong.com/phpMan.php/man/update-pciids/8/json"
        }
    ]
}