From e90ba6e8cce289d6f8c9e3f34d51d2f7a2a6a7e6 Mon Sep 17 00:00:00 2001 From: amitgu-xilinx Date: Wed, 25 Sep 2024 09:56:40 +0100 Subject: [PATCH] SWUTILS-806: Include PCIe Slot/Gen info to sfreport 'dmidecode -t slot' --- sfreport.pl | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/sfreport.pl b/sfreport.pl index 10fa165..ee7b932 100644 --- a/sfreport.pl +++ b/sfreport.pl @@ -1558,7 +1558,14 @@ sub print_device_status { turbo => get_turbo_status($_->address)}} values(%sfc_devices))]); print_footer('hw'); - print_heading("PCI configuration", "pci_config", 'hide'); + + print_heading("PCI configuration", "pci_config", 'hide'); + + if (my $pcieslot_file = `dmidecode -t slot |grep -b10 'PCI Express' 2>/dev/null`) { + print_heading('PCIe slots info '); + print_preformatted($pcieslot_file); + } + for my $address (keys(%bridge_devices), keys(%sfc_devices)) { print_heading("PCI configuration space for $address"); # Emulate lspci -x.