Linux, FreeBSD, Juniper, Cisco / Network security articles and troubleshooting guides

FAQ
It is currently Sun Feb 05, 2023 10:41 pm


Username:
Subject:
Message body:
Enter your message here, it may contain no more than 60000 characters. 

Smilies
:D :) ;) :( :o :shock: :? 8-) :lol: :x :P :oops: :cry: :evil: :twisted: :roll: :!: :?: :idea: :arrow: :| :mrgreen: :geek: :ugeek:
Font size:
 
Font colour
Options:
BBCode is ON
[img] is ON
[flash] is OFF
[url] is ON
Smilies are ON
Disable BBCode
Disable smilies
Do not automatically parse URLs
Confirmation code
Confirmation code:
In an effort to prevent automatic submissions, we require that you enter both of the words displayed into the text field underneath.
     

Topic review - How to list PCI devices in FreeBSD - pciconf
Author Message
Post subject: How to list PCI devices in FreeBSD - pciconf  |  Post Posted: Mon Jul 22, 2013 9:58 am
FreeBSD has a nice utility called pciconf that can be used to list pci devices. I will show here two arguments that make the output a little better for the reader.

Man pciconf:
Quote:
PCICONF(8) FreeBSD System Manager's Manual PCICONF(8)

NAME
pciconf -- diagnostic utility for the PCI bus

SYNOPSIS
pciconf -l [-bcv]
pciconf -a selector
pciconf -r [-b | -h] selector addr[:addr2]
pciconf -w [-b | -h] selector addr value

DESCRIPTION
The pciconf utility provides a command line interface to functionality
provided by the pci(4) ioctl(2) interface. As such, some of the func-
tions are only available to users with write access to /dev/pci, normally
only the super-user.

With the -l option, it lists all devices found by the boot probe in the
following format:

foo0@pci0:0:4:0: class=0x010000 card=0x00000000 chip=0x000f1000 rev=0x01 hdr=0x00
bar0@pci0:0:5:0: class=0x000100 card=0x00000000 chip=0x88c15333 rev=0x00 hdr=0x00
none0@pci0:0:6:0: class=0x020000 card=0x00000000 chip=0x802910ec rev=0x00 hdr=0x00
...
If the -v option is supplied, pciconf will attempt to load the ven-
dor/device information database, and print vendor, device, class and sub-
class identification strings for each device.

Code:
# pciconf -lv
hostb0@pci0:0:0:0:      class=0x060000 card=0x00000000 chip=0x71908086 rev=0x03 hdr=0x00
    vendor     = 'Intel Corporation'
    device     = '82443BX/ZX 440BX/ZX CPU to PCI Bridge (AGP Implemented)'
    class      = bridge
    subclass   = HOST-PCI
pcib1@pci0:0:1:0:       class=0x060400 card=0x00000000 chip=0x71918086 rev=0x03 hdr=0x01
    vendor     = 'Intel Corporation'
    device     = '440BX/ZX AGPset PCI-to-PCI bridge (82443BX/ZX)'
    class      = bridge
    subclass   = PCI-PCI
isab0@pci0:0:4:0:       class=0x060100 card=0x00000000 chip=0x71108086 rev=0x02 hdr=0x00
    vendor     = 'Intel Corporation'
    device     = 'PIIX4/4E/4M ISBridgeA  (82371AB/EB/MB)'
    class      = bridge
    subclass   = PCI-ISA
atapci0@pci0:0:4:1:     class=0x010180 card=0x00000000 chip=0x71118086 rev=0x01 hdr=0x00
    vendor     = 'Intel Corporation'
    device     = 'PIIX4/4E/4M IDE Controller (82371AB/EB/MB)'
    class      = mass storage
    subclass   = ATA
uhci0@pci0:0:4:2:       class=0x0c0300 card=0x00000000 chip=0x71128086 rev=0x01 hdr=0x00
    vendor     = 'Intel Corporation'
    device     = 'PIIX4/4E/4M USB Interface (82371AB/EB/MB)'
    class      = serial bus
    subclass   = USB
none0@pci0:0:4:3:       class=0x068000 card=0x00000000 chip=0x71138086 rev=0x02 hdr=0x00
    vendor     = 'Intel Corporation'
    device     = 'PIIX4/4E/4M Power Management Controller (82371AB/EB/MB)'
    class      = bridge
xl0@pci0:0:11:0:        class=0x020000 card=0x905510b7 chip=0x905510b7 rev=0x30 hdr=0x00
    vendor     = '3COM Corp, Networking Division'
    device     = 'Fast Etherlink 10/100 PCI TX NIC (3C905-TX)'
    class      = network
    subclass   = ethernet
twe0@pci0:0:16:0:       class=0x010400 card=0x100113c1 chip=0x100113c1 rev=0x01 hdr=0x00
    vendor     = '3ware Inc'
    device     = 'ATA-133 Storage Controller (7000/8000 series)'
    class      = mass storage
    subclass   = RAID
em0@pci0:0:18:0:        class=0x020000 card=0x00db0e11 chip=0x10108086 rev=0x01 hdr=0x00
    vendor     = 'Intel Corporation'
    device     = 'Dual Port Gigabit Ethernet Controller (Copper) (82546EB)'
    class      = network
    subclass   = ethernet
em1@pci0:0:18:1:        class=0x020000 card=0x00db0e11 chip=0x10108086 rev=0x01 hdr=0x00
    vendor     = 'Intel Corporation'
    device     = 'Dual Port Gigabit Ethernet Controller (Copper) (82546EB)'
    class      = network
    subclass   = ethernet
vgapci0@pci0:1:0:0:     class=0x030000 card=0xff00102b chip=0x0521102b rev=0x03 hdr=0x00
    vendor     = 'Matrox Electronic Systems Ltd.'
    device     = '102B (Matrox lnc MGA-G200B)'
    class      = display
    subclass   = VGA
Jump to:  
cronNews News Site map Site map SitemapIndex SitemapIndex RSS Feed RSS Feed Channel list Channel list


Delete all board cookies | The team | All times are UTC - 5 hours [ DST ]



phpBB SEO