Add VMware absolute-pointer backdoor (port 0x5658)#1542
Open
felixrieseberg wants to merge 2 commits intocopy:masterfrom
Open
Add VMware absolute-pointer backdoor (port 0x5658)#1542felixrieseberg wants to merge 2 commits intocopy:masterfrom
felixrieseberg wants to merge 2 commits intocopy:masterfrom
Conversation
Implements GETVERSION + ABSPOINTER_{COMMAND,STATUS,DATA} so a guest
driver (VBADOS VBMOUSE, vmwmouse, Linux vmmouse) can read the host
cursor position and track it 1:1 without pointer lock.
The queue is fed by the existing mouse-absolute bus event that
MouseAdapter already emits; PS/2 still supplies IRQ12 (the driver reads
this port on each mouse IRQ). Move-only packets are coalesced in place
so the guest never falls more than one packet behind regardless of how
slowly it drains. Emits vmware-absolute-mouse on the bus when the guest
toggles absolute mode so the embedder can drop pointer lock and hide the
host cursor.
State save/restore covers the enabled/absolute flags.
SuperMaxusa
reviewed
Apr 11, 2026
DEBUG builds assert on unregistered IO widths; some guests probe 0x5658 with IN AX,DX during detection. Answer 8/16-bit reads as an empty port and ignore writes. The |0 on the ABSPOINTER subcommand case labels was sign-coercion to match Int32Array reads, but all four constants fit in 31 bits so it was a no-op.
Owner
|
Nice work, thanks. This breaks mouse movement when the mouse is locked. We should probably have at least one of these, preferably both:
Oh, and updating the documentation how to install the driver on old Windows versions would be nice. I tested on Arch and it works out of the box. |
Contributor
Author
|
Sounds good, thanks for the feedback - I'll add it! Give me a week or so |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Implements GETVERSION + ABSPOINTER_{COMMAND,STATUS,DATA} so a guest driver (VBADOS VBMOUSE, vmwmouse, Linux vmmouse) can read the host cursor position and track it 1:1 without pointer lock.
The queue is fed by the existing mouse-absolute bus event that MouseAdapter already emits; PS/2 still supplies IRQ12 (the driver reads this port on each mouse IRQ). Move-only packets are coalesced in place so the guest never falls more than one packet behind regardless of how slowly it drains. Emits vmware-absolute-mouse on the bus when the guest toggles absolute mode so the embedder can drop pointer lock and hide the host cursor.
In practice, this is what it looks like on Windows 95:
cursor.mov