From 9e2a18e40afff8553b1ddd219876bb3e6c4fb41e Mon Sep 17 00:00:00 2001 From: Shawn Guo Date: Thu, 12 Sep 2019 10:54:03 +0800 Subject: [PATCH] zero-sugar: drop touch power control initialization Touch is not needed in U-Boot, so it makes more sense to get kernel initialize power for touch. Let's drop the code from U-Boot. The bonus point is that we get U-Boot boot up faster now, as the delay for power control is gone. If we can drop the digitizer power control later (if not needed), another 1 second delay can be gone as well, and kernel has been ready to initialize power for both touch and digitizer anyway. Signed-off-by: Shawn Guo --- board/reMarkable/zero-sugar/Makefile | 1 - board/reMarkable/zero-sugar/touch_init.c | 9 --------- board/reMarkable/zero-sugar/touch_init.h | 6 ------ board/reMarkable/zero-sugar/zero-sugar.c | 5 ----- 4 files changed, 21 deletions(-) delete mode 100644 board/reMarkable/zero-sugar/touch_init.c delete mode 100644 board/reMarkable/zero-sugar/touch_init.h diff --git a/board/reMarkable/zero-sugar/Makefile b/board/reMarkable/zero-sugar/Makefile index a5de1f48eb..80dc952ae7 100644 --- a/board/reMarkable/zero-sugar/Makefile +++ b/board/reMarkable/zero-sugar/Makefile @@ -7,7 +7,6 @@ obj-y := zero-sugar.o \ uart_init.o \ epd_pmic_init.o \ epd_display_init.o \ - touch_init.o \ digitizer_init.o \ charger_init.o \ serial_download_trap.o \ diff --git a/board/reMarkable/zero-sugar/touch_init.c b/board/reMarkable/zero-sugar/touch_init.c deleted file mode 100644 index 63e4d0c1ca..0000000000 --- a/board/reMarkable/zero-sugar/touch_init.c +++ /dev/null @@ -1,9 +0,0 @@ -#include -#include - -void zs_do_config_touch_powerctrl_pins(void) -{ - printf("Turning on touch power..\n"); - gpio_request(IMX_GPIO_NR(1, 11), "TOUCH_PWR_EN"); - gpio_direction_output(IMX_GPIO_NR(1, 11), 1); -} diff --git a/board/reMarkable/zero-sugar/touch_init.h b/board/reMarkable/zero-sugar/touch_init.h deleted file mode 100644 index f0872613c6..0000000000 --- a/board/reMarkable/zero-sugar/touch_init.h +++ /dev/null @@ -1,6 +0,0 @@ -#ifndef TOUCH_INIT_H -#define TOUCH_INIT_H - -void zs_do_config_touch_powerctrl_pins(void); - -#endif diff --git a/board/reMarkable/zero-sugar/zero-sugar.c b/board/reMarkable/zero-sugar/zero-sugar.c index 1c28f5a835..0fadd89d62 100644 --- a/board/reMarkable/zero-sugar/zero-sugar.c +++ b/board/reMarkable/zero-sugar/zero-sugar.c @@ -11,7 +11,6 @@ #include "uart_init.h" #include "epd_display_init.h" #include "epd_pmic_init.h" -#include "touch_init.h" #include "digitizer_init.h" #include "charger_init.h" #include "serial_download_trap.h" @@ -73,10 +72,6 @@ static void power_perfs(void) // Shutdown LCDIF lcdif_power_down(); - /* TOUCH */ - zs_do_config_touch_powerctrl_pins(); - udelay(500000); - /* DIGITIZER */ zs_do_config_digitizer_powerctrl_pins(); udelay(1000000);