From: Henrik Rydberg Date: Thu, 16 Dec 2010 08:52:23 +0000 (+0100) Subject: Input: synaptics - report clickpad property X-Git-Tag: firefly_0821_release~176^2~541^2~479^2~2^2~2 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=c14890a8e54977f895773d393d6a640d6d698fb8;p=firefly-linux-kernel-4.4.55.git Input: synaptics - report clickpad property With the new input property interface, it is possible to report the special quirks of a device using ioctl/sysfs. This patch sets up the device as a pointer, and reports the clickpad functionality via the INPUT_PROP_BUTTONPAD property. Acked-by: Chase Douglas Signed-off-by: Henrik Rydberg --- diff --git a/drivers/input/mouse/synaptics.c b/drivers/input/mouse/synaptics.c index 2e300a460556..8997cbc69dcc 100644 --- a/drivers/input/mouse/synaptics.c +++ b/drivers/input/mouse/synaptics.c @@ -622,6 +622,8 @@ static void set_input_params(struct input_dev *dev, struct synaptics_data *priv) { int i; + __set_bit(INPUT_PROP_POINTER, dev->propbit); + __set_bit(EV_ABS, dev->evbit); input_set_abs_params(dev, ABS_X, XMIN_NOMINAL, priv->x_max ?: XMAX_NOMINAL, 0, 0); @@ -663,6 +665,7 @@ static void set_input_params(struct input_dev *dev, struct synaptics_data *priv) input_abs_set_res(dev, ABS_Y, priv->y_res); if (SYN_CAP_CLICKPAD(priv->ext_cap_0c)) { + __set_bit(INPUT_PROP_BUTTONPAD, dev->propbit); /* Clickpads report only left button */ __clear_bit(BTN_RIGHT, dev->keybit); __clear_bit(BTN_MIDDLE, dev->keybit);