From 5fd5f56cacdd82ae10fb33496525e1614bcc0dd8 Mon Sep 17 00:00:00 2001 From: Aidan MacDonald Date: Sat, 30 Mar 2024 15:16:49 +0000 Subject: Disable unused LCD scroll functions in bootloaders These functions just reset some state related to the scroll engine, which is already disabled for bootloaders. They get called from the LCD code and compiled into the binary, but have no real effect when the rest of the scroll engine is not present. Replacing the calls with inline stubs gets rid of this dead code from bootloaders. Change-Id: I12a6d8926e19477ae3a5913e7fc8aff41cecd970 --- firmware/drivers/lcd-scroll.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'firmware/drivers') diff --git a/firmware/drivers/lcd-scroll.c b/firmware/drivers/lcd-scroll.c index 26b15732cd..895cf98cba 100644 --- a/firmware/drivers/lcd-scroll.c +++ b/firmware/drivers/lcd-scroll.c @@ -30,6 +30,7 @@ #define MAIN_LCD #endif +#if !defined(BOOTLOADER) static struct scrollinfo LCDFN(scroll)[LCDM(SCROLLABLE_LINES)]; struct scroll_screen_info LCDFN(scroll_info) = @@ -180,7 +181,6 @@ bool LCDFN(scroll_now)(struct scrollinfo *s) return ended; } -#if !defined(BOOTLOADER) static void LCDFN(scroll_worker)(void) { int index; -- cgit v1.2.3