Kernel: Fix scrolling up in VMware

The mouse wheel delta is provided as a signed 8 bit value.
This commit is contained in:
Tom 2021-02-28 13:58:21 -07:00 committed by Andreas Kling
parent 152af3a297
commit b4c1b96d96
Notes: sideshowbarker 2024-07-18 21:50:12 +09:00

View file

@ -231,7 +231,7 @@ Optional<MousePacket> VMWareBackdoor::receive_mouse_packet()
int buttons = (command.ax & 0xFFFF);
int x = (command.bx);
int y = (command.cx);
int z = (command.dx);
int z = (i8)(command.dx); // signed 8 bit value only!
if constexpr (PS2MOUSE_DEBUG) {
dbgln("Absolute Mouse: Buttons {:x}", buttons);