From f1bbdf870904ead2da641f88cb9d996462cd05d5 Mon Sep 17 00:00:00 2001 From: Konstantin Belousov Date: Thu, 20 Feb 2020 17:10:25 +0000 Subject: [PATCH] Print out some newly added PCIe extended capabilities and subclasses. Taken from https://pcisig.com/sites/default/files/files/PCI_Code-ID_r_1_11__v24_Jan_2019.pdf Submitted by: Dmitry Luhtionov MFC after: 1 week --- usr.sbin/pciconf/cap.c | 14 ++++++++++++++ usr.sbin/pciconf/pciconf.c | 25 +++++++++++++++++++++++++ 2 files changed, 39 insertions(+) diff --git a/usr.sbin/pciconf/cap.c b/usr.sbin/pciconf/cap.c index cb8e28a7427b..3fce34519bec 100644 --- a/usr.sbin/pciconf/cap.c +++ b/usr.sbin/pciconf/cap.c @@ -1015,6 +1015,20 @@ static struct { { PCIZ_LN_REQ, "LN Requester" }, { PCIZ_DPC, "Downstream Port Containment" }, { PCIZ_L1PM, "L1 PM Substates" }, + { PCIZ_PTM, "Precision Time Measurement" }, + { PCIZ_M_PCIE, "PCIe over M-PHY" }, + { PCIZ_FRS, "FRS Queuing" }, + { PCIZ_RTR, "Readiness Time Reporting" }, + { PCIZ_DVSEC, "Designated Vendor-Specific" }, + { PCIZ_VF_REBAR, "VF Resizable BAR" }, + { PCIZ_DLNK, "Data Link Feature" }, + { PCIZ_16GT, "Physical Layer 16.0 GT/s" }, + { PCIZ_LMR, "Lane Margining at Receiver" }, + { PCIZ_HIER_ID, "Hierarchy ID" }, + { PCIZ_NPEM, "Native PCIe Enclosure Management" }, + { PCIZ_PL32, "Physical Layer 32.0 GT/s" }, + { PCIZ_AP, "Alternate Protocol" }, + { PCIZ_SFI, "System Firmware Intermediary" }, { 0, NULL } }; diff --git a/usr.sbin/pciconf/pciconf.c b/usr.sbin/pciconf/pciconf.c index 0d2aad12e305..817de6ec09ed 100644 --- a/usr.sbin/pciconf/pciconf.c +++ b/usr.sbin/pciconf/pciconf.c @@ -665,12 +665,17 @@ static struct {PCIC_STORAGE, PCIS_STORAGE_SATA, "SATA"}, {PCIC_STORAGE, PCIS_STORAGE_SAS, "SAS"}, {PCIC_STORAGE, PCIS_STORAGE_NVM, "NVM"}, + {PCIC_STORAGE, PCIS_STORAGE_UFS, "UFS"}, {PCIC_NETWORK, -1, "network"}, {PCIC_NETWORK, PCIS_NETWORK_ETHERNET, "ethernet"}, {PCIC_NETWORK, PCIS_NETWORK_TOKENRING, "token ring"}, {PCIC_NETWORK, PCIS_NETWORK_FDDI, "fddi"}, {PCIC_NETWORK, PCIS_NETWORK_ATM, "ATM"}, {PCIC_NETWORK, PCIS_NETWORK_ISDN, "ISDN"}, + {PCIC_NETWORK, PCIS_NETWORK_WORLDFIP, "WorldFip"}, + {PCIC_NETWORK, PCIS_NETWORK_PICMG, "PICMG"}, + {PCIC_NETWORK, PCIS_NETWORK_INFINIBAND, "InfiniBand"}, + {PCIC_NETWORK, PCIS_NETWORK_HFC, "host fabric"}, {PCIC_DISPLAY, -1, "display"}, {PCIC_DISPLAY, PCIS_DISPLAY_VGA, "VGA"}, {PCIC_DISPLAY, PCIS_DISPLAY_XGA, "XGA"}, @@ -693,6 +698,11 @@ static struct {PCIC_BRIDGE, PCIS_BRIDGE_NUBUS, "PCI-NuBus"}, {PCIC_BRIDGE, PCIS_BRIDGE_CARDBUS, "PCI-CardBus"}, {PCIC_BRIDGE, PCIS_BRIDGE_RACEWAY, "PCI-RACEway"}, + {PCIC_BRIDGE, PCIS_BRIDGE_PCI_TRANSPARENT, + "Semi-transparent PCI-to-PCI"}, + {PCIC_BRIDGE, PCIS_BRIDGE_INFINIBAND, "InfiniBand-PCI"}, + {PCIC_BRIDGE, PCIS_BRIDGE_AS_PCI, + "AdvancedSwitching-PCI"}, {PCIC_SIMPLECOMM, -1, "simple comms"}, {PCIC_SIMPLECOMM, PCIS_SIMPLECOMM_UART, "UART"}, /* could detect 16550 */ {PCIC_SIMPLECOMM, PCIS_SIMPLECOMM_PAR, "parallel port"}, @@ -706,6 +716,8 @@ static struct {PCIC_BASEPERIPH, PCIS_BASEPERIPH_PCIHOT, "PCI hot-plug controller"}, {PCIC_BASEPERIPH, PCIS_BASEPERIPH_SDHC, "SD host controller"}, {PCIC_BASEPERIPH, PCIS_BASEPERIPH_IOMMU, "IOMMU"}, + {PCIC_BASEPERIPH, PCIS_BASEPERIPH_RCEC, + "Root Complex Event Collector"}, {PCIC_INPUTDEV, -1, "input device"}, {PCIC_INPUTDEV, PCIS_INPUTDEV_KEYBOARD, "keyboard"}, {PCIC_INPUTDEV, PCIS_INPUTDEV_DIGITIZER,"digitizer"}, @@ -721,10 +733,23 @@ static struct {PCIC_SERIALBUS, PCIS_SERIALBUS_USB, "USB"}, {PCIC_SERIALBUS, PCIS_SERIALBUS_FC, "Fibre Channel"}, {PCIC_SERIALBUS, PCIS_SERIALBUS_SMBUS, "SMBus"}, + {PCIC_SERIALBUS, PCIS_SERIALBUS_INFINIBAND, "InfiniBand"}, + {PCIC_SERIALBUS, PCIS_SERIALBUS_IPMI, "IPMI"}, + {PCIC_SERIALBUS, PCIS_SERIALBUS_SERCOS, "SERCOS"}, + {PCIC_SERIALBUS, PCIS_SERIALBUS_CANBUS, "CANbus"}, + {PCIC_SERIALBUS, PCIS_SERIALBUS_MIPI_I3C, "MIPI I3C"}, {PCIC_WIRELESS, -1, "wireless controller"}, {PCIC_WIRELESS, PCIS_WIRELESS_IRDA, "iRDA"}, {PCIC_WIRELESS, PCIS_WIRELESS_IR, "IR"}, {PCIC_WIRELESS, PCIS_WIRELESS_RF, "RF"}, + {PCIC_WIRELESS, PCIS_WIRELESS_BLUETOOTH, "bluetooth"}, + {PCIC_WIRELESS, PCIS_WIRELESS_BROADBAND, "broadband"}, + {PCIC_WIRELESS, PCIS_WIRELESS_80211A, "ethernet 802.11a"}, + {PCIC_WIRELESS, PCIS_WIRELESS_80211B, "ethernet 802.11b"}, + {PCIC_WIRELESS, PCIS_WIRELESS_CELL, + "cellular controller/modem"}, + {PCIC_WIRELESS, PCIS_WIRELESS_CELL_E, + "cellular controller/modem plus ethernet"}, {PCIC_INTELLIIO, -1, "intelligent I/O controller"}, {PCIC_INTELLIIO, PCIS_INTELLIIO_I2O, "I2O"}, {PCIC_SATCOM, -1, "satellite communication"},