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

It is currently Thu Jul 02, 2020 10:55 am

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

:D :) ;) :( :o :shock: :? 8-) :lol: :x :P :oops: :cry: :evil: :twisted: :roll: :!: :?: :idea: :arrow: :| :mrgreen: :geek: :ugeek:
Font size:
Font colour
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 - Linux network interface pci slot information - lspci / Intel or Broadcom
Author Message
Post subject: Linux network interface pci slot information - lspci / Intel or Broadcom  |  Post Posted: Fri Jan 16, 2015 7:58 pm
How to determine PCI slot information of your Linux server's network interface cards.
Network card manufacturers provide interface cards with more than one port and in some situations you can have both an Intel chip based card and Broadcome one.
Linux "ifconfig" and "iproute2" utilies show ethernet card information like IP address, kernel flags, state, counters, but it does not show manufacturer information nor kernel driver information for that interface.

How to determine if an eth interface is Intel or Broadcom in Linux based on their PCI slot address.

Method one: the ethtool way (short) to find out driver information on ethernet card.
# ethtool -i eth0       
driver: bnx2
version: 2.2.5f
firmware-version: 5.0.9 bc 5.0.6 NCSI 2.0.3
bus-info: 0000:01:00.0
supports-statistics: yes
supports-test: yes
supports-eeprom-access: yes
supports-register-dump: yes
supports-priv-flags: no

# modinfo bnx2
filename:       /lib/modules/3.10.0-5-pve/kernel/drivers/net/ethernet/broadcom/bnx2.ko
version:        2.2.5f
license:        GPL
description:    Broadcom NetXtreme II BCM5706/5708/5709/5716 Driver
author:         Michael Chan <>
srcversion:     FB6AE382ED134433CE0E4A7
alias:          pci:v000014E4d0000163Csv*sd*bc*sc*i*
alias:          pci:v000014E4d0000163Bsv*sd*bc*sc*i*
alias:          pci:v000014E4d0000163Asv*sd*bc*sc*i*
alias:          pci:v000014E4d00001639sv*sd*bc*sc*i*
alias:          pci:v000014E4d000016ACsv*sd*bc*sc*i*
alias:          pci:v000014E4d000016AAsv*sd*bc*sc*i*
alias:          pci:v000014E4d000016AAsv0000103Csd00003102bc*sc*i*
alias:          pci:v000014E4d0000164Csv*sd*bc*sc*i*
alias:          pci:v000014E4d0000164Asv*sd*bc*sc*i*
alias:          pci:v000014E4d0000164Asv0000103Csd00003106bc*sc*i*
alias:          pci:v000014E4d0000164Asv0000103Csd00003101bc*sc*i*
vermagic:       3.10.0-5-pve SMP mod_unload modversions
parm:           disable_msi:Disable Message Signaled Interrupt (MSI) (int)
parm:           stop_on_tx_timeout:For debugging purposes, prevent a chip  reset when a tx timeout occurs (int)

Quote from "man ethtool":
-i --driver
Queries the specified network device for associated driver information.

There you have it: Broadcom.

Method two: Using lspci and the linux kernel mapped /sys filesystem:
For this, lspci is queried to map server pci bus information. We're interested in "-tv" switches:
lspci is a utility for displaying information about PCI buses in the system and devices connected to them.

By default, it shows a brief list of devices. Use the options described below to request either a more verbose output or output intended for parsing by
other programs.

If you are going to report bugs in PCI device drivers or in lspci itself, please include output of "lspci -vvx" or even better "lspci -vvxxx" (however, see
below for possible caveats).

Some parts of the output, especially in the highly verbose modes, are probably intelligible only to experienced PCI hackers. For exact definitions of the
fields, please consult either the PCI specifications or the header.h and /usr/include/linux/pci.h include files.

Access to some parts of the PCI configuration space is restricted to root on many operating systems, so the features of lspci available to normal users are
limited. However, lspci tries its best to display as much as available and mark all other information with <access denied> text.
-t Show a tree-like diagram containing all buses, bridges, devices and connections between them.
-v Be verbose and display detailed information about all devices.
# lspci -tv
  \-[0000:00]-+-00.0  Intel Corporation 5520 I/O Hub to ESI Port
             +-01.0-[01]--+-00.0  Broadcom Corporation NetXtreme II BCM5709 Gigabit Ethernet
             |            \-00.1  Broadcom Corporation NetXtreme II BCM5709 Gigabit Ethernet
             +-03.0-[02]--+-00.0  Broadcom Corporation NetXtreme II BCM5709 Gigabit Ethernet
             |            \-00.1  Broadcom Corporation NetXtreme II BCM5709 Gigabit Ethernet
             +-04.0-[03]----00.0  LSI Logic / Symbios Logic MegaRAID SAS 1078

So we have a Broadcom card with four ports. Which one is which ?
# find /sys/ | grep eth0
:~# find /sys/devices/ -name device | grep eth

Between the two outputs above, we can see which interface port belongs to which interface card (eth0 to eth3 are part of a quad port BCM5709 card).

An there is also dmesg way to find out your card is Intel or Broadcom:
# dmesg | grep eth0
[    1.062475] bnx2 0000:01:00.0 eth0: Broadcom NetXtreme II BCM5709 1000Base-T (C0) PCI Express found at mem d6000000, IRQ 36, node addr 00:26:a1:4e:1c:2c
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 ]