1. 19 Oct, 2018 2 commits
  2. 15 Oct, 2018 1 commit
  3. 12 Oct, 2018 2 commits
    • Linus Walleij's avatar
      regulator/gpio: Allow nonexclusive GPIO access · b0ce7b29
      Linus Walleij authored
      This allows nonexclusive (simultaneous) access to a single
      GPIO line for the fixed regulator enable line. This happens
      when several regulators use the same GPIO for enabling and
      disabling a regulator, and all need a handle on their GPIO
      descriptor.
      
      This solution with a special flag is not entirely elegant
      and should ideally be replaced by something more careful as
      this makes it possible for several consumers to
      enable/disable the same GPIO line to the left and right
      without any consistency. The current use inside the regulator
      core should however be fine as it takes special care to
      handle this.
      
      For the state of the GPIO backend, this is still the
      lesser evil compared to going back to global GPIO
      numbers.
      
      Cc: Marek Szyprowski <m.szyprowski@samsung.com>
      Cc: Jon Hunter <jonathanh@nvidia.com>
      Fixes: efdfeb07 ("regulator: fixed: Convert to use GPIO descriptor only")
      Reported-by: default avatarMarek Szyprowski <m.szyprowski@samsung.com>
      Tested-by: default avatarJon Hunter <jonathanh@nvidia.com>
      Tested-by: default avatarMarek Szyprowski <m.szyprowski@samsung.com>
      Signed-off-by: default avatarLinus Walleij <linus.walleij@linaro.org>
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      b0ce7b29
    • Charles Keepax's avatar
      regulator: lochnagar: Add support for the Cirrus Logic Lochnagar · bef9391c
      Charles Keepax authored
      Lochnagar is an evaluation and development board for Cirrus
      Logic Smart CODEC and Amp devices. It allows the connection of
      most Cirrus Logic devices on mini-cards, as well as allowing
      connection of various application processor systems to provide a
      full evaluation platform. This driver supports the board
      controller chip on the Lochnagar board.
      
      The Lochnagar board provides power supplies for the attached
      CODEC/Amp device. Currently this driver supports the microphone
      supplies and the digital core voltage for the attached
      device. There are some additional supplies that will be
      added in time but these supplies are sufficient for most
      systems/use-cases.
      Signed-off-by: default avatarCharles Keepax <ckeepax@opensource.wolfsonmicro.com>
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      bef9391c
  4. 10 Oct, 2018 1 commit
  5. 08 Oct, 2018 1 commit
  6. 04 Oct, 2018 1 commit
  7. 02 Oct, 2018 1 commit
  8. 28 Sep, 2018 5 commits
  9. 21 Sep, 2018 1 commit
  10. 20 Sep, 2018 2 commits
  11. 19 Sep, 2018 1 commit
  12. 17 Sep, 2018 2 commits
    • Linus Walleij's avatar
      regulator: fixed: Convert to use GPIO descriptor only · efdfeb07
      Linus Walleij authored
      As we augmented the regulator core to accept a GPIO descriptor instead
      of a GPIO number, we can augment the fixed GPIO regulator to look up
      and pass that descriptor directly from device tree or board GPIO
      descriptor look up tables.
      
      Some boards just auto-enumerate their fixed regulator platform devices
      and I have assumed they get names like "fixed-regulator.0" but it's
      pretty hard to guess this. I need some testing from board maintainers to
      be sure. Other boards are straight forward, using just plain
      "fixed-regulator" (ID -1) or "fixed-regulator.1" hammering down the
      device ID.
      
      It seems the da9055 and da9211 has never got around to actually passing
      any enable gpio into its platform data (not the in-tree code anyway) so we
      can just decide to simply pass a descriptor instead.
      
      The fixed GPIO-controlled regulator in mach-pxa/ezx.c was confusingly named
      "*_dummy_supply_device" while it is a very real device backed by a GPIO
      line. There is nothing dummy about it at all, so I renamed it with the
      infix *_regulator_* as part of this patch set.
      
      Intel MID portions tested by Andy.
      
      Tested-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> # Check the x86 BCM stuff
      Acked-by: Tony Lindgren <tony@atomide.com> # OMAP1,2,3 maintainer
      Signed-off-by: default avatarLinus Walleij <linus.walleij@linaro.org>
      Reviewed-by: default avatarJanusz Krzysztofik <jmkrzyszt@gmail.com>
      Reviewed-by: default avatarMike Rapoport <rppt@linux.vnet.ibm.com>
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      efdfeb07
    • Colin Ian King's avatar
      regulator: pfuze100-regulator: fix spelling mistake "standy" -> "standby" · db6565af
      Colin Ian King authored
      Trivial fix to spelling mistake in dev_info message
      Signed-off-by: default avatarColin Ian King <colin.king@canonical.com>
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      db6565af
  13. 11 Sep, 2018 1 commit
    • Oleksij Rempel's avatar
      regulator: pfuze100-regulator: provide pm_power_off_prepare handler · c29daffa
      Oleksij Rempel authored
      On some boards the SoC can use one pin "PMIC_STBY_REQ" to notify th PMIC
      about state changes. In this case internal state of PMIC must be
      preconfigured for upcomming state change.
      It works fine with the current regulator framework, except with the
      power-off case.
      
      This patch is providing an optional pm_power_off_prepare handler
      which will configure standby state of the PMIC to disable all power lines.
      
      In my power consumption test on RIoTBoard, I got the following results:
      power off without this patch:	320 mA
      power off with this patch:	2   mA
      suspend to ram:			40  mA
      Signed-off-by: default avatarOleksij Rempel <o.rempel@pengutronix.de>
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      c29daffa
  14. 07 Sep, 2018 1 commit
    • David Frey's avatar
      regmap: split up regmap_config.use_single_rw · 1c96a2f6
      David Frey authored
      Split regmap_config.use_single_rw into use_single_read and
      use_single_write. This change enables drivers of devices which only
      support bulk operations in one direction to use the regmap_bulk_*()
      functions for both directions and have their bulk operation split into
      single operations only when necessary.
      
      Update all struct regmap_config instances where use_single_rw==true to
      instead set both use_single_read and use_single_write. No attempt was
      made to evaluate whether it is possible to set only one of
      use_single_read or use_single_write.
      Signed-off-by: default avatarDavid Frey <dpfrey@gmail.com>
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      1c96a2f6
  15. 04 Sep, 2018 1 commit
  16. 03 Sep, 2018 2 commits
    • Marek Szyprowski's avatar
      regulator: Fix useless O^2 complexity in suspend/resume · cd7e36ab
      Marek Szyprowski authored
      regulator_pm_ops with regulator_suspend and regulator_resume functions are
      assigned to every regulator device registered in the system, so there is no
      need to iterate over all again in them. Replace class_for_each_device()
      construction with direct operation on the rdev embedded in the given
      regulator device. This saves a lots of useless operations in suspend and
      resume paths.
      
      Fixes: f7efad10: regulator: add PM suspend and resume hooks
      Signed-off-by: default avatarMarek Szyprowski <m.szyprowski@samsung.com>
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      cd7e36ab
    • Marek Szyprowski's avatar
      regulator: Fix 'do-nothing' value for regulators without suspend state · 3edd79cf
      Marek Szyprowski authored
      Some regulators don't have all states defined and in such cases regulator
      core should not assume anything. However in current implementation
      of of_get_regulation_constraints() DO_NOTHING_IN_SUSPEND enable value was
      set only for regulators which had suspend node defined, otherwise the
      default 0 value was used, what means DISABLE_IN_SUSPEND. This lead to
      broken system suspend/resume on boards, which had simple regulator
      constraints definition (without suspend state nodes).
      
      To avoid further mismatches between the default and uninitialized values
      of the suspend enabled/disabled states, change the values of the them,
      so default '0' means DO_NOTHING_IN_SUSPEND.
      
      Fixes: 72069f99: regulator: leave one item to record whether regulator is enabled
      Signed-off-by: default avatarMarek Szyprowski <m.szyprowski@samsung.com>
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      Cc: stable@vger.kernel.org
      3edd79cf
  17. 29 Aug, 2018 1 commit
  18. 28 Aug, 2018 8 commits
  19. 10 Aug, 2018 1 commit
    • David Collins's avatar
      regulator: add QCOM RPMh regulator driver · 46fc033e
      David Collins authored
      Add the QCOM RPMh regulator driver to manage PMIC regulators
      which are controlled via RPMh on some Qualcomm Technologies, Inc.
      SoCs.  RPMh is a hardware block which contains several
      accelerators which are used to manage various hardware resources
      that are shared between the processors of the SoC.  The final
      hardware state of a regulator is determined within RPMh by
      performing max aggregation of the requests made by all of the
      processors.
      
      Add support for PMIC regulator control via the voltage regulator
      manager (VRM) and oscillator buffer (XOB) RPMh accelerators.
      VRM supports manipulation of enable state, voltage, and mode.
      XOB supports manipulation of enable state.
      Signed-off-by: default avatarDavid Collins <collinsd@codeaurora.org>
      Reviewed-by: default avatarDouglas Anderson <dianders@chromium.org>
      Reviewed-by: default avatarMatthias Kaehlcke <mka@chromium.org>
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      46fc033e
  20. 08 Aug, 2018 2 commits
  21. 30 Jul, 2018 2 commits
  22. 24 Jul, 2018 1 commit