1. 10 Jan, 2023 38 commits
  2. 09 Dec, 2022 2 commits
    • Douglas Anderson's avatar
      Input: elants_i2c - delay longer with reset asserted · c3991107
      Douglas Anderson authored
      The elan touchscreen datasheet says that the reset GPIO only needs to
      be asserted for 500us in order to reset the regulator. The problem is
      that some boards need a level shifter between the signals on the GPIO
      controller and the signals on the touchscreen. All of these extra
      components on the line can slow the transition of the signals. On one
      board, we measured the reset line and saw that it took almost 1.8ms to
      go low. Even after we bumped up the "drive strength" of the signal
      from the default 2mA to 8mA we still saw it take 421us for the signal
      to go low.
      
      In order to account for this let's lengthen the amount of time that we
      keep the reset asserted. Let's bump it up from 500us to 5000us.
      That's still a relatively short amount of time and is much safer.
      
      It should be noted that this fixes real problems. Case in point:
      1. The touchscreen power rail may be shared with another device (like
         an eDP panel). That means that at probe time power might already be
         on.
      2. In probe we grab the reset GPIO and assert it (make it low).
      3. We turn on power (a noop since it was already on).
      4. We wait 500us.
      5. We deassert the reset GPIO.
      
      With the above case and only a 500us delay we saw only a partial reset
      asserted, which is bad. Giving it 5ms is overkill but feels safer in
      case someone else has a different level shifter setup.
      
      Note that bumping up the delay to 5000 means that some configs yell
      about using udelay(). We'll change to using usleep_range(). We give a
      small range here because:
      - This isn't a delay that happens very often so we don't need to worry
        about giving a big range to allow for power efficiency.
      - usleep_range() is known to almost always pick the upper bound and
        delay that long and we really don't want to slow down the power on
        of the touchscreen that much.
      Signed-off-by: default avatarDouglas Anderson <dianders@chromium.org>
      Reviewed-by: default avatarMatthias Kaehlcke <mka@chromium.org>
      Link: https://lore.kernel.org/r/20221208180603.v2.5.I6edfb3f459662c041563a54e5b7df727c27caaba@changeidSigned-off-by: default avatarDmitry Torokhov <dmitry.torokhov@gmail.com>
      c3991107
    • Luca Weiss's avatar
      dt-bindings: input: Convert ti,drv260x to DT schema · 39cb018a
      Luca Weiss authored
      Convert the drv260x haptics binding to DT schema format.
      
      The only notable change from .txt format is that vbat-supply is not
      actually required, so don't make it a required property.
      Acked-by: default avatarAndrew Davis <afd@ti.com>
      Signed-off-by: default avatarLuca Weiss <luca@z3ntu.xyz>
      Reviewed-by: default avatarRob Herring <robh@kernel.org>
      Link: https://lore.kernel.org/r/20221118174831.69793-1-luca@z3ntu.xyzSigned-off-by: default avatarDmitry Torokhov <dmitry.torokhov@gmail.com>
      39cb018a