1 <!-- Copyright (C) 2003 Red Hat, Inc. -->
2 <!-- This material may be distributed only subject to the terms -->
3 <!-- and conditions set forth in the Open Publication License, v1.0 -->
4 <!-- or later (the latest version is presently available at -->
5 <!-- http://www.opencontent.org/openpub/). -->
6 <!-- Distribution of the work or derivative of the work in any -->
7 <!-- standard (paper) book form is prohibited unless prior -->
8 <!-- permission is obtained from the copyright holder. -->
12 >RedBoot Resource Usage</TITLE
13 ><meta name="MSSmartTagsPreventParsing" content="TRUE">
16 CONTENT="Modular DocBook HTML Stylesheet Version 1.76b+
19 TITLE="eCos Reference Manual"
20 HREF="ecos-ref.html"><LINK
22 TITLE="Getting Started with RedBoot"
23 HREF="getting-started-with-redboot.html"><LINK
25 TITLE="RedBoot Startup Mode"
26 HREF="startup-mode.html"><LINK
28 TITLE="Configuring the RedBoot Environment"
29 HREF="configuring-the-redboot-environment.html"></HEAD
40 SUMMARY="Header navigation table"
49 >eCos Reference Manual</TH
57 HREF="startup-mode.html"
65 >Chapter 1. Getting Started with RedBoot</TD
71 HREF="configuring-the-redboot-environment.html"
85 NAME="RESOURCE-USAGE">RedBoot Resource Usage</H1
89 >RedBoot takes up both flash and RAM resources depending on its
90 startup mode and number of enabled features. There are also other
91 resources used by RedBoot, such as timers. Platform-specific resources
92 used by RedBoot are listed in the platform specific parts of this
95 >Both flash and RAM resources used by RedBoot depend to some
96 degree on the features enabled in the RedBoot configuration. It is
97 possible to reduce in particular the RAM resources used by RedBoot by
98 removing features that are not needed. Flash resources can also be
99 reduced, but due to the granularity of the flash (the block sizes),
100 reductions in feature size do not always result in flash resource
107 NAME="AEN2631">Flash Resources</H2
109 >On many platforms, a ROM mode RedBoot image resides in the first
110 flash sectors, working as the board's primary boot monitor. On these
111 platforms, it is also normal to reserve a similar amount of flash for
112 a secondary RAM mode image, which is used when updating the primary
115 >On other platforms, a ROMRAM mode RedBoot image is used as the
116 primary boot monitor. On these platforms there is not normally
117 reserved space for a RAM mode RedBoot image, since the ROMRAM mode
118 RedBoot is capable of updating the primary boot monitor image.</P
120 >Most platforms also contain a FIS directory (keeping track of
121 available flash space) and a RedBoot config block (containing RedBoot
122 board configuration data).</P
124 >To see the amount of reserved flash memory, run the <B
143 Name FLASH addr Mem addr Length Entry point
144 RedBoot 0x00000000 0x00000000 0x00020000 0x00000000
145 RedBoot[RAM] 0x00020000 0x06020000 0x00020000 0x060213C0
146 RedBoot config 0x0007F000 0x0007F000 0x00001000 0x00000000
147 FIS directory 0x00070000 0x00070000 0x0000F000 0x00000000</PRE
153 >To save flash resources, use a ROMRAM mode RedBoot, or if using
154 a ROM mode RedBoot, avoid reserving space for the RedBoot[RAM] image
155 (this is done by changing the RedBoot configuration) and download the
156 RAM mode RedBoot whenever it is needed. If the RedBoot image takes up
157 a fraction of an extra flash block, it may be possible to reduce the
158 image size enough to free this block by removing some features.</P
165 NAME="AEN2641">RAM Resources</H2
167 >RedBoot reserves RAM space for its run-time data, and such
168 things as CPU exception/interrupt tables. It normally does so at the
169 bottom of the memory map. It may also reserve space at the top of the
170 memory map for configurable RedBoot features such as the net stack
171 and zlib decompression support.</P
173 >To see the actual amount of reserved space, issue the
177 > command, which prints the RedBoot banner,
178 including the RAM usage:
194 RedBoot(tm) bootstrap and debug environment [ROM]
195 Non-certified release, version UNKNOWN - built 13:31:57, May 17 2002
197 Platform: FooBar (SH 7615)
198 Copyright (C) 2000, 2001, 2002, Red Hat, Inc.
204 >RAM: 0x06000000-0x06080000, 0x06012498-0x06061000 available</I
207 FLASH: 0x00000000 - 0x00080000, 8 blocks of 0x00010000 bytes each.</PRE
213 >To simplify operations that temporarily need data in free
214 memory, the limits of free RAM are also available as aliases (aligned
215 to the nearest kilo-byte limit). These are named
218 be used in commands like any user defined alias:
230 >load -r -b %{FREEMEMLO} file</B
233 Raw file loaded 0x06012800-0x06013e53, assumed entry at 0x06012800</PRE
249 >x -b %{FREEMEMHI}</B
252 06061000: 86 F5 EB D8 3D 11 51 F2 96 F4 B2 DC 76 76 8F 77 |....=.Q.....vv.w|
253 06061010: E6 55 DD DB F3 75 5D 15 E0 F3 FC D9 C8 73 1D DA |.U...u]......s..|</PRE
259 >To reduce RedBoot's RAM resource usage, use a ROM mode
260 RedBoot. The RedBoot features that use most RAM are the net stack, the
261 flash support and the gunzip support. These, and other features, can
262 be disabled to reduce the RAM footprint, but obviously at the cost of
263 lost functionality.</P
271 SUMMARY="Footer navigation table"
282 HREF="startup-mode.html"
300 HREF="configuring-the-redboot-environment.html"
310 >RedBoot Startup Mode</TD
316 HREF="getting-started-with-redboot.html"
324 >Configuring the RedBoot Environment</TD