Home
last modified time | relevance | path

Searched +full:charger +full:- +full:type (Results 1 – 25 of 386) sorted by relevance

12345678910>>...16

/kernel/linux/linux-5.10/drivers/power/supply/
Dcros_usbpd-charger.c1 // SPDX-License-Identifier: GPL-2.0+
3 * Power supply driver for ChromeOS EC based USB PD Charger.
5 * Copyright (c) 2014 - 2018 Google, Inc
25 #define DRV_NAME "cros-usbpd-charger"
41 struct charger_data *charger; member
92 return port->port_number >= port->charger->num_usbpd_ports; in cros_usbpd_charger_port_is_dedicated()
95 static int cros_usbpd_charger_ec_command(struct charger_data *charger, in cros_usbpd_charger_ec_command() argument
103 struct cros_ec_dev *ec_dev = charger->ec_dev; in cros_usbpd_charger_ec_command()
109 return -ENOMEM; in cros_usbpd_charger_ec_command()
111 msg->version = version; in cros_usbpd_charger_ec_command()
[all …]
Dact8945a_charger.c1 // SPDX-License-Identifier: GPL-2.0-only
3 * Power supply driver for the Active-semi ACT8945A PMIC
19 static const char *act8945a_charger_manufacturer = "Active-semi";
22 * ACT8945A Charger Register Map
209 static int act8945a_get_capacity_level(struct act8945a_charger *charger, in act8945a_get_capacity_level() argument
214 int lbo_level = gpiod_get_value(charger->lbo_gpio); in act8945a_get_capacity_level()
268 * Riset(K) = 2336 * (1V/Ichg(mA)) - 0.205
276 static int act8945a_get_current_max(struct act8945a_charger *charger, in act8945a_get_current_max() argument
282 int chgin_level = gpiod_get_value(charger->chglev_gpio); in act8945a_get_current_max()
346 struct act8945a_charger *charger = power_supply_get_drvdata(psy); in act8945a_charger_get_property() local
[all …]
Dab8500_charger.c1 // SPDX-License-Identifier: GPL-2.0-only
3 * Copyright (C) ST-Ericsson SA 2012
5 * Charger driver for AB8500
31 #include <linux/mfd/abx500/ab8500-bm.h>
37 /* Charger constants */
92 /* Lowest charger voltage is 3.39V -> 0x4E */
105 /*External charger control*/
110 /* UsbLineStatus register - usb types */
172 * struct ab8500_charger_interrupts - ab8500 interupts
216 * struct ab8500_charger - ab8500 Charger device information
[all …]
Dtps65217_charger.c1 // SPDX-License-Identifier: GPL-2.0
2 // Battery charger driver for TI's tps65217
8 * Battery charger driver for TI's tps65217
45 static int tps65217_config_charger(struct tps65217_charger *charger) in tps65217_config_charger() argument
54 * is not recommended to do so. In sleep mode, the charger continues in tps65217_config_charger()
56 * values. Therefore, the charger would get the wrong temperature in tps65217_config_charger()
62 * NTC TYPE (for battery temperature measurement) in tps65217_config_charger()
67 ret = tps65217_clear_bits(charger->tps, TPS65217_REG_CHGCONFIG1, in tps65217_config_charger()
71 dev_err(charger->dev, in tps65217_config_charger()
79 static int tps65217_enable_charging(struct tps65217_charger *charger) in tps65217_enable_charging() argument
[all …]
Dgpio-charger.c1 // SPDX-License-Identifier: GPL-2.0-or-later
3 * Copyright (C) 2010, Lars-Peter Clausen <lars@metafoo.de>
18 #include <linux/power/gpio-charger.h>
31 struct power_supply *charger; member
44 struct power_supply *charger = devid; in gpio_charger_irq() local
46 power_supply_changed(charger); in gpio_charger_irq()
59 int ndescs = gpio_charger->current_limit_gpios->ndescs; in set_charge_current_limit()
60 struct gpio_desc **gpios = gpio_charger->current_limit_gpios->desc; in set_charge_current_limit()
63 if (!gpio_charger->current_limit_map_size) in set_charge_current_limit()
64 return -EINVAL; in set_charge_current_limit()
[all …]
/kernel/linux/linux-4.19/drivers/power/supply/
Dcros_usbpd-charger.c1 // SPDX-License-Identifier: GPL-2.0+
3 * Power supply driver for ChromeOS EC based USB PD Charger.
5 * Copyright (c) 2014 - 2018 Google, Inc
20 #define DRV_NAME "cros-usbpd-charger"
36 struct charger_data *charger; member
72 static int cros_usbpd_charger_ec_command(struct charger_data *charger, in cros_usbpd_charger_ec_command() argument
80 struct cros_ec_dev *ec_dev = charger->ec_dev; in cros_usbpd_charger_ec_command()
86 return -ENOMEM; in cros_usbpd_charger_ec_command()
88 msg->version = version; in cros_usbpd_charger_ec_command()
89 msg->command = ec_dev->cmd_offset + command; in cros_usbpd_charger_ec_command()
[all …]
Dact8945a_charger.c2 * Power supply driver for the Active-semi ACT8945A PMIC
23 static const char *act8945a_charger_manufacturer = "Active-semi";
26 * ACT8945A Charger Register Map
213 static int act8945a_get_capacity_level(struct act8945a_charger *charger, in act8945a_get_capacity_level() argument
218 int lbo_level = gpiod_get_value(charger->lbo_gpio); in act8945a_get_capacity_level()
272 * Riset(K) = 2336 * (1V/Ichg(mA)) - 0.205
280 static int act8945a_get_current_max(struct act8945a_charger *charger, in act8945a_get_current_max() argument
286 int chgin_level = gpiod_get_value(charger->chglev_gpio); in act8945a_get_current_max()
350 struct act8945a_charger *charger = power_supply_get_drvdata(psy); in act8945a_charger_get_property() local
351 struct regmap *regmap = charger->regmap; in act8945a_charger_get_property()
[all …]
Dab8500_charger.c2 * Copyright (C) ST-Ericsson SA 2012
4 * Charger driver for AB8500
31 #include <linux/mfd/abx500/ab8500-bm.h>
32 #include <linux/mfd/abx500/ab8500-gpadc.h>
37 /* Charger constants */
92 /* Lowest charger voltage is 3.39V -> 0x4E */
105 /*External charger control*/
110 /* UsbLineStatus register - usb types */
172 * struct ab8500_charger_interrupts - ab8500 interupts
216 * struct ab8500_charger - ab8500 Charger device information
[all …]
Dgpio-charger.c2 * Copyright (C) 2010, Lars-Peter Clausen <lars@metafoo.de>
28 #include <linux/power/gpio-charger.h>
34 struct power_supply *charger; member
41 struct power_supply *charger = devid; in gpio_charger_irq() local
43 power_supply_changed(charger); in gpio_charger_irq()
60 val->intval = gpiod_get_value_cansleep(gpio_charger->gpiod); in gpio_charger_get_property()
63 return -EINVAL; in gpio_charger_get_property()
73 if (!device_property_read_string(dev, "charger-type", &chargetype)) { in gpio_charger_get_type()
82 if (!strcmp("usb-sdp", chargetype)) in gpio_charger_get_type()
84 if (!strcmp("usb-dcp", chargetype)) in gpio_charger_get_type()
[all …]
Dtps65217_charger.c1 // SPDX-License-Identifier: GPL-2.0
2 // Battery charger driver for TI's tps65217
8 * Battery charger driver for TI's tps65217
45 static int tps65217_config_charger(struct tps65217_charger *charger) in tps65217_config_charger() argument
54 * is not recommended to do so. In sleep mode, the charger continues in tps65217_config_charger()
56 * values. Therefore, the charger would get the wrong temperature in tps65217_config_charger()
62 * NTC TYPE (for battery temperature measurement) in tps65217_config_charger()
67 ret = tps65217_clear_bits(charger->tps, TPS65217_REG_CHGCONFIG1, in tps65217_config_charger()
71 dev_err(charger->dev, in tps65217_config_charger()
79 static int tps65217_enable_charging(struct tps65217_charger *charger) in tps65217_enable_charging() argument
[all …]
Dcharger-manager.c5 * This driver enables to monitor battery health and control charger
6 * during suspend-to-mem.
7 * Charger manager depends on other devices. register this later than
25 #include <linux/power/charger-manager.h>
71 /* About in-suspend (suspend-again) monitoring */
85 * is_batt_present - See if the battery presents in place.
86 * @cm: the Charger Manager representing the battery.
95 switch (cm->desc->battery_present) { in is_batt_present()
102 psy = power_supply_get_by_name(cm->desc->psy_fuel_gauge); in is_batt_present()
113 for (i = 0; cm->desc->psy_charger_stat[i]; i++) { in is_batt_present()
[all …]
/kernel/linux/linux-4.19/drivers/usb/phy/
Dphy.c1 // SPDX-License-Identifier: GPL-2.0+
3 * phy.c -- USB phy handling
5 * Copyright (C) 2004-2013 Texas Instruments
17 /* Default current range by charger type. */
38 enum usb_phy_type type) in __usb_find_phy() argument
43 if (phy->type != type) in __usb_find_phy()
49 return ERR_PTR(-ENODEV); in __usb_find_phy()
57 return ERR_PTR(-ENODEV); in __of_usb_find_phy()
60 if (node != phy->dev->of_node) in __of_usb_find_phy()
66 return ERR_PTR(-EPROBE_DEFER); in __of_usb_find_phy()
[all …]
/kernel/linux/linux-5.10/drivers/usb/phy/
Dphy.c1 // SPDX-License-Identifier: GPL-2.0+
3 * phy.c -- USB phy handling
5 * Copyright (C) 2004-2013 Texas Instruments
17 /* Default current range by charger type. */
46 enum usb_phy_type type) in __usb_find_phy() argument
51 if (phy->type != type) in __usb_find_phy()
57 return ERR_PTR(-ENODEV); in __usb_find_phy()
65 return ERR_PTR(-ENODEV); in __of_usb_find_phy()
68 if (node != phy->dev->of_node) in __of_usb_find_phy()
74 return ERR_PTR(-EPROBE_DEFER); in __of_usb_find_phy()
[all …]
/kernel/linux/linux-4.19/Documentation/devicetree/bindings/power/supply/
Dgpio-charger.txt1 gpio-charger
4 - compatible : "gpio-charger"
5 - gpios : GPIO indicating the charger presence.
7 - charger-type : power supply type, one of
12 usb-sdp (USB standard downstream port)
13 usb-dcp (USB dedicated charging port)
14 usb-cdp (USB charging downstream port)
15 usb-aca (USB accessory charger adapter)
19 usb_charger: charger {
20 compatible = "gpio-charger";
[all …]
Dlp8727_charger.txt1 Binding for TI/National Semiconductor LP8727 Charger
4 - compatible: "ti,lp8727"
5 - reg: I2C slave address 27h
8 - interrupts: interrupt specifier (see interrupt binding[0])
9 - debounce-ms: interrupt debounce time. (u32)
12 - charger-type: "ac" or "usb" (string)
13 - eoc-level: value of 'enum lp8727_eoc_level' (u8)
14 - charging-current: value of 'enum lp8727_ichg' (u8)
16 [0]: Documentation/devicetree/bindings/interrupt-controller/interrupts.txt
25 interrupt-parent = <&gpio5>; /* base = 128 */
[all …]
Dqcom_smbb.txt1 Qualcomm Switch-Mode Battery Charger and Boost
4 - compatible:
6 Value type: <stringlist>
8 - "qcom,pm8941-charger"
10 - reg:
12 Value type: <prop-encoded-array>
15 - interrupts:
17 Value type: <prop-encoded-array>
21 - charge done
22 - charge fast mode
[all …]
Dqcom,coincell-charger.txt1 Qualcomm Coincell Charger:
7 - compatible:
9 Value type: <string>
10 Definition: must be: "qcom,pm8941-coincell"
12 - reg:
14 Value type: <u32>
15 Definition: base address of the coincell charger registers
17 - qcom,rset-ohms:
19 Value type: <u32>
20 Definition: resistance (in ohms) for current-limiting resistor
[all …]
/kernel/linux/linux-5.10/Documentation/power/
Dcharger-manager.rst2 Charger Manager
7 Charger Manager provides in-kernel battery charger management that
8 requires temperature monitoring during suspend-to-RAM state
12 Charger Manager is a platform_driver with power-supply-class entries.
13 An instance of Charger Manager (a platform-device created with Charger-Manager)
16 the system may need multiple instances of Charger Manager.
21 Charger Manager supports the following:
25 they may be activated at the same time. Each charger may have its
26 own power-supply-class and each power-supply-class can provide
28 aggregates charger-related information from multiple sources and
[all …]
/kernel/linux/linux-4.19/Documentation/power/
Dcharger-manager.txt1 Charger Manager
4 Charger Manager provides in-kernel battery charger management that
5 requires temperature monitoring during suspend-to-RAM state
9 Charger Manager is a platform_driver with power-supply-class entries.
10 An instance of Charger Manager (a platform-device created with Charger-Manager)
13 the system may need multiple instances of Charger Manager.
18 Charger Manager supports the following:
22 they may be activated at the same time. Each charger may have its
23 own power-supply-class and each power-supply-class can provide
25 aggregates charger-related information from multiple sources and
[all …]
/kernel/linux/linux-5.10/Documentation/devicetree/bindings/power/supply/
Dgpio-charger.yaml1 # SPDX-License-Identifier: GPL-2.0
3 ---
4 $id: http://devicetree.org/schemas/power/supply/gpio-charger.yaml#
5 $schema: http://devicetree.org/meta-schemas/core.yaml#
10 - Sebastian Reichel <sre@kernel.org>
19 const: gpio-charger
21 charger-type:
23 - unknown
24 - battery
25 - ups
[all …]
Dlp8727_charger.txt1 Binding for TI/National Semiconductor LP8727 Charger
4 - compatible: "ti,lp8727"
5 - reg: I2C slave address 27h
8 - interrupts: interrupt specifier (see interrupt binding[0])
9 - debounce-ms: interrupt debounce time. (u32)
12 - charger-type: "ac" or "usb" (string)
13 - eoc-level: value of 'enum lp8727_eoc_level' (u8)
14 - charging-current: value of 'enum lp8727_ichg' (u8)
16 [0]: Documentation/devicetree/bindings/interrupt-controller/interrupts.txt
25 interrupt-parent = <&gpio5>; /* base = 128 */
[all …]
Dqcom_smbb.txt1 Qualcomm Switch-Mode Battery Charger and Boost
4 - compatible:
6 Value type: <stringlist>
8 - "qcom,pm8941-charger"
10 - reg:
12 Value type: <prop-encoded-array>
15 - interrupts:
17 Value type: <prop-encoded-array>
21 - charge done
22 - charge fast mode
[all …]
Dqcom,coincell-charger.txt1 Qualcomm Coincell Charger:
7 - compatible:
9 Value type: <string>
10 Definition: must be: "qcom,pm8941-coincell"
12 - reg:
14 Value type: <u32>
15 Definition: base address of the coincell charger registers
17 - qcom,rset-ohms:
19 Value type: <u32>
20 Definition: resistance (in ohms) for current-limiting resistor
[all …]
/kernel/linux/linux-4.19/include/linux/power/
Dcharger-manager.h5 * Charger Manager.
7 * monitor charging even in the context of suspend-to-RAM with
51 * @name: the name of charger cable(external connector).
53 * @wq: the workqueue to control charger according to the state of
54 * charger cable. If charger cable is attached, enable charger.
55 * But if charger cable is detached, disable charger.
57 * (External Connector) when charger cable is attached/detached.
58 * @attached: the state of charger cable.
59 * true: the charger cable is attached
60 * false: the charger cable is detached
[all …]
/kernel/linux/linux-4.19/Documentation/devicetree/bindings/mfd/
Dab8500.txt1 * AB8500 Multi-Functional Device (MFD)
4 - compatible : contains "stericsson,ab8500";
5 - interrupts : contains the IRQ line for the AB8500
6 - interrupt-controller : describes the AB8500 as an Interrupt Controller (has its own domain)
7 - #interrupt-cells : should be 2, for 2-cell format
8 - The first cell is the AB8500 local IRQ number
9 - The second cell is used to specify optional parameters
10 - bits[3:0] trigger type and level flags:
11 1 = low-to-high edge triggered
12 2 = high-to-low edge triggered
[all …]

12345678910>>...16