1 .TH setpci 8 "@TODAY@" "@VERSION@" "The PCI Utilities"
4 setpci \- configure PCI devices
14 is a utility for querying and configuring PCI devices.
16 All numbers are entered in hexadecimal notation.
18 Root privileges are necessary for almost all operations, excluding reads
19 of the standard header of the configuration space on some operating systems.
22 for details on access rights.
31 to be verbose and display detailed information about configuration space accesses.
36 not to complain when there's nothing to do (when no devices are selected).
37 This option is intended for use in widely-distributed configuration scripts
38 where it's uncertain whether the device in question is present in the machine
42 `Demo mode' -- don't write anything to the configuration registers.
45 to see what your complex sequence of
47 operations does before you actually execute it.
52 version. This option should be used stand-alone.
54 .SS PCI access options
56 The PCI utilities use the PCI library to talk to PCI devices (see
57 \fBpcilib\fP(7) for details). You can use the following options to
58 influence its behavior:
61 The library supports a variety of methods to access the PCI hardware.
62 By default, it uses the first access method available, but you can use
63 this option to override this decision. See \fB-A help\fP for a list of
64 available methods and their descriptions.
67 The behavior of the library is controlled by several named parameters.
68 This option allows to set the value of any of the parameters. Use \fB-O help\fP
69 for a list of known parameters and their default values.
72 Use direct hardware access via Intel configuration mechanism 1.
73 (This is a shorthand for \fB-A intel-conf1\fP.)
76 Use direct hardware access via Intel configuration mechanism 2.
77 (This is a shorthand for \fB-A intel-conf2\fP.)
80 Increase debug level of the library.
84 Before each sequence of operations you need to select which devices you wish that
87 .B -s [[[[<domain>]:]<bus>]:][<slot>][.[<func>]]
88 Show only devices in the specified domain (in case your machine has several host bridges,
89 they can either share a common bus number space or each of them can address a PCI domain
90 of its own; domains are numbered from 0 to ffff), bus (0 to ff), slot (0 to 1f) and function (0 to 7).
91 Each component of the device address can be omitted or set to "*", both meaning "any value". All numbers are
92 hexadecimal. E.g., "0:" means all devices on bus 0, "0" means all functions of device 0
93 on any bus, "0.3" selects third function of device 0 on all buses and ".4" shows only
94 the fourth function of each device.
96 .B -d [<vendor>]:[<device>]
97 Select devices with specified vendor and device ID. Both ID's are given in
98 hexadecimal and may be omitted or given as "*", both meaning "any value".
102 To query value of a configuration register, just name it (either by typing its name or
103 by typing register address with optional
108 suffix specifying register width as byte, word or longword).
110 To set a register, write
114 is the same as you would use to query the register and
116 is a comma-separated list of values you want to write starting with the given
117 address. Each value to be written can be specified either as a hexadecimal number
120 pair which causes the bits corresponding to binary ones in the
122 to be changed to values of the corresponding bits in the
129 knows the following configuration register names. See PCI bus specifications for their precise
133 .B /usr/include/linux/pci.h
134 for a couple of comments.
198 CB_SUBSYSTEM_VENDOR_ID
207 The PCI Utilities are maintained by Martin Mares <mj@ucw.cz>.