]> git.ipfire.org Git - thirdparty/kernel/stable.git/commitdiff
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input
authorLinus Torvalds <torvalds@linux-foundation.org>
Fri, 7 Oct 2016 16:12:19 +0000 (09:12 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Fri, 7 Oct 2016 16:12:19 +0000 (09:12 -0700)
Pull input subsystem updates from Dmitry Torokhov:
 "You will get

   - a new driver for Elan eKTF2127 touchscreen controllers

   - a new "gpio-decoder" driver to read and report state of several
     GPIO lines

   - an ADC resistor ladder driver

   - the ft6326 driver is removed because edt-ft5x06 handles the same
     devices just fine.

  .. plus the regular slew of driver fixes/enhancements"

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input: (26 commits)
  Input: elan_i2c - fix return tests of i2c_smbus_read_block_data()
  Input: ektf2127 - mark PM functions as __maybe_unused
  Input: snvs_pwrkey - drop input_free_device call if input_register_device fails
  Input: add support for Elan eKTF2127 touchscreen controller
  Input: serio - add hangup support
  Input: tps65218-pwrbutton - add support for tps65217 variant
  Input: jornada720_ts - get rid of mach/irqs.h and mach/hardware.h includes
  Input: jornada720_kbd - remove unneeded mach/hardware.h include
  Input: focaltech - mark focaltech_set_resolution() static
  Input: wdt87xx_i2c - fix the flash erase issue
  Input: gpio-keys-polled - don't use unit-address with button nodes
  Input: add generic input driver to read encoded GPIO lines
  Input: add ADC resistor ladder driver
  Input: pegasus_notetaker - directly include workqueue header
  Input: elants_i2c - get product id on recovery mode for FW update
  Input: wm97xx - remove deprecated create_singletheread_workqueue
  Input: mc13783_ts - remove deprecated create_singletheread_workqueue
  Input: psmouse - remove deprecated create_singletheread_workqueue
  Input: jornada720_kbd - switch to using dev_dbg
  Input: jornada720_kbd - get rid of mach/irqs.h include
  ...

1  2 
drivers/input/misc/max77693-haptic.c

index 29ddeb7be84bb485f676ea1fb632db48a53d9cfc,08d5394dd9815ea45f30b9670948d79f7317574e..46b0f48fbf49a3f6feb578e768a336c63f2c9fec
@@@ -3,7 -3,7 +3,7 @@@
   *
   * Copyright (C) 2014,2015 Samsung Electronics
   * Jaewon Kim <jaewon02.kim@samsung.com>
-  * Krzysztof Kozlowski <k.kozlowski@samsung.com>
+  * Krzysztof Kozlowski <krzk@kernel.org>
   *
   * This program is not provided / owned by Maxim Integrated Products.
   *
@@@ -70,13 -70,10 +70,13 @@@ struct max77693_haptic 
  
  static int max77693_haptic_set_duty_cycle(struct max77693_haptic *haptic)
  {
 -      int delta = (haptic->pwm_dev->period + haptic->pwm_duty) / 2;
 +      struct pwm_args pargs;
 +      int delta;
        int error;
  
 -      error = pwm_config(haptic->pwm_dev, delta, haptic->pwm_dev->period);
 +      pwm_get_args(haptic->pwm_dev, &pargs);
 +      delta = (pargs.period + haptic->pwm_duty) / 2;
 +      error = pwm_config(haptic->pwm_dev, delta, pargs.period);
        if (error) {
                dev_err(haptic->dev, "failed to configure pwm: %d\n", error);
                return error;
@@@ -237,7 -234,6 +237,7 @@@ static int max77693_haptic_play_effect(
                                       struct ff_effect *effect)
  {
        struct max77693_haptic *haptic = input_get_drvdata(dev);
 +      struct pwm_args pargs;
        u64 period_mag_multi;
  
        haptic->magnitude = effect->u.rumble.strong_magnitude;
         * The formula to convert magnitude to pwm_duty as follows:
         * - pwm_duty = (magnitude * pwm_period) / MAX_MAGNITUDE(0xFFFF)
         */
 -      period_mag_multi = (u64)haptic->pwm_dev->period * haptic->magnitude;
 +      pwm_get_args(haptic->pwm_dev, &pargs);
 +      period_mag_multi = (u64)pargs.period * haptic->magnitude;
        haptic->pwm_duty = (unsigned int)(period_mag_multi >>
                                                MAX_MAGNITUDE_SHIFT);
  
@@@ -334,12 -329,6 +334,12 @@@ static int max77693_haptic_probe(struc
                return PTR_ERR(haptic->pwm_dev);
        }
  
 +      /*
 +       * FIXME: pwm_apply_args() should be removed when switching to the
 +       * atomic PWM API.
 +       */
 +      pwm_apply_args(haptic->pwm_dev);
 +
        haptic->motor_reg = devm_regulator_get(&pdev->dev, "haptic");
        if (IS_ERR(haptic->motor_reg)) {
                dev_err(&pdev->dev, "failed to get regulator\n");
@@@ -426,7 -415,7 +426,7 @@@ static struct platform_driver max77693_
  module_platform_driver(max77693_haptic_driver);
  
  MODULE_AUTHOR("Jaewon Kim <jaewon02.kim@samsung.com>");
- MODULE_AUTHOR("Krzysztof Kozlowski <k.kozlowski@samsung.com>");
+ MODULE_AUTHOR("Krzysztof Kozlowski <krzk@kernel.org>");
  MODULE_DESCRIPTION("MAXIM 77693/77843 Haptic driver");
  MODULE_ALIAS("platform:max77693-haptic");
  MODULE_LICENSE("GPL");