- 21 Jul, 2013 1 commit
-
-
Marek Vasut authored
This was a result of shuffling the code around, remove this useless line. Signed-off-by:
Marek Vasut <marex@denx.de>
-
- 17 Jul, 2013 3 commits
-
-
Marek Vasut authored
By using the -i option of MXSSB, one can now validate if the input image is correct. MXSSB will also dump the contents of the image. Signed-off-by:
Marek Vasut <marex@denx.de>
-
Marek Vasut authored
The MODE command string-value mapping table will be re-used by the image validator when it will be dumping the image contents, so pull the table out from the function. Signed-off-by:
Marek Vasut <marex@denx.de>
-
Marek Vasut authored
Rework the crypto functions so they can both encrypt and decrypt the payload. This will make use of them easy once we implement image verification. Signed-off-by:
Marek Vasut <marex@denx.de>
-
- 16 Jul, 2013 10 commits
-
-
Marek Vasut authored
Rename the functions to better match their purpose. This will come helpful when implementing image verification. Signed-off-by:
Marek Vasut <marex@denx.de>
-
Marek Vasut authored
Documentation is a must, add proper README file for this tool. Signed-off-by:
Marek Vasut <marex@denx.de>
-
Marek Vasut authored
The last missing command is the MODE command. Implement this command for the completeness of the command set. Signed-off-by:
Marek Vasut <marex@denx.de>
-
Marek Vasut authored
With the current parser, it is very easy to implement the commands. Implement the FILL command, which fills the memory with pattern. Signed-off-by:
Marek Vasut <marex@denx.de>
-
Marek Vasut authored
The jump command is almost identical to the CALL command, with the difference that CALL command saves stack and allows the called code to return into the BootROM. JUMP command does not do that, it just sets the PC register to a value and that's it. The sematics of both commands are almost identical though, therefore implement JUMP as a minor adjustment to CALL. Signed-off-by:
Marek Vasut <marex@denx.de>
-
Marek Vasut authored
It's year 2013 now, update the copyright message. Since the tool now also supports MX233, mention it in the description. Signed-off-by:
Marek Vasut <marex@denx.de>
-
Marek Vasut authored
The command stream is now in a configuration file, the target_cpu field is no longer used. Remove it. Signed-off-by:
Marek Vasut <marex@denx.de>
-
Marek Vasut authored
The section count can be calculated while parsing the configuration file. Do it and then use it when filling the SB image header. Moreover, the bootable section and possible multiple bootable sections collision can also be much better identified while parsing the configuration file. Signed-off-by:
Marek Vasut <marex@denx.de>
-
Marek Vasut authored
Rework the command parser. The command parsing can happen when reading the configuration file already, there is no need to read the configuration file in and parse only the result. The parser is now executed directly on each line that is read by from the configuration file instead and builds the image tree right away. Moreover, the parser is now implemented in much cleaner way and the command and section generation is cleanly separated. Finally, the memory usage of the tool went down by 20% . Signed-off-by:
Marek Vasut <marex@denx.de>
-
Marek Vasut authored
The IVT flag is completely useless now, especially since we treat the IVT as yet another data payload rather than something special. Signed-off-by:
Marek Vasut <marex@denx.de>
-
- 14 Jul, 2013 26 commits
-
-
Marek Vasut authored
Add the newly allocated section into the section list very early, so that in case of a failure during command parsing, the section can be properly deallocated with all the other sections. Signed-off-by:
Marek Vasut <marex@denx.de>
-
Marek Vasut authored
Report proper error messages when the command parsing function fails. Also report line number at which the error happened. Signed-off-by:
Marek Vasut <marex@denx.de>
-
Marek Vasut authored
Move the line tokenization fully into the sb_tag_to_command(). Moreover, improve error return and reporting from this function. Signed-off-by:
Marek Vasut <marex@denx.de>
-
Marek Vasut authored
Save the number at which line the command was. This will help when reporting errors from the parser. Signed-off-by:
Marek Vasut <marex@denx.de>
-
Marek Vasut authored
Use -EINVAL instead of -1 in the error messages. Signed-off-by:
Marek Vasut <marex@denx.de>
-
Marek Vasut authored
In case the parser comes across another section, it should return into the section loop instead of treating it as an unknown instruction. Signed-off-by:
Marek Vasut <marex@denx.de>
-
Marek Vasut authored
The BOOTABLE flag was set by default during development. This is not correct, implement a proper BOOTABLE flag for each section and make this configurable from the command file. Signed-off-by:
Marek Vasut <marex@denx.de>
-
Marek Vasut authored
The comma shall not be at the end of enum according to GCC. Signed-off-by:
Marek Vasut <marex@denx.de>
-
Marek Vasut authored
Remove these useless #define'd values. Signed-off-by:
Marek Vasut <marex@denx.de>
-
Marek Vasut authored
Check if the configuration file contains the LAST option of TAG command and if so, set up the LAST flag in the SB file. Signed-off-by:
Marek Vasut <marex@denx.de>
-
Marek Vasut authored
Properly set the HAB flag to a #define'd value instead of a hardcoded value. Signed-off-by:
Marek Vasut <marex@denx.de>
-
Marek Vasut authored
Add example configuration files for loading U-Boot and it's SPL on both MX23 and MX28. Signed-off-by:
Marek Vasut <marex@denx.de>
-
Marek Vasut authored
Load the instructions that shall be inserted into the SB image from file. There is now an easy parser and the built-in instruction tables are gone. WARNING: This breaks the command line interface! Signed-off-by:
Marek Vasut <marex@denx.de>
-
Marek Vasut authored
When loading the command table, it is much more beneficial to load it as a linked list, especially since we will be soon loading the table from a file. Signed-off-by:
Marek Vasut <marex@denx.de>
-
Marek Vasut authored
The static IVT tables are no longer used, remove them. Signed-off-by:
Marek Vasut <marex@denx.de>
-
Marek Vasut authored
The command file parsing should be in a separate function and should be called right before the image is being produced. Move the parsing into separate function from set_cpu(). Signed-off-by:
Marek Vasut <marex@denx.de>
-
Marek Vasut authored
Implement simple parser that reads command from text input. This allows us to get rid of the built-in tables and replace them with built-in blocks of text. In the long run, they are easily replacable by file input. Note that in order to preserve all functionality, the table containing instructions need to be hand-patched, therefore there is some copying happening in set_cpu(). Moreover, set_cpu() is now called a little later to ensure the filenames of spl and u-boot are already read. Signed-off-by:
Marek Vasut <marex@denx.de>
-
Marek Vasut authored
The verbose boot flag should be part of the image context, make it so. Signed-off-by:
Marek Vasut <marex@denx.de>
-
Marek Vasut authored
Use enum of list of CPU types to improve the typing of the variable. Signed-off-by:
Marek Vasut <marex@denx.de>
-
Marek Vasut authored
The CPU model should be part of the image context, make it so. Signed-off-by:
Marek Vasut <marex@denx.de>
-
Marek Vasut authored
Write the output file directly instead of creating a block in memory and then writing this whole block into a file. This saves some memory and is a bit easier. Signed-off-by:
Marek Vasut <marex@denx.de>
-
Marek Vasut authored
So far, we only support one section, but once we have proper parser we will be able to support multiple sections. Prepare for this by implementing the section generation in the image tree correctly. Signed-off-by:
Marek Vasut <marex@denx.de>
-
Marek Vasut authored
In case the memory allocation fails in the command parser, there will might remain some allocated memory upon return. Fix this. Signed-off-by:
Marek Vasut <marex@denx.de>
-
Marek Vasut authored
No functional change in the code, just reorder the functions so they are not in such a state of chaos. Signed-off-by:
Marek Vasut <marex@denx.de>
-
Marek Vasut authored
The variable was initialized and reinitialized twice as a remnant of the rework, initialize it only once. Signed-off-by:
Marek Vasut <marex@denx.de>
-
Marek Vasut authored
There is no need to pass the IV explicitly as another argument, the function can pull this information from the image context. Signed-off-by:
Marek Vasut <marex@denx.de>
-