该run命令用于运行 flash 管理工具。在开始之前,您需要一个可供 MILO 使用的设备,其中包含 updateflash 程序。这个程序(如 vmlinux)可以被 gzip 压缩。您需要使用(run)命令从 MILO 运行 flash 管理工具程序
MILO> run fd0:fmu.gz |
一旦加载和初始化完成,flash 管理工具将告诉您一些关于 flash 设备的信息,并提供一个命令提示符。同样,help命令是最有用的。
Linux MILO Flash Management Utility V1.0 Flash device is an Intel 28f008SA 16 segments, each of 0x10000 (65536) bytes Scanning Flash blocks for usage Block 12 contains the environment variables FMU> |
注意请注意,在可能存储环境变量且存在多个 flash 块的系统上(例如,AlphaPC64),flash 管理工具将查找一个块来保存 MILO 的环境变量。如果这样的块已经存在,flash 管理工具会告诉您它在哪里。否则,您必须使用environment命令来设置一个块并初始化它。在上面的例子中,flash 块 12 包含 MILO 的环境变量。
FMU> help FMU command summary: list - List the contents of flash program - program an image into flash quit - Quit environment - Set which block should contain the environment variables bootopt num - Select firmware type to use on next power up help - Print this help text FMU> |
注意,“environment和bootopt命令仅在 EB66+、AlphaPC64、EB164 和 PC164 系统(及其克隆版本)上可用。
“list” 命令显示 flash 存储器的当前使用情况。在有多个 flash 块的情况下,将显示每个 flash 块的使用情况。在下面的示例中,您可以看到 Windows NT ARC 正在使用块 4:7 和块 15。
FMU> list Flash blocks: 0:DBM 1:DBM 2:DBM 3:WNT 4:WNT 5:WNT 6:WNT 7:WNT 8:MILO 9:MILO 10:MILO 11:MILO 12:MILO 13:U 14:U 15:WNT Listing flash Images Flash image starting at block 0: Firmware Id: 0 (Alpha Evaluation Board Debug Monitor) Image size is 191248 bytes (3 blocks) Executing at 0x300000 Flash image starting at block 3: Firmware Id: 1 (Windows NT ARC) Image size is 277664 bytes (5 blocks) Executing at 0x300000 Flash image starting at block 8: Firmware Id: 7 (MILO/Linux) Image size is 217896 bytes (4 blocks) Executing at 0x200000 FMU> |
flash 管理工具包含 MILO flash 镜像的压缩副本。“program” 命令允许您将此镜像写入 flash。该命令允许您撤回,但在运行它之前,您应该使用 “list” 命令查看将 MILO 放在哪里。如果 MILO 已经在 flash 中,则 flash 管理工具将提供覆盖它的选项。
FMU> program Image is: Firmware Id: 7 (MILO/Linux) Image size is 217896 bytes (4 blocks) Executing at 0x200000 Found existing image at block 8 Overwrite existing image? (N/y)? y Do you really want to do this (y/N)? y Deleting blocks ready to program: 8 9 10 11 Programming image into flash Scanning Flash blocks for usage FMU> |
请等待它完成,然后再关闭系统电源。
注意我再怎么强调您在这里必须非常小心,不要覆盖您可能需要的现有 flash 镜像或使您的系统无法使用都不为过。一个非常好的规则是永远不要覆盖 Debug Monitor。
这会选择一个 flash 块来包含 MILO 的环境变量。
这与 MILO 的 “bootopt” 命令相同,请参阅(章节 第 6.4 节)。
这实际上是毫无意义的。一旦 flash 管理工具运行,返回 MILO(或任何其他程序)的唯一方法是重启系统。