]> git.dujemihanovic.xyz Git - u-boot.git/commit
Merge branch '2023-08-14-keep-fixed-gpio-regulator-count-in-balance' into next
authorTom Rini <trini@konsulko.com>
Mon, 14 Aug 2023 13:14:51 +0000 (09:14 -0400)
committerTom Rini <trini@konsulko.com>
Mon, 14 Aug 2023 13:14:51 +0000 (09:14 -0400)
commit831a80c2af322a80890cd9ef81c8ab7697788712
tree99340a83103530a83c49b59a9280cc833bd1bec3
parent321d7b4d875a77552a969dd6ea5bbed2644fcb0c
parent01b2917a1973b804338d3edbbd46198c540ba9f5
Merge branch '2023-08-14-keep-fixed-gpio-regulator-count-in-balance' into next

To quote the author:

The commit 4fcba5d556b4 ("regulator: implement basic reference counter")
have made it more important to keep fixed/gpio regulators enable/disable
state in balance.

This series fixes an inbalance in the mmc_dw driver and changes to use
the more relaxed regulator_set_enable_if_allowed function for a few
other drivers.

The regulator_set_enable_if_allowed function is more relaxed and will
return ENOSYS if the provided regulator is NULL or when DM_REGULATOR
was disabled. Using the following call convention should be safe:

  ret = regulator_set_enable_if_allowed(<supply>, <true|false>);
  if (ret && ret != -ENOSYS)
          return ret;