Skip to content
A bunch of GPIO fixes for the v4.7 series:

- Drop the lock before reading out the GPIO direction
  setting in drivers supporting the .get_direction()
  callback: some of them may be slowpath.

- Flush GPIO direction setting before locking a GPIO as an
  IRQ: some electronics or other poking around in the
  registers behind our back may have happened, so flush
  the direction status before trying to lock the line for
  use by IRQs.

- Bail out silently when asked to perform operations on
  NULL GPIO descriptors. That is what all the get_*_optional()
  is about: we get optional GPIO handles, if they are not
  there, we get NULL.

- Handle compatible ioctl() correctly: we need to convert
  the ioctl() pointer using compat_ptr() here like everyone
  else.

- Disable the broken .to_irq() on the LPC32xx platform.
  The whole irqchip infrastructure was replaced in the
  last merge window, and a new implementation will be
  needed.