[Bug 221074] Hyper V Gen 2 install has no mouse
bugzilla-noreply at freebsd.org
bugzilla-noreply at freebsd.org
Thu Mar 11 00:12:48 UTC 2021
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=221074
--- Comment #15 from Dexuan Cui <decui at microsoft.com> ---
(In reply to Vladimir Kondratyev from comment #14)
Hi Vladimir, sorry I actually just did some research and didn't write any code.
:-)
The Hyper-V/VMBus part of the driver should be straightforward, I'm just not
familiar with the HID part. The core logic of the Hyper-V mouse driver in Linux
VM is Line 296~306
(https://github.com/torvalds/linux/blob/master/drivers/hid/hid-hyperv.c#L296):
IIRC, for every mouse event, the Hyper-V host sends a 7-byte "input_report",
which in Linux VM is handled by the Linux HID API hid_input_report() and
nothing else is done. In FreeBSD, I'm not sure what the equivalent API is? --
I read the page you shared and I guess it may be:
METHOD int get_report {
device_t dev;
void *data;
hid_size_t maxlen;
hid_size_t *actlen;
uint8_t type;
uint8_t id;
};
I suppose the format of the 7 bytes from the Hyper-V host should comply with
the HID spec for mouse (I guess there is a spec for this?), and if so, FreeBSD
can use the 7 bytes directly, just like Linux VM does.
I'm currently in the middle of something else, so sorry I can't work on this
right now. I guess Wei (whu) on our team can help on this, and also review the
2 kbd patches.
--
You are receiving this mail because:
You are the assignee for the bug.
More information about the freebsd-virtualization
mailing list