diff --git a/drivers/power/bq27000_battery.c b/drivers/power/bq27000_battery.c
index cd4968e..d9be57a 100644
--- a/drivers/power/bq27000_battery.c
+++ b/drivers/power/bq27000_battery.c
@@ -29,6 +29,7 @@
 #include <linux/jiffies.h>
 #include <linux/delay.h>
 #include <linux/pm.h>
+#include <linux/workqueue.h>
 #include <linux/platform_device.h>
 #include <linux/power_supply.h>
 #include <linux/bq27000_battery.h>
@@ -110,9 +111,14 @@ enum bq27000_status_flags {
 
 #define NANOVOLTS_UNIT 3750
 
+#undef DO_BQ2700_WORK
+
 struct bq27000_device_info {
 	struct device *dev;
 	struct power_supply bat;
+	struct power_supply ac;
+	struct power_supply usb;
+	struct work_struct work;
 	struct bq27000_platform_data *pdata;
 };
 
@@ -147,13 +153,9 @@ static int hdq_read16(struct bq27000_device_info *di, int address)
 	return -ETIME;
 }
 
-#define to_bq27000_device_info(x) container_of((x), \
-					       struct bq27000_device_info, \
-					       bat);
-
 static void bq27000_battery_external_power_changed(struct power_supply *psy)
 {
-	struct bq27000_device_info *di = to_bq27000_device_info(psy);
+	struct bq27000_device_info *di = container_of(psy, struct bq27000_device_info, bat);
 
 	dev_dbg(di->dev, "%s\n", __FUNCTION__);
 }
@@ -163,7 +165,7 @@ static int bq27000_battery_get_property(struct power_supply *psy,
 				       union power_supply_propval *val)
 {
 	int v, n;
-	struct bq27000_device_info *di = to_bq27000_device_info(psy);
+	struct bq27000_device_info *di = container_of(psy, struct bq27000_device_info, bat);
 
 	if (!(di->pdata->hdq_initialized)())
 		return -EINVAL;
@@ -228,6 +230,15 @@ use_bat:
 		else
 			val->intval = POWER_SUPPLY_STATUS_DISCHARGING;
 		break;
+	case POWER_SUPPLY_PROP_HEALTH:
+		val->intval = POWER_SUPPLY_HEALTH_UNKNOWN;
+		/* Do we have accurate readings... */
+		v = (di->pdata->hdq_read)(BQ27000_FLAGS);
+		if (v < 0)
+			return v;
+		if (v & BQ27000_STATUS_VDQ)
+			val->intval = POWER_SUPPLY_HEALTH_GOOD;
+		break;
 	case POWER_SUPPLY_PROP_VOLTAGE_NOW:
 		v = hdq_read16(di, BQ27000_VOLT_L);
 		if (v < 0)
@@ -299,8 +310,70 @@ use_bat:
 	return 0;
 }
 
+static void bq27000_battery_work(struct work_struct *work)
+{
+	struct bq27000_device_info *di = container_of(work, struct bq27000_device_info, work);
+
+	/* Check battery capacity every 10 seconds */
+	msleep(10000);
+
+	power_supply_changed(&di->bat);
+
+	if (!schedule_work(&di->work))
+		dev_err(di->dev, "battery service reschedule failed\n");
+}
+
+static int ac_get_property(struct power_supply *psy,
+			enum power_supply_property psp,
+			union power_supply_propval *val)
+{
+	int ret = 0;
+	struct bq27000_device_info *di = container_of(psy, struct bq27000_device_info, ac);
+
+	if (!(di->pdata->hdq_initialized)())
+		return -EINVAL;
+
+	switch (psp) {
+	case POWER_SUPPLY_PROP_ONLINE:
+		if (di->pdata->get_charger_online_status)
+			val->intval = (di->pdata->get_charger_online_status)();
+		else
+			return -EINVAL;
+		break;
+	default:
+		ret = -EINVAL;
+		break;
+	}
+	return ret;
+}
+
+static int usb_get_property(struct power_supply *psy,
+			enum power_supply_property psp,
+			union power_supply_propval *val)
+{
+	int ret = 0;
+	struct bq27000_device_info *di = container_of(psy, struct bq27000_device_info, usb);
+
+	if (!(di->pdata->hdq_initialized)())
+		return -EINVAL;
+
+	switch (psp) {
+	case POWER_SUPPLY_PROP_ONLINE:
+		if (di->pdata->get_charger_online_status)
+			val->intval = (di->pdata->get_charger_online_status)();
+		else
+			return -EINVAL;
+		break;
+	default:
+		ret = -EINVAL;
+		break;
+	}
+	return ret;
+}
+
 static enum power_supply_property bq27000_battery_props[] = {
 	POWER_SUPPLY_PROP_STATUS,
+	POWER_SUPPLY_PROP_HEALTH,
 	POWER_SUPPLY_PROP_VOLTAGE_NOW,
 	POWER_SUPPLY_PROP_CURRENT_NOW,
 	POWER_SUPPLY_PROP_CHARGE_FULL,
@@ -313,6 +386,10 @@ static enum power_supply_property bq27000_battery_props[] = {
 	POWER_SUPPLY_PROP_ONLINE
 };
 
+static enum power_supply_property power_props[] = {
+	POWER_SUPPLY_PROP_ONLINE,
+};
+
 static int bq27000_battery_probe(struct platform_device *pdev)
 {
 	int retval = 0;
@@ -342,14 +419,49 @@ static int bq27000_battery_probe(struct platform_device *pdev)
 	di->bat.use_for_apm = 1;
 	di->pdata = pdata;
 
+	di->ac.name            = "ac";
+	di->ac.type            = POWER_SUPPLY_TYPE_MAINS;
+	di->ac.properties      = power_props;
+	di->ac.num_properties  = ARRAY_SIZE(power_props);
+	di->ac.get_property    = ac_get_property;
+
+	di->usb.name           = "usb";
+	di->usb.type           = POWER_SUPPLY_TYPE_USB;
+	di->usb.properties     = power_props;
+	di->usb.num_properties = ARRAY_SIZE(power_props);
+	di->usb.get_property   = usb_get_property;
+
 	retval = power_supply_register(&pdev->dev, &di->bat);
 	if (retval) {
 		dev_err(di->dev, "failed to register battery\n");
 		goto batt_failed;
 	}
 
+	retval = power_supply_register(&pdev->dev, &di->ac);
+	if (retval) {
+		dev_err(di->dev, "failed to register ac\n");
+		goto ac_failed;
+	}
+
+	retval = power_supply_register(&pdev->dev, &di->usb);
+	if (retval) {
+		dev_err(di->dev, "failed to register usb\n");
+		goto usb_failed;
+	}
+
+#ifdef DO_BQ2700_WORK
+	INIT_WORK(&di->work, bq27000_battery_work);
+
+	if (!schedule_work(&di->work))
+		dev_err(di->dev, "failed to schedule bq27000_battery_work\n");
+#endif
+
 	return 0;
 
+usb_failed:
+	power_supply_unregister(&di->ac);
+ac_failed:
+	power_supply_unregister(&di->bat);
 batt_failed:
 	kfree(di);
 di_alloc_failed:
@@ -361,6 +473,8 @@ static int bq27000_battery_remove(struct platform_device *pdev)
 	struct bq27000_device_info *di = platform_get_drvdata(pdev);
 
 	power_supply_unregister(&di->bat);
+	power_supply_unregister(&di->ac);
+	power_supply_unregister(&di->usb);
 
 	return 0;
 }
@@ -372,7 +486,8 @@ void bq27000_charging_state_change(struct platform_device *pdev)
 	if (!di)
 	    return;
 
-	power_supply_changed(&di->bat);
+	power_supply_changed(&di->ac);
+	power_supply_changed(&di->usb);
 }
 EXPORT_SYMBOL_GPL(bq27000_charging_state_change);
 
