changeset 518:372757bb62e4

loadtools/loadtool.help updated for new flash handling architecture
author Mychaela Falconia <falcon@freecalypso.org>
date Sat, 01 Jun 2019 22:46:54 +0000
parents 809829dbc58a
children f9d2ce6591b7
files loadtools/loadtool.help
diffstat 1 files changed, 69 insertions(+), 55 deletions(-) [+]
line wrap: on
line diff
--- a/loadtools/loadtool.help	Sat Jun 01 06:46:46 2019 +0000
+++ b/loadtools/loadtool.help	Sat Jun 01 22:46:54 2019 +0000
@@ -123,10 +123,8 @@
 
 The default method of cleaning up the target device state upon exit is set
 in the hardware parameters file selected with the -h or -H command line
-option; it is the exit-mode setting.  On the Pirelli phone the default exit
-mode is jump0: it causes the phone to reboot and enter the "charging boot"
-mode, as the USB cable is connected and VBUS is present.  On Compal phones the
-default exit mode is iota-off.
+option; it is the exit-mode setting.  On most targets the default exit mode is
+iota-off.
 
 If your device is a GTA02 and you are running fc-loadtool from inside the phone
 (from the AP), the exit command will power off the modem from the AP.  If you
@@ -142,18 +140,20 @@
 === flash
 === flash2
 The primary end use of fc-loadtool is for reading and writing the NOR flash
-memories of the supported GSM devices.  Compal phones and the GTA0x GSM modem
-have only one flash bank (as in chip select), and are manipulated with the
-flash command.  FreeCalypso devices and the Pirelli DP-L10 phone have two flash
-banks (as in chip selects) of 8 MiB each; they are manipulated with the flash
-and flash2 commands.
+memories of the supported GSM devices.  Most Calypso phones and modems have
+only one flash bank (as in chip select), and are manipulated with the flash
+command.  FreeCalypso development boards and the Pirelli DP-L10 phone have two
+flash banks (as in chip selects) of 8 MiB each; they are manipulated with the
+flash and flash2 commands.
 
-The following flash operations are available on all target devices:
+The following flash operations are available:
 
 flash blankchk		Blank-check a region of flash
 flash dump2bin		Dump flash content to a file in binary format
 flash dump2srec		Dump flash content to a file in S-record format
 flash erase		Erase a region of flash
+flash geom		Display geometry details of detected flash chip
+flash id		Perform flash chip autodetection sequence
 flash info		Display flash configuration info
 flash program-bin	Program flash with a binary file
 flash program-m0	Program flash with an image in TI's *.m0 format
@@ -161,28 +161,16 @@
 flash quickprog		Program a few flash words from the command line
 flash reset		Reset flash chip to read array mode
 flash sectors		Display the list of flash sector addresses and sizes
+flash status		Intel-style flash only: read Status Register
+flash unlock		Intel-style flash only: unlock flash sectors
+
+Additional operation for Compal targets only:
+
+flash erase-program-boot	Erase and reprogram the boot sector
 
 Substitute flash2 instead of flash when operating on the 2nd flash chip select
 of Pirelli-style flash memory configurations.  Prepend help before a command to
-get usage information, e.g., help flash program-bin.  See help compal for some
-additional info specific to Compal targets.
-
-=== compal
-=== compalflash
-=== flash:compal
-Compal phones have Intel or Intel-style flash chips; other Calypso targets for
-which loadtool was originally designed have AMD-style flash chips.  The author
-of the present software has a personal bias toward AMD-style flash, hence the
-support for Intel-style flash is not as clean.  Compal phones also have the
-Calypso boot ROM disabled, and depend on flash-resident boot code instead.
-This property makes them brickable.
-
-The following additional loadtool commands apply only to Compal targets with
-Intel-style flash:
-
-flash erase-program-boot	Erase and reprogram the boot sector
-flash status			Read Intel flash Status Register
-flash unlock			Unlock flash sectors
+get usage information, e.g., help flash program-bin.
 
 === flash:blankchk
 flash[2] blankchk hex-start-offset hex-length
@@ -199,8 +187,11 @@
 specified, the full flash bank is dumped; one can optionally specify a starting
 offset and an explicit length, both in hex.
 
-This command is merely a user-friendly front-end to the plain dump2bin command;
-see help dump2bin.
+This command was originally nothing more than a user-friendly front-end to the
+plain dump2bin command (see help dump2bin), but in the current version it first
+performs the flash chip autodetection operation if it hasn't been done already
+(needed in order to determine the size of the flash bank) and resets the flash
+to read array mode.
 
 === flash:dump2srec
 flash[2] dump2srec outfile [offset [length]]
@@ -209,8 +200,11 @@
 specified, the full flash bank is dumped; one can optionally specify a starting
 offset and an explicit length, both in hex.
 
-This command is merely a user-friendly front-end to the plain dump2srec command;
-see help dump2srec.
+This command was originally nothing more than a user-friendly front-end to the
+plain dump2srec command (see help dump2srec), but in the current version it
+first performs the flash chip autodetection operation if it hasn't been done
+already (needed in order to determine the size of the flash bank) and resets
+the flash to read array mode.
 
 === flash:erase
 flash[2] erase hex-start-offset hex-length
@@ -219,11 +213,11 @@
 address of the flash bank) and extending for the specified hex length.
 
 Flash memory can only be erased (turning 0 bits back to 1s) in units of
-sectors, as set in stone by the design of the flash chip in use.  Loadtool
-knows the sector layout of the flash chip in your device from CFI or from the
-hardware parameters file (you can display it with the flash[2] sectors
-command), and enforces that both arguments to the flash[2] erase command lie
-on sector boundaries.
+sectors, as set in stone by the design of the flash chip in use.  Loadtool will
+autodetect the flash chip in use and will only operate on those flash chip types
+which it knows about; if a known chip is found, loadtool knows its sector layout
+and enforces that both arguments to the flash[2] erase command lie on sector
+boundaries.
 
 === flash:erase-program-boot
 flash erase-program-boot binfile [length]
@@ -243,9 +237,27 @@
 must not exceed the length of flash sector 0: 64 KiB on the "basic" Compal
 phones or 8 KiB on C155/156.
 
+=== flash:geom
+This command displays information about the detected flash chip: device name,
+geometry details and the command set style (AMD or Intel).  The displayed
+geometry details include the total size of the flash bank, the total number of
+sectors, the number of regions with different sector sizes and the sector size
+and the number of sectors in each region.
+
+=== flash:id
+This command explicitly invokes the same flash chip autodetection operation
+that is performed the first time each flash bank is accessed with any flash or
+flash2 command.
+
 === flash:info
-This command displays summary information about the flash memory configuration
-of the Calypso target device loadtool thinks it's talking to.
+This command displays the global flash configuration settings that have been
+selected at fc-loadtool invokation time (hardware parameters associated with
+the target set via -h or -H): the global single-4M, single-8M or dual-8M
+setting and flash bank base addresses.
+
+In previous versions this command performed flash ID checks and displayed
+geometry information; these functions have been moved to the new flash id and
+flash geom commands.
 
 === flash:program-bin
 flash[2] program-bin flash-offset binfile [file-offset [length]]
@@ -296,30 +308,32 @@
 information.
 
 === flash:reset
-Intel-style flash memory chips (found in Compal phones) have two "stable" or
-"quiescent" states: reading array data and reading the status register (SR).
-After an erase or program operation the flash chip is "parked" in the Read SR
-state; the flash reset command switches it back to reading array data.
+Intel-style flash memory chips have two "stable" or "quiescent" states: reading
+array data and reading the status register (SR).  After an erase or program
+operation the flash chip is "parked" in the Read SR state; the flash reset
+command switches it back to reading array data.
 
-This command works for AMD-style flash as well (found in Openmoko and Pirelli
-phones), but it is normally not needed, as AMD-style flash chips automatically
-return to the read-array-data state after every erase or program operation.
+This command works for AMD-style flash as well, but it is normally not needed,
+as AMD-style flash chips automatically return to the read-array-data state
+after every erase or program operation.
 
 === flash:sectors
-This command displays the list of sector offsets and sizes for the flash chip
-in the Calypso target device loadtool thinks it's talking to.
+This command displays the list of sector offsets and sizes for the detected
+flash chip.  This command is deprecated except for debugging of loadtool
+internals; the new flash geom command displays the same information in a much
+more compact form.
 
 === flash:status
-This command is only applicable to Intel-style flash as found in Compal phones.
-It reads the flash chip's Status Register, which can be used to diagnose errors
-incurred by previous erase or program operations.
+This command is only applicable to Intel-style flash chips.  It reads the flash
+chip's Status Register, which can be used to diagnose errors incurred by
+previous erase or program operations.
 
 === flash:unlock
 flash unlock hex-start-offset hex-length
 
-This command is only applicable to Intel-style flash as found in Compal phones.
-These flash chips power up with each sector (erase block) in the "locked" state;
-each sector needs to be unlocked before it can be erased or programmed.
+This command is only applicable to Intel-style flash chips.  These flash chips
+power up with each sector (erase block) in the "locked" state; each sector
+needs to be unlocked before it can be erased or programmed.
 
 This command is normally not needed, as the flash erase command unlocks each
 sector before erasing it.  However, if you are going to perform program