lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  PHC 
Open Source and information security mailing list archives
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Date:	Sun, 14 Jul 2013 23:08:15 +0530
From:	Jenny TC <>
Cc:	Anton Vorontsov <>,
	Anton Vorontsov <>,
	Jenny TC <>
Subject: [PATCH 3/3] power_supply: add throttle state

The charger and battery temperature contribute to the
platform thermal. The only way to control the temperature
is to control the charging. The charging can be controlled in different
way. This could be disabling charger, disabling charging, adjusting CC,
or by adjusting the INLMT. This patch adds a structure to define the
charger throttle actions. Also this patch adds a throttle_states
field to the struct power_supply which can be used by the charger
driver to define it's throttle actions for different states

Signed-off-by: Jenny TC <>
 include/linux/power_supply.h |   15 +++++++++++++++
 1 file changed, 15 insertions(+)

diff --git a/include/linux/power_supply.h b/include/linux/power_supply.h
index 5a24e10..516e4c4 100644
--- a/include/linux/power_supply.h
+++ b/include/linux/power_supply.h
@@ -209,6 +209,18 @@ union power_supply_propval {
 struct device_node;
+enum psy_throttle_action {
+struct psy_throttle_state {
+	enum psy_throttle_action throttle_action;
+	unsigned throttle_val;
 struct power_supply {
 	const char *name;
 	enum power_supply_type type;
@@ -223,6 +235,9 @@ struct power_supply {
 	size_t num_supplies;
 	struct device_node *of_node;
+	struct psy_throttle_state *throttle_states;
+	size_t num_throttle_states;
 	int (*get_property)(struct power_supply *psy,
 			    enum power_supply_property psp,
 			    union power_supply_propval *val);

To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

Powered by blists - more mailing lists