Memory Architecture
6-30
ADSP-BF535 Blackfin Processor Hardware Reference
Example Code for Direct Invalidation
The following four listings show how to invalidate instruction cache
(
Listing 6-1
), how to invalidate data cache (
Listing 6-2
), how to invalidate
Superbank A (
Listing 6-3
), and how to invalidate Superbank B
(
Listing 6-4
).
Listing 6-1. Invalidating Instruction Cache Lines Directly
/* Setting the icache to cache for preloading */
P0.L = (IMEM_CONTROL & 0xFFFF);
P0.H = (IMEM_CONTROL >> 16);
R0.L = 0X5; /* Enable instruction memory as cache. */
R0.H = 0X0;
[P0] = R0;
P1.L = (DMEM_CONTROL & 0xFFFF);
P1.H = (DMEM_CONTROL >> 16);
R0.L = 0XD; /* Enable data bank A and B as caches.
*/
R0.H = 0X0;
[P1] = R0;
csync;
/* Preloading the Instruction Cache */
/* Registers used:
*/
/* r0 - contains the command value. written to ITEST COMMAND */
/* r1 - value written to ITEST DATA0 and ITEST DATA1 */
/* * DATA write */
/* - contains the instruction to be written */
/* r2 - contains intermediate values during computation
*/
/* r3 - contains mask for the double word index (bit[3:4]=00) */
/* r4 - contains mask for the set index (bit[5:9]=00000) */
/* r5 - contains mask for the ways (bit[26:27]=00) */
/* r6 - value written to ITEST DATA0 */
/* * TAG write */
/* - contains the original address */
Summary of Contents for ADSP-BF535 Blackfin
Page 80: ...Development Tools 1 26 ADSP BF535 Blackfin Processor Hardware Reference...
Page 312: ...Working With Memory 6 86 ADSP BF535 Blackfin Processor Hardware Reference...
Page 332: ...System Interfaces 7 20 ADSP BF535 Blackfin Processor Hardware Reference...
Page 360: ...Dynamic Power Management Controller 8 28 ADSP BF535 Blackfin Processor Hardware Reference...
Page 446: ...Beginning and Ending an SPI Transfer 10 40 ADSP BF535 Blackfin Processor Hardware Reference...
Page 522: ...Timing Examples 11 76 ADSP BF535 Blackfin Processor Hardware Reference...
Page 562: ...IrDA Support 12 40 ADSP BF535 Blackfin Processor Hardware Reference...
Page 608: ...PCI I O Issues 13 46 ADSP BF535 Blackfin Processor Hardware Reference...
Page 672: ...References 14 64 ADSP BF535 Blackfin Processor Hardware Reference...
Page 810: ...SDRAM Controller SDC 18 86 ADSP BF535 Blackfin Processor Hardware Reference...
Page 811: ...ADSP BF535 Blackfin Processor Hardware Reference 18 87 External Bus Interface Unit...
Page 812: ...SDRAM Controller SDC 18 88 ADSP BF535 Blackfin Processor Hardware Reference...
Page 860: ...DMA Bus Debug Registers 20 30 ADSP BF535 Blackfin Processor Hardware Reference...