From a6423bfc6d21fd5a11eb63f94f279458b212e0ad Mon Sep 17 00:00:00 2001 From: SimonFair <39065407+SimonFair@users.noreply.github.com> Date: Tue, 9 Dec 2025 19:06:56 +0000 Subject: [PATCH] Align with lspci --- emhttp/plugins/dynamix/include/Helpers.php | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/emhttp/plugins/dynamix/include/Helpers.php b/emhttp/plugins/dynamix/include/Helpers.php index b62fc8b63..c8bf7f41a 100644 --- a/emhttp/plugins/dynamix/include/Helpers.php +++ b/emhttp/plugins/dynamix/include/Helpers.php @@ -1062,14 +1062,11 @@ function getPciLinkInfo($pciAddress) } unset($out["max_width_raw"], $out["current_width_raw"]); // Cleanup // Downgrade flags - if ($out["current_speed"] && $out["max_speed"]) { + $class_check= strpos(trim(file_get_contents("$base/class")),"0x06",0); + if ($out["current_speed"] && $out["max_speed"] && $class_check === false) { $out["speed_downgraded"] = ($out["current_speed"] < $out["max_speed"]); } - if ( - $out["current_width"] !== null && - $out["max_width"] !== null && - $out["current_width"] < $out["max_width"] - ) { + if ($out["current_width"] !== null && $out["max_width"] !== null && $out["current_width"] < $out["max_width"] && $class_check === false) { $out["width_downgraded"] = true; } // PCIe Generation Table