mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-29 11:11:45 -04:00
Merge 4.7-rc6 into usb-next
We want the USB fixes in here as well. Signed-off-by: Greg Kroah-Hartman <[email protected]>
This commit is contained in:
commit
c318a821b9
504 changed files with 4321 additions and 2570 deletions
|
|
@ -565,11 +565,12 @@ static int power_supply_read_temp(struct thermal_zone_device *tzd,
|
|||
|
||||
WARN_ON(tzd == NULL);
|
||||
psy = tzd->devdata;
|
||||
ret = psy->desc->get_property(psy, POWER_SUPPLY_PROP_TEMP, &val);
|
||||
ret = power_supply_get_property(psy, POWER_SUPPLY_PROP_TEMP, &val);
|
||||
if (ret)
|
||||
return ret;
|
||||
|
||||
/* Convert tenths of degree Celsius to milli degree Celsius. */
|
||||
if (!ret)
|
||||
*temp = val.intval * 100;
|
||||
*temp = val.intval * 100;
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
|
@ -612,10 +613,12 @@ static int ps_get_max_charge_cntl_limit(struct thermal_cooling_device *tcd,
|
|||
int ret;
|
||||
|
||||
psy = tcd->devdata;
|
||||
ret = psy->desc->get_property(psy,
|
||||
POWER_SUPPLY_PROP_CHARGE_CONTROL_LIMIT_MAX, &val);
|
||||
if (!ret)
|
||||
*state = val.intval;
|
||||
ret = power_supply_get_property(psy,
|
||||
POWER_SUPPLY_PROP_CHARGE_CONTROL_LIMIT_MAX, &val);
|
||||
if (ret)
|
||||
return ret;
|
||||
|
||||
*state = val.intval;
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
|
@ -628,10 +631,12 @@ static int ps_get_cur_chrage_cntl_limit(struct thermal_cooling_device *tcd,
|
|||
int ret;
|
||||
|
||||
psy = tcd->devdata;
|
||||
ret = psy->desc->get_property(psy,
|
||||
POWER_SUPPLY_PROP_CHARGE_CONTROL_LIMIT, &val);
|
||||
if (!ret)
|
||||
*state = val.intval;
|
||||
ret = power_supply_get_property(psy,
|
||||
POWER_SUPPLY_PROP_CHARGE_CONTROL_LIMIT, &val);
|
||||
if (ret)
|
||||
return ret;
|
||||
|
||||
*state = val.intval;
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -197,6 +197,7 @@ static int tps65217_charger_probe(struct platform_device *pdev)
|
|||
{
|
||||
struct tps65217 *tps = dev_get_drvdata(pdev->dev.parent);
|
||||
struct tps65217_charger *charger;
|
||||
struct power_supply_config cfg = {};
|
||||
int ret;
|
||||
|
||||
dev_dbg(&pdev->dev, "%s\n", __func__);
|
||||
|
|
@ -208,9 +209,12 @@ static int tps65217_charger_probe(struct platform_device *pdev)
|
|||
charger->tps = tps;
|
||||
charger->dev = &pdev->dev;
|
||||
|
||||
cfg.of_node = pdev->dev.of_node;
|
||||
cfg.drv_data = charger;
|
||||
|
||||
charger->ac = devm_power_supply_register(&pdev->dev,
|
||||
&tps65217_charger_desc,
|
||||
NULL);
|
||||
&cfg);
|
||||
if (IS_ERR(charger->ac)) {
|
||||
dev_err(&pdev->dev, "failed: power supply register\n");
|
||||
return PTR_ERR(charger->ac);
|
||||
|
|
|
|||
Loading…
Reference in a new issue