/*
** The way to parse the PCI bus info from the /proc/bus/pci/devices
**
** That file contains one line for each device.
**
** Each line contains the following fields delimited by white space:
**
** 0201 -- [02] bus number, [01] devfn
** 8086105e -- vendor/device
** 11 -- IRQ
** cfc00004 -- MEMBAR 0 including control IO vs. MEM info
** 00000000 -- MEMBAR 1
** 00000000 -- MEMBAR 2
** 00000000 -- MEMBAR 3
** 0000c001 -- MEMBAR 4
** 00000000 -- MEMBAR 5
** 00000000 -- MEMBAR 6
** 00020000 -- MEMBAR 0 length
** 00000000 -- MEMBAR 1 length
** 00000000 -- MEMBAR 2 length
** 00000000 -- MEMBAR 3 length
** 00000020 -- MEMBAR 4 length
** 00000000 -- MEMBAR 5 length
** 00000000 -- MEMBAR 6 length
** e1000 -- driver name, optional
*/
/proc/bus/pci/devices 各个域的意义
最新推荐文章于 2024-07-17 15:01:27 发布
本文介绍如何从/proc/bus/pci/devices文件中解析PCI设备信息。该文件为每一台PCI设备提供了一行记录,包括总线号、设备号、供应商/设备ID、IRQ编号、内存基址寄存器(MEMBAR)及其长度等信息。
960

被折叠的 条评论
为什么被折叠?



