From c49d6cab0d7fde39297949c4da257db69999292e Mon Sep 17 00:00:00 2001 From: Marek BehĂșn Date: Sat, 19 Sep 2020 20:03:04 +0200 Subject: leds: parse linux,default-trigger DT property in LED core MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Do the parsing of `linux,default-trigger` DT property to LED core. Currently it is done in many different drivers and the code is repeated. This patch removes the parsing from 23 drivers: an30259a, aw2013, bcm6328, bcm6358, cr0014114, el15203000, gpio, is31fl32xx, lm3532, lm36274, lm3692x, lm3697, lp50xx, lp8860, lt3593, max77650, mt6323, ns2, pm8058, pwm, syscon, tlc591xx and turris-omnia. There is one driver in drivers/input which parses this property on it's own. I shall send a separate patch there after this is applied. There are still 8 drivers that parse this property on their own because they do not pass the led_init_data structure to the registering function. I will try to refactor those in the future. Signed-off-by: Marek BehĂșn Signed-off-by: Pavel Machek --- drivers/leds/leds-max77650.c | 3 --- 1 file changed, 3 deletions(-) (limited to 'drivers/leds/leds-max77650.c') diff --git a/drivers/leds/leds-max77650.c b/drivers/leds/leds-max77650.c index acc1174197c3..1eeac56b0014 100644 --- a/drivers/leds/leds-max77650.c +++ b/drivers/leds/leds-max77650.c @@ -100,9 +100,6 @@ static int max77650_led_probe(struct platform_device *pdev) led->cdev.brightness_set_blocking = max77650_led_brightness_set; led->cdev.max_brightness = MAX77650_LED_MAX_BRIGHTNESS; - fwnode_property_read_string(child, "linux,default-trigger", - &led->cdev.default_trigger); - init_data.fwnode = child; init_data.devicename = "max77650"; /* for backwards compatibility if `label` is not present */ -- cgit v1.2.3