fix: update Mellanox firmware tools

This commit is contained in:
2025-09-16 13:41:01 +02:00
parent db794e6eea
commit 65aba0f69d
3 changed files with 18 additions and 5 deletions

12
modules/mft/README.md Normal file
View File

@@ -0,0 +1,12 @@
# README
For posterity:
``
sudo modprobe mst_pci.ko
sudo mlxconfig -d /dev/mst/mt4123_pciconf0 q |less
sudo mlxconfig -d /dev/mst/mt4123_pciconf0 set LINK_TYPE_P1=2
mlxconfig show_confs
mlxconfig i
``

View File

@@ -8,13 +8,13 @@ in
{
###### interface
options.features.hpc.mft = {
options.features.mft = {
enable = mkEnableOption "Mellanox MFT";
};
###### implementation
config = mkIf config.features.hpc.mft.enable {
config = mkIf config.features.mft.enable {
environment.etc."mft/mft.conf".source = "${mft.mft}/etc/mft/mft.conf";
environment.etc."mft/mst.conf".source = "${mft.mft}/etc/mft/mst.conf";
environment.etc."mft/ca-bundle.crt".source = "${mft.mft}/etc/mft/ca-bundle.crt";

View File

@@ -1,7 +1,7 @@
{pkgs, lib, stdenv, kernel ? pkgs.linux, ...}:
let
version = "4.27.0";
ver = "${version}-83";
version = "4.33.0";
ver = "${version}-169";
arch = "amd64";
rpath = lib.strings.concatStringsSep ":" [
@@ -12,7 +12,7 @@ let
src = pkgs.fetchurl {
url = "https://www.mellanox.com/downloads/MFT/mft-${ver}-x86_64-deb.tgz";
hash = "sha256-Mx2dyHSFkZ+vsorAd7yVe2vU8nhksoGieE+LPcA5fZA=";
hash = "sha256-9PRRzKObF9F2WR457fo0wWr5C1HmE9Xi+/+jVmh/18Y=";
};
unpackPhase = ''
@@ -60,6 +60,7 @@ rec {
sed -i "s,mft_prefix_location=.*,mft_prefix_location=$out/usr," $out/etc/mft/mft.conf
mkdir $out/bin
cp -s $out/usr/bin/* $out/bin
cp -sr $out/usr/share/mft/device_info $out/usr/bin/device_info
'';
};