summaryrefslogtreecommitdiff
path: root/board/toradex/colibri_vf/colibri_vf.c
diff options
context:
space:
mode:
authorGerard Salvatella <gerard.salvatella@toradex.com>2018-08-31 09:47:44 +0200
committerMarcel Ziswiler <marcel.ziswiler@toradex.com>2018-09-13 14:06:50 +0200
commit5717b9a050a123d3e1eafa7c0883810847e74d2c (patch)
tree679d577c617588db0b29754a0a70619ec2dd895f /board/toradex/colibri_vf/colibri_vf.c
parent71c46c0c7531467a8387d3a686aef66397abd94c (diff)
board: toradex: turn off lcd backlight before OS handover
U-Boot typically tears down the display controller before handing control over to Linux. On LCD displays disabling pixel clock leads to a fading out effect with vertical/horizontal lines. Make sure to disable back light before booting Linux. Signed-off-by: Gerard Salvatella <gerard.salvatella@toradex.com> Acked-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
Diffstat (limited to 'board/toradex/colibri_vf/colibri_vf.c')
-rw-r--r--board/toradex/colibri_vf/colibri_vf.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/board/toradex/colibri_vf/colibri_vf.c b/board/toradex/colibri_vf/colibri_vf.c
index 02997e18a8..025eefc784 100644
--- a/board/toradex/colibri_vf/colibri_vf.c
+++ b/board/toradex/colibri_vf/colibri_vf.c
@@ -42,6 +42,7 @@ DECLARE_GLOBAL_DATA_PTR;
#define USB_PEN_GPIO 83
#define USB_CDET_GPIO 102
+#define PTC0_GPIO_45 45
static struct ddrmc_cr_setting colibri_vf_cr_settings[] = {
{ DDRMC_CR79_CTLUPD_AREF(1), 79 },
@@ -650,3 +651,12 @@ int board_usb_phy_mode(int port)
}
}
#endif
+
+/*
+ * Backlight off before OS handover
+ */
+void board_preboot_os(void)
+{
+ gpio_request(PTC0_GPIO_45, "BL_ON");
+ gpio_direction_output(PTC0_GPIO_45, 0);
+}