
On Wed, 17 Nov 2010 13:42:43 +0100 Detlev Zundel dzu@denx.de wrote:
Yes, a simple C tool to take an existing PBL or RCW dump and "espi-ize" it into a PBL dump would be nice. The user will still need to acquire the existing RCW manually. This only needs to be done once on a board; it's not part of building a U-Boot image.
@Scott: What is meant by "acquiring the existing RCW"? Can't we have a tool that is fed with a value for RCW?
I mean that a simple tool could take an existing RCW and modify it for espi boot, but it needs to take as input an RCW that is valid for other parameters.
The least error prone way to do this, for a user that wants to take a board that's already successfully booting from NOR and make it boot from eSPI, is to extract the RCW they're already using from the board.
Creating an RCW from scratch is more complicated, which is why we have that javascript tool -- though we could provide some example RCWs for common configs.
This README describes how to build an Image can be used by PBL (pre-boot loader), building u-boot image is the first step, then RCW, PBI commands, XXD dump of u-boot.bin, the tool will combine the RCW and PBI and XXD dump together to produce the PBL XXD file, suppose the PBL XXD file is saved as x.xxd, we need to run "xxd -r x.xxd > pbl_image.bin" to produce the final PBL Image. Take a look at the whole process, I see no way it can be scripted / automatized.
I said it once before, look at how kwbimage wraps up u-boot.bin into such an "augmented" image. If the Marvell guys can do this for their platform, I see no reason why this cannot be done for your platform.
Sure, once you have a valid input RCW it should be possible to automate the rest.
-Scott