PCI: Difference between revisions

283 bytes added ,  4 years ago
more headings to ease navigation
[unchecked revision][unchecked revision]
m (Identify the actual in & out function used in the code examples)
(more headings to ease navigation)
Line 137:
 
 
==== Common Header Fields ====
The following field descriptions are common to all Header Types:
* '''Device ID:''' Identifies the particular device. Where valid IDs are allocated by the vendor.
Line 150 ⟶ 151:
* '''Latency Timer:''' Specifies the latency timer in units of PCI bus clocks.
* '''Cache Line Size:''' Specifies the system cache line size in 32-bit units. A device can limit the number of cacheline sizes it can support, if a unsupported value is written to this field, the device will behave as if a value of 0 was written.
 
 
==== Header Type 0x00 ====
 
This table is applicable if the Header Type is 00h. (Figure 2)
Line 242 ⟶ 246:
* '''Capabilities Pointer:''' Points (i.e. an offset into this function's configuration space) to a linked list of new capabilities implemented by the device. Used if bit 4 of the status register (Capabilities List bit) is set to 1. The bottom two bits are reserved and should be masked before the Pointer is used to access the Configuration Space.
 
 
==== Header Type 0x01 (PCI-to-PCI bridge) ====
 
This table is applicable if the Header Type is 01h (PCI-to-PCI bridge) (Figure 3)
Line 327 ⟶ 333:
|}
 
 
===== Header Type Register =====
 
Here is the layout of the Header Type register:
Line 342 ⟶ 350:
'''Header Type''' - 00h Standard Header - 01h PCI-to-PCI Bridge - 02h CardBus Bridge
 
 
===== BIST Register =====
 
Here is the layout of the BIST register:
Line 357 ⟶ 367:
 
'''Completion Code''' - Will return 0, after BIST execution, if the test completed successfully.
 
 
==== Header Type 0x02 (PCI-to-CardBus bridge) ====
 
This table is applicable if the Header Type is 02h (PCI-to-CardBus bridge)
Line 448 ⟶ 461:
| colspan="4" | 16-bit PC Card legacy mode base address
|}
 
 
===== Command Register =====
 
Here is the layout of the Command register:
Line 491 ⟶ 507:
'''I/O Space''' - If set to 1 the device can respond to I/O Space accesses; otherwise, the device's response is disabled.
 
 
===== Status Register =====
 
Here is the layout of the Status register:
Line 541 ⟶ 559:
 
=== Base Address Registers ===
 
Base address Registers (or BARs) can be used to hold memory addresses used by the device, or offsets for port addresses. Typically, memory address BARs need to be located in physical ram while I/O space BARs can reside at any memory address (even beyond physical memory). To distinguish between them, you can check the value of the lowest bit. The following tables describe the two types of BARs:
 
Anonymous user