| /linux/drivers/leds/ |
| H A D | leds-ns2.c | 1 // SPDX-License-Identifier: GPL-2.0-or-later 3 * leds-ns2.c - Driver for the Network Space v2 (and parents) dual-GPIO LED 9 * Based on leds-gpio.c by Raphael Assenat <raph@8d.com> 33 u32 mode; member 39 * The Network Space v2 dual-GPIO LED is wired to a CPLD. Three different LED 40 * modes are available: off, on and SATA activity blinking. The LED modes are 42 * for the command/slow GPIOs corresponds to a LED mode. 50 unsigned char sata; /* True when SATA mode active. */ 56 static int ns2_led_get_mode(struct ns2_led *led, enum ns2_led_modes *mode) in ns2_led_get_mode() argument 62 cmd_level = gpiod_get_value_cansleep(led->cmd); in ns2_led_get_mode() [all …]
|
| H A D | leds-max8997.c | 1 // SPDX-License-Identifier: GPL-2.0-only 3 * leds-max8997.c - LED class driver for MAX8997 LEDs. 14 #include <linux/mfd/max8997-private.h> 47 static void max8997_led_set_mode(struct max8997_led *led, in max8997_led_set_mode() argument 48 enum max8997_led_mode mode) in max8997_led_set_mode() argument 51 struct i2c_client *client = led->iodev->i2c; in max8997_led_set_mode() 54 switch (mode) { in max8997_led_set_mode() 57 val = led->id ? in max8997_led_set_mode() 59 led->cdev.max_brightness = MAX8997_LED_FLASH_MAX_BRIGHTNESS; in max8997_led_set_mode() 63 val = led->id ? in max8997_led_set_mode() [all …]
|
| H A D | leds-spi-byte.c | 1 // SPDX-License-Identifier: GPL-2.0 2 // Copyright (c) 2019 Christian Mauderer <oss@c-mauderer.de> 6 * - one LED is controlled by a single byte on MOSI 7 * - the value of the byte gives the brightness between two values (lowest to 9 * - no return value is necessary (no MISO signal) 15 * - "ubnt,acb-spi-led": Microcontroller (SONiX 8F26E611LA) based device used 18 * * Higher two bits set a mode. Lower six bits are a parameter. 19 * * Mode: 00 -> set brightness between 0x00 (min) and 0x3F (max) 20 * * Mode: 01 -> pulsing pattern (min -> max -> min) with an interval. From 24 * * Mode: 10 -> same as 01 but with only a ramp from min to max. Again a [all …]
|
| H A D | leds-bcm6328.c | 1 // SPDX-License-Identifier: GPL-2.0-or-later 3 * Driver for BCM6328 memory-mapped LEDs, based on leds-syscon.c 59 * struct bcm6328_led - state container for bcm6328 based LEDs 60 * @cdev: LED class device for this LED 63 * @pin: LED pin number 66 * @active_low: LED is active low 98 * bits [31:0] -> LEDs 8-23 99 * bits [47:32] -> LEDs 0-7 100 * bits [63:48] -> unused 105 return pin + 16; /* LEDs 0-7 (bits 47:32) */ in bcm6328_pin2shift() [all …]
|
| H A D | leds-ltc3220.c | 1 // SPDX-License-Identifier: GPL-2.0 3 * LTC3220 18-Channel LED Driver 91 * Set LED brightness. Hardware supports 0-63 brightness levels. 92 * Mode switching (blink/gradation) is handled through dedicated callbacks. 94 * In aggregated mode only a single LED (reg = 1) is registered and the 95 * hardware quick-write feature propagates the write to all 18 channels, so 106 ret = regmap_write(ltc3220->regmap, LTC3220_ULED_REG(uled_cfg->led_index), in __ltc3220_set_led_data() 111 uled_cfg->reg_value = brightness; in __ltc3220_set_led_data() 121 struct ltc3220 *ltc3220 = container_of(uled_cfg - uled_cfg->led_index, struct ltc3220, in ltc3220_set_led_data() 125 mutex_lock(<c3220->lock); in ltc3220_set_led_data() [all …]
|
| H A D | leds-el15203000.c | 1 // SPDX-License-Identifier: GPL-2.0 13 * +-----+---------+ 14 * | LED | COMMAND | 15 * +-----+---------+ 17 * +-----+---------+ 21 * +----------+--------------+-------------------------------------------+ 23 * +----------+--------------+-------------------------------------------+ 25 * +----------+--------------+-------------------------------------------+ 27 * +----------+--------------+-------------------------------------------+ 29 * +----------+--------------+-------------------------------------------+ [all …]
|
| /linux/drivers/hid/ |
| H A D | hid-gt683r.c | 1 // SPDX-License-Identifier: GPL-2.0-or-later 3 * MSI GT683R led driver 14 #include "hid-ids.h" 50 enum gt683r_led_mode mode; member 63 struct device *dev = led_cdev->dev->parent; in gt683r_brightness_set() 65 struct gt683r_led *led = hid_get_drvdata(hdev); in gt683r_brightness_set() local 68 if (led_cdev == &led->led_devs[i]) in gt683r_brightness_set() 73 led->brightnesses[i] = brightness; in gt683r_brightness_set() 74 schedule_work(&led->work); in gt683r_brightness_set() 83 struct hid_device *hdev = to_hid_device(dev->parent); in mode_show() [all …]
|
| /linux/drivers/leds/flash/ |
| H A D | leds-max77693.c | 1 // SPDX-License-Identifier: GPL-2.0-only 3 * LED Flash class driver for the flash cell of max77693 mfd. 11 #include <linux/led-class-flash.h> 13 #include <linux/mfd/max77693-common.h> 14 #include <linux/mfd/max77693-private.h> 20 #include <media/v4l2-flash-led-class.h> 59 /* corresponding LED Flash class device */ 80 /* sub led data */ 92 /* mode of fled outputs */ 96 /* bitmask of FLED outputs use state (bit 0. - FLED1, bit 1. - FLED2) */ [all …]
|
| H A D | leds-aat1290.c | 1 // SPDX-License-Identifier: GPL-2.0-only 3 * LED Flash class driver for the AAT1290 4 * 1.5A Step-Up Current Regulator for Flash LEDs 13 #include <linux/led-class-flash.h> 21 #include <media/v4l2-flash-led-class.h> 50 /* maximum LED current in movie mode */ 52 /* maximum LED current in flash mode */ 58 /* max LED brightness level */ 68 /* corresponding LED Flash class device */ 77 /* movie mode current scale */ [all …]
|
| /linux/drivers/net/wireless/intel/iwlwifi/mld/ |
| H A D | led.c | 1 // SPDX-License-Identifier: GPL-2.0 OR BSD-3-Clause 8 #include "fw/api/led.h" 10 #include "led.h" 20 if (WARN_ON(!mld->fw_status.running)) in iwl_mld_send_led_fw_cmd() 28 IWL_WARN(mld, "LED command failed: %d\n", err); in iwl_mld_send_led_fw_cmd() 34 struct iwl_mld *mld = container_of(led_cdev, struct iwl_mld, led); in iwl_led_brightness_set() 36 if (!mld->fw_status.running) in iwl_led_brightness_set() 44 int mode = iwlwifi_mod_params.led_mode; in iwl_mld_leds_init() local 47 switch (mode) { in iwl_mld_leds_init() 49 IWL_ERR(mld, "Blink led mode not supported, used default\n"); in iwl_mld_leds_init() [all …]
|
| /linux/drivers/net/ethernet/intel/igc/ |
| H A D | igc_leds.c | 1 // SPDX-License-Identifier: GPL-2.0 42 struct led_classdev led; member 47 container_of(lcdev, struct igc_led_classdev, led) 49 static void igc_led_select(struct igc_adapter *adapter, int led, in igc_led_select() argument 52 switch (led) { in igc_led_select() 70 netdev_err(adapter->netdev, "Unknown LED %d selected!\n", led); in igc_led_select() 74 static void igc_led_set(struct igc_adapter *adapter, int led, u32 mode, in igc_led_set() argument 78 struct igc_hw *hw = &adapter->hw; in igc_led_set() 80 igc_led_select(adapter, led, &mask, &shift, &blink_bit); in igc_led_set() 82 pm_runtime_get_sync(&adapter->pdev->dev); in igc_led_set() [all …]
|
| /linux/Documentation/devicetree/bindings/leds/ |
| H A D | leds-lm3532.txt | 1 * Texas Instruments - lm3532 White LED driver with ambient light sensing 4 The LM3532 provides the 3 high-voltage, low-side current sinks. The device is 5 programmable over an I2C-compatible interface and has independent 7 method allows for different LED currents in each current sink thus allowing 11 each with 32 internal voltage setting resistors, 8-bit logarithmic and linear 16 - compatible : "ti,lm3532" 17 - reg : I2C slave address 18 - #address-cells : 1 19 - #size-cells : 0 22 - enable-gpios : gpio pin to enable (active high)/disable the device. [all …]
|
| H A D | richtek,rt8515.yaml | 1 # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) 3 --- 5 $schema: http://devicetree.org/meta-schemas/core.yaml# 7 title: Richtek RT8515 1.5A dual channel LED driver 10 - Linus Walleij <linusw@kernel.org> 13 The Richtek RT8515 is a dual channel (two mode) LED driver that 14 supports driving a white LED in flash or torch mode. The maximum 15 current for each mode is defined in hardware using two resistors 22 enf-gpios: 26 ent-gpios: [all …]
|
| H A D | common.yaml | 1 # SPDX-License-Identifier: GPL-2.0-only 3 --- 5 $schema: http://devicetree.org/meta-schemas/core.yaml# 10 - Jacek Anaszewski <jacek.anaszewski@gmail.com> 11 - Pavel Machek <pavel@ucw.cz> 14 LED and flash LED devices provide the same basic functionality as current 15 regulators, but extended with LED and flash LED specific features like 16 blinking patterns, flash timeout, flash faults and external flash strobe mode. 18 Many LED devices expose more than one current output that can be connected 19 to one or more discrete LED component. Since the arrangement of connections [all …]
|
| H A D | lacie,ns2-leds.yaml | 1 # SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause 3 --- 4 $id: http://devicetree.org/schemas/leds/lacie,ns2-leds.yaml# 5 $schema: http://devicetree.org/meta-schemas/core.yaml# 7 title: Dual-GPIO LEDs found on Network Space v2 (and parents) 10 - Simon Guinot <simon.guinot@sequanux.org> 13 The Network Space v2 dual-GPIO LED is wired to a CPLD. Three different LED 14 modes are available, off, on and SATA activity blinking. The LED modes are 16 for the command/slow GPIOs corresponds to a LED mode. 20 const: lacie,ns2-leds [all …]
|
| H A D | maxim,max77693.yaml | 1 # SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause 3 --- 5 $schema: http://devicetree.org/meta-schemas/core.yaml# 10 - Krzysztof Kozlowski <krzk@kernel.org> 16 There are two LED outputs available - FLED1 and FLED2. Each of them can 17 control a separate LED or they can be connected together to double the 18 maximum current for a single connected LED. One LED is represented by one 26 const: maxim,max77693-led 28 maxim,boost-mode: 30 In boost mode the device can produce up to 1.2A of total current on both [all …]
|
| /linux/drivers/net/wireless/realtek/rtw89/ |
| H A D | led.c | 1 // SPDX-License-Identifier: GPL-2.0 OR BSD-3-Clause 7 #include "led.h" 13 .mode = {.addr = R_AX_GPIO_EXT_CTRL + 2, .data = BIT(0) | BIT(8)}, 25 rtw89_write32_mask(rtwdev, e->pinmux.addr, e->pinmux.mask, e->pinmux.data); in rtw89_led_gpio_config() 26 rtw89_write16_clr(rtwdev, e->mode.addr, e->mode.data); in rtw89_led_gpio_config() 34 rtw89_write16_clr(rtwdev, e->mode.addr, e->mode.data); in rtw89_led_gpio_set() 36 rtw89_write16_set(rtwdev, e->mode.addr, e->mode.data); in rtw89_led_gpio_set() 37 rtw89_write8_clr(rtwdev, e->out.addr, e->out.data); in rtw89_led_gpio_set() 41 static int rtw89_led_set(struct led_classdev *led, enum led_brightness brightness) in rtw89_led_set() argument 43 struct rtw89_led *rtw_led = container_of(led, struct rtw89_led, led); in rtw89_led_set() [all …]
|
| /linux/arch/arm64/boot/dts/microchip/ |
| H A D | sparx5_pcb134_board.dtsi | 1 // SPDX-License-Identifier: (GPL-2.0+ OR MIT) 6 /dts-v1/; 10 gpio-restart { 11 compatible = "gpio-restart"; 16 i2c0_imux: i2c-mux-0 { 17 compatible = "i2c-mux-pinctrl"; 18 #address-cells = <1>; 19 #size-cells = <0>; 20 i2c-parent = <&i2c0>; 23 i2c0_emux: i2c-mux-1 { [all …]
|
| /linux/sound/core/ |
| H A D | control_led.c | 1 // SPDX-License-Identifier: GPL-2.0-or-later 3 * LED state routines for driver control interface 14 MODULE_DESCRIPTION("ALSA control interface to LED trigger code."); 17 #define MAX_LED (((SNDRV_CTL_ELEM_ACCESS_MIC_LED - SNDRV_CTL_ELEM_ACCESS_SPK_LED) \ 33 struct snd_ctl_led *led; member 42 enum snd_ctl_led_mode mode; member 60 .group = (SNDRV_CTL_ELEM_ACCESS_SPK_LED >> SNDRV_CTL_ELEM_ACCESS_LED_SHIFT) - 1, 62 .mode = MODE_FOLLOW_MUTE, 66 .group = (SNDRV_CTL_ELEM_ACCESS_MIC_LED >> SNDRV_CTL_ELEM_ACCESS_LED_SHIFT) - 1, 68 .mode = MODE_FOLLOW_MUTE, [all …]
|
| /linux/Documentation/devicetree/bindings/leds/backlight/ |
| H A D | lm3630a-backlight.yaml | 1 # SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause) 3 --- 4 $id: http://devicetree.org/schemas/leds/backlight/lm3630a-backlight.yaml# 5 $schema: http://devicetree.org/meta-schemas/core.yaml# 7 title: TI LM3630A High-Efficiency Dual-String White LED 10 - Lee Jones <lee@kernel.org> 11 - Daniel Thompson <daniel.thompson@linaro.org> 12 - Jingoo Han <jingoohan1@gmail.com> 15 The LM3630A is a current-mode boost converter which supplies the power and 26 '#address-cells': [all …]
|
| /linux/sound/usb/caiaq/ |
| H A D | control.c | 1 // SPDX-License-Identifier: GPL-2.0-or-later 24 struct snd_usb_caiaqdev *cdev = caiaqdev(chip->card); in control_info() 25 int pos = kcontrol->private_value; in control_info() 29 uinfo->count = 1; in control_info() 32 switch (cdev->chip.usb_id) { in control_info() 36 /* current input mode of A8DJ and A4DJ */ in control_info() 37 uinfo->type = SNDRV_CTL_ELEM_TYPE_INTEGER; in control_info() 38 uinfo->value.integer.min = 0; in control_info() 39 uinfo->value.integer.max = 2; in control_info() 54 uinfo->type = SNDRV_CTL_ELEM_TYPE_INTEGER; in control_info() [all …]
|
| /linux/Documentation/ABI/testing/ |
| H A D | sysfs-class-led-driver-lm3533 | 1 What: /sys/class/leds/<led>/als_channel 7 ALS-current-control mode (1, 2), where: 14 What: /sys/class/leds/<led>/als_en 19 Enable ALS-current-control mode (0, 1). 21 What: /sys/class/leds/<led>/falltime 22 What: /sys/class/leds/<led>/risetime 40 What: /sys/class/leds/<led>/id 45 Get the id of this led (0..3). 47 What: /sys/class/leds/<led>/linear 52 Set the brightness-mapping mode (0, 1), where: [all …]
|
| /linux/drivers/net/ethernet/realtek/ |
| H A D | r8169_leds.c | 1 // SPDX-License-Identifier: GPL-2.0-only 31 struct led_classdev led; member 37 #define lcdev_to_r8169_ldev(lcdev) container_of(lcdev, struct r8169_led_classdev, led) 58 struct rtl8169_private *tp = netdev_priv(ldev->ndev); in rtl8168_led_hw_control_is_supported() 59 int shift = ldev->index * 4; in rtl8168_led_hw_control_is_supported() 62 /* Switch LED off to indicate that mode isn't supported */ in rtl8168_led_hw_control_is_supported() 64 return -EOPNOTSUPP; in rtl8168_led_hw_control_is_supported() 74 struct rtl8169_private *tp = netdev_priv(ldev->ndev); in rtl8168_led_hw_control_set() 75 int shift = ldev->index * 4; in rtl8168_led_hw_control_set() 76 u16 mode = 0; in rtl8168_led_hw_control_set() local [all …]
|
| /linux/include/linux/ |
| H A D | leds.h | 1 /* SPDX-License-Identifier: GPL-2.0-only */ 3 * Driver model for leds and led triggers 11 #include <dt-bindings/leds/common.h> 29 * LED Core 47 * struct led_lookup_data - represents a single LED lookup entry 49 * @list: internal list of all LED lookup entries 50 * @provider: name of led_classdev providing the LED 51 * @dev_id: name of the device associated with this LED 52 * @con_id: name of the LED from the device's point of view 66 * with in-driver hard-coded LED names used as a fallback when [all …]
|
| /linux/Documentation/sound/hd-audio/ |
| H A D | models.rst | 2 HD-Audio Codec-Specific Models 8 3-jack in back and a headphone out 9 3stack-digout 10 3-jack in back, a HP out and a SPDIF out 12 5-jack in back, 2-jack in front 13 5stack-digout 14 5-jack in back, 2-jack in front, a SPDIF out 16 6-jack in back, 2-jack in front 17 6stack-digout 18 6-jack with a SPDIF out [all …]
|