Jump to content

lspci

From Wikipedia, the free encyclopedia

This is an old revision of this page, as edited by 奧田95 (talk | contribs) at 14:04, 17 December 2020. The present address (URL) is a permanent link to this revision, which may differ significantly from the current revision.


Developer(s)Martin Mareš
Initial release7 February 1998 (1998-02-07)
Stable release
3.5.4 / 25 February 2017; 7 years ago (2017-02-25)
Repository
Written inC
Operating systemLinux, Unix-like, Microsoft Windows, KolibriOS
PlatformAll ports can work on at least x86 (32-bit and/or 64-bit); the Linux, FreeBSD, NetBSD, OpenBSD, and AIX ports can also work on other CPU architectures.
TypeUtility software
LicenseGNU General Public License
Websitemj.ucw.cz/sw/pciutils

lspci is a command on Unix-like operating systems that prints ("lists") detailed information about all PCI buses and devices in the system.[1] It is based on a common portable library libpci which offers access to the PCI configuration space on a variety of operating systems.

Example usage

Example output on a Linux system:

# lspci
00:00.0 Host bridge: Intel Corporation 82815 815 Chipset Host Bridge and Memory Controller Hub (rev 11)
00:02.0 VGA compatible controller: Intel Corporation 82815 Chipset Graphics Controller (CGC) (rev 11)
00:1e.0 PCI bridge: Intel Corporation 82801 Mobile PCI Bridge (rev 03)
00:1f.0 ISA bridge: Intel Corporation 82801BAM ISA Bridge (LPC) (rev 03)
00:1f.1 IDE interface: Intel Corporation 82801BAM IDE U100 Controller (rev 03)
00:1f.2 USB Controller: Intel Corporation 82801BA/BAM USB Controller #1 (rev 03)
00:1f.3 SMBus: Intel Corporation 82801BA/BAM SMBus Controller (rev 03)
00:1f.4 USB Controller: Intel Corporation 82801BA/BAM USB Controller #2 (rev 03)
00:1f.5 Multimedia audio controller: Intel Corporation 82801BA/BAM AC'97 Audio Controller (rev 03)
01:03.0 CardBus bridge: O2 Micro, Inc. OZ6933/711E1 CardBus/SmartCardBus Controller (rev 01)
01:03.1 CardBus bridge: O2 Micro, Inc. OZ6933/711E1 CardBus/SmartCardBus Controller (rev 01)
01:0b.0 PCI bridge: Actiontec Electronics Inc Mini-PCI bridge (rev 11)
02:04.0 Ethernet controller: Intel Corporation 82557/8/9/0/1 Ethernet Pro 100 (rev 08)
02:08.0 Communication controller: Agere Systems WinModem 56k (rev 01)

If many devices are shown as unknown (e.g. "Unknown device 2830 (rev 02)"), issuing the command update-pciids will usually correct this.

lsusb

lsusb[2] is a similar command for USB buses and devices. To make use of all the features of this program, you need to have a Linux kernel which supports the /proc/bus/usb interface (e.g., Linux kernel 2.3.15 or newer).

hwinfo

hwinfo[3] is for all the hardware.[4] Hwinfo output reports for various computer models are collected in a public GitHub repository.[5]

lshw

lshw is a subset of what hwinfo presents.[6][7]

Other platforms

The equivalent command for FreeBSD is pciconf -l. pciconf can also perform other functions such as reading and writing PCI registers. For more information, see the man page.

The HWiNFO tool, which is not related to the hwinfo tool mentioned above, can be downloaded in binary form at no cost. It is claimed to be a "system information and diagnostics comprehensive hardware analysis, monitoring and reporting for Windows and DOS".[citation needed]

Similar commands

  • dmesg — prints the message buffer of the kernel.
  • uname — prints the name, version and other details about the current machine and the operating system.
  • dmidecode — prints information from DMI interface from BIOS.
  • lscpu — prints information about CPU(s).
  • lsscsi — prints information about SCSI devices.

See also

References

  1. ^ https://linux.die.net/man/8/lspci
  2. ^ lsusb(8) – Linux Administration and Privileged Commands Manual
  3. ^ "hwinfo(8) — hwinfo — Debian testing — Debian Manpages". manpages.debian.org. Retrieved 2020-12-17.
  4. ^ Discover your hardware in Linux, H-node.org
  5. ^ Large collection of hwinfo reports for various computer models
  6. ^ 16 commands to check hardware information on Linux on BinaryTides.com, April 2014
  7. ^ How to interpret lshw output on Ezix.org; retrieved in October 2016