Keymap issues with Pointer+Keys device

Peter Hutterer peter.hutterer at
Mon Sep 15 16:02:46 PDT 2008

On Mon, Sep 15, 2008 at 07:59:16PM +0200, Sascha Hlusiak wrote:
> Basically it's like this:
> 1) In PreInit of the official device:
> - xf86AllocateInput, fill out a second device struct and save it for later.  
> Duplicate the IDevPtr struct for that, otherwise pointers/optionlists are 
> freed twice.
> 2) In DEVICE_INIT of official device:
>  - Call xf86ActivateDevice for the slave device.
>  - Set dev->inited = device_control(dev, DEVICE_INIT) manually.
>  - Call xf86EnableDevice(dev);
> 3) In UnInit of official device:
>  - Call xf86DisableDevice(dev, TRUE);
> Here, "panic" set to TRUE doesn't seem so right but it's the only way I found 
> to totally remove a device.

Sounds alright. The panic is necessary as you can't call RemoveDevice
directly (which would disable everything properly).

I'm thinking, maybe it might be worth making NewInputDeviceRequest and
DeleteInputDeviceRequest part of the server API. That way, you could just
assemble the option list, pass it in and let the server worry about the rest.


More information about the xorg mailing list