■ Type This field can have one of the following values:
■ RESERVED Indicates that this area is reserved. Romimage.exe skips these sections during image creation. For example, the Ce.bib file shown in Figure 2-4 includes several RESERVED sections, such as an ARGS section to provide a shared memory area for the boot loader (EBOOT) to pass data to the system after startup (ARGS) and a DISPLAY section for a display buffer. The Ce.bib file of other OS designs might include different RESERVED sections for memory areas that the kernel is not supposed to use as system memory.
■ RAMIMAGE Defines the memory area that the system can use to load the kernel image and any modules you specified in the MODULES and FILES sections of .bib files. A run-time image can only have one RAMIMAGE section and the address range must be contiguous.
■ RAM Defines a memory area for the RAM file system and for running applications. This memory section must be contiguous. If you need a noncontiguous memory section, such as for extension dynamic RAM (DRAM) present on the device, you can allocate noncontiguous memory by implementing the OEMGetExtensionDRAM function in the OAL of the BSP. Windows Embedded CE supports up to two sections of physical noncontiguous memory.
.BIB File CONFIG Section The CONFIG section defines additional parameters for the run-time image, including the following options:
■ AUTOSIZE Automatically combines RAMIMAGE and RAM sections and allocates any unused memory in the RAMIMAGE section to RAM, or if necessary takes memory from the RAM section and provides it to the RAMIMAGE.
■ BOOTJUMP If specified, moves the boot jump page to a specific area within the RAMIMAGE section, rather than by using the default area.
■ COMPRESSION Automatically compresses writable memory sections in the image. The default value for this option is ON.
■ FIXUPVAR Initializes a kernel global variable during the Make Binary Image phase.
■ FSRAMPERCENT Sets the percentage of RAM used for the RAM file system.
■ KERNELFIXUPS Instructs Romimage.exe to relocate memory writable by the kernel. This option is generally enabled (ON).
■ OUTPUT Changes the directory that Romimage.exe uses as the output directory for the Nk.bin file.
■ PROFILE Specifies whether the image includes the profiler.
■ RAM_AUTOSIZE Expands the size of RAM to the end of the last XIP section.
■ RESETVECTOR Relocates the jump page to a specified location. This is required for MIPS processors to boot from 9FC00000.
■ ROM_AUTOSIZE Resizes XIP regions, taking into account the ROMSIZE_AUTOGAP setting.
■ ROMFLAGS Configures the following options for the kerneclass="underline"
■ Demand paging Fully copying a file into RAM before executing it or paging in parts of it.
■ Full kernel mode Run every OS thread in kernel mode, which leaves the system vulnerable to attack but improves performance.
■ Trust only ROM modules Marks only files in ROM as trusted.
■ Flush the X86 TLB onX86 systems Improves performance but adds a security risk.
■ Honor the /base linker setting Defines whether or not to use the /base linker setting in DLLs.
■ ROMOFFSET Enables you to run the run-time image in a memory location that is different from the storage location. For example, you can store the run-time image in FLASH memory, and then copy and run it from RAM.
■ ROMSIZE Specifies the size of the ROM in bytes.
■ ROMSTART Specifies the ROM's starting address.
■ ROMWIDTH Specifies the number of data bits and how Romimage.exe splits the run-time image. Romimage.exe can put the entire run-time image into one file, split the run-time image into two files of even and odd 16-bit words, or create four files of even and odd 8-bit bytes.
■ SRE Determines whether Romimage.exe generates a .sre file. Motorola S-record (SRE) is a file format recognized by most ROM burners.
■ X86BOOT Specifies whether or not to add a JUMP instruction at the x86 reset vector address.
■ XIPSCHAIN Enables the creation of Chain.bin and Chain.lst files to set up an XIP chain, so that you can split an image into multiple files.
.BIB File MODULES and FILES Sections BSP and OS design developers must frequently edit the MODULES and FILES sections of a .bib file to add new components to a run-time image. The format for the MODULES and FILES section is practically identical, although the MODULES section supports more configuration options. The key difference is that the MODULES section lists files not compressed in memory to support XIP, while the FILES section lists files that are compressed. The operating system must decompress the data when accessing the files.
The following listing shows two small MODULES and FILES sections from a Platform.bib file. For a complete example, check out the Platform.bib file of the Device Emulator BSP.
MODULES
; Name Path Memory Type
; -------------- ---------------------------- -----------
; @CESYSGEN IF CE_MODULES_DISPLAY
IF BSP_NODISPLAY !
DeviceEmulator_lcd.dll $(_FLATRELEASEDIR)\DeviceEmulator_lcd.dll NK SHK
IF BSP_NOBACKLIGHT !
backlight.dll $(_FLATRELEASEDIR)\backlight.dll NK SHK
ENDIF BSP_NOBACKLIGHT !
ENDIF BSP_NODISPLAY !
; @CESYSGEN ENDIF CE_MODULES_DISPLAY
FILES
; Name Path Memory Type
; -------------- ---------------------------- -----------
; @CESYSGEN IF CE_MODULES_PPP
dmacnect.lnk $(_FLATRELEASEDIR)\dmacnect.lnk NK SH
; @CESYSGEN ENDIF CE_MODULES_PPP
You can define the following options for file references in MODULES and FILES sections:
■ Name The name of the module or file as it appears in the memory table. This name is usually the same as the file name in the run-time image.
■ Path The complete path to the file that Romimage.exe incorporates into the run-time image.
■ Memory References the name of a memory area in the MEMORY section of the Config.bib file into which Romimage.exe loads the module or file. It is usually set to NK to integrate the file in the NK area defined in the MEMORY section.
■ Section Override Enables you to specify modules in a FILES section and files in a MODULES section. Essentially, Romimage.exe ignores the section in which the entry resides, and treats the entry as a member of the specified section. This parameter is optional.
■ Type Specifies the file type and can be a combination of flags, as shown in Table 2-3.