summaryrefslogtreecommitdiff
path: root/drivers/video/backlight/pwm_bl.c
diff options
context:
space:
mode:
authorSteven Rostedt (VMware) <rostedt@goodmis.org>2019-03-26 15:21:59 -0400
committerSteven Rostedt (VMware) <rostedt@goodmis.org>2019-03-26 15:21:59 -0400
commit0f96371a30f16f6244195c717b9e2b2f42aa4e89 (patch)
tree3f42b4abf3a7643ddd06f0c7727f2e3b06798c3c /drivers/video/backlight/pwm_bl.c
parente021bb4fb77a8782d21cab4cb0702778fc3784c7 (diff)
parentce194fa2b267e2018f42442347d90df01c4071d6 (diff)
Merge tag 'v4.19.29' into v4.19-rt
This is the 4.19.29 stable release Conflicts: drivers/irqchip/irq-gic-v3-its.c
Diffstat (limited to 'drivers/video/backlight/pwm_bl.c')
-rw-r--r--drivers/video/backlight/pwm_bl.c19
1 files changed, 10 insertions, 9 deletions
diff --git a/drivers/video/backlight/pwm_bl.c b/drivers/video/backlight/pwm_bl.c
index bdfcc0a71db1..6bde543452f2 100644
--- a/drivers/video/backlight/pwm_bl.c
+++ b/drivers/video/backlight/pwm_bl.c
@@ -263,6 +263,16 @@ static int pwm_backlight_parse_dt(struct device *dev,
memset(data, 0, sizeof(*data));
/*
+ * These values are optional and set as 0 by default, the out values
+ * are modified only if a valid u32 value can be decoded.
+ */
+ of_property_read_u32(node, "post-pwm-on-delay-ms",
+ &data->post_pwm_on_delay);
+ of_property_read_u32(node, "pwm-off-delay-ms", &data->pwm_off_delay);
+
+ data->enable_gpio = -EINVAL;
+
+ /*
* Determine the number of brightness levels, if this property is not
* set a default table of brightness levels will be used.
*/
@@ -374,15 +384,6 @@ static int pwm_backlight_parse_dt(struct device *dev,
data->max_brightness--;
}
- /*
- * These values are optional and set as 0 by default, the out values
- * are modified only if a valid u32 value can be decoded.
- */
- of_property_read_u32(node, "post-pwm-on-delay-ms",
- &data->post_pwm_on_delay);
- of_property_read_u32(node, "pwm-off-delay-ms", &data->pwm_off_delay);
-
- data->enable_gpio = -EINVAL;
return 0;
}