summaryrefslogtreecommitdiffstats
path: root/kernel/main.c
diff options
context:
space:
mode:
authorArthur Hanson Rasmusson <arthur@vgpu.io>2026-10-20 06:46:26 -0400
committerArthur Hanson Rasmusson <arthur@vgpu.io>2026-10-20 06:46:26 -0400
commit1cde51713fee3daf3fadea9c5bba64b0d9fb9ba0 (patch)
tree7512df28446bae51ed581913a4b674362ed33e4e /kernel/main.c
parent410532fb29d53d307cdd55fa0da5cf6f1d2faace (diff)
downloadopen-iov-1cde51713fee3daf3fadea9c5bba64b0d9fb9ba0.tar.gz
open-iov-1cde51713fee3daf3fadea9c5bba64b0d9fb9ba0.zip
vgsp: C56F acquire wait gate as an opt-in experiment (default off)
The streams2 readback-before-scale class is root-caused: core CUDA starts compute-channel pushes with a C56F SEM_EXECUTE acquire (ACQ_CIRC_GEQ on a tracking semaphore; e.g. the D2H readback push waits on 0x20400fef0 >= its sequence number) and the decoder ignored it, so the copy ran ahead of the scale launch it waits for. The gate implemented here (decode the acquire; svc_run_ops holds the push's work until the semaphore satisfies, with the driver's release(N)+acquire(N) same-push pattern treated as satisfied; op-pending bounded hold; kill switch at 2048 holds; diagnostics sema-wait held rows with a per-session budget) OVER-HOLDS on boots where a channel's first pushes wait on counter values only their own withheld release would install (wait counts reach thousands, the client stalls; r337/r338/r339). The tracking-semaphore value semantics (what the guest word should read vs the driver's sequence numbers) need a dedicated pass before this can be enabled. Default OFF so behaviour is the pre-r336 one; enable per-boot with sema_wait_gate=1 for the experiment. Everything else (pin-wins, vector_add, the battery) is unaffected.
Diffstat (limited to 'kernel/main.c')
-rw-r--r--kernel/main.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/kernel/main.c b/kernel/main.c
index c150a1a..47a1aba 100644
--- a/kernel/main.c
+++ b/kernel/main.c
@@ -2824,6 +2824,7 @@ MODULE_PARM_DESC(sema_pool_hold_fresh, "apply pool releases at fresh-pin time in
* the m163 retry path re-resolve with pins.
*/
module_param_named(sema_copy_dst_pin_guard, gsp_sema_copy_dst_pin_guard, bool, 0644);
+module_param_named(sema_wait_gate, gsp_sema_wait_gate, bool, 0644);
MODULE_PARM_DESC(sema_copy_dst_pin_guard, "hold device-dst copies without a pin-resolved translation (default 1)");
/*