Datasheet

Chapter 4. Local Memory 4-1
Chapter 4
Local Memory
This chapter describes the MCF5407 implementation of the ColdFire Version 4 local
memory specication. It consists of two major sections.
Section 4.2, “SRAM Overview,” describes the MCF5407 on-chip static RAM
(SRAM) implementation. It covers general operations, conguration, and
initialization. It also provides information and examples showing how to minimize
power consumption when using the SRAM.
Section 4.7, “Cache Overview,” describes the MCF5407 cache implementation,
including organization, conguration, and coherency. It describes cache operations
and how the cache interfaces with other memory structures.
4.1 Interactions between Local Memory Modules
Depending on conguration information, instruction fetches and data read accesses may be
sent simultaneously to the RAM and cache controllers. This approach is required because
all three controllers are memory-mapped devices and the hit/miss determination is made
concurrently with the read data access. Power dissipation can be minimized by conguring
the RAMBARs to mask unused address spaces whenever possible.
If the access address is mapped into the region dened by the RAM (and this region is not
masked), the RAM provides the data back to the processor, and the cache data is discarded.
Accesses from the RAM module are never cached. The complete denition of the
processor’s local bus priority scheme for read references is as follows:
if (RAM “hits”
) RAM supplies data to the processor
else if (data cache “hits”)
data cache supplies data to the processor
else system memory reference to access data
For data write references, the memory mapping into the local memories is resolved before
the appropriate destination memory is accessed. Accordingly, only the targeted local
memory is accessed for data write transfers.
4.2 SRAM Overview
The two 2-Kbyte on-chip SRAM modules provide pipelined, single-cycle access to
memory mapped to these modules. Memory can be independently mapped to any