diff options
| author | Linus Torvalds <torvalds@linux-foundation.org> | 2014-10-31 22:51:11 -0400 |
|---|---|---|
| committer | Linus Torvalds <torvalds@linux-foundation.org> | 2014-10-31 22:51:11 -0400 |
| commit | 9f935675d41aa51ebf929fc977cf530ff7d1a7fc (patch) | |
| tree | 97c4f71d7fbd067a22f1509a3cfbb11f2a90b2bd /drivers/input/misc | |
| parent | ab01f963deb5b70113c6a2fe9622fe06035836eb (diff) | |
| parent | e55a3366984cda7d179e194a772f5ae4fe551b80 (diff) | |
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input
Pull input updates from Dmitry Torokhov:
"A bunch of fixes for minor defects reported by Coverity, a few driver
fixups and revert of i8042.nomux change so that we are once again
enable active MUX mode if box claims to support it"
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input:
Revert "Input: i8042 - disable active multiplexing by default"
Input: altera_ps2 - use correct type for irq return value
Input: altera_ps2 - write to correct register when disabling interrupts
Input: max77693-haptic - fix potential overflow
Input: psmouse - remove unneeded check in psmouse_reconnect()
Input: vsxxxaa - fix code dropping bytes from queue
Input: ims-pcu - fix dead code in ims_pcu_ofn_reg_addr_store()
Input: opencores-kbd - fix error handling
Input: wm97xx - adapt parameters to tosa touchscreen.
Input: i8042 - quirks for Fujitsu Lifebook A544 and Lifebook AH544
Input: stmpe-keypad - fix valid key line bitmask
Input: soc_button_array - update calls to gpiod_get*()
Diffstat (limited to 'drivers/input/misc')
| -rw-r--r-- | drivers/input/misc/ims-pcu.c | 2 | ||||
| -rw-r--r-- | drivers/input/misc/max77693-haptic.c | 5 | ||||
| -rw-r--r-- | drivers/input/misc/soc_button_array.c | 2 |
3 files changed, 4 insertions, 5 deletions
diff --git a/drivers/input/misc/ims-pcu.c b/drivers/input/misc/ims-pcu.c index 719410feb84b..afed8e2b2f94 100644 --- a/drivers/input/misc/ims-pcu.c +++ b/drivers/input/misc/ims-pcu.c | |||
| @@ -1381,7 +1381,7 @@ static ssize_t ims_pcu_ofn_reg_addr_store(struct device *dev, | |||
| 1381 | pcu->ofn_reg_addr = value; | 1381 | pcu->ofn_reg_addr = value; |
| 1382 | mutex_unlock(&pcu->cmd_mutex); | 1382 | mutex_unlock(&pcu->cmd_mutex); |
| 1383 | 1383 | ||
| 1384 | return error ?: count; | 1384 | return count; |
| 1385 | } | 1385 | } |
| 1386 | 1386 | ||
| 1387 | static DEVICE_ATTR(reg_addr, S_IRUGO | S_IWUSR, | 1387 | static DEVICE_ATTR(reg_addr, S_IRUGO | S_IWUSR, |
diff --git a/drivers/input/misc/max77693-haptic.c b/drivers/input/misc/max77693-haptic.c index 7b1fde93799e..ef6a9d650d69 100644 --- a/drivers/input/misc/max77693-haptic.c +++ b/drivers/input/misc/max77693-haptic.c | |||
| @@ -194,7 +194,7 @@ static int max77693_haptic_play_effect(struct input_dev *dev, void *data, | |||
| 194 | struct ff_effect *effect) | 194 | struct ff_effect *effect) |
| 195 | { | 195 | { |
| 196 | struct max77693_haptic *haptic = input_get_drvdata(dev); | 196 | struct max77693_haptic *haptic = input_get_drvdata(dev); |
| 197 | uint64_t period_mag_multi; | 197 | u64 period_mag_multi; |
| 198 | 198 | ||
| 199 | haptic->magnitude = effect->u.rumble.strong_magnitude; | 199 | haptic->magnitude = effect->u.rumble.strong_magnitude; |
| 200 | if (!haptic->magnitude) | 200 | if (!haptic->magnitude) |
| @@ -205,8 +205,7 @@ static int max77693_haptic_play_effect(struct input_dev *dev, void *data, | |||
| 205 | * The formula to convert magnitude to pwm_duty as follows: | 205 | * The formula to convert magnitude to pwm_duty as follows: |
| 206 | * - pwm_duty = (magnitude * pwm_period) / MAX_MAGNITUDE(0xFFFF) | 206 | * - pwm_duty = (magnitude * pwm_period) / MAX_MAGNITUDE(0xFFFF) |
| 207 | */ | 207 | */ |
| 208 | period_mag_multi = (int64_t)(haptic->pwm_dev->period * | 208 | period_mag_multi = (u64)haptic->pwm_dev->period * haptic->magnitude; |
| 209 | haptic->magnitude); | ||
| 210 | haptic->pwm_duty = (unsigned int)(period_mag_multi >> | 209 | haptic->pwm_duty = (unsigned int)(period_mag_multi >> |
| 211 | MAX_MAGNITUDE_SHIFT); | 210 | MAX_MAGNITUDE_SHIFT); |
| 212 | 211 | ||
diff --git a/drivers/input/misc/soc_button_array.c b/drivers/input/misc/soc_button_array.c index 735604753568..e097f1ab427f 100644 --- a/drivers/input/misc/soc_button_array.c +++ b/drivers/input/misc/soc_button_array.c | |||
| @@ -55,7 +55,7 @@ static int soc_button_lookup_gpio(struct device *dev, int acpi_index) | |||
| 55 | struct gpio_desc *desc; | 55 | struct gpio_desc *desc; |
| 56 | int gpio; | 56 | int gpio; |
| 57 | 57 | ||
| 58 | desc = gpiod_get_index(dev, KBUILD_MODNAME, acpi_index); | 58 | desc = gpiod_get_index(dev, KBUILD_MODNAME, acpi_index, GPIOD_ASIS); |
| 59 | if (IS_ERR(desc)) | 59 | if (IS_ERR(desc)) |
| 60 | return PTR_ERR(desc); | 60 | return PTR_ERR(desc); |
| 61 | 61 | ||
