Skip to contentSkip to conversation

Input: tell mousedev to handle HP remote console virtual mouse using absolute coordinates

PATCH In review Micah Parrish 2 participants 2 messages Jan 15, 2008 Input drivers

lore
Share & tools
lore
#0 lore raw

PATCH v2 1/1 Input: tell mousedev to handle HP remote console virtual mouse using absolute coordinates

The HP Integrated Remote Console Virtual Mouse, which is standard equipment on all Proliant and Integrity servers, produces absolute coordinates instead of relative coordinates. This is done to synchronize the position of the mouse cursor on the client desktop with the mouse cursor position on the server. Mousedev is not designed to pass those absolute events directly to X, but it can translate them into relative movements. It currently does this for tablet like devices and touchpads. This patch tells mousedev to also enable this function for the HP virtual mouse. This patch is narrower in scope than my previous patch of the same name, which enabled abs-to-rel translation for all devices with ABS_X, ABS_Y, and BTN_LEFT.

This patch enables the mouse pointer to move when using the remote console. Without this patch, the cursor will not move.

---

 mousedev.c |   10 ++++++++++
 1 file changed, 10 insertions(+)
drivers/input/mousedev.c +10 -0
index 9173916..e67a9cc 100644
@@ -829,6 +829,16 @@ static const struct input_device_id mousedev_ids[] = {
                .keybit = { [LONG(BTN_TOOL_FINGER)] = BIT(BTN_TOOL_FINGER) },
                .absbit = { BIT(ABS_X) | BIT(ABS_Y) | BIT(ABS_PRESSURE) | BIT(ABS_TOOL_WIDTH) },
        },      /* A touchpad */
+       {
+               .vendor = 0x03f0,
+               .product = 0x1126,
+               .flags = INPUT_DEVICE_ID_MATCH_EVBIT 
+                       | INPUT_DEVICE_ID_MATCH_KEYBIT 
+                       | INPUT_DEVICE_ID_MATCH_ABSBIT,
+               .evbit = { BIT(EV_KEY) | BIT(EV_ABS) | BIT(EV_SYN) },
+               .keybit = { [LONG(BTN_LEFT)] = BIT(BTN_LEFT) },
+               .absbit = { BIT(ABS_X) | BIT(ABS_Y) },
+       },      /* hp ILO2 High Performance mouse */
 
        { },    /* Terminating entry */
 };
maintainer
#1 lore raw

Hi Micah,

Quoted 12 lines · Micah Parrish

The HP Integrated Remote Console Virtual Mouse, which is standard equipment on all Proliant and Integrity servers, produces absolute coordinates instead of relative coordinates. This is done to synchronize the position of the mouse cursor on the client desktop with the mouse cursor position on the server. Mousedev is not designed to pass those absolute events directly to X, but it can translate them into relative movements. It currently does this for tablet like devices and touchpads. This patch tells mousedev to also enable this function for the HP virtual mouse. This patch is narrower in scope than my previous patch of the same name, which enabled abs-to-rel translation for all devices with ABS_X, ABS_Y, and BTN_LEFT.

I thought it over and I decided to include the previous version of the patch (the one that does not have venor/pid restriction), since it looks like Xen people might need it too.

It should be included in the next pull request to Linus.

Sorry for the delays.

Signature · 1 line
Dmitry