Merge remote-tracking branches 'regulator/topic/discharge', 'regulator/topic/fan53555...
authorMark Brown <broonie@kernel.org>
Sun, 13 Mar 2016 08:19:35 +0000 (15:19 +0700)
committerMark Brown <broonie@kernel.org>
Sun, 13 Mar 2016 08:19:35 +0000 (15:19 +0700)
1  2  3  4  5  6 
drivers/regulator/Kconfig
drivers/regulator/Makefile
drivers/regulator/core.c

Simple merge
@@@@@@@ -35,9 -34,9 -34,8 -34,9 -34,10 -34,9 +35,10 @@@@@@@ obj-$(CONFIG_REGULATOR_DB8500_PRCMU) +
      obj-$(CONFIG_REGULATOR_FAN53555) += fan53555.o
      obj-$(CONFIG_REGULATOR_GPIO) += gpio-regulator.o
      obj-$(CONFIG_REGULATOR_HI6421) += hi6421-regulator.o
++++ +obj-$(CONFIG_REGULATOR_HI655X) += hi655x-regulator.o
      obj-$(CONFIG_REGULATOR_ISL6271A) += isl6271a-regulator.o
      obj-$(CONFIG_REGULATOR_ISL9305) += isl9305.o
  +   obj-$(CONFIG_REGULATOR_LM363X) += lm363x-regulator.o
      obj-$(CONFIG_REGULATOR_LP3971) += lp3971.o
      obj-$(CONFIG_REGULATOR_LP3972) += lp3972.o
      obj-$(CONFIG_REGULATOR_LP872X) += lp872x.o
@@@@@@@ -1135,12 -1136,27 -1136,16 -1136,16 -1136,16 -1136,16 +1135,23 @@@@@@@ static int set_machine_constraints(stru
                ret = ops->set_over_current_protection(rdev);
                if (ret < 0) {
                        rdev_err(rdev, "failed to set over current protection\n");
 -----                  goto out;
 +++++                  return ret;
  ++++          }
  ++++  }
  ++++
+ ++++  if (rdev->constraints->active_discharge && ops->set_active_discharge) {
+ ++++          bool ad_state = (rdev->constraints->active_discharge ==
+ ++++                        REGULATOR_ACTIVE_DISCHARGE_ENABLE) ? true : false;
+ ++++
+ ++++          ret = ops->set_active_discharge(rdev, ad_state);
+ ++++          if (ret < 0) {
+ ++++                  rdev_err(rdev, "failed to set active discharge\n");
+ ++++                  return ret;
+               }
+       }
+     
        print_constraints(rdev);
        return 0;
 -----out:
 -----  kfree(rdev->constraints);
 -----  rdev->constraints = NULL;
 -----  return ret;
      }
      
      /**