Compare commits

..

10 Commits

Author SHA1 Message Date
967709982a Fix AMDuProfPcm so it finds libnuma.so
We change the search procedure so it detects NixOS from /etc/os-release
and uses "libnuma.so" when calling dlopen, instead of harcoding a full
path to /usr. The full patch of libnuma is stored in the runpath, so
dlopen can find it.
2025-09-19 10:29:16 +02:00
cb29c9fb6d Add amd_hsmp module in fox for AMD uProf 2025-09-19 10:29:16 +02:00
b55339d947 Add AMD uProf section to fox documentation 2025-09-19 10:29:16 +02:00
5aa9028f7f Fix hidden dependencies for AMDuProfSys
It tries to dlopen libcrypt.so.1 and libstdc++.so.6, so we make sure
they are available by adding them to the runpath.
2025-09-19 10:29:16 +02:00
08ac9adf52 Disable NMI watchdog in fox 2025-09-19 10:29:16 +02:00
9dd913fad0 Fix amd-uprof dependencies with patchelf 2025-09-19 10:29:16 +02:00
2e998017f3 Fix hrtimer new interface
The hrtimer_init() is now done via hrtimer_setup() with the callback
function as argument.

See: https://lwn.net/Articles/996598/
2025-09-19 10:29:16 +02:00
ee58d29da5 Use CFLAGS_MODULE instead of EXTRA_CFLAGS
Fixes the build in Linux 6.15.6, as it was not able to find the include
files.
2025-09-19 10:29:16 +02:00
2d7e84737b Add AMD uProf module and enable it in fox 2025-09-19 10:29:16 +02:00
cb3b6e78a3 Add AMD uProf package and driver 2025-09-19 10:29:11 +02:00
2 changed files with 2 additions and 2 deletions

View File

@ -25,6 +25,7 @@ let
version = "5.1.701";
tarball = "AMDuProf_Linux_x64_${version}.tar.bz2";
# NOTE: Remember to update the radare2 patch below if AMDuProfPcm changes.
uprofSrc = runCommandLocal tarball {
nativeBuildInputs = [ curl ];
outputHash = "sha256-j9gxcBcIg6Zhc5FglUXf/VV9bKSo+PAKeootbN7ggYk=";
@ -80,6 +81,7 @@ in
rm $out/bin/AMDPowerProfilerDriverSource.tar.gz
patchelf --replace-needed libroctracer64.so.1 libroctracer64.so $out/bin/ProfileAgents/x64/libAMDGpuAgent.so
patchelf --add-needed libcrypt.so.1 --add-needed libstdc++.so.6 $out/bin/AMDuProfSys
echo "16334a51fcc48668307ad94e20482ca4 $out/bin/AMDuProfPcm" | md5sum -c -
radare2 -w -q -i ${./libnuma.r2} $out/bin/AMDuProfPcm
patchelf --add-needed libnuma.so $out/bin/AMDuProfPcm
set +x

View File

@ -1,8 +1,6 @@
{ stdenv
, lib
, amd-uprof
, curl
, cacert
, kernel
, runCommandLocal
}: