diff options
| author | Arthur Hanson Rasmusson <arthur@vgpu.io> | 2026-09-29 16:14:12 -0400 |
|---|---|---|
| committer | Arthur Hanson Rasmusson <arthur@vgpu.io> | 2026-09-29 16:14:12 -0400 |
| commit | 6d5131e87a2c9cb5c20437669c1917f7be6252b5 (patch) | |
| tree | 43934878bc90db539f697bdb2fe069ab0c484442 /tools/guest-diag/semfix_uvmt.py | |
| parent | 78b8f909784676c5ec6f02a6c48d51ec2a589f96 (diff) | |
| download | open-iov-6d5131e87a2c9cb5c20437669c1917f7be6252b5.tar.gz open-iov-6d5131e87a2c9cb5c20437669c1917f7be6252b5.zip | |
sema-svc: persist GR counter slot per channel; stable slot layout; bulk pin queue 4k
- counter_pa autoreg result is written back to the channel table so later
passes cannot re-target a different slot when the live GR count changes
during teardown; re-registration of the same channel preserves the slot.
- counter slot layout uses the max GR count ever seen in the generation
instead of the shrinking live count.
- sema_map_add queue 64 -> 4096 entries so a full-window pin burst drains
without ENOSPC retries.
- pin_gr_stream: one batched sudo pass per flush (was one process per run,
~4 s for 400 runs), retrying only queue-rejected runs.
- semfix_uvmt: SEMFIX_SKIP_PB=1 skips the blocking push-buffer chain walk
when the vsock window stream already supplies those pages.
Diffstat (limited to 'tools/guest-diag/semfix_uvmt.py')
| -rwxr-xr-x | tools/guest-diag/semfix_uvmt.py | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/tools/guest-diag/semfix_uvmt.py b/tools/guest-diag/semfix_uvmt.py index 02d4f9e..fd58299 100755 --- a/tools/guest-diag/semfix_uvmt.py +++ b/tools/guest-diag/semfix_uvmt.py @@ -43,6 +43,11 @@ COUNTER_LO = int(os.environ.get("COUNTER_LO", "0x20400f000"), 16) COUNTER_HI = int(os.environ.get("COUNTER_HI", "0x204010000"), 16) SEMSTREAM = os.environ.get("SEM_STREAM_FILE", "/tmp/opencode/sem_stream.txt") TRACE_EVERY = int(os.environ.get("UVMT_TRACE_EVERY", "5")) +# The push-buffer resolution walks the channel/pool/manager chain with many +# QMP reads and can block the poller for tens of seconds. When the GR window +# stream (pin_gr_stream.py) already supplies the push-buffer pages, skip it so +# the tracking-sem poller stays live during the client's deadline window. +SKIP_PB = os.environ.get("SEMFIX_SKIP_PB", "0") == "1" class Stream: @@ -309,6 +314,8 @@ def main(): ok = pin(gv, gpa) log("semfix: sem=0x%x pool va=0x%x -> gpa=0x%x pin=%s" % (sem, gv, gpa, "ok" if ok else "FAILED")) + if SKIP_PB: + continue d = {} try: res = resolve_from_sem(q, sem, d) |
