1. 24 Oct, 2016 1 commit
  2. 19 Feb, 2016 1 commit
    • Linus Walleij's avatar
      gpio: add userspace ABI for GPIO line information · 521a2ad6
      Linus Walleij authored
      This adds a GPIO line ABI for getting name, label and a few select
      flags from the kernel.
      
      This hides the kernel internals and only tells userspace what it
      may need to know: the different in-kernel consumers are masked
      behind the flag "kernel" and that is all userspace needs to know.
      
      However electric characteristics like active low, open drain etc
      are reflected to userspace, as this is important information.
      
      We provide information on all lines on all chips, later on we will
      likely add a flag for the chardev consumer so we can filter and
      display only the lines userspace actually uses in e.g. lsgpio,
      but then we first need an ABI for userspace to grab and use
      (get/set/select direction) a GPIO line.
      
      Sample output from "lsgpio" on ux500:
      
      GPIO chip: gpiochip7, "8011e000.gpio", 32 GPIO lines
              line 0: unnamed unlabeled
              line 1: unnamed unlabeled
      (...)
              line 25: unnamed "SFH7741 Proximity Sensor" [kernel output open-drain]
              line 26: unnamed unlabeled
      (...)
      Tested-by: Michael Welling's avatarMichael Welling <mwelling@ieee.org>
      Signed-off-by: default avatarLinus Walleij <linus.walleij@linaro.org>
      521a2ad6
  3. 09 Feb, 2016 1 commit
    • Linus Walleij's avatar
      tools/gpio: create GPIO tools · 6d591c46
      Linus Walleij authored
      This creates GPIO tools under tools/gpio/* and adds a single
      example program to list the GPIOs on a system. When proper
      devices are created it provides this minimal output:
      
      Cc: Johan Hovold <johan@kernel.org>
      Cc: Michael Welling <mwelling@ieee.org>
      Cc: Markus Pargmann <mpa@pengutronix.de>
      Signed-off-by: default avatarLinus Walleij <linus.walleij@linaro.org>
      6d591c46