drm: implement syncobj and fence for VIRGL/VirtIO driver
Extract protocol-agnostic FenceTimeline from Intel to shared src/drivers/fence.rs — atomic-based fence tracking suitable for Intel, VIRGL, and AMD drivers. Extract protocol-agnostic SyncobjManager from Intel to shared src/drivers/syncobj.rs — syncobj create/destroy/signal/reset/ wait/query and sync_file fd export/import. Wire both into VirtioDriver: - Add FenceTimeline + SyncobjManager fields - Implement all 5 GpuDriver syncobj trait methods (create, destroy, wait, export_fd, import_fd) - Track fence seqnos in virgl_submit_3d (allocate before submit, signal after completion) Intel fence.rs and syncobj.rs converted to thin re-export modules pointing at shared sources — no behavioral change for Intel driver. This gives Mesa VIRGL userspace the standard DRM syncobj API for GPU/compositor synchronization.
This commit is contained in:
@@ -0,0 +1,41 @@
|
||||
|
||||
#------------------------------------------------------------
|
||||
# $File: bytecode,v 1.5 2023/02/20 16:25:05 christos Exp $
|
||||
# magic for various bytecodes
|
||||
|
||||
# From: Mikhail Gusarov <dottedmag@dottedmag.net>
|
||||
# NekoVM (https://nekovm.org/) bytecode
|
||||
0 string NEKO NekoVM bytecode
|
||||
>4 lelong x (%d global symbols,
|
||||
>8 lelong x %d global fields,
|
||||
>12 lelong x %d bytecode ops)
|
||||
!:mime application/x-nekovm-bytecode
|
||||
|
||||
# https://www.iana.org/assignments/media-types/application/vnd.resilient.logic
|
||||
# From: Benedikt Muessig <benedikt@resilient-group.de>
|
||||
0 belong 0x07524c4d Resilient Logic bytecode
|
||||
!:mime application/vnd.resilient.logic
|
||||
>4 byte/16 x \b, version %d
|
||||
>4 byte&0x0f x \b.%d
|
||||
|
||||
# Guile file magic from <dalepsmith@gmail.com>
|
||||
# https://www.gnu.org/s/guile/
|
||||
# https://git.savannah.gnu.org/gitweb/?p=guile.git;f=libguile/_scm.h;hb=HEAD#l250
|
||||
|
||||
0 string GOOF---- Guile Object
|
||||
>8 string LE \b, little endian
|
||||
>8 string BE \b, big endian
|
||||
>11 string 4 \b, 32bit
|
||||
>11 string 8 \b, 64bit
|
||||
>13 regex .\\.. \b, bytecode v%s
|
||||
|
||||
# Racket file magic
|
||||
# From: Haelwenn (lanodan) Monnier <contact+libmagic@hacktivis.me>
|
||||
# https://racket-lang.org/
|
||||
# https://github.com/racket/racket/blob/master/racket/src/expander/compile/write-linklet.rkt
|
||||
0 string #~
|
||||
>&0 pstring x
|
||||
>>&0 pstring racket
|
||||
>>>0 string #~ Racket bytecode
|
||||
>>>>&0 pstring x (version %s)
|
||||
|
||||
Reference in New Issue
Block a user