[U-Boot] [U-Boot, v2, 2/4] tools: moved code common to all image tools to a separated module.

Tom Rini trini at ti.com
Mon Dec 16 15:15:34 CET 2013


On Sun, Dec 01, 2013 at 12:43:10PM -0700, Simon Glass wrote:

> From: Guilherme Maciel Ferreira <guilherme.maciel.ferreira at gmail.com>
> 
> In order to avoid duplicating code and keep only one point of modification,
> the functions, structs and defines useful for "dumpimage" were moved from
> "mkimage" to a common module called "imagetool".
> 
> This modification also weakens the coupling between image types (FIT, IMX, MXS,
> and so on) and image tools (mkimage and dumpimage). Any tool may initialize the
> "imagetool" through register_image_tool() function, while the image types
> register themselves within an image tool using the register_image_type()
> function:
> 
>                                                       +---------------+
>                                                +------|   fit_image   |
>  +--------------+          +-----------+       |      +---------------+
>  |    mkimage   |--------> |           | <-----+
>  +--------------+          |           |              +---------------+
>                            | imagetool | <------------|    imximage   |
>  +--------------+          |           |              +---------------+
>  |  dumpimage   |--------> |           | <-----+
>  +--------------+          +-----------+       |      +---------------+
>                                                +------| default_image |
>                                                       +---------------+
> 
>           register_image_tool()           register_image_type()
> 
> Also, the struct "mkimage_params" was renamed to "image_tool_params" to make
> clear its general purpose.
> 
> Signed-off-by: Guilherme Maciel Ferreira <guilherme.maciel.ferreira at gmail.com>
> Signed-off-by: Simon Glass <sjg at chromium.org>

Applied to u-boot/master, thanks!

-- 
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: Digital signature
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20131216/f66a8548/attachment.pgp>


More information about the U-Boot mailing list