From 930789eafcb2ed05929c5ca8f92b5fda3b58875c Mon Sep 17 00:00:00 2001 From: Arthur Hanson Rasmusson Date: Tue, 6 Oct 2026 17:37:50 -0400 Subject: vgsp: SKED/FE readback + QMD w50..53 + two-step PCAS gate (m41 instrumentation) --- kernel/gsp_phys_gpu.c | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) (limited to 'kernel/gsp_phys_gpu.c') diff --git a/kernel/gsp_phys_gpu.c b/kernel/gsp_phys_gpu.c index 9100959..5ec97e2 100644 --- a/kernel/gsp_phys_gpu.c +++ b/kernel/gsp_phys_gpu.c @@ -637,6 +637,24 @@ int gsp_phys_rmcall_gr_pcas_value(void) } EXPORT_SYMBOL_GPL(gsp_phys_rmcall_gr_pcas_value); +/* + * Two-step PCAS gate (default 0). With the explicit PCAS pair on, setting + * this marks the QMD's REQUIRE_SCHEDULING_PCAS (w4 bit12) and emits the copy + * PCAS (INVALIDATE only) followed by a schedule-only PCAS (SCHEDULE), the + * dependent-QMD flow (cuda_device.h:1108-1113). + */ +static int gsp_phys_rmcall_gr_pcas_two_step_param; +module_param_named(gsp_phys_rmcall_gr_pcas_two_step, + gsp_phys_rmcall_gr_pcas_two_step_param, int, 0644); +MODULE_PARM_DESC(gsp_phys_rmcall_gr_pcas_two_step, + "Two-step PCAS: set QMD REQUIRE_SCHEDULING_PCAS and emit copy PCAS then schedule-only PCAS (default 0; requires gsp_phys_rmcall_gr_pcas=1)"); + +int gsp_phys_rmcall_gr_pcas_two_step_value(void) +{ + return gsp_phys_rmcall_gr_pcas_two_step_param; +} +EXPORT_SYMBOL_GPL(gsp_phys_rmcall_gr_pcas_two_step_value); + /* * Rank-2 qmdwin diagnostic (gsp_phys_rmcall_gr_qmdwin; default 0). When set, * a forwarded GR launch relocates its inline-QMD destination from the guest -- cgit v1.2.3