Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 19c935b4 authored by Linux Build Service Account's avatar Linux Build Service Account Committed by Gerrit - the friendly Code Review server
Browse files

Merge "power: qpnp-fg: Add SOC_REPORTING_READY to indicate actual SOC reporting"

parents 8070c055 9aae0cd7
Loading
Loading
Loading
Loading
+1 −0
Original line number Original line Diff line number Diff line
@@ -246,6 +246,7 @@ static struct device_attribute power_supply_attrs[] = {
	POWER_SUPPLY_ATTR(current_capability),
	POWER_SUPPLY_ATTR(current_capability),
	POWER_SUPPLY_ATTR(typec_mode),
	POWER_SUPPLY_ATTR(typec_mode),
	POWER_SUPPLY_ATTR(allow_hvdcp3),
	POWER_SUPPLY_ATTR(allow_hvdcp3),
	POWER_SUPPLY_ATTR(soc_reporting_ready),
	/* Local extensions of type int64_t */
	/* Local extensions of type int64_t */
	POWER_SUPPLY_ATTR(charge_counter_ext),
	POWER_SUPPLY_ATTR(charge_counter_ext),
	/* Properties of type `const char *' */
	/* Properties of type `const char *' */
+4 −0
Original line number Original line Diff line number Diff line
@@ -3217,6 +3217,7 @@ static enum power_supply_property fg_power_props[] = {
	POWER_SUPPLY_PROP_CYCLE_COUNT,
	POWER_SUPPLY_PROP_CYCLE_COUNT,
	POWER_SUPPLY_PROP_CYCLE_COUNT_ID,
	POWER_SUPPLY_PROP_CYCLE_COUNT_ID,
	POWER_SUPPLY_PROP_HI_POWER,
	POWER_SUPPLY_PROP_HI_POWER,
	POWER_SUPPLY_PROP_SOC_REPORTING_READY,
};
};


static int fg_power_get_property(struct power_supply *psy,
static int fg_power_get_property(struct power_supply *psy,
@@ -3304,6 +3305,9 @@ static int fg_power_get_property(struct power_supply *psy,
	case POWER_SUPPLY_PROP_HI_POWER:
	case POWER_SUPPLY_PROP_HI_POWER:
		val->intval = !!chip->bcl_lpm_disabled;
		val->intval = !!chip->bcl_lpm_disabled;
		break;
		break;
	case POWER_SUPPLY_PROP_SOC_REPORTING_READY:
		val->intval = !!chip->profile_loaded;
		break;
	default:
	default:
		return -EINVAL;
		return -EINVAL;
	}
	}
+1 −0
Original line number Original line Diff line number Diff line
@@ -209,6 +209,7 @@ enum power_supply_property {
	POWER_SUPPLY_PROP_CURRENT_CAPABILITY,
	POWER_SUPPLY_PROP_CURRENT_CAPABILITY,
	POWER_SUPPLY_PROP_TYPEC_MODE,
	POWER_SUPPLY_PROP_TYPEC_MODE,
	POWER_SUPPLY_PROP_ALLOW_HVDCP3,
	POWER_SUPPLY_PROP_ALLOW_HVDCP3,
	POWER_SUPPLY_PROP_SOC_REPORTING_READY,
	/* Local extensions of type int64_t */
	/* Local extensions of type int64_t */
	POWER_SUPPLY_PROP_CHARGE_COUNTER_EXT,
	POWER_SUPPLY_PROP_CHARGE_COUNTER_EXT,
	/* Properties of type `const char *' */
	/* Properties of type `const char *' */