From 53fc42ef2ee414b2e301ef1963dc5abbe3007dcd Mon Sep 17 00:00:00 2001 From: Diljit Singh Date: Tue, 24 Nov 2026 21:04:02 -0500 Subject: [PATCH 1/3] drm/asahi: g16: pass compute_only=false to SignalBundle::publish Commit fae8191fafba ("drm/asahi: g17: lift non-M5 effort immediately for waited compute submissions") added a second `compute_only: bool` parameter to `g17::sync_output::SignalBundle::publish()`, while the concurrently merged G16 stack (#3043) added a call site in `drivers/gpu/drm/asahi/g16/fence.rs` passing the previous one-argument signature, breaking `aurora.ko` builds on `main` with `rustc E0061`. Pass `false` from `g16::fence::Syncs::publish()`: the flag controls G17's non-M5 compute-waiter effort lifting hook (`asahi_g17_note_compute_waiter`), which G16 does not participate in because it manages power/DVFS in its own driver path. Fixes: fae8191fafba ("drm/asahi: g17: lift non-M5 effort immediately for waited compute submissions") Fixes: 175375add602 ("Merge pull request #3043 from aurora-silicon/djdev/g16-perf-wave15") Signed-off-by: Diljit Singh --- drivers/gpu/drm/asahi/g16/fence.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/asahi/g16/fence.rs b/drivers/gpu/drm/asahi/g16/fence.rs index 75ca2b6768c81..e223c74f9c853 100644 --- a/drivers/gpu/drm/asahi/g16/fence.rs +++ b/drivers/gpu/drm/asahi/g16/fence.rs @@ -588,7 +588,8 @@ impl Syncs { pub(crate) fn publish(&mut self, fence: &Fence) -> Result { let first = self.input_count.min(self.syncs.len()); if let Some(bundle) = &mut self.cumulative { - bundle.publish(fence)?; + // G16 has its own power/DVFS path; never poke G17's non-M5 compute-waiter hook. + bundle.publish(fence, false)?; self.cumulative = None; self.syncs.truncate(first); return Ok(()); From 6830b3df58c1f4abc6f2da9605bca47c15cc5a8d Mon Sep 17 00:00:00 2001 From: Diljit Singh Date: Tue, 24 Nov 2026 21:12:53 -0500 Subject: [PATCH 2/3] drm/asahi: guard crate::g16::Gpu check with CONFIG_DRM_ASAHI_G16 Commit 703cbfb8ec12 (part of #3043) added `gpu.as_any().is::()` in `drivers/gpu/drm/asahi/file.rs:1895` without a `#[cfg(CONFIG_DRM_ASAHI_G16)]` guard, breaking builds where `CONFIG_DRM_ASAHI_G16=n` (such as KUnit configs). Guard the `crate::g16::Gpu` type check with `#[cfg(CONFIG_DRM_ASAHI_G16)]` (evaluating to `false` when disabled), matching all other `crate::g16` references in `asahi_core.rs`, `driver.rs`, and `fwid.rs`. Fixes: 703cbfb8ec12 ("drm/asahi: g16: use cumulative output scopes on G16") Signed-off-by: Diljit Singh --- drivers/gpu/drm/asahi/file.rs | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/asahi/file.rs b/drivers/gpu/drm/asahi/file.rs index be78c01b39aff..cdd367f64b638 100644 --- a/drivers/gpu/drm/asahi/file.rs +++ b/drivers/gpu/drm/asahi/file.rs @@ -1887,12 +1887,22 @@ impl File { } else { None }; + let cumulative_sync = gpu.as_any().is::() || { + #[cfg(CONFIG_DRM_ASAHI_G16)] + { + gpu.as_any().is::() + } + #[cfg(not(CONFIG_DRM_ASAHI_G16))] + { + false + } + }; let syncs = match SyncItem::parse_array( file, data.syncs, data.in_sync_count, data.out_sync_count, - gpu.as_any().is::() || gpu.as_any().is::(), + cumulative_sync, ) { Ok(syncs) => syncs, Err(e) => { From f7a059d114dfb71bb6c67ba067fadbb73a3e0065 Mon Sep 17 00:00:00 2001 From: Diljit Singh Date: Tue, 24 Nov 2026 21:28:26 -0500 Subject: [PATCH 3/3] selftests: asahi-m4: update SignalBundle::publish mock for compute_only arg Update the SignalBundle::publish mock in test-fence-signalling.py to match the two-argument signature (fence, compute_only: bool), record compute_only in BundleLog, and assert !compute_only so G16 never invokes G17 compute-waiter effort accounting. Signed-off-by: Diljit Singh --- .../drivers/gpu/asahi-m4/test-fence-signalling.py | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/tools/testing/selftests/drivers/gpu/asahi-m4/test-fence-signalling.py b/tools/testing/selftests/drivers/gpu/asahi-m4/test-fence-signalling.py index 0843277bc9368..ffc523fa9f5e3 100644 --- a/tools/testing/selftests/drivers/gpu/asahi-m4/test-fence-signalling.py +++ b/tools/testing/selftests/drivers/gpu/asahi-m4/test-fence-signalling.py @@ -350,14 +350,20 @@ def extract_function(text, name): #[derive(Default)] pub(crate) struct BundleLog { pub(crate) published: Vec, + pub(crate) compute_only: Vec, pub(crate) failed: Vec, pub(crate) fail_publish: bool, } pub(crate) struct SignalBundle(pub(crate) Rc>); impl SignalBundle { - pub(crate) fn publish(&mut self, fence: &Fence) -> Result { + pub(crate) fn publish(&mut self, fence: &Fence, compute_only: bool) -> Result { + assert!( + !compute_only, + "G16 must not trigger G17 compute-waiter effort accounting" + ); let mut log = self.0.borrow_mut(); + log.compute_only.push(compute_only); if log.fail_publish { return Err(ENOMEM); }