From 2bbb12c355308d10bf123911044fbdf6ae7fb59c Mon Sep 17 00:00:00 2001 From: Peter Hutterer Date: Sun, 13 Jul 2008 20:23:14 +0930 Subject: [PATCH] Xi: remove ChangeDeviceControl for CoreCtl. If you want to set a device to core, attach it to a master device. --- Xi/chgdctl.c | 17 +++-------------- hw/kdrive/src/kinput.c | 1 + hw/xfree86/common/xf86Xinput.c | 1 + 3 files changed, 5 insertions(+), 14 deletions(-) diff --git a/Xi/chgdctl.c b/Xi/chgdctl.c index 26b79f6dc..8c97d8fe8 100644 --- a/Xi/chgdctl.c +++ b/Xi/chgdctl.c @@ -245,20 +245,9 @@ ProcXChangeDeviceControl(ClientPtr client) break; case DEVICE_CORE: - c = (xDeviceCoreCtl *)&stuff[1]; - - status = ChangeDeviceControl(client, dev, (xDeviceCtl *) c); - - if (status == Success) { - dev->coreEvents = c->status; - ret = Success; - } else if (status == DeviceBusy) { - rep.status = DeviceBusy; - ret = Success; - } else { - ret = BadMatch; - } - + /* Sorry, no device core switching no more. If you want a device to + * send core events, attach it to a master device */ + ret = BadMatch; break; case DEVICE_ENABLE: e = (xDeviceEnableCtl *)&stuff[1]; diff --git a/hw/kdrive/src/kinput.c b/hw/kdrive/src/kinput.c index 830875210..e200c5493 100644 --- a/hw/kdrive/src/kinput.c +++ b/hw/kdrive/src/kinput.c @@ -2404,6 +2404,7 @@ ChangeDeviceControl(register ClientPtr client, DeviceIntPtr pDev, return Success; case DEVICE_CORE: + return BadMatch; case DEVICE_ENABLE: return Success; diff --git a/hw/xfree86/common/xf86Xinput.c b/hw/xfree86/common/xf86Xinput.c index 498f79706..2a9dfe5b9 100644 --- a/hw/xfree86/common/xf86Xinput.c +++ b/hw/xfree86/common/xf86Xinput.c @@ -299,6 +299,7 @@ ChangeDeviceControl (ClientPtr client, DeviceIntPtr dev, xDeviceCtl *control) if (!local->control_proc) { switch (control->control) { case DEVICE_CORE: + return BadMatch; case DEVICE_RESOLUTION: case DEVICE_ABS_CALIB: case DEVICE_ABS_AREA: