MULTI QUEUE GROUP GUC INTERFACE(9)
π Multi Queue Group GuC interface π
okay bestie, you're reading the Kernel API Manual page Multi Queue...uC interface(9) β yes the header is literally truncated like that, that's just how it renders, we move π
So here's the tea: the multi queue group coordination between KMD and GuC goes through a software construct called the Context Group Page (CGP). The CGP is a KMD managed 4KB page, and it's allocated in the global GTT. slay.
π CGP format π
one bullet per DWORD row so literally nothing gets lost, periodt:
- DWORD
0βVersionβ bits[15:8]=Major ver,[7:0]=Minor ver - DWORD
1..15βRESERVEDβ MBZ - DWORD
16βKMD_QUEUE_UPDATE_MASK_DW0β KMD queue mask for queues31..0 - DWORD
17βKMD_QUEUE_UPDATE_MASK_DW1β KMD queue mask for queues63..32 - DWORD
18..31βRESERVEDβ MBZ - DWORD
32βQ0CD_DW0β Queue 0 context LRC descriptor lower DWORD - DWORD
33βQ0ContextIndexβ Context ID for Queue 0 - DWORD
34βQ1CD_DW0β Queue 1 context LRC descriptor lower DWORD - DWORD
35βQ1ContextIndexβ Context ID for Queue 1 - DWORD
158βQ63CD_DW0β Queue 63 context LRC descriptor lower DWORD - DWORD
159βQ63ContextIndexβ Context ID for Queue 63 - DWORD
160..1024βRESERVEDβ MBZ
and yes the list jumps straight from 35 to 158, no I'm not okay either π just so you're not jumpscared.
π¦ how the registering actually goes π¦
While registering Q0 with GuC, the CGP gets updated with the Q0 entry, and GuC is notified through the XE_GUC_ACTION_REGISTER_CONTEXT_MULTI_QUEUE H2G message β which specifies the CGP address. iconic.
When the secondary queues are added to the group, the CGP is updated with the entry for that queue, and GuC is notified through the H2G interface XE_GUC_ACTION_MULTI_QUEUE_CONTEXT_CGP_SYNC.
GuC responds to these H2G messages with a XE_GUC_ACTION_NOTIFY_MULTIQ_CONTEXT_CGP_SYNC_DONE G2H message. π«Ά
GuC also sends a XE_GUC_ACTION_NOTIFY_MULTI_QUEUE_CGP_CONTEXT_ERROR notification for any error in the CGP. not the error notification π
β οΈ okay this part matters: only one of these CGP update messages can be outstanding (waiting for GuC response) at any time. one at a time, bestie. the bits in the KMD_QUEUE_UPDATE_MASK_DW* fields indicate which queue entry is being updated in the CGP.
The primary queue (Q0) represents the multi queue group context in GuC, and submission on any queue of the group must be through the Q0 GuC interface only. no detours, no side quests π
And since it is not required to register secondary queues with GuC, the secondary queue context ids in the CGP are populated with the Q0 context id. cute, efficient, we love a shortcut that's actually legal β¨
π SEE ALSO π
Kernel file ./drivers/gpu/drm/xe/xe_guc_submit.c plus the whole friend group:
xe_guc_submit_init(9)xe_guc_submit_wedge(9)xe_guc_submit_pause(9)xe_guc_submit_pause_vf(9)xe_guc_submit_unpause_prepare_vf(9)xe_guc_submit_unpause(9)xe_guc_submit_unpause_vf(9)xe_guc_submit_pause_abort(9)xe_guc_exec_queue_cgp_sync_done_handler(9)xe_guc_exec_queue_snapshot_capture(9)xe_guc_exec_queue_snapshot_capture_delayed(9)xe_guc_exec_queue_snapshot_print(9)xe_guc_exec_queue_snapshot_free(9)xe_guc_register_vf_exec_queue(9)xe_guc_submit_print(9)xe_guc_has_registered_mlrc_queues(9)xe_guc_contexts_hwsp_rebase(9)
mwah, that's the whole page π this came from ./drivers/gpu/drm/xe, dated October 2026, and the footer still calls it Multi Queue...uC interface(9) β go read it again if you need to, i'll be right here π«Άπ
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms