[U-Boot-Users] [PATCH 02/13] [new uImage] Define a API for image handling operations

Marian Balakowicz m8 at semihalf.com
Tue Jan 15 11:58:33 CET 2008


Wolfgang Denk wrote:
> In message <20080111142800.8025.66590.stgit at hekate.izotz.org> you wrote:
>> - Add inline helper macros for basic header processing
>> - Move common non inline code common/image.c
>> - Replace direct header access with the API routines
>> - Rename IH_CPU_* to IH_ARCH_*
> 
> Please review your patches and make sure to keep  the  original  for-
> matting of the U-Boot output; for example:
[snip]

> --- a/include/image.h
> +++ b/include/image.h
> ...
> +char *strncpy(char *dest, const char *src, size_t count);
> 
> Please don't do this! Include the appropriate header file instead.

Will fix.


> +static inline int image_check_target_arch(image_header_t *hdr)
> 
> Theoretical thought: could it  ever  happen  that  we  might  have  a
> multi-architecture image?

With the new uImage that would be possible, each component image will
have it's own arch/os properties.

The above routine (handling current image format which does not allow
multi arch images) checks whether image arch matches target arch.

It is a reasonable check, running other arch images usually make
little sens. That would also apply for new uImage format, we may have
multiple component images (each for different arch) but before running
selected image we check for arch compatibility.

Cheers,
m.




More information about the U-Boot mailing list