1 /***************************************************************************
3 * Open \______ \ ____ ____ | | _\_ |__ _______ ___
4 * Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
5 * Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
6 * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
10 * Copyright (C) 2006,2007 by Greg White
12 * This program is free software; you can redistribute it and/or
13 * modify it under the terms of the GNU General Public License
14 * as published by the Free Software Foundation; either version 2
15 * of the License, or (at your option) any later version.
17 * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
18 * KIND, either express or implied.
20 ****************************************************************************/
22 /* This file MUST be included in your system-target.h file if you want arm
23 * cache coherence functions to be called (I.E. during codec load, etc).
29 #define CACHE_ALL 0x0C
33 void memory_init(void);
35 void enable_mmu(void);
36 void map_section(unsigned int pa
, unsigned int va
, int mb
, int flags
);
38 /* Cleans entire DCache */
39 void clean_dcache(void);
41 /* Invalidate entire DCache */
42 /* will do writeback */
43 void invalidate_dcache(void);
45 /* Invalidate DCache for this range */
46 /* will do writeback */
47 void invalidate_dcache_range(const void *base
, unsigned int size
);
49 /* clean DCache for this range */
50 /* forces DCache writeback for the specified range */
51 void clean_dcache_range(const void *base
, unsigned int size
);
53 /* Dump DCache for this range */
54 /* Will *NOT* do write back except for buffer ends not on a line boundary */
55 void dump_dcache_range(const void *base
, unsigned int size
);
57 /* Invalidate entire ICache and DCache */
58 /* will do writeback */
59 void invalidate_idcache(void);
61 #define HAVE_CPUCACHE_INVALIDATE
62 #define HAVE_CPUCACHE_FLUSH
64 #endif /* MMU_ARM_H */