mirror of
https://dev.lirent.ru/Vatrog/vm-introspection-engine.git
synced 2026-06-18 04:16:39 +03:00
Keep the arch layer's prose consumer-agnostic; note the x86-64 binding
The generic address-space layer no longer names win32 in its comments: the khalf_score and gva_translate doc-comments described themselves in terms of their current Windows consumer, a downward coupling from the stable layer to a specific, swappable one. Reworded to describe what each primitive does, not who calls it. Also drop a dangling reference to the renamed engine handle. State the contract's real scope in memmodel.h: OS-agnostic but architecture- bound. The address-space key is the x86-64 CR3 (the PML4 base), shared by any guest OS on x86-64 - CR3 is an ISA register, not a Windows concept; only its per-process storage (DirectoryTableBase) is win32-specific and stays in the win32 engine.
This commit is contained in:
+2
-2
@@ -46,8 +46,8 @@ static int gva_gpa(vmie_mem* m, uintptr_t cr3, uintptr_t va,
|
||||
}
|
||||
|
||||
/* cold extern translate: GPA of `va` under `cr3`, or -1. Wraps the hot static
|
||||
* gva_gpa for cold callers outside this TU (win32 bring-up) without exposing the
|
||||
* inlinable hot primitive. Declared in engine-arch.h. */
|
||||
* gva_gpa for cold callers outside this TU without exposing the inlinable hot
|
||||
* primitive. Declared in engine-arch.h. */
|
||||
__attribute__((cold))
|
||||
int gva_translate(vmie_mem* m, uintptr_t cr3, uintptr_t va, uintptr_t* gpa) {
|
||||
return gva_gpa(m, cr3, va, gpa, NULL);
|
||||
|
||||
Reference in New Issue
Block a user