Build fails for u-boot jpg driver using defconfig sg2002_licheea53nano_sd #108

Open
opened 2025-12-15 02:47:19 -05:00 by Nefarious19 · 2 comments
Nefarious19 commented 2025-12-15 02:47:19 -05:00 (Migrated from github.com)

Title says everything. Build for risc-v works ok. But for a53 there is an error as below:

/workdir/u-boot-2021.10/drivers/jpeg/jpurun.c: In function ‘copy_to_dest_addr’: /workdir/u-boot-2021.10/drivers/jpeg/jpurun.c:113:2: error: implicit declaration of function ‘flush_dcache_range’ [-Werror=implicit-function-declaration] flush_dcache_range((unsigned long)pRefYuv, (unsigned long)pRefYuv + lumaSize + chromaSize + chromaSize); ^~~~~~~~~~~~~~~~~~ CC drivers/video/panel-uclass.o /workdir/u-boot-2021.10/drivers/jpeg/jdi.c: In function ‘jdi_write_register’: /workdir/u-boot-2021.10/drivers/jpeg/jdi.c:226:2: error: implicit declaration of function ‘flush_dcache_range’ [-Werror=implicit-function-declaration] flush_dcache_range(reg_addr, reg_addr + sizeof(unsigned int)); ^~~~~~~~~~~~~~~~~~ /workdir/u-boot-2021.10/drivers/jpeg/jdi.c: In function ‘jdi_read_register’: /workdir/u-boot-2021.10/drivers/jpeg/jdi.c:237:2: error: implicit declaration of function ‘invalidate_dcache_range’ [-Werror=implicit-function-declaration] invalidate_dcache_range(reg_addr, reg_addr + sizeof(unsigned int)); ^~~~~~~~~~~~~~~~~~~~~~~ /workdir/u-boot-2021.10/drivers/jpeg/jdi_osal.c: In function ‘josal_memcpy’: /workdir/u-boot-2021.10/drivers/jpeg/jdi_osal.c:107:2: error: implicit declaration of function ‘flush_dcache_range’ [-Werror=implicit-function-declaration] flush_dcache_range((unsigned long)dst, count); ^~~~~~~~~~~~~~~~~~ CC drivers/video/simple_panel.o /workdir/u-boot-2021.10/drivers/jpeg/jdi_osal.c: In function ‘jinv_dcache_range’: /workdir/u-boot-2021.10/drivers/jpeg/jdi_osal.c:409:2: error: implicit declaration of function ‘invalidate_dcache_range’ [-Werror=implicit-function-declaration] invalidate_dcache_range(start, size); ^~~~~~~~~~~~~~~~~~~~~~~

Title says everything. Build for risc-v works ok. But for a53 there is an error as below: `/workdir/u-boot-2021.10/drivers/jpeg/jpurun.c: In function ‘copy_to_dest_addr’: /workdir/u-boot-2021.10/drivers/jpeg/jpurun.c:113:2: error: implicit declaration of function ‘flush_dcache_range’ [-Werror=implicit-function-declaration] flush_dcache_range((unsigned long)pRefYuv, (unsigned long)pRefYuv + lumaSize + chromaSize + chromaSize); ^~~~~~~~~~~~~~~~~~ CC drivers/video/panel-uclass.o /workdir/u-boot-2021.10/drivers/jpeg/jdi.c: In function ‘jdi_write_register’: /workdir/u-boot-2021.10/drivers/jpeg/jdi.c:226:2: error: implicit declaration of function ‘flush_dcache_range’ [-Werror=implicit-function-declaration] flush_dcache_range(reg_addr, reg_addr + sizeof(unsigned int)); ^~~~~~~~~~~~~~~~~~ /workdir/u-boot-2021.10/drivers/jpeg/jdi.c: In function ‘jdi_read_register’: /workdir/u-boot-2021.10/drivers/jpeg/jdi.c:237:2: error: implicit declaration of function ‘invalidate_dcache_range’ [-Werror=implicit-function-declaration] invalidate_dcache_range(reg_addr, reg_addr + sizeof(unsigned int)); ^~~~~~~~~~~~~~~~~~~~~~~ /workdir/u-boot-2021.10/drivers/jpeg/jdi_osal.c: In function ‘josal_memcpy’: /workdir/u-boot-2021.10/drivers/jpeg/jdi_osal.c:107:2: error: implicit declaration of function ‘flush_dcache_range’ [-Werror=implicit-function-declaration] flush_dcache_range((unsigned long)dst, count); ^~~~~~~~~~~~~~~~~~ CC drivers/video/simple_panel.o /workdir/u-boot-2021.10/drivers/jpeg/jdi_osal.c: In function ‘jinv_dcache_range’: /workdir/u-boot-2021.10/drivers/jpeg/jdi_osal.c:409:2: error: implicit declaration of function ‘invalidate_dcache_range’ [-Werror=implicit-function-declaration] invalidate_dcache_range(start, size); ^~~~~~~~~~~~~~~~~~~~~~~`
Nefarious19 commented 2025-12-15 02:57:31 -05:00 (Migrated from github.com)

When I've fixed temporary by adding functions declarations to files I've encountered another problem:

Image
When I've fixed temporary by adding functions declarations to files I've encountered another problem: <img width="2340" height="755" alt="Image" src="https://github.com/user-attachments/assets/6a9267bb-192b-4471-bd74-43fcdfbf091e" />
Tualua commented 2026-03-11 01:02:15 -04:00 (Migrated from github.com)

Got the same problem

Got the same problem
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
maxpeterkaya/LicheeRV-Nano-Build#108
No description provided.