mirror of
https://source.denx.de/u-boot/u-boot.git
synced 2025-08-19 05:31:31 +02:00
Remove <common.h> from all mach-npcm files and when needed add missing include files directly. Signed-off-by: Tom Rini <trini@konsulko.com>
30 lines
468 B
C
30 lines
468 B
C
// SPDX-License-Identifier: GPL-2.0+
|
|
/*
|
|
* Copyright (c) 2021 Nuvoton Technology Corp.
|
|
*/
|
|
|
|
#include <config.h>
|
|
#include <asm/io.h>
|
|
#include <asm/pl310.h>
|
|
|
|
void l2_pl310_init(void);
|
|
|
|
void set_pl310_ctrl(u32 enable)
|
|
{
|
|
struct pl310_regs *const pl310 = (struct pl310_regs *)CFG_SYS_PL310_BASE;
|
|
|
|
writel(enable, &pl310->pl310_ctrl);
|
|
}
|
|
|
|
void v7_outer_cache_enable(void)
|
|
{
|
|
l2_pl310_init();
|
|
|
|
set_pl310_ctrl(1);
|
|
}
|
|
|
|
void v7_outer_cache_disable(void)
|
|
{
|
|
set_pl310_ctrl(0);
|
|
}
|