ret = -ENOENT; \
} else { \
if (psy->desc->function##_property != NULL) { \
- ret = psy->desc->function##_property(psy, (property), &(value)); \
+ ret = psy->desc->function##_property(psy, \
+ (enum power_supply_property) (property), &(value)); \
if (ret < 0) { \
pr_err("%s: Fail to %s "#function" (%d=>%d)\n", \
__func__, name, (property), ret); \
{
struct max77865_charger_data *charger = power_supply_get_drvdata(psy);
u8 reg_data;
- enum power_supply_ext_property ext_psp = psp;
+ enum power_supply_ext_property ext_psp = (enum power_supply_ext_property)psp;
switch (psp) {
case POWER_SUPPLY_PROP_ONLINE:
u8 reg = 0;
static u8 chg_int_state;
int buck_state = ENABLE;
- enum power_supply_ext_property ext_psp = psp;
+ enum power_supply_ext_property ext_psp = (enum power_supply_ext_property)psp;
switch (psp) {
/* val->intval : type */
union power_supply_propval *val)
{
struct mfc_charger_data *charger = power_supply_get_drvdata(psy);
- enum power_supply_ext_property ext_psp = psp;
+ enum power_supply_ext_property ext_psp = (enum power_supply_ext_property) psp;
// union power_supply_propval value;
u8 mst_mode;
u8 reg_data;
int current_cable_type = SEC_BATTERY_CABLE_NONE;
int full_check_type = SEC_BATTERY_FULLCHARGED_NONE;
union power_supply_propval value = {0, };
- enum power_supply_ext_property ext_psp = psp;
+ enum power_supply_ext_property ext_psp = (enum power_supply_ext_property) psp;
dev_dbg(battery->dev,
"%s: (%d,%d)\n", __func__, psp, val->intval);
{
struct sec_battery_info *battery = power_supply_get_drvdata(psy);
union power_supply_propval value = {0, };
- enum power_supply_ext_property ext_psp = psp;
+ enum power_supply_ext_property ext_psp = (enum power_supply_ext_property) psp;
switch (psp) {
case POWER_SUPPLY_PROP_STATUS:
union power_supply_propval *val)
{
struct sec_battery_info *battery = power_supply_get_drvdata(psy);
- enum power_supply_ext_property ext_psp = psp;
+ enum power_supply_ext_property ext_psp = (enum power_supply_ext_property) psp;
switch (psp) {
case POWER_SUPPLY_PROP_ONLINE: