
GRMON3-UM
June 2019, Version 3.1.0
171
www.cobham.com/gaisler
70. pci - syntax
NAME
pci - Control the PCI bus master
SYNOPSIS
pci subcommand ?
args...
?
DESCRIPTION
The PCI debug drivers are mainly useful for PCI host systems. The pci init command initializes the host's target
BAR1 to point to RAM (PCI address 0x40000000 -> AHB address 0x4000000) and enables PCI memory space and
bus mastering. Commands are provided for initializing the bus, scanning the bus, configuring the found resources,
disabling byte twisting and displaying information. Note that on non-host systems only the info command has
any effect.
The pci scan command can be used to print the current configuration of the PCI bus. If a OS has initialized the
PCI core and the PCI bus (at least enumerated all PCI buses) the scan utility can be used to see how the OS has
configured the PCI address space. Note that scanning a multi-bus system that has not been enumerated will fail.
The pci conf command can fail to configure all found devices if the PCI address space addressable by the host
controller is smaller than the amount of memory needed by the devices.
A configured PCI system can be registered into the GRMON device handling system similar to the on-chip AMBA
bus devices, controlled using the pci bus commands. GRMON will hold a copy of the PCI configuration in memory
until a new pci conf, pci bus unreg or pci scan is issued. The user is responsible for updating GRMON's PCI
configuration if the configuration is updated in hardware. The devices can be inspected from info sys and Tcl
variables making read and writing PCI devices configuration space easier. The Tcl variables are named in a similar
fashion to AMBA devices, for example puts $pdev0::status prints the STATUS register of PCI device0. See pci
bus reference description below and the Tcl API description in the manual.
pci bt ?
boolean
?
Enable/Disable the byte twisting (if supported by host controller)
pci bus reg
Register a previously configured PCI bus into the GRMON device handling system. If the PCI bus has not
been configured previously the pci conf is automatically called first (similar to pci conf -reg).
pci bus unreg
Unregister (remove) a previously registered PCI bus from the GRMON device handling system.
pci cfg8
deviceid
offset
pci cfg16
deviceid
offset
pci cfg32
deviceid
offset
Read a 8-, 16- or 32-bit value from configuration space. The device ID selects which PCI device/function
is address during the configuration access. The offset must must be located with the device's space and
be aligned to access type. Three formats are allowed to specify the
deviceid
: 1.
bus:slot:func
,
2. device name (pdev#), 3. host. It's allowed to skip the bus index, i.e. only specifying
slot:func
, it
will then default to bus index 0. The ID numbers are specified in hex. If "host" is given the Host Bridge
Controller itself will be queried (if supported by Host Bridge). A device name (for example "pdev0") may
also be used to identify a device found from the info sys command output.
pci conf ?
-reg
?
Enumerate all PCI buses, configures the BARs of all devices and enables PCI-PCI bridges where needed.
If -reg is given the configured PCI bus is registered into GRMON device handling system similar to pci
bus reg, see above.
pci init
Initializes the host controller as described above
pci info
Displays information about the host controller
Содержание GRMON3
Страница 56: ...GRMON3 UM June 2019 Version 3 1 0 56 www cobham com gaisler...
Страница 114: ...GRMON3 UM June 2019 Version 3 1 0 114 www cobham com gaisler...
Страница 123: ...GRMON3 UM June 2019 Version 3 1 0 123 www cobham com gaisler dcache...
Страница 156: ...GRMON3 UM June 2019 Version 3 1 0 156 www cobham com gaisler SEE ALSO Section 6 13 On chip logic analyzer driver...
Страница 208: ...GRMON3 UM June 2019 Version 3 1 0 208 www cobham com gaisler SEE ALSO Section 3 5 Tcl integration...