Home
last modified time | relevance | path

Searched refs:num_leds (Results 1 – 25 of 119) sorted by relevance

12345

/Linux-v5.4/drivers/leds/
Dleds-ns2.c248 int ret, num_leds = 0; in ns2_leds_get_of_pdata() local
250 num_leds = of_get_child_count(np); in ns2_leds_get_of_pdata()
251 if (!num_leds) in ns2_leds_get_of_pdata()
254 leds = devm_kcalloc(dev, num_leds, sizeof(struct ns2_led), in ns2_leds_get_of_pdata()
317 pdata->num_leds = num_leds; in ns2_leds_get_of_pdata()
334 int num_leds; member
338 static inline int sizeof_ns2_led_priv(int num_leds) in sizeof_ns2_led_priv() argument
341 (sizeof(struct ns2_led_data) * num_leds); in sizeof_ns2_led_priv()
369 sizeof_ns2_led_priv(pdata->num_leds), GFP_KERNEL); in ns2_led_probe()
372 priv->num_leds = pdata->num_leds; in ns2_led_probe()
[all …]
Dleds-mc13783.c38 int num_leds; member
134 pdata->num_leds = of_get_child_count(parent); in mc13xxx_led_probe_dt()
136 pdata->led = devm_kcalloc(dev, pdata->num_leds, sizeof(*pdata->led), in mc13xxx_led_probe_dt()
160 pdata->num_leds = i; in mc13xxx_led_probe_dt()
202 leds->num_leds = pdata->num_leds; in mc13xxx_led_probe()
204 if ((leds->num_leds < 1) || in mc13xxx_led_probe()
205 (leds->num_leds > (devtype->led_max - devtype->led_min + 1))) { in mc13xxx_led_probe()
206 dev_err(dev, "Invalid LED count %d\n", leds->num_leds); in mc13xxx_led_probe()
210 leds->led = devm_kcalloc(dev, leds->num_leds, sizeof(*leds->led), in mc13xxx_led_probe()
222 for (i = 0; i < leds->num_leds; i++) { in mc13xxx_led_probe()
[all …]
Dleds-gpio.c124 int num_leds; member
128 static inline int sizeof_gpio_leds_priv(int num_leds) in sizeof_gpio_leds_priv() argument
131 (sizeof(struct gpio_led_data) * num_leds); in sizeof_gpio_leds_priv()
150 struct gpio_led_data *led_dat = &priv->leds[priv->num_leds]; in gpio_leds_create()
189 priv->num_leds++; in gpio_leds_create()
254 if (pdata && pdata->num_leds) { in gpio_led_probe()
256 sizeof_gpio_leds_priv(pdata->num_leds), in gpio_led_probe()
261 priv->num_leds = pdata->num_leds; in gpio_led_probe()
262 for (i = 0; i < priv->num_leds; i++) { in gpio_led_probe()
300 for (i = 0; i < priv->num_leds; i++) { in gpio_led_shutdown()
Dleds-is31fl319x.c77 int num_leds; member
81 .num_leds = 1,
85 .num_leds = 3,
89 .num_leds = 6,
93 .num_leds = 9,
128 for (i = 0; i < is31->cdef->num_leds; i++) { in is31fl319x_brightness_set()
223 if (!count || count > is31->cdef->num_leds) { in is31fl319x_parse_dt()
225 is31->cdef->num_leds); in is31fl319x_parse_dt()
239 if (reg < 1 || reg > is31->cdef->num_leds) { in is31fl319x_parse_dt()
377 for (i = 0; i < is31->cdef->num_leds; i++) in is31fl319x_probe()
[all …]
Dleds-pca9532.c34 u8 num_leds; member
74 .num_leds = 2,
77 .num_leds = 8,
80 .num_leds = 16,
83 .num_leds = 4,
119 for (i = 0; i < data->chip_info->num_leds; i++) { in pca9532_calcpwm()
143 u8 maxleds = data->chip_info->num_leds; in pca9532_setpwm()
159 u8 maxleds = data->chip_info->num_leds; in pca9532_setled()
245 u8 maxleds = data->chip_info->num_leds; in pca9532_input_work()
257 u8 maxleds = data->chip_info->num_leds; in pca9532_getled()
[all …]
Dleds-lm36274.c40 int num_leds; member
56 for (i = 0; i < lm36274_data->num_leds; i++) in lm36274_init()
93 lm36274_data->num_leds = fwnode_property_count_u32(child, "led-sources"); in lm36274_parse_dt()
94 if (lm36274_data->num_leds <= 0) in lm36274_parse_dt()
99 lm36274_data->num_leds); in lm36274_parse_dt()
Dleds-max77650.c70 int rv, num_leds; in max77650_led_probe() local
84 num_leds = device_get_child_node_count(dev); in max77650_led_probe()
85 if (!num_leds || num_leds > MAX77650_LED_NUM_LEDS) in max77650_led_probe()
Dleds-netxbig.c58 int num_leds; member
419 int num_leds = 0; in netxbig_leds_get_of_pdata() local
470 num_leds = of_get_child_count(np); in netxbig_leds_get_of_pdata()
471 if (!num_leds) { in netxbig_leds_get_of_pdata()
476 leds = devm_kcalloc(dev, num_leds, sizeof(*leds), GFP_KERNEL); in netxbig_leds_get_of_pdata()
553 pdata->num_leds = num_leds; in netxbig_leds_get_of_pdata()
583 pdata->num_leds, sizeof(*leds_data), in netxbig_led_probe()
592 for (i = 0; i < pdata->num_leds; i++) { in netxbig_led_probe()
Dleds-adp5520.c104 if (pdata->num_leds > ADP5520_01_MAXLEDS) { in adp5520_led_probe()
110 led = devm_kcalloc(&pdev->dev, pdata->num_leds, sizeof(*led), in adp5520_led_probe()
121 for (i = 0; i < pdata->num_leds; ++i) { in adp5520_led_probe()
177 for (i = 0; i < pdata->num_leds; i++) { in adp5520_led_remove()
Dleds-gpio-register.c28 if (!pdata->num_leds) in gpio_led_register_device()
32 pdata->num_leds * sizeof(*pdata->leds), GFP_KERNEL); in gpio_led_register_device()
Dleds-pwm.c31 int num_leds; member
71 struct led_pwm_data *led_data = &priv->leds[priv->num_leds]; in led_pwm_add()
110 priv->num_leds++; in led_pwm_add()
164 count = pdata->num_leds; in led_pwm_probe()
Dleds-lm3697.c59 int num_leds; member
247 led->num_leds = fwnode_property_count_u32(child, "led-sources"); in lm3697_probe_dt()
248 if (led->num_leds > LM3697_MAX_LED_STRINGS) { in lm3697_probe_dt()
255 led->num_leds); in lm3697_probe_dt()
262 for (j = 0; j < led->num_leds; j++) in lm3697_probe_dt()
Dleds-da9052.c112 pled->num_leds, sizeof(struct da9052_led), in da9052_led_probe()
119 for (i = 0; i < pled->num_leds; i++) { in da9052_led_probe()
171 for (i = 0; i < pled->num_leds; i++) { in da9052_led_remove()
Dleds-pca963x.c319 pdata->leds.num_leds = chip->n_leds; in pca963x_get_pdata()
375 if (pdata && (pdata->leds.num_leds < 1 || in pca963x_probe()
376 pdata->leds.num_leds > chip->n_leds)) { in pca963x_probe()
407 if (pdata && i < pdata->leds.num_leds) { in pca963x_probe()
416 if (!pdata || i >= pdata->leds.num_leds || in pca963x_probe()
Dleds-is31fl32xx.c46 unsigned int num_leds; member
361 for (i = 0; i < priv->num_leds; i++) { in is31fl32xx_find_led_data()
377 &priv->leds[priv->num_leds]; in is31fl32xx_parse_dt()
405 priv->num_leds++; in is31fl32xx_parse_dt()
Dleds-an30259a.c78 int num_leds; member
250 chip->num_leds = i; in an30259a_dt_init()
308 for (i = 0; i < chip->num_leds; i++) { in an30259a_probe()
Dleds-pca955x.c130 int num_leds; member
406 pdata->num_leds = chip->bits; in pca955x_get_pdata()
455 if (pdata->num_leds != chip->bits) { in pca955x_probe()
458 pdata->num_leds, chip->bits); in pca955x_probe()
/Linux-v5.4/drivers/input/
Dinput-leds.c46 unsigned int num_leds; member
89 unsigned int num_leds; in input_leds_connect() local
94 num_leds = input_leds_get_count(dev); in input_leds_connect()
95 if (!num_leds) in input_leds_connect()
98 leds = kzalloc(struct_size(leds, leds, num_leds), GFP_KERNEL); in input_leds_connect()
102 leds->num_leds = num_leds; in input_leds_connect()
175 for (i = 0; i < leds->num_leds; i++) { in input_leds_disconnect()
/Linux-v5.4/drivers/input/keyboard/
Dcap11xx.c84 int num_leds; member
93 unsigned int num_leds; member
103 [CAP1106] = { .product_id = 0x55, .num_channels = 6, .num_leds = 0 },
104 [CAP1126] = { .product_id = 0x53, .num_channels = 6, .num_leds = 2 },
105 [CAP1188] = { .product_id = 0x50, .num_channels = 8, .num_leds = 8 },
208 if (IS_ENABLED(CONFIG_LEDS_CLASS) && priv->num_leds) in cap11xx_set_sleep()
249 struct cap11xx_priv *priv, int num_leds) in cap11xx_init_leds() argument
256 if (!num_leds || !cnt) in cap11xx_init_leds()
259 if (cnt > num_leds) in cap11xx_init_leds()
293 if (error != 0 || reg >= num_leds) { in cap11xx_init_leds()
[all …]
/Linux-v5.4/drivers/hid/
Dhid-led.c75 int num_leds; member
257 .num_leds = 1,
360 .num_leds = 1,
370 .num_leds = 1,
381 .num_leds = 2,
392 .num_leds = 1,
403 .num_leds = 6,
415 if (config->num_leds > 1) in hidled_init_led()
482 ldev->rgb = devm_kcalloc(&hdev->dev, ldev->config->num_leds, in hidled_probe()
493 for (i = 0; i < ldev->config->num_leds; i++) { in hidled_probe()
/Linux-v5.4/arch/mips/ar7/
Dplatform.c497 ar7_led_data.num_leds = ARRAY_SIZE(default_leds); in detect_leds()
509 ar7_led_data.num_leds = ARRAY_SIZE(fb_fon_leds); in detect_leds()
512 ar7_led_data.num_leds = ARRAY_SIZE(fb_sl_leds); in detect_leds()
516 ar7_led_data.num_leds = ARRAY_SIZE(dsl502t_leds); in detect_leds()
519 ar7_led_data.num_leds = ARRAY_SIZE(dg834g_leds); in detect_leds()
522 ar7_led_data.num_leds = ARRAY_SIZE(titan_leds); in detect_leds()
525 ar7_led_data.num_leds = ARRAY_SIZE(gt701_leds); in detect_leds()
/Linux-v5.4/drivers/mfd/
Dlm3533-core.c439 if (!pdata->leds || pdata->num_leds == 0) in lm3533_device_led_init()
442 if (pdata->num_leds > ARRAY_SIZE(lm3533_led_devs)) in lm3533_device_led_init()
443 pdata->num_leds = ARRAY_SIZE(lm3533_led_devs); in lm3533_device_led_init()
445 for (i = 0; i < pdata->num_leds; ++i) { in lm3533_device_led_init()
451 pdata->num_leds, NULL, 0, NULL); in lm3533_device_led_init()
/Linux-v5.4/include/linux/
Dleds_pwm.h18 int num_leds; member
/Linux-v5.4/include/linux/platform_data/
Dleds-kirkwood-ns2.h34 int num_leds; member
/Linux-v5.4/include/linux/mfd/
Dhtc-pasic3.h44 unsigned int num_leds; member

12345