1. 17 4月, 2020 13 次提交
  2. 16 4月, 2020 1 次提交
  3. 02 4月, 2020 2 次提交
  4. 01 4月, 2020 1 次提交
  5. 31 3月, 2020 1 次提交
  6. 28 3月, 2020 4 次提交
  7. 27 3月, 2020 3 次提交
  8. 26 3月, 2020 1 次提交
  9. 25 3月, 2020 7 次提交
  10. 24 3月, 2020 1 次提交
  11. 20 3月, 2020 1 次提交
  12. 11 3月, 2020 4 次提交
    • H
      gpiolib: acpi: Add quirk to ignore EC wakeups on HP x2 10 BYT + AXP288 model · 0e91506b
      Hans de Goede 提交于
      Commit aa23ca3d ("gpiolib: acpi: Add honor_wakeup module-option +
      quirk mechanism") was added to deal with spurious wakeups on one specific
      model of the HP x2 10 series. In the mean time I have learned that there
      are at least 3 different HP x2 10 models:
      
      Bay Trail SoC + AXP288 PMIC
      Cherry Trail SoC + AXP288 PMIC
      Cherry Trail SoC + TI PMIC
      
      And the original quirk is only correct for (and only matches the)
      Cherry Trail SoC + TI PMIC model.
      
      The Bay Trail SoC + AXP288 PMIC model has different DMI strings, has
      the external EC interrupt on a different GPIO pin and only needs to ignore
      wakeups on the EC interrupt, the INT0002 device works fine on this model.
      
      This commit adds an extra DMI based quirk for the HP x2 10 BYT + AXP288
      model, ignoring wakeups for ACPI GPIO events on the EC interrupt pin
      on this model. This fixes spurious wakeups from suspend on this model.
      
      Fixes: aa23ca3d ("gpiolib: acpi: Add honor_wakeup module-option + quirk mechanism")
      Signed-off-by: NHans de Goede <hdegoede@redhat.com>
      Link: https://lore.kernel.org/r/20200302111225.6641-3-hdegoede@redhat.comAcked-by: NMika Westerberg <mika.westerberg@linux.intel.com>
      Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
      0e91506b
    • H
      gpiolib: acpi: Rework honor_wakeup option into an ignore_wake option · 2ccb21f5
      Hans de Goede 提交于
      Commit aa23ca3d ("gpiolib: acpi: Add honor_wakeup module-option +
      quirk mechanism") was added to deal with spurious wakeups on one specific
      model of the HP x2 10 series.
      
      The approach taken there was to add a bool controlling wakeup support for
      all ACPI GPIO events. This was sufficient for the specific HP x2 10 model
      the commit was trying to fix, but in the mean time other models have
      turned up which need a similar workaround to avoid spurious wakeups from
      suspend, but only for one of the pins on which the ACPI tables request
      ACPI GPIO events.
      
      Since the honor_wakeup option was added to be able to ignore wake events,
      the name was perhaps not the best, this commit renames it to ignore_wake
      and changes it to a string with the following format:
      gpiolib_acpi.ignore_wake=controller@pin[,controller@pin[,...]]
      
      This allows working around spurious wakeup issues on a per pin basis.
      
      This commit also reworks the existing quirk for the HP x2 10 so that
      it functions as before.
      
      Note:
      -This removes the honor_wakeup parameter. This has only been upstream for
       a short time and to the best of my knowledge there are no users using
       this module parameter.
      
      -The controller@pin[,controller@pin[,...]] syntax is based on an existing
       kernel module parameter using the same controller@pin format. That version
       uses ';' as separator, but in practice that is problematic because grub2
       cannot handle this without taking special care to escape the ';', so here
       we are using a ',' as separator instead which does not have this issue.
      
      Fixes: aa23ca3d ("gpiolib: acpi: Add honor_wakeup module-option + quirk mechanism")
      Signed-off-by: NHans de Goede <hdegoede@redhat.com>
      Link: https://lore.kernel.org/r/20200302111225.6641-2-hdegoede@redhat.comAcked-by: NMika Westerberg <mika.westerberg@linux.intel.com>
      Reviewed-by: NAndy Shevchenko <andriy.shevchenko@linux.intel.com>
      Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
      2ccb21f5
    • H
      gpiolib: acpi: Correct comment for HP x2 10 honor_wakeup quirk · efaa87fa
      Hans de Goede 提交于
      Commit aa23ca3d ("gpiolib: acpi: Add honor_wakeup module-option +
      quirk mechanism") added a quirk for some models of the HP x2 10 series.
      
      There are 2 issues with the comment describing the quirk:
      1) The comment claims the DMI quirk applies to all Cherry Trail based HP x2
         10 models. In the mean time I have learned that there are at least 3
         models of the HP x2 10 models:
      
         Bay Trail SoC + AXP288 PMIC
         Cherry Trail SoC + AXP288 PMIC
         Cherry Trail SoC + TI PMIC
      
         And this quirk's DMI matches only match the Cherry Trail SoC + TI PMIC
         SoC, which is good because we want a slightly different quirk for the
         others. This commit updates the comment to make it clear that the quirk
         is only for the Cherry Trail SoC + TI PMIC models.
      
      2) The comment says that it is ok to disable wakeup on all ACPI GPIO event
         handlers, because there is only the one for the embedded-controller
         events. This is not true, there also is a handler for the special
         INT0002 device which is related to USB wakeups. We need to also disable
         wakeups on that one because the device turns of the USB-keyboard built
         into the dock when closing the lid. The XHCI controller takes a while
         to notice this, so it only notices it when already suspended, causing
         a spurious wakeup because of this. So disabling wakeup on all handlers
         is the right thing to do, but not because there only is the one handler
         for the EC events. This commit updates the comment to correctly reflect
         this.
      
      Fixes: aa23ca3d ("gpiolib: acpi: Add honor_wakeup module-option + quirk mechanism")
      Signed-off-by: NHans de Goede <hdegoede@redhat.com>
      Link: https://lore.kernel.org/r/20200302111225.6641-1-hdegoede@redhat.comAcked-by: NMika Westerberg <mika.westerberg@linux.intel.com>
      Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
      efaa87fa
    • L
      gpiolib: Fix irq_disable() semantics · 8959b304
      Linus Walleij 提交于
      The implementation if .irq_disable() which kicks in between
      the gpiolib and the driver is not properly mimicking the
      expected semantics of the irqchip core: the irqchip will
      call .irq_disable() if that exists, else it will call
      mask_irq() which first checks if .irq_mask() is defined
      before calling it.
      
      Since we are calling it unconditionally, we get this bug
      from drivers/pinctrl/qcom/pinctrl-ssbi-gpio.c, as it only
      defines .irq_mask_ack and not .irq_mask:
      
        Unable to handle kernel NULL pointer dereference at virtual address 00000000
        pgd = (ptrval)
        (...)
        PC is at 0x0
        LR is at gpiochip_irq_disable+0x20/0x30
      
      Fix this by only calling .irq_mask() if it exists.
      
      Cc: Brian Masney <masneyb@onstation.org>
      Cc: Hans Verkuil <hans.verkuil@cisco.com>
      Cc: stable@vger.kernel.org
      Reviewed-by: NBartosz Golaszewski <bgolaszewski@baylibre.com>
      Fixes: 461c1a7d ("gpiolib: override irq_enable/disable")
      Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
      Link: https://lore.kernel.org/r/20200306132326.1329640-1-linus.walleij@linaro.org
      8959b304
  13. 09 3月, 2020 1 次提交