Fix error: implicit declaration of function 'cp15_invalidate_icache'; did you mean 'cp15_invalidate_dcache'?

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
This commit is contained in:
Xiang Xiao 2022-12-25 20:51:09 +08:00 committed by Xiang Xiao
parent c61195bcc9
commit 1ea9db4ebe
5 changed files with 37 additions and 3 deletions

View File

@ -714,7 +714,7 @@ int up_addrenv_coherent(const group_addrenv_t *addrenv)
/* Invalidate I-Cache */
cp15_invalidate_icache();
up_invalidate_icache_all();
/* Clean D-Cache in each region.
* REVISIT: Cause crashes when trying to clean unmapped memory. In order

View File

@ -902,6 +902,23 @@ extern "C"
* Public Function Prototypes
****************************************************************************/
/****************************************************************************
* Name: cp15_invalidate_icache
*
* Description:
* Invalidate the instruction cache within the specified region.
*
* Input Parameters:
* start - virtual start address of region
* end - virtual end address of region + 1
*
* Returned Value:
* None
*
****************************************************************************/
void cp15_invalidate_icache(uintptr_t start, uintptr_t end);
/****************************************************************************
* Name: cp15_dcache_op_level
*

View File

@ -909,6 +909,23 @@ extern "C"
* Public Function Prototypes
****************************************************************************/
/****************************************************************************
* Name: cp15_invalidate_icache
*
* Description:
* Invalidate the instruction cache within the specified region.
*
* Input Parameters:
* start - virtual start address of region
* end - virtual end address of region + 1
*
* Returned Value:
* None
*
****************************************************************************/
void cp15_invalidate_icache(uintptr_t start, uintptr_t end);
/****************************************************************************
* Name: cp15_dcache_op_level
*

View File

@ -504,7 +504,7 @@ void up_irqinitialize(void)
*/
vectorsize = sam_vectorsize();
cp15_invalidate_icache();
cp15_invalidate_icache(0, vectorsize);
cp15_invalidate_dcache(0, vectorsize);
mmu_invalidate_region(0, vectorsize);

View File

@ -151,7 +151,7 @@ int dram_main(int argc, char *argv[])
/* Invalidate caches and TLBs */
cp15_invalidate_icache();
cp15_invalidate_icache_all();
cp15_invalidate_dcache_all();
cp15_invalidate_tlbs();