From b7a45a0b6b7561cd626b4537d14baa95cf774f58 Mon Sep 17 00:00:00 2001 From: cepetr Date: Wed, 24 Apr 2024 07:30:56 +0200 Subject: [PATCH] fixup! feat(core): refactor display drivers --- core/SConscript.bootloader_emu | 2 +- core/SConscript.unix | 5 +---- core/embed/lib/dma2d_emul.c | 4 ---- 3 files changed, 2 insertions(+), 9 deletions(-) diff --git a/core/SConscript.bootloader_emu b/core/SConscript.bootloader_emu index a7e21ad6c..c57cecd0b 100644 --- a/core/SConscript.bootloader_emu +++ b/core/SConscript.bootloader_emu @@ -91,7 +91,6 @@ SOURCE_MOD += [ 'embed/lib/buffers.c', 'embed/lib/colors.c', 'embed/lib/display_utils.c', - 'embed/lib/dma2d_emul.c', 'embed/lib/fonts/font_bitmap.c', 'embed/lib/fonts/fonts.c', 'embed/lib/gl_color.c', @@ -122,6 +121,7 @@ if NEW_RENDERING: else: SOURCE_MOD += [ 'embed/lib/display_draw.c', + 'embed/lib/dma2d_emul.c', ] if TREZOR_MODEL in ('1', ): diff --git a/core/SConscript.unix b/core/SConscript.unix index 2c80b07f2..0a848b301 100644 --- a/core/SConscript.unix +++ b/core/SConscript.unix @@ -444,6 +444,7 @@ if NEW_RENDERING: else: SOURCE_MOD += [ 'embed/trezorhal/unix/display-unix.c', + 'embed/lib/dma2d_emul.c', ] @@ -462,10 +463,6 @@ if DMA2D: 'USE_DMA2D', ] - SOURCE_UNIX += [ - 'embed/lib/dma2d_emul.c', - ] - TRANSLATION_DATA = [ "translations/en.json", diff --git a/core/embed/lib/dma2d_emul.c b/core/embed/lib/dma2d_emul.c index 7685ff060..99fb880be 100644 --- a/core/embed/lib/dma2d_emul.c +++ b/core/embed/lib/dma2d_emul.c @@ -20,8 +20,6 @@ #include "colors.h" #include "display.h" -#ifndef NEW_RENDERING - typedef enum { DMA2D_LAYER_FG = 1, DMA2D_LAYER_BG = 0, @@ -144,5 +142,3 @@ void dma2d_start_blend(uint8_t* overlay_addr, uint8_t* bg_addr, void dma2d_wait_for_transfer(void) { // done in place when emulating, so no need for wait here } - -#endif