1. 09 11月, 2014 3 次提交
  2. 21 8月, 2014 1 次提交
    • T
      pinctrl: exynos: Lock GPIOs as interrupts when used as EINTs · f6a8249f
      Tomasz Figa 提交于
      Currently after configuring a GPIO pin as an interrupt related pinmux
      registers are changed, but there is no protection from calling
      gpio_direction_*() in a badly written driver, which would cause the same
      pinmux register to be reconfigured for regular input/output and this
      disabling interrupt capability of the pin.
      
      This patch addresses this issue by moving pinmux reconfiguration to
      .irq_{request,release}_resources() callback of irq_chip and calling
      gpio_lock_as_irq() helper to prevent reconfiguration of pin direction.
      
      Setting up a GPIO interrupt on Samsung SoCs is a two-step operation -
      in addition to trigger configuration in a dedicated register, the pinmux
      must be also reconfigured to GPIO interrupt, which is a different function
      than normal GPIO input, although I/O-wise they both behave in the same way
      and gpio_get_value() can be used on a pin configured as IRQ as well.
      
      Such design implies subtleties such as gpio_direction_input() not having
      to fail if a pin is already configured as an interrupt nor change the
      configuration to normal input. But the FLAG_USED_AS_IRQ set in gpiolib by
      gpio_lock_as_irq() is only used to check that gpio_direction_output() is
      not called, it's not used to prevent gpio_direction_input() to be called.
      So this is not a complete solution for Samsung SoCs but it's definitely a
      move in the right direction.
      Signed-off-by: NTomasz Figa <t.figa@samsung.com>
      [javier: use request resources instead of startup and expand commit message]
      Signed-off-by: NJavier Martinez Canillas <javier.martinez@collabora.co.uk>
      Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
      f6a8249f
  3. 11 7月, 2014 2 次提交
  4. 23 4月, 2014 1 次提交
  5. 11 2月, 2014 1 次提交
  6. 27 9月, 2013 1 次提交
  7. 28 8月, 2013 1 次提交
  8. 19 6月, 2013 1 次提交
  9. 18 6月, 2013 1 次提交
  10. 16 6月, 2013 2 次提交
  11. 27 5月, 2013 2 次提交
  12. 09 4月, 2013 3 次提交
  13. 27 3月, 2013 1 次提交
  14. 05 3月, 2013 1 次提交
  15. 19 11月, 2012 1 次提交
  16. 12 11月, 2012 1 次提交
  17. 15 10月, 2012 5 次提交
  18. 21 9月, 2012 6 次提交
  19. 07 9月, 2012 1 次提交