X-Git-Url: https://git.sur5r.net/?a=blobdiff_plain;f=arch%2Fnios2%2Fcpu%2Fcpu.c;h=edf256017a3c2e79bcf295df3a2ee9034b48a739;hb=f9342e2c3e81d62e42393c0c1a8179c309ef3a20;hp=ef360eecbb4075aa1f39ca9b767c0450a84df23d;hpb=cdc51c294ad33879c4e57edf4c9d2155381b1d59;p=u-boot diff --git a/arch/nios2/cpu/cpu.c b/arch/nios2/cpu/cpu.c index ef360eecbb..edf256017a 100644 --- a/arch/nios2/cpu/cpu.c +++ b/arch/nios2/cpu/cpu.c @@ -24,6 +24,7 @@ #include #include #include +#include #if defined (CONFIG_SYS_NIOS_SYSID_BASE) extern void display_sysid (void); @@ -47,3 +48,18 @@ int do_reset(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) nios2_callr(CONFIG_SYS_RESET_ADDR); return 0; } + +int dcache_status(void) +{ + return 1; +} + +void dcache_enable(void) +{ + flush_dcache(CONFIG_SYS_DCACHE_SIZE, CONFIG_SYS_DCACHELINE_SIZE); +} + +void dcache_disable(void) +{ + flush_dcache(CONFIG_SYS_DCACHE_SIZE, CONFIG_SYS_DCACHELINE_SIZE); +}