How is a PCI / PCIe BAR size determined?

前端 未结 3 1675
无人及你
无人及你 2020-12-30 06:48

I know that the base address register (BAR) in PCI configuration space defines the start location of a PCI address, but how does the size of this region get established?

3条回答
  •  南方客
    南方客 (楼主)
    2020-12-30 07:20

    Found the answer at OSDev Wiki:

    "To determine the amount of address space needed by a PCI device, you must save the original value of the BAR, write a value of all 1's to the register, then read it back."

提交回复
热议问题