Skip to content

Commit

Permalink
Merge main into amdxdna-support
Browse files Browse the repository at this point in the history
  • Loading branch information
nokyan committed Jan 4, 2025
2 parents f1d11ae + 167684d commit 8ad88f7
Showing 1 changed file with 9 additions and 2 deletions.
11 changes: 9 additions & 2 deletions src/utils/gpu/nvidia.rs
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,18 @@ use std::{path::PathBuf, sync::LazyLock};

static NVML: LazyLock<Result<Nvml, NvmlError>> = LazyLock::new(|| {
Nvml::init()
.inspect_err(|err| warn!("Unable to connect to NVML: {err}"))
.inspect_err(|err| {
warn!("Unable to connect to NVML: {err}");
if *IS_FLATPAK {
warn!("This can occur when the version of the NVIDIA Flatpak runtime \
(org.freedesktop.Platform.GL.nvidia) and the version of the natively installed NVIDIA driver do not \
match. Consider updating both your system and Flatpak packages before opening an issue.");
}
})
.inspect(|_| debug!("Successfully connected to NVML"))
});

use crate::utils::pci::Device;
use crate::utils::{pci::Device, IS_FLATPAK};

use super::GpuImpl;

Expand Down

0 comments on commit 8ad88f7

Please sign in to comment.