[U-Boot] [PATCH v8 7/9] rockchip: board: evb_rk3399: initialize pwm0 for dispaly backlight
Eric Gao
eric.gao at rock-chips.com
Tue May 2 10:23:55 UTC 2017
Enable pwm0 for display of rk3399 evb board. The PWM do not have decicated
interrupt number in dts and can not get periph_id by pinctrl framework. So
init them here.
Signed-off-by: Eric Gao <eric.gao at rock-chips.com>
Reviewed-by: Simon Glass <sjg at chromium.org>
---
Changes in v8: None
Changes in v7: None
Changes in v6: None
Changes in v5: None
Changes in v4: None
Changes in v3:
-Add ret value in debug message.
Changes in v2:
-Add pwm0 pinctrl init for lcd backlight.
board/rockchip/evb_rk3399/evb-rk3399.c | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/board/rockchip/evb_rk3399/evb-rk3399.c b/board/rockchip/evb_rk3399/evb-rk3399.c
index e83dedb..f63f003 100644
--- a/board/rockchip/evb_rk3399/evb-rk3399.c
+++ b/board/rockchip/evb_rk3399/evb-rk3399.c
@@ -29,6 +29,13 @@ int board_init(void)
goto out;
}
+ /* Enable pwm0 for panel backlight */
+ ret = pinctrl_request_noflags(pinctrl, PERIPH_ID_PWM0);
+ if (ret) {
+ debug("%s PWM0 pinctrl init fail! (ret=%d)\n", __func__, ret);
+ goto out;
+ }
+
ret = pinctrl_request_noflags(pinctrl, PERIPH_ID_PWM2);
if (ret) {
debug("%s PWM2 pinctrl init fail!\n", __func__);
--
1.9.1
More information about the U-Boot
mailing list