/linux/Documentation/devicetree/bindings/power/supply/ |
H A D | gpio-charger.yaml | 1 # 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 …]
|
H A D | charger-manager.yaml | 1 # SPDX-License-Identifier: GPL-2.0 3 --- 4 $id: http://devicetree.org/schemas/power/supply/charger-manager.yaml# 5 $schema: http://devicetree.org/meta-schemas/core.yaml# 10 - Sebastian Reichel <sre@kernel.org> 18 const: charger-manager 20 cm-chargers: 22 $ref: /schemas/types.yaml#/definitions/string-array 24 cm-num-chargers: 28 cm-fuel-gauge: [all …]
|
/linux/drivers/extcon/ |
H A D | extcon-intel-cht-wc.c | 1 // SPDX-License-Identifier: GPL-2.0 7 * Copyright (C) 2013-2015 Intel Corporation. All rights reserved. 10 #include <linux/extcon-provider.h> 22 #include <linux/usb/role.h> 24 #include "extcon-intel.h" 67 /* 0 - open drain, 1 - regular push-pull output */ 69 /* 0 - pin is controlled by SW, 1 - by HW */ 125 * According to the spec. we should read the USB-ID pin ADC value here in cht_wc_extcon_get_id() 126 * to determine the resistance of the used pull-down resister and then in cht_wc_extcon_get_id() 129 * a combination of a charging port with one or more USB-A ports, so in cht_wc_extcon_get_id() [all …]
|
H A D | extcon-axp288.c | 1 // SPDX-License-Identifier: GPL-2.0-only 3 * extcon-axp288.c - X-Power AXP288 PMIC extcon cable detection driver 5 * Copyright (c) 2017-2018 Hans de Goede <hdegoede@redhat.com> 19 #include <linux/extcon-provider.h> 22 #include <linux/usb/role.h> 26 #include <asm/intel-family.h> 53 /* BC USB status register */ 137 ret = regmap_read(info->regmap, AXP288_PS_BOOT_REASON_REG, &val); in axp288_extcon_log_rsi() 139 dev_err(info->dev, "failed to read reset source indicator\n"); in axp288_extcon_log_rsi() 143 bits = val & GENMASK(ARRAY_SIZE(axp288_pwr_up_down_info) - 1, 0); in axp288_extcon_log_rsi() [all …]
|
H A D | extcon-lc824206xa.c | 1 // SPDX-License-Identifier: GPL-2.0-or-later 3 * ON Semiconductor LC824206XA Micro USB Switch driver 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() [all …]
|
H A D | extcon.c | 1 // SPDX-License-Identifier: GPL-2.0-only 3 * drivers/extcon/extcon.c - External Connector (extcon) framework. 44 /* USB external connector */ 48 .name = "USB", 53 .name = "USB-HOST", 60 .name = "SDP", 80 .name = "FAST-CHARGER", 85 .name = "SLOW-CHARGER", 112 .name = "LINE-IN", 117 .name = "LINE-OUT", [all …]
|
/linux/drivers/scsi/ |
H A D | sd.c | 1 // SPDX-License-Identifier: GPL-2.0-only 10 * - Drew Eckhardt <drew@colorado.edu> original 11 * - Eric Youngdale <eric@andante.org> add scatter-gather, multiple 13 * Support loadable low-level scsi drivers. 14 * - Jirka Hanika <geo@ff.cuni.cz> support more scsi disks using 16 * - Richard Gooch <rgooch@atnf.csiro.au> support devfs. 17 * - Torben Mathiasen <tmm@image.dk> Resource allocation fixes in 19 * - Alex Davis <letmein@erols.com> Fix problem where partition info 22 * - Douglas Gilbert <dgilbert@interlog.com> cleanup for lk 2.5.x 23 * - Badari Pulavarty <pbadari@us.ibm.com>, Matthew Wilcox [all …]
|
/linux/Documentation/scsi/ |
H A D | scsi_mid_low_api.rst | 1 .. SPDX-License-Identifier: GPL-2.0 4 SCSI mid_level - lower_level driver interface 14 (SCSI terminology, see SAM-3 at http://www.t10.org) sends SCSI commands 20 its own subsystem in Linux (e.g. USB and ieee1394). In such cases the 22 Examples are the usb-storage driver (found in the drivers/usb/storage 30 HBAs. These HBAs might be either on PCI daughter-boards or built into 33 has its own PCI device address. [The one-to-one correspondence between 49 documented in Documentation/scsi (e.g. aic7xxx.rst). The SCSI mid-level is 53 scsi-generic.rst (for the sg driver). 57 about the USB mass storage driver see the [all …]
|
/linux/Documentation/ABI/testing/ |
H A D | sysfs-class-power | 5 Contact: linux-pm@vger.kernel.org 14 Contact: linux-pm@vger.kernel.org 23 Contact: linux-pm@vger.kernel.org 32 Contact: linux-pm@vger.kernel.org 37 Valid values: "Battery", "UPS", "Mains", "USB", "Wireless" 39 **Battery and USB properties** 43 Contact: linux-pm@vger.kernel.org 52 USB: 62 batteries and for USB IBUS current. 66 Contact: linux-pm@vger.kernel.org [all …]
|
/linux/include/linux/ |
H A D | extcon.h | 1 /* SPDX-License-Identifier: GPL-2.0-only */ 4 * - linux/include/linux/extcon.h for extcon consumer device driver. 26 #define EXTCON_TYPE_USB BIT(0) /* USB connector */ 37 /* USB external connector */ 44 * When one SDP charger connector was reported, we should also report 45 * the USB connector, which means EXTCON_CHG_USB_SDP should always 60 #define EXTCON_CHG_USB_PD 12 /* USB Power Delivery */ 73 #define EXTCON_DISP_HDMI 40 /* High-Definition Multimedia Interface */ 74 #define EXTCON_DISP_MHL 41 /* Mobile High-Definition Link */ 78 #define EXTCON_DISP_HMD 45 /* Head-Mounted Display */ [all …]
|
/linux/Documentation/userspace-api/ioctl/ |
H A D | ioctl-number.rst | 33 patch to Linus Torvalds. Or you can e-mail me at <mec@shout.net> and 67 no attempt to list non-X86 architectures or ioctls from drivers/staging/. 73 0x00 00-1F linux/fs.h conflict! 74 0x00 00-1F scsi/scsi_ioctl.h conflict! 75 0x00 00-1F linux/fb.h conflict! 76 0x00 00-1F linux/wavefront.h conflict! 79 0x04 D2-DC linux/umsdos_fs.h Dead since 2.6.11, but don't r… 81 0x07 9F-D0 linux/vmw_vmci_defs.h, uapi/linux/vm_sockets.h 83 0x10 00-0F drivers/char/s390/vmcp.h 84 0x10 10-1F arch/s390/include/uapi/sclp_ctl.h [all …]
|
/linux/drivers/power/supply/ |
H A D | max8997_charger.c | 1 // SPDX-License-Identifier: GPL-2.0+ 3 // max8997_charger.c - Power supply consumer driver for the Maxim 8997/8966 15 #include <linux/mfd/max8997-private.h> 17 #include <linux/devm-helpers.h> 55 struct i2c_client *i2c = charger->iodev->i2c; in max8997_battery_get_property() 61 val->intval = 0; in max8997_battery_get_property() 66 val->intval = POWER_SUPPLY_STATUS_FULL; in max8997_battery_get_property() 68 val->intval = POWER_SUPPLY_STATUS_CHARGING; in max8997_battery_get_property() 70 val->intval = POWER_SUPPLY_STATUS_DISCHARGING; in max8997_battery_get_property() 74 val->intval = 0; in max8997_battery_get_property() [all …]
|
H A D | gpio-charger.c | 1 // 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> 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() 66 for (i = 0; i < gpio_charger->current_limit_map_size; i++) { in set_charge_current_limit() 67 if (gpio_charger->current_limit_map[i].limit_ua <= val) in set_charge_current_limit() 75 if (i >= gpio_charger->current_limit_map_size) in set_charge_current_limit() [all …]
|
H A 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> 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() 167 ret = regmap_update_bits(info->regmap, in axp288_charger_set_cc() 171 info->cc = cc; in axp288_charger_set_cc() [all …]
|
H A 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> 45 struct regmap *regmap = charger->regmap; 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() 134 struct rt5033_charger_data *chg = &charger->chg; in rt5033_init_const_charge() 140 if (chg->const_uvolt < RT5033_CHARGER_CONST_VOLTAGE_LIMIT_MIN || in rt5033_init_const_charge() [all …]
|
H A D | bd99954-charger.c | 1 // SPDX-License-Identifier: GPL-2.0-only 20 * a) Trickle-charge with constant current (8). 21 * b) pre-charge with constant current (6) 22 * c) fast-charge, first with constant current (5) phase. After 30 *(4)` `.` ` ` ` ` ` ` ` ` ` ` ` ` ` ----------------------------. 32 * . o----+/:/ ` ` ` ` ` ` ` ` ` ` ` ` `.` ` (5) 34 * . + /- -- . 35 * . +`/- + . 36 * . o/- -: . 38 * . .--+ `/ . [all …]
|
H A D | power_supply_sysfs.c | 1 // SPDX-License-Identifier: GPL-2.0-only 52 [POWER_SUPPLY_TYPE_USB] = "USB", 65 [POWER_SUPPLY_USB_TYPE_SDP] = "SDP", 117 [POWER_SUPPLY_TECHNOLOGY_LION] = "Li-ion", 118 [POWER_SUPPLY_TECHNOLOGY_LIPO] = "Li-poly", 141 [POWER_SUPPLY_CHARGE_BEHAVIOUR_INHIBIT_CHARGE] = "inhibit-charge", 142 [POWER_SUPPLY_CHARGE_BEHAVIOUR_FORCE_DISCHARGE] = "force-discharge", 237 return to_ps_attr(attr) - power_supply_attrs; in dev_attr_psp() 262 return -EINVAL; in power_supply_show_enum_with_available() 266 buf[count - 1] = '\n'; in power_supply_show_enum_with_available() [all …]
|
H A D | qcom_pmi8998_charger.c | 1 // SPDX-License-Identifier: GPL-2.0-only 3 * Copyright (c) 2016-2019 The Linux Foundation. All rights reserved. 7 * This driver is for the switch-mode battery charger and boost 12 #include <linux/devm-helpers.h> 26 /* clang-format off */ 352 /* clang-format on */ 372 * struct smb2_chip - smb2 chip structure 379 * @cable_irq: USB plugin IRQ 419 rc = regmap_read(chip->regmap, chip->base + POWER_PATH_STATUS, &stat); in smb2_get_prop_usb_online() 421 dev_err(chip->dev, "Couldn't read power path status: %d\n", rc); in smb2_get_prop_usb_online() [all …]
|
/linux/drivers/usb/typec/tipd/ |
H A D | trace.h | 1 /* SPDX-License-Identifier: GPL-2.0+ */ 3 * Driver for TI TPS6598x USB Power Delivery controller family 104 { TPS_STATUS_CONN_STATE_CONN_WITH_R_A, "conn-Ra" }, \ 105 { TPS_STATUS_CONN_STATE_CONN_NO_R_A, "conn-no-Ra" }, \ 106 { TPS_STATUS_CONN_STATE_NO_CONN_R_A, "no-conn-Ra" }, \ 110 { TPS_STATUS_CONN_STATE_NO_CONN, "no-conn" }) 122 { TPS_STATUS_POWER_SOURCE_VIN_3P3, "vin-3p3" }, \ 123 { TPS_STATUS_POWER_SOURCE_DEAD_BAT, "dead-battery" }, \ 135 { TPS_STATUS_USB_HOST_PRESENT_PD_USB, "pd-usb" }, \ 136 { TPS_STATUS_USB_HOST_PRESENT_NO_PD, "no-pd" }, \ [all …]
|
/linux/arch/mips/boot/dts/ingenic/ |
H A D | qi_lb60.dts | 1 // SPDX-License-Identifier: GPL-2.0 2 /dts-v1/; 6 #include <dt-bindings/gpio/gpio.h> 7 #include <dt-bindings/iio/adc/ingenic,adc.h> 8 #include <dt-bindings/clock/ingenic,tcu.h> 9 #include <dt-bindings/input/input.h> 27 stdout-path = &uart0; 30 vcc: regulator-0 { 31 compatible = "regulator-fixed"; 32 regulator-name = "vcc"; [all …]
|
/linux/arch/arm/boot/dts/nxp/imx/ |
H A D | imx6ull-uti260b.dts | 1 // SPDX-License-Identifier: (GPL-2.0 OR MIT) 2 // Copyright (C) 2022-2024 Sebastian Reichel <sre@kernel.org> 4 /dts-v1/; 6 #include <dt-bindings/gpio/gpio.h> 7 #include <dt-bindings/input/input.h> 8 #include <dt-bindings/clock/imx6ul-clock.h> 9 #include <dt-bindings/leds/common.h> 12 model = "UNI-T UTi260B Thermal Camera"; 13 compatible = "uni-t,uti260b", "fsl,imx6ull"; 16 stdout-path = "serial0:115200n8"; [all …]
|
/linux/drivers/phy/ti/ |
H A D | phy-tusb1210.c | 1 // SPDX-License-Identifier: GPL-2.0-only 3 * tusb1210.c - TUSB1210 USB ULPI PHY driver 77 struct device *dev = tusb->dev; in tusb1210_ulpi_write() 89 struct device *dev = tusb->dev; in tusb1210_ulpi_read() 107 gpiod_set_value_cansleep(tusb->gpio_reset, 1); in tusb1210_power_on() 108 gpiod_set_value_cansleep(tusb->gpio_cs, 1); in tusb1210_power_on() 113 tusb1210_ulpi_write(tusb, TUSB1210_VENDOR_SPECIFIC2, tusb->vendor_specific2); in tusb1210_power_on() 122 gpiod_set_value_cansleep(tusb->gpio_reset, 0); in tusb1210_power_off() 123 gpiod_set_value_cansleep(tusb->gpio_cs, 0); in tusb1210_power_off() 159 tusb->otg_ctrl = reg; in tusb1210_set_mode() [all …]
|
/linux/arch/arm/boot/dts/ti/omap/ |
H A D | omap4-sdp.dts | 1 // SPDX-License-Identifier: GPL-2.0-only 3 * Copyright (C) 2011 Texas Instruments Incorporated - https://www.ti.com/ 5 /dts-v1/; 9 #include "omap4-mcpdm.dtsi" 12 model = "TI OMAP4 SDP board"; 13 compatible = "ti,omap4-sdp", "ti,omap4430", "ti,omap4"; 26 vdd_eth: fixedregulator-vdd-eth { 27 pinctrl-names = "default"; 28 pinctrl-0 = <&enet_enable_gpio>; 30 compatible = "regulator-fixed"; [all …]
|
/linux/drivers/mfd/ |
H A D | twl4030-power.c | 9 * Peter De Schrijver <peter.de-schrijver@nokia.com> 23 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 33 #include <asm/mach-types.h> 51 #define STARTON_USB BIT(2) /* Start on USB host */ 57 #define PHY_TO_OFF_PM_MASTER(p) (p - 0x36) 58 #define PHY_TO_OFF_PM_RECEIVER(p) (p - 0x5b) 60 /* resource - hfclk */ 222 int err = -EINVAL; in twl4030_write_script() 224 for (; len; len--, address++, script++) { in twl4030_write_script() 227 script->pmb_message, in twl4030_write_script() [all …]
|
/linux/drivers/gpu/drm/amd/pm/swsmu/inc/pmfw_if/ |
H A D | smu11_driver_if_sienna_cichlid.h | 53 #define MAX_GFXCLK_DPM_LEVEL (NUM_GFXCLK_DPM_LEVELS - 1) 54 #define MAX_SMNCLK_DPM_LEVEL (NUM_SMNCLK_DPM_LEVELS - 1) 55 #define MAX_SOCCLK_DPM_LEVEL (NUM_SOCCLK_DPM_LEVELS - 1) 56 #define MAX_MP0CLK_DPM_LEVEL (NUM_MP0CLK_DPM_LEVELS - 1) 57 #define MAX_DCLK_DPM_LEVEL (NUM_DCLK_DPM_LEVELS - 1) 58 #define MAX_VCLK_DPM_LEVEL (NUM_VCLK_DPM_LEVELS - 1) 59 #define MAX_DCEFCLK_DPM_LEVEL (NUM_DCEFCLK_DPM_LEVELS - 1) 60 #define MAX_DISPCLK_DPM_LEVEL (NUM_DISPCLK_DPM_LEVELS - 1) 61 #define MAX_PIXCLK_DPM_LEVEL (NUM_PIXCLK_DPM_LEVELS - 1) 62 #define MAX_PHYCLK_DPM_LEVEL (NUM_PHYCLK_DPM_LEVELS - 1) [all …]
|