Merge tag 'for-v3.7' of git://git.infradead.org/battery-2.6
authorLinus Torvalds <torvalds@linux-foundation.org>
Sun, 7 Oct 2012 08:29:24 +0000 (17:29 +0900)
committerLinus Torvalds <torvalds@linux-foundation.org>
Sun, 7 Oct 2012 08:29:24 +0000 (17:29 +0900)
Pull battery updates from Anton Vorontsov:
 "1. New drivers:
     - Marvell 88pm860x charger and battery drivers;
     - Texas Instruments LP8788 charger driver;
  2. Two new power supply properties: whether a battery is authentic,
     and chargers' maximal currents and voltages;
  3. A lot of TI LP8727 Charger cleanups;
  4. New features for Charger Manager, mainly now we can disable
     specific regulators;
  5. Random fixes and cleanups for other drivers."

Fix up trivial conflicts in <linux/mfd/88pm860x.h>

* tag 'for-v3.7' of git://git.infradead.org/battery-2.6: (52 commits)
  pda_power: Remove ac_draw_failed goto and label
  charger-manager: Add support sysfs entry for charger
  charger-manager: Support limit of maximum possible
  charger-manager: Check fully charged state of battery periodically
  lp8727_charger: More pure cosmetic improvements
  lp8727_charger: Fix checkpatch warning
  lp8727_charger: Add description in the private data
  lp8727_charger: Fix a typo - chg_parm to chg_param
  lp8727_charger: Make some cosmetic changes in lp8727_delayed_func()
  lp8727_charger: Clean up lp8727_charger_changed()
  lp8727_charger: Return if the battery is discharging
  lp8727_charger: Make lp8727_charger_get_propery() simpler
  lp8727_charger: Make lp8727_ctrl_switch() inline
  lp8727_charger: Make lp8727_init_device() shorter
  lp8727_charger: Clean up lp8727_is_charger_attached()
  lp8727_charger: Use specific definition
  lp8727_charger: Clean up lp8727 definitions
  lp8727_charger: Use the definition rather than enum
  lp8727_charger: Fix code for getting battery temp
  lp8727_charger: Clear interrrupts at inital time
  ...

1  2 
drivers/mfd/88pm860x-core.c
drivers/power/Kconfig
drivers/power/Makefile
drivers/power/ab8500_btemp.c
drivers/power/ab8500_charger.c
drivers/power/ab8500_fg.c
drivers/power/charger-manager.c
drivers/power/wm97xx_battery.c
include/linux/mfd/88pm860x.h

index 59d117e9fa313840bfc95190b3e9160e8deec742,2abd607eb05b53396490ea4420af17328b596dd9..8fa86edf70d46ae77d7e47589b6641a3e411ba58
@@@ -925,10 -792,25 +932,23 @@@ static void __devinit device_power_init
  
        power_devs[2].platform_data = &preg_init_data;
        power_devs[2].pdata_size = sizeof(struct regulator_init_data);
 -      power_devs[2].num_resources = ARRAY_SIZE(preg_resources);
 -      power_devs[2].resources = &preg_resources[0],
        ret = mfd_add_devices(chip->dev, 0, &power_devs[2], 1,
 -                            &preg_resources[0], chip->irq_base, NULL);
 +                            NULL, chip->irq_base, NULL);
        if (ret < 0)
                dev_err(chip->dev, "Failed to add preg subdev\n");
+       if (pdata->chg_desc) {
+               pdata->chg_desc->charger_regulators =
+                       &chg_desc_regulator_data[0];
+               pdata->chg_desc->num_charger_regulators =
+                       ARRAY_SIZE(chg_desc_regulator_data),
+               power_devs[3].platform_data = pdata->chg_desc;
+               power_devs[3].pdata_size = sizeof(*pdata->chg_desc);
+               ret = mfd_add_devices(chip->dev, 0, &power_devs[3], 1,
+                                     NULL, chip->irq_base, NULL);
+               if (ret < 0)
+                       dev_err(chip->dev, "Failed to add chg-manager subdev\n");
+       }
  }
  
  static void __devinit device_onkey_init(struct pm860x_chip *chip,
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
index ef3e6b701179e3c09d6898d2f3df288fd50866cc,b7c5a3c27c98d5c6d30ff85a407de688135bf091..cd97530205c22e995708ec7c4f96ca31aaf3841b
@@@ -359,24 -460,10 +440,25 @@@ struct pm860x_platform_data 
        struct pm860x_rtc_pdata         *rtc;
        struct pm860x_touch_pdata       *touch;
        struct pm860x_power_pdata       *power;
 -      struct regulator_init_data      *regulator;
 +      struct regulator_init_data      *buck1;
 +      struct regulator_init_data      *buck2;
 +      struct regulator_init_data      *buck3;
 +      struct regulator_init_data      *ldo1;
 +      struct regulator_init_data      *ldo2;
 +      struct regulator_init_data      *ldo3;
 +      struct regulator_init_data      *ldo4;
 +      struct regulator_init_data      *ldo5;
 +      struct regulator_init_data      *ldo6;
 +      struct regulator_init_data      *ldo7;
 +      struct regulator_init_data      *ldo8;
 +      struct regulator_init_data      *ldo9;
 +      struct regulator_init_data      *ldo10;
 +      struct regulator_init_data      *ldo12;
 +      struct regulator_init_data      *ldo_vibrator;
 +      struct regulator_init_data      *ldo14;
+       struct charger_desc             *chg_desc;
  
 -      unsigned short  companion_addr; /* I2C address of companion chip */
 +      int             companion_addr; /* I2C address of companion chip */
        int             i2c_port;       /* Controlled by GI2C or PI2C */
        int             irq_mode;       /* Clear interrupt by read/write(0/1) */
        int             irq_base;       /* IRQ base number of 88pm860x */