power: pm8921-charger: remove set_usb_power_supply_type
This custom API is no longer required since AC charging
reporting to userspace is solely dependent on the maximum
current supplied by the USB rather than the connector
type.
CRs-Fixed: 339841
Change-Id: Id542b083dd4f0ba5679d64f9e20d3b04cf14d972
Signed-off-by: David Keitel <dkeitel@codeaurora.org>
diff --git a/drivers/power/pm8921-charger.c b/drivers/power/pm8921-charger.c
index 9b8ea48..0d15890 100644
--- a/drivers/power/pm8921-charger.c
+++ b/drivers/power/pm8921-charger.c
@@ -1146,13 +1146,7 @@
return 0;
/* USB charging */
- if (psy->type == POWER_SUPPLY_TYPE_USB ||
- psy->type == POWER_SUPPLY_TYPE_USB_DCP ||
- psy->type == POWER_SUPPLY_TYPE_USB_CDP ||
- psy->type == POWER_SUPPLY_TYPE_USB_ACA) {
- val->intval = is_usb_chg_plugged_in(the_chip);
- return 0;
- }
+ val->intval = is_usb_chg_plugged_in(the_chip);
break;
default:
return -EINVAL;
@@ -1691,23 +1685,6 @@
}
EXPORT_SYMBOL(pm8921_is_battery_charging);
-int pm8921_set_usb_power_supply_type(enum power_supply_type type)
-{
- if (!the_chip) {
- pr_err("called before init\n");
- return -EINVAL;
- }
-
- if (type < POWER_SUPPLY_TYPE_USB)
- return -EINVAL;
-
- the_chip->usb_psy.type = type;
- power_supply_changed(&the_chip->usb_psy);
- power_supply_changed(&the_chip->dc_psy);
- return 0;
-}
-EXPORT_SYMBOL_GPL(pm8921_set_usb_power_supply_type);
-
int pm8921_batt_temperature(void)
{
if (!the_chip) {