/linux-6.12.1/Documentation/devicetree/bindings/power/supply/ |
D | summit,smb347-charger.yaml | 1 # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) 3 --- 4 $id: http://devicetree.org/schemas/power/supply/summit,smb347-charger.yaml# 5 $schema: http://devicetree.org/meta-schemas/core.yaml# 10 - David Heidelberg <david@ixit.cz> 11 - Dmitry Osipenko <digetx@gmail.com> 16 - summit,smb345 17 - summit,smb347 18 - summit,smb358 26 monitored-battery: [all …]
|
D | richtek,rt9467.yaml | 1 # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) 3 --- 5 $schema: http://devicetree.org/meta-schemas/core.yaml# 10 - ChiYuan Huang <cy_huang@richtek.com> 11 - ChiaEn Wu <chiaen_wu@richtek.com> 14 RT9467 is a switch-mode single cell Li-Ion/Li-Polymer battery charger for 16 MOSFETs, input current sensing and regulation, high-accuracy voltage 20 The RT9467 also features USB On-The-Go (OTG) support. It also integrates 21 D+/D- pin for USB host/charging port detection. 24 https://www.richtek.com/assets/product_file/RT9467/DS9467-01.pdf [all …]
|
D | qcom,pm8941-charger.yaml | 1 # SPDX-License-Identifier: GPL-2.0 3 --- 4 $id: http://devicetree.org/schemas/power/supply/qcom,pm8941-charger.yaml# 5 $schema: http://devicetree.org/meta-schemas/core.yaml# 7 title: Qualcomm Switch-Mode Battery Charger and Boost 10 - Sebastian Reichel <sre@kernel.org> 15 - qcom,pm8226-charger 16 - qcom,pm8941-charger 23 - description: charge done 24 - description: charge fast mode [all …]
|
D | richtek,rt9471.yaml | 1 # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) 3 --- 5 $schema: http://devicetree.org/meta-schemas/core.yaml# 10 - Alina Yu <alina_yu@richtek.com> 11 - ChiYuan Huang <cy_huang@richtek.com> 14 RT9471 is a switch-mode single cell Li-Ion/Li-Polymer battery charger for 16 voltage regulations in both charging and boost mode. 19 https://www.richtek.com/assets/product_file/RT9471=RT9471D/DS9471D-02.pdf 28 charge-enable-gpios: 29 description: GPIO used to turn on and off charging. [all …]
|
/linux-6.12.1/drivers/power/supply/ |
D | rt5033_charger.c | 1 // SPDX-License-Identifier: GPL-2.0-only 9 #include <linux/devm-helpers.h> 18 #include <linux/mfd/rt5033-private.h> 38 bool otg; member 45 struct regmap *regmap = charger->regmap; in rt5033_get_charger_state() 71 /* For OTG mode, RT5033 would still report "charging" */ in rt5033_get_charger_state() 72 if (charger->otg) in rt5033_get_charger_state() 80 struct regmap *regmap = charger->regmap; in rt5033_get_charger_type() 102 struct regmap *regmap = charger->regmap; in rt5033_get_charger_current_limit() 118 struct regmap *regmap = charger->regmap; in rt5033_get_charger_const_voltage() [all …]
|
D | axp288_charger.c | 1 // SPDX-License-Identifier: GPL-2.0-only 3 * axp288_charger.c - X-power AXP288 PMIC Charger driver 5 * Copyright (C) 2016-2017 Hans de Goede <hdegoede@redhat.com> 18 #include <linux/usb/otg.h> 126 /* OTG/Host mode */ 132 } otg; member 134 /* SDP/CDP/DCP USB charging cable notifications */ 160 else if (cc > info->max_cc) in axp288_charger_set_cc() 161 cc = info->max_cc; in axp288_charger_set_cc() 163 reg_val = (cc - CHRG_CCCV_CC_OFFSET) / CHRG_CCCV_CC_LSB_RES; in axp288_charger_set_cc() [all …]
|
D | smb347-charger.c | 1 // SPDX-License-Identifier: GPL-2.0-only 23 #include <dt-bindings/power/summit,smb347-charger.h> 26 #define SMB3XX_SOFT_TEMP_COMPENSATE_DEFAULT -1 29 #define SMB3XX_TEMP_USE_DEFAULT -273 34 * reloaded from non-volatile registers after POR. 136 * struct smb347_charger - smb347 charger instance 149 * @pre_charge_current: current (in uA) to use in pre-charging phase 151 * charging cycle terminates 153 * pre-charge to fast charge mode 158 * current [%100 - %130] (in degree C) [all …]
|
D | isp1704_charger.c | 1 // SPDX-License-Identifier: GPL-2.0-or-later 6 * Copyright (C) 2012 - 2013 Pali Rohár <pali@kernel.org> 22 #include <linux/usb/otg.h> 63 return usb_phy_io_read(isp->phy, reg); in isp1704_read() 68 return usb_phy_io_write(isp->phy, val, reg); in isp1704_write() 73 gpiod_set_value(isp->enable_gpio, on); in isp1704_charger_set_power() 77 * Determine is the charging port DCP (dedicated charger) or CDP (Host/HUB 80 * REVISIT: The method is defined in Battery Charging Specification and is 103 /* Enable strong pull-up on DP (1.5K) and reset */ in isp1704_charger_type() 138 /* Clear the DP and DM pull-down bits */ in isp1704_charger_verify() [all …]
|
D | Kconfig | 1 # SPDX-License-Identifier: GPL-2.0-only 5 Say Y here to enable power supply class support. This allows 15 Say Y here to enable debugging messages for power supply class 35 Say Y here to enable support APM status emulation using 42 Say Y here to enable support for the generic battery driver 57 Say Y here to enable support for the battery charger in the Maxim 64 Say Y here to enable support for the backup battery charger 71 Say Y here to enable support for the power management unit 78 Say Y here to enable support for the power management unit 90 Say Y here to enable battery monitor for Marvell 88PM860x chip. [all …]
|
D | qcom_smbb.c | 1 // SPDX-License-Identifier: GPL-2.0-only 4 * This driver is for the multi-block Switch-Mode Battery Charger and Boost 6 * integrated, single-cell lithium-ion battery charger. 8 * Sub-components: 9 * - Charger core 10 * - Buck 11 * - DC charge-path 12 * - USB charge-path 13 * - Battery interface 14 * - Boost (not implemented) [all …]
|
D | twl4030_charger.c | 1 // SPDX-License-Identifier: GPL-2.0-or-later 21 #include <linux/usb/otg.h> 73 #define TWL4030_ICHGEOC BIT(4) /* Battery current end-of-charge */ 132 int usb_mode, ac_mode; /* charging mode requested */ 207 * CGAIN == 0: ICHG = (BCIICHG * 1.7) / (2^10 - 1) - 0.85 208 * CGAIN == 1: ICHG = (BCIICHG * 3.4) / (2^10 - 1) - 1.7 210 * CGAIN == 0: val * 1.6618 - 0.85 * 1000 211 * CGAIN == 1: (val * 1.6618 - 0.85 * 1000) * 2 219 return (regval * 16618 - 8500 * 1000) / 5; in regval2ua() 221 return (regval * 16618 - 8500 * 1000) / 10; in regval2ua() [all …]
|
D | ab8500_charger.c | 1 // SPDX-License-Identifier: GPL-2.0-only 3 * Copyright (C) ST-Ericsson SA 2012 32 #include <linux/usb/otg.h> 36 #include "ab8500-bm.h" 37 #include "ab8500-chargalg.h" 94 /* Lowest charger voltage is 3.39V -> 0x4E */ 112 /* UsbLineStatus register - usb types */ 174 * struct ab8500_charger_interrupts - ab8500 interrupts 218 * struct ab8500_charger - ab8500 Charger device information 359 dev_dbg(di->dev, "SW Fallback: %d\n", fallback); in ab8500_enable_disable_sw_fallback() [all …]
|
D | bq25890_charger.c | 1 // SPDX-License-Identifier: GPL-2.0-or-later 90 u8 ilim_en; /* enable ILIM pin */ 113 char name[28]; /* "bq25890-charger-%d" */ 272 * Most of the val -> idx conversions can be computed, given the minimum, 322 0, -10, -20, -30, -40, -60, -70, -80, 323 -90, -10, -120, -140, -150, -170, -190, -210, 367 ret = regmap_field_read(bq->rmap_fields[field_id], &val); in bq25890_field_read() 377 return regmap_field_write(bq->rmap_fields[field_id], val); in bq25890_field_write() 394 rtbl_size = (rtbl->max - rtbl->min) / rtbl->step + 1; in bq25890_find_idx() 397 idx < rtbl_size && (idx * rtbl->step + rtbl->min <= value); in bq25890_find_idx() [all …]
|
D | mt6360_charger.c | 1 // SPDX-License-Identifier: GPL-2.0 6 #include <linux/devm-helpers.h> 163 ret = regmap_read(mci->regmap, MT6360_PMU_FOD_STAT, ®val); in mt6360_get_chrdet_ext_stat() 179 val->intval = pwr_rdy ? true : false; in mt6360_charger_get_online() 198 ret = regmap_read(mci->regmap, MT6360_PMU_CHG_STAT, ®val); in mt6360_charger_get_status() 214 ret = -EIO; in mt6360_charger_get_status() 218 val->intval = status; in mt6360_charger_get_status() 229 ret = regmap_read(mci->regmap, MT6360_PMU_CHG_STAT, ®val); in mt6360_charger_get_charge_type() 241 case 0x00: /* Not Charging */ in mt6360_charger_get_charge_type() 249 val->intval = type; in mt6360_charger_get_charge_type() [all …]
|
D | rt9455_charger.c | 1 // SPDX-License-Identifier: GPL-2.0-or-later 21 #define RT9455_DRIVER_NAME "rt9455-charger" 165 #define GET_MASK(fid) (BIT(rt9455_reg_fields[fid].msb + 1) - \ 169 * Each array initialised below shows the possible real-world values for a 171 * ascending order. The index of each real-world value represents the value 265 for (i = 0; i < tbl_size - 1; i++) in rt9455_find_idx() 269 return (tbl_size - 1); in rt9455_find_idx() 279 ret = regmap_field_read(info->regmap_fields[field], &v); in rt9455_get_field_val() 283 v = (v >= tbl_size) ? (tbl_size - 1) : v; in rt9455_get_field_val() 295 return regmap_field_write(info->regmap_fields[field], idx); in rt9455_set_field_val() [all …]
|
/linux-6.12.1/drivers/usb/phy/ |
D | phy-fsl-usb.c | 1 // SPDX-License-Identifier: GPL-2.0+ 6 * Jerry Huang <Chang-Ming.Huang@freescale.com> 32 #include "phy-fsl-usb.h" 43 #define DRIVER_DESC "Freescale USB OTG Transceiver Driver" 46 static const char driver_name[] = "fsl-usb2-otg"; 109 fsl_writel(temp, &usb_dr_regs->ulpiview); in write_ulpi() 113 /* -------------------------------------------------------------*/ 114 /* Operations that will be called from OTG Finite State Machine */ 121 tmp = fsl_readl(&usb_dr_regs->otgsc) & ~OTGSC_INTSTS_MASK; in fsl_otg_chrg_vbus() 124 /* stop discharging, start charging */ in fsl_otg_chrg_vbus() [all …]
|
D | phy-gpio-vbus-usb.c | 1 // SPDX-License-Identifier: GPL-2.0 3 * gpio-vbus.c - simple GPIO VBUS sensing driver for B peripheral devices 20 #include <linux/usb/otg.h> 47 * some bouncing due to current surges (e.g. charging local capacitance) 60 struct regulator *vbus_draw = gpio_vbus->vbus_draw; in set_vbus_draw() 67 enabled = gpio_vbus->vbus_draw_enabled; in set_vbus_draw() 74 gpio_vbus->vbus_draw_enabled = 1; in set_vbus_draw() 81 gpio_vbus->vbus_draw_enabled = 0; in set_vbus_draw() 84 gpio_vbus->mA = mA; in set_vbus_draw() 89 return gpiod_get_value(gpio_vbus->vbus_gpiod); in is_vbus_powered() [all …]
|
/linux-6.12.1/arch/arm/boot/dts/rockchip/ |
D | rk3188-bqedison2qc.dts | 1 // SPDX-License-Identifier: (GPL-2.0+ OR MIT) 7 /dts-v1/; 8 #include <dt-bindings/i2c/i2c.h> 9 #include <dt-bindings/input/input.h> 10 #include <dt-bindings/interrupt-controller/irq.h> 14 model = "BQ Edison2 Quad-Core"; 15 compatible = "mundoreader,bq-edison2qc", "rockchip,rk3188"; 29 compatible = "pwm-backlight"; 30 power-supply = <&vsys>; 34 gpio-keys { [all …]
|
/linux-6.12.1/drivers/mfd/ |
D | tps65010.c | 1 // SPDX-License-Identifier: GPL-2.0-or-later 3 * tps65010 - driver for tps6501x power management chips 6 * Copyright (C) 2004-2005 David Brownell 27 /*-------------------------------------------------------------------------*/ 37 /*-------------------------------------------------------------------------*/ 40 * voltage regulators, lithium ion/polymer battery charging, GPIOs, LEDs, 47 * battery-insert != device-on. 65 unsigned charging:1; member 84 /*-------------------------------------------------------------------------*/ 97 ? " (charging)" : ""), in dbg_chgstat() [all …]
|
/linux-6.12.1/drivers/phy/ti/ |
D | phy-twl4030-usb.c | 1 // SPDX-License-Identifier: GPL-2.0-or-later 3 * twl4030_usb - TWL4030 USB transceiver, talking to OMAP OTG controller 5 * Copyright (C) 2004-2007 Texas Instruments 10 * - HS USB ULPI mode works. 11 * - 3-pin mode support may be added in future. 22 #include <linux/usb/otg.h> 138 * cable is present and we need to be runtime-enabled 175 /*-------------------------------------------------------------------------*/ 186 dev_dbg(twl->dev, "Write%d[%d,0x%x] wrote %02x but read %02x\n", in twl4030_i2c_write_u8_verify() 194 dev_dbg(twl->dev, "Write%d[%d,0x%x] wrote %02x but read %02x\n", in twl4030_i2c_write_u8_verify() [all …]
|
/linux-6.12.1/drivers/usb/musb/ |
D | tusb6010.c | 1 // SPDX-License-Identifier: GPL-2.0 3 * TUSB6010 USB 2.0 OTG Dual Role controller 9 * - Driver assumes that interface to external host (main CPU) is 27 #include <linux/dma-mapping.h> 36 struct gpio_desc *enable; member 51 void __iomem *tbase = musb->ctrl_base; in tusb_get_revision() 68 void __iomem *tbase = musb->ctrl_base; in tusb_print_revision() 71 rev = musb->tusb_revision; in tusb_print_revision() 96 * Workaround for spontaneous WBUS wake-up issue #2 for tusb3.0. 101 void __iomem *tbase = musb->ctrl_base; in tusb_wbus_quirk() [all …]
|
/linux-6.12.1/drivers/extcon/ |
D | extcon-lc824206xa.c | 1 // SPDX-License-Identifier: GPL-2.0-or-later 8 * (ENA2222-D.PDF), but no full datasheet. So there is no documentation 11 * This driver is based on the register info from the extcon-fsa9285.c driver, 22 #include <linux/extcon-provider.h> 57 /* 5 bits? ADC 0x10 GND, 0x1a-0x1f ACA, 0x1f float */ 82 * auto-reset to 0, so these must be set to 0 manually after clearing. 139 ret = i2c_smbus_read_byte_data(data->client, reg); in lc824206xa_read_reg() 141 dev_err(&data->client->dev, "Error %d reading reg 0x%02x\n", ret, reg); in lc824206xa_read_reg() 150 ret = i2c_smbus_write_byte_data(data->client, reg, val); in lc824206xa_write_reg() 152 dev_err(&data->client->dev, "Error %d writing reg 0x%02x\n", ret, reg); in lc824206xa_write_reg() [all …]
|
/linux-6.12.1/drivers/phy/rockchip/ |
D | phy-rockchip-inno-usb2.c | 1 // SPDX-License-Identifier: GPL-2.0-or-later 9 #include <linux/clk-provider.h> 11 #include <linux/extcon-provider.h> 28 #include <linux/usb/otg.h> 50 * enum usb_chg_state - Different states involved in USB charger detection. 85 unsigned int enable; member 89 * struct rockchip_chg_det_reg - usb charger detect registers 90 * @cp_det: charging port detected successfully. 91 * @dcp_det: dedicated charging port detected successfully. 115 * struct rockchip_usb2phy_port_cfg - usb-phy port configuration. [all …]
|
/linux-6.12.1/drivers/platform/x86/x86-android-tablets/ |
D | lenovo.c | 1 // SPDX-License-Identifier: GPL-2.0-or-later 8 * Copyright (C) 2021-2023 Hans de Goede <hdegoede@redhat.com> 27 #include "shared-psy-info.h" 28 #include "x86-android-tablets.h" 33 * The Android kernels have a hack in the i915 driver to write a non-standard 34 * panel specific DSI register to set the duty-cycle of the LCD's PWM output. 46 * But on some models the panel's PWM output defaults to a duty-cycle of 65 PROPERTY_ENTRY_U32("hid-descr-addr", 0x0001), 66 PROPERTY_ENTRY_U32("post-reset-deassert-delay-ms", 150), 75 * The HiDeep IST940E touchscreen comes up in I2C-HID mode. The native protocol [all …]
|
/linux-6.12.1/arch/arm/boot/dts/ti/omap/ |
D | omap4-epson-embt2ws.dts | 1 // SPDX-License-Identifier: GPL-2.0-only 5 /dts-v1/; 7 #include <dt-bindings/leds/common.h> 8 #include <dt-bindings/input/input.h> 12 model = "Epson Moverio BT-200"; 20 backlight-left { 21 compatible = "pwm-backlight"; 23 power-supply = <&unknown_supply>; 26 backlight-right { 27 compatible = "pwm-backlight"; [all …]
|