Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

platform/x86: int3472: Rename pled to led in LED registration code

Rename the privacy LED type, struct member, and functions from "pled"
to "led" in preparation for supporting additional LED types beyond
just the privacy LED.

No functional change.

Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Reviewed-by: Hans de Goede <johannes.goede@oss.qualcomm.com>
Signed-off-by: Marco Nenciarini <mnencia@kcore.it>
Link: https://patch.msgid.link/20260401203638.1601661-3-mnencia@kcore.it
Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>

authored by

Marco Nenciarini and committed by
Ilpo Järvinen
39237e32 d6116d86

+13 -13
+2 -2
drivers/platform/x86/intel/int3472/discrete.c
··· 354 354 355 355 break; 356 356 case INT3472_GPIO_TYPE_PRIVACY_LED: 357 - ret = skl_int3472_register_pled(int3472, gpio); 357 + ret = skl_int3472_register_led(int3472, gpio); 358 358 if (ret) 359 359 err_msg = "Failed to register LED\n"; 360 360 ··· 429 429 gpiod_remove_lookup_table(&int3472->gpios); 430 430 431 431 skl_int3472_unregister_clock(int3472); 432 - skl_int3472_unregister_pled(int3472); 432 + skl_int3472_unregister_led(int3472); 433 433 skl_int3472_unregister_regulator(int3472); 434 434 } 435 435 EXPORT_SYMBOL_NS_GPL(int3472_discrete_cleanup, "INTEL_INT3472_DISCRETE");
+7 -7
drivers/platform/x86/intel/int3472/led.c
··· 6 6 #include <linux/leds.h> 7 7 #include <linux/platform_data/x86/int3472.h> 8 8 9 - static int int3472_pled_set(struct led_classdev *led_cdev, enum led_brightness brightness) 9 + static int int3472_led_set(struct led_classdev *led_cdev, enum led_brightness brightness) 10 10 { 11 - struct int3472_pled *led = container_of(led_cdev, struct int3472_pled, classdev); 11 + struct int3472_led *led = container_of(led_cdev, struct int3472_led, classdev); 12 12 13 13 gpiod_set_value_cansleep(led->gpio, brightness); 14 14 return 0; 15 15 } 16 16 17 - int skl_int3472_register_pled(struct int3472_discrete_device *int3472, struct gpio_desc *gpio) 17 + int skl_int3472_register_led(struct int3472_discrete_device *int3472, struct gpio_desc *gpio) 18 18 { 19 - struct int3472_pled *led = &int3472->pled; 19 + struct int3472_led *led = &int3472->led; 20 20 char *p; 21 21 int ret; 22 22 ··· 34 34 35 35 led->classdev.name = led->name; 36 36 led->classdev.max_brightness = 1; 37 - led->classdev.brightness_set_blocking = int3472_pled_set; 37 + led->classdev.brightness_set_blocking = int3472_led_set; 38 38 39 39 ret = led_classdev_register(int3472->dev, &led->classdev); 40 40 if (ret) ··· 48 48 return 0; 49 49 } 50 50 51 - void skl_int3472_unregister_pled(struct int3472_discrete_device *int3472) 51 + void skl_int3472_unregister_led(struct int3472_discrete_device *int3472) 52 52 { 53 - struct int3472_pled *led = &int3472->pled; 53 + struct int3472_led *led = &int3472->led; 54 54 55 55 if (IS_ERR_OR_NULL(led->classdev.dev)) 56 56 return;
+4 -4
include/linux/platform_data/x86/int3472.h
··· 122 122 u8 imgclk_index; 123 123 } clock; 124 124 125 - struct int3472_pled { 125 + struct int3472_led { 126 126 struct led_classdev classdev; 127 127 struct led_lookup_data lookup; 128 128 char name[INT3472_LED_MAX_NAME_LEN]; 129 129 struct gpio_desc *gpio; 130 - } pled; 130 + } led; 131 131 132 132 struct int3472_discrete_quirks quirks; 133 133 ··· 161 161 const char *second_sensor); 162 162 void skl_int3472_unregister_regulator(struct int3472_discrete_device *int3472); 163 163 164 - int skl_int3472_register_pled(struct int3472_discrete_device *int3472, struct gpio_desc *gpio); 165 - void skl_int3472_unregister_pled(struct int3472_discrete_device *int3472); 164 + int skl_int3472_register_led(struct int3472_discrete_device *int3472, struct gpio_desc *gpio); 165 + void skl_int3472_unregister_led(struct int3472_discrete_device *int3472); 166 166 167 167 #endif