mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] gpu: nova-core: fix warning with NOVA_CORE_SELFTESTS disabled
@ 2026-10-04  1:00 Alexandre Courbot
  2026-10-04  3:49 ` John Hubbard
  0 siblings, 1 reply; 2+ messages in thread
From: Alexandre Courbot @ 2026-10-04  1:00 UTC (permalink / raw)
  To: Danilo Krummrich, Alice Ryhl, David Airlie, Simona Vetter, John Hubbard
  Cc: nova-gpu, rust-for-linux, dri-devel, linux-kernel,
	kernel test robot, Alexandre Courbot

A module-wide new import becomes unused if the `NOVA_CORE_SELFTESTS`
config option is disabled:

    warning: unused import: `Spec`
      --> ../drivers/gpu/nova-core/driver.rs:29:9
       |
    29 |         Spec, //
       |         ^^^^
       |

Fix this by fully qualifying the unique use of `Spec` when the tests are
enabled.

Fixes: 9cb3f5d56e81 ("gpu: nova-core: add an interrupt delivery self-test")
Reported-by: kernel test robot <lkp@intel.com>
Closes: https://lore.kernel.org/oe-kbuild-all/202610031630.JOlyp48X-lkp@intel.com/
Signed-off-by: Alexandre Courbot <acourbot@nvidia.com>
---
 drivers/gpu/nova-core/driver.rs | 7 ++-----
 1 file changed, 2 insertions(+), 5 deletions(-)

diff --git a/drivers/gpu/nova-core/driver.rs b/drivers/gpu/nova-core/driver.rs
index d195fd2bcf8c..560a70c4f5a7 100644
--- a/drivers/gpu/nova-core/driver.rs
+++ b/drivers/gpu/nova-core/driver.rs
@@ -24,10 +24,7 @@
 
 use crate::{
     api::NovaCoreApi,
-    gpu::{
-        Gpu,
-        Spec, //
-    }, //
+    gpu::Gpu, //
 };
 
 /// Counter for generating unique auxiliary device IDs.
@@ -121,7 +118,7 @@ fn probe<'bound>(
             // Run self-tests that do not depend on the `Gpu` instance.
             #[cfg(CONFIG_NOVA_CORE_SELFTESTS)]
             _: {
-                let spec = Spec::new(pdev.as_ref(), bar)?;
+                let spec = crate::gpu::Spec::new(pdev.as_ref(), bar)?;
 
                 // We must wait for GFW_BOOT completion before doing any significant setup on
                 // the GPU.

---
base-commit: df718311a84188e26d499301c3921e4c392d557e
change-id: 20261004-nova-int-fixup-4593b4d61084

Best regards,
--  
Alexandre Courbot <acourbot@nvidia.com>


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2026-10-04  3:50 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-10-04  1:00 [PATCH] gpu: nova-core: fix warning with NOVA_CORE_SELFTESTS disabled Alexandre Courbot
2026-10-04  3:49 ` John Hubbard

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®