Home
last modified time | relevance | path

Searched +full:led +full:- (Results 1 – 25 of 1041) sorted by relevance

12345678910>>...42

/kernel/linux/linux-5.10/sound/usb/caiaq/
Dcontrol.c1 // 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()
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()
55 uinfo->value.integer.min = 0; in control_info()
[all …]
/kernel/linux/linux-4.19/sound/usb/caiaq/
Dcontrol.c17 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
37 struct snd_usb_caiaqdev *cdev = caiaqdev(chip->card); in control_info()
38 int pos = kcontrol->private_value; in control_info()
42 uinfo->count = 1; in control_info()
45 switch (cdev->chip.usb_id) { in control_info()
50 uinfo->type = SNDRV_CTL_ELEM_TYPE_INTEGER; in control_info()
51 uinfo->value.integer.min = 0; in control_info()
52 uinfo->value.integer.max = 2; in control_info()
67 uinfo->type = SNDRV_CTL_ELEM_TYPE_INTEGER; in control_info()
68 uinfo->value.integer.min = 0; in control_info()
[all …]
/kernel/linux/linux-5.10/drivers/leds/
Dleds-bd2802.c1 // SPDX-License-Identifier: GPL-2.0-only
3 * leds-bd2802.c - RGB LED Driver
8 * Datasheet: http://www.rohm.com/products/databook/driver/pdf/bd2802gu-e.pdf
16 #include <linux/leds-bd2802.h>
73 struct led_state led[2]; member
104 /*--------------------------------------------------------------*/
106 /*--------------------------------------------------------------*/
108 static inline int bd2802_is_rgb_off(struct bd2802_led *led, enum led_ids id, in bd2802_is_rgb_off() argument
113 return !led->led[id].r; in bd2802_is_rgb_off()
115 return !led->led[id].g; in bd2802_is_rgb_off()
[all …]
DKconfig1 # SPDX-License-Identifier: GPL-2.0-only
10 bool "LED Support"
12 Say Y to enable Linux LED support. This allows control of supported
18 tristate "LED Class Support"
20 This option enables the LED sysfs class in /sys/class/leds. You'll
24 tristate "LED Flash Class Support"
27 This option enables the flash LED sysfs class in /sys/class/leds.
28 It wraps LED Class and adds flash LEDs specific sysfs attributes
30 for the flash related features of a LED device. It can be built
34 tristate "LED Multicolor Class Support"
[all …]
Dleds-lm3601x.c1 // SPDX-License-Identifier: GPL-2.0
2 // Flash and torch driver for Texas Instruments LM3601X LED
4 // Copyright (C) 2018 Texas Instruments Incorporated - https://www.ti.com/
9 #include <linux/led-class-flash.h>
73 * struct lm3601x_led -
74 * @fled_cdev: flash LED class device pointer
78 * @led_name: LED label for the Torch or IR LED
135 static int lm3601x_read_faults(struct lm3601x_led *led) in lm3601x_read_faults() argument
140 ret = regmap_read(led->regmap, LM3601X_FLAGS_REG, &flags_val); in lm3601x_read_faults()
142 return -EIO; in lm3601x_read_faults()
[all …]
Dleds-lm3692x.c1 // SPDX-License-Identifier: GPL-2.0
2 // TI LM3692x LED chip family driver
3 // Copyright (C) 2017-18 Texas Instruments Incorporated - https://www.ti.com/
99 * struct lm3692x_led -
100 * @lock - Lock for reading/writing the device
101 * @client - Pointer to the I2C client
102 * @led_dev - LED class device pointer
103 * @regmap - Devices register map
104 * @enable_gpio - VDDIO/EN gpio to enable communication interface
105 * @regulator - LED supply regulator pointer
[all …]
Dleds-cpcap.c1 // SPDX-License-Identifier: GPL-2.0-or-later
7 #include <linux/mfd/motorola-cpcap.h>
52 /* camera privacy led */
62 struct led_classdev led; member
81 static int cpcap_led_set_power(struct cpcap_led *led, bool status) in cpcap_led_set_power() argument
85 if (status == led->powered) in cpcap_led_set_power()
89 err = regulator_enable(led->vdd); in cpcap_led_set_power()
91 err = regulator_disable(led->vdd); in cpcap_led_set_power()
94 dev_err(led->dev, "regulator failure: %d", err); in cpcap_led_set_power()
98 led->powered = status; in cpcap_led_set_power()
[all …]
Dleds-aat1290.c1 // 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
12 #include <linux/led-class-flash.h>
20 #include <media/v4l2-flash-led-class.h>
49 /* maximum LED current in movie mode */
51 /* maximum LED current in flash mode */
57 /* max LED brightness level */
67 /* corresponding LED Flash class device */
96 static void aat1290_as2cwire_write(struct aat1290_led *led, int addr, int value) in aat1290_as2cwire_write() argument
[all …]
Dleds-ktd2692.c1 // SPDX-License-Identifier: GPL-2.0-only
3 * LED driver : leds-ktd2692.c
12 #include <linux/led-class-flash.h>
64 /* maximum LED current in movie mode */
66 /* maximum LED current in flash mode */
70 /* max LED brightness level */
75 /* Related LED Flash class device */
95 static void ktd2692_expresswire_start(struct ktd2692_context *led) in ktd2692_expresswire_start() argument
97 gpiod_direction_output(led->ctrl_gpio, KTD2692_HIGH); in ktd2692_expresswire_start()
101 static void ktd2692_expresswire_reset(struct ktd2692_context *led) in ktd2692_expresswire_reset() argument
[all …]
Dleds-max77693.c1 // 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 */
96 /* bitmask of FLED outputs use state (bit 0. - FLED1, bit 1. - FLED2) */
109 return (ua - FLASH_IOUT_MIN) / FLASH_IOUT_STEP; in max77693_led_iout_to_reg()
[all …]
Dleds-max8997.c1 // 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
51 struct i2c_client *client = led->iodev->i2c; 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()
65 led->cdev.max_brightness = MAX8997_LED_MOVIE_MAX_BRIGHTNESS; in max8997_led_set_mode()
70 val = led->id ? in max8997_led_set_mode()
[all …]
Dleds-ns2.c1 // 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>
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.
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()
63 slow_level = gpiod_get_value_cansleep(led->slow); in ns2_led_get_mode()
65 for (i = 0; i < led->num_modes; i++) { in ns2_led_get_mode()
[all …]
Dleds-wm8350.c1 // SPDX-License-Identifier: GPL-2.0-only
3 * LED driver for WM8350 driven LEDS.
88 static int wm8350_led_enable(struct wm8350_led *led) in wm8350_led_enable() argument
92 if (led->enabled) in wm8350_led_enable()
95 ret = regulator_enable(led->isink); in wm8350_led_enable()
97 dev_err(led->cdev.dev, "Failed to enable ISINK: %d\n", ret); in wm8350_led_enable()
101 ret = regulator_enable(led->dcdc); in wm8350_led_enable()
103 dev_err(led->cdev.dev, "Failed to enable DCDC: %d\n", ret); in wm8350_led_enable()
104 regulator_disable(led->isink); in wm8350_led_enable()
108 led->enabled = 1; in wm8350_led_enable()
[all …]
/kernel/linux/linux-4.19/drivers/leds/
Dleds-bd2802.c2 * leds-bd2802.c - RGB LED Driver
11 * Datasheet: http://www.rohm.com/products/databook/driver/pdf/bd2802gu-e.pdf
20 #include <linux/leds-bd2802.h>
76 struct led_state led[2]; member
107 /*--------------------------------------------------------------*/
109 /*--------------------------------------------------------------*/
111 static inline int bd2802_is_rgb_off(struct bd2802_led *led, enum led_ids id, in bd2802_is_rgb_off() argument
116 return !led->led[id].r; in bd2802_is_rgb_off()
118 return !led->led[id].g; in bd2802_is_rgb_off()
120 return !led->led[id].b; in bd2802_is_rgb_off()
[all …]
Dleds-lm3601x.c1 // SPDX-License-Identifier: GPL-2.0
2 // Flash and torch driver for Texas Instruments LM3601X LED
4 // Copyright (C) 2018 Texas Instruments Incorporated - http://www.ti.com/
9 #include <linux/led-class-flash.h>
74 * struct lm3601x_led -
75 * @fled_cdev: flash LED class device pointer
79 * @led_name: LED label for the Torch or IR LED
138 static int lm3601x_read_faults(struct lm3601x_led *led) in lm3601x_read_faults() argument
143 ret = regmap_read(led->regmap, LM3601X_FLAGS_REG, &flags_val); in lm3601x_read_faults()
145 return -EIO; in lm3601x_read_faults()
[all …]
DKconfig9 bool "LED Support"
11 Say Y to enable Linux LED support. This allows control of supported
17 tristate "LED Class Support"
19 This option enables the led sysfs class in /sys/class/leds. You'll
23 tristate "LED Flash Class Support"
26 This option enables the flash led sysfs class in /sys/class/leds.
27 It wrapps LED Class and adds flash LEDs specific sysfs attributes
29 for the flash related features of a LED device. It can be built
33 bool "LED Class brightness_hw_changed attribute support"
37 for led sysfs class devices under /sys/class/leds.
[all …]
Dleds-cpcap.c15 #include <linux/mfd/motorola-cpcap.h>
60 /* camera privacy led */
70 struct led_classdev led; member
89 static int cpcap_led_set_power(struct cpcap_led *led, bool status) in cpcap_led_set_power() argument
93 if (status == led->powered) in cpcap_led_set_power()
97 err = regulator_enable(led->vdd); in cpcap_led_set_power()
99 err = regulator_disable(led->vdd); in cpcap_led_set_power()
102 dev_err(led->dev, "regulator failure: %d", err); in cpcap_led_set_power()
106 led->powered = status; in cpcap_led_set_power()
113 struct cpcap_led *led = container_of(ledc, struct cpcap_led, led); in cpcap_led_set() local
[all …]
Dleds-lm3692x.c1 // SPDX-License-Identifier: GPL-2.0
2 // TI LM3692x LED chip family driver
3 // Copyright (C) 2017-18 Texas Instruments Incorporated - http://www.ti.com/
99 * struct lm3692x_led -
100 * @lock - Lock for reading/writing the device
101 * @client - Pointer to the I2C client
102 * @led_dev - LED class device pointer
103 * @regmap - Devices register map
104 * @enable_gpio - VDDIO/EN gpio to enable communication interface
105 * @regulator - LED supply regulator pointer
[all …]
Dleds-aat1290.c2 * LED Flash class driver for the AAT1290
3 * 1.5A Step-Up Current Regulator for Flash LEDs
15 #include <linux/led-class-flash.h>
23 #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 */
98 static void aat1290_as2cwire_write(struct aat1290_led *led, int addr, int value) in aat1290_as2cwire_write() argument
102 gpiod_direction_output(led->gpio_fl_en, 0); in aat1290_as2cwire_write()
[all …]
Dleds-ktd2692.c2 * LED driver : leds-ktd2692.c
15 #include <linux/led-class-flash.h>
67 /* maximum LED current in movie mode */
69 /* maximum LED current in flash mode */
73 /* max LED brightness level */
78 /* Related LED Flash class device */
98 static void ktd2692_expresswire_start(struct ktd2692_context *led) in ktd2692_expresswire_start() argument
100 gpiod_direction_output(led->ctrl_gpio, KTD2692_HIGH); in ktd2692_expresswire_start()
104 static void ktd2692_expresswire_reset(struct ktd2692_context *led) in ktd2692_expresswire_reset() argument
106 gpiod_direction_output(led->ctrl_gpio, KTD2692_LOW); in ktd2692_expresswire_reset()
[all …]
Dleds-max77693.c2 * LED Flash class driver for the flash cell of max77693 mfd.
14 #include <linux/led-class-flash.h>
16 #include <linux/mfd/max77693-common.h>
17 #include <linux/mfd/max77693-private.h>
23 #include <media/v4l2-flash-led-class.h>
62 /* corresponding LED Flash class device */
83 /* sub led data */
99 /* bitmask of FLED outputs use state (bit 0. - FLED1, bit 1. - FLED2) */
112 return (ua - FLASH_IOUT_MIN) / FLASH_IOUT_STEP; in max77693_led_iout_to_reg()
117 return (us - FLASH_TIMEOUT_MIN) / FLASH_TIMEOUT_STEP; in max77693_flash_timeout_to_reg()
[all …]
Dleds-max8997.c2 * leds-max8997.c - LED class driver for MAX8997 LEDs.
18 #include <linux/mfd/max8997-private.h>
51 static void max8997_led_set_mode(struct max8997_led *led, in max8997_led_set_mode() argument
55 struct i2c_client *client = led->iodev->i2c; in max8997_led_set_mode()
61 val = led->id ? in max8997_led_set_mode()
63 led->cdev.max_brightness = MAX8997_LED_FLASH_MAX_BRIGHTNESS; in max8997_led_set_mode()
67 val = led->id ? in max8997_led_set_mode()
69 led->cdev.max_brightness = MAX8997_LED_MOVIE_MAX_BRIGHTNESS; in max8997_led_set_mode()
74 val = led->id ? in max8997_led_set_mode()
76 led->cdev.max_brightness = MAX8997_LED_FLASH_MAX_BRIGHTNESS; in max8997_led_set_mode()
[all …]
Dleds-wm8350.c2 * LED driver for WM8350 driven LEDS.
92 static int wm8350_led_enable(struct wm8350_led *led) in wm8350_led_enable() argument
96 if (led->enabled) in wm8350_led_enable()
99 ret = regulator_enable(led->isink); in wm8350_led_enable()
101 dev_err(led->cdev.dev, "Failed to enable ISINK: %d\n", ret); in wm8350_led_enable()
105 ret = regulator_enable(led->dcdc); in wm8350_led_enable()
107 dev_err(led->cdev.dev, "Failed to enable DCDC: %d\n", ret); in wm8350_led_enable()
108 regulator_disable(led->isink); in wm8350_led_enable()
112 led->enabled = 1; in wm8350_led_enable()
117 static int wm8350_led_disable(struct wm8350_led *led) in wm8350_led_disable() argument
[all …]
Dleds-lp8860.c2 * TI LP8860 4-Channel LED Driver
91 * struct lp8860_led -
92 * @lock - Lock for reading/writing the device
93 * @client - Pointer to the I2C client
94 * @led_dev - led class device pointer
95 * @regmap - Devices register map
96 * @eeprom_regmap - EEPROM register map
97 * @enable_gpio - VDDIO/EN gpio to enable communication interface
98 * @regulator - LED supply regulator pointer
99 * @label - LED label
[all …]
/kernel/linux/linux-5.10/Documentation/devicetree/bindings/leds/
Dcommon.yaml1 # 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
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
20 can influence the way of the LED device initialization, the LED components
[all …]

12345678910>>...42